View Javadoc
1   package org.andromda.cartridges.spring;
2   
3   import org.andromda.core.profile.Profile;
4   import org.andromda.metafacades.uml.UMLProfile;
5   
6   
7   /**
8    * The Spring profile. Contains the profile information (tagged values, and stereotypes) for the Spring cartridge.
9    *
10   * @author Chad Brandon
11   * @author Peter Friese
12   */
13  public class SpringProfile
14      extends UMLProfile
15  {
16      /**
17       * The Profile instance from which we retrieve the mapped profile names.
18       */
19      private static final Profile PROFILE = Profile.instance();
20  
21      /* ----------------- Stereotypes -------------------- */
22      /**
23       * Stores the service init-method stereotype.
24       */
25      public static final String STEREOTYPE_POST_CONSTRUCT_METHOD = PROFILE.get("POST_CONSTRUCT");
26  
27      /**
28       * Stores the service destroy-method stereotype.
29       */
30      public static final String STEREOTYPE_PRE_DESTROY_METHOD = PROFILE.get("PRE_DESTROY");
31  
32      /**
33       * 'PrePersist' Specifies the entity business operation as a pre-persist callback
34       */
35      public static final String STEREOTYPE_PRE_PERSIST = PROFILE.get("PRE_PERSIST");
36  
37      /**
38       * 'PostPersist' Specifies the entity operation as a post-persist operation
39       */
40      public static final String STEREOTYPE_POST_PERSIST = PROFILE.get("POST_PERSIST");
41  
42      /**
43       * 'PreRemove' Specifies the entity business operati operationre-remove operation
44       */
45      public static final String STEREOTYPE_PRE_REMOVE = PROFILE.get("PRE_REMOVE");
46  
47      /**
48       * 'PostRemove' Specifies the entity business operation as a post-remove operation
49       */
50      public static final String STEREOTYPE_POST_REMOVE = PROFILE.get("POST_REMOVE");
51  
52      /**
53       * 'PreUpdate' Specifies the entity business operation as a pre-update operation
54       */
55      public static final String STEREOTYPE_PRE_UPDATE = PROFILE.get("PRE_UPDATE");
56  
57      /**
58       * 'PostUpdate' Specifies the entity business operation as a post-update operation
59       */
60      public static final String STEREOTYPE_POST_UPDATE = PROFILE.get("POST_UPDATE");
61  
62      /* ----------------- Tagged Values -------------------- */
63  
64      /**
65       * Stores the EJB service transaction type.
66       */
67      public static final String TAGGEDVALUE_EJB_TRANSACTION_TYPE = PROFILE.get("EJB_TRANSACTION_TYPE");
68  
69      /**
70       * Stores the EJB service view type (local/remote).
71       */
72      public static final String TAGGEDVALUE_EJB_VIEW_TYPE = PROFILE.get("EJB_VIEW_TYPE");
73  
74      /**
75       * Stores the Spring service transaction type.
76       */
77      public static final String TAGGEDVALUE_TRANSACTION_TYPE = PROFILE.get("TRANSACTION_TYPE");
78  
79      /**
80       * Stores whether a criteria search attribute may be nullable.
81       */
82      public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_NULLABLE = PROFILE.get("HIBERNATE_CRITERIA_NULLABLE");
83  
84      /**
85       * Stores a criteria search attribute path.
86       */
87      public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_ATTRIBUTE = PROFILE.get("HIBERNATE_CRITERIA_ATTRIBUTE");
88  
89      /**
90       * Stores a criteria search comparator.
91       */
92      public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_COMPARATOR = PROFILE.get("HIBERNATE_CRITERIA_COMPARATOR");
93  
94      /**
95       * Stores a hibernate matchmode.
96       */
97      public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_MATCHMODE = PROFILE.get("HIBERNATE_CRITERIA_MATCHMODE");
98  
99      /**
100      * Stores the criteria search order direction.
101      */
102     public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_ORDER_DIRECTION =
103         PROFILE.get("HIBERNATE_CRITERIA_ORDER_DIRECTION");
104 
105     /**
106      * Stores the criteria search order relevance.
107      */
108     public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_ORDER_RELEVANCE =
109         PROFILE.get("HIBERNATE_CRITERIA_ORDER_RELEVANCE");
110 
111     /**
112      * Stores whether or not criteria like comparator's should ignore case.
113      */
114     public static final String TAGGEDVALUE_HIBERNATE_CRITERIA_COMPARATOR_IGNORE_CASE =
115         PROFILE.get("HIBERNATE_CRITERIA_COMPARATOR_IGNORE_CASE");
116 
117     /**
118      * Stores a hibernate query.
119      */
120     public static final String TAGGEDVALUE_HIBERNATE_QUERY = PROFILE.get("HIBERNATE_QUERY");
121 
122     /**
123      * Stores the hibernate inheritance use for entities.
124      */
125     public static final String TAGGEDVALUE_HIBERNATE_INHERITANCE = PROFILE.get("HIBERNATE_INHERITANCE");
126 
127     /**
128      * Define whether the marked finder will use named parameters or positional parameters.
129      */
130     public static final String TAGGEDVALUE_HIBERNATE_USE_NAMED_PARAMETERS = PROFILE
131             .get("HIBERNATE_USE_NAMED_PARAMETERS");
132 
133     /**
134      * Defines the remoting type for spring services.
135      */
136     public static final String TAGGEDVALUE_SPRING_SERVICE_REMOTING_TYPE = PROFILE.get("SPRING_SERVICE_REMOTING_TYPE");
137 
138     /**
139      * Defines the remote port for spring services.
140      */
141     public static final String TAGGEDVALUE_SPRING_SERVICE_REMOTE_PORT = PROFILE.get("SPRING_SERVICE_REMOTE_PORT");
142 
143     /**
144      * Define additional spring interceptors
145      */
146     public static final String TAGGEDVALUE_SPRING_SERVICE_INTERCEPTORS = PROFILE.get("SPRING_SERVICE_INTERCEPTORS");
147 
148     /**
149      * Define whether we will render only the configuration, but not the service itself.
150      */
151     public static final String TAGGEDVALUE_SERVICE_CONFIG_ONLY = PROFILE.get("SPRING_SERVICE_CONFIG_ONLY");
152 
153     /**
154     * Define whether the service is private.
155     */
156     public static final String TAGGEDVALUE_SERVICE_PRIVATE = PROFILE.get("SPRING_SERVICE_PRIVATE");
157 
158     /**
159      * Optimize acknowledge flag for ActiveMQ connections.
160      */
161     public static final String TAGGEDVALUEVALUE_ACTIVEMQ_OPTIMIZE_ACKNOWLEDGE = PROFILE.get("ACTIVEMQ_OPTIMIZE_ACKNOWLEDGE");
162 
163     /**
164      * Session acknowledge mode for messaging (JMS).
165      */
166     public static final String TAGGEDVALUEVALUE_MESSAGING_SESSION_ACKNOWLEDGE_MODE = PROFILE.get("MESSAGING_SESSION_ACKNOWLEDGE_MODE");
167 
168     /* ----------------- Tagged Value Values ------------- */
169 
170     /**
171      * The "like" comparator.
172      */
173     public static final String TAGGEDVALUEVALUE_COMPARATOR_LIKE = PROFILE.get("LIKE_COMPARATOR");
174 
175     /**
176      * The "case insensitive like" comparator.
177      */
178     public static final String TAGGEDVALUEVALUE_INSENSITIVE_LIKE_COMPARATOR =
179         PROFILE.get("INSENSITIVE_LIKE_COMPARATOR");
180 
181     /**
182      * The "equals" comparator.
183      */
184     public static final String TAGGEDVALUEVALUE_COMPARATOR_EQUAL = PROFILE.get("EQUAL_COMPARATOR");
185 
186     /**
187      * The "greater of even" comparator.
188      */
189     public static final String TAGGEDVALUEVALUE_COMPARATOR_GREATER_OR_EQUAL =
190         PROFILE.get("GREATER_THAN_OR_EQUAL_COMPARATOR");
191 
192     /**
193      * The "greater" comparator.
194      */
195     public static final String TAGGEDVALUEVALUE_COMPARATOR_GREATER = PROFILE.get("GREATER_THAN_COMPARATOR");
196 
197     /**
198      * The "less of even" comparator.
199      */
200     public static final String TAGGEDVALUEVALUE_COMPARATOR_LESS_OR_EQUAL = PROFILE.get("LESS_THAN_OR_EQUAL_COMPARATOR");
201 
202     /**
203      * The "less" comparator.
204      */
205     public static final String TAGGEDVALUEVALUE_COMPARATOR_LESS = PROFILE.get("LESS_THAN_COMPARATOR");
206 
207     /**
208      * The "in" comparator.
209      */
210     public static final String TAGGEDVALUEVALUE_COMPARATOR_IN = PROFILE.get("IN_COMPARATOR");
211 
212     /**
213      * The "not equal" comparator.
214      */
215     public static final String TAGGEDVALUEVALUE_COMPARATOR_NOT_EQUAL = PROFILE.get("NOT_EQUAL_COMPARATOR");
216 
217     /**
218      * PROFILE.get("MATCHMODE_ANYWHERE")
219      * net.sf.hibernate.expression.MatchMode#ANYWHERE match mode.
220      */
221     public static final String TAGGEDVALUEVALUE_MATCHMODE_ANYWHERE = PROFILE.get("MATCHMODE_ANYWHERE");
222 
223     /**
224      * PROFILE.get("MATCHMODE_END")
225      * net.sf.hibernate.expression.MatchMode#END match mode.
226      */
227     public static final String TAGGEDVALUEVALUE_MATCHMODE_END = PROFILE.get("MATCHMODE_END");
228 
229     /**
230      * PROFILE.get("MATCHMODE_EXACT")
231      * net.sf.hibernate.expression.MatchMode#EXACT match mode.
232      */
233     public static final String TAGGEDVALUEVALUE_MATCHMODE_EXACT = PROFILE.get("MATCHMODE_EXACT");
234 
235     /**
236      * PROFILE.get("MATCHMODE_START")
237      * net.sf.hibernate.expression.MatchMode#START match mode.
238      */
239     public static final String TAGGEDVALUEVALUE_MATCHMODE_START = PROFILE.get("MATCHMODE_START");
240 
241     /**
242      * Ascending sort order.
243      */
244     public static final String TAGGEDVALUEVALUE_ORDER_ASCENDING = PROFILE.get("ORDER_ASCENDING");
245 
246     /**
247      * Descending sort order.
248      */
249     public static final String TAGGEDVALUEVALUE_ORDER_DESCENDING = PROFILE.get("ORDER_DESCENDING");
250 }