Skip to content

Commit

Permalink
PSR compliance.
Browse files Browse the repository at this point in the history
  • Loading branch information
wtfzdotnet committed Mar 1, 2014
1 parent 1e5a7b7 commit 2c19c97
Show file tree
Hide file tree
Showing 115 changed files with 468 additions and 241 deletions.
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/AbstractApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
* Class AbstractApi
* @package Tmdb\Api
*/
abstract class AbstractApi
implements ApiInterface
abstract class AbstractApi implements ApiInterface
{
/**
* The client
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Account.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#account
*/
class Account
extends AbstractApi
class Account extends AbstractApi
{
/**
* Get the basic information for an account. You will need to have a valid session id.
Expand Down
6 changes: 3 additions & 3 deletions lib/Tmdb/Api/Authentication.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#authentication
*/
class Authentication
extends AbstractApi
class Authentication extends AbstractApi
{
const REQUEST_TOKEN_URI = 'https://www.themoviedb.org/authenticate';

Expand Down Expand Up @@ -78,7 +77,8 @@ public function getNewSession($requestToken)
* You should only generate a single guest session per user (or device)
* as you will be able to attach the ratings to a TMDb user account in the future.
*
* There is also IP limits in place so you should always make sure it's the end user doing the guest session actions.
* There is also IP limits in place so you should always make sure it's the end user
* doing the guest session actions.
*
* If a guest session is not used for the first time within 24 hours, it will be automatically discarded.
*
Expand Down
6 changes: 3 additions & 3 deletions lib/Tmdb/Api/Certifications.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#certifications
*/
class Certifications
extends AbstractApi
class Certifications extends AbstractApi
{
/**
* Get the list of supported certifications for movies.
*
* These can be used in conjunction with the certification_country and certification.lte parameters when using discover.
* These can be used in conjunction with the certification_country and
* certification.lte parameters when using discover.
*
* @param array $parameters
* @param array $headers
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Changes.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* http://docs.themoviedb.apiary.io/#changes
*/
class Changes
extends AbstractApi
class Changes extends AbstractApi
{
/**
* Get a list of movie ids that have been edited.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Collections.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#collections
*/
class Collections
extends AbstractApi
class Collections extends AbstractApi
{
/**
* Get the basic collection information for a specific collection id.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Companies.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#companies
*/
class Companies
extends AbstractApi
class Companies extends AbstractApi
{
/**
* This method is used to retrieve all of the basic information about a company.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@
*
* @see http://docs.themoviedb.apiary.io/#configuration
*/
class Configuration
extends AbstractApi
class Configuration extends AbstractApi
{
/**
* Get the system wide configuration information.
Expand Down
10 changes: 6 additions & 4 deletions lib/Tmdb/Api/Credits.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,14 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#credits
*/
class Credits
extends AbstractApi
class Credits extends AbstractApi
{
/**
* Get the detailed information about a particular credit record. This is currently only supported with the new credit model found in TV.
* These ids can be found from any TV credit response as well as the tv_credits and combined_credits methods for people.
* Get the detailed information about a particular credit record.
*
* This is currently only supported with the new credit model found in TV.
* These ids can be found from any TV credit response as well as
* the tv_credits and combined_credits methods for people.
*
* The episodes object returns a list of episodes and are generally going to be guest stars.
* The season array will return a list of season numbers.
Expand Down
6 changes: 3 additions & 3 deletions lib/Tmdb/Api/Discover.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#discover
*/
class Discover
extends AbstractApi
class Discover extends AbstractApi
{
/**
* Discover movies by different types of data like average rating, number of votes, genres and certifications.
Expand All @@ -33,7 +32,8 @@ public function discoverMovies(array $parameters = array(), array $headers = arr
}

/**
* Discover TV shows by different types of data like average rating, number of votes, genres, the network they aired on and air dates.
* Discover TV shows by different types of data like average rating, number of votes, genres,
* the network they aired on and air dates.
*
* @param array $parameters
* @param array $headers
Expand Down
9 changes: 6 additions & 3 deletions lib/Tmdb/Api/Find.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,15 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#find
*/
class Find
extends AbstractApi
class Find extends AbstractApi
{
/**
* The find method makes it easy to search for objects in our database by an external id. For instance, an IMDB ID. This will search all objects (movies, TV shows and people) and return the results in a single response. TV season and TV episode searches will be supported shortly.
* The find method makes it easy to search for objects in our database by an external id.
*
* For instance, an IMDB ID. This will search all objects (movies, TV shows and people)
* and return the results in a single response.
*
* TV season and TV episode searches will be supported shortly.
* The supported external sources for each object are as follows:
*
* Movies: imdb_id
Expand Down
6 changes: 3 additions & 3 deletions lib/Tmdb/Api/Genres.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#genres
*/
class Genres
extends AbstractApi
class Genres extends AbstractApi
{
/**
* Get the list of genres, and return one by id
Expand Down Expand Up @@ -72,8 +71,9 @@ public function getMovies($genre_id, array $parameters = array(), array $headers
private function extractGenreByIdFromResponse($id, array $data = array())
{
foreach ($data as $genre) {
if ($id == $genre['id'])
if ($id == $genre['id']) {
return $genre;
}
}

return null;
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Jobs.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#jobs
*/
class Jobs
extends AbstractApi
class Jobs extends AbstractApi
{
/**
* Get a list of valid jobs.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Keywords.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#keywords
*/
class Keywords
extends AbstractApi
class Keywords extends AbstractApi
{
/**
* Get the basic information for a specific keyword id.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Lists.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#lists
*/
class Lists
extends AbstractApi
class Lists extends AbstractApi
{
/**
* Get a list by id.
Expand Down
18 changes: 11 additions & 7 deletions lib/Tmdb/Api/Movies.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#movies
*/
class Movies
extends AbstractApi
class Movies extends AbstractApi
{
/**
* Get the basic movie information for a specific movie id.
Expand Down Expand Up @@ -189,7 +188,8 @@ public function getLatest(array $parameters = array(), array $headers = array())
}

/**
* Get the list of upcoming movies. This list refreshes every day. The maximum number of items this list will include is 100.
* Get the list of upcoming movies. This list refreshes every day.
* The maximum number of items this list will include is 100.
*
* @param array $parameters
* @param array $headers
Expand All @@ -201,7 +201,8 @@ public function getUpcoming(array $parameters = array(), array $headers = array(
}

/**
* Get the list of movies playing in theatres. This list refreshes every day. The maximum number of items this list will include is 100.
* Get the list of movies playing in theatres. This list refreshes every day.
* The maximum number of items this list will include is 100.
*
* @param array $parameters
* @param array $headers
Expand All @@ -213,7 +214,8 @@ public function getNowPlaying(array $parameters = array(), array $headers = arra
}

/**
* Get the list of popular movies on The Movie Database. This list refreshes every day.
* Get the list of popular movies on The Movie Database.
* This list refreshes every day.
*
* @param array $parameters
* @param array $headers
Expand All @@ -225,7 +227,8 @@ public function getPopular(array $parameters = array(), array $headers = array()
}

/**
* Get the list of top rated movies. By default, this list will only include movies that have 10 or more votes. This list refreshes every day.
* Get the list of top rated movies. By default, this list will only include
* movies that have 10 or more votes. This list refreshes every day.
*
* @param array $parameters
* @param array $headers
Expand All @@ -237,7 +240,8 @@ public function getTopRated(array $parameters = array(), array $headers = array(
}

/**
* This method lets users get the status of whether or not the movie has been rated or added to their favourite or watch lists.
* This method lets users get the status of whether or not the movie has been rated
* or added to their favourite or watch lists.
*
* A valid session id is required.
*
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Networks.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#networks
*/
class Networks
extends AbstractApi
class Networks extends AbstractApi
{
/**
* This method is used to retrieve the basic information about a TV network.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/People.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#people
*/
class People
extends AbstractApi
class People extends AbstractApi
{
/**
* Get the general person information for a specific id.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Reviews.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#reviews
*/
class Reviews
extends AbstractApi
class Reviews extends AbstractApi
{
/**
* Get the full details of a review by ID.
Expand Down
3 changes: 1 addition & 2 deletions lib/Tmdb/Api/Search.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#search
*/
class Search
extends AbstractApi
class Search extends AbstractApi
{
/**
* Search for movies by title.
Expand Down
4 changes: 1 addition & 3 deletions lib/Tmdb/Api/Tv.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
* @package Tmdb\Api
* @see http://docs.themoviedb.apiary.io/#tv
*/
class Tv
extends AbstractApi
class Tv extends AbstractApi
{
/**
* Get the primary information about a TV series by id.
Expand Down Expand Up @@ -114,5 +113,4 @@ public function getTranslations($tvshow_id, array $parameters = array(), array $
{
$this->get('tv/' . $tvshow_id . '/translations', $parameters, $headers);
}

}
Loading

0 comments on commit 2c19c97

Please sign in to comment.