|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.felix.dm.impl.metatype.ObjectClassDefinitionImpl
public class ObjectClassDefinitionImpl
ObjectClassDefinition implementation.
Field Summary |
---|
Fields inherited from interface org.osgi.service.metatype.ObjectClassDefinition |
---|
ALL, OPTIONAL, REQUIRED |
Constructor Summary | |
---|---|
ObjectClassDefinitionImpl(String id,
String name,
String description,
List propertiesMetaData,
Resource resource)
|
Method Summary | |
---|---|
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 an InputStream 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. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ObjectClassDefinitionImpl(String id, String name, String description, List propertiesMetaData, Resource resource)
Method Detail |
---|
public AttributeDefinition[] getAttributeDefinitions(int filter)
ObjectClassDefinition
Return a set of attributes. The filter parameter can distinguish between
ALL
,REQUIRED
or the OPTIONAL
attributes.
getAttributeDefinitions
in interface ObjectClassDefinition
filter
- ALL
,REQUIRED
,OPTIONAL
null
if no
attributes are selectedpublic String getDescription()
ObjectClassDefinition
getDescription
in interface ObjectClassDefinition
public String getID()
ObjectClassDefinition
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 organisations 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.
getID
in interface ObjectClassDefinition
public InputStream getIcon(int size) throws IOException
ObjectClassDefinition
InputStream
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.
getIcon
in interface ObjectClassDefinition
size
- Requested size of an icon, e.g. a 16x16 pixels icon then size =
16
null
IOException
- If the InputStream
cannot be returned.public String getName()
ObjectClassDefinition
getName
in interface ObjectClassDefinition
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |