Class EPPRegistryDomainContact
java.lang.Object
com.verisign.epp.codec.registry.v02.EPPRegistryAbstractMinMax
com.verisign.epp.codec.registry.v02.EPPRegistryDomainContact
- All Implemented Interfaces:
EPPCodecComponent,Serializable,Cloneable
Defines the miniumum and maximum numbers of contacts by contact type. The
contact type is defined with the required "type" attribute with the possible
values of "admin", "tech", and "billing". The <registry:contact>
element contains the following child elements
- <registry:min> - The minimum number of contacts for the contact
type. Use
EPPRegistryAbstractMinMax.getMin()andEPPRegistryAbstractMinMax.setMin(Integer)to get and set this element. - <registry:max> - The OPTIONAL maximum number of contacts for the
contact type. If this element is not defined, the maximum number is
unbounded. Use
EPPRegistryAbstractMinMax.getMax()andEPPRegistryAbstractMinMax.setMax(Integer)to get and set this element.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumPossible values for thesharePolicyattribute. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringXML attribute name for thetypeattribute.static final StringXML local name forEPPRegistryDomainContact.static final StringXML root tag forEPPRegistryDomainContact.Fields inherited from class com.verisign.epp.codec.registry.v02.EPPRegistryAbstractMinMax
ELM_MAX, ELM_MAX_LENGTH, ELM_MIN, ELM_MIN_LENGTH -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor ofEPPRegistryDomainContact.EPPRegistryDomainContact(EPPRegistryDomainContact.Type aType, int aMin, int aMax) Creates a newEPPRegistryDomainContactobject that takes the types and both the minimum and maximum values asint's.EPPRegistryDomainContact(EPPRegistryDomainContact.Type aType, Integer aMin, Integer aMax) Creates a newEPPRegistryDomainContactobject that takes the types and both the minimum and maximum values asInteger's. -
Method Summary
Modifier and TypeMethodDescriptionclone()CloneEPPRegistryDomainContact.voidDecode theEPPRegistryDomainContactattributes from the aElement DOM Element tree.Encode a DOM Element tree from the attributes of theEPPRegistryDomainContactinstance.booleanimplements a deepEPPRegistryDomainContactcompare.protected StringGets the maximum element local name.protected StringGets the minimum element local name.protected org.slf4j.LoggerGets theLoggerto use.protected StringGets the root element local name.getType()Gets the type of contact.voidSets the type of contact.toString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.protected voidValidate the state of theEPPRegistryDomainContactinstance.Methods inherited from class com.verisign.epp.codec.registry.v02.EPPRegistryAbstractMinMax
getMax, getMin, getNamespace, setMax, setMin
-
Field Details
-
ELM_LOCALNAME
XML local name forEPPRegistryDomainContact.- See Also:
-
ELM_NAME
XML root tag forEPPRegistryDomainContact.- See Also:
-
ATTR_TYPE
XML attribute name for thetypeattribute.- See Also:
-
-
Constructor Details
-
EPPRegistryDomainContact
public EPPRegistryDomainContact()Default constructor ofEPPRegistryDomainContact. All attributes are set to null. Must callsetType(EPPRegistryDomainContact.Type)andEPPRegistryAbstractMinMax.setMin(Integer)before callingencode(Document). -
EPPRegistryDomainContact
Creates a newEPPRegistryDomainContactobject that takes the types and both the minimum and maximum values asInteger's.- Parameters:
aType- type of contactaMin- minimum number of contact entries.aMax- maximum number of contact entries.
-
EPPRegistryDomainContact
Creates a newEPPRegistryDomainContactobject that takes the types and both the minimum and maximum values asint's.- Parameters:
aType- type of contactaMin- minimum number of contact entries.aMax- maximum number of contact entries.
-
-
Method Details
-
encode
Encode a DOM Element tree from the attributes of theEPPRegistryDomainContactinstance.- Specified by:
encodein interfaceEPPCodecComponent- Overrides:
encodein classEPPRegistryAbstractMinMax- Parameters:
aDocument- DOM Document that is being built. Used as an Element factory.- Returns:
- Element Root DOM Element representing the
EPPRegistryDomainContactinstance. - Throws:
EPPEncodeException- - Unable to encodeEPPRegistryDomainContactinstance.
-
decode
Decode theEPPRegistryDomainContactattributes from the aElement DOM Element tree.- Specified by:
decodein interfaceEPPCodecComponent- Overrides:
decodein classEPPRegistryAbstractMinMax- Parameters:
aElement- Root DOM Element to decodeEPPRegistryDomainContactfrom.- Throws:
EPPDecodeException- Unable to decode aElement
-
clone
CloneEPPRegistryDomainContact.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classEPPRegistryAbstractMinMax- Returns:
- clone of
EPPRegistryDomainContact - Throws:
CloneNotSupportedException- standard Object.clone exception
-
equals
implements a deepEPPRegistryDomainContactcompare.- Overrides:
equalsin classEPPRegistryAbstractMinMax- Parameters:
aObject-EPPRegistryDomainContactinstance to compare with- Returns:
trueif this object is the same as the aObject argument;falseotherwise
-
toString
Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.- Overrides:
toStringin classEPPRegistryAbstractMinMax- Returns:
- Indented XML
Stringif successful;ERRORotherwise.
-
getType
Gets the type of contact.- Returns:
- Type of contact if defined;
nullotherwise.
-
setType
Sets the type of contact.- Parameters:
aType- The type of contact
-
getRootName
Gets the root element local name.- Specified by:
getRootNamein classEPPRegistryAbstractMinMax- Returns:
- Root element local name.
-
getElmMin
Gets the minimum element local name.- Specified by:
getElmMinin classEPPRegistryAbstractMinMax- Returns:
- Minimum element local name.
-
getElmMax
Gets the maximum element local name.- Specified by:
getElmMaxin classEPPRegistryAbstractMinMax- Returns:
- Maximum element local name.
-
getLogger
protected org.slf4j.Logger getLogger()Gets theLoggerto use.- Specified by:
getLoggerin classEPPRegistryAbstractMinMax- Returns:
Loggerinstance to use for logging.
-
validateState
Validate the state of theEPPRegistryDomainContactinstance. A valid state means that all of the required attributes have been set. If validateState returns without an exception, the state is valid. If the state is not valid, theEPPCodecExceptionwill contain a description of the error.- Overrides:
validateStatein classEPPRegistryAbstractMinMax- Throws:
EPPEncodeException- Validation error
-