Class EPPValidatePostalDefinition

java.lang.Object
com.verisign.epp.codec.validate.v02.EPPValidatePostalDefinition
All Implemented Interfaces:
EPPCodecComponent, Serializable, Cloneable

public class EPPValidatePostalDefinition extends Object implements EPPCodecComponent
Represents a contact postal address definition. The child elements associated with an EPPValidatePostalDefinition include:
See Also:
  • Field Details

  • Constructor Details

    • EPPValidatePostalDefinition

      public EPPValidatePostalDefinition()
      EPPValidatePostalDefinition default constructor.
    • EPPValidatePostalDefinition

      public EPPValidatePostalDefinition(EPPValidatePostalDefinition.Type aType)
      EPPValidatePostalDefinition constructor that takes the contact postal type as an argument.
      Parameters:
      aType - Postal type
    • EPPValidatePostalDefinition

      public EPPValidatePostalDefinition(EPPValidatePostalDefinition.Type aType, String aName, EPPValidateAddress aAddress)
      EPPValidatePostalDefinition constructor that sets the required attributes with the parameters.
      Parameters:
      aType - Postal type
      aName - contact name
      aAddress - contact address
  • Method Details

    • getType

      Gets the contact postal type.
      Returns:
      Contact postal type
    • setType

      public void setType(EPPValidatePostalDefinition.Type aType)
      Sets the contact type.
      Parameters:
      aType - Contact postal type
    • getName

      public String getName()
      Gets the contact name
      Returns:
      Contact Name if defined; null otherwise.
    • setName

      public void setName(String aName)
      Sets the contact name.
      Parameters:
      aName - Contact Name
    • hasOrg

      public boolean hasOrg()
      Is the org defined?
      Returns:
      true if the org is defined; false otherwise.
    • getOrg

      public String getOrg()
      Gets the contact org
      Returns:
      Contact Org if defined; null otherwise.
    • setOrg

      public void setOrg(String aOrg)
      Sets the contact org.
      Parameters:
      aOrg - Contact org
    • getAddress

      public EPPValidateAddress getAddress()
      Gets the contact address
      Returns:
      Contact address if defined; null otherwise.
    • setAddress

      public void setAddress(EPPValidateAddress aAddress)
      Sets the contact address
      Parameters:
      aAddress - Contact address
    • encode

      public Element encode(Document aDocument) throws EPPEncodeException
      Encode a DOM Element tree from the attributes of the EPPValidatePostalDefinition instance.
      Specified by:
      encode in interface EPPCodecComponent
      Parameters:
      aDocument - DOM Document that is being built. Used as an Element factory.
      Returns:
      Encoded DOM Element
      Throws:
      EPPEncodeException - On encoding error
    • decode

      public void decode(Element aElement) throws EPPDecodeException
      Decode the EPPValidatePostalDefinition attributes from the aElement DOM Element tree.
      Specified by:
      decode in interface EPPCodecComponent
      Parameters:
      aElement - Root DOM Element to decode EPPValidatePostalDefinition from.
      Throws:
      EPPDecodeException - Unable to decode aElement
    • equals

      public boolean equals(Object aObject)
      implements a deep EPPValidatePostalDefinition compare.
      Overrides:
      equals in class Object
      Parameters:
      aObject - EPPValidatePostalDefinition instance to compare with
      Returns:
      true if the object is equal to aObject; false otherwise.
    • clone

      public Object clone() throws CloneNotSupportedException
      Clone EPPValidatePostalDefinition.
      Specified by:
      clone in interface EPPCodecComponent
      Overrides:
      clone in class Object
      Returns:
      clone of EPPValidatePostalDefinition
      Throws:
      CloneNotSupportedException - standard Object.clone exception
    • toString

      public String toString()
      Implementation of Object.toString, which will result in an indented XML String representation of the concrete EPPCodecComponent.
      Overrides:
      toString in class Object
      Returns:
      Indented XML String if successful; ERROR otherwise.
    • getNamespace

      public String getNamespace()
      Returns the XML namespace associated with the EPPCodecComponent.
      Specified by:
      getNamespace in interface EPPCodecComponent
      Returns:
      XML namespace for the EPPCodecComponent.