Package com.networknt.schema.format
Class TimeFormat
- java.lang.Object
-
- com.networknt.schema.format.TimeFormat
-
-
Field Summary
Fields Modifier and Type Field Description private static java.time.format.DateTimeFormatter
formatter
private static long
MAX_OFFSET_MIN
private static long
MIN_OFFSET_MIN
-
Constructor Summary
Constructors Constructor Description TimeFormat()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getMessageKey()
Gets the message key to use for the message.java.lang.String
getName()
Gets the format name.boolean
matches(ExecutionContext executionContext, java.lang.String value)
Determines if the value matches the format.
-
-
-
Field Detail
-
MAX_OFFSET_MIN
private static final long MAX_OFFSET_MIN
- See Also:
- Constant Field Values
-
MIN_OFFSET_MIN
private static final long MIN_OFFSET_MIN
- See Also:
- Constant Field Values
-
formatter
private static final java.time.format.DateTimeFormatter formatter
-
-
Method Detail
-
matches
public boolean matches(ExecutionContext executionContext, java.lang.String value)
Description copied from interface:Format
Determines if the value matches the format.This should be implemented for string node types.
-
getName
public java.lang.String getName()
Description copied from interface:Format
Gets the format name.
-
getMessageKey
public java.lang.String getMessageKey()
Description copied from interface:Format
Gets the message key to use for the message.See jsv-messages.properties.
The following are the arguments.
{0} The instance location
{1} The format name
{2} The error message description
{3} The input value- Specified by:
getMessageKey
in interfaceFormat
- Returns:
- the message key
-
-