public abstract class EPPProtocolExtension extends java.lang.Object implements EPPMessage
EPPProtocolExtension can be encoded and
decoded by EPPCodec. EPPProtocolExtension and
implement the Template Method Design Pattern doGenEncode and
doGenDecode methods. An EPPProtocolExtension client will call
encode or decode, which in turn will call doGenEncode
or doGenDecode, respectively. There is one derived
EPPProtocolExtension for each type of extension defined in the
general EPP Specification.| Constructor and Description |
|---|
EPPProtocolExtension()
Allocates a new
EPPProtocolExtension with default attribute
values. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Clone
EPPProtocolExtension. |
void |
decode(org.w3c.dom.Element aElement)
decode
EPPProtocolExtension from a DOM element tree. |
protected abstract void |
doDecode(org.w3c.dom.Element aElement)
Decodes the atributes of a general extension of
EPPProtocolExtension. |
protected abstract org.w3c.dom.Element |
doEncode(org.w3c.dom.Document aDocument)
Encodes the atributes of a protocol extension of
EPPProtocolExtension. |
org.w3c.dom.Element |
encode(org.w3c.dom.Document aDocument)
encode
EPPProtocolExtension into a DOM element tree. |
boolean |
equals(java.lang.Object aObject)
implements a deep
EPPProtocolExtension compare. |
abstract java.lang.String |
getNamespace()
Gets the EPP namespace associated with the
EPPProtocolExtension. |
java.lang.String |
toString()
Implementation of
Object.toString, which will result in an
indented XML String representation of the concrete
EPPCodecComponent. |
public EPPProtocolExtension()
EPPProtocolExtension with default attribute
values.public abstract java.lang.String getNamespace()
EPPProtocolExtension.getNamespace in interface EPPCodecComponentgetNamespace in interface EPPMessageEPPProtocolExtension.public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument)
throws EPPEncodeException
EPPProtocolExtension into a DOM element tree. The
<extensiongt; element is created and the attribute nodes are appending
as children. This method is a Template Method in the Template
Method Design Pattern.encode in interface EPPCodecComponentaDocument - DOM Document to create elements fromEPPEncodeException - Error encoding the DOM element tree.public void decode(org.w3c.dom.Element aElement)
throws EPPDecodeException
EPPProtocolExtension from a DOM element tree. The
"extension" element needs to be the value of the aElement
argument. This method is a Template Method in the Template Method
Design Pattern.decode in interface EPPCodecComponentaElement - <extensiongt; root element tree.EPPDecodeException - Error decoding the DOM element tree.public boolean equals(java.lang.Object aObject)
EPPProtocolExtension compare.equals in class java.lang.ObjectaObject - EPPProtocolExtension instance to compare withtrue if equal; false otherwise.public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
EPPProtocolExtension.clone in interface EPPCodecComponentclone in class java.lang.ObjectEPPProtocolExtensionjava.lang.CloneNotSupportedException - standard Object.clone exceptionpublic java.lang.String toString()
Object.toString, which will result in an
indented XML String representation of the concrete
EPPCodecComponent.toString in class java.lang.ObjectString if successful; ERROR
otherwise.protected abstract org.w3c.dom.Element doEncode(org.w3c.dom.Document aDocument)
throws EPPEncodeException
EPPProtocolExtension. An example of a protocol extension is
EPPAlert. encode is a Template Method and this
method is a Primitive Operation within the Template Method Design
Pattern.aDocument - DOM document used as a factory of DOM objects.EPPEncodeException - Error encoding the DOM element tree.protected abstract void doDecode(org.w3c.dom.Element aElement)
throws EPPDecodeException
EPPProtocolExtension. An example of a protocol extension is
EPPAlert. decode is a Template Method and this
method is a Primitive Operation within the Template Method Design
Pattern.aElement - root DOM element associated with instanceEPPDecodeException - Error decoding the DOM element tree.