| 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 | |
|---|
| 22 | package org.docx4j.dml; |
|---|
| 23 | |
|---|
| 24 | import javax.xml.bind.annotation.XmlEnum; |
|---|
| 25 | import javax.xml.bind.annotation.XmlEnumValue; |
|---|
| 26 | import 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 | * <simpleType name="ST_ColorSchemeIndex"> |
|---|
| 36 | * <restriction base="{http://www.w3.org/2001/XMLSchema}token"> |
|---|
| 37 | * <enumeration value="dk1"/> |
|---|
| 38 | * <enumeration value="lt1"/> |
|---|
| 39 | * <enumeration value="dk2"/> |
|---|
| 40 | * <enumeration value="lt2"/> |
|---|
| 41 | * <enumeration value="accent1"/> |
|---|
| 42 | * <enumeration value="accent2"/> |
|---|
| 43 | * <enumeration value="accent3"/> |
|---|
| 44 | * <enumeration value="accent4"/> |
|---|
| 45 | * <enumeration value="accent5"/> |
|---|
| 46 | * <enumeration value="accent6"/> |
|---|
| 47 | * <enumeration value="hlink"/> |
|---|
| 48 | * <enumeration value="folHlink"/> |
|---|
| 49 | * </restriction> |
|---|
| 50 | * </simpleType> |
|---|
| 51 | * </pre> |
|---|
| 52 | * |
|---|
| 53 | */ |
|---|
| 54 | @XmlType(name = "ST_ColorSchemeIndex") |
|---|
| 55 | @XmlEnum |
|---|
| 56 | public enum STColorSchemeIndex { |
|---|
| 57 | |
|---|
| 58 | |
|---|
| 59 | /** |
|---|
| 60 | * Dark 1 |
|---|
| 61 | * |
|---|
| 62 | */ |
|---|
| 63 | @XmlEnumValue("dk1") |
|---|
| 64 | DK_1("dk1"), |
|---|
| 65 | |
|---|
| 66 | /** |
|---|
| 67 | * Light 1 |
|---|
| 68 | * |
|---|
| 69 | */ |
|---|
| 70 | @XmlEnumValue("lt1") |
|---|
| 71 | LT_1("lt1"), |
|---|
| 72 | |
|---|
| 73 | /** |
|---|
| 74 | * Dark 2 |
|---|
| 75 | * |
|---|
| 76 | */ |
|---|
| 77 | @XmlEnumValue("dk2") |
|---|
| 78 | DK_2("dk2"), |
|---|
| 79 | |
|---|
| 80 | /** |
|---|
| 81 | * Light 2 |
|---|
| 82 | * |
|---|
| 83 | */ |
|---|
| 84 | @XmlEnumValue("lt2") |
|---|
| 85 | LT_2("lt2"), |
|---|
| 86 | |
|---|
| 87 | /** |
|---|
| 88 | * Accent 1 |
|---|
| 89 | * |
|---|
| 90 | */ |
|---|
| 91 | @XmlEnumValue("accent1") |
|---|
| 92 | ACCENT_1("accent1"), |
|---|
| 93 | |
|---|
| 94 | /** |
|---|
| 95 | * Accent 2 |
|---|
| 96 | * |
|---|
| 97 | */ |
|---|
| 98 | @XmlEnumValue("accent2") |
|---|
| 99 | ACCENT_2("accent2"), |
|---|
| 100 | |
|---|
| 101 | /** |
|---|
| 102 | * Accent 3 |
|---|
| 103 | * |
|---|
| 104 | */ |
|---|
| 105 | @XmlEnumValue("accent3") |
|---|
| 106 | ACCENT_3("accent3"), |
|---|
| 107 | |
|---|
| 108 | /** |
|---|
| 109 | * Accent 4 |
|---|
| 110 | * |
|---|
| 111 | */ |
|---|
| 112 | @XmlEnumValue("accent4") |
|---|
| 113 | ACCENT_4("accent4"), |
|---|
| 114 | |
|---|
| 115 | /** |
|---|
| 116 | * Accent 5 |
|---|
| 117 | * |
|---|
| 118 | */ |
|---|
| 119 | @XmlEnumValue("accent5") |
|---|
| 120 | ACCENT_5("accent5"), |
|---|
| 121 | |
|---|
| 122 | /** |
|---|
| 123 | * Accent 6 |
|---|
| 124 | * |
|---|
| 125 | */ |
|---|
| 126 | @XmlEnumValue("accent6") |
|---|
| 127 | ACCENT_6("accent6"), |
|---|
| 128 | |
|---|
| 129 | /** |
|---|
| 130 | * Hyperlink |
|---|
| 131 | * |
|---|
| 132 | */ |
|---|
| 133 | @XmlEnumValue("hlink") |
|---|
| 134 | HLINK("hlink"), |
|---|
| 135 | |
|---|
| 136 | /** |
|---|
| 137 | * |
|---|
| 138 | * Followed Hyperlink |
|---|
| 139 | * |
|---|
| 140 | * |
|---|
| 141 | */ |
|---|
| 142 | @XmlEnumValue("folHlink") |
|---|
| 143 | FOL_HLINK("folHlink"); |
|---|
| 144 | private final String value; |
|---|
| 145 | |
|---|
| 146 | STColorSchemeIndex(String v) { |
|---|
| 147 | value = v; |
|---|
| 148 | } |
|---|
| 149 | |
|---|
| 150 | public String value() { |
|---|
| 151 | return value; |
|---|
| 152 | } |
|---|
| 153 | |
|---|
| 154 | public static STColorSchemeIndex fromValue(String v) { |
|---|
| 155 | for (STColorSchemeIndex c: STColorSchemeIndex.values()) { |
|---|
| 156 | if (c.value.equals(v)) { |
|---|
| 157 | return c; |
|---|
| 158 | } |
|---|
| 159 | } |
|---|
| 160 | throw new IllegalArgumentException(v); |
|---|
| 161 | } |
|---|
| 162 | |
|---|
| 163 | } |
|---|