public final class HostnameFormatSpecifier extends FormatSpecifier
host-name format specification
Note: even though non FQDN hostnames are valid stricto sensu, this implementation considers non fully-qualified hostnames as invalid. While this contradicts the RFC, this is more in line with user expectations.
Guava's InternetDomainName is used for validation.
| Modifier and Type | Field and Description |
|---|---|
private static FormatSpecifier |
instance |
| Modifier | Constructor and Description |
|---|---|
private |
HostnameFormatSpecifier() |
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
checkValue(List<String> messages,
JsonNode value)
Abstract method implemented by all specifiers
|
static FormatSpecifier |
getInstance() |
validateprivate static final FormatSpecifier instance
public static FormatSpecifier getInstance()
void checkValue(List<String> messages, JsonNode value)
FormatSpecifierIt is only called if the value type is one expected by the
specifier, see FormatSpecifier.validate(List, JsonNode).
checkValue in class FormatSpecifiermessages - the list of messages to fillvalue - the value to validateCopyright © 2012. All Rights Reserved.