uitdatabank.searchresults module¶
-
class
uitdatabank.searchresults.
SearchResults
(results_string)¶ Bases:
object
get_soonest_event
This function gets the earliest event in the search results get_events
The search results of a query on UiTdatabank are pure json, which is nice, but there should be some functionality to easily navigate this json file. The SearchResults class offers some functionalities.
Parameters: results_string – the json output of the uitdatabank json Returns: None As an example, you could look for upcoming events in Brussels:
>>> udb_shortcuts = Shortcuts("settings.cfg") >>> upcoming_events_in_brussels = udb_shortcuts.find_upcoming_events_by_city_name("Brussel") >>> for event in upcoming_events_in_brussels.get_events(): ... print(event)
-
get_events
()¶
-
get_soonest_event
()¶ This function gets the earliest event in the search results
Returns:
-