Class EPPFeeTransform

    • Constructor Summary

      Constructors 
      Constructor Description
      EPPFeeTransform()
      Default constructor for EPPFeeTransform.
      EPPFeeTransform​(EPPFeeValue aFee)
      Constructor for EPPFeeTransform that takes a single fee.
      EPPFeeTransform​(EPPFeeValue aFee, java.lang.String aCurrency)
      Constructor for EPPFeeTransform that takes a single fee and the optional currency.
      EPPFeeTransform​(java.util.List<EPPFeeValue> aFees, java.lang.String aCurrency)
      Constructor for EPPFeeTransform that takes all attributes.
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      void addFee​(EPPFeeValue aFee)
      Adds a fee to the list of fees.
      java.lang.Object clone()
      clone an EPPCodecComponent.
      void decode​(org.w3c.dom.Element aElement)
      Decode a DOM element tree to initialize the instance attributes.
      org.w3c.dom.Element encode​(org.w3c.dom.Document aDocument)
      Encode instance into a DOM element tree.
      boolean equals​(java.lang.Object aObject)
      Compare an instance of EPPFeeTransform with this instance.
      java.lang.String getCurrency()
      Gets the currency value.
      java.util.List<EPPFeeValue> getFees()
      Gets the list of fees if defined.
      protected abstract java.lang.String getLocalName()
      Abstract method that the sub-class must define to return the local name for the root element.
      boolean hasCurrency()
      Is the currency defined?
      boolean hasFees()
      Are the fees defined?
      void setCurrency​(java.lang.String aCurrency)
      Sets the currency value.
      void setFees​(java.util.List<EPPFeeValue> aFees)
      Sets the list of fees.
      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

      • EPPFeeTransform

        public EPPFeeTransform()
        Default constructor for EPPFeeTransform.
      • EPPFeeTransform

        public EPPFeeTransform​(EPPFeeValue aFee)
        Constructor for EPPFeeTransform that takes a single fee.
        Parameters:
        aFee - A single fee of the transform command
      • EPPFeeTransform

        public EPPFeeTransform​(EPPFeeValue aFee,
                               java.lang.String aCurrency)
        Constructor for EPPFeeTransform that takes a single fee and the optional currency.
        Parameters:
        aFee - A single fee of the transform command
        aCurrency - Currency of the fee
      • EPPFeeTransform

        public EPPFeeTransform​(java.util.List<EPPFeeValue> aFees,
                               java.lang.String aCurrency)
        Constructor for EPPFeeTransform that takes all attributes.
        Parameters:
        aFees - The fees of the transform command
        aCurrency - Currency of the fees
    • Method Detail

      • getLocalName

        protected abstract java.lang.String getLocalName()
        Abstract method that the sub-class must define to return the local name for the root element.
        Returns:
        Local name of the root element of the transform command.
      • hasCurrency

        public boolean hasCurrency()
        Is the currency defined?
        Returns:
        true if the currency is defined; false otherwise.
      • getCurrency

        public java.lang.String getCurrency()
        Gets the currency value.
        Returns:
        Currency if defined; null otherwise.
      • setCurrency

        public void setCurrency​(java.lang.String aCurrency)
        Sets the currency value.
        Parameters:
        aCurrency - Currency value
      • hasFees

        public boolean hasFees()
        Are the fees defined?
        Returns:
        true if the fees are defined; false otherwise.
      • getFees

        public java.util.List<EPPFeeValue> getFees()
        Gets the list of fees if defined.
        Returns:
        List of fees if defined; empty list otherwise.
      • addFee

        public void addFee​(EPPFeeValue aFee)
        Adds a fee to the list of fees.
        Parameters:
        aFee - The fee to add.
      • setFees

        public void setFees​(java.util.List<EPPFeeValue> aFees)
        Sets the list of fees.
        Parameters:
        aFees - The fees to set.
      • encode

        public org.w3c.dom.Element encode​(org.w3c.dom.Document aDocument)
                                   throws EPPEncodeException
        Encode instance into a DOM element tree. A DOM Document is passed as an argument and functions as a factory for DOM objects. The root element associated with the instance is created and each instance attribute is appended as a child node.
        Specified by:
        encode in interface EPPCodecComponent
        Parameters:
        aDocument - DOM Document, which acts is an Element factory
        Returns:
        Element Root element associated with the object
        Throws:
        EPPEncodeException - Error encoding EPPFeeTransform
      • decode

        public void decode​(org.w3c.dom.Element aElement)
                    throws EPPDecodeException
        Decode a DOM element tree to initialize the instance attributes. The aElement argument represents the root DOM element and is used to traverse the DOM nodes for instance attribute values.
        Specified by:
        decode in interface EPPCodecComponent
        Parameters:
        aElement - Element to decode
        Throws:
        EPPDecodeException - Error decoding Element
      • clone

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

        public boolean equals​(java.lang.Object aObject)
        Compare an instance of EPPFeeTransform with this instance.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        aObject - Object to compare with.
        Returns:
        true if equal; false otherwise.