source: trunk/docx4j/src/main/java/org/docx4j/wml/UnderlineEnumeration.java @ 359

Revision 359, 4.4 KB checked in by jharrop, 4 years ago (diff)

Change CT_FldChar to FldChar?;
Style is freestanding, rather than an inner class of Styles.
(Other changes largely whitespace in license header)

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 UnderlineEnumeration.
31 *
32 * <p>The following schema fragment specifies the expected content contained within this class.
33 * <p>
34 * <pre>
35 * &lt;simpleType name="UnderlineEnumeration">
36 *   &lt;restriction base="{http://www.w3.org/2001/XMLSchema}string">
37 *     &lt;enumeration value="single"/>
38 *     &lt;enumeration value="words"/>
39 *     &lt;enumeration value="double"/>
40 *     &lt;enumeration value="thick"/>
41 *     &lt;enumeration value="dotted"/>
42 *     &lt;enumeration value="dottedHeavy"/>
43 *     &lt;enumeration value="dash"/>
44 *     &lt;enumeration value="dashedHeavy"/>
45 *     &lt;enumeration value="dashLong"/>
46 *     &lt;enumeration value="dashLongHeavy"/>
47 *     &lt;enumeration value="dotDash"/>
48 *     &lt;enumeration value="dashDotHeavy"/>
49 *     &lt;enumeration value="dotDotDash"/>
50 *     &lt;enumeration value="dashDotDotHeavy"/>
51 *     &lt;enumeration value="wave"/>
52 *     &lt;enumeration value="wavyHeavy"/>
53 *     &lt;enumeration value="wavyDouble"/>
54 *     &lt;enumeration value="none"/>
55 *   &lt;/restriction>
56 * &lt;/simpleType>
57 * </pre>
58 *
59 */
60@XmlType(name = "UnderlineEnumeration")
61@XmlEnum
62public enum UnderlineEnumeration {
63
64
65    /**
66     * Single Underline
67     *
68     */
69    @XmlEnumValue("single")
70    SINGLE("single"),
71
72    /**
73     * Underline Non-Space Characters
74     *                                          Only
75     *
76     */
77    @XmlEnumValue("words")
78    WORDS("words"),
79
80    /**
81     * Double Underline
82     *
83     */
84    @XmlEnumValue("double")
85    DOUBLE("double"),
86
87    /**
88     * Thick Underline
89     *
90     */
91    @XmlEnumValue("thick")
92    THICK("thick"),
93
94    /**
95     * Dotted Underline
96     *
97     */
98    @XmlEnumValue("dotted")
99    DOTTED("dotted"),
100
101    /**
102     * Thick Dotted Underline
103     *
104     */
105    @XmlEnumValue("dottedHeavy")
106    DOTTED_HEAVY("dottedHeavy"),
107
108    /**
109     * Dashed Underline
110     *
111     */
112    @XmlEnumValue("dash")
113    DASH("dash"),
114
115    /**
116     * Thick Dashed Underline
117     *
118     */
119    @XmlEnumValue("dashedHeavy")
120    DASHED_HEAVY("dashedHeavy"),
121
122    /**
123     * Long Dashed Underline
124     *
125     */
126    @XmlEnumValue("dashLong")
127    DASH_LONG("dashLong"),
128
129    /**
130     * Thick Long Dashed
131     *                                          Underline
132     *
133     */
134    @XmlEnumValue("dashLongHeavy")
135    DASH_LONG_HEAVY("dashLongHeavy"),
136
137    /**
138     * Dash-Dot Underline
139     *
140     */
141    @XmlEnumValue("dotDash")
142    DOT_DASH("dotDash"),
143
144    /**
145     * Thick Dash-Dot
146     *                                          Underline
147     *
148     */
149    @XmlEnumValue("dashDotHeavy")
150    DASH_DOT_HEAVY("dashDotHeavy"),
151
152    /**
153     * Dash-Dot-Dot Underline
154     *
155     */
156    @XmlEnumValue("dotDotDash")
157    DOT_DOT_DASH("dotDotDash"),
158
159    /**
160     * Thick Dash-Dot-Dot
161     *                                          Underline
162     *
163     */
164    @XmlEnumValue("dashDotDotHeavy")
165    DASH_DOT_DOT_HEAVY("dashDotDotHeavy"),
166
167    /**
168     * Wave Underline
169     *
170     */
171    @XmlEnumValue("wave")
172    WAVE("wave"),
173
174    /**
175     * Heavy Wave Underline
176     *
177     */
178    @XmlEnumValue("wavyHeavy")
179    WAVY_HEAVY("wavyHeavy"),
180
181    /**
182     * Double Wave Underline
183     *
184     */
185    @XmlEnumValue("wavyDouble")
186    WAVY_DOUBLE("wavyDouble"),
187
188    /**
189     * No Underline
190     *
191     */
192    @XmlEnumValue("none")
193    NONE("none");
194    private final String value;
195
196    UnderlineEnumeration(String v) {
197        value = v;
198    }
199
200    public String value() {
201        return value;
202    }
203
204    public static UnderlineEnumeration fromValue(String v) {
205        for (UnderlineEnumeration c: UnderlineEnumeration.values()) {
206            if (c.value.equals(v)) {
207                return c;
208            }
209        }
210        throw new IllegalArgumentException(v);
211    }
212
213}
Note: See TracBrowser for help on using the repository browser.