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