Class EPPNameWatchRptTo

java.lang.Object
com.verisign.epp.codec.nameWatch.EPPNameWatchRptTo
All Implemented Interfaces:
EPPCodecComponent, Serializable, Cloneable

public class EPPNameWatchRptTo extends Object implements EPPCodecComponent
Specifies the e-mail address to send the NameWatch reports and the frequency of the reports.

See Also:
  • Field Details

  • Constructor Details

    • EPPNameWatchRptTo

      public EPPNameWatchRptTo()
      EPPNameWatchRptTo default constructor. The period is initialized to unspecified. The period must be set before invoking encode.
    • EPPNameWatchRptTo

      public EPPNameWatchRptTo(String aRptTo)
      EPPNameWatchRptTo constructor that takes the nameWatch e-mail address to report to. The frequency is set to RPTTO_FREQ_DAILY.
      Parameters:
      aRptTo - e-mail address to report to.
    • EPPNameWatchRptTo

      public EPPNameWatchRptTo(String aFreqType, String aRptTo)
      EPPNameWatchRptTo constructor that takes the nameWatch frequency and namewatch e-mail address to report to.
      Parameters:
      aFreqType - Report frequency, which should be one of the RPTTO_FREQ_ constant values. If null, it will be set to RPTTO_FREQ_DAILY by default.
      aRptTo - E-mail address to report to.
  • Method Details

    • clone

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

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

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

      public boolean equals(Object aObject)
      implements a deep EPPNameWatchRptTo compare.
      Overrides:
      equals in class Object
      Parameters:
      aObject - EPPNameWatchRptTo instance to compare with
      Returns:
      DOCUMENT ME!
    • getRptTo

      public String getRptTo()
      Gets the email address to report to.
      Returns:
      Report to e-mail address if defined; null otherwise.
    • getFreqType

      public String getFreqType()
      Get nameWatch report frequency.
      Returns:
      Report frequency, which should be one of the RPTTO_FREQ_ constant values.
    • isRptToUnspec

      public boolean isRptToUnspec()
      Test whether the report to attribute is unspecified.
      Returns:
      true is unspecified and false is specified.
    • setRptTo

      public void setRptTo(String newRptTo) throws EPPCodecException
      Sets the namewatch e-mail address to report to.
      Parameters:
      newRptTo - e-mail address to report to
      Throws:
      EPPCodecException - Format error
    • setFreqType

      public void setFreqType(String newFreqType)
      Sets the frequency of the report.
      Parameters:
      newFreqType - Should be one of the RPTTO_FREQ_ constant values.
    • 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 Object
      Returns:
      Indented XML String if successful; ERROR otherwise.
    • getNamespace

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