예제 #1
0
    def get_request_url(self, query, filterAdultContents, limit):
        """Returns the request url expanding the query, filter adult content,
        and results limit place holders.
        """
        request_url = self.url.replace(u"%s", urlencode(query))
        request_url = request_url.replace(u"%a", 
                                          unicode(int(not filterAdultContents)))
        request_url = request_url.replace(u"%l", unicode(int(limit)))

        return request_url
예제 #2
0
 def file_handler(self, path):
     return 'file://' + urlencode(path)
예제 #3
0
 def file_handler(self, path):
     return 'file://' + urlencode(path)