Examples of MethodDescriptionComposite


Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        HashMap<String, MethodDescriptionComposite> compositeHashMap =
            new HashMap<String, MethodDescriptionComposite>();
        Iterator<MethodDescriptionComposite> compIterator =
                composite.getMethodDescriptionsList().iterator();
        while (compIterator.hasNext()) {
            MethodDescriptionComposite mdc = compIterator.next();
            compositeHashMap.put(mdc.getMethodName(), mdc);
        }
        // Add methods declared in the implementation's superclass
        addSuperClassMethods(compositeHashMap, composite);

        HashMap<String, MethodDescriptionComposite> seiMethodHashMap =
            new HashMap<String, MethodDescriptionComposite>();
        Iterator<MethodDescriptionComposite> seiMethodIterator =
                seic.getMethodDescriptionsList().iterator();
        while (seiMethodIterator.hasNext()) {
            MethodDescriptionComposite mdc = seiMethodIterator.next();
            seiMethodHashMap.put(mdc.getMethodName(), mdc);
        }
        // Add any methods declared in superinterfaces of the SEI
        addSuperClassMethods(seiMethodHashMap, seic);

        // Make sure all the methods in the SEI (including any inherited from superinterfaces) are
        // implemented by the bean (including inherited methods on the bean).
        Iterator<MethodDescriptionComposite> verifySEIIterator =
                seiMethodHashMap.values().iterator();
        while (verifySEIIterator.hasNext()) {
            MethodDescriptionComposite mdc = verifySEIIterator.next();
            // TODO: This does not take into consideration overloaded java methods!
            MethodDescriptionComposite implMDC = compositeHashMap.get(mdc.getMethodName());
           
            if (implMDC == null) {
                // TODO: RAS/NLS
                throw ExceptionFactory.makeWebServiceException(
                        "Validation error: Implementation subclass does not implement method on specified interface.  Implementation class: "
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        DescriptionBuilderComposite superDBC = dbcMap.get(dbc.getSuperClassName());
        if (superDBC != null) {
            Iterator<MethodDescriptionComposite> mIter =
                    superDBC.getMethodDescriptionsList().iterator();
            while (mIter.hasNext()) {
                MethodDescriptionComposite mdc = mIter.next();
                methodMap.put(mdc.getMethodName(), mdc);
            }
            addSuperClassMethods(methodMap, superDBC);
        }
    }
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        validateMethods(seic.getMethodDescriptionsList());
    }

    /** @return Returns TRUE if we find just one WebMethod Annotation */
    private boolean webMethodAnnotationsExist() {
        MethodDescriptionComposite mdc = null;
        Iterator<MethodDescriptionComposite> iter =
                composite.getMethodDescriptionsList().iterator();

        while (iter.hasNext()) {
            mdc = iter.next();

            if (mdc.getWebMethodAnnot() != null)
                return true;
        }

        return false;
    }
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

    public List<MethodDescriptionComposite> convertMethods() {
        List<MethodDescriptionComposite> mdcList = new
                ArrayList<MethodDescriptionComposite>();
        for (Method method : methods) {
            if (!ConverterUtils.isInherited(method, declaringClass)) {
                MethodDescriptionComposite mdc = new MethodDescriptionComposite();
                setExceptionList(mdc, method);
                mdc.setMethodName(method.getName());
                setReturnType(mdc, method);
                mdc.setDeclaringClass(method.getDeclaringClass().getName());
                attachHandlerChainAnnotation(mdc, method);
                attachOnewayAnnotation(mdc, method);
                attachSoapBindingAnnotation(mdc, method);
                attachRequestWrapperAnnotation(mdc, method);
                attachResponseWrapperAnnotation(mdc, method);
                attachWebEndpointAnnotation(mdc, method);
                attachWebMethodAnnotation(mdc, method);
                attachWebResultAnnotation(mdc, method);
                attachWebServiceRefAnnotation(mdc, method);
                if (method.getGenericParameterTypes().length > 0) {
                    JavaParamToPDCConverter paramConverter = new JavaParamToPDCConverter(
                            method.getGenericParameterTypes(), method.getParameterAnnotations());
                    List<ParameterDescriptionComposite> pdcList = paramConverter.
                            convertParams();
                    ConverterUtils.attachParameterDescriptionComposites(pdcList, mdc);
                }
                mdcList.add(mdc);
            }
        }

        for (Constructor constructor : constructors) {
            MethodDescriptionComposite mdc = new MethodDescriptionComposite();
            mdc.setMethodName("<init>");
            mdc.setDeclaringClass(constructor.getDeclaringClass().getName());
            mdcList.add(mdc);
            if (constructor.getGenericParameterTypes().length > 0) {
                JavaParamToPDCConverter paramConverter = new JavaParamToPDCConverter(
                        constructor.getGenericParameterTypes(),
                        constructor.getParameterAnnotations());
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

            } catch (Exception e) {
                // This must be a legacy exception
                faultInfo = "";
            }
        } else {
            MethodDescriptionComposite mdc =
                    composite.getMethodDescriptionComposite("getFaultInfo", 1);
            if (mdc != null) {
                faultInfo = mdc.getReturnType();
            } else {
                faultInfo = "";
            }
        }
        return faultInfo;
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        //Retrieve the relevent method composites for this dbc (and those in the superclass chain)
        Iterator<MethodDescriptionComposite> iter = retrieveReleventMethods(dbc);

        if (log.isDebugEnabled())
            log.debug("EndpointInterfaceDescriptionImpl: Finished retrieving methods");
        MethodDescriptionComposite mdc = null;

        while (iter.hasNext()) {
            mdc = iter.next();

            //TODO: Verify that this classname is truly always the wrapper class
            mdc.setDeclaringClass(dbc.getClassName());

            // Only add if it is a method that would be or is in the WSDL i.e.
            // don't create an OperationDescriptor for the MDC representing the
            // constructor
            if (DescriptionUtils.createOperationDescription(mdc.getMethodName())) {
                //First check if this operation already exists on the AxisService, if so
                //then use that in the description hierarchy

                AxisService axisService = getEndpointDescription().getAxisService();
                AxisOperation axisOperation = axisService
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

                    Iterator<MethodDescriptionComposite> iterMethod =
                            dbc.getMethodDescriptionsList().iterator();

                    while (iterMethod.hasNext()) {
                        MethodDescriptionComposite mdc = iterMethod.next();

                        if (!DescriptionUtils.isExcludeTrue(mdc)) {
                            mdc.setDeclaringClass(superDBC.getClassName());
                            retrieveList.add(mdc);
                        }
                    }
                }
                tempDBC = superDBC;
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        int baseLevel = hierarchyMap.get(mdc.getDeclaringClass());
        if (log.isDebugEnabled()) {
            log.debug("Base method: " + mdc.getMethodName() + " initial level: " + baseLevel);
        }
        for (; index < methodList.size(); index++) {
            MethodDescriptionComposite compareMDC = methodList.get(index);
            // If the two methods are the same method that means we have found an inherited
            // overridden case
            if (mdc.equals(compareMDC)) {
                if (log.isDebugEnabled()) {
                    log.debug("Found equivalent methods: " + mdc.getMethodName());
                }
                // get the declaration level of the method we are comparing to
                int compareLevel = hierarchyMap.get(compareMDC.getDeclaringClass());
                // if the method was declared by a class in a lower level of the hierarchy it
                // becomes the method that we will compare other methods to
                if (compareLevel < baseLevel) {
                    if (log.isDebugEnabled()) {
                        log.debug("Found method lower in hierarchy chain: " +
                                compareMDC.getMethodName()
                                + " of class: " + compareMDC.getMethodName());
                    }
                    mdc = compareMDC;
                    baseLevel = compareLevel;
                }
            }
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

            List<MethodDescriptionComposite> mdcList = dbc.getMethodDescriptionsList();

            if (mdcList != null) {
                iter = dbc.getMethodDescriptionsList().iterator();
                while (iter.hasNext()) {
                    MethodDescriptionComposite mdc = iter.next();

                    if (!DescriptionUtils.isExcludeTrue(mdc)) {
                        mdc.setDeclaringClass(dbc.getClassName());
                        retrieveList.add(mdc);
                    }
                }
            }
        }
View Full Code Here

Examples of org.apache.axis2.jaxws.description.builder.MethodDescriptionComposite

        List<MethodDescriptionComposite> mdcList = dbc.getMethodDescriptionsList();

        if (mdcList != null) {
            iter = dbc.getMethodDescriptionsList().iterator();
            while (iter.hasNext()) {
                MethodDescriptionComposite mdc = iter.next();
                mdc.setDeclaringClass(dbc.getClassName());
                retrieveList.add(mdc);
            }
        }

        return retrieveList;
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.