class AssociationDefinitionModelImpl extends AssociationModelImpl implements AssociationDefinitionModel
| Modifier and Type | Field and Description | 
|---|---|
| private String | childCardinalityUri | 
| private Logger | logger | 
| private String | parentCardinalityUri | 
| private ViewConfigurationModelImpl | viewConfig | 
childTopics, em, id, mf, pl, typeUri, uri, value| Constructor and Description | 
|---|
| AssociationDefinitionModelImpl(AssociationModelImpl assoc)Remains partially uninitialzed. | 
| AssociationDefinitionModelImpl(AssociationModelImpl assoc,
                              String parentCardinalityUri,
                              String childCardinalityUri,
                              ViewConfigurationModelImpl viewConfig) | 
| Modifier and Type | Method and Description | 
|---|---|
| (package private) String | className() | 
| (package private) AssociationDefinitionModelImpl | createModelWithChildTopics(ChildTopicsModel childTopics) | 
| private String | defaultInstanceLevelAssocTypeUri() | 
| String | getAssocDefUri() | 
| String | getChildCardinalityUri() | 
| String | getChildTypeUri() | 
| private TopicModelImpl | getCustomAssocType() | 
| String | getCustomAssocTypeUri() | 
| String | getInstanceLevelAssocTypeUri() | 
| String | getParentCardinalityUri() | 
| String | getParentTypeUri() | 
| ViewConfigurationModelImpl | getViewConfig() | 
| (package private) boolean | includeInLabel() | 
| (package private) AssociationDefinitionImpl | instantiate() | 
| (package private) boolean | isIdentityAttr() | 
| (package private) boolean | isReadable() | 
| (package private) void | postUpdate(DMXObjectModel updateModel,
          DMXObjectModel oldObject)2 assoc def specific tasks must be performed once the underlying association is updated:
   - Update the assoc def's cardinality (in type cache + DB). | 
| void | setChildCardinalityUri(String childCardinalityUri) | 
| void | setParentCardinalityUri(String parentCardinalityUri) | 
| void | setViewConfig(ViewConfigurationModel viewConfig) | 
| org.codehaus.jettison.json.JSONObject | toJSON() | 
| private void | updateCardinality(AssociationDefinitionModel newAssocDef) | 
| private void | updateChildCardinality(String newChildCardinalityUri) | 
| (package private) void | updateChildCardinalityUri(String childCardinalityUri) | 
| private void | updateParentCardinality(String newParentCardinalityUri) | 
| (package private) void | updateParentCardinalityUri(String parentCardinalityUri) | 
_delete, checkReadAccess, checkWriteAccess, clone, createRoleModel, getAssociations, getDeleteDirective, getOtherPlayerId, getPlayer, getPostDeleteEvent, getPostUpdateEvent, getPreDeleteEvent, getPreUpdateEvent, getRelatedTopic, getRelatedTopics, getRelatedTopics, getRoleModel, getRoleModel1, getRoleModel2, getTopicByType, getType, getUpdateDirective, hasSameRoleTypeUris, indexSimpleValue, matches, preCreate, preDelete, removeProperty, setRoleModel1, setRoleModel2, storeProperty, storeSimpleValue, storeTypeUri, storeUri, updateRoleTypeUri_updateSimpleValue, delete, equals, getChildTopicsModel, getId, getIndexValue, getSimpleValue, getTypeUri, getUri, hashCode, isSimple, loadChildTopics, loadChildTopics, loadChildTopics, objectInfo, postCreate, postDelete, preUpdate, set, setChildTopicsModel, setId, setSimpleValue, setSimpleValue, setSimpleValue, setSimpleValue, setSimpleValue, setTypeUri, setUri, toString, update, updateChildTopics, updateChildTopics, updateSimpleValue, updateTypeUri, updateUri, uriChangefinalize, getClass, notify, notifyAll, wait, wait, waitclone, getOtherPlayerId, getRoleModel, getRoleModel1, getRoleModel2, hasSameRoleTypeUris, matches, setRoleModel1, setRoleModel2createRoleModel, getChildTopicsModel, getId, getSimpleValue, getTypeUri, getUri, set, setChildTopicsModel, setId, setSimpleValue, setSimpleValue, setSimpleValue, setSimpleValue, setSimpleValue, setTypeUri, setUriprivate String parentCardinalityUri
private String childCardinalityUri
private ViewConfigurationModelImpl viewConfig
AssociationDefinitionModelImpl(AssociationModelImpl assoc)
AssociationDefinitionModelImpl(AssociationModelImpl assoc, String parentCardinalityUri, String childCardinalityUri, ViewConfigurationModelImpl viewConfig)
assoc - the underlying association.public String getAssocDefUri()
getAssocDefUri in interface AssociationDefinitionModelpublic String getCustomAssocTypeUri()
getCustomAssocTypeUri in interface AssociationDefinitionModelnull if no Custom Association Type is set.public String getInstanceLevelAssocTypeUri()
getInstanceLevelAssocTypeUri in interface AssociationDefinitionModelpublic String getParentTypeUri()
getParentTypeUri in interface AssociationDefinitionModelpublic String getChildTypeUri()
getChildTypeUri in interface AssociationDefinitionModelpublic String getParentCardinalityUri()
getParentCardinalityUri in interface AssociationDefinitionModelpublic String getChildCardinalityUri()
getChildCardinalityUri in interface AssociationDefinitionModelpublic ViewConfigurationModelImpl getViewConfig()
getViewConfig in interface AssociationDefinitionModelpublic void setParentCardinalityUri(String parentCardinalityUri)
setParentCardinalityUri in interface AssociationDefinitionModelpublic void setChildCardinalityUri(String childCardinalityUri)
setChildCardinalityUri in interface AssociationDefinitionModelpublic void setViewConfig(ViewConfigurationModel viewConfig)
setViewConfig in interface AssociationDefinitionModelpublic org.codehaus.jettison.json.JSONObject toJSON()
toJSON in interface JSONEnabledtoJSON in class AssociationModelImplString className()
className in class AssociationModelImplAssociationDefinitionImpl instantiate()
instantiate in class AssociationModelImplAssociationDefinitionModelImpl createModelWithChildTopics(ChildTopicsModel childTopics)
createModelWithChildTopics in class AssociationModelImplvoid postUpdate(DMXObjectModel updateModel, DMXObjectModel oldObject)
Pre condition: these 3 assoc def parts are already up-to-date through the generic (model-driven) object update procedure: - Assoc Def type (type URI). - Custom assoc type (child topics). - "Include in Label" flag (child topics).
Called when update() is called on an AssociationDefinitionModel object. This is in 2 cases: - Edit a type interactively (a type topic is selected). - Programmatically call getChildTopics().set() on an AssociationDefinitionModel object, e.g. from a migration.
Not called when an association which also acts as an assoc def is edited interactively (an association is selected). In this case: - Cardinality doesn't need to be updated as Cardinality can't be edited interactively through an association. - Rehashing is already performed in TypeModelImpl#_updateAssocDef (called from AssociationModelImpl#postUpdate)
postUpdate in class AssociationModelImplupdateModel - the update data/instructions.
              Note: on post-update time updateModel and this (assoc def) model may differ at least because
                a) updateModel might contain only certain assoc def parts; this is called a "partial update"
                b) updateModel might contain refs and deletion-refs; this model never contains refsvoid updateParentCardinalityUri(String parentCardinalityUri)
void updateChildCardinalityUri(String childCardinalityUri)
final boolean isIdentityAttr()
final boolean includeInLabel()
boolean isReadable()
private void updateCardinality(AssociationDefinitionModel newAssocDef)
private void updateParentCardinality(String newParentCardinalityUri)
private void updateChildCardinality(String newChildCardinalityUri)
private TopicModelImpl getCustomAssocType()
private String defaultInstanceLevelAssocTypeUri()
Copyright © 2018. All Rights Reserved.