Format Java code with respect to ONAP Code Style
[externalapi/nbi.git] / src / main / java / org / onap / nbi / apis / serviceorder / model / SeverityMessage.java
1 /**
2  *     Copyright (c) 2018 Orange
3  *
4  *     Licensed under the Apache License, Version 2.0 (the "License");
5  *     you may not use this file except in compliance with the License.
6  *     You may obtain a copy of the License at
7  *
8  *         http://www.apache.org/licenses/LICENSE-2.0
9  *
10  *     Unless required by applicable law or agreed to in writing, software
11  *     distributed under the License is distributed on an "AS IS" BASIS,
12  *     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  *     See the License for the specific language governing permissions and
14  *     limitations under the License.
15  */
16 /*
17  * API ServiceOrder serviceOrder API designed for ONAP Beijing Release. This API is build from TMF
18  * open API16.5 + applied TMF guideline 3.0
19  *
20  * OpenAPI spec version: 0.1.1_inProgress
21  * 
22  *
23  * NOTE: This class is auto generated by the swagger code generator program.
24  * https://github.com/swagger-api/swagger-codegen.git Do not edit the class manually.
25  *
26  * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
27  * in compliance with the License. You may obtain a copy of the License at
28  *
29  * http://www.apache.org/licenses/LICENSE-2.0
30  *
31  * Unless required by applicable law or agreed to in writing, software distributed under the License
32  * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
33  * or implied. See the License for the specific language governing permissions and limitations under
34  * the License.
35  */
36
37 package org.onap.nbi.apis.serviceorder.model;
38
39 import com.fasterxml.jackson.annotation.JsonCreator;
40 import com.fasterxml.jackson.annotation.JsonValue;
41
42 /**
43  *
44  */
45 public enum SeverityMessage {
46
47     INFORMATION("information"),
48
49     ERROR("error");
50
51     private String value;
52
53     SeverityMessage(String value) {
54         this.value = value;
55     }
56
57     @Override
58     public String toString() {
59         return String.valueOf(value);
60     }
61
62     @JsonCreator
63     public static SeverityMessage fromValue(String text) {
64         for (SeverityMessage b : SeverityMessage.values()) {
65             if (String.valueOf(b.value).equals(text)) {
66                 return b;
67             }
68         }
69         return null;
70     }
71
72     @JsonValue
73     public String value() {
74         return this.value;
75     }
76
77 }