java.time.format.internal

TTBPDateTimeParseContext

final class TTBPDateTimeParseContext extends AnyRef

Context object used during date and time parsing.

This class represents the current state of the parse. It has the ability to store and retrieve the parsed values and manage optional segments. It also provides key information to the parsing methods.

Once parsing is complete, the #toBuilder() is typically used to obtain a builder that can combine the separate parsed fields into meaningful values.

Specification for implementors

This class is a mutable context intended for use from a single thread. Usage of the class is thread-safe within standard parsing as a new instance of this class is automatically created for each parse and parsing is single-threaded

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. TTBPDateTimeParseContext
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new TTBPDateTimeParseContext(other: TTBPDateTimeParseContext)

  2. new TTBPDateTimeParseContext(locale: Locale, symbols: DecimalStyle, chronology: Chronology)

  3. new TTBPDateTimeParseContext(formatter: DateTimeFormatter)

    Creates a new instance of the context.

    Creates a new instance of the context.

    formatter

    the formatter controlling the parse, not null

  4. new TTBPDateTimeParseContext(locale: Locale, symbols: DecimalStyle, overrideChronology: Chronology, overrideZone: ZoneId, caseSensitive: Boolean = true, strict: Boolean = true)

Type Members

  1. final class Parsed extends TemporalAccessor

    Temporary store of parsed data.

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. def addChronologyChangedParser(reducedPrinterParser: ReducedPrinterParser, value: Long, errorPos: Int, successPos: Int): Unit

  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def charEquals(ch1: Char, ch2: Char): Boolean

    Helper to compare two char.

    Helper to compare two char. This uses #isCaseSensitive().

    ch1

    the first character

    ch2

    the second character

    returns

    true if equal

  9. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  10. def copy: TTBPDateTimeParseContext

    Creates a copy of this context.

  11. def endOptional(successful: Boolean): Unit

    Ends the parsing of an optional segment of the input.

    Ends the parsing of an optional segment of the input.

    successful

    whether the optional segment was successfully parsed

  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  16. def getEffectiveChronology: Chronology

    Gets the effective chronology during parsing.

    Gets the effective chronology during parsing.

    returns

    the effective parsing chronology, not null

  17. def getLocale: Locale

    Gets the locale.

    Gets the locale.

    This locale is used to control localization in the parse except where localization is controlled by the symbols.

    returns

    the locale, not null

  18. def getParsed(field: TemporalField): Long

    Gets the first value that was parsed for the specified field.

    Gets the first value that was parsed for the specified field.

    This searches the results of the parse, returning the first value found for the specified field. No attempt is made to derive a value. The field may have an out of range value. For example, the day-of-month might be set to 50, or the hour to 1000.

    field

    the field to query from the map, null returns null

    returns

    the value mapped to the specified field, null if field was not parsed

  19. def getSymbols: DecimalStyle

    Gets the formatting symbols.

    Gets the formatting symbols.

    The symbols control the localization of numeric parsing.

    returns

    the formatting symbols, not null

  20. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  21. def isCaseSensitive: Boolean

    Checks if parsing is case sensitive.

    Checks if parsing is case sensitive.

    returns

    true if parsing is case sensitive, false if case insensitive

  22. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  23. def isStrict: Boolean

    Checks if parsing is strict.

    Checks if parsing is strict.

    Strict parsing requires exact matching of the text and sign styles.

    returns

    true if parsing is strict, false if lenient

  24. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  25. final def notify(): Unit

    Definition Classes
    AnyRef
  26. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  27. def setCaseSensitive(caseSensitive: Boolean): Unit

    Sets whether the parsing is case sensitive or not.

    Sets whether the parsing is case sensitive or not.

    caseSensitive

    changes the parsing to be case sensitive or not from now on

  28. def setLocale(locale: Locale): Unit

    Sets the locale.

    Sets the locale.

    This locale is used to control localization in the print output except where localization is controlled by the symbols.

    locale

    the locale, not null

  29. def setParsed(zone: ZoneId): Unit

    Stores the parsed zone.

    Stores the parsed zone.

    This stores the zone that has been parsed. No validation is performed other than ensuring it is not null.

    zone

    the parsed zone, not null

  30. def setParsed(chrono: Chronology): Unit

    Stores the parsed chronology.

    Stores the parsed chronology.

    This stores the chronology that has been parsed. No validation is performed other than ensuring it is not null.

    chrono

    the parsed chronology, not null

  31. def setParsedField(field: TemporalField, value: Long, errorPos: Int, successPos: Int): Int

    Stores the parsed field.

    Stores the parsed field.

    This stores a field-value pair that has been parsed. The value stored may be out of range for the field - no checks are performed.

    field

    the field to set in the field-value map, not null

    value

    the value to set in the field-value map

    errorPos

    the position of the field being parsed

    successPos

    the position after the field being parsed

    returns

    the new position

  32. def setParsedLeapSecond(): Unit

    Stores the leap second.

  33. def setStrict(strict: Boolean): Unit

    Sets whether parsing is strict or lenient.

    Sets whether parsing is strict or lenient.

    strict

    changes the parsing to be strict or lenient from now on

  34. def startOptional(): Unit

    Starts the parsing of an optional segment of the input.

  35. def subSequenceEquals(cs1: CharSequence, offset1: Int, cs2: CharSequence, offset2: Int, length: Int): Boolean

    Helper to compare two CharSequence instances.

    Helper to compare two CharSequence instances. This uses #isCaseSensitive().

    cs1

    the first character sequence, not null

    offset1

    the offset into the first sequence, valid

    cs2

    the second character sequence, not null

    offset2

    the offset into the second sequence, valid

    length

    the length to check, valid

    returns

    true if equal

  36. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  37. def toParsed: Parsed

    Returns a TemporalAccessor that can be used to interpret the results of the parse.

    Returns a TemporalAccessor that can be used to interpret the results of the parse.

    returns

    an accessor with the results of the parse, not null

  38. def toString(): String

    Returns a string version of the context for debugging.

    Returns a string version of the context for debugging.

    returns

    a string representation of the context data, not null

    Definition Classes
    TTBPDateTimeParseContext → AnyRef → Any
  39. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  41. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped