예제 #1
0
    def __init__(self,start_url,thread_number,depth,queue):
        BaseSpider.__init__(self)
	self.start_url = start_url
        self.depth = depth
	self.good_keywords = ['topit']
	self.bad_keywords = ['login']
	self.number = thread_number
	self.queue = queue

	'递归,设置深度限制'
예제 #2
0
 def __init__(self, userid, topic, html_source, index, total_followee_num,
              cookie):
     BaseSpider.__init__(self, topic)
     self.userid = userid
     self.html_source = html_source
     self.tree = html.fromstring(self.html_source)
     self.index = index
     self.total_followee_num = total_followee_num
     self.cookies = cookie
     return
예제 #3
0
    def __init__(self,img_url,number,queue):
        BaseSpider.__init__(self)
	self.image_url = img_url
	self.number = str(number)
	self.queue = queue
	self.cd = ColorDescriptor((8, 12, 3))
예제 #4
0
 def __init__(self, userid, topic, headers, cookies):
     BaseSpider.__init__(self, topic)
     self.headers = headers
     self.cookies = cookies
     self.userid = userid
     self.topic = topic