Esempio n. 1
0
    def parseJournalInfo(self, article):
        JournalInfo = {}

        try:
            JournalInfo['Journal'] = article[u'Article'][u'Journal'][u'Title']
        except:
            JournalInfo['Journal'] = ''
        try:
            JournalInfo['ISSN'] = article[u'Article'][u'Journal'][u'ISSN'][
                u'*content*']
        except:
            JournalInfo['ISSN'] = ''
        try:
            JournalInfo['Volume'] = article[u'Article'][u'Journal'][
                u'JournalIssue'][u'Volume']
        except:
            JournalInfo['Volume'] = ''
        try:
            JournalInfo['Issue'] = article[u'Article'][u'Journal'][
                u'JournalIssue'][u'Issue']
        except:
            JournalInfo['Issue'] = ''
        try:
            PubDateYear = article[u'Article'][u'Journal'][u'JournalIssue'][
                u'PubDate'][u'Year']
        except:
            PubDateYear = '1500'
        try:
            PubDateMonth = article[u'Article'][u'Journal'][u'JournalIssue'][
                u'PubDate'][u'Month']
        except:
            PubDateMonth = '01'
        try:
            PubDateDay = article[u'Article'][u'Journal'][u'JournalIssue'][
                u'PubDate'][u'Day']
        except:
            PubDateDay = '01'
        JournalInfo['PubDate'] = utils.parseEpochDeltaFromDate(PubDateMonth +
                                                               '-' +
                                                               PubDateDay +
                                                               '-' +
                                                               PubDateYear)
        try:
            JournalInfo['ISOAbbreviation'] = article[u'Article'][u'Journal'][
                u'ISOAbbreviation']
        except:
            JournalInfo['ISOAbbreviation'] = ''

        return JournalInfo
Esempio n. 2
0
 def parseDateRevised(self, article):
     try:
         DateRevisedYear = article[u'DateRevised'][u'Year']
     except:
         DateRevisedYear = '1500'
     try:
         DateRevisedMonth = article[u'DateRevised'][u'Month']
     except:
         DateRevisedMonth = '01'
     try:
         DateRevisedDay = article[u'DateRevised'][u'Day']
     except:
         DateRevisedDay = '01'
     DateRevised = DateRevisedMonth + '-' + DateRevisedDay + '-' + DateRevisedYear
     return utils.parseEpochDeltaFromDate(DateRevised)
Esempio n. 3
0
 def parseDateRevised(self, article):
     try:
         DateRevisedYear = article[u'DateRevised'][u'Year']
     except:
         DateRevisedYear = '1500'
     try:
         DateRevisedMonth = article[u'DateRevised'][u'Month']
     except:
         DateRevisedMonth = '01'
     try:
         DateRevisedDay = article[u'DateRevised'][u'Day']
     except:
         DateRevisedDay = '01'
     DateRevised = DateRevisedMonth + '-' + DateRevisedDay + '-' + DateRevisedYear
     return utils.parseEpochDeltaFromDate(DateRevised)
Esempio n. 4
0
    def parseJournalInfo(self, article):
        JournalInfo = {}

        try:
            JournalInfo['Journal'] = article[u'Article'][u'Journal'][u'Title']
        except:
            JournalInfo['Journal'] = ''
        try:
            JournalInfo['ISSN'] = article[u'Article'][u'Journal'][u'ISSN'][u'*content*']
        except:
            JournalInfo['ISSN'] = ''
        try:
            JournalInfo['Volume'] = article[u'Article'][u'Journal'][u'JournalIssue'][u'Volume']
        except:
            JournalInfo['Volume'] = ''
        try:
            JournalInfo['Issue'] = article[u'Article'][u'Journal'][u'JournalIssue'][u'Issue']
        except:
            JournalInfo['Issue'] = ''
        try:
            PubDateYear = article[u'Article'][u'Journal'][u'JournalIssue'][u'PubDate'][u'Year']
        except:
            PubDateYear = '1500'
        try:
            PubDateMonth = article[u'Article'][u'Journal'][u'JournalIssue'][u'PubDate'][u'Month']
        except:
            PubDateMonth = '01'
        try:
            PubDateDay = article[u'Article'][u'Journal'][u'JournalIssue'][u'PubDate'][u'Day']
        except:
            PubDateDay = '01'
        JournalInfo['PubDate'] = utils.parseEpochDeltaFromDate(PubDateMonth + '-' + PubDateDay + '-' + PubDateYear)
        try:
            JournalInfo['ISOAbbreviation'] = article[u'Article'][u'Journal'][u'ISOAbbreviation']
        except:
            JournalInfo['ISOAbbreviation'] = ''

        return JournalInfo