Class EPPHostCheckResult

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

    public class EPPHostCheckResult
    extends java.lang.Object
    implements EPPCodecComponent
    EPPHostCheckResult represents the result of an individual host name check. The attributes of EPPHostCheckResult include the domain name and a boolean value indicating if the domain name is available. host reason must be set before invoking encode if the available flag is set to false.

    See Also:
    EPPHostCheckResp, Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      EPPHostCheckResult()
      Default constructor for EPPHostCheckResult.
      EPPHostCheckResult​(java.lang.String aName, boolean isAvailable)
      Constructor for EPPHostCheckResult that includes the domain name and the is known flag.
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      java.lang.Object clone()
      Clone EPPHostCheckResult.
      void decode​(org.w3c.dom.Element aElement)
      Decode the EPPHostCheckResult 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 EPPHostCheckResult instance.
      boolean equals​(java.lang.Object aObject)
      Compare an instance of EPPHostCheckResult with this instance.
      java.lang.String getHostReason()
      Gets host reason.
      java.lang.String getLanguage()
      Sets domain reason to check.
      java.lang.String getName()
      Gets the domain name associated with the result.
      java.lang.String getNamespace()
      Returns the XML namespace associated with the EPPCodecComponent.
      boolean isAvailable()
      Gets if the domain associated with EPPHostCheckResult is availability (can it be provisioned or not) at the moment the <check> command was completed.
      boolean isKnown()
      Deprecated.
      As of EPP 1.0, replaced with isAvailable().
      void setHostReason​(java.lang.String aReason)
      Sets host reason.
      void setIsAvailable​(boolean aIsAvailable)
      Sets if the host associated with EPPHostCheckResult is availability (can it be provisioned or not) at the moment the <check> command was completed.
      void setIsKnown​(boolean aIsKnown)
      Deprecated.
      As of EPP 1.0, replaced with setIsAvailable(boolean).
      void setLanguage​(java.lang.String aLang)
      Sets language attribute.
      void setName​(java.lang.String aName)
      Sets the domain name associated with the result.
      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
    • Constructor Detail

      • EPPHostCheckResult

        public EPPHostCheckResult()
        Default constructor for EPPHostCheckResult. the defaults include the following:

        • name is set to null
        • known is set to false

        The name must be set before invoking encode.
      • EPPHostCheckResult

        public EPPHostCheckResult​(java.lang.String aName,
                                  boolean isAvailable)
        Constructor for EPPHostCheckResult that includes the domain name and the is known flag.
        Parameters:
        aName - Domain name associated with result
        isAvailable - Is the domain name available?
    • Method Detail

      • getName

        public java.lang.String getName()
        Gets the domain name associated with the result.
        Returns:
        Domain name associated with the result if defined; null otherwise.
      • setName

        public void setName​(java.lang.String aName)
        Sets the domain name associated with the result.
        Parameters:
        aName - Domain Name associated with the result.
      • isKnown

        @Deprecated
        public boolean isKnown()
        Deprecated.
        As of EPP 1.0, replaced with isAvailable().
        Gets if the domain associated with EPPHostCheckResult is known.
        Returns:
        Is the domain known?
      • setIsKnown

        @Deprecated
        public void setIsKnown​(boolean aIsKnown)
        Deprecated.
        As of EPP 1.0, replaced with setIsAvailable(boolean).
        Sets if the domain associated with EPPHostCheckResult is known.
        Parameters:
        aIsKnown - Is the domain known?
      • isAvailable

        public boolean isAvailable()
        Gets if the domain associated with EPPHostCheckResult is availability (can it be provisioned or not) at the moment the <check> command was completed.
        Returns:
        Is the host available? If false, call getHostReason() for inavailability reason.
      • setIsAvailable

        public void setIsAvailable​(boolean aIsAvailable)
        Sets if the host associated with EPPHostCheckResult is availability (can it be provisioned or not) at the moment the <check> command was completed.
        Parameters:
        aIsAvailable - Is the host available?
      • setHostReason

        public void setHostReason​(java.lang.String aReason)
        Sets host reason.
        Parameters:
        aReason - Host Reason.
      • getHostReason

        public java.lang.String getHostReason()
        Gets host reason.
        Returns:
        String of host reason.
      • setLanguage

        public void setLanguage​(java.lang.String aLang)
        Sets language attribute.
        Parameters:
        aLang - Sets value of language attribute.
      • getLanguage

        public java.lang.String getLanguage()
        Sets domain reason to check.
        Returns:
        String of language attribute.
      • encode

        public org.w3c.dom.Element encode​(org.w3c.dom.Document aDocument)
                                   throws EPPEncodeException
        Encode a DOM Element tree from the attributes of the EPPHostCheckResult 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 EPPHostCheckResult instance.
        Throws:
        EPPEncodeException - Unable to encode EPPHostCheckResult instance.
      • decode

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

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

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