Class DefaultLineTracker

  • All Implemented Interfaces:
    ILineTracker, ILineTrackerExtension

    public class DefaultLineTracker
    extends AbstractLineTracker
    Standard implementation of ILineTracker.

    The line tracker considers the three common line delimiters which are '\n', '\r', '\r\n'.

    This class is not intended to be subclassed.

    This class is not intended to be subclassed by clients.
    • Field Detail


        public static final String[] DELIMITERS
        The predefined delimiters of this tracker
    • Constructor Detail

      • DefaultLineTracker

        public DefaultLineTracker()
        Creates a standard line tracker.
    • Method Detail

      • getLegalLineDelimiters

        public String[] getLegalLineDelimiters()
        Description copied from interface: ILineTracker
        Returns the strings this tracker considers as legal line delimiters.
        the legal line delimiters
      • nextDelimiterInfo

        protected AbstractLineTracker.DelimiterInfo nextDelimiterInfo​(String text,
                                                                      int offset)
        Description copied from class: AbstractLineTracker
        Returns the information about the first delimiter found in the given text starting at the given offset.
        Specified by:
        nextDelimiterInfo in class AbstractLineTracker
        text - the text to be searched
        offset - the offset in the given text
        the information of the first found delimiter or null