Class CSLCitationItem

  • All Implemented Interfaces:
    JsonObject

    public class CSLCitationItem
    extends Object
    implements JsonObject
    A citation item is used to register a citation in the CSL processor. It usually only consists of the citation's ID but can also contain other formatting parameters.
    Author:
    Michel Kraemer
    • Method Detail

      • getId

        public String getId()
        Returns:
        the citation item's id
      • getItemData

        public CSLItemData getItemData()
        Returns:
        the citation item's itemData
      • getPrefix

        public String getPrefix()
        Returns:
        the citation item's prefix
      • getSuffix

        public String getSuffix()
        Returns:
        the citation item's suffix
      • getLocator

        public String getLocator()
        Returns:
        the citation item's locator
      • getPosition

        public Integer getPosition()
        Returns:
        the citation item's position
      • getNearNote

        public Boolean getNearNote()
        Returns:
        the citation item's near-note
      • getNoteNumber

        public Integer getNoteNumber()
        Returns:
        the citation item's note-number
      • getFirstReferenceNoteNumber

        public Integer getFirstReferenceNoteNumber()
        Returns:
        the citation item's first-reference-note-number
      • getLabel

        public CSLLabel getLabel()
        Returns:
        the citation item's label
      • getSuppressAuthor

        public Boolean getSuppressAuthor()
        Returns:
        the citation item's suppress-author
      • getAuthorOnly

        public Boolean getAuthorOnly()
        Returns:
        the citation item's author-only
      • getUris

        public String[] getUris()
        Returns:
        the citation item's uris
      • toJson

        public Object toJson​(JsonBuilder builder)
        Description copied from interface: JsonObject
        Converts this object to a JSON object
        Specified by:
        toJson in interface JsonObject
        Parameters:
        builder - a builder that can be used to perform the conversion
        Returns:
        the JSON object
      • fromJson

        public static CSLCitationItem fromJson​(Map<String,​Object> obj)
        Converts a JSON object to a CSLCitationItem object. The JSON object must at least contain the following required properties: id
        Parameters:
        obj - the JSON object to convert
        Returns:
        the converted CSLCitationItem object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object