|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.tinyradius.dictionary.AttributeType
public class AttributeType
Represents a Radius attribute type.
Constructor Summary | |
---|---|
AttributeType(int vendor,
int code,
java.lang.String name,
java.lang.Class type)
Constructs a Vendor-Specific sub-attribute type. |
|
AttributeType(int code,
java.lang.String name,
java.lang.Class type)
Create a new attribute type. |
Method Summary | |
---|---|
void |
addEnumerationValue(int num,
java.lang.String name)
Adds a name for an integer value of this attribute. |
java.lang.Class |
getAttributeClass()
Retrieves the RadiusAttribute descendant class which represents attributes of this type. |
java.lang.String |
getEnumeration(int value)
Returns the name of the given integer value if this attribute is an enumeration, or null if it is not or if the integer value is unknown. |
java.lang.Integer |
getEnumeration(java.lang.String value)
Returns the number of the given string value if this attribute is an enumeration, or null if it is not or if the string value is unknown. |
java.lang.String |
getName()
Retrieves the name of this type. |
int |
getTypeCode()
Retrieves the Radius type code for this attribute type. |
int |
getVendorId()
Returns the vendor ID. |
void |
setAttributeClass(java.lang.Class type)
Sets the RadiusAttribute descendant class which represents attributes of this type. |
void |
setName(java.lang.String name)
Sets the name of this type. |
void |
setTypeCode(int code)
Sets the Radius type code for this attribute type. |
void |
setVendorId(int vendorId)
Sets the vendor ID. |
java.lang.String |
toString()
String representation of AttributeType object for debugging purposes. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AttributeType(int code, java.lang.String name, java.lang.Class type)
code
- Radius attribute type codename
- Attribute type nametype
- RadiusAttribute descendant who handles
attributes of this typepublic AttributeType(int vendor, int code, java.lang.String name, java.lang.Class type)
vendor
- vendor IDcode
- sub-attribute type codename
- sub-attribute nametype
- sub-attribute classMethod Detail |
---|
public int getTypeCode()
public void setTypeCode(int code)
code
- type code, 1-255public java.lang.String getName()
public void setName(java.lang.String name)
name
- type namepublic java.lang.Class getAttributeClass()
public void setAttributeClass(java.lang.Class type)
public int getVendorId()
public void setVendorId(int vendorId)
vendorId
- vendor IDpublic java.lang.String getEnumeration(int value)
public java.lang.Integer getEnumeration(java.lang.String value)
value
- string value
public void addEnumerationValue(int num, java.lang.String name)
num
- number that shall get a namename
- the name for this numberpublic java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |