TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Dec 2014 |
Maintained by Pedro Piñera.
Get showtimes from any City thanks to Google Showtime. I discovered there was no option to access to this information so I decided to parse the information directly from their Website. As iOS Developer I thought it would be useful to release a Objective-C class to get/parse this information for all developers. I called it PPiShowtime.
In order to use PPiShowtime in your project you only have to add PPiShowtime folder into your project. It contains Hpple folder. Hpple is the XML/HTML parser for Objective-C we use to parse Google Showtime information and it depends on libxml2 so you need to add it into your project:
PPiShowtime has class methods to get the information needed. The easiest way to understand them is using an Example:
Getting theaters from a given City
[PPiShowtime getShowTimesOfCity:@"Valencia"
shorter:PPiShowtimeShortingTheaters
forDay:PPiShowtimeDateToday
withSuccessfulHandler:^(NSArray *result) {}
andErrorHandler:^(NSError *error) {}];
Getting films from a given City
[PPiShowtime getShowTimesOfCity:@"Valencia"
shorter:PPiShowtimeShortingFilms
forDay:PPiShowtimeDateToday
withSuccessfulHandler:^(NSArray *result) {}
andErrorHandler:^(NSError *error) {}];
Getting theaters for a given film and City
[PPiShowtime getSchedulesForFilm:@"r3sacon"
inCity:@"Valencia"
forDay:PPiShowtimeDateToday
withSuccessfulHandler:^(NSDictionary *film) {}
andErrorHandler:^(NSError *error) {}];
Getting films for a given theater and City
[PPiShowtime getFilmsForTheater:@"Lys"
inCity:@"Valencia"
forDay:PPiShowtimeDateToday
withSuccessfulHandler:^(NSDictionary *film) {}
andErrorHandler:^(NSError *error) {}];
The main in put parameters are PPiShowtimeDate and PPiShowtimeShorting because you can specify the day and organize the data by films or by theaters.
Date:
Sorting:
Output data from first two methods depend on sorting method. In case you organize it by movies the result has the following structure:
And in case movie sorting:
Each film title containts moreover information about the film ( if it's in 3D or in Digital for example ). PPiShowtime parse this information and include it in an extra array with OPTIONS
If you like this library and you would like to contribute with it feel free to do it. I'll thank you. Moreover you'll find more information in my website www.ppinera.es and my portfolio as a developer.
MIT License