Class IntegerAttribute
java.lang.Object
org.tinyradius.core.attribute.type.OctetsAttribute
org.tinyradius.core.attribute.type.IntegerAttribute
- All Implemented Interfaces:
RadiusAttribute
This class represents a Radius attribute which only contains a 32 bit integer.
-
Constructor Summary
ConstructorDescriptionIntegerAttribute
(Dictionary dictionary, int vendorId, io.netty.buffer.ByteBuf data) -
Method Summary
Modifier and TypeMethodDescriptionint
long
Returns the value of this attribute as a string.static byte[]
stringParser
(Dictionary dictionary, int vendorId, int type, String value) Methods inherited from class org.tinyradius.core.attribute.type.OctetsAttribute
encode, equals, getData, getDictionary, getTag, getValue, getVendorId, hashCode, stringHexParser, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.tinyradius.core.attribute.type.RadiusAttribute
decode, flatten, getAttributeName, getAttributeTemplate, getHeaderSize, getLength, getLengthSize, getTagSize, getType, getTypeSize, getVendor, isEncoded, isTagged, toByteArray, toByteBuf
-
Constructor Details
-
IntegerAttribute
-
-
Method Details
-
getValueLong
public long getValueLong()- Returns:
- long value of this attribute (unsigned int)
-
getValueInt
public int getValueInt()- Returns:
- int value of this attribute. May be negative as Java ints are signed.
-
getValueString
Returns the value of this attribute as a string. Tries to resolve enumerations.- Specified by:
getValueString
in interfaceRadiusAttribute
- Overrides:
getValueString
in classOctetsAttribute
- Returns:
- value of this attribute as a hex string.
-
stringParser
-