KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > Olj > ValueModeType4


1 /**
2  * <copyright>
3  * </copyright>
4  *
5  * $Id$
6  */

7 package Olj;
8
9 import java.util.Arrays JavaDoc;
10 import java.util.Collections JavaDoc;
11 import java.util.List JavaDoc;
12
13 import org.eclipse.emf.common.util.AbstractEnumerator;
14
15 /**
16  * <!-- begin-user-doc -->
17  * A representation of the literals of the enumeration '<em><b>Value Mode Type4</b></em>',
18  * and utility methods for working with them.
19  * <!-- end-user-doc -->
20  * @see Olj.OljPackage#getValueModeType4()
21  * @model
22  * @generated
23  */

24 public final class ValueModeType4 extends AbstractEnumerator {
25     /**
26      * The '<em><b>Overwrite</b></em>' literal value.
27      * <!-- begin-user-doc -->
28      * <!-- end-user-doc -->
29      * @see #OVERWRITE_LITERAL
30      * @model name="Overwrite"
31      * @generated
32      * @ordered
33      */

34     public static final int OVERWRITE = 0;
35
36     /**
37      * The '<em><b>Update</b></em>' literal value.
38      * <!-- begin-user-doc -->
39      * <!-- end-user-doc -->
40      * @see #UPDATE_LITERAL
41      * @model name="Update"
42      * @generated
43      * @ordered
44      */

45     public static final int UPDATE = 1;
46
47     /**
48      * The '<em><b>Set If Created</b></em>' literal value.
49      * <!-- begin-user-doc -->
50      * <!-- end-user-doc -->
51      * @see #SET_IF_CREATED_LITERAL
52      * @model name="SetIfCreated"
53      * @generated
54      * @ordered
55      */

56     public static final int SET_IF_CREATED = 2;
57
58     /**
59      * The '<em><b>Overwrite</b></em>' literal object.
60      * <!-- begin-user-doc -->
61      * <p>
62      * If the meaning of '<em><b>Overwrite</b></em>' literal object isn't clear,
63      * there really should be more of a description here...
64      * </p>
65      * <!-- end-user-doc -->
66      * @see #OVERWRITE
67      * @generated
68      * @ordered
69      */

70     public static final ValueModeType4 OVERWRITE_LITERAL = new ValueModeType4(OVERWRITE, "Overwrite");
71
72     /**
73      * The '<em><b>Update</b></em>' literal object.
74      * <!-- begin-user-doc -->
75      * <p>
76      * If the meaning of '<em><b>Update</b></em>' literal object isn't clear,
77      * there really should be more of a description here...
78      * </p>
79      * <!-- end-user-doc -->
80      * @see #UPDATE
81      * @generated
82      * @ordered
83      */

84     public static final ValueModeType4 UPDATE_LITERAL = new ValueModeType4(UPDATE, "Update");
85
86     /**
87      * The '<em><b>Set If Created</b></em>' literal object.
88      * <!-- begin-user-doc -->
89      * <p>
90      * If the meaning of '<em><b>Set If Created</b></em>' literal object isn't clear,
91      * there really should be more of a description here...
92      * </p>
93      * <!-- end-user-doc -->
94      * @see #SET_IF_CREATED
95      * @generated
96      * @ordered
97      */

98     public static final ValueModeType4 SET_IF_CREATED_LITERAL = new ValueModeType4(SET_IF_CREATED, "SetIfCreated");
99
100     /**
101      * An array of all the '<em><b>Value Mode Type4</b></em>' enumerators.
102      * <!-- begin-user-doc -->
103      * <!-- end-user-doc -->
104      * @generated
105      */

106     private static final ValueModeType4[] VALUES_ARRAY =
107         new ValueModeType4[] {
108             OVERWRITE_LITERAL,
109             UPDATE_LITERAL,
110             SET_IF_CREATED_LITERAL,
111         };
112
113     /**
114      * A public read-only list of all the '<em><b>Value Mode Type4</b></em>' enumerators.
115      * <!-- begin-user-doc -->
116      * <!-- end-user-doc -->
117      * @generated
118      */

119     public static final List JavaDoc VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));
120
121     /**
122      * Returns the '<em><b>Value Mode Type4</b></em>' literal with the specified name.
123      * <!-- begin-user-doc -->
124      * <!-- end-user-doc -->
125      * @generated
126      */

127     public static ValueModeType4 get(String JavaDoc name) {
128         for (int i = 0; i < VALUES_ARRAY.length; ++i) {
129             ValueModeType4 result = VALUES_ARRAY[i];
130             if (result.toString().equals(name)) {
131                 return result;
132             }
133         }
134         return null;
135     }
136
137     /**
138      * Returns the '<em><b>Value Mode Type4</b></em>' literal with the specified value.
139      * <!-- begin-user-doc -->
140      * <!-- end-user-doc -->
141      * @generated
142      */

143     public static ValueModeType4 get(int value) {
144         switch (value) {
145             case OVERWRITE: return OVERWRITE_LITERAL;
146             case UPDATE: return UPDATE_LITERAL;
147             case SET_IF_CREATED: return SET_IF_CREATED_LITERAL;
148         }
149         return null;
150     }
151
152     /**
153      * Only this class can construct instances.
154      * <!-- begin-user-doc -->
155      * <!-- end-user-doc -->
156      * @generated
157      */

158     private ValueModeType4(int value, String JavaDoc name) {
159         super(value, name);
160     }
161
162 } //ValueModeType4
163
Popular Tags