Package com.verisign.epp.codec.contact
Class EPPContactAddChange
- java.lang.Object
-
- com.verisign.epp.codec.contact.EPPContactAddChange
-
- All Implemented Interfaces:
EPPCodecComponent
,java.io.Serializable
,java.lang.Cloneable
public class EPPContactAddChange extends java.lang.Object implements EPPCodecComponent
Represents attributes to add, remove or change with aEPPContactUpdateCmd
. InEPPContactUpdateCmd
, an instance ofEPPContactAddRemove
is used to specify the attributes to add, an instance ofEPPContactAddRemove
is used to specify the attributes to remove and an instance ofEPPContactAddRemove
is used o specify the attributes to change.
The <contact:add> and <contact:rem> elements SHALL contain the following child elements:
- One or more <contact:status> elements that contain status values to be associated with or removed from the object. When specifying a value to be removed, only the attribute value is significant; element text is not required to match a value for removal.
A <contact:chg> element SHALL contain the following OPTIONAL child elements:
- A <contact:postalInfo> element that contains the postal contacts.
Use
getPostalInfo
,addPostalInfo
andsetPostalInfo
to get, add and set the elements. - An <contact:voice> element that contains the contact's voice
telephone number. Use
getVoice
andsetVoice
to get and set the elements. - An <contact:fax> element that contains the contact's facsimile
telephone number. Use
getFax
andsetFax
to get and set the elements. - A <contact:email> element that contains the contact's e-mail
address. Use
getEmail
andsetEmail
to get and set the elements.
- See Also:
EPPContactUpdateCmd
,EPPContactAddress
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description EPPContactAddChange()
Default constructor forEPPContactAddChange
.EPPContactAddChange(EPPContactPostalDefinition aPostalInfo, java.lang.String aVoice, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.EPPContactAddChange(EPPContactPostalDefinition aPostalInfo, java.lang.String aVoice, java.lang.String aFax, java.lang.String aEmail, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.EPPContactAddChange(java.util.Vector newStatuses)
Constructor forEPPContactAddChange
.EPPContactAddChange(java.util.Vector aPostalInfo, java.lang.String aVoice, java.lang.String aFax, java.lang.String aEmail, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addPostalInfo(EPPContactPostalDefinition aPostalInfo)
Adds contact postalInfo.java.lang.Object
clone()
CloneEPPContactAddChange
.void
decode(org.w3c.dom.Element aElement)
Decode theEPPContactAddChange
attributes from theaElement
DOM Element tree.org.w3c.dom.Element
encode(org.w3c.dom.Document aDocument)
Encode a DOM Element tree from the attributes of theEPPContactAddChange
instance.boolean
equals(java.lang.Object aObject)
implements a deepEPPContactAddChange
compare.EPPAuthInfo
getAuthInfo()
Get authorization information for contact change.EPPContactDisclose
getDisclose()
Get disclose information.java.lang.String
getEmail()
Gets email.java.lang.String
getFax()
Get fax number.java.lang.String
getFaxExt()
Gets the fax extension.java.lang.String
getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.java.util.Vector
getPostalInfo()
Gets the postalInfo elements of contact change.java.util.Vector
getStatuses()
Get a list of contact statuses.java.lang.String
getVoice()
Get voice number.java.lang.String
getVoiceExt()
Get voice number extension.boolean
hasAuthInfo()
Returnstrue
if auth info exists.boolean
hasDisclose()
Returnstrue
if disclose exists.boolean
hasEmail()
Returnstrue
if email exists.boolean
hasFax()
Returnstrue
if fax exists.boolean
hasFaxExt()
Returnstrue
if fax extension exists.boolean
hasStatuses()
Returnstrue
if statuses exist.boolean
hasVoice()
Returnstrue
if voice exists.boolean
hasVoiceExt()
Returnstrue
if voice extension exists.void
setAuthInfo(EPPAuthInfo aAuthInfo)
Set authorization information for contact change.void
setDisclose(EPPContactDisclose aDisclose)
Sets the disclose information.void
setEmail(java.lang.String aEmail)
Sets the email.void
setFax(java.lang.String aFax)
Sets the fax number.void
setFaxExt(java.lang.String aFaxExt)
Sets the fax extension.void
setPostalInfo(java.util.Vector aPostalContacts)
Sets list of contact postal information.void
setStatuses(java.util.Vector aStatuses)
Sets the list of contact statuses.void
setVoice(java.lang.String aVoice)
Sets the voice number.void
setVoiceExt(java.lang.String aVoiceExt)
Sets the contact voice extension.java.lang.String
toString()
Implementation ofObject.toString
, which will result in an indented XMLString
representation of the concreteEPPCodecComponent
.
-
-
-
Constructor Detail
-
EPPContactAddChange
public EPPContactAddChange()
Default constructor forEPPContactAddChange
.
-
EPPContactAddChange
public EPPContactAddChange(java.util.Vector newStatuses)
Constructor forEPPContactAddChange
.- Parameters:
newStatuses
- Vector of statuses for contact add.
-
EPPContactAddChange
public EPPContactAddChange(EPPContactPostalDefinition aPostalInfo, java.lang.String aVoice, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.- Parameters:
aPostalInfo
- EPPContactPostalDefinition, defining a series objects for contact changes.aVoice
- Voice numberaAuthInfo
- Authorization information for contact change.
-
EPPContactAddChange
public EPPContactAddChange(EPPContactPostalDefinition aPostalInfo, java.lang.String aVoice, java.lang.String aFax, java.lang.String aEmail, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.- Parameters:
aPostalInfo
- EPPContactPostalDefinition, defining a series objects for contact changes.aVoice
- Voice numberaFax
- Fax numberaEmail
- EmailaAuthInfo
- Authorization information for contact change.
-
EPPContactAddChange
public EPPContactAddChange(java.util.Vector aPostalInfo, java.lang.String aVoice, java.lang.String aFax, java.lang.String aEmail, EPPAuthInfo aAuthInfo)
Constructor forEPPContactAddChange
.- Parameters:
aPostalInfo
- Vector, defining a series objects for contact changes.aVoice
- Voice numberaFax
- Fax numberaEmail
- EmailaAuthInfo
- Authorization information for contact change.
-
-
Method Detail
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeException
Encode a DOM Element tree from the attributes of theEPPContactAddChange
instance.- Specified by:
encode
in interfaceEPPCodecComponent
- Parameters:
aDocument
- DOM Document that is being built. Used as an Element factory.- Returns:
- Root DOM Element representing the
EPPContactAddChange
instance. - Throws:
EPPEncodeException
- Unable to encodeEPPContactAddChange
instance.
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeException
Decode theEPPContactAddChange
attributes from theaElement
DOM Element tree.- Specified by:
decode
in interfaceEPPCodecComponent
- Parameters:
aElement
- Root DOM Element to decodeEPPContactAddChange
from.- Throws:
EPPDecodeException
- Unable to decodeaElement
.
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPContactAddChange
compare.- Overrides:
equals
in classjava.lang.Object
- Parameters:
aObject
-EPPContactAddChange
instance to compare with- Returns:
true
if the objects are equal;false
otherwise
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
CloneEPPContactAddChange
.- Specified by:
clone
in interfaceEPPCodecComponent
- Overrides:
clone
in classjava.lang.Object
- Returns:
- clone of
EPPContactAddChange
- Throws:
java.lang.CloneNotSupportedException
- standard Object.clone exception
-
toString
public java.lang.String toString()
Implementation ofObject.toString
, which will result in an indented XMLString
representation of the concreteEPPCodecComponent
.- Overrides:
toString
in classjava.lang.Object
- Returns:
- Indented XML
String
if successful;ERROR
otherwise.
-
getPostalInfo
public java.util.Vector getPostalInfo()
Gets the postalInfo elements of contact change.- Returns:
Vector
ofEPPContactPostalDefinition
instances
-
setPostalInfo
public void setPostalInfo(java.util.Vector aPostalContacts)
Sets list of contact postal information.- Parameters:
aPostalContacts
- java.util.Vector ofEPPContactPostalDefinition
instances. Ifnull
, the list will be reset.
-
addPostalInfo
public void addPostalInfo(EPPContactPostalDefinition aPostalInfo)
Adds contact postalInfo.- Parameters:
aPostalInfo
- Postal information to add
-
hasAuthInfo
public boolean hasAuthInfo()
Returnstrue
if auth info exists.- Returns:
true
if auth info exists; otherwisefalse
.
-
getAuthInfo
public EPPAuthInfo getAuthInfo()
Get authorization information for contact change.- Returns:
- The authorization information is set;
null
otherwise
-
setAuthInfo
public void setAuthInfo(EPPAuthInfo aAuthInfo)
Set authorization information for contact change.- Parameters:
aAuthInfo
- Authorization information to set. The
-
hasDisclose
public boolean hasDisclose()
Returnstrue
if disclose exists.- Returns:
true
if disclose exists; otherwisefalse
.
-
getDisclose
public EPPContactDisclose getDisclose()
Get disclose information.- Returns:
- Disclose information if defined;
null
otherwise;
-
setDisclose
public void setDisclose(EPPContactDisclose aDisclose)
Sets the disclose information.- Parameters:
aDisclose
- Disclose information to set.
-
hasEmail
public boolean hasEmail()
Returnstrue
if email exists.- Returns:
true
if email exists; otherwisefalse
.
-
getEmail
public java.lang.String getEmail()
Gets email.- Returns:
- Email if set;
null
otherwise
-
setEmail
public void setEmail(java.lang.String aEmail)
Sets the email.- Parameters:
aEmail
- Email to set
-
hasFax
public boolean hasFax()
Returnstrue
if fax exists.- Returns:
true
if fax exists; otherwisefalse
.
-
getFax
public java.lang.String getFax()
Get fax number.- Returns:
- String fax number
-
setFax
public void setFax(java.lang.String aFax)
Sets the fax number.- Parameters:
aFax
- Fax number to set
-
hasFaxExt
public boolean hasFaxExt()
Returnstrue
if fax extension exists.- Returns:
true
if fax extension exists; otherwisefalse
.
-
getFaxExt
public java.lang.String getFaxExt()
Gets the fax extension.- Returns:
- fax extension if defined;
null
otherwise.
-
setFaxExt
public void setFaxExt(java.lang.String aFaxExt)
Sets the fax extension.- Parameters:
aFaxExt
- Fax extension
-
hasStatuses
public boolean hasStatuses()
Returnstrue
if statuses exist.- Returns:
true
if statuses exist; otherwisefalse
.
-
getStatuses
public java.util.Vector getStatuses()
Get a list of contact statuses.- Returns:
- Contact statuses if defined;
null
otherwise
-
setStatuses
public void setStatuses(java.util.Vector aStatuses)
Sets the list of contact statuses.- Parameters:
aStatuses
- List of contact statuses
-
hasVoice
public boolean hasVoice()
Returnstrue
if voice exists.- Returns:
true
if voice exists; otherwisefalse
.
-
getVoice
public java.lang.String getVoice()
Get voice number.- Returns:
- String fax number
-
setVoice
public void setVoice(java.lang.String aVoice)
Sets the voice number.- Parameters:
aVoice
- The voice number to set
-
hasVoiceExt
public boolean hasVoiceExt()
Returnstrue
if voice extension exists.- Returns:
true
if voice extension exists; otherwisefalse
.
-
getVoiceExt
public java.lang.String getVoiceExt()
Get voice number extension.- Returns:
- Voice number extension if defined;
null
otherwise.
-
setVoiceExt
public void setVoiceExt(java.lang.String aVoiceExt)
Sets the contact voice extension.- Parameters:
aVoiceExt
- voice extension
-
getNamespace
public java.lang.String getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.- Specified by:
getNamespace
in interfaceEPPCodecComponent
- Returns:
- XML namespace for the
EPPCodecComponent
.
-
-