Class ChargingMappingModel

java.lang.Object
com.highdeal.pnr.hci.ChargingMappingModel
All Implemented Interfaces:
XMLMarshallable

public class ChargingMappingModel extends Object implements XMLMarshallable
A ChargingMappingModel represents a charging mapping. A chargingMapping is contained in a ChargeActivationModel and managed by subscription operations.

XML API for HCI

The XML APIs specify the following XSD fragment:

XSD Fragment

<xs:element name="chargingMapping">
   <xs:complexType>
     <xs:sequence>
       <xs:element ref="creditLimitItem" minOccurs="0" maxOccurs="unbounded"/>
     </xs:sequence>
     <xs:attribute name="chargingReferenceCode" type="xs:string" use="required"/>
     <xs:attribute name="prepaidAccountCode" type="xs:string"/>
     <xs:attribute name="externalAccountCode" type="xs:string"/>
   </xs:complexType>
 </xs:element>

 <xs:element name="creditLimitItem">
   <xs:complexType>
     <xs:attribute name="name" type="xs:string" use="required"/>
   </xs:complexType>
 </xs:element>

  • Field Details

  • Constructor Details

    • ChargingMappingModel

      public ChargingMappingModel()
      Constructs an empty charging model.
    • ChargingMappingModel

      public ChargingMappingModel(String chargingReference, String prepaidAccount, String externalAccount, Vector<String> creditLimits)
      Initializes a subscriber account with its owner, its code and its subscriber.
      Parameters:
      chargingReference - the code of the charging reference
      prepaidAccount - the prepaid account of the subscriber account
      externalAccount - the external account of the subscriber account
      creditLimits - the list of credit limit balance codes
  • Method Details

    • getChargingReferenceCode

      public String getChargingReferenceCode()
      Returns the code of charging reference.
      Returns:
      This charging reference code.
      See Also:
    • setChargingReferenceCode

      public void setChargingReferenceCode(String chargingReferenceCode)
      Sets the code of charging reference.
      Parameters:
      chargingReferenceCode - String code which represents the code of charging reference.
      See Also:
    • getCreditLimitBalances

      public List<String> getCreditLimitBalances()
      Returns a list of credit limit balances code.
      Returns:
      The list of credit limit balances code.
    • setCreditLimitBalances

      public void setCreditLimitBalances(List<String> creditLimits)
      Sets the list of credit limit balances.
      Parameters:
      creditLimits - List creditLimits which represents the list of credit limit balances code.
    • getExternalAccountCode

      public String getExternalAccountCode()
      Returns the code of the external account.
      Returns:
      The external account code.
    • setExternalAccountCode

      public void setExternalAccountCode(String externalAccountCode)
      Sets the code of the external account.
      Parameters:
      externalAccountCode - String code which represents the code of the external account.
    • getPrepaidAccountCode

      public String getPrepaidAccountCode()
      Returns the code of the prepaid account.
      Returns:
      The prepaid account code.
    • setPrepaidAccountCode

      public void setPrepaidAccountCode(String prepaidAccountCode)
      Sets the code of the prepaid account.
      Parameters:
      prepaidAccountCode - String code which represents the code of the prepaid account.
    • isPrepaidAccount

      public boolean isPrepaidAccount()
      Returns true if the mapping references a prepaid account, false otherwise.
      Returns:
      true if its a prepaid mapping.
    • isExternalAccount

      public boolean isExternalAccount()
      Returns true if the mapping references a external account, false otherwise.
      Returns:
      true if its an external mapping.
    • isValid

      public boolean isValid()
      Returns true if the model is valid, false otherwise.
      Returns:
      true or false.
    • setAttributes

      public void setAttributes(XMLAttributes atts)
      Description copied from interface: XMLMarshallable
      Sets the attributes of the XML representation of the element being processed.
      Specified by:
      setAttributes in interface XMLMarshallable
      Parameters:
      atts - The XML attributes of the current element
    • addChild

      public void addChild(String name, XMLMarshallable child)
      Description copied from interface: XMLMarshallable
      Adds a child to the object, the child representing the marshallable object which must be added to the element.
      Specified by:
      addChild in interface XMLMarshallable
      Parameters:
      name - The name of tag for the child
      child - The child to be added
    • addCharacterData

      public void addCharacterData(String cData)
      Description copied from interface: XMLMarshallable
      Adds character data to the content element.
      Specified by:
      addCharacterData in interface XMLMarshallable
      Parameters:
      cData - The character data to be added
    • marshal

      public void marshal(XMLOutputter output)
      Description copied from interface: XMLMarshallable
      Gives an XML representation of this object, including its children.
      Specified by:
      marshal in interface XMLMarshallable
      Parameters:
      output - The XML output to marshal the object into