KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > ws > jaxme > xs > xml > XsEUnion


1 /*
2  * Copyright 2003, 2004 The Apache Software Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15
16  */

17 package org.apache.ws.jaxme.xs.xml;
18
19
20 /** <p>Interface of <code>xs:union</code>, following the
21  * specification below:
22  * <pre>
23  * &lt;xs:element name="union" id="union"&gt;
24  * &lt;xs:complexType&gt;
25  * &lt;xs:annotation&gt;
26  * &lt;xs:documentation
27  * source="http://www.w3.org/TR/xmlschema-2/#element-union"&gt;
28  * memberTypes attribute must be non-empty or there must be
29  * at least one simpleType child
30  * &lt;/xs:documentation&gt;
31  * &lt;/xs:annotation&gt;
32  * &lt;xs:complexContent&gt;
33  * &lt;xs:extension base="xs:annotated"&gt;
34  * &lt;xs:sequence&gt;
35  * &lt;xs:element name="simpleType" type="xs:localSimpleType"
36  * minOccurs="0" maxOccurs="unbounded"/&gt;
37  * &lt;/xs:sequence&gt;
38  * &lt;xs:attribute name="memberTypes" use="optional"&gt;
39  * &lt;xs:simpleType&gt;
40  * &lt;xs:list itemType="xs:QName"/&gt;
41  * &lt;/xs:simpleType&gt;
42  * &lt;/xs:attribute&gt;
43  * &lt;/xs:extension&gt;
44  * &lt;/xs:complexContent&gt;
45  * &lt;/xs:complexType&gt;
46  * &lt;/xs:element&gt;
47  * </pre></p>
48  *
49  * @author <a HREF="mailto:joe@ispsoft.de">Jochen Wiedmann</a>
50  */

51 public interface XsEUnion extends XsTAnnotated {
52   /** <p>Creates a new, local simple type as a member type of the union.</p>
53    */

54   public XsTLocalSimpleType createSimpleType();
55
56   /** <p>Returns an array of member types which have been
57    * created using {@link #createSimpleType()}.</p>
58    */

59   public XsTLocalSimpleType[] getSimpleTypes();
60
61   /** <p>Sets the qualified names of simple types being used as member
62    * types of the union.</p>
63    */

64   public void setMemberTypes(XsQName[] pTypes);
65
66   /** <p>Returns an array of member types which have been added
67    * using {@link #setMemberTypes(XsQName[])}. This array may be null,
68    * if the method {@link #setMemberTypes(XsQName[])} wasn't invoked
69    * at all, or it may be the empty array, if an empty string was
70    * passed as argument to the method.</p>
71    */

72   public XsQName[] getMemberTypes();
73 }
74
Popular Tags