Package com.verisign.epp.codec.gen
Class EPPMsgQueue
- java.lang.Object
-
- com.verisign.epp.codec.gen.EPPMsgQueue
-
- All Implemented Interfaces:
EPPCodecComponent,java.io.Serializable,java.lang.Cloneable
public class EPPMsgQueue extends java.lang.Object implements EPPCodecComponent
EPPMsgQueuedescribes messages queued for client retrieval. A <msgQ> element MUST NOT be present if there are no messages queued for client retrieval. A <msgQ> element MAY be present in responses to EPP commands other than the <pol> command if messages are queued for retrieval. A <msgQ> element MUST be present in responses to the EPP <poll> command if messages are queued for retrieval. The <msgQ> element contains the following attributes:
- A "count" attribute that describes the number of messages that exist in the queue.
- An "id" attribute used to uniquely identify the message at the head of the queue.
- A <qDate> element that contains the date and time that the message was enqueued.
- A <msg> element containing a human-readable message. The language of the response is identified via an OPTIONAL "lang" attribute. If not specified, the default attribute value MUST be "en" (English). This element MAY contain XML content for formatting purposes, but the XML content is not specified by the protocol and will thus not be processed for validity.
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringDEFAULT_LANGThe default language of the reason "en".
-
Constructor Summary
Constructors Constructor Description EPPMsgQueue()Default constructor required for serialization.EPPMsgQueue(java.lang.Long aCount, java.lang.String aId)Allocates a newEPPMsgQueuewith the required attributes.EPPMsgQueue(java.lang.Long aCount, java.lang.String aId, java.util.Date aQDate, java.lang.String aMsg)Allocates a newEPPMsgQueuewith all of the attributes.EPPMsgQueue(java.lang.Long aCount, java.lang.String aId, java.util.Date aQDate, org.w3c.dom.NodeList aMsgNodeList)Allocates a newEPPMsgQueuewith all of the attributes.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()CloneEPPMsgQueue.voiddecode(org.w3c.dom.Element aElement)decodeEPPMsgQueuefrom a DOM element tree.org.w3c.dom.Elementencode(org.w3c.dom.Document aDocument)encodeEPPMsgQueueinto a DOM element tree.booleanequals(java.lang.Object aObject)implements a deepEPPMsgQueuecompare.java.lang.LonggetCount()Gets the number of messages that exist in the queue.java.lang.StringgetId()Gets the id that uniquely identifies the message at the head of the queue.java.lang.StringgetLang()Gets the message language.java.lang.StringgetMsg()Gets the optional human-readable message.org.w3c.dom.NodeListgetMsgNodeList()Gets the message DOMNodeListrepresenting mixed XML content for the message.java.lang.StringgetNamespace()Returns the XML namespace associated with theEPPCodecComponent.java.util.DategetQDate()Gets the optional date and time that the message was enqueued.voidsetCount(java.lang.Long aCount)Sets the number of messages that exist in the queue.voidsetId(java.lang.String aId)Gets the id that uniquely identifies the message at the head of the queue.voidsetLang(java.lang.String aLang)Sets the message language.voidsetMsg(java.lang.String aMsg)Sets the optional human-readable message.voidsetMsgNodeList(org.w3c.dom.NodeList aMsgNodeList)Sets the message DOMNodeListrepresenting mixed XML content for the message.voidsetQDate(java.util.Date aDate)Sets the optional date and time that the message was enqueued.java.lang.StringtoString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.
-
-
-
Field Detail
-
DEFAULT_LANG
public static final java.lang.String DEFAULT_LANG
The default language of the reason "en".- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EPPMsgQueue
public EPPMsgQueue()
Default constructor required for serialization. Thecountandidattributes must be set before callingencode.
-
EPPMsgQueue
public EPPMsgQueue(java.lang.Long aCount, java.lang.String aId)Allocates a newEPPMsgQueuewith the required attributes. The optional attributes are initialized tonull.- Parameters:
aCount- The number of messages that exist in the queueaId- uniquely identify the message at the head of the queue
-
EPPMsgQueue
public EPPMsgQueue(java.lang.Long aCount, java.lang.String aId, java.util.Date aQDate, java.lang.String aMsg)Allocates a newEPPMsgQueuewith all of the attributes.- Parameters:
aCount- The number of messages that exist in the queueaId- uniquely identify the message at the head of the queueaQDate- date and time that the message was enqueuedaMsg- human-readable message. The language defaults toDEFAULT_LANG, but can be set withsetLang(String).
-
EPPMsgQueue
public EPPMsgQueue(java.lang.Long aCount, java.lang.String aId, java.util.Date aQDate, org.w3c.dom.NodeList aMsgNodeList)Allocates a newEPPMsgQueuewith all of the attributes.- Parameters:
aCount- The number of messages that exist in the queueaId- uniquely identify the message at the head of the queueaQDate- date and time that the message was enqueuedaMsgNodeList- Mixed XML content for the message.
-
-
Method Detail
-
getCount
public java.lang.Long getCount()
Gets the number of messages that exist in the queue.- Returns:
- Number of messages in the queue
-
setCount
public void setCount(java.lang.Long aCount)
Sets the number of messages that exist in the queue.- Parameters:
aCount- Number of messages in the queue
-
getId
public java.lang.String getId()
Gets the id that uniquely identifies the message at the head of the queue.- Returns:
- id for message
-
setId
public void setId(java.lang.String aId)
Gets the id that uniquely identifies the message at the head of the queue.- Parameters:
aId- Message id
-
getQDate
public java.util.Date getQDate()
Gets the optional date and time that the message was enqueued.- Returns:
- Date and time that the message was enqueued if defined;
nullotherwise.
-
setQDate
public void setQDate(java.util.Date aDate)
Sets the optional date and time that the message was enqueued.- Parameters:
aDate- The date and time that the message was enqueued
-
getLang
public java.lang.String getLang()
Gets the message language. The Language must be structured as documented in [RFC1766].- Returns:
- Language of the message, with the default of
DEFAULT_LANG.
-
setLang
public void setLang(java.lang.String aLang)
Sets the message language. The Language must be structured as documented in [RFC1766].- Parameters:
aLang- Language of the message.
-
getMsg
public java.lang.String getMsg()
Gets the optional human-readable message. The language defaults toDEFAULT_LANG, but the value can be retrieved with thegetLang()method.- Returns:
- the human-readable message if defined;
nullotherwise.
-
setMsg
public void setMsg(java.lang.String aMsg)
Sets the optional human-readable message. The language defaults toDEFAULT_LANG, but can be set with thesetLang(String)method.- Parameters:
aMsg- human-readable message
-
getMsgNodeList
public org.w3c.dom.NodeList getMsgNodeList()
Gets the message DOMNodeListrepresenting mixed XML content for the message. This is an alternative to using a simpleStringfor the message.- Returns:
- Message
NodeListif defined;nullotherwise
-
setMsgNodeList
public void setMsgNodeList(org.w3c.dom.NodeList aMsgNodeList)
Sets the message DOMNodeListrepresenting mixed XML content for the message. This is an alternative to using a simpleStringfor the message.- Parameters:
aMsgNodeList-NodeListcontaining mixed XML content
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeExceptionencodeEPPMsgQueueinto a DOM element tree.- Specified by:
encodein interfaceEPPCodecComponent- Parameters:
aDocument- Factory for DOM components- Returns:
- <extValue> root element tree.
- Throws:
EPPEncodeException- Error encoding the DOM element tree.
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeExceptiondecodeEPPMsgQueuefrom a DOM element tree. TheaElementargument needs to be the "extValue" element.- Specified by:
decodein interfaceEPPCodecComponent- Parameters:
aElement- The "extValue" XML element.- Throws:
EPPDecodeException- Error decoding the DOM element tree.
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPMsgQueuecompare.- Overrides:
equalsin classjava.lang.Object- Parameters:
aObject-EPPMsgQueueinstance to compare with- Returns:
trueif equal;falseotherwise
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedExceptionCloneEPPMsgQueue.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classjava.lang.Object- Returns:
- Deep copy clone of
EPPMsgQueue - Throws:
java.lang.CloneNotSupportedException- standard Object.clone exception
-
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.
-
-