Package org.apache.tuscany.sca.interfacedef.wsdl

Examples of org.apache.tuscany.sca.interfacedef.wsdl.DefaultWSDLFactory


    /**
     * @see junit.framework.TestCase#setUp()
     */
    protected void setUp() throws Exception {
        super.setUp();
        registry = new WSDLDocumentProcessor(new DefaultWSDLFactory(), null);
        resolver = new TestModelResolver(getClass().getClassLoader());
        wsdlFactory = new DefaultWSDLFactory();
    }
View Full Code Here


    /**
     * @see junit.framework.TestCase#setUp()
     */
    protected void setUp() throws Exception {
        super.setUp();
        processor = new WSDLDocumentProcessor(new DefaultWSDLFactory(), null);
        resolver = new TestModelResolver(getClass().getClassLoader());
        wsdlFactory = new DefaultWSDLFactory();
    }
View Full Code Here

    /**
     * @see junit.framework.TestCase#setUp()
     */
    protected void setUp() throws Exception {
        super.setUp();
        registry = new WSDLDocumentProcessor(new DefaultWSDLFactory(), null);
        resolver = new TestModelResolver(getClass().getClassLoader());
        URL url = getClass().getResource("../xml/stockquote.wsdl");
        definition = registry.read(null, new URI("stockquote.wsdl"), url);
        portType = definition.getDefinition().getPortType(PORTTYPE_NAME);
    }
View Full Code Here

        portType = definition.getDefinition().getPortType(PORTTYPE_NAME);
    }

    @SuppressWarnings("unchecked")
    public final void testIntrospectPortType() throws InvalidInterfaceException {
        DefaultWSDLInterfaceIntrospector introspector = new DefaultWSDLInterfaceIntrospector(new DefaultWSDLFactory());
        WSDLInterface contract = introspector.introspect(portType, definition.getInlinedSchemas(), resolver);
        Assert.assertEquals(contract.getName().getLocalPart(), "StockQuotePortType");
        List<Operation> operations = contract.getOperations();
        Assert.assertEquals(1, operations.size());
        Operation operation = operations.get(0);
View Full Code Here

        mapper = new InterfaceContractMapperImpl();
        inputFactory = XMLInputFactory.newInstance();
        staxProcessors = new DefaultStAXArtifactProcessorExtensionPoint();
        staxProcessor = new ExtensibleStAXArtifactProcessor(staxProcessors, XMLInputFactory.newInstance(), XMLOutputFactory.newInstance());

        WSDLInterfaceProcessor wsdlProcessor = new WSDLInterfaceProcessor(new DefaultWSDLFactory(), null);
        staxProcessors.addArtifactProcessor(wsdlProcessor);
    }
View Full Code Here

        staxProcessors.addArtifactProcessor(new CompositeProcessor(factory, policyFactory, mapper, staxProcessor));
        staxProcessors.addArtifactProcessor(new ComponentTypeProcessor(factory, policyFactory, staxProcessor));
        staxProcessors.addArtifactProcessor(new ConstrainingTypeProcessor(factory, policyFactory, staxProcessor));

        WSDLInterfaceProcessor wsdlProcessor = new WSDLInterfaceProcessor(new DefaultWSDLFactory(), null);
        staxProcessors.addArtifactProcessor(wsdlProcessor);
    }
View Full Code Here

    public void setUp() throws Exception {
        inputFactory = XMLInputFactory.newInstance();
        documentProcessors = new DefaultURLArtifactProcessorExtensionPoint();
        documentProcessor = new ExtensibleURLArtifactProcessor(documentProcessors);

        WSDLDocumentProcessor wsdlProcessor = new WSDLDocumentProcessor(new DefaultWSDLFactory(), null);
        documentProcessors.addArtifactProcessor(wsdlProcessor);
    }
View Full Code Here

        return null;
    }

    public void start(ExtensionPointRegistry registry) {
       
        WSDLFactory wsdlFactory = new DefaultWSDLFactory();
        WSDLInterfaceIntrospector interfaceIntrospector = new DefaultWSDLInterfaceIntrospector(wsdlFactory);
       
        // Register <interface.wsdl> processor
        StAXArtifactProcessorExtensionPoint processors = registry.getExtensionPoint(StAXArtifactProcessorExtensionPoint.class);
        processors.addArtifactProcessor(new WSDLInterfaceProcessor(wsdlFactory, interfaceIntrospector));
View Full Code Here

        DefaultDataBindingExtensionPoint dataBindings = new DefaultDataBindingExtensionPoint();
        JAXWSFaultExceptionMapper faultExceptionMapper = new JAXWSFaultExceptionMapper(dataBindings, null);
        new JAXWSJavaInterfaceProcessor(dataBindings, faultExceptionMapper, null).visitInterface(iface);
        new DataBindingJavaInterfaceProcessor(dataBindings).visitInterface(iface);
        DefaultModelFactoryExtensionPoint modelFactories = new DefaultModelFactoryExtensionPoint();
        WSDLDefinition wsdlDefinition = new DefaultWSDLFactory(modelFactories).createWSDLDefinition();
        DefaultXSDFactory factory = new DefaultXSDFactory();
        Interface2WSDLGenerator generator = new Interface2WSDLGenerator(false, new XSDModelResolver(null, null), dataBindings, factory, null);
        Definition definition = generator.generate(iface, wsdlDefinition);

        // print the generated WSDL file and inline schemas
View Full Code Here

     */
    public static WSDLInterfaceContract createWSDLInterfaceContract(JavaInterfaceContract contract) {
        JavaInterface iface = (JavaInterface)contract.getInterface();
        Definition def = Java2WSDLHelper.createDefinition(iface.getJavaClass());

        DefaultWSDLFactory wsdlFactory = new DefaultWSDLFactory();

        WSDLInterfaceContract wsdlContract = wsdlFactory.createWSDLInterfaceContract();
        WSDLInterface wsdlInterface = wsdlFactory.createWSDLInterface();

        wsdlContract.setInterface(wsdlInterface);
        WSDLDefinition wsdlDefinition = new DefaultWSDLFactory().createWSDLDefinition();
        wsdlDefinition.setDefinition(def);
        wsdlInterface.setWsdlDefinition(wsdlDefinition);
        wsdlInterface.setRemotable(true);
        wsdlInterface.setConversational(contract.getInterface().isConversational());
        wsdlInterface.setUnresolved(false);
View Full Code Here

TOP

Related Classes of org.apache.tuscany.sca.interfacedef.wsdl.DefaultWSDLFactory

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.