How to use the habanero.cross_cite.ccite function in habanero

To help you get started, we’ve selected a few habanero examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github sckott / habanero / habanero / habanero.py View on Github external
Usage::

            from habanero import Habanero
            hb = Habanero()
            hb.crosscite("10.5284/1011335")
            hb.crosscite(doi = ['10.5169/SEALS-52668','10.2314/GBV:493109919','10.2314/GBV:493105263','10.2314/GBV:487077911','10.2314/GBV:607866403'])
        '''
        if doi.__class__ == str:
            doi = [doi]
        if len(doi) > 1:
          coll = []
          for i in range(len(doi)):
            coll.append(ccite(doi[i], style, locale, **kwargs))
          return coll
        else:
          return ccite(doi[0], style, locale, **kwargs)
github sckott / habanero / habanero / habanero.py View on Github external
See http://www.crosscite.org/cn/ for more info on the
            Crossref Content Negotiation API service

        Usage::

            from habanero import Habanero
            hb = Habanero()
            hb.crosscite("10.5284/1011335")
            hb.crosscite(doi = ['10.5169/SEALS-52668','10.2314/GBV:493109919','10.2314/GBV:493105263','10.2314/GBV:487077911','10.2314/GBV:607866403'])
        '''
        if doi.__class__ == str:
            doi = [doi]
        if len(doi) > 1:
          coll = []
          for i in range(len(doi)):
            coll.append(ccite(doi[i], style, locale, **kwargs))
          return coll
        else:
          return ccite(doi[0], style, locale, **kwargs)