HCE Project Python language Distributed Tasks Manager Application, Distributed Crawler Application and client API bindings.  2.0.0-chaika
Hierarchical Cluster Engine Python language binding
CrawledResource.py
Go to the documentation of this file.
1 """
2 HCE project, Python bindings, Distributed Tasks Manager application.
3 Event objects definitions.
4 
5 @package: dc
6 @file CrawledResource.py
7 @author Oleksii <developers.hce@gmail.com>
8 @link: http://hierarchical-cluster-engine.com/
9 @copyright: Copyright &copy; 2013-2014 IOIX Ukraine
10 @license: http://hierarchical-cluster-engine.com/license/
11 @since: 0.1
12 """
13 
14 
15 from dc.EventObjects import URL
16 # #The CrawledResource class
17 #
18 #
19 class CrawledResource(object):
20 
21 
22  def __init__(self):
23  # rendered unicode content for dynamic fetcher
24  self.html_content = ""
25  self.binary_content = ""
26  self.response_header = ""
27  self.html_request = ""
28  self.content_type = URL.CONTENT_TYPE_UNDEFINED
29  self.charset = ""
30  self.error_mask = 0
31  self.crawling_time = 0
32  self.http_code = 200
33  self.bps = 0
34  self.last_modified = ""
35  self.etag = ""
36  self.resource_changed = True
37  # before rendered unicode content for dynamic fetcher
38  self.meta_content = ""
39  self.cookies = {}
42