source: trunk/docx4j/src/main/java/org/docx4j/vml/CTTextbox.java @ 1461

Revision 1461, 7.0 KB checked in by jharrop, 14 months ago (diff)

VML generated classes, based on ECMA 376 1ed (rather than earlier draft).
Includes @XmlType? namespace annotations from revs 940 and 1129.

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.vml;
23
24import javax.xml.bind.Unmarshaller;
25import javax.xml.bind.annotation.XmlAccessType;
26import javax.xml.bind.annotation.XmlAccessorType;
27import javax.xml.bind.annotation.XmlAnyElement;
28import javax.xml.bind.annotation.XmlAttribute;
29import javax.xml.bind.annotation.XmlElement;
30import javax.xml.bind.annotation.XmlTransient;
31import javax.xml.bind.annotation.XmlType;
32import org.docx4j.vml.officedrawing.STInsetMode;
33import org.docx4j.vml.officedrawing.STTrueFalse;
34import org.docx4j.wml.CTTxbxContent;
35import org.jvnet.jaxb2_commons.ppp.Child;
36import org.w3c.dom.Element;
37
38
39/**
40 * <p>Java class for CT_Textbox complex type.
41 *
42 * <p>The following schema fragment specifies the expected content contained within this class.
43 *
44 * <pre>
45 * &lt;complexType name="CT_Textbox">
46 *   &lt;complexContent>
47 *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
48 *       &lt;choice>
49 *         &lt;element ref="{http://schemas.openxmlformats.org/wordprocessingml/2006/main}txbxContent" minOccurs="0"/>
50 *         &lt;any processContents='skip' namespace=''/>
51 *       &lt;/choice>
52 *       &lt;attGroup ref="{urn:schemas-microsoft-com:vml}AG_Style"/>
53 *       &lt;attGroup ref="{urn:schemas-microsoft-com:vml}AG_Id"/>
54 *       &lt;attribute name="inset" type="{http://www.w3.org/2001/XMLSchema}string" />
55 *       &lt;attribute ref="{urn:schemas-microsoft-com:office:office}singleclick"/>
56 *       &lt;attribute ref="{urn:schemas-microsoft-com:office:office}insetmode"/>
57 *     &lt;/restriction>
58 *   &lt;/complexContent>
59 * &lt;/complexType>
60 * </pre>
61 *
62 *
63 */
64@XmlAccessorType(XmlAccessType.FIELD)
65@XmlType(name = "CT_Textbox", propOrder = {
66    "txbxContent",
67    "any"
68})
69public class CTTextbox implements Child
70{
71
72    @XmlElement(namespace = "http://schemas.openxmlformats.org/wordprocessingml/2006/main")
73    protected CTTxbxContent txbxContent;
74    @XmlAnyElement
75    protected Element any;
76    @XmlAttribute(name = "inset")
77    protected String inset;
78    @XmlAttribute(name = "singleclick", namespace = "urn:schemas-microsoft-com:office:office")
79    protected STTrueFalse singleclick;
80    @XmlAttribute(name = "insetmode", namespace = "urn:schemas-microsoft-com:office:office")
81    protected STInsetMode insetmode;
82    @XmlAttribute(name = "style")
83    protected String style;
84    @XmlAttribute(name = "id")
85    protected String vmlId;
86    @XmlTransient
87    private Object parent;
88
89    /**
90     * Gets the value of the txbxContent property.
91     *
92     * @return
93     *     possible object is
94     *     {@link CTTxbxContent }
95     *     
96     */
97    public CTTxbxContent getTxbxContent() {
98        return txbxContent;
99    }
100
101    /**
102     * Sets the value of the txbxContent property.
103     *
104     * @param value
105     *     allowed object is
106     *     {@link CTTxbxContent }
107     *     
108     */
109    public void setTxbxContent(CTTxbxContent value) {
110        this.txbxContent = value;
111    }
112
113    /**
114     * Gets the value of the any property.
115     *
116     * @return
117     *     possible object is
118     *     {@link Element }
119     *     
120     */
121    public Element getAny() {
122        return any;
123    }
124
125    /**
126     * Sets the value of the any property.
127     *
128     * @param value
129     *     allowed object is
130     *     {@link Element }
131     *     
132     */
133    public void setAny(Element value) {
134        this.any = value;
135    }
136
137    /**
138     * Gets the value of the inset property.
139     *
140     * @return
141     *     possible object is
142     *     {@link String }
143     *     
144     */
145    public String getInset() {
146        return inset;
147    }
148
149    /**
150     * Sets the value of the inset property.
151     *
152     * @param value
153     *     allowed object is
154     *     {@link String }
155     *     
156     */
157    public void setInset(String value) {
158        this.inset = value;
159    }
160
161    /**
162     * Text Box Single-Click Selection Toggle
163     *
164     * @return
165     *     possible object is
166     *     {@link STTrueFalse }
167     *     
168     */
169    public STTrueFalse getSingleclick() {
170        return singleclick;
171    }
172
173    /**
174     * Sets the value of the singleclick property.
175     *
176     * @param value
177     *     allowed object is
178     *     {@link STTrueFalse }
179     *     
180     */
181    public void setSingleclick(STTrueFalse value) {
182        this.singleclick = value;
183    }
184
185    /**
186     * Text Inset Mode
187     *
188     * @return
189     *     possible object is
190     *     {@link STInsetMode }
191     *     
192     */
193    public STInsetMode getInsetmode() {
194        if (insetmode == null) {
195            return STInsetMode.CUSTOM;
196        } else {
197            return insetmode;
198        }
199    }
200
201    /**
202     * Sets the value of the insetmode property.
203     *
204     * @param value
205     *     allowed object is
206     *     {@link STInsetMode }
207     *     
208     */
209    public void setInsetmode(STInsetMode value) {
210        this.insetmode = value;
211    }
212
213    /**
214     * Gets the value of the style property.
215     *
216     * @return
217     *     possible object is
218     *     {@link String }
219     *     
220     */
221    public String getStyle() {
222        return style;
223    }
224
225    /**
226     * Sets the value of the style property.
227     *
228     * @param value
229     *     allowed object is
230     *     {@link String }
231     *     
232     */
233    public void setStyle(String value) {
234        this.style = value;
235    }
236
237    /**
238     * Gets the value of the vmlId property.
239     *
240     * @return
241     *     possible object is
242     *     {@link String }
243     *     
244     */
245    public String getVmlId() {
246        return vmlId;
247    }
248
249    /**
250     * Sets the value of the vmlId property.
251     *
252     * @param value
253     *     allowed object is
254     *     {@link String }
255     *     
256     */
257    public void setVmlId(String value) {
258        this.vmlId = value;
259    }
260
261    /**
262     * Gets the parent object in the object tree representing the unmarshalled xml document.
263     *
264     * @return
265     *     The parent object.
266     */
267    public Object getParent() {
268        return this.parent;
269    }
270
271    public void setParent(Object parent) {
272        this.parent = parent;
273    }
274
275    /**
276     * This method is invoked by the JAXB implementation on each instance when unmarshalling completes.
277     *
278     * @param parent
279     *     The parent object in the object tree.
280     * @param unmarshaller
281     *     The unmarshaller that generated the instance.
282     */
283    public void afterUnmarshal(Unmarshaller unmarshaller, Object parent) {
284        setParent(parent);
285    }
286
287}
Note: See TracBrowser for help on using the repository browser.