com.verisign.epp.codec.host

## Class EPPHostCreateResp

- java.lang.Object
- - com.verisign.epp.codec.gen.EPPResponse
  - - com.verisign.epp.codec.host.EPPHostCreateResp

- All Implemented Interfaces:
    EPPCodecComponent, EPPMessage, java.io.Serializable, java.lang.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:
    `EPPHostCreateCmd`, Serialized Form

- - ### Field Summary

    - ### Fields inherited from class com.verisign.epp.codec.gen.EPPResponse

      `extensions, TRANSFER_CLIENT_APPROVED, TRANSFER_CLIENT_CANCELLED, TRANSFER_CLIENT_REJECTED, TRANSFER_PENDING, TRANSFER_SERVER_APPROVED, TRANSFER_SERVER_CANCELLED`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `EPPHostCreateResp()` `EPPHostCreateResp` default constructor.
    `EPPHostCreateResp(EPPTransId aTransId, java.lang.String aName)` `EPPHostCreateResp` constructor that will set the result of an individual host.
    `EPPHostCreateResp(EPPTransId aTransId, java.lang.String aName, java.util.Date aCreationDate)` `EPPHostCreateResp` constructor that takes the required attribute values as parameters.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.Object` | `clone()` Clone `EPPHostCreateResp`.
    `protected void` | `doDecode(org.w3c.dom.Element aElement)` Decode the `EPPHostCreateResp` attributes from the aElement DOM Element tree.
    `protected org.w3c.dom.Element` | `doEncode(org.w3c.dom.Document aDocument)` Encode a DOM Element tree from the attributes of the `EPPHostCreateResp` instance.
    `boolean` | `equals(java.lang.Object aObject)` Compare an instance of `EPPHostCreateResp` with this instance.
    `java.util.Date` | `getCreationDate()` Get creation date.
    `java.lang.String` | `getName()` Get host name.
    `java.lang.String` | `getNamespace()` Get the EPP command Namespace associated with `EPPHostCreateResp`.
    `java.lang.String` | `getType()` Get the EPP response type associated with `EPPHostCreateResp`.
    `void` | `setCreationDate(java.util.Date newCrDate)` Set creation date.
    `void` | `setName(java.lang.String newName)` Set host name.
    `java.lang.String` | `toString()` Implementation of `Object.toString`, which will result in an indented XML `String` representation of the concrete `EPPCodecComponent`.

    - ### Methods inherited from class com.verisign.epp.codec.gen.EPPResponse

      `addExtension, decode, encode, findDuplicateExtNamespaces, getExtension, getExtension, getExtensions, getMessageQueue, getMsgQueue, getMsgQueueCount, getMsgQueueDate, getMsgQueueMsg, getQDate, getResult, getResults, getTransId, hasExtension, hasExtensions, hasMessageQueue, hasMsgQueue, hasResultCode, isSuccess, setExtension, setExtensions, setMsgQueue, setResult, setResult, setResult, setResult, setResults, setTransId`

    - ### Methods inherited from class java.lang.Object

      `finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### 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,
                                   java.lang.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,
                                   java.lang.String aName,
                                   java.util.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 Detail

    - #### getType

          public java.lang.String getType()

      Get the EPP response type associated with `EPPHostCreateResp`.
      Overrides:
        `getType` in class `EPPResponse`
      Returns:
        EPPHostCreateResp.ELM_NAME

    - #### getNamespace

          public java.lang.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 java.util.Date getCreationDate()

      Get creation date.
      Returns:
        creation date

    - #### setCreationDate

          public void setCreationDate(java.util.Date newCrDate)

      Set creation date.
      Parameters:
        `newCrDate` - creation date

    - #### doEncode

          protected org.w3c.dom.Element doEncode(org.w3c.dom.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(org.w3c.dom.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(java.lang.Object aObject)

      Compare an instance of `EPPHostCreateResp` with this instance.
      Overrides:
        `equals` in class `EPPResponse`
      Parameters:
        `aObject` - Object to compare with.
      Returns:
        DOCUMENT ME!

    - #### clone

          public java.lang.Object clone()
                                 throws java.lang.CloneNotSupportedException

      Clone `EPPHostCreateResp`.
      Specified by:
        `clone` in interface `EPPCodecComponent`
      Overrides:
        `clone` in class `EPPResponse`
      Returns:
        clone of `EPPHostCreateResp`
      Throws:
        `java.lang.CloneNotSupportedException` - standard Object.clone exception

    - #### toString

          public java.lang.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 java.lang.String getName()

      Get host name.
      Returns:
        String Host Name

    - #### setName

          public void setName(java.lang.String newName)

      Set host name.
      Parameters:
        `newName` - String