Package javax.xml.ws

Examples of javax.xml.ws.Action


        this.seiMethod = seiMethod;
        setWsaActions();
    }

    private void setWsaActions() {
        Action action = seiMethod.getAnnotation(Action.class);
        if(action != null) {
            inputAction = action.input();
            outputAction = action.output();
        }

        //@Action(input) =="", get it from @WebMethod(action)
        WebMethod webMethod = seiMethod.getAnnotation(WebMethod.class);
        String soapAction = "";
View Full Code Here


    @Override
    public void addOperationInputExtension(TypedXmlWriter input, JavaMethod method) {
        if (!enabled)
            return;

        Action a = method.getSEIMethod().getAnnotation(Action.class);
        if (a != null && !a.input().equals("")) {
            addAttribute(input, a.input());
        } else {
            if (method.getBinding().getSOAPAction().equals("")) {
                //hack: generate default action for interop with .Net3.0 when soapAction is non-empty
                String defaultAction = getDefaultAction(method);
                addAttribute(input, defaultAction);
View Full Code Here

    @Override
    public void addOperationOutputExtension(TypedXmlWriter output, JavaMethod method) {
        if (!enabled)
            return;

        Action a = method.getSEIMethod().getAnnotation(Action.class);
        if (a != null && !a.output().equals("")) {
            addAttribute(output, a.output());
        }
    }
View Full Code Here

    @Override
    public void addOperationFaultExtension(TypedXmlWriter fault, JavaMethod method, CheckedException ce) {
        if (!enabled)
            return;

        Action a = method.getSEIMethod().getAnnotation(Action.class);
        Class[] exs = method.getSEIMethod().getExceptionTypes();

        if (exs == null)
            return;

        if (a != null && a.fault() != null) {
            for (FaultAction fa : a.fault()) {
                if (fa.className().getName().equals(ce.getExceptionClass().getName())) {
                    if (fa.value().equals(""))
                        return;

                    addAttribute(fault, fa.value());
View Full Code Here

        String action = "";
        if (wm != null) {
            action = wm.action();
        }
        if (StringUtils.isEmpty(action)) {
            Action act = method.getAnnotation(Action.class);
            if (act != null) {
                action = act.input();
            }
        }
        return action;
    }
View Full Code Here

        //nothing
        if (method == null) {
            return;
        }

        Action action = method.getAnnotation(Action.class);
        if (action == null) {
            return;
        }
        MessageInfo input = operation.getInput();
        if (!StringUtils.isEmpty(action.input())) {
            input.addExtensionAttribute(JAXWSAConstants.WSAW_ACTION_QNAME, action.input());
        }
       
        MessageInfo output = operation.getOutput();
        if (output != null && !StringUtils.isEmpty(action.output())) {
            output.addExtensionAttribute(JAXWSAConstants.WSAW_ACTION_QNAME, action.output());
        }
       
        FaultAction[] faultActions = action.fault();
        if (faultActions != null
            && faultActions.length > 0
            && operation.getFaults() != null) {
            for (FaultAction faultAction : faultActions) {               
                FaultInfo faultInfo = getFaultInfo(operation, faultAction.className());
View Full Code Here

        String action = "";
        if (wm != null) {
            action = wm.action();
        }
        if (StringUtils.isEmpty(action)) {
            Action act = method.getAnnotation(Action.class);
            if (act != null) {
                action = act.input();
            }
        }
        return action;
    }
View Full Code Here

        Class<?> pcls = classLoader.loadClass("org.apache.cxf.w2j.hello_world_soap_http.Greeter");
        Class<?> acls = classLoader.loadClass("org.apache.cxf.w2j.hello_world_soap_http.types.GreetMe");
        Method m = pcls.getMethod("greetMe", new Class[] {acls});

        Action actionAnn = AnnotationUtil.getPrivMethodAnnotation(m, Action.class);
        assertNotNull(actionAnn);
        assertEquals("http://cxf.apache.org/w2j/hello_world_soap_http/greetMe", actionAnn.input());
    }
View Full Code Here

        String action = "";
        if (wm != null) {
            action = wm.action();
        }
        if (StringUtils.isEmpty(action)) {
            Action act = method.getAnnotation(Action.class);
            if (act != null) {
                action = act.input();
            }
        }
        return action;
    }
View Full Code Here

    @Override
    public void addOperationInputExtension(TypedXmlWriter input, JavaMethod method) {
        if (!enabled)
            return;

        Action a = method.getSEIMethod().getAnnotation(Action.class);
        if (a != null && !a.input().equals("")) {
            addAttribute(input, a.input());
        } else {

            String soapAction = method.getBinding().getSOAPAction();
            // in SOAP 1.2 soapAction is optional ...
            if (soapAction == null || soapAction.equals("")) {
View Full Code Here

TOP

Related Classes of javax.xml.ws.Action

Copyright © 2018 www.massapicom. 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.