Interface TerminalInformation
-
- All Superinterfaces:
Cloneable,DiameterAvp,GroupedAvp
public interface TerminalInformation extends GroupedAvp
Defines an interface representing the Terminal-Information grouped AVP type. From the Diameter Ro Reference Point Protocol Details (3GPP TS 32.299 V11.8.0) specification:7.3.3 Terminal-Information The Terminal-Information AVP is of type Grouped. This AVP shall contain the information about the user’s terminal. AVP format: Terminal-Information ::= < AVP Header: 1401 > [ IMEI ] [ TGPP2-MEID ] [ Software-Version ] * [ AVP ]
-
-
Field Summary
-
Fields inherited from interface org.jainslee.resources.diameter.base.DiameterAvp
FLAG_RULE_MAY, FLAG_RULE_MUST, FLAG_RULE_MUSTNOT
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DiameterAvp[]getExtensionAvps()Returns the set of extension AVPs.StringgetImei()Returns the value of the IMEI AVP, of type UTF8String.StringgetSoftwareVersion()Returns the value of the Software-Version AVP, of type UTF8String.byte[]getTgpp2Meid()Returns the value of the TGPP2-MEID AVP, of type OctetString.booleanhasImei()Returns true if the IMEI AVP is present in the Terminal-Information AVP.booleanhasSoftwareVersion()Returns true if the Software-Version AVP is present in the Terminal-Information AVP.booleanhasTgpp2Meid()Returns true if the TGPP2-MEID AVP is present in the Terminal-Information AVP.voidremoveExtensionAvps()Removes all extension AVPs from the Terminal-Information AVP.voidremoveImei()Removes the IMEI AVP from the Terminal-Information AVP.voidremoveSoftwareVersion()Removes the Software-Version AVP from the Terminal-Information AVP.voidremoveTgpp2Meid()Removes the TGPP2-MEID AVP from the Terminal-Information AVP.voidsetExtensionAvps(DiameterAvp[] avps)Sets the set of extension AVPs with all the values in the given array.voidsetImei(String imei)Sets the value of the IMEI AVP, of type UTF8String.voidsetSoftwareVersion(String softwareVersion)Sets the value of the Software-Version AVP, of type UTF8String.voidsetTgpp2Meid(byte[] tgpp2Meid)Sets the value of the TGPP2-MEID AVP, of type OctetString.-
Methods inherited from interface org.jainslee.resources.diameter.base.DiameterAvp
byteArrayValue, clone, doubleValue, floatValue, getCode, getMandatoryRule, getName, getProtectedRule, getType, getVendorID, groupedAvpValue, intValue, longValue, stringValue
-
-
-
-
Method Detail
-
hasImei
boolean hasImei()
Returns true if the IMEI AVP is present in the Terminal-Information AVP.
-
getImei
String getImei()
Returns the value of the IMEI AVP, of type UTF8String.- Returns:
- the value of the IMEI AVP, or null if it has not been set.
-
setImei
void setImei(String imei)
Sets the value of the IMEI AVP, of type UTF8String.- Throws:
NullPointerException- ifimeiisnull.
-
removeImei
void removeImei()
Removes the IMEI AVP from the Terminal-Information AVP. If the IMEI AVP is not present, this method returns silently.
-
hasTgpp2Meid
boolean hasTgpp2Meid()
Returns true if the TGPP2-MEID AVP is present in the Terminal-Information AVP.
-
getTgpp2Meid
byte[] getTgpp2Meid()
Returns the value of the TGPP2-MEID AVP, of type OctetString.- Returns:
- the value of the TGPP2-MEID AVP, or null if it has not been set.
-
setTgpp2Meid
void setTgpp2Meid(byte[] tgpp2Meid)
Sets the value of the TGPP2-MEID AVP, of type OctetString.- Throws:
NullPointerException- iftgpp2Meidisnull.
-
removeTgpp2Meid
void removeTgpp2Meid()
Removes the TGPP2-MEID AVP from the Terminal-Information AVP. If the TGPP2-MEID AVP is not present, this method returns silently.
-
hasSoftwareVersion
boolean hasSoftwareVersion()
Returns true if the Software-Version AVP is present in the Terminal-Information AVP.
-
getSoftwareVersion
String getSoftwareVersion()
Returns the value of the Software-Version AVP, of type UTF8String.- Returns:
- the value of the Software-Version AVP, or null if it has not been set.
-
setSoftwareVersion
void setSoftwareVersion(String softwareVersion)
Sets the value of the Software-Version AVP, of type UTF8String.- Throws:
NullPointerException- ifsoftwareVersionisnull.
-
removeSoftwareVersion
void removeSoftwareVersion()
Removes the Software-Version AVP from the Terminal-Information AVP. If the Software-Version AVP is not present, this method returns silently.
-
getExtensionAvps
DiameterAvp[] getExtensionAvps()
Returns the set of extension AVPs. The returned array contains the extension AVPs in the order they appear in the Terminal-Information AVP. A return value of null implies that no extensions AVPs have been set.
-
setExtensionAvps
void setExtensionAvps(DiameterAvp[] avps) throws AvpNotAllowedException
Sets the set of extension AVPs with all the values in the given array. The AVPs will be added to Terminal-Information AVP in the order in which they appear in the array. Note: the array must not be altered by the caller following this call, and getExtensionAvps() is not guaranteed to return the same array instance, e.g. an "==" check would fail.- Throws:
AvpNotAllowedException- if an AVP is encountered of a type already known to this class (i.e. an AVP for which get/set methods already appear in this class)NullPointerException- ifavpsisnull.
-
removeExtensionAvps
void removeExtensionAvps()
Removes all extension AVPs from the Terminal-Information AVP. If no extension AVPs are present, this method returns silently.
-
-