Class EPPRegistryKey

java.lang.Object
com.verisign.epp.codec.registry.v02.EPPRegistryAbstractMinMax
com.verisign.epp.codec.registry.v02.EPPRegistryKey
All Implemented Interfaces:
EPPCodecComponent, Serializable, Cloneable

public class EPPRegistryKey extends EPPRegistryAbstractMinMax
Defines the Key Data Interface, as defined in RFC 5910, policies. The <registry:keyDataInterface> element contains the following child elements:

See Also:
  • Field Details

  • Constructor Details

    • EPPRegistryKey

      public EPPRegistryKey()
    • EPPRegistryKey

      public EPPRegistryKey(Integer aMin, Integer aMax)
      Constructs an instance with min and max.
      Parameters:
      aMin - minimum number of keys associated with the domain object
      aMax - maximum number of keys associated with the domain object
    • EPPRegistryKey

      public EPPRegistryKey(Integer aMin, Integer aMax, List<Integer> aFlags, List<Integer> aProtocols, List<Integer> aAlgorithms)
      Constructs an instance with min, max and List of algorithms.
      Parameters:
      aMin - minimum number of keys associated with the domain object
      aMax - maximum number of keys associated with the domain object
      aFlags - supported flags as described in section 2.1.1 of RFC 4034
      aProtocols - supported protocols as described in section 2.1.2 of RFC 4034
      aAlgorithms - supported algorithms as described in section 2.1.3 of RFC 4034
    • EPPRegistryKey

      public EPPRegistryKey(int aMin, int aMax, List<Integer> aFlags, List<Integer> aProtocols, List<Integer> aAlgorithms)
      Constructs an instance with min, max and List of algorithms.
      Parameters:
      aMin - minimum number of keys associated with the domain object
      aMax - maximum number of keys associated with the domain object
      aFlags - supported flags as described in section 2.1.1 of RFC 4034
      aProtocols - supported protocols as described in section 2.1.2 of RFC 4034
      aAlgorithms - supported algorithms as described in section 2.1.3 of RFC 4034
  • Method Details

    • encode

      public Element encode(Document aDocument) throws EPPEncodeException
      Encode a DOM Element tree from the attributes of the EPPRegistryKey instance.
      Specified by:
      encode in interface EPPCodecComponent
      Overrides:
      encode in class EPPRegistryAbstractMinMax
      Parameters:
      aDocument - DOM Document that is being built. Used as an Element factory.
      Returns:
      Element Root DOM Element representing the EPPRegistryKey instance.
      Throws:
      EPPEncodeException - - Unable to encode EPPRegistryKey instance.
    • decode

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

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

      public boolean equals(Object aObject)
      implements a deep EPPRegistryKey compare.
      Overrides:
      equals in class EPPRegistryAbstractMinMax
      Parameters:
      aObject - EPPRegistryKey instance to compare with
      Returns:
      true if this object is the same as the aObject argument; false otherwise
    • 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 EPPRegistryAbstractMinMax
      Returns:
      Indented XML String if successful; ERROR otherwise.
    • hasFlags

      public boolean hasFlags()
      Is the flags defined?
      Returns:
      true if the flags is defined; false otherwise.
    • getFlags

      public List<Integer> getFlags()
      Gets the supported flags.
      Returns:
      List of supported flags as described in section 2.1.1 of RFC 4034
    • setFlags

      public void setFlags(List<Integer> aFlags)
      Sets the supported flags.
      Parameters:
      aFlags - List of supported flags as described in section 2.1.1 of RFC 4034
    • addFlags

      public void addFlags(Integer aFlags)
      Adds one flags field to existing supported flags.
      Parameters:
      aFlags - supported flags field as described in section 2.1.1 of RFC 4034
    • hasProtocols

      public boolean hasProtocols()
      Is the protocols defined?
      Returns:
      true if the protocols is defined; false otherwise.
    • getProtocols

      public List<Integer> getProtocols()
      Gets the supported protocols.
      Returns:
      List of supported protocols as described in section 2.1.2 of RFC 4034
    • setProtocols

      public void setProtocols(List<Integer> aProtocol)
      Sets the supported protocols.
      Parameters:
      aProtocol - List of supported protocols as described in section 2.1.2 of RFC 4034
    • addProtocol

      public void addProtocol(Integer aProtocol)
      Adds one protocol to existing the supported protocols.
      Parameters:
      aProtocol - supported protocol as described in section 2.1.2 of RFC 4034
    • hasAlgorithms

      public boolean hasAlgorithms()
      Is the algorithms defined?
      Returns:
      true if the algorithms is defined; false otherwise.
    • getAlgorithms

      public List<Integer> getAlgorithms()
      Gets the supported algorithms.
      Returns:
      List of supported algorithms as described in section 2.1.3 of RFC 4034
    • setAlgorithms

      public void setAlgorithms(List<Integer> aAlgorithms)
      Sets the supported algorithms.
      Parameters:
      aAlgorithms - List of supported algorithms as described in section 2.1.3 of RFC 4034
    • addAlgorithm

      public void addAlgorithm(Integer aAlgorithm)
      Adds one algorithm to existing supported algorithms.
      Parameters:
      aAlgorithm - supported algorithm as described in section 2.1.3 of RFC 4034
    • getNamespace

      public String getNamespace()
      Returns the XML namespace associated with the EPPCodecComponent.
      Specified by:
      getNamespace in interface EPPCodecComponent
      Overrides:
      getNamespace in class EPPRegistryAbstractMinMax
      Returns:
      XML namespace for the EPPCodecComponent.
    • getRootName

      protected String getRootName()
      Gets the root element local name.
      Specified by:
      getRootName in class EPPRegistryAbstractMinMax
      Returns:
      Root element local name.
    • getElmMin

      protected String getElmMin()
      Gets the minimum element local name.
      Specified by:
      getElmMin in class EPPRegistryAbstractMinMax
      Returns:
      Minimum element local name.
    • getElmMax

      protected String getElmMax()
      Gets the maximum element local name.
      Specified by:
      getElmMax in class EPPRegistryAbstractMinMax
      Returns:
      Maximum element local name.
    • getLogger

      protected org.slf4j.Logger getLogger()
      Gets the Logger to use.
      Specified by:
      getLogger in class EPPRegistryAbstractMinMax
      Returns:
      Logger instance to use for logging.