Class EPPRegistryInfoCmd

All Implemented Interfaces:
EPPCodecComponent, EPPMessage, Serializable, Cloneable

public class EPPRegistryInfoCmd extends EPPInfoCmd
Represents an EPP Registry <info> command that is used to retrieve information associated with a registry. The <registry:info> element MUST contain one of the following child elements:

  • A <registry:all> empty element that specifies whether or not to query a list of all supported zone objects by the server. Use isAll and setAll to get and set the element.
  • A <registry:name> element that contains the fully qualified zone object name for which information is requested. Use getName and setName to get and set the element.
  • A <registry:system> Element that is empty and that indicates that the registry system attributes, like maximum connections and timeouts, are queried. Use isSystem and setSystem to get and set the element.
A valid EPPRegistryInfoCmd must contains one and only one of the above elements.

EPPRegistryInfoResp is the concrete EPPReponse associated with EPPRegistryInfoResp.

See Also:
  • Field Details

  • Constructor Details

    • EPPRegistryInfoCmd

      public EPPRegistryInfoCmd()
      EPPRegistryInfoCmd default constructor. The mode must be set using setMode(Mode) prior to invoking EPPCommand.encode(Document).
    • EPPRegistryInfoCmd

      public EPPRegistryInfoCmd(String aTransId, String aName)
      EPPRegistryInfoCmd constructor that takes the qualified aLabel zone object name as an argument. The mode is set to Enum.name().
      Parameters:
      aTransId - transaction Id associated with command
      aName - fully qualified aLabel zone object name to get information on
    • EPPRegistryInfoCmd

      public EPPRegistryInfoCmd(String aTransId, EPPRegistryZoneName aName)
      EPPRegistryInfoCmd constructor that takes the qualified zone object name as an argument. The mode is set to Enum.name().
      Parameters:
      aTransId - transaction Id associated with command
      aName - fully qualified zone object name to get information on
    • EPPRegistryInfoCmd

      public EPPRegistryInfoCmd(String aTransId, EPPRegistryInfoCmd.Mode aMode)
      EPPRegistryInfoCmd constructor defines the query mode to use. It is most likely used when setting the mode to EPPRegistryInfoCmd.Mode.system.
      Parameters:
      aTransId - transaction Id associated with command
      aMode - Query mode to use.
    • EPPRegistryInfoCmd

      public EPPRegistryInfoCmd(String aTransId, EPPRegistryInfoCmd.Scope aScope)
      EPPRegistryInfoCmd constructor that queries for all of the accessible and/or available zone objects from the server with the desired scope. The mode is set to EPPRegistryInfoCmd.Mode.all.
      Parameters:
      aTransId - transaction Id associated with command
      aScope - Zone scope to query for. Passing null will result in the use of the default scope Scope#accessible.
  • Method Details

    • doEncode

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

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

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

      public String getKey()
      Gets the key for the registry object, which is the registry zone name.
      Overrides:
      getKey in class EPPCommand
      Returns:
      The zone name if set; null otherwise.
    • equals

      public boolean equals(Object aObject)
      Compare an instance of EPPRegistryInfoCmd with this instance.
      Overrides:
      equals in class EPPInfoCmd
      Parameters:
      aObject - Object to compare with
      Returns:
      true if this object is the same as the aObject argument; false otherwise
    • clone

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

      public boolean hasName()
      Is the name defined?
      Returns:
      true if the name is defined; false otherwise.
    • getName

      public EPPRegistryZoneName getName()
      Gets the zone name.
      Returns:
      Zone name if set; null otherwise.
    • setName

      public void setName(EPPRegistryZoneName aName)
      Sets the zone name to query for. The mode is set to Enum.name().
      Parameters:
      aName - Zone name
    • setName

      public void setName(String aName)
      Sets the zone name to query for. The mode is set to Enum.name().
      Parameters:
      aName - aLabel zone name
    • hasMode

      public boolean hasMode()
      Is the query mode defined?
      Returns:
      true if the query mode is defined; false otherwise.
    • getMode

      public EPPRegistryInfoCmd.Mode getMode()
      Gets the query mode.
      Returns:
      The query mode if defined; null otherwise.
    • setMode

      public void setMode(EPPRegistryInfoCmd.Mode aMode)
      Sets the query mode.
      Parameters:
      aMode - Query mode to use
    • getScope

      public EPPRegistryInfoCmd.Scope getScope()
      Gets the zone scope used with the query all option.
      Returns:
      Scope passed with the <registry:all> "scope" attribute if defined; null otherwise.
    • setScope

      public void setScope(EPPRegistryInfoCmd.Scope aScope)
      Sets the zone scope used with the query all mode. The mode is set to EPPRegistryInfoCmd.Mode.all.
      Parameters:
      aScope - Scope passed with the <registry:all> "scope" attribute. If null is passed, the default value of EPPRegistryInfoCmd.Scope.accessible will be used.