Class EPPMaintenanceDescription
java.lang.Object
com.verisign.epp.codec.maintenance.v1_0.EPPMaintenanceDescription
- All Implemented Interfaces:
EPPCodecComponent,Serializable,Cloneable
EPPMaintenanceDescription is a free-form descriptions of the
maintenance without having to create and traverse an external resource
defined by the <maint:detail> element. The OPTIONAL "lang" attribute
MAY be present to identify the language if the negotiated value is something
other then the default value of "en" (English). The OPTIONAL "type" attribute
MAY be present to identify the format of the description. It MUST either be
"plain" for plain text or "html" HTML text that is defined in [W3C-HTML5] and
XML-escaped, with a default value of "plain".- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumDescription type enumerated values. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor forEPPMaintenanceDescription.EPPMaintenanceDescription(String aDescription) Constructor forEPPMaintenanceDescriptionwith the required attribute as a parameter.EPPMaintenanceDescription(String aDescription, EPPMaintenanceDescription.Type aType, String aLang) Constructor forEPPMaintenanceDescriptionwith all of the attributes as parameters. -
Method Summary
Modifier and TypeMethodDescriptionclone()CloneEPPMaintenanceDescription.voidDecode theEPPMaintenanceDescriptionattributes from the aElement DOM Element tree.Encode a DOM Element tree from the attributes of theEPPMaintenanceDescriptioninstance.booleanimplements a deepEPPMaintenanceDescriptioncompare.Gets the free-form description of the maintenance without having to create an external resource.getLang()Gets the description language value.Returns the XML namespace associated with theEPPCodecComponent.getType()Gets the description type value.booleanhasLang()Is the description language defined with a non-default value?voidsetDescription(String aDescription) Sets the free-form description of the maintenance without having to create an external resource.voidSets the description language value.voidSets the description type value.toString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.
-
Field Details
-
DEFAULT_LANG
Default language- See Also:
-
ELM_LOCALNAME
XML local name forEPPMaintenanceDescription.- See Also:
-
ELM_NAME
XML root tag forEPPMaintenance.- See Also:
-
-
Constructor Details
-
EPPMaintenanceDescription
public EPPMaintenanceDescription()Default constructor forEPPMaintenanceDescription. The required attributes need to be set. Thetypeattribute defaults toEPPMaintenanceDescription.Type.plainand thelangattribute defaults toDEFAULT_LANG. -
EPPMaintenanceDescription
Constructor forEPPMaintenanceDescriptionwith the required attribute as a parameter.- Parameters:
aDescription- Description value
-
EPPMaintenanceDescription
public EPPMaintenanceDescription(String aDescription, EPPMaintenanceDescription.Type aType, String aLang) Constructor forEPPMaintenanceDescriptionwith all of the attributes as parameters.- Parameters:
aDescription- Description valueaType- Type of the descriptionaLang- Language of the description
-
-
Method Details
-
getDescription
Gets the free-form description of the maintenance without having to create an external resource.- Returns:
- The free-form description of the maintenance if defined;
nullotherwise.
-
setDescription
Sets the free-form description of the maintenance without having to create an external resource.- Parameters:
aDescription- Free-form description of the maintenance without having to create an external resource.
-
hasLang
public boolean hasLang()Is the description language defined with a non-default value?- Returns:
trueif the description language is defined;falseotherwise.
-
getLang
Gets the description language value.- Returns:
- Description language if defined;
DEFAULT_LANGotherwise.
-
setLang
Sets the description language value.- Parameters:
aLang- Description language for value.
-
getType
Gets the description type value.- Returns:
- Description type with a default value of
EPPMaintenanceDescription.Type.plain.
-
setType
Sets the description type value.- Parameters:
aType- Description type value.
-
encode
Encode a DOM Element tree from the attributes of theEPPMaintenanceDescriptioninstance.- Specified by:
encodein interfaceEPPCodecComponent- Parameters:
aDocument- DOM Document that is being built. Used as an Element factory.- Returns:
- Root DOM Element representing the
EPPMaintenanceDescriptioninstance. - Throws:
EPPEncodeException- Unable to encodeEPPMaintenanceDescriptioninstance.
-
decode
Decode theEPPMaintenanceDescriptionattributes from the aElement DOM Element tree.- Specified by:
decodein interfaceEPPCodecComponent- Parameters:
aElement- Root DOM Element to decodeEPPMaintenanceDescriptionfrom.- Throws:
EPPDecodeException- Unable to decode aElement.
-
equals
implements a deepEPPMaintenanceDescriptioncompare. -
clone
CloneEPPMaintenanceDescription.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classObject- Returns:
- clone of
EPPMaintenanceDescription - Throws:
CloneNotSupportedException- standard Object.clone exception
-
toString
Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent. -
getNamespace
Returns the XML namespace associated with theEPPCodecComponent.- Specified by:
getNamespacein interfaceEPPCodecComponent- Returns:
- XML namespace for the
EPPCodecComponent.
-