Classes | |
| class | OutStreamEncoder |
| class | XmlHandler |
| class | Videos |
Functions | |
| def | detectUserLocationByIP |
| def | massageDescription |
| def | _initLogger |
| def | textUtf8 |
| def | ampReplace |
| def | setTreeViewIcon |
| def | processVideoUrl |
| def | searchTitle |
| def | searchForVideos |
| def | displayTreeView |
| def | makeURL |
| def | getVideos |
| def | getVideosForURL |
| def | getVideosForGroupURL |
Variables | |
| string | __title__ = "dailymotion_api - Simple-to-use Python interface to the dailymotion API (http://www.dailymotion.com/ca-en/doc/api/player)" |
| string | __author__ = "R.D. Vaughan" |
| string | __purpose__ |
| string | __version__ = "v0.2.4" |
| tree_dir_icon | |
| channel | |
| treeview | |
| tree_key | |
| next_page | |
| groupview | |
| group_id | |
| groupview_image | |
| def nv_python_libs::dailymotion::dailymotion_api::detectUserLocationByIP | ( | self | ) |
Get longitude and latitiude to find videos relative to your location. Up to three different
servers will be tried before giving up.
return a dictionary e.g.
{'Latitude': '43.6667', 'Country': 'Canada', 'Longitude': '-79.4167', 'City': 'Toronto'}
return an empty dictionary if there were any errors
Code found at: http://blog.suinova.com/2009/04/from-ip-to-geolocation-country-city.html
Definition at line 548 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::massageDescription | ( | self, | ||
| text | ||||
| ) |
Removes HTML markup from a text string. @param text The HTML source. @return The plain text. If the HTML source contains non-ASCII entities or character references, this is a Unicode string.
Definition at line 607 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::_initLogger | ( | self | ) | [private] |
Setups a logger using the logging module, returns a log object
Definition at line 641 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::textUtf8 | ( | self, | ||
| text | ||||
| ) |
Definition at line 660 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::ampReplace | ( | self, | ||
| text | ||||
| ) |
Replace all "&" characters with "&"
Definition at line 672 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::setTreeViewIcon | ( | self, | ||
dir_icon = None | ||||
| ) |
Check if there is a specific generic tree view icon. If not default to the channel icon. return self.tree_dir_icon
Definition at line 680 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::processVideoUrl | ( | self, | ||
| url | ||||
| ) |
Definition at line 702 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::searchTitle | ( | self, | ||
| title, | ||||
| pagenumber, | ||||
| pagelen | ||||
| ) |
Key word video search of the Dailymotion web site return an array of matching item dictionaries return
Definition at line 707 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::searchForVideos | ( | self, | ||
| title, | ||||
| pagenumber | ||||
| ) |
Common name for a video search. Used to interface with MythTV plugin NetVision
Definition at line 721 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::displayTreeView | ( | self | ) |
Gather the Dailymotion categories/feeds/...etc then get a max page of videos meta data in each of them. return array of directories and their video meta data
Definition at line 766 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::makeURL | ( | self, | ||
| URL | ||||
| ) |
Form a URL to search for videos return a URL
Definition at line 791 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::getVideos | ( | self, | ||
| dir_dict, | ||||
| dictionaries | ||||
| ) |
Parse a list made of category lists and retrieve video meta data return a dictionary of directory names and category's video meta data
Definition at line 817 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::getVideosForURL | ( | self, | ||
| url, | ||||
| dictionaries | ||||
| ) |
Get the video meta data for url search return the video dictionary of directories and their video mata data
Definition at line 851 of file dailymotion_api.py.
| def nv_python_libs::dailymotion::dailymotion_api::getVideosForGroupURL | ( | self, | ||
| url, | ||||
| dictionaries | ||||
| ) |
Get the video meta data for a group url search return the video dictionary of directories and their video mata data
Definition at line 977 of file dailymotion_api.py.
| string nv_python_libs::dailymotion::dailymotion_api::__title__ = "dailymotion_api - Simple-to-use Python interface to the dailymotion API (http://www.dailymotion.com/ca-en/doc/api/player)" |
Definition at line 15 of file dailymotion_api.py.
| string nv_python_libs::dailymotion::dailymotion_api::__author__ = "R.D. Vaughan" |
Definition at line 16 of file dailymotion_api.py.
''' This python script is intended to perform a variety of utility functions to search and access text meta data, video and image URLs from dailymotion. These routines are based on the api. Specifications for this api are published at http://www.dailymotion.com/ca-en/doc/api/player '''
Definition at line 17 of file dailymotion_api.py.
Definition at line 23 of file dailymotion_api.py.
Definition at line 684 of file dailymotion_api.py.
Definition at line 725 of file dailymotion_api.py.
Definition at line 781 of file dailymotion_api.py.
Definition at line 785 of file dailymotion_api.py.
Definition at line 874 of file dailymotion_api.py.
Definition at line 981 of file dailymotion_api.py.
Definition at line 1003 of file dailymotion_api.py.
Definition at line 1020 of file dailymotion_api.py.
1.6.3