Java Code Examples for com.sun.xml.internal.ws.model.JavaMethodImpl#getResponseParameters()

The following examples show how to use com.sun.xml.internal.ws.model.JavaMethodImpl#getResponseParameters() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: StubHandler.java    From TencentKona-8 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 2
Source File: SEIMethodHandler.java    From TencentKona-8 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 3
Source File: StubHandler.java    From jdk8u60 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 4
Source File: SEIMethodHandler.java    From jdk8u60 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 5
Source File: StubHandler.java    From openjdk-jdk8u with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 6
Source File: SEIMethodHandler.java    From openjdk-jdk8u with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 7
Source File: StubHandler.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 8
Source File: SEIMethodHandler.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 9
Source File: StubHandler.java    From openjdk-jdk9 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 10
Source File: SEIMethodHandler.java    From openjdk-jdk9 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 11
Source File: StubHandler.java    From hottub with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 12
Source File: SEIMethodHandler.java    From hottub with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 13
Source File: StubHandler.java    From openjdk-8-source with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 14
Source File: SEIMethodHandler.java    From openjdk-8-source with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 15
Source File: StubHandler.java    From openjdk-8 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}
 
Example 16
Source File: SEIMethodHandler.java    From openjdk-8 with GNU General Public License v2.0 4 votes vote down vote up
ResponseBuilder buildResponseBuilder(JavaMethodImpl method, ValueSetterFactory setterFactory) {
    // prepare objects for processing response
    List<ParameterImpl> rp = method.getResponseParameters();
    List<ResponseBuilder> builders = new ArrayList<ResponseBuilder>();

    for( ParameterImpl param : rp ) {
        ValueSetter setter;
        switch(param.getOutBinding().kind) {
        case BODY:
            if(param.isWrapperStyle()) {
                if(param.getParent().getBinding().isRpcLit())
                    builders.add(new ResponseBuilder.RpcLit((WrapperParameter)param, setterFactory));
                else
                    builders.add(new ResponseBuilder.DocLit((WrapperParameter)param, setterFactory));
            } else {
                setter = setterFactory.get(param);
                builders.add(new ResponseBuilder.Body(param.getXMLBridge(),setter));
            }
            break;
        case HEADER:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.Header(owner.soapVersion, param, setter));
            break;
        case ATTACHMENT:
            setter = setterFactory.get(param);
            builders.add(ResponseBuilder.AttachmentBuilder.createAttachmentBuilder(param, setter));
            break;
        case UNBOUND:
            setter = setterFactory.get(param);
            builders.add(new ResponseBuilder.NullSetter(setter,
                ResponseBuilder.getVMUninitializedValue(param.getTypeInfo().type)));
            break;
        default:
            throw new AssertionError();
        }
    }
    ResponseBuilder rb;
    switch(builders.size()) {
    case 0:
        rb = ResponseBuilder.NONE;
        break;
    case 1:
        rb = builders.get(0);
        break;
    default:
        rb = new ResponseBuilder.Composite(builders);
    }
    return rb;
}