new parameter 'sortby' to searches (relevance, rating, views and date)
This commit is contained in:
parent
f1ee6d674a
commit
911cdc134b
5 changed files with 43 additions and 6 deletions
|
|
@ -41,12 +41,18 @@ class ICapVideoProvider(ICap):
|
|||
def iter_page_urls(self, mozaic_url):
|
||||
raise NotImplementedError()
|
||||
|
||||
def iter_search_results(self, pattern=None):
|
||||
(SEARCH_RELEVANCE,
|
||||
SEARCH_RATING,
|
||||
SEARCH_VIEWS,
|
||||
SEARCH_DATE) = range(4)
|
||||
|
||||
def iter_search_results(self, pattern=None, sortby=SEARCH_RELEVANCE):
|
||||
"""
|
||||
Iter results of a search on a pattern. Note that if pattern is None,
|
||||
it get the latest videos.
|
||||
|
||||
@param pattern [str] pattern to search on
|
||||
@param sortby [enum] sort by...
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue