| 1 | /* |
|---|
| 2 | * Copyright 2009, 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 | package org.docx4j.customXmlProperties; |
|---|
| 22 | |
|---|
| 23 | import java.util.ArrayList; |
|---|
| 24 | import java.util.List; |
|---|
| 25 | import javax.xml.bind.annotation.XmlAccessType; |
|---|
| 26 | import javax.xml.bind.annotation.XmlAccessorType; |
|---|
| 27 | import javax.xml.bind.annotation.XmlAttribute; |
|---|
| 28 | import javax.xml.bind.annotation.XmlRootElement; |
|---|
| 29 | import javax.xml.bind.annotation.XmlType; |
|---|
| 30 | |
|---|
| 31 | |
|---|
| 32 | /** |
|---|
| 33 | * <p>Java class for anonymous complex type. |
|---|
| 34 | * |
|---|
| 35 | * <p>The following schema fragment specifies the expected content contained within this class. |
|---|
| 36 | * |
|---|
| 37 | * <pre> |
|---|
| 38 | * <complexType> |
|---|
| 39 | * <complexContent> |
|---|
| 40 | * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> |
|---|
| 41 | * <sequence> |
|---|
| 42 | * <element name="schemaRef" maxOccurs="unbounded" minOccurs="0"> |
|---|
| 43 | * <complexType> |
|---|
| 44 | * <complexContent> |
|---|
| 45 | * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> |
|---|
| 46 | * <attribute name="uri" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /> |
|---|
| 47 | * </restriction> |
|---|
| 48 | * </complexContent> |
|---|
| 49 | * </complexType> |
|---|
| 50 | * </element> |
|---|
| 51 | * </sequence> |
|---|
| 52 | * </restriction> |
|---|
| 53 | * </complexContent> |
|---|
| 54 | * </complexType> |
|---|
| 55 | * </pre> |
|---|
| 56 | * |
|---|
| 57 | * |
|---|
| 58 | */ |
|---|
| 59 | @XmlAccessorType(XmlAccessType.FIELD) |
|---|
| 60 | @XmlType(name = "", propOrder = { |
|---|
| 61 | "schemaRef" |
|---|
| 62 | }) |
|---|
| 63 | @XmlRootElement(name = "schemaRefs") |
|---|
| 64 | public class SchemaRefs { |
|---|
| 65 | |
|---|
| 66 | protected List<SchemaRefs.SchemaRef> schemaRef; |
|---|
| 67 | |
|---|
| 68 | /** |
|---|
| 69 | * Gets the value of the schemaRef property. |
|---|
| 70 | * |
|---|
| 71 | * <p> |
|---|
| 72 | * This accessor method returns a reference to the live list, |
|---|
| 73 | * not a snapshot. Therefore any modification you make to the |
|---|
| 74 | * returned list will be present inside the JAXB object. |
|---|
| 75 | * This is why there is not a <CODE>set</CODE> method for the schemaRef property. |
|---|
| 76 | * |
|---|
| 77 | * <p> |
|---|
| 78 | * For example, to add a new item, do as follows: |
|---|
| 79 | * <pre> |
|---|
| 80 | * getSchemaRef().add(newItem); |
|---|
| 81 | * </pre> |
|---|
| 82 | * |
|---|
| 83 | * |
|---|
| 84 | * <p> |
|---|
| 85 | * Objects of the following type(s) are allowed in the list |
|---|
| 86 | * {@link SchemaRefs.SchemaRef } |
|---|
| 87 | * |
|---|
| 88 | * |
|---|
| 89 | */ |
|---|
| 90 | public List<SchemaRefs.SchemaRef> getSchemaRef() { |
|---|
| 91 | if (schemaRef == null) { |
|---|
| 92 | schemaRef = new ArrayList<SchemaRefs.SchemaRef>(); |
|---|
| 93 | } |
|---|
| 94 | return this.schemaRef; |
|---|
| 95 | } |
|---|
| 96 | |
|---|
| 97 | |
|---|
| 98 | /** |
|---|
| 99 | * <p>Java class for anonymous complex type. |
|---|
| 100 | * |
|---|
| 101 | * <p>The following schema fragment specifies the expected content contained within this class. |
|---|
| 102 | * |
|---|
| 103 | * <pre> |
|---|
| 104 | * <complexType> |
|---|
| 105 | * <complexContent> |
|---|
| 106 | * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> |
|---|
| 107 | * <attribute name="uri" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /> |
|---|
| 108 | * </restriction> |
|---|
| 109 | * </complexContent> |
|---|
| 110 | * </complexType> |
|---|
| 111 | * </pre> |
|---|
| 112 | * |
|---|
| 113 | * |
|---|
| 114 | */ |
|---|
| 115 | @XmlAccessorType(XmlAccessType.FIELD) |
|---|
| 116 | @XmlType(name = "") |
|---|
| 117 | public static class SchemaRef { |
|---|
| 118 | |
|---|
| 119 | @XmlAttribute(namespace = "http://schemas.openxmlformats.org/officeDocument/2006/customXml", required = true) |
|---|
| 120 | protected String uri; |
|---|
| 121 | |
|---|
| 122 | /** |
|---|
| 123 | * Gets the value of the uri property. |
|---|
| 124 | * |
|---|
| 125 | * @return |
|---|
| 126 | * possible object is |
|---|
| 127 | * {@link String } |
|---|
| 128 | * |
|---|
| 129 | */ |
|---|
| 130 | public String getUri() { |
|---|
| 131 | return uri; |
|---|
| 132 | } |
|---|
| 133 | |
|---|
| 134 | /** |
|---|
| 135 | * Sets the value of the uri property. |
|---|
| 136 | * |
|---|
| 137 | * @param value |
|---|
| 138 | * allowed object is |
|---|
| 139 | * {@link String } |
|---|
| 140 | * |
|---|
| 141 | */ |
|---|
| 142 | public void setUri(String value) { |
|---|
| 143 | this.uri = value; |
|---|
| 144 | } |
|---|
| 145 | |
|---|
| 146 | } |
|---|
| 147 | |
|---|
| 148 | } |
|---|