|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.diameter.charging.util.UsedServiceUnit
public class UsedServiceUnit
UsedServiceUnit is a lightweight representation of the Grouped [Used-Service-Unit] Avp. It reports how many units of quota has been used since the service became active or how many units of quota has been used since the last interim/update.
The [Used-Service-Unit] Avp is defined in RFC 4006 - Diameter Credit-Control Application.
Constructor Summary | |
---|---|
UsedServiceUnit()
Constructs an empty UsedServiceUnit object representing the [Used-Service-Unit] Avp. |
|
UsedServiceUnit(java.util.List<Avp> avps)
Constructs a UsedServiceUnit object representing the Grouped [Used-Service-Unit] Avp. |
Method Summary | |
---|---|
java.lang.Long |
getCcInputOctets()
Gets the value corresponding to the payload of the [CC-Input-Octets] Avp. |
java.lang.Long |
getCcOutputOctets()
Gets the value corresponding to the payload of the [CC-Output-Octets] Avp. |
java.lang.Long |
getCcServiceSpecificUnits()
Gets the value corresponding to the payload of the [CC-Service-Specific-Units] Avp. |
java.lang.Integer |
getCcTime()
Gets the value corresponding to the payload of the [CC-Time] Avp. |
java.lang.Long |
getCcTotalOctets()
Gets the value corresponding to the payload of the [CC-Total-Octets] Avp. |
java.lang.Long |
getTariffTimeChange()
Gets the value corresponding to the payload of the [Tariff-Time-Change] Avp. |
void |
setCcInputOctets(java.lang.Long ccInputOctets)
Sets the value corresponding to the payload of the [CC-Input-Octets] Avp. |
void |
setCcOutputOctets(java.lang.Long ccOutputOctets)
Sets the value corresponding to the payload of the [CC-Output-Octets] Avp. |
void |
setCcServiceSpecificUnits(java.lang.Long ccServiceSpecificUnits)
Sets the value corresponding to the payload of the [CC-Service-Specific-Units] Avp. |
void |
setCcTime(java.lang.Integer ccTime)
Sets the value corresponding to the payload of the [CC-Time] Avp. |
void |
setCcTotalOctets(java.lang.Long ccTotalOctets)
Sets the value corresponding to the payload of the [CC-Total-Octets] Avp. |
void |
setTariffTimeChange(java.lang.Long tariffTimeChange)
Sets the value corresponding to the payload of the [Tariff-Time-Change] Avp. |
Avp |
toAvp()
Transforms a UsedServiceUnit object into a Grouped [Used-Service-Unit] Avp. |
void |
validate()
Validates the members of the UsedServiceUnit object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UsedServiceUnit()
public UsedServiceUnit(java.util.List<Avp> avps) throws AvpTransformationException
The method takes a List of Avps as an input. If an Avp code inside the list corresponds to a member of UsedServiceUnit, the member will be populated with the Avp value during construction. If an Avp code is unknown, the value will be silently discarded.
avps
- a list of Avps that can appear in the Grouped
[Used-Service-Unit] Avp.
AvpTransformationException
- if the Avp value is in an unexpected format.Method Detail |
---|
public java.lang.Long getCcInputOctets()
public void setCcInputOctets(java.lang.Long ccInputOctets)
ccInputOctets
- the value corresponding to the payload of the [CC-Input-Octets] Avp.public java.lang.Long getCcOutputOctets()
public void setCcOutputOctets(java.lang.Long ccOutputOctets)
ccOutputOctets
- the value corresponding to the payload of the [CC-Output-Octets] Avp.public java.lang.Long getCcServiceSpecificUnits()
public void setCcServiceSpecificUnits(java.lang.Long ccServiceSpecificUnits)
ccServiceSpecificUnits
- the value corresponding to the payload of the [CC-Service-Specific-Units] Avp.public java.lang.Integer getCcTime()
public void setCcTime(java.lang.Integer ccTime)
ccTime
- the value corresponding to the payload of the [CC-Time] Avp.public java.lang.Long getCcTotalOctets()
public void setCcTotalOctets(java.lang.Long ccTotalOctets)
ccTotalOctets
- the value corresponding to the payload of the [CC-Total-Octets] Avp.public java.lang.Long getTariffTimeChange()
public void setTariffTimeChange(java.lang.Long tariffTimeChange)
tariffTimeChange
- the value corresponding to the payload of the [Tariff-Time-Change] Avp.public void validate() throws ChargingValidationException
ChargingValidationException
- if a member of UsedServiceUnit is in an unexpected format.public Avp toAvp() throws AvpTransformationException
All non-null members of UsedServiceUnit will be transformed into Avps nested inside of the [Used-Service-Unit] Avp.
AvpTransformationException
- if a member of UsedServiceUnit is in an
unexpected format.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |