Class EPPRegistryPeriodType

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  EPPRegistryPeriodType.Unit
      Possible values for the unit attribute.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String ATTR_UNIT
      Attribute name for the unit attribute.
      static java.lang.String ELM_LOCALNAME
      Default root element local name
      protected java.lang.Integer number
      Number of the period
      protected EPPRegistryPeriodType.Unit unit
      Unit of the period
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object clone()
      Clone EPPRegistryPeriodType.
      void decode​(org.w3c.dom.Element aElement)
      Decode the EPPRegistryPeriodType attributes from the aElement DOM Element tree.
      org.w3c.dom.Element encode​(org.w3c.dom.Document aDocument)
      Encode a DOM Element tree from the attributes of the EPPRegistryPeriodType instance.
      boolean equals​(java.lang.Object aObject)
      implements a deep EPPRegistryPeriodType compare.
      java.lang.Integer getNumber()
      Gets the period number.
      protected java.lang.String getRootName()
      Gets the root element local name.
      EPPRegistryPeriodType.Unit getUnit()
      Gets the period unit.
      void setNumber​(java.lang.Integer aNumber)
      Sets the period number.
      void setUnit​(EPPRegistryPeriodType.Unit aUnit)
      Sets the period unit.
      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 java.lang.Object

        finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • ELM_LOCALNAME

        public static final java.lang.String ELM_LOCALNAME
        Default root element local name
        See Also:
        Constant Field Values
      • ATTR_UNIT

        public static final java.lang.String ATTR_UNIT
        Attribute name for the unit attribute.
        See Also:
        Constant Field Values
      • number

        protected java.lang.Integer number
        Number of the period
    • Constructor Detail

      • EPPRegistryPeriodType

        public EPPRegistryPeriodType()
        Default constructor for EPPRegistryPeriodType. The number and unit attributes must be set.
      • EPPRegistryPeriodType

        public EPPRegistryPeriodType​(java.lang.Integer aNumber,
                                     EPPRegistryPeriodType.Unit aUnit)
        EPPRegistryPeriodType constructor that takes both the period number as an Integer and unit.
        Parameters:
        aNumber - Period number
        aUnit - Period unit
      • EPPRegistryPeriodType

        public EPPRegistryPeriodType​(int aNumber,
                                     EPPRegistryPeriodType.Unit aUnit)
        EPPRegistryPeriodType constructor that takes both the period number as an int and unit.
        Parameters:
        aNumber - Period number
        aUnit - Period unit
    • Method Detail

      • getRootName

        protected java.lang.String getRootName()
        Gets the root element local name.
        Returns:
        Root element local name.
      • encode

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

        public void decode​(org.w3c.dom.Element aElement)
                    throws EPPDecodeException
        Decode the EPPRegistryPeriodType attributes from the aElement DOM Element tree.
        Specified by:
        decode in interface EPPCodecComponent
        Parameters:
        aElement - Root DOM Element to decode EPPRegistryPeriodType from.
        Throws:
        EPPDecodeException - Unable to decode aElement
      • equals

        public boolean equals​(java.lang.Object aObject)
        implements a deep EPPRegistryPeriodType compare.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        aObject - EPPRegistryPeriodType instance to compare with
        Returns:
        true if this object is the same as the aObject argument; false otherwise
      • clone

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

        public java.lang.Integer getNumber()
        Gets the period number.
        Returns:
        Period number if defined; null otherwise.
      • setNumber

        public void setNumber​(java.lang.Integer aNumber)
        Sets the period number.
        Parameters:
        aNumber - Period number