Package org.apache.axis.wsdl.wsdl2ws.info

Examples of org.apache.axis.wsdl.wsdl2ws.info.MethodInfo


    {
        try
        {
            writer.write(
                "\n/*Methods corresponding to the web service methods*/\n");
            MethodInfo minfo;
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) methods.get(i);
                this.writeMethodInWrapper(minfo);
                writer.write("\n");
View Full Code Here


                "AXIS_BINDING_STYLE AXISCALL "
                    + classname
                    + "_GetBindingStyle(void*p);\n");
            writer.write(
                "/*Methods corresponding to the web service methods*/\n");
            MethodInfo minfo;
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) methods.get(i);
                writer.write(
                    "int "
                        + minfo.getMethodname()
                        + CUtils.WRAPPER_METHOD_APPENDER
                        + "(IWrapperSoapDeSerializer DZ, IWrapperSoapSerializer SZ);");
                writer.write("\n");
            }
        }
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeMethods()
     */
    protected void writeMethods() throws WrapperFault
    {
        MethodInfo minfo;
        try
        {
            writer.write("\n");
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) this.methods.get(i);
                boolean isAllTreatedAsOutParams = false;
                ParameterInfo returntype = null;
                int noOfOutParams = minfo.getOutputParameterTypes().size();
                if (0 == noOfOutParams)
                {
                    returntype = null;
                    writer.write("void ");
                }
                else
                    if (1 == noOfOutParams)
                    {
                        returntype =
                            (ParameterInfo) minfo
                                .getOutputParameterTypes()
                                .iterator()
                                .next();
                        writer.write(
                            WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                returntype,
                                wscontext)
                                + " ");
                    }
                    else
                    {
                        isAllTreatedAsOutParams = true;
                        writer.write("void ");
                    }
                writer.write(minfo.getMethodname() + "(");
                //write parameter names
                Iterator params = minfo.getInputParameterTypes().iterator();
                if (params.hasNext())
                {
                    ParameterInfo fparam = (ParameterInfo) params.next();
                    writer.write(
                        WrapperUtils
                            .getClassNameFromParamInfoConsideringArrays(
                            fparam,
                            wscontext)
                            + " Value"
                            + 0);
                }
                for (int j = 1; params.hasNext(); j++)
                {
                    ParameterInfo nparam = (ParameterInfo) params.next();
                    writer.write(
                        ","
                            + WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                nparam,
                                wscontext)
                            + " Value"
                            + j);
                }
                if (isAllTreatedAsOutParams)
                {
                    params = minfo.getOutputParameterTypes().iterator();
                    for (int j = 0; params.hasNext(); j++)
                    {
                        ParameterInfo nparam = (ParameterInfo) params.next();
                        writer.write(
                            ", AXIS_OUT_PARAM "
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.axis.wsdl.wsdl2ws.cpp.HeaderFileWriter#writeMethods()
     */
    protected void writeMethods() throws WrapperFault
    {
        MethodInfo minfo;
        try
        {
            writer.write("\tpublic: \n");
            writer.write("\t\tvoid onFault();\n");
            writer.write("\t\tvoid init();\n");
            writer.write("\t\tvoid fini();\n");
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) this.methods.get(i);
                boolean isAllTreatedAsOutParams = false;
                ParameterInfo returntype = null;
                int noOfOutParams = minfo.getOutputParameterTypes().size();
                if (0 == noOfOutParams)
                {
                    returntype = null;
                    writer.write("\t\tvoid ");
                }
                else
                {
                    if (1 == noOfOutParams)
                    {
                        returntype =
                            (ParameterInfo) minfo
                                .getOutputParameterTypes()
                                .iterator()
                                .next();
                        writer.write(
                            "\t\t"
                                + WrapperUtils
                                    .getClassNameFromParamInfoConsideringArrays(
                                    returntype,
                                    wscontext)
                                + " ");
                    }
                    else
                    {
                        isAllTreatedAsOutParams = true;
                        writer.write("\t\tvoid ");
                    }
                }
                //write return type
                writer.write(minfo.getMethodname() + "(");
                //write parameter names
                Iterator params = minfo.getInputParameterTypes().iterator();
                if (params.hasNext())
                {
                    ParameterInfo fparam = (ParameterInfo) params.next();
                    writer.write(
                        WrapperUtils
                            .getClassNameFromParamInfoConsideringArrays(
                            fparam,
                            wscontext)
                            + " Value"
                            + 0);
                }
                for (int j = 1; params.hasNext(); j++)
                {
                    ParameterInfo nparam = (ParameterInfo) params.next();
                    writer.write(
                        ","
                            + WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                nparam,
                                wscontext)
                            + " Value"
                            + j);
                }
                if (isAllTreatedAsOutParams)
                {
                    params = minfo.getOutputParameterTypes().iterator();
                    for (int j = 0; params.hasNext(); j++)
                    {
                        ParameterInfo nparam = (ParameterInfo) params.next();
                        writer.write(
                            ", AXIS_OUT_PARAM "
View Full Code Here

    protected void writeFaultHeaders() throws WrapperFault
    {
        try
        {

            MethodInfo minfo;
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) methods.get(i);
                Iterator fault = minfo.getFaultType().iterator();
                String faultInfoName = null;
                while (fault.hasNext())
                {
                    FaultInfo info = (FaultInfo) fault.next();
                    faultInfoName = info.getFaultInfo();
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.axis.wsdl.wsdl2ws.cpp.HeaderFileWriter#writeMethods()
     */
    protected void writeMethods() throws WrapperFault
    {
        MethodInfo minfo;

        try
        {
            writer.write("public: \n");
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) this.methods.get(i);
                boolean isAllTreatedAsOutParams = false;
                int noOfOutParams = minfo.getOutputParameterTypes().size();
                //write return type
                if (0 == noOfOutParams)
                {
                    writer.write("\tSTORAGE_CLASS_INFO void ");
                }
                else
                {
                    if (1 == noOfOutParams)
                    {
                        ParameterInfo returnParam =
                            (ParameterInfo) minfo
                                .getOutputParameterTypes()
                                .iterator()
                                .next();
                        writer.write(
                            "\tSTORAGE_CLASS_INFO "
                                + WrapperUtils
                                    .getClassNameFromParamInfoConsideringArrays(
                                    returnParam,
                                    wscontext)
                                + " ");
                    }
                    else
                    {
                        isAllTreatedAsOutParams = true;
                        writer.write("\tSTORAGE_CLASS_INFO void ");
                    }
                }
                //write return type
                writer.write(minfo.getMethodname() + "(");

                //write parameter names
                Iterator params = minfo.getInputParameterTypes().iterator();
                if (params.hasNext())
                {
                    ParameterInfo fparam = (ParameterInfo) params.next();
                    writer.write(
                        WrapperUtils
                            .getClassNameFromParamInfoConsideringArrays(
                            fparam,
                            wscontext)
                            + " Value"
                            + 0);
                }
                for (int j = 1; params.hasNext(); j++)
                {
                    ParameterInfo nparam = (ParameterInfo) params.next();
                    writer.write(
                        ","
                            + WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                nparam,
                                wscontext)
                            + " Value"
                            + j);
                }
                if (isAllTreatedAsOutParams)
                {
                    params = minfo.getOutputParameterTypes().iterator();
                    for (int j = 0; params.hasNext(); j++)
                    {
                        ParameterInfo nparam = (ParameterInfo) params.next();
                        writer.write(
                            ", AXIS_OUT_PARAM "
View Full Code Here

    protected void writeFaultHeaders() throws WrapperFault
    {
        try
        {

            MethodInfo minfo;
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) methods.get(i);
                Iterator fault = minfo.getFaultType().iterator();
                String faultInfoName = null;
                while (fault.hasNext())
                {
                    FaultInfo info = (FaultInfo) fault.next();
                    faultInfoName = info.getFaultInfo();
View Full Code Here

    {
        try
        {
            writer.write(
                "\n/*Methods corresponding to the web service methods*/\n");
            MethodInfo minfo;
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) methods.get(i);
                this.writeMethodInWrapper(minfo);
                writer.write("\n");
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.axis.wsdl.wsdl2ws.cpp.HeaderFileWriter#writeMethods()
     */
    protected void writeMethods() throws WrapperFault
    {
        MethodInfo minfo;
        try
        {
            writer.write(
                "\n/* This function is called by the AxisEngine when something went wrong"
                    + "\n with the current web service request processing. Appropriate actions should"
                    + "\n be taken here.*/");
            writer.write("\nvoid " + classname + "::onFault()\n{\n}");
            writer.write(
                "\n/* This function is called by the AxisEngine when this web service"
                    + "\n library is first loaded. So here we can initialize any global/static"
                    + "\n data structures of this web service or open database connections */");
            writer.write("\nvoid " + classname + "::init()\n{\n}");
            writer.write(
                "\n/* This function is called by the AxisEngine when this web service"
                    + "\n library is unloaded. So we can deallocate any global/static data structures"
                    + "\n and close database connections etc here. */");
            writer.write("\nvoid " + classname + "::fini()\n{\n}");
            writer.write("\n");
            for (int i = 0; i < methods.size(); i++)
            {
                minfo = (MethodInfo) this.methods.get(i);
                boolean isAllTreatedAsOutParams = false;
                ParameterInfo returntype = null;
                int noOfOutParams = minfo.getOutputParameterTypes().size();
                if (0 == noOfOutParams)
                {
                    returntype = null;
                    writer.write("void ");
                }
                else
                {
                    if (1 == noOfOutParams)
                    {
                        returntype =
                            (ParameterInfo) minfo
                                .getOutputParameterTypes()
                                .iterator()
                                .next();
                        writer.write(
                            WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                returntype,
                                wscontext)
                                + " ");
                    }
                    else
                    {
                        isAllTreatedAsOutParams = true;
                        writer.write("void ");
                    }
                }
                writer.write(classname + "::" + minfo.getMethodname() + "(");
                //write parameter names
                Iterator params = minfo.getInputParameterTypes().iterator();
                if (params.hasNext())
                {
                    ParameterInfo fparam = (ParameterInfo) params.next();
                    writer.write(
                        WrapperUtils
                            .getClassNameFromParamInfoConsideringArrays(
                            fparam,
                            wscontext)
                            + " Value"
                            + 0);
                }
                for (int j = 1; params.hasNext(); j++)
                {
                    ParameterInfo nparam = (ParameterInfo) params.next();
                    writer.write(
                        ", "
                            + WrapperUtils
                                .getClassNameFromParamInfoConsideringArrays(
                                nparam,
                                wscontext)
                            + " Value"
                            + j);
                }
                if (isAllTreatedAsOutParams)
                {
                    params = minfo.getOutputParameterTypes().iterator();
                    for (int j = 0; params.hasNext(); j++)
                    {
                        ParameterInfo nparam = (ParameterInfo) params.next();
                        writer.write(
                            ", AXIS_OUT_PARAM "
View Full Code Here

            for (int i = 0; i < operations.size(); i++) {
                //for the each binding operation found
                if (operations.get(i) instanceof javax.wsdl.BindingOperation) {
                 
          javax.wsdl.BindingOperation bindinop = (javax.wsdl.BindingOperation) operations.get(i);
          MethodInfo method = getMethodInfoByName(bindinop.getName());
          method.setSoapAction(SymbolTableParsingUtils.getSoapAction(bindinop));
          SymbolTableParsingUtils.getInputInfo(bindinop.getBindingInput(),method);
                    SymbolTableParsingUtils.getOutputInfo(bindinop.getBindingOutput(),method);
                }
            }
        }
View Full Code Here

TOP

Related Classes of org.apache.axis.wsdl.wsdl2ws.info.MethodInfo

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.