01: package org.andromda.metafacades.emf.uml2;
02:
03: import org.andromda.metafacades.uml.AttributeFacade;
04: import org.andromda.metafacades.uml.ClassifierFacade;
05: import org.andromda.metafacades.uml.ManageableEntity;
06:
07: /**
08: * MetafacadeLogic implementation for
09: * org.andromda.metafacades.uml.ManageableEntityAssociationEnd.
10: *
11: * @see org.andromda.metafacades.uml.ManageableEntityAssociationEnd
12: */
13: public class ManageableEntityAssociationEndLogicImpl extends
14: ManageableEntityAssociationEndLogic {
15: public ManageableEntityAssociationEndLogicImpl(
16: final Object metaObject, final String context) {
17: super (metaObject, context);
18: }
19:
20: /**
21: * @see org.andromda.metafacades.uml.ManageableEntityAssociationEnd#getManageableIdentifier()
22: */
23: protected Object handleGetManageableIdentifier() {
24: AttributeFacade manageableIdentifier = null;
25:
26: final ClassifierFacade classifierFacade = this .getType();
27: if (classifierFacade instanceof ManageableEntity) {
28: final ManageableEntity entity = (ManageableEntity) classifierFacade;
29: manageableIdentifier = entity.getManageableIdentifier();
30: }
31:
32: return manageableIdentifier;
33: }
34:
35: /**
36: * @see org.andromda.metafacades.uml.ManageableEntityAssociationEnd#isDisplay()
37: */
38: protected boolean handleIsDisplay() {
39: // we always display association ends
40: return true;
41: }
42: }
|