Interface LocationType
-
- All Superinterfaces:
Cloneable
,DiameterAvp
,GroupedAvp
public interface LocationType extends GroupedAvp
Defines an interface representing the Location-Type grouped AVP type. From the Diameter Ro Reference Point Protocol Details (3GPP TS 32.299 V12.11.0) specification:7.2.96 Location-Type AVP The Location-Type AVP (AVP code 1244) is of type Grouped and indicates the type of location estimate required by the LCS client. It has the following ABNF grammar: Location-Type ::= < AVP Header: 1244> [ Location-Estimate-Type ] [ Deferred-Location-Event-Type ]
Note:
The support for extension AVPs is present even thou the ABNF grammar for this AVP does not contain the "* [ AVP ]" line. Be aware that adding any extension AVPs may result in interoperability problems with products that strongly validate the incoming diameter message for it's adherence to the specification.
-
-
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 String
getDeferredLocationEventType()
Returns the value of the Deferred-Location-Event-Type AVP, of type UTF8String.DiameterAvp[]
getExtensionAvps()
Returns the set of extension AVPs.LocationEstimateType
getLocationEstimateType()
Returns the value of the Location-Estimate-Type AVP, of type Enumerated.boolean
hasDeferredLocationEventType()
Returns true if the Deferred-Location-Event-Type AVP is present in the Location-Type AVP.boolean
hasLocationEstimateType()
Returns true if the Location-Estimate-Type AVP is present in the Location-Type AVP.void
removeDeferredLocationEventType()
Removes the Deferred-Location-Event-Type AVP from the Location-Type AVP.void
removeExtensionAvps()
Removes all extension AVPs from the Location-Type AVP.void
removeLocationEstimateType()
Removes the Location-Estimate-Type AVP from the Location-Type AVP.void
setDeferredLocationEventType(String deferredLocationEventType)
Sets the value of the Deferred-Location-Event-Type AVP, of type UTF8String.void
setExtensionAvps(DiameterAvp[] avps)
Sets the set of extension AVPs with all the values in the given array.void
setLocationEstimateType(LocationEstimateType locationEstimateType)
Sets the value of the Location-Estimate-Type AVP, of type Enumerated.-
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
-
hasLocationEstimateType
boolean hasLocationEstimateType()
Returns true if the Location-Estimate-Type AVP is present in the Location-Type AVP.
-
getLocationEstimateType
LocationEstimateType getLocationEstimateType()
Returns the value of the Location-Estimate-Type AVP, of type Enumerated.- Returns:
- the value of the Location-Estimate-Type AVP, or null if it has not been set.
-
setLocationEstimateType
void setLocationEstimateType(LocationEstimateType locationEstimateType)
Sets the value of the Location-Estimate-Type AVP, of type Enumerated.- Throws:
NullPointerException
- iflocationEstimateType
isnull
.
-
removeLocationEstimateType
void removeLocationEstimateType()
Removes the Location-Estimate-Type AVP from the Location-Type AVP. If the Location-Estimate-Type AVP is not present, this method returns silently.
-
hasDeferredLocationEventType
boolean hasDeferredLocationEventType()
Returns true if the Deferred-Location-Event-Type AVP is present in the Location-Type AVP.
-
getDeferredLocationEventType
String getDeferredLocationEventType()
Returns the value of the Deferred-Location-Event-Type AVP, of type UTF8String.- Returns:
- the value of the Deferred-Location-Event-Type AVP, or null if it has not been set.
-
setDeferredLocationEventType
void setDeferredLocationEventType(String deferredLocationEventType)
Sets the value of the Deferred-Location-Event-Type AVP, of type UTF8String.- Throws:
NullPointerException
- ifdeferredLocationEventType
isnull
.
-
removeDeferredLocationEventType
void removeDeferredLocationEventType()
Removes the Deferred-Location-Event-Type AVP from the Location-Type AVP. If the Deferred-Location-Event-Type 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 Location-Type 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 Location-Type 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
- ifavps
isnull
.
-
removeExtensionAvps
void removeExtensionAvps()
Removes all extension AVPs from the Location-Type AVP. If no extension AVPs are present, this method returns silently.
-
-