Interface PatternReader.TokenVisitor

All Known Implementing Classes:
CombinedDateTimePatternTokenVisitor
Enclosing class:
PatternReader

public static interface PatternReader.TokenVisitor
Visits a date time pattern token when one encountered. All methods receive a custom object.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Visits a literal token, i.e.
    void
    visitTokenLetter(int letter, int repetitions)
     
  • Method Details

    • visitLiteral

      void visitLiteral(String text)
      Visits a literal token, i.e. plain text without special meaning.
      Parameters:
      text - Plain text to process.
    • visitTokenLetter

      void visitTokenLetter(int letter, int repetitions)
      Parameters:
      letter - The token letter that was encountered, i.e. Y.
      repetitions - The number of repetitions of the letter. E.g. when a pattern contains YYYY, with method is called once with repetitions set to 4.