Class EPPMaintenanceInfoResp

java.lang.Object
com.verisign.epp.codec.gen.EPPResponse
com.verisign.epp.codec.maintenance.v1_0.EPPMaintenanceInfoResp
All Implemented Interfaces:
EPPCodecComponent, EPPMessage, Serializable, Cloneable

public class EPPMaintenanceInfoResp extends EPPResponse
Response information associated with a EPPMaintenanceInfoCmd of type EPPMaintenanceInfoCmd.InfoType.id, which will only include a single element, and of type EPPMaintenanceInfoCmd.InfoType.id that can include a list of zero or more maintenances items (EPPMaintenanceListItem).
See Also:
  • Field Details

  • Constructor Details

    • EPPMaintenanceInfoResp

      public EPPMaintenanceInfoResp()
      EPPMaintenanceInfoResp default constructor. The infoType will default to InfoType.list.
    • EPPMaintenanceInfoResp

      public EPPMaintenanceInfoResp(EPPTransId aTransId)
      EPPMaintenanceInfoResp constructor that only takes the transaction identifier.
      Parameters:
      aTransId - Transaction Id associated with response.
    • EPPMaintenanceInfoResp

      public EPPMaintenanceInfoResp(EPPTransId aTransId, EPPMaintenanceItem aMaintenance)
      EPPMaintenanceInfoResp constructor that only takes the transaction identifier and the maintenance, which will set the infoType to InfoType#maintenance.
      Parameters:
      aTransId - Transaction Id associated with command. Set to null if a client transaction identifier is not desired.
      aMaintenance - Maintenance object
    • EPPMaintenanceInfoResp

      public EPPMaintenanceInfoResp(EPPTransId aTransId, List<EPPMaintenanceListItem> aListItems)
      EPPMaintenanceInfoResp constructor that only takes the transaction identifier and the list of maintenance items, which will set the infoType to EPPMaintenanceInfoResp.InfoType.list.
      Parameters:
      aTransId - Transaction Id associated with command. Set to null if a client transaction identifier is not desired.
      aListItems - Maintenance list items
  • Method Details

    • getInfoType

      public EPPMaintenanceInfoResp.InfoType getInfoType()
      Gets the infoType for the info response.
      Returns:
      the infoType for the info response.
    • setInfoType

      public void setInfoType(EPPMaintenanceInfoResp.InfoType aInfoType)
      Sets the infoType for the info response.
      Parameters:
      aInfoType - The infoType for the info response.
    • hastMaintenance

      public boolean hastMaintenance()
      Is the maintenance defined?
      Returns:
      true if the maintenance is defined; false otherwise.
    • getMaintenance

      public EPPMaintenanceItem getMaintenance()
      Gets the maintenance.
      Returns:
      The maintenance if defined; null otherwise.
    • setMaintenance

      public void setMaintenance(EPPMaintenanceItem aMaintenance)
      Sets the maintenance. When set to a non-null value, the infoType is set to InfoType.maintenance; otherwise infoType is set to InfoType.list.
      Parameters:
      aMaintenance - The maintenance.
    • hasListItems

      public boolean hasListItems()
      Is there any maintenance list items set?
      Returns:
      true if there is at least one EPPMaintenanceListItem set; false otherwise.
    • addListItem

      public void addListItem(EPPMaintenanceListItem aItem)
      Adds a maintenance item to the list of maintenance items.
      Parameters:
      aItem - maintenance item to add to the list of maintenance items.
    • getListItems

      public List<EPPMaintenanceListItem> getListItems()
      Gets the list of maintenance items.
      Returns:
      The list of maintenance items if defined; null otherwise.
    • setListItems

      public void setListItems(List<EPPMaintenanceListItem> aListItmes)
      Sets the list of maintenance items. When set to a non-null value, the infoType is set to InfoType.list; otherwise infoType is set to InfoType.maintenance.
      Parameters:
      aListItmes - the list items to set.
    • doEncode

      protected Element doEncode(Document aDocument) throws EPPEncodeException
      Encode a DOM Element tree from the attributes of the EPPMaintenanceInfoResp instance.
      Overrides:
      doEncode in class EPPResponse
      Parameters:
      aDocument - DOM Document that is being built. Used as an Element factory.
      Returns:
      Element Root DOM Element representing the EPPMaintenanceInfoResp instance.
      Throws:
      EPPEncodeException - Unable to encode EPPMaintenanceInfoResp instance.
    • doDecode

      protected void doDecode(Element aElement) throws EPPDecodeException
      Decode the EPPMaintenanceInfoResp attributes from the aElement DOM Element tree.
      Overrides:
      doDecode in class EPPResponse
      Parameters:
      aElement - Root DOM Element to decode EPPMaintenanceInfoResp from.
      Throws:
      EPPDecodeException - Unable to decode aElement
    • clone

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

      public String getType()
      Gets the EPP response type associated with EPPMaintenanceInfoResp.
      Overrides:
      getType in class EPPResponse
      Returns:
      EPPMaintenanceInfoResp.ELM_NAME
    • getNamespace

      public String getNamespace()
      Gets the EPP command namespace associated with EPPMaintenanceInfoResp .
      Specified by:
      getNamespace in interface EPPCodecComponent
      Specified by:
      getNamespace in interface EPPMessage
      Overrides:
      getNamespace in class EPPResponse
      Returns:
      EPPMaintenanceMapFactory.NS
    • equals

      public boolean equals(Object aObject)
      Compare an instance of EPPMaintenanceInfoResp with this instance.
      Overrides:
      equals in class EPPResponse
      Parameters:
      aObject - Object to compare with.
      Returns:
      true if this object is the same as the aObject argument; false otherwise
    • 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 EPPResponse
      Returns:
      Indented XML String if successful; ERROR otherwise.