Package com.verisign.epp.codec.ttl.v1_0
Class EPPTtl
- java.lang.Object
-
- com.verisign.epp.codec.ttl.v1_0.EPPTtl
-
- All Implemented Interfaces:
EPPCodecComponent,java.io.Serializable,java.lang.Cloneable
public class EPPTtl extends java.lang.Object implements EPPCodecComponent
EPPTtlis used to define TTL values for the DNS resource records associated with domain and host objects.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringELM_LOCALNAMEConstant for the phase local namestatic java.lang.StringELM_NAMEConstant for the phase qualified name (prefix and local name)
-
Constructor Summary
Constructors Constructor Description EPPTtl()Default constructor.EPPTtl(RRecType aRRecType)CreateEPPTtlinstance with the TTL resource record type and with anullTTL value.EPPTtl(RRecType aRRecType, java.lang.Integer aValue)CreateEPPTtlinstance with the TTL resource record type and the TTL value.EPPTtl(RRecType aRRecType, java.lang.String aCustom)CreateEPPTtlinstance with a custom TTL resource record type and with anullTTL value.EPPTtl(RRecType aRRecType, java.lang.String aCustom, java.lang.Integer aValue)CreateEPPTtlinstance with a custom TTL resource record type and the TTL value.EPPTtl(RRecType aRRecType, java.lang.String aCustom, java.lang.Integer aMinValue, java.lang.Integer aMaxValue, java.lang.Integer aDefaultValue, java.lang.Integer aValue)CreateEPPTtlinstance with all of the attributes.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()CloneEPPTtlinstance.voiddecode(org.w3c.dom.Element aElement)Decode theEPPTtlelement aElement DOM Element tree.org.w3c.dom.Elementencode(org.w3c.dom.Document aDocument)Encode a DOM Element tree from the attributes of theEPPTtlinstance.booleanequals(java.lang.Object aObject)implements a deepEPPTtlcompare.java.lang.StringgetCustom()Gets the custom resource record type attribute value.java.lang.IntegergetDefaultValue()Gets the default TTL value.java.lang.IntegergetMaxValue()Gets the max TTL value.java.lang.IntegergetMinValue()Gets the min TTL value.java.lang.StringgetNamespace()Returns the XML namespace associated with theEPPCodecComponent.RRecTypegetRRecType()Gets the resource record type.java.lang.IntegergetValue()Gets the TTL value.booleanhasCustom()Is the custom resource record type attribute defined?booleanhasDefaultValue()Is the default TTL value defined?booleanhasMaxValue()Is the max TTL value defined?booleanhasMinValue()Is the min TTL value defined?booleanhasPolicyValues()Are all the policy TTL values (minValue,maxValue,defaultValue) defined?booleanhasValue()Is the TTL value defined?voidsetCustom(java.lang.String aCustom)Sets the custom resource record type attribute value.voidsetDefaultValue(java.lang.Integer aDefaultValue)Sets the TTL default value.voidsetMaxValue(java.lang.Integer aMaxValue)Sets the TTL max value.voidsetMinValue(java.lang.Integer aMinValue)Sets the TTL min value.voidsetPolicyValues(java.lang.Integer aMinValue, java.lang.Integer aMaxValue, java.lang.Integer aDefaultValue)Sets the policy TTL values (minValue,maxValue,defaultValue).voidsetRRecType(RRecType aRRecType)Sets resource record type.voidsetValue(java.lang.Integer aValue)Sets the TTL value.java.lang.StringtoString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.voidunsetPolicyValues()Unsets the policy TTL values (minValue,maxValue,defaultValue).
-
-
-
Field Detail
-
ELM_LOCALNAME
public static final java.lang.String ELM_LOCALNAME
Constant for the phase local name- See Also:
- Constant Field Values
-
ELM_NAME
public static final java.lang.String ELM_NAME
Constant for the phase qualified name (prefix and local name)- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EPPTtl
public EPPTtl()
Default constructor. By default the value isnull, which will unset the TTL setting.
-
EPPTtl
public EPPTtl(RRecType aRRecType)
CreateEPPTtlinstance with the TTL resource record type and with anullTTL value.- Parameters:
aRRecType- Required resource record type
-
EPPTtl
public EPPTtl(RRecType aRRecType, java.lang.String aCustom)
CreateEPPTtlinstance with a custom TTL resource record type and with anullTTL value.- Parameters:
aRRecType- Required resource record typeaCustom- Custom resource record type
-
EPPTtl
public EPPTtl(RRecType aRRecType, java.lang.Integer aValue)
CreateEPPTtlinstance with the TTL resource record type and the TTL value.- Parameters:
aRRecType- Required resource record typeaValue- The TTL value. Set tonullto unset the explicit TTL value.
-
EPPTtl
public EPPTtl(RRecType aRRecType, java.lang.String aCustom, java.lang.Integer aValue)
CreateEPPTtlinstance with a custom TTL resource record type and the TTL value.- Parameters:
aRRecType- Required resource record typeaCustom- Custom resource record typeaValue- The TTL value. Set tonullto unset the explicit TTL value.
-
EPPTtl
public EPPTtl(RRecType aRRecType, java.lang.String aCustom, java.lang.Integer aMinValue, java.lang.Integer aMaxValue, java.lang.Integer aDefaultValue, java.lang.Integer aValue)
CreateEPPTtlinstance with all of the attributes.- Parameters:
aRRecType- Required resource record typeaCustom- Custom resource record type. Usenullif undefined.aMinValue- Min TTL value. Usenullif undefined.aMaxValue- Max TTL value. Usenullif undefined.aDefaultValue- Default TTL value. Usenullif undefined.aValue- The ttl value. Set tonullto unset the explicit TTL value.
-
-
Method Detail
-
getRRecType
public RRecType getRRecType()
Gets the resource record type.- Returns:
- Resource record type if defined;
nullotherwise.
-
setRRecType
public void setRRecType(RRecType aRRecType)
Sets resource record type.- Parameters:
aRRecType- Sets resource record type
-
hasCustom
public boolean hasCustom()
Is the custom resource record type attribute defined?- Returns:
trueif the custom resource record type attribute is defined;falseotherwise.
-
getCustom
public java.lang.String getCustom()
Gets the custom resource record type attribute value.- Returns:
- Custom resource record type attribute if defined;
nullotherwise.
-
setCustom
public void setCustom(java.lang.String aCustom)
Sets the custom resource record type attribute value.- Parameters:
aCustom- Custom resource record type value. Unset withnull.
-
hasMinValue
public boolean hasMinValue()
Is the min TTL value defined?- Returns:
trueif the min TTL value is defined;falseotherwise.
-
getMinValue
public java.lang.Integer getMinValue()
Gets the min TTL value.- Returns:
- Min TTL value if defined;
nullotherwise.
-
setMinValue
public void setMinValue(java.lang.Integer aMinValue)
Sets the TTL min value.- Parameters:
aMinValue- Min TTL value. Unset withnull.
-
hasMaxValue
public boolean hasMaxValue()
Is the max TTL value defined?- Returns:
trueif the max TTL value is defined;falseotherwise.
-
getMaxValue
public java.lang.Integer getMaxValue()
Gets the max TTL value.- Returns:
- Max TTL value if defined;
nullotherwise.
-
setMaxValue
public void setMaxValue(java.lang.Integer aMaxValue)
Sets the TTL max value.- Parameters:
aMaxValue- Max TTL value. Unset withnull.
-
hasDefaultValue
public boolean hasDefaultValue()
Is the default TTL value defined?- Returns:
trueif the default TTL value is defined;falseotherwise.
-
getDefaultValue
public java.lang.Integer getDefaultValue()
Gets the default TTL value.- Returns:
- Default TTL value if defined;
nullotherwise.
-
setDefaultValue
public void setDefaultValue(java.lang.Integer aDefaultValue)
Sets the TTL default value.- Parameters:
aDefaultValue- Default TTL value. Unset withnull.
-
hasPolicyValues
public boolean hasPolicyValues()
Are all the policy TTL values (minValue,maxValue,defaultValue) defined?- Returns:
trueif all of the policy TTL values are defined;falseotherwise.
-
setPolicyValues
public void setPolicyValues(java.lang.Integer aMinValue, java.lang.Integer aMaxValue, java.lang.Integer aDefaultValue)Sets the policy TTL values (minValue,maxValue,defaultValue).- Parameters:
aMinValue- Min TTL value. Usenullif undefined.aMaxValue- Max TTL value. Usenullif undefined.aDefaultValue- Default TTL value. Usenullif undefined.
-
unsetPolicyValues
public void unsetPolicyValues()
Unsets the policy TTL values (minValue,maxValue,defaultValue).
-
hasValue
public boolean hasValue()
Is the TTL value defined?- Returns:
trueif the TTL value is defined;falseotherwise.
-
getValue
public java.lang.Integer getValue()
Gets the TTL value.- Returns:
- TTL value if defined;
nullotherwise.
-
setValue
public void setValue(java.lang.Integer aValue)
Sets the TTL value.- Parameters:
aValue- TTL value. Unset withnull.
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedExceptionCloneEPPTtlinstance.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classjava.lang.Object- Returns:
- clone of
EPPTtl - Throws:
java.lang.CloneNotSupportedException- standard Object.clone exception
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeExceptionDecode theEPPTtlelement aElement DOM Element tree.- Specified by:
decodein interfaceEPPCodecComponent- Parameters:
aElement- - Root DOM Element to decodeEPPTtlfrom.- Throws:
EPPDecodeException- Unable to decode aElement
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeExceptionEncode a DOM Element tree from the attributes of theEPPTtlinstance.- Specified by:
encodein interfaceEPPCodecComponent- Parameters:
aDocument- - DOM Document that is being built. Used as an Element factory.- Returns:
- Element - Root DOM Element representing the
EPPTtlinstance. - Throws:
EPPEncodeException- - Unable to encodeEPPTtlinstance.
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPTtlcompare.- Overrides:
equalsin classjava.lang.Object- Parameters:
aObject-EPPTtlinstance to compare with- Returns:
trueif equal;falseotherwise
-
toString
public java.lang.String toString()
Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.- Overrides:
toStringin classjava.lang.Object- Returns:
- Indented XML
Stringif successful;ERRORotherwise.
-
getNamespace
public java.lang.String getNamespace()
Returns the XML namespace associated with theEPPCodecComponent.- Specified by:
getNamespacein interfaceEPPCodecComponent- Returns:
- XML namespace for the
EPPCodecComponent.
-
-