Package org.apache.commons.lang3.time
Class FastDateParser.CopyQuotedStrategy
java.lang.Object
org.apache.commons.lang3.time.FastDateParser.Strategy
org.apache.commons.lang3.time.FastDateParser.CopyQuotedStrategy
- Enclosing class:
- FastDateParser
A strategy that copies the static or quoted field in the parsing pattern
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCopyQuotedStrategy
(String formatField) Constructs a Strategy that ensures the formatField has literal text -
Method Summary
Modifier and TypeMethodDescription(package private) boolean
isNumber()
Is this field a number? The default implementation returns false.(package private) boolean
parse
(FastDateParser parser, Calendar calendar, String source, ParsePosition pos, int maxWidth) toString()
Converts this instance to a handy debug string.
-
Field Details
-
formatField
-
-
Constructor Details
-
CopyQuotedStrategy
CopyQuotedStrategy(String formatField) Constructs a Strategy that ensures the formatField has literal text- Parameters:
formatField
- The literal text to match
-
-
Method Details
-
isNumber
boolean isNumber()Is this field a number? The default implementation returns false.- Overrides:
isNumber
in classFastDateParser.Strategy
- Returns:
- true, if field is a number
-
parse
boolean parse(FastDateParser parser, Calendar calendar, String source, ParsePosition pos, int maxWidth) - Specified by:
parse
in classFastDateParser.Strategy
-
toString
Converts this instance to a handy debug string.
-