/*- * ============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.logs; 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 'Log Level', * and utility methods for working with them. * * @see org.openecomp.ncomp.core.logs.LogsPackage#getLogLevel() * @model * @generated */ public enum LogLevel implements Enumerator { /** * The 'UNKNOWN' literal object. * * * @see #UNKNOWN_VALUE * @generated * @ordered */ UNKNOWN(0, "UNKNOWN", "UNKNOWN"), /** * The 'TRACE' literal object. * * * @see #TRACE_VALUE * @generated * @ordered */ TRACE(0, "TRACE", "TRACE"), /** * The 'DEBUG' literal object. * * * @see #DEBUG_VALUE * @generated * @ordered */ DEBUG(0, "DEBUG", "DEBUG"), /** * The 'INFO' literal object. * * * @see #INFO_VALUE * @generated * @ordered */ INFO(0, "INFO", "INFO"), /** * The 'WARN' literal object. * * * @see #WARN_VALUE * @generated * @ordered */ WARN(0, "WARN", "WARN"), /** * The 'ERROR' literal object. * * * @see #ERROR_VALUE * @generated * @ordered */ ERROR(0, "ERROR", "ERROR"), /** * The 'FATAL' literal object. * * * @see #FATAL_VALUE * @generated * @ordered */ FATAL(0, "FATAL", "FATAL"); /** * The 'UNKNOWN' literal value. * *

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

* * @see #UNKNOWN * @model * @generated * @ordered */ public static final int UNKNOWN_VALUE = 0; /** * The 'TRACE' literal value. * *

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

* * @see #TRACE * @model * @generated * @ordered */ public static final int TRACE_VALUE = 0; /** * The 'DEBUG' literal value. * *

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

* * @see #DEBUG * @model * @generated * @ordered */ public static final int DEBUG_VALUE = 0; /** * The 'INFO' literal value. * *

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

* * @see #INFO * @model * @generated * @ordered */ public static final int INFO_VALUE = 0; /** * The 'WARN' literal value. * *

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

* * @see #WARN * @model * @generated * @ordered */ public static final int WARN_VALUE = 0; /** * The 'ERROR' literal value. * *

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

* * @see #ERROR * @model * @generated * @ordered */ public static final int ERROR_VALUE = 0; /** * The 'FATAL' literal value. * *

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

* * @see #FATAL * @model * @generated * @ordered */ public static final int FATAL_VALUE = 0; /** * An array of all the 'Log Level' enumerators. * * * @generated */ private static final LogLevel[] VALUES_ARRAY = new LogLevel[] { UNKNOWN, TRACE, DEBUG, INFO, WARN, ERROR, FATAL, }; /** * A public read-only list of all the 'Log Level' enumerators. * * * @generated */ public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); /** * Returns the 'Log Level' literal with the specified literal value. * * * @generated */ public static LogLevel get(String literal) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { LogLevel result = VALUES_ARRAY[i]; if (result.toString().equals(literal)) { return result; } } return null; } /** * Returns the 'Log Level' literal with the specified name. * * * @generated */ public static LogLevel getByName(String name) { for (int i = 0; i < VALUES_ARRAY.length; ++i) { LogLevel result = VALUES_ARRAY[i]; if (result.getName().equals(name)) { return result; } } return null; } /** * Returns the 'Log Level' literal with the specified integer value. * * * @generated */ public static LogLevel get(int value) { switch (value) { case UNKNOWN_VALUE: return UNKNOWN; } 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 LogLevel(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; } } //LogLevel