com.github.fge.jsonschema.format.helpers
Class SharedHostNameAttribute
java.lang.Object
com.github.fge.jsonschema.format.AbstractFormatAttribute
com.github.fge.jsonschema.format.helpers.SharedHostNameAttribute
- All Implemented Interfaces:
- FormatAttribute
public final class SharedHostNameAttribute
- extends AbstractFormatAttribute
Validator for the host-name
format attribute.
Important note: the basis for host name format validation is RFC 1034. The RFC does not
require that a host name have more than one domain name component. As
such, foo
is a valid hostname.
Guava's InternetDomainName
is used for validation.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SharedHostNameAttribute
public SharedHostNameAttribute(String fmt)
validate
public void validate(ProcessingReport report,
MessageBundle bundle,
FullData data)
throws ProcessingException
- Description copied from interface:
FormatAttribute
- Validate the instance against this format attribute
- Parameters:
report
- the report to usebundle
- the message bundle to usedata
- the validation data
- Throws:
ProcessingException
- an exception occurs (normally, never for a
format attribute)