Class EPPMaintenanceType

  • All Implemented Interfaces:
    EPPCodecComponent, java.io.Serializable, java.lang.Cloneable

    public class EPPMaintenanceType
    extends java.lang.Object
    implements EPPCodecComponent
    Type of the maintenance that has the possible set of values defined by server policy, such as "Routine Maintenance", "Software Update", "Software Upgrade", or "Extended Outage".
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String DEFAULT_LANG
      Default language
      static java.lang.String ELM_LOCALNAME
      XML local name for EPPMaintenanceType.
      static java.lang.String ELM_NAME
      XML root tag for EPPMaintenance.
    • Constructor Summary

      Constructors 
      Constructor Description
      EPPMaintenanceType()
      Default constructor for EPPMaintenanceType.
      EPPMaintenanceType​(java.lang.String aType)
      Constructor for EPPMaintenanceType with the required attribute as a parameter.
      EPPMaintenanceType​(java.lang.String aType, java.lang.String aLang)
      Constructor for EPPMaintenanceType with all of the attributes as parameters.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object clone()
      Clone EPPMaintenanceType.
      void decode​(org.w3c.dom.Element aElement)
      Decode the EPPMaintenanceType 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 EPPMaintenanceType instance.
      boolean equals​(java.lang.Object aObject)
      implements a deep EPPMaintenanceType compare.
      java.lang.String getLang()
      Gets the type language value.
      java.lang.String getNamespace()
      Returns the XML namespace associated with the EPPCodecComponent.
      java.lang.String getType()
      Gets the maintenance type
      boolean hasLang()
      Is the type language defined with a non-default value?
      void setLang​(java.lang.String aLang)
      Sets the type language value.
      void setType​(java.lang.String aType)
      Sets the maintenance type
      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

      • DEFAULT_LANG

        public static final java.lang.String DEFAULT_LANG
        Default language
        See Also:
        Constant Field Values
      • ELM_LOCALNAME

        public static final java.lang.String ELM_LOCALNAME
        XML local name for EPPMaintenanceType.
        See Also:
        Constant Field Values
      • ELM_NAME

        public static final java.lang.String ELM_NAME
        XML root tag for EPPMaintenance.
        See Also:
        Constant Field Values
    • Constructor Detail

      • EPPMaintenanceType

        public EPPMaintenanceType()
        Default constructor for EPPMaintenanceType. The required attributes need to be set. The lang attribute defaults to DEFAULT_LANG.
      • EPPMaintenanceType

        public EPPMaintenanceType​(java.lang.String aType)
        Constructor for EPPMaintenanceType with the required attribute as a parameter.
        Parameters:
        aType - Type value
      • EPPMaintenanceType

        public EPPMaintenanceType​(java.lang.String aType,
                                  java.lang.String aLang)
        Constructor for EPPMaintenanceType with all of the attributes as parameters.
        Parameters:
        aType - Type value
        aLang - Language of the type
    • Method Detail

      • getType

        public java.lang.String getType()
        Gets the maintenance type
        Returns:
        The type of the maintenance if defined; null otherwise.
      • setType

        public void setType​(java.lang.String aType)
        Sets the maintenance type
        Parameters:
        aType - Type of the maintenance
      • hasLang

        public boolean hasLang()
        Is the type language defined with a non-default value?
        Returns:
        true if the type language is defined; false otherwise.
      • getLang

        public java.lang.String getLang()
        Gets the type language value.
        Returns:
        Type language if defined; DEFAULT_LANG otherwise.
      • setLang

        public void setLang​(java.lang.String aLang)
        Sets the type language value.
        Parameters:
        aLang - Type language for value.
      • encode

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

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

        public boolean equals​(java.lang.Object aObject)
        implements a deep EPPMaintenanceType compare.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        aObject - EPPMaintenanceType instance to compare with
        Returns:
        true of aObject is equal to instance; false otherwise.
      • clone

        public java.lang.Object clone()
                               throws java.lang.CloneNotSupportedException
        Clone EPPMaintenanceType.
        Specified by:
        clone in interface EPPCodecComponent
        Overrides:
        clone in class java.lang.Object
        Returns:
        clone of EPPMaintenanceType
        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.
      • getNamespace

        public java.lang.String getNamespace()
        Returns the XML namespace associated with the EPPCodecComponent.
        Specified by:
        getNamespace in interface EPPCodecComponent
        Returns:
        XML namespace for the EPPCodecComponent.