1 // license-header java merge-point
2 //
3 // Attention: generated code (by MetafacadeLogic.vsl) - do not modify!
4 //
5 package org.andromda.metafacades.uml14;
6
7 import java.util.Collection;
8 import org.andromda.core.metafacade.ModelValidationMessage;
9 import org.andromda.metafacades.uml.ArgumentFacade;
10 import org.omg.uml.behavioralelements.commonbehavior.Argument;
11
12 /**
13 * Represents an argument to an operation. All parameters except for the return parameter.
14 * MetafacadeLogic for ArgumentFacade
15 *
16 * @see ArgumentFacade
17 */
18 public abstract class ArgumentFacadeLogic
19 extends ModelElementFacadeLogicImpl
20 implements ArgumentFacade
21 {
22 /**
23 * The underlying UML object
24 * @see Argument
25 */
26 protected Argument metaObject;
27
28 /** Create Metafacade implementation instance using the MetafacadeFactory from the context
29 * @param metaObjectIn
30 * @param context
31 */
32 protected ArgumentFacadeLogic(Argument metaObjectIn, String context)
33 {
34 super(metaObjectIn, getContext(context));
35 this.metaObject = metaObjectIn;
36 }
37
38 /**
39 * Gets the context for this metafacade logic instance.
40 * @param context String. Set to ArgumentFacade if null
41 * @return context String
42 */
43 private static String getContext(String context)
44 {
45 if (context == null)
46 {
47 context = "org.andromda.metafacades.uml.ArgumentFacade";
48 }
49 return context;
50 }
51
52 /** Reset context only for non-root metafacades
53 * @param context
54 */
55 @Override
56 public void resetMetafacadeContext(String context)
57 {
58 if (!this.contextRoot) // reset context only for non-root metafacades
59 {
60 context = getContext(context); // to have same value as in original constructor call
61 setMetafacadeContext (context);
62 }
63 }
64
65 /**
66 * @return boolean true always
67 * @see ArgumentFacade
68 */
69 public boolean isArgumentFacadeMetaType()
70 {
71 return true;
72 }
73
74 /**
75 * @param validationMessages Collection<ModelValidationMessage>
76 * @see ModelElementFacadeLogicImpl#validateInvariants(Collection validationMessages)
77 */
78 @Override
79 public void validateInvariants(Collection<ModelValidationMessage> validationMessages)
80 {
81 super.validateInvariants(validationMessages);
82 }
83 }