public class AttributeType extends Object
| 构造器和说明 |
|---|
AttributeType(int vendor,
int code,
String name,
Class type)
Constructs a Vendor-Specific sub-attribute type.
|
AttributeType(int code,
String name,
Class type)
Create a new attribute type.
|
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addEnumerationValue(int num,
String name)
Adds a name for an integer value of this attribute.
|
Class |
getAttributeClass()
Retrieves the RadiusAttribute descendant class which represents
attributes of this type.
|
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.
|
Integer |
getEnumeration(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.
|
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(Class type)
Sets the RadiusAttribute descendant class which represents
attributes of this type.
|
void |
setName(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.
|
String |
toString()
String representation of AttributeType object
for debugging purposes.
|
public AttributeType(int code,
String name,
Class type)
code - Radius attribute type codename - Attribute type nametype - RadiusAttribute descendant who handles
attributes of this typepublic int getTypeCode()
public void setTypeCode(int code)
code - type code, 1-255public String getName()
public void setName(String name)
name - type namepublic Class getAttributeClass()
public void setAttributeClass(Class type)
public int getVendorId()
public void setVendorId(int vendorId)
vendorId - vendor IDpublic String getEnumeration(int value)
public Integer getEnumeration(String value)
value - string valuepublic void addEnumerationValue(int num,
String name)
num - number that shall get a namename - the name for this numberpublic String toString()
toString 在类中 ObjectObject.toString()Copyright © 2016. All rights reserved.