Class SentenceImpl

  • All Implemented Interfaces:
    Sentence

    public class SentenceImpl
    extends BaseDocumentElem
    implements Sentence
    IMPORTANT: Never instantiate directly this class!
    Sentence of a document together with its descriptive features.
    • Constructor Detail

    • Method Detail

      • getId

        public Integer getId()
        Description copied from interface: Sentence
        Document-wide unambiguous sentence Id
        Specified by:
        getId in interface Sentence
        Returns:
      • setId

        public void setId​(Integer id)
      • getText

        public String getText()
        Description copied from interface: Sentence
        Text of the sentence
        Specified by:
        getText in interface Sentence
        Returns:
      • setText

        public void setText​(String text)
      • getAbstractId

        public Integer getAbstractId()
        Description copied from interface: Sentence
        Return the ID of the abstract the sentence belongs to. For papers having only one abstract, if the sentence is included in the abstract, its abstract ID is equal to 1. For papers having more than one abstract (one per language for instance), if the sentence is included in the first abstract, its abstract ID is equal to 1, otherwise its abstract ID is equal to 2. Sentences that are not part of the abstract of the paper have the abstract ID value set to -1.
        Specified by:
        getAbstractId in interface Sentence
        Returns:
      • setAbstractId

        public void setAbstractId​(Integer abstractId)
      • setContainingSection

        public void setContainingSection​(Section containingSection)
      • addCitationMarker

        public void addCitationMarker​(CitationMarker citationMarker)
      • addCandidateTerm

        public void addCandidateTerm​(CandidateTermOcc candidateTerm)
      • isAck

        public boolean isAck()
      • setAck

        public void setAck​(boolean isAck)
      • addBabelSynsetOcc

        public void addBabelSynsetOcc​(BabelSynsetOcc babelSynsetOcc)
      • setTokens

        public void setTokens​(List<Token> tokens)
      • getTokens

        public List<Token> getTokens()
        Description copied from interface: Sentence
        List of tokens included in the sentence
        Specified by:
        getTokens in interface Sentence
        Returns:
      • setLanguage

        public void setLanguage​(LangENUM languge)
      • getLanguage

        public LangENUM getLanguage()
        Description copied from interface: Sentence
        Get the language of the sentence
        Specified by:
        getLanguage in interface Sentence
        Returns:
      • asString

        public String asString​(boolean compactOutput)
        Description copied from interface: Sentence
        String representation of the object
        Specified by:
        asString in interface Sentence
        Returns:
      • isAcknowledgment

        public boolean isAcknowledgment()
        Description copied from interface: Sentence
        Check if a sentence is an acknowledgment
        Specified by:
        isAcknowledgment in interface Sentence
        Returns:
      • getSpottedEntities

        public Map<String,​MetaEntityTypeENUM> getSpottedEntities()
        Description copied from interface: Sentence
        It the sentence is an acknowledgment (in the current version only acknowledgment sentences may contain spotted entities)
        Specified by:
        getSpottedEntities in interface Sentence
        Returns: