Class EPPHostCreateResp

java.lang.Object
com.verisign.epp.codec.gen.EPPResponse
com.verisign.epp.codec.host.EPPHostCreateResp
All Implemented Interfaces:
EPPCodecComponent, EPPMessage, Serializable, Cloneable

public class EPPHostCreateResp extends EPPResponse
Represents an EPP Host <host:resData> response to a EPPHostCreateCmd. When a <create> command has been processed successfully, the EPP <resData> element MUST contain a child <host:creData> element that identifies the host namespace and the location of the host schema. The <host:creData> element SHALL contain the following child elements:
  • A <host:name> element that contains the fully qualified name of the host object. Use getName and setName to get and set the element.
  • A <host:crDate> element that contains the date and time of host object. Use getCreationDate and setCreationDate to get and set the element.
See Also:
  • Field Details

  • Constructor Details

    • EPPHostCreateResp

      public EPPHostCreateResp()
      EPPHostCreateResp default constructor.
      It will set results attribute to an empty Vector. The name is initialized to null. The creation date must be set before invoking encode.
    • EPPHostCreateResp

      public EPPHostCreateResp(EPPTransId aTransId, String aName)
      EPPHostCreateResp constructor that will set the result of an individual host. The creation date must be set before invoking encode.
      Parameters:
      aTransId - Transaction Id associated with response.
      aName - Host name
    • EPPHostCreateResp

      public EPPHostCreateResp(EPPTransId aTransId, String aName, Date aCreationDate)
      EPPHostCreateResp constructor that takes the required attribute values as parameters.
      Parameters:
      aTransId - Transaction Id associated with response.
      aName - Host name
      aCreationDate - Creation date of the host
  • Method Details

    • getType

      public String getType()
      Get the EPP response type associated with EPPHostCreateResp.
      Overrides:
      getType in class EPPResponse
      Returns:
      EPPHostCreateResp.ELM_NAME
    • getNamespace

      public String getNamespace()
      Get the EPP command Namespace associated with EPPHostCreateResp.
      Specified by:
      getNamespace in interface EPPCodecComponent
      Specified by:
      getNamespace in interface EPPMessage
      Overrides:
      getNamespace in class EPPResponse
      Returns:
      EPPHostMapFactory.NS
    • getCreationDate

      public Date getCreationDate()
      Get creation date.
      Returns:
      creation date
    • setCreationDate

      public void setCreationDate(Date aCrDate)
      Set creation date.
      Parameters:
      aCrDate - creation date
    • doEncode

      protected Element doEncode(Document aDocument) throws EPPEncodeException
      Encode a DOM Element tree from the attributes of the EPPHostCreateResp instance.
      Overrides:
      doEncode in class EPPResponse
      Parameters:
      aDocument - DOM Document that is being built. Used as an Element factory.
      Returns:
      Element Root DOM Element representing the EPPHostCreateResp instance.
      Throws:
      EPPEncodeException - Unable to encode EPPHostCreateResp instance.
    • doDecode

      protected void doDecode(Element aElement) throws EPPDecodeException
      Decode the EPPHostCreateResp attributes from the aElement DOM Element tree.
      Overrides:
      doDecode in class EPPResponse
      Parameters:
      aElement - Root DOM Element to decode EPPHostCreateResp from.
      Throws:
      EPPDecodeException - Unable to decode aElement
    • equals

      public boolean equals(Object aObject)
      Compare an instance of EPPHostCreateResp with this instance.
      Overrides:
      equals in class EPPResponse
      Parameters:
      aObject - Object to compare with.
      Returns:
      true when equal; false otherwise.
    • clone

      public Object clone() throws CloneNotSupportedException
      Clone EPPHostCreateResp.
      Specified by:
      clone in interface EPPCodecComponent
      Overrides:
      clone in class EPPResponse
      Returns:
      clone of EPPHostCreateResp
      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 EPPResponse
      Returns:
      Indented XML String if successful; ERROR otherwise.
    • getName

      public String getName()
      Get host name.
      Returns:
      String Host Name
    • setName

      public void setName(String newName)
      Set host name.
      Parameters:
      newName - String