Package com.verisign.epp.codec.gen
Class EPPAuthInfo
- java.lang.Object
-
- com.verisign.epp.codec.gen.EPPAuthInfo
-
- All Implemented Interfaces:
EPPCodecComponent
,java.io.Serializable
,java.lang.Cloneable
public class EPPAuthInfo extends java.lang.Object implements EPPCodecComponent
Represents authorization information which is a shared structure been used by other mapping such as domain and contact mappings. This object structure is a direct mapping from the data typeauthInfo
in the EPP Shared Structure Schema (with the name spaceeppcom
).- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.String
ATTR_ROID
XML Element roid attribute name ofEPPAuthInfo
root element.protected static java.lang.String
ELM_EXT
XML Element name for extensible authorization typeprotected static java.lang.String
ELM_NULL
XML Element name for null authorization typeprotected static java.lang.String
ELM_PW
XML Element name for password authorization typeprotected EPPCodecComponent
ext
Extension authorization information.protected java.lang.String
password
Password authorization information.protected java.lang.String
roid
roid.protected short
type
type, and default value isTYPE_PW
static short
TYPE_EXT
Extensible auth info type.static short
TYPE_NULL
Null type to remove authorization information.static short
TYPE_PW
Password auth info type
-
Constructor Summary
Constructors Constructor Description EPPAuthInfo()
Default constructor that must have the password or extension attributes set before callingencode
.EPPAuthInfo(EPPCodecComponent aExt)
Constructor that takes just the authorization extension.EPPAuthInfo(java.lang.String aPassword)
Constructor that takes just the authorization password.EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, EPPCodecComponent aExt)
Constructor that takes a root elemeent and the authorization extension.EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, java.lang.String aPassword)
Constructor that takes the root element and the authorization password.EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, java.lang.String aRoid, java.lang.String aPassword)
Constructor that takes the root element, the authorization password, and the roid.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.Object
clone()
CloneEPPAuthInfo
.void
decode(org.w3c.dom.Element aElement)
Decode the EPPAuthInfo attributes from the aElement DOM Element tree.org.w3c.dom.Element
encode(org.w3c.dom.Document aDocument)
Encode a DOM Element tree from the attributes of the EPPAuthInfo instance.boolean
equals(java.lang.Object aObject)
implements a deepEPPAuthInfo
compare.java.lang.String
getAuthInfo()
Deprecated.Replaced bygetPassword()
.EPPCodecComponent
getExt()
Gets the extension authorization.java.lang.String
getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.java.lang.String
getPassword()
Gets the password authorization information.java.lang.String
getRoid()
Get Registry Object IDentifier (ROID).java.lang.String
getRootName()
Get root name such as domain or contact.java.lang.String
getRootNS()
Gets the root element XML namespace URI.short
getType()
Get the type of the auth info.boolean
hasExt()
Has the the the extension authorization set?boolean
hasPassword()
Has the the password been set with a non-empty value?void
removePassword()
Removes the password authorization information on update.void
setAuthInfo(java.lang.String aPassword)
Deprecated.Replaced bysetPassword(String)
.void
setExt(EPPCodecComponent aExt)
Sets the extension authorization information.void
setPassword(java.lang.String aPassword)
Sets the password authorization information.void
setRoid(java.lang.String aRoid)
Set Registry Object IDentifier (ROID).void
setRootName(java.lang.String aRootNS, java.lang.String newRootName)
Set root name and XML namespace.void
setType(short aType)
Set auth info type.java.lang.String
toString()
Implementation ofObject.toString
, which will result in an indented XMLString
representation of the concreteEPPCodecComponent
.
-
-
-
Field Detail
-
TYPE_PW
public static final short TYPE_PW
Password auth info type- See Also:
- Constant Field Values
-
TYPE_EXT
public static final short TYPE_EXT
Extensible auth info type.- See Also:
- Constant Field Values
-
TYPE_NULL
public static final short TYPE_NULL
Null type to remove authorization information. This is not supported by all objects.- See Also:
- Constant Field Values
-
ELM_PW
protected static final java.lang.String ELM_PW
XML Element name for password authorization type- See Also:
- Constant Field Values
-
ELM_EXT
protected static final java.lang.String ELM_EXT
XML Element name for extensible authorization type- See Also:
- Constant Field Values
-
ELM_NULL
protected static final java.lang.String ELM_NULL
XML Element name for null authorization type- See Also:
- Constant Field Values
-
ATTR_ROID
protected static final java.lang.String ATTR_ROID
XML Element roid attribute name ofEPPAuthInfo
root element.- See Also:
- Constant Field Values
-
password
protected java.lang.String password
Password authorization information.
-
ext
protected EPPCodecComponent ext
Extension authorization information.
-
type
protected short type
type, and default value isTYPE_PW
-
roid
protected java.lang.String roid
roid.
-
-
Constructor Detail
-
EPPAuthInfo
public EPPAuthInfo()
Default constructor that must have the password or extension attributes set before callingencode
.
-
EPPAuthInfo
public EPPAuthInfo(java.lang.String aPassword)
Constructor that takes just the authorization password.- Parameters:
aPassword
- Authorization password
-
EPPAuthInfo
public EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, java.lang.String aPassword)
Constructor that takes the root element and the authorization password.- Parameters:
aRootNS
- Root element namespace URIaRootName
- Root element of auth info.aPassword
- Authorization password
-
EPPAuthInfo
public EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, java.lang.String aRoid, java.lang.String aPassword)
Constructor that takes the root element, the authorization password, and the roid.- Parameters:
aRootNS
- Root element namespace URIaRootName
- Root element of auth info.aRoid
- Roid of the RegistrantaPassword
- Authorization password
-
EPPAuthInfo
public EPPAuthInfo(EPPCodecComponent aExt)
Constructor that takes just the authorization extension.- Parameters:
aExt
- Extension authorization element
-
EPPAuthInfo
public EPPAuthInfo(java.lang.String aRootNS, java.lang.String aRootName, EPPCodecComponent aExt)
Constructor that takes a root elemeent and the authorization extension.- Parameters:
aRootNS
- Root element namespace URIaRootName
- Root element of auth info.aExt
- Extension authorization element
-
-
Method Detail
-
getRoid
public java.lang.String getRoid()
Get Registry Object IDentifier (ROID).- Returns:
- Registry Object IDentifier (ROID)
-
setRoid
public void setRoid(java.lang.String aRoid)
Set Registry Object IDentifier (ROID).- Parameters:
aRoid
- The Registry Object IDentifier (ROID) value.
-
getRootNS
public java.lang.String getRootNS()
Gets the root element XML namespace URI.- Returns:
- root element XML namespace URI
-
getRootName
public java.lang.String getRootName()
Get root name such as domain or contact.- Returns:
- String
-
setRootName
public void setRootName(java.lang.String aRootNS, java.lang.String newRootName)
Set root name and XML namespace.- Parameters:
aRootNS
- Root element namespace URInewRootName
- String
-
getAuthInfo
@Deprecated public java.lang.String getAuthInfo()
Deprecated.Replaced bygetPassword()
.Gets the password authorization information.- Returns:
- Password
-
hasPassword
public boolean hasPassword()
Has the the password been set with a non-empty value?- Returns:
true
if the password has has been set with a non-empty value;false
otherwise.
-
getPassword
public java.lang.String getPassword()
Gets the password authorization information.- Returns:
- Authorization password
-
setPassword
public void setPassword(java.lang.String aPassword)
Sets the password authorization information.- Parameters:
aPassword
- Authorization password
-
removePassword
public void removePassword()
Removes the password authorization information on update. This option is not supported by all objects and only available with the update command. It will result in setting thetype
toTYPE_NULL
.
-
hasExt
public boolean hasExt()
Has the the the extension authorization set?- Returns:
true
if the extension authorization has been set;false
otherwise.
-
getExt
public EPPCodecComponent getExt()
Gets the extension authorization.- Returns:
- Authorization extension
-
setExt
public void setExt(EPPCodecComponent aExt)
Sets the extension authorization information.- Parameters:
aExt
- Authorization extension
-
setAuthInfo
@Deprecated public void setAuthInfo(java.lang.String aPassword)
Deprecated.Replaced bysetPassword(String)
.Sets the password authorization information.- Parameters:
aPassword
- Authorization password
-
getType
public short getType()
Get the type of the auth info.- Returns:
- One of the
TYPE_
constants.
-
setType
public void setType(short aType)
Set auth info type. The default value isTYPE_PW
.- Parameters:
aType
- One of theTYPE_
constants
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
CloneEPPAuthInfo
.- Specified by:
clone
in interfaceEPPCodecComponent
- Overrides:
clone
in classjava.lang.Object
- Returns:
- clone of
EPPAuthInfo
- Throws:
java.lang.CloneNotSupportedException
- standard Object.clone exception
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeException
Decode the EPPAuthInfo attributes from the aElement DOM Element tree.- Specified by:
decode
in interfaceEPPCodecComponent
- Parameters:
aElement
- - Root DOM Element to decode EPPDomainContact from.- Throws:
EPPDecodeException
- - Unable to decode aElement.
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeException
Encode a DOM Element tree from the attributes of the EPPAuthInfo instance.- Specified by:
encode
in interfaceEPPCodecComponent
- Parameters:
aDocument
- - DOM Document that is being built. Used as an Element factory.- Returns:
- Element - Root DOM Element representing the EPPAuthInfo instance.
- Throws:
EPPEncodeException
- - Unable to encode EPPAuthInfo instance.
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPAuthInfo
compare.- Overrides:
equals
in classjava.lang.Object
- Parameters:
aObject
-EPPAuthInfo
instance to compare with- Returns:
true
if equal;false
otherwise
-
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.
-
getNamespace
public java.lang.String getNamespace()
Returns the XML namespace associated with theEPPCodecComponent
.- Specified by:
getNamespace
in interfaceEPPCodecComponent
- Returns:
- XML namespace for the
EPPCodecComponent
.
-
-