|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.remedy.cmdb.api.CMDBClass
com.remedy.cmdb.api.CMDBRelationship
The CMDBRelationship
class defines the relationship of
CMDBclass objects. It is a subclass of CMDBClass.
Field Summary | |
static int |
CMDB_CLASS_RELATIONSHIP_CARDINALITY_1_1
Cardinality (relationship) is one-to-one. |
static int |
CMDB_CLASS_RELATIONSHIP_CARDINALITY_1_MANY
Cardinality (relationship) is one-to-many. |
static int |
CMDB_CLASS_RELATIONSHIP_CARDINALITY_MANY_1
Cardinality (relationship) is many-to-one. |
static int |
CMDB_CLASS_RELATIONSHIP_CARDINALITY_MANY_MANY
Cardinality (relationship) is many-to-many. |
static int |
CMDB_CLASS_RELATIONSHIP_CARDINALITY_NONE
No cardinality. |
Constructor Summary | |
CMDBRelationship(CMDBClassNameKey aNameKey,
CMDBClassNameKey aSuperClassKey,
java.util.Map newAttributeMap,
CMDBIndex[] indexArray,
java.lang.String[] newRoleNames,
CMDBClassNameKey[] newRelClassNames,
int aCardinality,
boolean aWeakReference,
CMDBWeakPropagatedAttrs[] aWeakAttrArray,
boolean aCascadeDelete)
Constructor to create an CMDBRelationship object with the provided information. |
|
CMDBRelationship(CMDBClassNameKey relClassKey,
CMDBClassNameKey aSuperClassKey,
java.lang.String[] newRoleNames,
CMDBClassNameKey[] newRelClassNames)
Creates an CMDBRelationship object with minimum information. |
|
CMDBRelationship(CMDBClassNameKey relClassKey,
java.lang.String classId,
CMDBClassNameKey aSuperClassKey,
java.lang.String[] newRoleNames,
CMDBClassNameKey[] newRelClassNames)
Creates an CMDBRelationship object with minimum information. |
Method Summary | |
int |
getCardinality()
Gets the cardinality of the relationship. |
CMDBClassNameKey[] |
getRelationClassNames()
Gets the name of the two classes that are involved in the relationship. |
java.lang.String[] |
getRoleNames()
Gets the name of the Roles of the relationship. |
CMDBWeakPropagatedAttrs[] |
getWeakPropagatedAttrs()
Get propagated attributes of the weak relationship object |
boolean |
isCascadeDelete()
Tells if the relationship supports cascade deletion. |
boolean |
isRole2WeakReference()
Tells if role two is a weak reference. |
void |
setCardinality(int cardinality)
Sets the cardinality property of the CMDBRelationship object. |
void |
setCascadeDelete(boolean newCascadeDelete)
Sets the cascade deletion property of the CMDBRelationship object. |
void |
setRole2WeakReference(boolean newWeakReference)
Sets role2 to be a weak reference. |
void |
setWeakPropagatedAttrs(CMDBWeakPropagatedAttrs[] newWeakAttrArray)
Set propagated attributes of the weak relationship object |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int CMDB_CLASS_RELATIONSHIP_CARDINALITY_NONE
public static final int CMDB_CLASS_RELATIONSHIP_CARDINALITY_1_1
public static final int CMDB_CLASS_RELATIONSHIP_CARDINALITY_MANY_1
public static final int CMDB_CLASS_RELATIONSHIP_CARDINALITY_1_MANY
public static final int CMDB_CLASS_RELATIONSHIP_CARDINALITY_MANY_MANY
Constructor Detail |
public CMDBRelationship(CMDBClassNameKey relClassKey, CMDBClassNameKey aSuperClassKey, java.lang.String[] newRoleNames, CMDBClassNameKey[] newRelClassNames)
relClassKey
- a relationship class keyaSuperClassKey
- the class key of the super classnewRoleNames
- the names of the roles of the relationshipnewRelClassNames
- the names of the classes that are involved
in the relationship
java.lang.IllegalArgumentException
- if the length of any role
names are longer than
Constants.AR_MAX_NAME_SIZE
public CMDBRelationship(CMDBClassNameKey relClassKey, java.lang.String classId, CMDBClassNameKey aSuperClassKey, java.lang.String[] newRoleNames, CMDBClassNameKey[] newRelClassNames)
relClassKey
- a relationship class keyclassId
- the id of the classaSuperClassKey
- the class key of the super classnewRoleNames
- the names of the roles of the relationshipnewRelClassNames
- the names of the classes that are involved
in the relationship
java.lang.IllegalArgumentException
- if the length of any role
names are longer than
Constants.AR_MAX_NAME_SIZE
public CMDBRelationship(CMDBClassNameKey aNameKey, CMDBClassNameKey aSuperClassKey, java.util.Map newAttributeMap, CMDBIndex[] indexArray, java.lang.String[] newRoleNames, CMDBClassNameKey[] newRelClassNames, int aCardinality, boolean aWeakReference, CMDBWeakPropagatedAttrs[] aWeakAttrArray, boolean aCascadeDelete)
aNameKey
- the nameKey of CMDBclass objectaSuperClassKey
- the key of the super CMDBclassnewAttributeMap
- Attributes of the relationship. The attributes
are organized as a map that uses the attribute name as
its map key and CMDBAttribute as its mapped value.newRoleNames
- the names of the roles of the relationshipnewRelClassNames
- the names of the classes that are involved
in the relationshipaCardinality
- the cardinality of the relationshipaWeakReference
- if role two is a weak reference.aWeakAttrArray
- a propagated attributes array for the weak relationshipaCascadeDelete
- if the relationshiop supports cascade deletion
java.lang.IllegalArgumentException
- if the length of any role
names are longer than
Constants.AR_MAX_NAME_SIZE
Method Detail |
public java.lang.String[] getRoleNames()
public CMDBClassNameKey[] getRelationClassNames()
public int getCardinality()
public boolean isRole2WeakReference()
public CMDBWeakPropagatedAttrs[] getWeakPropagatedAttrs()
public boolean isCascadeDelete()
public void setRole2WeakReference(boolean newWeakReference)
newWeakReference
- the weak reference property to be setpublic void setWeakPropagatedAttrs(CMDBWeakPropagatedAttrs[] newWeakAttrArray)
newWeakAttrArray
- the new weak attributes of the weak relationshippublic void setCascadeDelete(boolean newCascadeDelete)
newCascadeDelete
- the cascade deletion property to be setpublic void setCardinality(int cardinality)
cardinality
- the cardinality property to be set
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |