Package com.networknt.schema.format
Class RegexFormat
java.lang.Object
com.networknt.schema.format.RegexFormat
- All Implemented Interfaces:
Format
Format for regex.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the message key to use for the message.getName()
Gets the format name.boolean
matches
(ExecutionContext executionContext, ValidationContext validationContext, String value) Determines if the value matches the format.
-
Constructor Details
-
RegexFormat
public RegexFormat()
-
-
Method Details
-
matches
public boolean matches(ExecutionContext executionContext, ValidationContext validationContext, String value) Description copied from interface:Format
Determines if the value matches the format. -
getName
Description copied from interface:Format
Gets the format name. -
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
-