Class EPPRegistryGracePeriod
java.lang.Object
com.verisign.epp.codec.registry.v02.EPPRegistryPeriodType
com.verisign.epp.codec.registry.v02.EPPRegistryGracePeriod
- All Implemented Interfaces:
EPPCodecComponent,Serializable,Cloneable
Defines the grace periods by operation type. The required "command" attribute
defines the operation type with the sample values of "create", "renew",
"transfer", and "autoRenew". The <registry:gracePeriod> element
requires the "unit" attribute with the possible values of "d" for day, "h"
for hour, and "m" for minute.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.verisign.epp.codec.registry.v02.EPPRegistryPeriodType
EPPRegistryPeriodType.Unit -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringXML attribute name for thecommandattribute.protected StringEPP transform command to which this period appliesstatic final StringXML local name forEPPRegistryGracePeriod.Fields inherited from class com.verisign.epp.codec.registry.v02.EPPRegistryPeriodType
ATTR_UNIT, number, unit -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.EPPRegistryGracePeriod(String command, int number, EPPRegistryPeriodType.Unit unit) Constructs an instance ofEPPRegistryGracePeriodwithcommand,numberandunit.EPPRegistryGracePeriod(String aCommand, Integer aNumber, EPPRegistryPeriodType.Unit aUnit) Constructs an instance ofEPPRegistryGracePeriodwithcommand,numberandunit. -
Method Summary
Modifier and TypeMethodDescriptionvoidDecode theEPPRegistryGracePeriodattributes from the aElement DOM Element tree.Encode a DOM Element tree from the attributes of theEPPRegistryGracePeriodinstance.booleanimplements a deepEPPRegistryGracePeriodcompare.Get the EPP transform command to which this period applies.Returns the XML namespace associated with theEPPCodecComponent.protected StringGets the root element local name.voidsetCommand(String command) Set the EPP transform command to which this period applies.
-
Field Details
-
ELM_LOCALNAME
XML local name forEPPRegistryGracePeriod.- See Also:
-
ATTR_COMMAND
XML attribute name for thecommandattribute.- See Also:
-
command
EPP transform command to which this period applies
-
-
Constructor Details
-
EPPRegistryGracePeriod
public EPPRegistryGracePeriod()Default constructor. Must callEPPRegistryPeriodType.setNumber(Integer),EPPRegistryPeriodType.setUnit(EPPRegistryPeriodType.Unit)andsetCommand(String)before callingencode(Document)method. -
EPPRegistryGracePeriod
Constructs an instance ofEPPRegistryGracePeriodwithcommand,numberandunit.- Parameters:
aCommand- EPP command to which this period appliesaNumber- number must be > 0aUnit- unit must be one ofUnit.d,Unit.h, orUnit.m.
-
EPPRegistryGracePeriod
Constructs an instance ofEPPRegistryGracePeriodwithcommand,numberandunit.- Parameters:
command- EPP command to which this period appliesnumber- number must be > 0unit- unit must be one ofUnit.d,Unit.h, orUnit.m.
-
-
Method Details
-
encode
Encode a DOM Element tree from the attributes of theEPPRegistryGracePeriodinstance.- Specified by:
encodein interfaceEPPCodecComponent- Overrides:
encodein classEPPRegistryPeriodType- Parameters:
aDocument- DOM Document that is being built. Used as an Element factory.- Returns:
- Element Root DOM Element representing the
EPPRegistryGracePeriodinstance. - Throws:
EPPEncodeException- - Unable to encodeEPPRegistryGracePeriodinstance.
-
decode
Decode theEPPRegistryGracePeriodattributes from the aElement DOM Element tree.- Specified by:
decodein interfaceEPPCodecComponent- Overrides:
decodein classEPPRegistryPeriodType- Parameters:
aElement- Root DOM Element to decodeEPPRegistryGracePeriodfrom.- Throws:
EPPDecodeException- Unable to decode aElement
-
equals
implements a deepEPPRegistryGracePeriodcompare.- Overrides:
equalsin classEPPRegistryPeriodType- Parameters:
aObject-EPPRegistryGracePeriodinstance to compare with- Returns:
trueif this object is the same as the aObject argument;falseotherwise
-
getCommand
Get the EPP transform command to which this period applies.- Returns:
- EPP transform command to which this period applies
-
setCommand
Set the EPP transform command to which this period applies.- Parameters:
command- EPP transform command to which this period applies
-
getNamespace
Returns the XML namespace associated with theEPPCodecComponent.- Returns:
- XML namespace for the
EPPCodecComponent.
-
getRootName
Gets the root element local name.- Overrides:
getRootNamein classEPPRegistryPeriodType- Returns:
- Root element local name.
-