Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d9cf1aa

Browse files
committed
Add stubs for JAX-WS
1 parent 55d584b commit d9cf1aa

8 files changed

Lines changed: 1914 additions & 0 deletions

File tree

java/ql/src/semmle/code/java/frameworks/JavaxAnnotations.qll

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,13 @@ class InterceptorsAnnotation extends Annotation {
137137
* Annotations in the package `javax.jws`.
138138
*/
139139

140+
/**
141+
* A `@javax.jws.WebMethod` annotation.
142+
*/
143+
class WebMethodAnnotation extends Annotation {
144+
WebMethodAnnotation() { this.getType().hasQualifiedName("javax.jws", "WebMethod") }
145+
}
146+
140147
/**
141148
* A `@javax.jws.WebService` annotation.
142149
*/

java/ql/test/stubs/jaxws-api-2.0/LICENSE.md

Lines changed: 761 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
/*
2+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
3+
*
4+
* Copyright (c) 2005-2017 Oracle and/or its affiliates. All rights reserved.
5+
*
6+
* The contents of this file are subject to the terms of either the GNU
7+
* General Public License Version 2 only ("GPL") or the Common Development
8+
* and Distribution License("CDDL") (collectively, the "License"). You
9+
* may not use this file except in compliance with the License. You can
10+
* obtain a copy of the License at
11+
* https://oss.oracle.com/licenses/CDDL+GPL-1.1
12+
* or LICENSE.txt. See the License for the specific
13+
* language governing permissions and limitations under the License.
14+
*
15+
* When distributing the software, include this License Header Notice in each
16+
* file and include the License file at LICENSE.txt.
17+
*
18+
* GPL Classpath Exception:
19+
* Oracle designates this particular file as subject to the "Classpath"
20+
* exception as provided by Oracle in the GPL Version 2 section of the License
21+
* file that accompanied this code.
22+
*
23+
* Modifications:
24+
* If applicable, add the following below the License Header, with the fields
25+
* enclosed by brackets [] replaced by your own identifying information:
26+
* "Portions Copyright [year] [name of copyright owner]"
27+
*
28+
* Contributor(s):
29+
* If you wish your version of this file to be governed by only the CDDL or
30+
* only the GPL Version 2, indicate your decision by adding "[Contributor]
31+
* elects to include this software in this distribution under the [CDDL or GPL
32+
* Version 2] license." If you don't indicate a single choice of license, a
33+
* recipient has the option to distribute your version of this file under
34+
* either the CDDL, the GPL Version 2 or to extend the choice of license to
35+
* its licensees as provided above. However, if you add GPL Version 2 code
36+
* and therefore, elected the GPL Version 2 license, then the option applies
37+
* only if the new code is made subject to such option by the copyright
38+
* holder.
39+
*/
40+
41+
package javax.xml.ws;
42+
43+
import java.lang.annotation.Documented;
44+
import java.lang.annotation.Target;
45+
import java.lang.annotation.Retention;
46+
import java.lang.annotation.ElementType;
47+
import java.lang.annotation.RetentionPolicy;
48+
49+
/**
50+
* Used to annotate the <code>get<em>PortName</em>()</code>
51+
* methods of a generated service interface.
52+
*
53+
* <p>The information specified in this annotation is sufficient
54+
* to uniquely identify a {@code wsdl:port} element
55+
* inside a {@code wsdl:service}. The latter is
56+
* determined based on the value of the {@code WebServiceClient}
57+
* annotation on the generated service interface itself.
58+
*
59+
* @since 1.6, JAX-WS 2.0
60+
*
61+
* @see javax.xml.ws.WebServiceClient
62+
**/
63+
@Target({ElementType.METHOD})
64+
@Retention(RetentionPolicy.RUNTIME)
65+
@Documented
66+
public @interface WebEndpoint {
67+
/**
68+
* The local name of the endpoint.
69+
*
70+
* @return ocal name of the endpoint
71+
**/
72+
String name() default "";
73+
}
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
/*
2+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
3+
*
4+
* Copyright (c) 2005-2017 Oracle and/or its affiliates. All rights reserved.
5+
*
6+
* The contents of this file are subject to the terms of either the GNU
7+
* General Public License Version 2 only ("GPL") or the Common Development
8+
* and Distribution License("CDDL") (collectively, the "License"). You
9+
* may not use this file except in compliance with the License. You can
10+
* obtain a copy of the License at
11+
* https://oss.oracle.com/licenses/CDDL+GPL-1.1
12+
* or LICENSE.txt. See the License for the specific
13+
* language governing permissions and limitations under the License.
14+
*
15+
* When distributing the software, include this License Header Notice in each
16+
* file and include the License file at LICENSE.txt.
17+
*
18+
* GPL Classpath Exception:
19+
* Oracle designates this particular file as subject to the "Classpath"
20+
* exception as provided by Oracle in the GPL Version 2 section of the License
21+
* file that accompanied this code.
22+
*
23+
* Modifications:
24+
* If applicable, add the following below the License Header, with the fields
25+
* enclosed by brackets [] replaced by your own identifying information:
26+
* "Portions Copyright [year] [name of copyright owner]"
27+
*
28+
* Contributor(s):
29+
* If you wish your version of this file to be governed by only the CDDL or
30+
* only the GPL Version 2, indicate your decision by adding "[Contributor]
31+
* elects to include this software in this distribution under the [CDDL or GPL
32+
* Version 2] license." If you don't indicate a single choice of license, a
33+
* recipient has the option to distribute your version of this file under
34+
* either the CDDL, the GPL Version 2 or to extend the choice of license to
35+
* its licensees as provided above. However, if you add GPL Version 2 code
36+
* and therefore, elected the GPL Version 2 license, then the option applies
37+
* only if the new code is made subject to such option by the copyright
38+
* holder.
39+
*/
40+
41+
package javax.xml.ws;
42+
43+
import java.lang.annotation.Documented;
44+
import java.lang.annotation.Target;
45+
import java.lang.annotation.Retention;
46+
import java.lang.annotation.ElementType;
47+
import java.lang.annotation.RetentionPolicy;
48+
49+
/**
50+
* Used to annotate a generated service interface.
51+
*
52+
* <p>The information specified in this annotation is sufficient
53+
* to uniquely identify a {@code wsdl:service}
54+
* element inside a WSDL document. This {@code wsdl:service}
55+
* element represents the Web service for which the generated
56+
* service interface provides a client view.
57+
*
58+
* @since 1.6, JAX-WS 2.0
59+
**/
60+
@Target({ElementType.TYPE})
61+
@Retention(RetentionPolicy.RUNTIME)
62+
@Documented
63+
public @interface WebServiceClient {
64+
/**
65+
* The local name of the Web service.
66+
*
67+
* @return local name
68+
*/
69+
String name() default "";
70+
71+
/**
72+
* The namespace for the Web service.
73+
*
74+
* @return target namespace name
75+
*/
76+
String targetNamespace() default "";
77+
78+
/**
79+
* The location of the WSDL document for the service (a URL).
80+
*
81+
* @return location of the WSDL document (a URL)
82+
*/
83+
String wsdlLocation() default "";
84+
}
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
/*
2+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
3+
*
4+
* Copyright (c) 2005-2017 Oracle and/or its affiliates. All rights reserved.
5+
*
6+
* The contents of this file are subject to the terms of either the GNU
7+
* General Public License Version 2 only ("GPL") or the Common Development
8+
* and Distribution License("CDDL") (collectively, the "License"). You
9+
* may not use this file except in compliance with the License. You can
10+
* obtain a copy of the License at
11+
* https://oss.oracle.com/licenses/CDDL+GPL-1.1
12+
* or LICENSE.txt. See the License for the specific
13+
* language governing permissions and limitations under the License.
14+
*
15+
* When distributing the software, include this License Header Notice in each
16+
* file and include the License file at LICENSE.txt.
17+
*
18+
* GPL Classpath Exception:
19+
* Oracle designates this particular file as subject to the "Classpath"
20+
* exception as provided by Oracle in the GPL Version 2 section of the License
21+
* file that accompanied this code.
22+
*
23+
* Modifications:
24+
* If applicable, add the following below the License Header, with the fields
25+
* enclosed by brackets [] replaced by your own identifying information:
26+
* "Portions Copyright [year] [name of copyright owner]"
27+
*
28+
* Contributor(s):
29+
* If you wish your version of this file to be governed by only the CDDL or
30+
* only the GPL Version 2, indicate your decision by adding "[Contributor]
31+
* elects to include this software in this distribution under the [CDDL or GPL
32+
* Version 2] license." If you don't indicate a single choice of license, a
33+
* recipient has the option to distribute your version of this file under
34+
* either the CDDL, the GPL Version 2 or to extend the choice of license to
35+
* its licensees as provided above. However, if you add GPL Version 2 code
36+
* and therefore, elected the GPL Version 2 license, then the option applies
37+
* only if the new code is made subject to such option by the copyright
38+
* holder.
39+
*/
40+
41+
package javax.xml.ws;
42+
43+
import java.lang.annotation.Documented;
44+
import java.lang.annotation.Target;
45+
import java.lang.annotation.Retention;
46+
import java.lang.annotation.ElementType;
47+
import java.lang.annotation.RetentionPolicy;
48+
/**
49+
* Used to annotate a Provider implementation class.
50+
*
51+
* @since 1.6, JAX-WS 2.0
52+
* @see javax.xml.ws.Provider
53+
*/
54+
@Target(ElementType.TYPE)
55+
@Retention(RetentionPolicy.RUNTIME)
56+
@Documented
57+
public @interface WebServiceProvider {
58+
/**
59+
* Location of the WSDL description for the service.
60+
*
61+
* @return location of the WSDL description
62+
*/
63+
String wsdlLocation() default "";
64+
65+
/**
66+
* Service name.
67+
*
68+
* @return service name
69+
*/
70+
String serviceName() default "";
71+
72+
/**
73+
* Target namespace for the service
74+
*
75+
* @return target namespace
76+
*/
77+
String targetNamespace() default "";
78+
79+
/**
80+
* Port name.
81+
*
82+
* @return port name
83+
*/
84+
String portName() default "";
85+
}

0 commit comments

Comments
 (0)