001/**
002 */
003package org.nasdanika.models.gitlab;
004
005import java.util.Arrays;
006import java.util.Collections;
007import java.util.List;
008
009import org.eclipse.emf.common.util.Enumerator;
010
011/**
012 * <!-- begin-user-doc -->
013 * A representation of the literals of the enumeration '<em><b>Auto Devops Deploy Strategy</b></em>',
014 * and utility methods for working with them.
015 * <!-- end-user-doc -->
016 * @see org.nasdanika.models.gitlab.GitLabPackage#getAutoDevopsDeployStrategy()
017 * @model
018 * @generated
019 */
020public enum AutoDevopsDeployStrategy implements Enumerator {
021        /**
022         * The '<em><b>Continuous</b></em>' literal object.
023         * <!-- begin-user-doc -->
024         * <!-- end-user-doc -->
025         * @see #CONTINUOUS_VALUE
026         * @generated
027         * @ordered
028         */
029        CONTINUOUS(0, "Continuous", "Info"),
030
031        /**
032         * The '<em><b>Manual</b></em>' literal object.
033         * <!-- begin-user-doc -->
034         * <!-- end-user-doc -->
035         * @see #MANUAL_VALUE
036         * @generated
037         * @ordered
038         */
039        MANUAL(1, "Manual", "Manual"),
040
041        /**
042         * The '<em><b>Timed Incremental</b></em>' literal object.
043         * <!-- begin-user-doc -->
044         * <!-- end-user-doc -->
045         * @see #TIMED_INCREMENTAL_VALUE
046         * @generated
047         * @ordered
048         */
049        TIMED_INCREMENTAL(2, "TimedIncremental", "TimedIncremental");
050
051        /**
052         * The '<em><b>Continuous</b></em>' literal value.
053         * <!-- begin-user-doc -->
054         * <!-- end-user-doc -->
055         * @see #CONTINUOUS
056         * @model name="Continuous" literal="Info"
057         * @generated
058         * @ordered
059         */
060        public static final int CONTINUOUS_VALUE = 0;
061
062        /**
063         * The '<em><b>Manual</b></em>' literal value.
064         * <!-- begin-user-doc -->
065         * <!-- end-user-doc -->
066         * @see #MANUAL
067         * @model name="Manual"
068         * @generated
069         * @ordered
070         */
071        public static final int MANUAL_VALUE = 1;
072
073        /**
074         * The '<em><b>Timed Incremental</b></em>' literal value.
075         * <!-- begin-user-doc -->
076         * <!-- end-user-doc -->
077         * @see #TIMED_INCREMENTAL
078         * @model name="TimedIncremental"
079         * @generated
080         * @ordered
081         */
082        public static final int TIMED_INCREMENTAL_VALUE = 2;
083
084        /**
085         * An array of all the '<em><b>Auto Devops Deploy Strategy</b></em>' enumerators.
086         * <!-- begin-user-doc -->
087         * <!-- end-user-doc -->
088         * @generated
089         */
090        private static final AutoDevopsDeployStrategy[] VALUES_ARRAY =
091                new AutoDevopsDeployStrategy[] {
092                        CONTINUOUS,
093                        MANUAL,
094                        TIMED_INCREMENTAL,
095                };
096
097        /**
098         * A public read-only list of all the '<em><b>Auto Devops Deploy Strategy</b></em>' enumerators.
099         * <!-- begin-user-doc -->
100         * <!-- end-user-doc -->
101         * @generated
102         */
103        public static final List<AutoDevopsDeployStrategy> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));
104
105        /**
106         * Returns the '<em><b>Auto Devops Deploy Strategy</b></em>' literal with the specified literal value.
107         * <!-- begin-user-doc -->
108         * <!-- end-user-doc -->
109         * @param literal the literal.
110         * @return the matching enumerator or <code>null</code>.
111         * @generated
112         */
113        public static AutoDevopsDeployStrategy get(String literal) {
114                for (int i = 0; i < VALUES_ARRAY.length; ++i) {
115                        AutoDevopsDeployStrategy result = VALUES_ARRAY[i];
116                        if (result.toString().equals(literal)) {
117                                return result;
118                        }
119                }
120                return null;
121        }
122
123        /**
124         * Returns the '<em><b>Auto Devops Deploy Strategy</b></em>' literal with the specified name.
125         * <!-- begin-user-doc -->
126         * <!-- end-user-doc -->
127         * @param name the name.
128         * @return the matching enumerator or <code>null</code>.
129         * @generated
130         */
131        public static AutoDevopsDeployStrategy getByName(String name) {
132                for (int i = 0; i < VALUES_ARRAY.length; ++i) {
133                        AutoDevopsDeployStrategy result = VALUES_ARRAY[i];
134                        if (result.getName().equals(name)) {
135                                return result;
136                        }
137                }
138                return null;
139        }
140
141        /**
142         * Returns the '<em><b>Auto Devops Deploy Strategy</b></em>' literal with the specified integer value.
143         * <!-- begin-user-doc -->
144         * <!-- end-user-doc -->
145         * @param value the integer value.
146         * @return the matching enumerator or <code>null</code>.
147         * @generated
148         */
149        public static AutoDevopsDeployStrategy get(int value) {
150                switch (value) {
151                        case CONTINUOUS_VALUE: return CONTINUOUS;
152                        case MANUAL_VALUE: return MANUAL;
153                        case TIMED_INCREMENTAL_VALUE: return TIMED_INCREMENTAL;
154                }
155                return null;
156        }
157
158        /**
159         * <!-- begin-user-doc -->
160         * <!-- end-user-doc -->
161         * @generated
162         */
163        private final int value;
164
165        /**
166         * <!-- begin-user-doc -->
167         * <!-- end-user-doc -->
168         * @generated
169         */
170        private final String name;
171
172        /**
173         * <!-- begin-user-doc -->
174         * <!-- end-user-doc -->
175         * @generated
176         */
177        private final String literal;
178
179        /**
180         * Only this class can construct instances.
181         * <!-- begin-user-doc -->
182         * <!-- end-user-doc -->
183         * @generated
184         */
185        private AutoDevopsDeployStrategy(int value, String name, String literal) {
186                this.value = value;
187                this.name = name;
188                this.literal = literal;
189        }
190
191        /**
192         * <!-- begin-user-doc -->
193         * <!-- end-user-doc -->
194         * @generated
195         */
196        @Override
197        public int getValue() {
198          return value;
199        }
200
201        /**
202         * <!-- begin-user-doc -->
203         * <!-- end-user-doc -->
204         * @generated
205         */
206        @Override
207        public String getName() {
208          return name;
209        }
210
211        /**
212         * <!-- begin-user-doc -->
213         * <!-- end-user-doc -->
214         * @generated
215         */
216        @Override
217        public String getLiteral() {
218          return literal;
219        }
220
221        /**
222         * Returns the literal value of the enumerator, which is its string representation.
223         * <!-- begin-user-doc -->
224         * <!-- end-user-doc -->
225         * @generated
226         */
227        @Override
228        public String toString() {
229                return literal;
230        }
231        
232} //AutoDevopsDeployStrategy