Class EPPContactCheckCmd

All Implemented Interfaces:
EPPCodecComponent, EPPMessage, Serializable, Cloneable

public class EPPContactCheckCmd extends EPPCheckCmd
Represents an EPP Contact <check> command, which is used to determine if a contact id is known to the server. In addition to the standard EPP command elements, the <check> command MUST contain a <contact:check> element that identifies the contact namespace and the location of the contact schema. The <contact:check> element MUST contain the following child elements:

  • One or more <contact:id> elements. The contact id is the the server-unique identifier for the contact. Use getIds and setIds to get and set the elements. Use setId to set an individual id.

EPPContactCheckResp is the concrete EPPReponse associated with EPPContactCheckCmd.

See Also:
  • Constructor Details

    • EPPContactCheckCmd

      public EPPContactCheckCmd()
      EPPContactCheckCmd default constructor. It will set the ids attribute to an empty Vector.
    • EPPContactCheckCmd

      public EPPContactCheckCmd(String aTransId, String aId)
      EPPContactCheckCmd constructor that will check an individual contact id.
      Parameters:
      aTransId - Transaction Id associated with command.
      aId - Contact id to check
    • EPPContactCheckCmd

      public EPPContactCheckCmd(String aTransId, Vector someIds)
      EPPContactCheckCmd constructor that will check a list of contact ids.
      Parameters:
      aTransId - Transaction Id associated with command.
      someIds - Vector of contact id String's.
  • Method Details

    • getNamespace

      public String getNamespace()
      Gets the EPP command Namespace associated with EPPContactCheckCmd.
      Specified by:
      getNamespace in interface EPPCodecComponent
      Specified by:
      getNamespace in interface EPPMessage
      Specified by:
      getNamespace in class EPPCommand
      Returns:
      EPPContactMapFactory.NS
    • getKey

      public String getKey()
      Gets the key for the contact object, which is the contact identifier.
      Overrides:
      getKey in class EPPCommand
      Returns:
      The contact identifier if set with a single value; null otherwise.
    • doEncode

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

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

      public boolean equals(Object aObject)
      Compare an instance of EPPContactCheckCmd with this instance.
      Overrides:
      equals in class EPPCheckCmd
      Parameters:
      aObject - Object to compare with.
      Returns:
      DOCUMENT ME!
    • clone

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

      public void setId(String aId)
      Sets contact id to check.
      Parameters:
      aId - Id to check.
    • getIds

      public Vector getIds()
      Gets contact ids to check.
      Returns:
      Vector of contact id String's.
    • setIds

      public void setIds(Vector someIds)
      Sets contact ids to check.
      Parameters:
      someIds - Ids to check.