This project has retired. For details please refer to its Attic page.
EnumServiceException xref

1   
2   package org.apache.chemistry.opencmis.commons.impl.jaxb;
3   
4   import javax.xml.bind.annotation.XmlEnum;
5   import javax.xml.bind.annotation.XmlEnumValue;
6   import javax.xml.bind.annotation.XmlType;
7   
8   
9   /**
10   * <p>Java class for enumServiceException.
11   * 
12   * <p>The following schema fragment specifies the expected content contained within this class.
13   * <p>
14   * <pre>
15   * &lt;simpleType name="enumServiceException">
16   *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
17   *     &lt;enumeration value="constraint"/>
18   *     &lt;enumeration value="nameConstraintViolation"/>
19   *     &lt;enumeration value="contentAlreadyExists"/>
20   *     &lt;enumeration value="filterNotValid"/>
21   *     &lt;enumeration value="invalidArgument"/>
22   *     &lt;enumeration value="notSupported"/>
23   *     &lt;enumeration value="objectNotFound"/>
24   *     &lt;enumeration value="permissionDenied"/>
25   *     &lt;enumeration value="runtime"/>
26   *     &lt;enumeration value="storage"/>
27   *     &lt;enumeration value="streamNotSupported"/>
28   *     &lt;enumeration value="updateConflict"/>
29   *     &lt;enumeration value="versioning"/>
30   *   &lt;/restriction>
31   * &lt;/simpleType>
32   * </pre>
33   * 
34   */
35  @XmlType(name = "enumServiceException")
36  @XmlEnum
37  public enum EnumServiceException {
38  
39      @XmlEnumValue("constraint")
40      CONSTRAINT("constraint"),
41      @XmlEnumValue("nameConstraintViolation")
42      NAME_CONSTRAINT_VIOLATION("nameConstraintViolation"),
43      @XmlEnumValue("contentAlreadyExists")
44      CONTENT_ALREADY_EXISTS("contentAlreadyExists"),
45      @XmlEnumValue("filterNotValid")
46      FILTER_NOT_VALID("filterNotValid"),
47      @XmlEnumValue("invalidArgument")
48      INVALID_ARGUMENT("invalidArgument"),
49      @XmlEnumValue("notSupported")
50      NOT_SUPPORTED("notSupported"),
51      @XmlEnumValue("objectNotFound")
52      OBJECT_NOT_FOUND("objectNotFound"),
53      @XmlEnumValue("permissionDenied")
54      PERMISSION_DENIED("permissionDenied"),
55      @XmlEnumValue("runtime")
56      RUNTIME("runtime"),
57      @XmlEnumValue("storage")
58      STORAGE("storage"),
59      @XmlEnumValue("streamNotSupported")
60      STREAM_NOT_SUPPORTED("streamNotSupported"),
61      @XmlEnumValue("updateConflict")
62      UPDATE_CONFLICT("updateConflict"),
63      @XmlEnumValue("versioning")
64      VERSIONING("versioning");
65      private final String value;
66  
67      EnumServiceException(String v) {
68          value = v;
69      }
70  
71      public String value() {
72          return value;
73      }
74  
75      public static EnumServiceException fromValue(String v) {
76          for (EnumServiceException c: EnumServiceException.values()) {
77              if (c.value.equals(v)) {
78                  return c;
79              }
80          }
81          throw new IllegalArgumentException(v);
82      }
83  
84  }