Package javax.jws

Examples of javax.jws.WebResult.targetNamespace()


        String localName = webResult.name();

        if ("".equals(localName))
          localName = "return";

        if ("".equals(webResult.targetNamespace()))
          _resultName = new QName(localName);
        else
          _resultName = new QName(webResult.targetNamespace(), localName);
      }
      else {
View Full Code Here


          localName = "return";

        if ("".equals(webResult.targetNamespace()))
          _resultName = new QName(localName);
        else
          _resultName = new QName(webResult.targetNamespace(), localName);
      }
      else {
        _headerReturn = false;
        _resultName = new QName("return"); // XXX namespace?
      }
View Full Code Here

        Class<?> clz = classLoader.loadClass("org.apache.locator.LocatorService");

        Class<?> paraClass = classLoader.loadClass("org.apache.locator.types.QueryEndpoints");
        Method method = clz.getMethod("queryEndpoints", new Class[] {paraClass});
        WebResult webRes = AnnotationUtil.getPrivMethodAnnotation(method, WebResult.class);
        assertEquals("http://apache.org/locator/types", webRes.targetNamespace());
        assertEquals("queryEndpointsResponse", webRes.name());
        WebParam webParamAnn = AnnotationUtil.getWebParam(method, "queryEndpoints");
        assertEquals("http://apache.org/locator/types", webParamAnn.targetNamespace());

        method = clz.getMethod("deregisterPeerManager", new Class[] {String.class});
View Full Code Here

        env.put(ToolConstants.CFG_ALLOW_ELEMENT_REFS, "true");
        processor.setContext(env);
        processor.execute();
        Class<?> clz = classLoader.loadClass("org.apache.cxf.tools.fortest.cxf2944.WebResultService");
        WebResult webResult = AnnotationUtil.getWebResult(clz.getMethods()[0]);
        assertEquals("hello/name", webResult.targetNamespace());
        assertEquals("name", webResult.name());
    }

    @Test
    public void testCXF2935() throws Exception {
View Full Code Here

                        operation.getParameterModes().set(i, getParameterMode(param.mode()));
                    }
                }
                WebResult result = method.getAnnotation(WebResult.class);
                if (result != null) {
                    String ns = getValue(result.targetNamespace(), tns);
                    // Default to <operationName>Response for doc-bare
                    String name = getValue(result.name(), documentStyle ? operationName + "Response" : "return");
                    QName element = new QName(ns, name);
                    Object logical = operation.getOutputType().getLogical();
                    if (logical instanceof XMLType) {
View Full Code Here

                }

                List<ElementInfo> outputElements = new ArrayList<ElementInfo>();
                WebResult result = method.getAnnotation(WebResult.class);
                // Default to "" for doc-lit-wrapped && non-header
                ns = result != null ? result.targetNamespace() : "";
                ns = getValue(ns, documentStyle && (result == null || !result.header()) ? "" : tns);
                name = result != null ? result.name() : "";
                name = getValue(name, "return");
                QName element = new QName(ns, name);
View Full Code Here

            WebResult webResult = getWebResult(method);

            String tns = null;
            String local = null;
            if (webResult != null) {
                tns = webResult.targetNamespace();
                local = webResult.name();
            }
            if (tns == null || tns.length() == 0) {
                QName wrappername = getResponseWrapperName(op, method);
                if (wrappername != null) {
View Full Code Here

        Class<?> clz = classLoader.loadClass("org.apache.locator.LocatorService");

        Class<?> paraClass = classLoader.loadClass("org.apache.locator.types.QueryEndpoints");
        Method method = clz.getMethod("queryEndpoints", new Class[] {paraClass});
        WebResult webRes = AnnotationUtil.getPrivMethodAnnotation(method, WebResult.class);
        assertEquals("http://apache.org/locator/types", webRes.targetNamespace());
        assertEquals("queryEndpointsResponse", webRes.name());
        WebParam webParamAnn = AnnotationUtil.getWebParam(method, "queryEndpoints");
        assertEquals("http://apache.org/locator/types", webParamAnn.targetNamespace());

        method = clz.getMethod("deregisterPeerManager", new Class[] {String.class});
View Full Code Here

        env.put(ToolConstants.CFG_ALLOW_ELEMENT_REFS, "true");
        processor.setContext(env);
        processor.execute();
        Class<?> clz = classLoader.loadClass("org.apache.cxf.tools.fortest.cxf2944.WebResultService");
        WebResult webResult = AnnotationUtil.getWebResult(clz.getMethods()[0]);
        assertEquals("hello/name", webResult.targetNamespace());
        assertEquals("name", webResult.name());
    }

    @Test
    public void testCXF2935() throws Exception {
View Full Code Here

            WebResult webResult = getWebResult(method);

            String tns = null;
            String local = null;
            if (webResult != null) {
                tns = webResult.targetNamespace();
                local = webResult.name();
            }
            if (tns == null || tns.length() == 0) {
                QName wrappername = getResponseWrapperName(op, method);
                if (wrappername != null) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.