Class EPPEncodedSignedCode
- java.lang.Object
-
- com.verisign.epp.codec.verificationcode.EPPEncodedSignedCode
-
- All Implemented Interfaces:
EPPCodecComponent,java.io.Serializable,java.lang.Cloneable
public class EPPEncodedSignedCode extends java.lang.Object implements EPPCodecComponent
Class for the encoded signed code, which contains the code and theXMLSignatureitself. This class extendsEPPSignedCode.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringELM_LOCALNAMEConstant for the code local name for encoded signedCode elementstatic java.lang.StringELM_NAMEConstant for the code tag for signedCode element
-
Constructor Summary
Constructors Constructor Description EPPEncodedSignedCode()Default constructorEPPEncodedSignedCode(EPPEncodedSignedCodeValue aEncodedSignedCodeValue)Construct an encoded signed code with a single encoded signed code value.EPPEncodedSignedCode(EPPSignedCode aSignedCode)Construct an encoded signed code with a single signed code value.EPPEncodedSignedCode(EPPVerificationCode aCode)Create anEPPEncodedSignedCodewith the code of the signed code.EPPEncodedSignedCode(java.lang.String aCode, java.lang.String aType)Create anEPPEncodedSignedCodewith the code of the signed code and code type.EPPEncodedSignedCode(java.util.List<EPPEncodedSignedCodeValue> aCodes)Create anEPPEncodedSignedCodewith a list of encoded signed code values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddCode(EPPEncodedSignedCodeValue aCode)Adds a encoded signed code to the list of encoded signed codes.java.lang.Objectclone()CloneEPPEncodedSignedCode.voiddecode(org.w3c.dom.Element aElement)Decode theEPPSignedCodecomponentorg.w3c.dom.Elementencode(org.w3c.dom.Document aDocument)Sets all this instance's data in the given XML documentbooleanequals(java.lang.Object aObject)implements a deepEPPEncodedSignedCodecompare.java.lang.StringgetNamespace()Returns the XML namespace associated with theEPPCodecComponent.java.util.List<EPPEncodedSignedCodeValue>getSignedCodes()Gets the list of encoded signed codes.booleanhasCodes()Are encoded signed codes defined?voidsetCode(EPPEncodedSignedCodeValue aCode)Sets the encoded signed codes to a single code.voidsetSignedCodes(java.util.List<EPPEncodedSignedCodeValue> aCodes)Sets the list of encoded signed codes.java.lang.StringtoString()Implementation ofObject.toString, which will result in an indented XMLStringrepresentation of the concreteEPPCodecComponent.
-
-
-
Field Detail
-
ELM_LOCALNAME
public static final java.lang.String ELM_LOCALNAME
Constant for the code local name for encoded signedCode element- See Also:
- Constant Field Values
-
ELM_NAME
public static final java.lang.String ELM_NAME
Constant for the code tag for signedCode element- See Also:
- Constant Field Values
-
-
Constructor Detail
-
EPPEncodedSignedCode
public EPPEncodedSignedCode()
Default constructor
-
EPPEncodedSignedCode
public EPPEncodedSignedCode(EPPSignedCode aSignedCode) throws EPPEncodeException, EPPDecodeException
Construct an encoded signed code with a single signed code value.- Parameters:
aSignedCode- Signed code value that will be encoded and added to the list.- Throws:
EPPEncodeException- Error encoding the SignedCodebyte[].EPPDecodeException- Error decoding the encoded SignedCodebyte[].
-
EPPEncodedSignedCode
public EPPEncodedSignedCode(EPPEncodedSignedCodeValue aEncodedSignedCodeValue)
Construct an encoded signed code with a single encoded signed code value.- Parameters:
aEncodedSignedCodeValue- Encoded signed code value to add to the list.
-
EPPEncodedSignedCode
public EPPEncodedSignedCode(EPPVerificationCode aCode) throws EPPEncodeException
Create anEPPEncodedSignedCodewith the code of the signed code.- Parameters:
aCode- Verification code- Throws:
EPPEncodeException- Thrown if any errors prevent encoding.
-
EPPEncodedSignedCode
public EPPEncodedSignedCode(java.lang.String aCode, java.lang.String aType) throws EPPEncodeExceptionCreate anEPPEncodedSignedCodewith the code of the signed code and code type.- Parameters:
aCode- Verification codeaType- OPTIONAL verification code type. Set tonullif no type is defined.- Throws:
EPPEncodeException- Thrown if any errors prevent encoding.
-
EPPEncodedSignedCode
public EPPEncodedSignedCode(java.util.List<EPPEncodedSignedCodeValue> aCodes)
Create anEPPEncodedSignedCodewith a list of encoded signed code values.- Parameters:
aCodes- List of encoded signed code values
-
-
Method Detail
-
hasCodes
public boolean hasCodes()
Are encoded signed codes defined?- Returns:
trueif encoded signed codes are defined;falseotherwise.
-
getSignedCodes
public java.util.List<EPPEncodedSignedCodeValue> getSignedCodes()
Gets the list of encoded signed codes.- Returns:
- List of encoded signed codes if set;
nullotherwise.
-
setSignedCodes
public void setSignedCodes(java.util.List<EPPEncodedSignedCodeValue> aCodes)
Sets the list of encoded signed codes.- Parameters:
aCodes- List of encoded signed codes
-
setCode
public void setCode(EPPEncodedSignedCodeValue aCode)
Sets the encoded signed codes to a single code.- Parameters:
aCode- Encoded signed code to set
-
addCode
public void addCode(EPPEncodedSignedCodeValue aCode)
Adds a encoded signed code to the list of encoded signed codes.- Parameters:
aCode- Encoded signed code to add to the list of encoded signed codes.
-
decode
public void decode(org.w3c.dom.Element aElement) throws EPPDecodeExceptionDecode theEPPSignedCodecomponent- Specified by:
decodein interfaceEPPCodecComponent- Parameters:
aElement- Root element of theEPPSignedCode- Throws:
EPPDecodeException- Error decoding theEPPSignedCode
-
encode
public org.w3c.dom.Element encode(org.w3c.dom.Document aDocument) throws EPPEncodeExceptionSets all this instance's data in the given XML document- Specified by:
encodein interfaceEPPCodecComponent- Parameters:
aDocument- a DOM Document to attach data to.- Returns:
- The root element of this component.
- Throws:
EPPEncodeException- Thrown if any errors prevent encoding.
-
equals
public boolean equals(java.lang.Object aObject)
implements a deepEPPEncodedSignedCodecompare.- Overrides:
equalsin classjava.lang.Object- Parameters:
aObject-EPPEncodedSignedCodeinstance to compare with- Returns:
- true if equal false otherwise
-
clone
public java.lang.Object clone() throws java.lang.CloneNotSupportedExceptionCloneEPPEncodedSignedCode.- Specified by:
clonein interfaceEPPCodecComponent- Overrides:
clonein classjava.lang.Object- Returns:
- clone of
EPPEncodedSignedCode - 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.
-
-