/*- * ============LICENSE_START========================================== * OPENECOMP - DCAE * =================================================================== * Copyright (c) 2017 AT&T Intellectual Property. All rights reserved. * =================================================================== * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * ============LICENSE_END============================================ */ /** */ package org.openecomp.ncomp.core.metrics; import java.util.Arrays; import java.util.Collections; import java.util.List; import org.eclipse.emf.common.util.Enumerator; /** * * A representation of the literals of the enumeration 'Aggregation Metric Value Option Type', * and utility methods for working with them. * * @see org.openecomp.ncomp.core.metrics.MetricsPackage#getAggregationMetricValueOptionType() * @model * @generated */ public enum AggregationMetricValueOptionType implements Enumerator { /** * The 'SUM' literal object. * * * @see #SUM_VALUE * @generated * @ordered */ SUM(0, "SUM", "SUM"), /** * The 'AVERAGE' literal object. * * * @see #AVERAGE_VALUE * @generated * @ordered */ AVERAGE(0, "AVERAGE", "AVERAGE"), /** * The 'COUNT' literal object. * * * @see #COUNT_VALUE * @generated * @ordered */ COUNT(0, "COUNT", "COUNT"), /** * The 'MAX' literal object. * * * @see #MAX_VALUE * @generated * @ordered */ MAX(0, "MAX", "MAX"), /** * The 'MIN' literal object. * * * @see #MIN_VALUE * @generated * @ordered */ MIN(0, "MIN", "MIN"); /** * The 'SUM' literal value. * *

* If the meaning of 'SUM' literal object isn't clear, * there really should be more of a description here... *

* * @see #SUM * @model * @generated * @ordered */ public static final int SUM_VALUE = 0; /** * The 'AVERAGE' literal value. * *

* If the meaning of 'AVERAGE' literal object isn't clear, * there really should be more of a description here... *

* * @see #AVERAGE * @model * @generated * @ordered */ public static final int AVERAGE_VALUE = 0; /** * The 'COUNT' literal value. * *

* If the meaning of 'COUNT' literal object isn't clear, * there really should be more of a description here... *

* * @see #COUNT * @model * @generated * @ordered */ public static final int COUNT_VALUE = 0; /** * The 'MAX' literal value. * *

* If the meaning of 'MAX' literal object isn't clear, * there really should be more of a description here... *

* * @see #MAX * @model * @generated * @ordered */ public static final int MAX_VALUE = 0; /** * The 'MIN' literal value. * *

* If the meaning of 'MIN' literal object isn't clear, * there really should be more of a description here... *

* * @see #MIN * @model * @generated * @ordered */ public static final int MIN_VALUE = 0; /** * An array of all the 'Aggregation Metric Value Option Type' enumerators. * * * @generated */ private static final AggregationMetricValueOptionType[] VALUES_ARRAY = new AggregationMetricValueOptionType[] { SUM, AVERAGE, COUNT, MAX, MIN, }; /** * A public read-only list of all the 'Aggregation Metric Value Option Type' enumerators. * * * @generated */ public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); /** * Returns the 'Aggregation Metric Value Option Type' literal with the specified literal value. * * * @generated */ public static AggregationMetricValueOptionType get(String literal) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { AggregationMetricValueOptionType result = VALUES_ARRAY[i]; if (result.toString().equals(literal)) { return result; } } return null; } /** * Returns the 'Aggregation Metric Value Option Type' literal with the specified name. * * * @generated */ public static AggregationMetricValueOptionType getByName(String name) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { AggregationMetricValueOptionType result = VALUES_ARRAY[i]; if (result.getName().equals(name)) { return result; } } return null; } /** * Returns the 'Aggregation Metric Value Option Type' literal with the specified integer value. * * * @generated */ public static AggregationMetricValueOptionType get(int value) { switch (value) { case SUM_VALUE: return SUM; } return null; } /** * * * @generated */ private final int value; /** * * * @generated */ private final String name; /** * * * @generated */ private final String literal; /** * Only this class can construct instances. * * * @generated */ private AggregationMetricValueOptionType(int value, String name, String literal) { this.value = value; this.name = name; this.literal = literal; } /** * * * @generated */ public int getValue() { return value; } /** * * * @generated */ public String getName() { return name; } /** * * * @generated */ public String getLiteral() { return literal; } /** * Returns the literal value of the enumerator, which is its string representation. * * * @generated */ @Override public String toString() { return literal; } } //AggregationMetricValueOptionType