1 /*
2 * Copyright 2001-2008 The Apache Software Foundation.
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
18
19 package org.uddi.policy_v3_instanceparms;
20
21 import java.io.Serializable;
22
23 import javax.xml.bind.annotation.XmlEnum;
24 import javax.xml.bind.annotation.XmlEnumValue;
25 import javax.xml.bind.annotation.XmlType;
26
27
28 /**
29 * <p>Java class for authInfoUse_type.
30 *
31 * <p>The following schema fragment specifies the expected content contained within this class.
32 * <p>
33 * <pre>
34 * <simpleType name="authInfoUse_type">
35 * <restriction base="{http://www.w3.org/2001/XMLSchema}NMTOKEN">
36 * <enumeration value="required"/>
37 * <enumeration value="optional"/>
38 * <enumeration value="ignored"/>
39 * </restriction>
40 * </simpleType>
41 * </pre>
42 *
43 */
44 @XmlType(name = "authInfoUse_type")
45 @XmlEnum
46 public enum AuthInfoUseType implements Serializable{
47
48 @XmlEnumValue("required")
49 REQUIRED("required"),
50 @XmlEnumValue("optional")
51 OPTIONAL("optional"),
52 @XmlEnumValue("ignored")
53 IGNORED("ignored");
54 private final String value;
55
56 AuthInfoUseType(String v) {
57 value = v;
58 }
59
60 public String value() {
61 return value;
62 }
63
64 public static AuthInfoUseType fromValue(String v) {
65 for (AuthInfoUseType c: AuthInfoUseType.values()) {
66 if (c.value.equals(v)) {
67 return c;
68 }
69 }
70 throw new IllegalArgumentException(v);
71 }
72
73 }