Class EPPRegistryDomainName
- java.lang.Object
-
- com.verisign.epp.codec.registry.v02.EPPRegistryDomainName
-
- All Implemented Interfaces:
EPPCodecComponent
,java.io.Serializable
,java.lang.Cloneable
public class EPPRegistryDomainName extends java.lang.Object implements EPPCodecComponent
This class is encoded to the <registry:domainName> element inside the <registry:domain> element. It represents policies for a domain name label for a specific level, defined with the "level" attribute, with a minimum value of "2" for the second level domain name label level. The <registry:domainName> element contains the following child elements
- <registry:minLength> - An OPTIONAL minimum length of the domain
name label. Use
getMinLength()
andsetMinLength(Integer)
to get and set the element. - <registry:maxLength> - An OPTIONAL maximum length of the domain
name label. Use
getMaxLength()
andsetMaxLength(Integer)
to get and set the element. - <registry:alphaNumStart> - An OPTIONAL flag indicating whether the
label must start with an alphanumeric character with a default of "false".
Use
getAlphaNumStart()
andsetAlphaNumStart(Boolean)
to get and set the element. - <registry:alphaNumEnd> - An OPTIONAL flag indicating whether the
label must end with an alphanumeric character with a default value of
"false". Use
getAlphaNumEnd()
andsetAlphaNumEnd(Boolean)
to get and set the element. - <registry:aLabelSupported> - An OPTIONAL flag indicating whether
ASCII domain names are supported with a default value of "true". Use
getALabelSupported()
andsetALabelSupported(Boolean)
to get and set the element. - <registry:uLabelSupported> - An OPTIONAL flag indicating whether
non-ASCII domain names are supported with a default value of "false". Use
getULabelSupported()
andsetULabelSupported(Boolean)
to get and set the element. - <registry:nameRegex> - The OPTIONAL regular expression used to
validate the domain name label. Use
getNameRegex()
andsetNameRegex(EPPRegistryRegex)
to get and set the element. - <registry:reservedNames> - An OPTIONAL element that defines the set
of reserved domain names starting from that label level. The reserved names
can refer to values with more than one level which is relative to the level
of the parent <registry:domainName> element. Use
getReservedNames()
andsetReservedNames(EPPRegistryReservedNames)
to get and set the element.
- See Also:
EPPRegistryDomain
,EPPRegistryReservedNames
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ELM_LOCALNAME
XML local name forEPPRegistryDomainName
.static java.lang.String
ELM_NAME
XML root tag forEPPRegistryDomainName
.
-
Constructor Summary
Constructors Constructor Description EPPRegistryDomainName()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
clone()
CloneEPPRegistryDomainName
.void
decode(org.w3c.dom.Element aElement)
Decode theEPPRegistryDomainName
attributes from the aElement DOM Element tree.org.w3c.dom.Element
encode(org.w3c.dom.Document aDocument)
Encode a DOM Element tree from the attributes of theEPPRegistryDomainName
instance.boolean
equals(java.lang.Object aObject)
implements a deepEPPRegistryDomainName
compare.java.lang.Boolean
getALabelSupported()
Get whether ASCII domain names are supported.java.lang.Boolean
getAlphaNumEnd()
Get whether or not to allow domain name end with an alphanumeric character.java.lang.Boolean
getAlphaNumStart()
Get whether or not to allow domain name start with an alphanumeric character.java.lang.Integer
getLevel()
Get the level of domain name.java.lang.Integer
getMaxLength()
Get maximum number of characters in a domain name.java.lang.Integer
getMinLength()
Get minimum number of characters in a domain name.EPPRegistryRegex
getNameRegex()
Get the regular expression that domain name must follow.java.lang.String
getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.EPPRegistryReservedNames
getReservedNames()
Get the instance ofEPPRegistryReservedNames
that defines a set of reserved domain names.java.lang.Boolean
getULabelSupported()
Get whether non-ASCII domain names are supported.boolean
hasNameRegex()
Is the domain name regular expression defined?void
setALabelSupported(java.lang.Boolean aALabelSupported)
Set whether whether ASCII domain names are supported.void
setAlphaNumEnd(java.lang.Boolean alphaNumEnd)
Set whether or not to allow domain name end with an alphanumeric character.void
setAlphaNumStart(java.lang.Boolean alphaNumStart)
Set whether or not to allow domain name start with an alphanumeric character.void
setLevel(java.lang.Integer level)
Set the level of domain name.void
setMaxLength(java.lang.Integer maxLength)
Set maximum number of characters in a domain name.void
setMinLength(java.lang.Integer minLength)
Set minimum number of characters in a domain name.void
setNameRegex(EPPRegistryRegex aNameRegex)
Set the regular expression that domain name must follow.void
setReservedNames(EPPRegistryReservedNames reservedNames)
Set the instance ofEPPRegistryReservedNames
that defines a set of reserved domain names.void
setULabelSupported(java.lang.Boolean aULabelSupported)
Set whether non-ASCII domain names are supported.java.lang.String
toString()
Implementation ofObject.toString
, which will result in an indented XMLString
representation of the concreteEPPCodecComponent
.
-
-
-
Field Detail
-
ELM_LOCALNAME
public static final java.lang.String ELM_LOCALNAME
XML local name forEPPRegistryDomainName
.- See Also:
- Constant Field Values
-
ELM_NAME
public static final java.lang.String ELM_NAME
XML root tag forEPPRegistryDomainName
.- See Also:
- Constant Field Values
-
-
Method Detail
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeException
Encode a DOM Element tree from the attributes of theEPPRegistryDomainName
instance.- Specified by:
encode
in interfaceEPPCodecComponent
- Parameters:
aDocument
- DOM Document that is being built. Used as an Element factory.- Returns:
- Element Root DOM Element representing the
EPPRegistryDomainName
instance. - Throws:
EPPEncodeException
- - Unable to encodeEPPRegistryDomainName
instance.
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeException
Decode theEPPRegistryDomainName
attributes from the aElement DOM Element tree.- Specified by:
decode
in interfaceEPPCodecComponent
- Parameters:
aElement
- Root DOM Element to decodeEPPRegistryDomainName
from.- Throws:
EPPDecodeException
- Unable to decode aElement
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPRegistryDomainName
compare.- Overrides:
equals
in classjava.lang.Object
- Parameters:
aObject
-EPPRegistryDomainName
instance to compare with- Returns:
true
if this object is the same as the aObject argument;false
otherwise
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
CloneEPPRegistryDomainName
.- Specified by:
clone
in interfaceEPPCodecComponent
- Overrides:
clone
in classjava.lang.Object
- Returns:
- clone of
EPPRegistryDomainName
- Throws:
java.lang.CloneNotSupportedException
- standard Object.clone exception
-
toString
public java.lang.String toString()
Implementation ofObject.toString
, which will result in an indented XMLString
representation of the concreteEPPCodecComponent
.- Overrides:
toString
in classjava.lang.Object
- Returns:
- Indented XML
String
if successful;ERROR
otherwise.
-
getLevel
public java.lang.Integer getLevel()
Get the level of domain name.- Returns:
- level of domain name. Must be >= 2
-
setLevel
public void setLevel(java.lang.Integer level)
Set the level of domain name.- Parameters:
level
- level of domain name. Must be >= 2
-
getMinLength
public java.lang.Integer getMinLength()
Get minimum number of characters in a domain name.- Returns:
- minimum number of characters in a domain name
-
setMinLength
public void setMinLength(java.lang.Integer minLength)
Set minimum number of characters in a domain name.- Parameters:
minLength
- minimum number of characters in a domain name
-
getMaxLength
public java.lang.Integer getMaxLength()
Get maximum number of characters in a domain name.- Returns:
- maximum number of characters in a domain name
-
setMaxLength
public void setMaxLength(java.lang.Integer maxLength)
Set maximum number of characters in a domain name.- Parameters:
maxLength
- maximum number of characters in a domain name
-
getAlphaNumStart
public java.lang.Boolean getAlphaNumStart()
Get whether or not to allow domain name start with an alphanumeric character.- Returns:
true
allow domain name start with an alphanumeric character.false
do not allow domain name start with an alphanumeric character
-
setAlphaNumStart
public void setAlphaNumStart(java.lang.Boolean alphaNumStart)
Set whether or not to allow domain name start with an alphanumeric character.- Parameters:
alphaNumStart
-true
allow domain name start with an alphanumeric character.false
do not allow domain name start with an alphanumeric character
-
getAlphaNumEnd
public java.lang.Boolean getAlphaNumEnd()
Get whether or not to allow domain name end with an alphanumeric character.- Returns:
true
allow domain name end with an alphanumeric character.false
do not allow domain name end with an alphanumeric character
-
setAlphaNumEnd
public void setAlphaNumEnd(java.lang.Boolean alphaNumEnd)
Set whether or not to allow domain name end with an alphanumeric character.- Parameters:
alphaNumEnd
-true
allow domain name end with an alphanumeric character.false
do not allow domain name end with an alphanumeric character
-
getALabelSupported
public java.lang.Boolean getALabelSupported()
Get whether ASCII domain names are supported.- Returns:
true
if ASCII domain names are supported;false
otherwise.
-
setALabelSupported
public void setALabelSupported(java.lang.Boolean aALabelSupported)
Set whether whether ASCII domain names are supported.- Parameters:
aALabelSupported
-true
ASCII domain names are supported;false
otherwise.
-
getULabelSupported
public java.lang.Boolean getULabelSupported()
Get whether non-ASCII domain names are supported.- Returns:
true
if non-ASCII domain names are supported;false
otherwise.
-
setULabelSupported
public void setULabelSupported(java.lang.Boolean aULabelSupported)
Set whether non-ASCII domain names are supported.- Parameters:
aULabelSupported
-true
non-ASCII domain names are supported;false
otherwise.
-
hasNameRegex
public boolean hasNameRegex()
Is the domain name regular expression defined?- Returns:
true
if the domain name regular expression is defined;false
otherwise.
-
getNameRegex
public EPPRegistryRegex getNameRegex()
Get the regular expression that domain name must follow.- Returns:
- Regular expression if defined;
null
otherwise.
-
setNameRegex
public void setNameRegex(EPPRegistryRegex aNameRegex)
Set the regular expression that domain name must follow.- Parameters:
aNameRegex
- Regular expression for the domain name label. Set tonull
to unset it.
-
getReservedNames
public EPPRegistryReservedNames getReservedNames()
Get the instance ofEPPRegistryReservedNames
that defines a set of reserved domain names.- Returns:
- instance of
EPPRegistryReservedNames
-
setReservedNames
public void setReservedNames(EPPRegistryReservedNames reservedNames)
Set the instance ofEPPRegistryReservedNames
that defines a set of reserved domain names.- Parameters:
reservedNames
- instance ofEPPRegistryReservedNames
-
getNamespace
public java.lang.String getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.- Specified by:
getNamespace
in interfaceEPPCodecComponent
- Returns:
- XML namespace for the
EPPCodecComponent
.
-
-