Esempio n. 1
0
    def __init__(self, root):
        self.root = root
        self.children = []  # so it knows there are no static children

        cfg = ConfigParser()
        cfg.readfp(open('scrapy.properties'))

        self.graph_default = loads(cfg.get('autodiscover', 'graph_default'))
        keys_default = loads(cfg.get('autodiscover', 'keys_default'))
        for k in self.graph_default['keys']:
            self.graph_default['keys'][k].update(keys_default)

        JsonResource.__init__(self)
Esempio n. 2
0
    def __init__(self, root):
        self.root = root
        self.children = []  # so it knows there are no static children

        cfg = ConfigParser()
        cfg.readfp(open('scrapy.properties'))

        self.graph_default = loads(cfg.get('autodiscover', 'graph_default'))
        keys_default = loads(cfg.get('autodiscover', 'keys_default'))
        for k in self.graph_default['keys']:
            self.graph_default['keys'][k].update(keys_default)

        JsonResource.__init__(self)
Esempio n. 3
0
 def __init__(self, crawler, target=None):
     JsonResource_.__init__(self)
     self.crawler = crawler
     self.json_encoder = ScrapyJSONEncoder(crawler=crawler)
Esempio n. 4
0
 def __init__(self, root):
     JsonResource.__init__(self)
     self.root = root
Esempio n. 5
0
 def __init__(self, root):
     self.root = root  # it looks as a WsResource this way...
     JsonResource.__init__(self)
Esempio n. 6
0
    def __init__(self, root):
        self.root = root
        self.children = []  # so it knows there are no static children

        JsonResource.__init__(self)
Esempio n. 7
0
 def __init__(self, root):
     self.root = root  # it looks as a WsResource this way...
     JsonResource.__init__(self)
Esempio n. 8
0
    def __init__(self, root):
        self.root = root
        self.children = []  # so it knows there are no static children

        JsonResource.__init__(self)