|
Compoze Software, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.compoze.collab.ItemClass
Defines the class of an Item
including its name, default
keys, implementing Java class, containing item class and parent item class.
Defines how to create a class of Item
instance.
Field Summary | |
protected Key[] |
m_defaultKeys
|
protected java.lang.Class |
m_javaClass
|
protected java.lang.String |
m_sContainingItemClass
|
protected java.lang.String |
m_sInternalName
|
protected java.lang.String |
m_sItemClassParent
|
Method Summary | |
protected static boolean |
checkForDuplicates(Key[] defaultKeys)
Check for duplicates in the defaultKeys array |
static ItemClass |
create(java.lang.String sInternalName,
Key[] defaultKeys,
java.lang.Class javaClass,
java.lang.String sContainingItemClass,
java.lang.String sItemClassParent)
Creates an ItemClass, given its name and properties, or returns an existing ItemClass if one has already been created with the same name and properties. |
boolean |
equals(java.lang.Object obj)
Equals. |
java.lang.String |
getContainingItemClass()
Get the internal name of the ItemClass of containers of
this ItemClass . |
Key[] |
getDefaultKeys()
Gets the Keys for the properties that are available for a specific Item. |
java.lang.String |
getInternalName()
Get the ItemClass's name. |
java.lang.String |
getItemClassParent()
Gets the internal name of the parent ItemClass that
this ItemClass extends. |
java.lang.Class |
getJavaClass()
Gets the implementation class for the item class. |
Key[] |
getMinimumKeys()
Gets the minimum set of keys for this class. |
int |
hashCode()
Gets the hash code of the item class (the hash of its internal name). |
boolean |
isDefaultKey(Key key)
Determines if the specified key is a default for the item. |
boolean |
isInstanceOf(ItemClass itemClass)
Checks to see if this ItemClass is the same as or a subclass
of the given ItemClass . |
static ItemClass |
lookupItemClass(java.lang.String sInternalName)
Find the ItemClass instance for the internal name. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.lang.String m_sInternalName
protected Key[] m_defaultKeys
protected java.lang.Class m_javaClass
protected java.lang.String m_sContainingItemClass
protected java.lang.String m_sItemClassParent
Method Detail |
public static ItemClass create(java.lang.String sInternalName, Key[] defaultKeys, java.lang.Class javaClass, java.lang.String sContainingItemClass, java.lang.String sItemClassParent) throws CollaborationException
sInternalName
- unique internal name for this class (not null
)defaultKeys
- array of class specific default keys;
null
means nonejavaClass
- Java class representing this class; must implement
IItem
(not null
)sContainingItemClass
- the internal name of the item class of containers
of this item (may be null
if the item has no
logical container, such as a root container)sItemClassParent
- the internal name of the parent item class
that this item class extends.CollaborationException
- if sInternalName
or
javaClass
is null
,
if sInternalName is already used for a different
class, or javaClass does not implement IItem.protected static boolean checkForDuplicates(Key[] defaultKeys)
defaultKeys
- the default Key arraytrue
if there are any duplicatespublic Key[] getDefaultKeys()
Key[0]
, never null
.public Key[] getMinimumKeys()
public boolean isDefaultKey(Key key)
key
- the key (must not be null
)true
if the key is a default keypublic java.lang.String getInternalName()
public java.lang.Class getJavaClass()
public static ItemClass lookupItemClass(java.lang.String sInternalName)
sInternalName
- internal name to look upnull
if none existspublic java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public java.lang.String getContainingItemClass()
ItemClass
of containers of
this ItemClass
.public boolean isInstanceOf(ItemClass itemClass)
ItemClass
is the same as or a subclass
of the given ItemClass
.itemClass
- the ItemClass
to check (not
null
)true
if itemClass
is the same or
a subclass of this classpublic java.lang.String getItemClassParent()
ItemClass
that
this ItemClass
extends.public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
true
if the specified object is an
ItemClass
instance with the same internal name
|
Compoze Software, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |