Class StringSpan

    • Constructor Detail

      • StringSpan

        public StringSpan​(java.lang.CharSequence doc,
                          int start,
                          int end)
    • Method Detail

      • intersection

        public Span intersection​(Span r)
        Description copied from interface: Span
        Returns a new span that is the intersection of this span and another.
        Specified by:
        intersection in interface Span
      • getDocument

        public java.lang.Object getDocument()
        Specified by:
        getDocument in interface Span
      • intersects

        public boolean intersects​(Span r)
        Specified by:
        intersects in interface Span
      • isSubspan

        public boolean isSubspan​(Span r)
        Specified by:
        isSubspan in interface Span
      • getStartIdx

        public int getStartIdx()
        Description copied from interface: Span
        Returns an integer index identifying the start of this span. Beware that in some cases (e.g., for images), this may not correspond directly to a sequence index.
        Specified by:
        getStartIdx in interface Span
      • getEndIdx

        public int getEndIdx()
        Description copied from interface: Span
        Returns an integer index identifying the end of this span. Beware that in some cases (e.g., for images), this may not correspond directly to a sequence index.
        Specified by:
        getEndIdx in interface Span
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class Token