Interface ObjectClassDefinition
-
@ConsumerType public interface ObjectClassDefinition
Description for the data type information of an objectclass.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description AttributeDefinition[]
getAttributeDefinitions(int filter)
Return the attribute definitions for this object class.String
getDescription()
Return a description of this object class.InputStream
getIcon(int size)
Return anInputStream
object that can be used to create an icon from.String
getID()
Return the id of this object class.String
getName()
Return the name of this object class.
-
-
-
Field Detail
-
REQUIRED
static final int REQUIRED
Argument forgetAttributeDefinitions(int)
.REQUIRED
indicates that only the required definitions are returned. The value is 1.- See Also:
- Constant Field Values
-
OPTIONAL
static final int OPTIONAL
Argument forgetAttributeDefinitions(int)
.OPTIONAL
indicates that only the optional definitions are returned. The value is 2.- See Also:
- Constant Field Values
-
ALL
static final int ALL
Argument forgetAttributeDefinitions(int)
.ALL
indicates that all the definitions are returned. The value is -1.- See Also:
- Constant Field Values
-
-
Method Detail
-
getName
String getName()
Return the name of this object class. The name may be localized.- Returns:
- The name of this object class.
-
getID
String getID()
Return the id of this object class.ObjectDefintion
objects share a global namespace in the registry. They share this aspect with LDAP/X.500 attributes. In these standards the OSI Object Identifier (OID) is used to uniquely identify object classes. If such an OID exists, (which can be requested at several standard organizations and many companies already have a node in the tree) it can be returned here. Otherwise, a unique id should be returned which can be a Java class name (reverse domain name) or generated with a GUID algorithm. Note that all LDAP defined object classes already have an OID associated. It is strongly advised to define the object classes from existing LDAP schemes which will give the OID for free. Many such schemes exist ranging from postal addresses to DHCP parameters.- Returns:
- The id of this object class.
-
getDescription
String getDescription()
Return a description of this object class. The description may be localized.- Returns:
- The description of this object class.
-
getAttributeDefinitions
AttributeDefinition[] getAttributeDefinitions(int filter)
Return the attribute definitions for this object class.Return a set of attributes. The filter parameter can distinguish between
ALL
,REQUIRED
or theOPTIONAL
attributes.- Parameters:
filter
-ALL
,REQUIRED
,OPTIONAL
- Returns:
- An array of attribute definitions or
null
if no attributes are selected
-
getIcon
InputStream getIcon(int size) throws IOException
Return anInputStream
object that can be used to create an icon from.Indicate the size and return an
InputStream
object containing an icon. The returned icon maybe larger or smaller than the indicated size.The icon may depend on the localization.
- Parameters:
size
- Requested size of an icon. For example, a 16x16 pixel icon has a size of 16- Returns:
- An InputStream representing an icon or
null
- Throws:
IOException
- If theInputStream
cannot be returned.
-
-