1<!--***********************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  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,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 ***********************************************************-->
21
22<xsd:schema version="0.9"
23            xmlns:xsd="http://www.w3.org/2001/XMLSchema"
24            xmlns="http://jfreereport.sourceforge.net/namespaces/engine/openoffice/stylemapper"
25            targetNamespace="http://jfreereport.sourceforge.net/namespaces/engine/openoffice/stylemapper"
26            attributeFormDefault="unqualified">
27    <xsd:annotation>
28        <xsd:documentation>
29      This schema describes the format of the stylemapper definition file.
30      The stylemapper declares what style-families are referenced by an element.
31        </xsd:documentation>
32    </xsd:annotation>
33
34    <xsd:simpleType name="styleNameRefType">
35        <xsd:restriction base="xsd:NMTOKEN">
36            <xsd:enumeration value="styleNameRef"/>
37            <xsd:enumeration value="styleNameRefs"/>
38        </xsd:restriction>
39    </xsd:simpleType>
40
41    <xsd:simpleType name="styleFamilyType">
42        <xsd:restriction base="xsd:NMTOKEN">
43            <xsd:enumeration value="paragraph"/>
44            <xsd:enumeration value="text"/>
45            <xsd:enumeration value="section"/>
46            <xsd:enumeration value="table"/>
47            <xsd:enumeration value="table-column"/>
48            <xsd:enumeration value="table-row"/>
49            <xsd:enumeration value="table-cell"/>
50            <xsd:enumeration value="table-page"/>
51            <xsd:enumeration value="chart"/>
52            <xsd:enumeration value="default"/>
53            <xsd:enumeration value="drawing-page"/>
54            <xsd:enumeration value="graphic"/>
55            <xsd:enumeration value="presentation"/>
56            <xsd:enumeration value="control"/>
57            <xsd:enumeration value="ruby"/>
58            <xsd:enumeration value="custom-shape"/>
59        </xsd:restriction>
60    </xsd:simpleType>
61
62    <xsd:element name="mapping">
63        <xsd:complexType>
64            <xsd:attribute name="element-namespace" use="required" type="xsd:anyURI"/>
65            <xsd:attribute name="element-name"  use="required" type="xsd:NCName"/>
66            <xsd:attribute name="attribute-namespace"  use="required" type="xsd:anyURI"/>
67            <xsd:attribute name="attribute-name"  use="required" type="xsd:NCName"/>
68            <xsd:attribute name="type"  use="required" type="styleNameRefType"/>
69            <xsd:attribute name="style-family"  use="required" type="styleFamilyType"/>
70        </xsd:complexType>
71    </xsd:element>
72
73    <xsd:element name="style-mapper-definition">
74        <xsd:complexType>
75            <xsd:complexContent>
76                <xsd:restriction base="xsd:anyType">
77                    <xsd:sequence>
78                        <xsd:element ref="mapping" minOccurs="0" maxOccurs="unbounded"/>
79                    </xsd:sequence>
80                </xsd:restriction>
81            </xsd:complexContent>
82        </xsd:complexType>
83    </xsd:element>
84
85</xsd:schema>
86