Permalink
Browse files

Merge commit 'abe6a286c4bc98d3f3d1ed123791471d5e25b2cd'

  • Loading branch information...
2 parents f4bb17f + abe6a28 commit 7c0f6b23ff0b013149b92e191290072aa7a34c1d @wagnerrp wagnerrp committed Dec 30, 2012
@@ -80,9 +80,10 @@ This is not yet supported.
## Searching
There are currently three search methods available for use: movies, people,
-and studios. Search results from TheMovieDb are sent iteratively, twenty
-results per page. The search methods provided by the PyTMDB3 module return
-list-like structures that will automatically grab new pages as needed.
+studios, lists, and collections. Search results from TheMovieDb are sent
+iteratively, twenty results per page. The search methods provided by the
+PyTMDB3 module return list-like structures that will automatically grab new
+pages as needed.
>>> from tmdb3 import searchMovie
>>> res = searchMovie('A New Hope')
@@ -111,6 +112,16 @@ out. The people search method behaves similarly.
>>> res[0]
<Studio 'Sony Pictures'>
+The movieSearch() method accepts a 'year' keyword, tell tell TMDB to filter
+for movies of only that specific year. There is a helper method,
+movieSearchWithYear(), which will process the release year from movie names
+where the year is contained in parentheses, as in:
+
+ >>> from tmdb import searchMovieWithYear
+ >>> list(searchMovieWithYear('Star Wars (1977)'))
+ [<Movie 'Star Wars: Episode IV - A New Hope' (1977)>,
+ <Movie 'The Making of 'Star Wars'' (1977)>]
+
## Direct Queries
@@ -190,6 +201,8 @@ Collection:
Backdrop backdrop
Poster poster
list(Movie) members (sorted by release date)
+ list(Backdrop) backdrops
+ list(Poster) posters
Movie:
integer id
@@ -222,14 +235,34 @@ Movie:
list(Keyword) keywords
dict(Release) releases (indexed by country)
list(Translation) translations
+ list(Movie) similar
+ list(List) lists
list(Movie) getSimilar()
+ None setFavorite(bool) mark favorite status for current user
+ None setRating(int) rate movie by current user
+ None setWatchlist(bool) mark watchlist status for current user
Movie classmethods:
Movie fromIMDB(imdbid) special constructor for use with IMDb codes
Movie latest() gets latest movie added to database
list(Movie) nowplaying() content currently in theater
list(Movie) mostpopular() based off themoviedb.org page view counts
list(Movie) toprated() based off themoviedb.org user ratings
+ list(Movie) upcoming() curated list, typically contains 100 movies
+ list(Movie) favorites() current user's favorite movies
+ list(Movie) ratedmovies() movies rated by current user
+ list(Movie) watchlist() movies marked to watch by current user
+
+List:
+ hex string id
+ string name
+ string author
+ string description
+ integer favorites number of users that have marked list
+ string language
+ integer count
+ Poster poster
+ list(Movie) members
Person:
integer id
@@ -4,7 +4,7 @@
setup(
name='tmdb3',
- version='0.6.4',
+ version='0.6.16',
description='TheMovieDB.org APIv3 interface',
long_description="Object-oriented interface to TheMovieDB.org's v3 API.",
packages=['tmdb3']
@@ -1,7 +1,8 @@
#!/usr/bin/env python
-from tmdb_api import Configuration, searchMovie, searchPerson, searchStudio, \
- Studio, Person, Movie, Collection, Genre, __version__
+from tmdb_api import Configuration, searchMovie, searchMovieWithYear, \
+ searchPerson, searchStudio, searchList, searchCollection, \
+ Person, Movie, Collection, Genre, List, __version__
from request import set_key, set_cache
from locales import get_locale, set_locale
from tmdb_auth import get_session, set_session
@@ -6,6 +6,7 @@
# Author: Raymond Wagner
#-----------------------
+from tmdb_exceptions import *
import locale
syslocale = None
Oops, something went wrong.

0 comments on commit 7c0f6b2

Please sign in to comment.