View Javadoc
1   /*
2    * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
3    * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4    *
5    * This code is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU General Public License version 2 only, as
7    * published by the Free Software Foundation.  Oracle designates this
8    * particular file as subject to the "Classpath" exception as provided
9    * by Oracle in the LICENSE file that accompanied this code.
10   *
11   * This code is distributed in the hope that it will be useful, but WITHOUT
12   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
14   * version 2 for more details (a copy is included in the LICENSE file that
15   * accompanied this code).
16   *
17   * You should have received a copy of the GNU General Public License version
18   * 2 along with this work; if not, write to the Free Software Foundation,
19   * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20   *
21   * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22   * or visit www.oracle.com if you need additional information or have any
23   * questions.
24   */
25  
26  package com.sun.tools.internal.ws.wsdl.document.jaxws;
27  
28  import com.sun.tools.internal.ws.wsdl.parser.Constants;
29  
30  import javax.xml.namespace.QName;
31  
32  /**
33   * @author Vivek Pandey
34   *
35   */
36  public interface JAXWSBindingsConstants {
37  
38      static final String NS_JAXWS_BINDINGS = "http://java.sun.com/xml/ns/jaxws";
39      static final String NS_JAXB_BINDINGS = "http://java.sun.com/xml/ns/jaxb";
40      static final String NS_XJC_BINDINGS = "http://java.sun.com/xml/ns/jaxb/xjc";
41  
42      /**
43       * jaxws:bindings schema component
44       *
45       * <jaxws:bindings wsdlLocation="xs:anyURI"? node="xs:string"?
46       *      version="string"?> binding declarations...
47       * </jaxws:bindings>
48       *
49       * wsdlLocation="xs:anyURI"? node="xs:string"? version="string"?> binding
50       * declarations... </jaxws:bindings>
51       *
52       * <code>@wsdlLocation</code> A URI pointing to a WSDL file establishing the scope of the
53       *               contents of this binding declaration. It MUST NOT be
54       *               present if the binding declaration is used as an extension
55       *               inside a WSDL document or if there is an ancestor binding
56       *               declaration that contains this attribute.
57       *
58       * <code>@node</code> An XPath expression pointing to the element in the WSDL file in
59       *       scope that this binding declaration is attached to.
60       *
61       * <code>@version</code> A version identifier. It MAY only appear on jaxws:bindings
62       *          elements that don't have any jaxws:bindings ancestors (i.e. on
63       *          outermost binding declarations).
64       */
65      static final QName JAXWS_BINDINGS = new QName(NS_JAXWS_BINDINGS, "bindings");
66      static final String WSDL_LOCATION_ATTR = "wsdlLocation";
67      static final String NODE_ATTR = "node";
68      static final String VERSION_ATTR = "version";
69  
70      /*
71       * <jaxws:package name="xs:string">? <jaxws:javadoc>xs:string
72       * </jaxws:javadoc> </jaxws:package>
73       */
74      static final QName PACKAGE = new QName(NS_JAXWS_BINDINGS, "package");
75      static final String NAME_ATTR = "name";
76      static final QName JAVADOC = new QName(NS_JAXWS_BINDINGS, "javadoc");
77  
78      /*
79       * <jaxws:enableWrapperStyle>xs:boolean </jaxws:enableWrapperStyle>?
80       */
81      static final QName ENABLE_WRAPPER_STYLE = new QName(NS_JAXWS_BINDINGS, "enableWrapperStyle");
82  
83      /*
84       * <jaxws:enableAsynchronousMapping>xs:boolean
85       *      </jaxws:enableAsynchronousMapping>?
86       */
87      static final QName ENABLE_ASYNC_MAPPING = new QName(NS_JAXWS_BINDINGS, "enableAsyncMapping");
88  
89      /*
90       * <jaxws:enableAdditionalSOAPHeaderMapping>xs:boolean</jaxws:enableAdditionalSOAPHeaderMapping>?
91       */
92      static final QName ENABLE_ADDITIONAL_SOAPHEADER_MAPPING = new QName(NS_JAXWS_BINDINGS, "enableAdditionalSOAPHeaderMapping");
93  
94      /*
95       * <jaxws:enableMIMEContent>xs:boolean</jaxws:enableMIMEContent>?
96       */
97      static final QName ENABLE_MIME_CONTENT = new QName(NS_JAXWS_BINDINGS, "enableMIMEContent");
98  
99      /*
100      * <jaxwsc:provider>xs:boolean</jaxws:provider>?
101      */
102     static final QName PROVIDER = new QName(NS_JAXWS_BINDINGS, "provider");
103 
104     /*
105      * PortType
106      *
107      * <jaxws:class name="xs:string">?
108      *  <jaxws:javadoc>xs:string</jaxws:javadoc>?
109      * </jaxws:class>
110      *
111      * <jaxws:enableWrapperStyle>
112      *  xs:boolean
113      * </jaxws:enableWrapperStyle>?
114      *
115      * <jaxws:enableAsynchronousMapping>
116      *  xs:boolean
117      * </jaxws:enableAsynchronousMapping>?
118      *
119      */
120 
121     static final QName CLASS = new QName(NS_JAXWS_BINDINGS, "class");
122 
123     /*
124      * PortType WSDLOperation
125      *
126      * <jaxws:method name="xs:string">?
127      *   <jaxws:javadoc>xs:string</jaxws:javadoc>?
128      * </jaxws:method>
129      *
130      * <jaxws:enableWrapperStyle>
131      *  xs:boolean
132      * </jaxws:enableWrapperStyle>?
133      *
134      * <jaxws:enableAsyncMapping>
135      *  xs:boolean
136      * </jaxws:enableAsyncMapping>?
137      *
138      * <jaxws:parameter part="xs:string"
139      *      childElementName="xs:QName"?
140      *      name="xs:string"/>*
141      */
142 
143 
144 
145     static final QName METHOD = new QName(NS_JAXWS_BINDINGS, "method");
146     static final QName PARAMETER = new QName(NS_JAXWS_BINDINGS, "parameter");
147     static final String PART_ATTR = "part";
148     static final String ELEMENT_ATTR = "childElementName";
149 
150     /*
151      * Binding
152      *
153      * <jaxws:enableAdditionalSOAPHeaderMapping>
154      *  xs:boolean
155      * </jaxws:enableAdditionalSOAPHeaderMapping>?
156      *
157      * <jaxws:enableMIMEContent>
158      *  xs:boolean
159      * </jaxws:enableMIMEContent>?
160      */
161 
162     /*
163      * WSDLBoundOperation
164      *
165      * <jaxws:enableAdditionalSOAPHeaderMapping>
166      *  xs:boolean
167      * </jaxws:enableAdditionalSOAPHeaderMapping>?
168      *
169      * <jaxws:enableMIMEContent>
170      *  xs:boolean
171      * </jaxws:enableMIMEContent>?
172      *
173      * <jaxws:parameter part="xs:string"
174      *                  element="xs:QName"?
175      *                  name="xs:string"/>*
176      *
177      * <jaxws:exception part="xs:string">*
178      *  <jaxws:class name="xs:string">?
179      *      <jaxws:javadoc>xs:string</jaxws:javadoc>?
180      *  </jaxws:class>
181      * </jaxws:exception>
182      */
183 
184     static final QName EXCEPTION = new QName(NS_JAXWS_BINDINGS, "exception");
185 
186 
187     /*
188      * jaxb:bindgs QName
189      */
190     static final QName JAXB_BINDINGS = new QName(NS_JAXB_BINDINGS, "bindings");
191     static final String JAXB_BINDING_VERSION = "2.0";
192     static final QName XSD_APPINFO = new QName(Constants.NS_XSD, "appinfo");
193     static final QName XSD_ANNOTATION = new QName(Constants.NS_XSD, "annotation");
194 }