Ejemplo n.º 1
0
    def __init__(self, package_name=None, path=None):
        self.package_name = package_name
        self.path = path
        self._dois = []
        self.articles_normalized = []
        self.logger = create_logger("Springer")

        if not path and package_name:
            self.logger.info("Got package: %s" % (package_name,))
            self.path = self._extract_packages()
        elif not path and not package_name:
            print "Starting harves"
            self.run()
        self._crawl_springer_and_find_main_xml()
Ejemplo n.º 2
0
    def __init__(self, package_name=None, path=None):
        self.package_name = package_name
        self.path = path
        self.found_articles = []
        self._found_issues = []
        self.logger = create_logger("Elsevier")

        if not path and package_name:
            self.logger.info("Got package: %s" % (package_name,))
            self._extract_package()
        elif not path and not package_name:
            print "Starting harves"
            from invenio.contrast_out import ContrastOutConnector
            self.conn = ContrastOutConnector(self.logger)
            self.conn.run()
        self._crawl_elsevier_and_find_main_xml()
        self._crawl_elsevier_and_find_issue_xml()
        self._build_doi_mapping()