source: trunk/docx4j/src/main/java/org/docx4j/wml/STColorSchemeIndex.java @ 940

Revision 940, 3.7 KB checked in by jharrop, 3 years ago (diff)

Fix all 11 instances of "Two classes have the same XML type name .. Use .. @XmlType?.namespace to assign different names to them."

Line 
1/*
2 *  Copyright 2007-2008, Plutext Pty Ltd.
3 *   
4 *  This file is part of docx4j.
5
6    docx4j is licensed under the Apache License, Version 2.0 (the "License");
7    you may not use this file except in compliance with the License.
8
9    You may obtain a copy of the License at
10
11        http://www.apache.org/licenses/LICENSE-2.0
12
13    Unless required by applicable law or agreed to in writing, software
14    distributed under the License is distributed on an "AS IS" BASIS,
15    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16    See the License for the specific language governing permissions and
17    limitations under the License.
18
19 */
20
21
22package org.docx4j.wml;
23
24import javax.xml.bind.annotation.XmlEnum;
25import javax.xml.bind.annotation.XmlEnumValue;
26import javax.xml.bind.annotation.XmlType;
27
28
29/**
30 * <p>Java class for ST_ColorSchemeIndex.
31 *
32 * <p>The following schema fragment specifies the expected content contained within this class.
33 * <p>
34 * <pre>
35 * &lt;simpleType name="ST_ColorSchemeIndex">
36 *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
37 *     &lt;enumeration value="dark1"/>
38 *     &lt;enumeration value="light1"/>
39 *     &lt;enumeration value="dark2"/>
40 *     &lt;enumeration value="light2"/>
41 *     &lt;enumeration value="accent1"/>
42 *     &lt;enumeration value="accent2"/>
43 *     &lt;enumeration value="accent3"/>
44 *     &lt;enumeration value="accent4"/>
45 *     &lt;enumeration value="accent5"/>
46 *     &lt;enumeration value="accent6"/>
47 *     &lt;enumeration value="hyperlink"/>
48 *     &lt;enumeration value="followedHyperlink"/>
49 *   &lt;/restriction>
50 * &lt;/simpleType>
51 * </pre>
52 *
53 */
54@XmlType(namespace = "http://schemas.openxmlformats.org/wordprocessingml/2006/main", name = "ST_ColorSchemeIndex")
55@XmlEnum
56public enum STColorSchemeIndex {
57
58
59    /**
60     * Dark 1 Theme Color
61     *                                          Reference
62     *
63     */
64    @XmlEnumValue("dark1")
65    DARK_1("dark1"),
66
67    /**
68     * Light 1 Theme Color
69     *                                          Reference
70     *
71     */
72    @XmlEnumValue("light1")
73    LIGHT_1("light1"),
74
75    /**
76     * Dark 2 Theme Color
77     *                                          Reference
78     *
79     */
80    @XmlEnumValue("dark2")
81    DARK_2("dark2"),
82
83    /**
84     * Light 2 Theme Color
85     *                                          Reference
86     *
87     */
88    @XmlEnumValue("light2")
89    LIGHT_2("light2"),
90
91    /**
92     * Accent 1 Theme Color
93     *                                          Reference
94     *
95     */
96    @XmlEnumValue("accent1")
97    ACCENT_1("accent1"),
98
99    /**
100     * Accent 2 Theme Color
101     *                                          Reference
102     *
103     */
104    @XmlEnumValue("accent2")
105    ACCENT_2("accent2"),
106
107    /**
108     * Accent 3 Theme Color
109     *                                          Reference
110     *
111     */
112    @XmlEnumValue("accent3")
113    ACCENT_3("accent3"),
114
115    /**
116     * Accent4 Theme Color
117     *                                          Reference
118     *
119     */
120    @XmlEnumValue("accent4")
121    ACCENT_4("accent4"),
122
123    /**
124     * Accent5 Theme Color
125     *                                          Reference
126     *
127     */
128    @XmlEnumValue("accent5")
129    ACCENT_5("accent5"),
130
131    /**
132     * Accent 6 Theme Color
133     *                                          Reference
134     *
135     */
136    @XmlEnumValue("accent6")
137    ACCENT_6("accent6"),
138
139    /**
140     * Hyperlink Theme Color
141     *                                          Reference
142     *
143     */
144    @XmlEnumValue("hyperlink")
145    HYPERLINK("hyperlink"),
146
147    /**
148     * Followed Hyperlink Theme Color
149     *                                          Reference
150     *
151     */
152    @XmlEnumValue("followedHyperlink")
153    FOLLOWED_HYPERLINK("followedHyperlink");
154    private final String value;
155
156    STColorSchemeIndex(String v) {
157        value = v;
158    }
159
160    public String value() {
161        return value;
162    }
163
164    public static STColorSchemeIndex fromValue(String v) {
165        for (STColorSchemeIndex c: STColorSchemeIndex.values()) {
166            if (c.value.equals(v)) {
167                return c;
168            }
169        }
170        throw new IllegalArgumentException(v);
171    }
172
173}
Note: See TracBrowser for help on using the repository browser.