Package org.apache.openejb.jee

Examples of org.apache.openejb.jee.ServiceEndpointInterfaceMapping


    private void doHeavyweightMapping(QName serviceName, PortType portType, List<ServiceEndpointInterfaceMapping> endpointMappings, Bundle bundle, List operations, Binding binding, Style portStyle, SOAPConstants soapVersion, Map exceptionMap, SchemaInfoBuilder schemaInfoBuilder, JavaWsdlMapping mapping, OperationInfo[] operationInfos, String portName, URL location, List handlerInfos, Map seiPortNameToFactoryMap, Map seiClassNameToFactoryMap, String credentialsName) throws DeploymentException {
        Class<?> serviceEndpointInterface;
        SEIFactory seiFactory;
        //complete jaxrpc mapping file supplied
        QName portTypeQName = portType.getQName();
        ServiceEndpointInterfaceMapping endpointMapping = WSDescriptorParser.getServiceEndpointInterfaceMapping(endpointMappings, portTypeQName);
        String fqcn = endpointMapping.getServiceEndpointInterface();
        try {
            serviceEndpointInterface = bundle.loadClass(fqcn);
        } catch (ClassNotFoundException e) {
            throw new DeploymentException("Could not load service endpoint interface", e);
        }
//        Class enhancedServiceEndpointClass = enhanceServiceEndpointInterface(serviceEndpointInterface, context, module, classLoader);

        Collection<OperationDesc> operationDescs = new ArrayList<OperationDesc>();
        List<ServiceEndpointMethodMapping> methodMappings = endpointMapping.getServiceEndpointMethodMapping();
        int i = 0;
        Set wrapperElementQNames = new HashSet();
        List<JavaXmlTypeMapping> javaXmlTypeMappings = mapping.getJavaXmlTypeMapping();
        boolean hasEncoded = false;
        for (Iterator ops = operations.iterator(); ops.hasNext();) {
View Full Code Here


    private void doHeavyweightMapping(QName serviceName, PortType portType, List<ServiceEndpointInterfaceMapping> endpointMappings, Bundle bundle, List operations, Binding binding, Style portStyle, SOAPConstants soapVersion, Map exceptionMap, SchemaInfoBuilder schemaInfoBuilder, JavaWsdlMapping mapping, OperationInfo[] operationInfos, String portName, URL location, List handlerInfos, Map seiPortNameToFactoryMap, Map seiClassNameToFactoryMap, String credentialsName) throws DeploymentException {
        Class<?> serviceEndpointInterface;
        SEIFactory seiFactory;
        //complete jaxrpc mapping file supplied
        QName portTypeQName = portType.getQName();
        ServiceEndpointInterfaceMapping endpointMapping = WSDescriptorParser.getServiceEndpointInterfaceMapping(endpointMappings, portTypeQName);
        String fqcn = endpointMapping.getServiceEndpointInterface();
        try {
            serviceEndpointInterface = bundle.loadClass(fqcn);
        } catch (ClassNotFoundException e) {
            throw new DeploymentException("Could not load service endpoint interface", e);
        }
//        Class enhancedServiceEndpointClass = enhanceServiceEndpointInterface(serviceEndpointInterface, context, module, classLoader);

        Collection<OperationDesc> operationDescs = new ArrayList<OperationDesc>();
        List<ServiceEndpointMethodMapping> methodMappings = endpointMapping.getServiceEndpointMethodMapping();
        int i = 0;
        Set wrapperElementQNames = new HashSet();
        List<JavaXmlTypeMapping> javaXmlTypeMappings = mapping.getJavaXmlTypeMapping();
        boolean hasEncoded = false;
        for (Iterator ops = operations.iterator(); ops.hasNext();) {
View Full Code Here

        return found;
    }

    private ServiceEndpointMethodMapping getMethodMappingForOperation(final String operationName, final Class serviceEndpointInterface) throws OpenEJBException {
        // get mapping for service endpoint interface
        final ServiceEndpointInterfaceMapping interfaceMapping = javaWsdlMapping.getServiceEndpointInterfaceMappingMap().get(serviceEndpointInterface.getName());
        if (interfaceMapping == null) {
            throw new OpenEJBException("No java-wsdl mapping found for the service interface " + serviceEndpointInterface);
        }

        // match by operation name
        for (final ServiceEndpointMethodMapping methodMapping : interfaceMapping.getServiceEndpointMethodMapping()) {
            if (operationName.equals(methodMapping.getWsdlOperation())) {
                return methodMapping;
            }
        }

        // failed - throw nice exception message
        final StringBuffer availOps = new StringBuffer(128);
        for (final ServiceEndpointMethodMapping methodMapping : interfaceMapping.getServiceEndpointMethodMapping()) {
            if (availOps.length() > 0) availOps.append(",");
            availOps.append(methodMapping.getWsdlOperation());
        }
        throw new OpenEJBException("No method found for operation named '" + operationName + "'. Available operations: " + availOps);
    }
View Full Code Here

        return found;
    }

    private ServiceEndpointMethodMapping getMethodMappingForOperation(String operationName, Class serviceEndpointInterface) throws OpenEJBException {
        // get mapping for service endpoint interface
        ServiceEndpointInterfaceMapping interfaceMapping = javaWsdlMapping.getServiceEndpointInterfaceMappingMap().get(serviceEndpointInterface.getName());
        if (interfaceMapping == null) {
            throw new OpenEJBException("No java-wsdl mapping found for the service interface " + serviceEndpointInterface);
        }

        // match by operation name
        for (ServiceEndpointMethodMapping methodMapping : interfaceMapping.getServiceEndpointMethodMapping()) {
            if (operationName.equals(methodMapping.getWsdlOperation())) {
                return methodMapping;
            }
        }

        // failed - throw nice exception message
        StringBuffer availOps = new StringBuffer(128);
        for (ServiceEndpointMethodMapping methodMapping : interfaceMapping.getServiceEndpointMethodMapping()) {
            if (availOps.length() > 0) availOps.append(",");
            availOps.append(methodMapping.getWsdlOperation());
        }
        throw new OpenEJBException("No method found for operation named '" + operationName + "'. Available operations: " + availOps);
    }
View Full Code Here

TOP

Related Classes of org.apache.openejb.jee.ServiceEndpointInterfaceMapping

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.