Examples of BookStore


Examples of org.apache.axis2.jaxws.client.soapaction.BookStore

    public void testSendRequestWithSoapAction() {
        TestLogger.logger.debug("----------------------------------");
        TestLogger.logger.debug("test: " + getName());

        BookStoreService service = new BookStoreService();
        BookStore bs = service.getBookStorePort();
       
        float price = bs.getPriceWithAction("test item");
        TestLogger.logger.debug("return value [" + price + "]");
        //assertTrue("The return value was invalid", price > 0);
    }
View Full Code Here

Examples of org.apache.camel.example.cxf.jaxrs.resources.BookStore

        context.start();
        context.addRoutes(new CamelRouterBuilder());
        Thread.sleep(1000);
        // JAXWSClient invocation
        JAXWSClient jaxwsClient = new JAXWSClient();
        BookStore bookStore = jaxwsClient.getBookStore();
       
        bookStore.addBook(new Book("Camel User Guide", 234L));
        Book book = bookStore.getBook(123L);
        System.out.println("Get the book with id 123. " + book);      
     
        try {
            book = bookStore.getBook(124L);
            System.out.println("Get the book with id 124. " + book);
        } catch (Exception exception) {
            System.out.println("Get the exception " + exception);
        }
       
        // JAXRSClient invocation
        JAXRSClient jaxrsClient = new JAXRSClient();
        bookStore =  jaxrsClient.getBookStore();
       
        bookStore.addBook(new Book("Camel User Guide", 124L));
        book = bookStore.getBook(124L);
        System.out.println("Get the book with id 124. " + book);
       
        try {
            book = bookStore.getBook(126L);
            System.out.println("Get the book with id 126. " + book);
        } catch (Exception exception) {
            System.out.println("Get the exception " + exception.getCause());
        }
       
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    public void testProxyConfiguration() {
        // interface
        BookInterface proxy = JAXRSClientFactory.create("http://foo", BookInterface.class);
        assertNotNull(WebClient.getConfig(proxy) != null);
        // cglib
        BookStore proxy2 = JAXRSClientFactory.create("http://foo", BookStore.class);
        assertNotNull(WebClient.getConfig(proxy2) != null);
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

       
        JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
        bean.setAddress("http://bar");
        bean.setResourceClass(BookStore.class);
        bean.setClassLoader(loader);
        BookStore client = (BookStore)bean.createWithValues(BookStore.class);
        assertNotNull(client);
        assertSame(client.getClass().getClassLoader(), loader);
        // tricky to test the loader has been used correctly with Maven
        // given that the system loader loads all the test classes 
       
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    @Test
    public void testGetConduit() throws Exception {
        JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
        bean.setAddress("http://bar");
        bean.setResourceClass(BookStore.class);
        BookStore store = bean.create(BookStore.class);
        Conduit conduit = WebClient.getConfig(store).getConduit();
        assertTrue(conduit instanceof HTTPConduit);
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

       
        JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
        bean.setAddress("http://bar");
        bean.setResourceClass(BookStore.class);
        bean.setClassLoader(loader);
        BookStore client = (BookStore)bean.createWithValues(BookStore.class);
        assertNotNull(client);
        assertSame(client.getClass().getClassLoader(), loader);
        // tricky to test the loader has been used correctly with Maven
        // given that the system loader loads all the test classes 
       
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    @Test
    public void testGetConduit() throws Exception {
        JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
        bean.setAddress("http://bar");
        bean.setResourceClass(BookStore.class);
        BookStore store = bean.create(BookStore.class);
        Conduit conduit = WebClient.getConfig(store).getConduit();
        assertTrue(conduit instanceof HTTPConduit);
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    @Test
    public void testGetConduit() throws Exception {
        JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
        bean.setAddress("http://bar");
        bean.setResourceClass(BookStore.class);
        BookStore store = bean.create(BookStore.class);
        Conduit conduit = WebClient.getConfig(store).getConduit();
        assertTrue(conduit instanceof HTTPConduit);
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    public void testProxyConfiguration() {
        // interface
        BookInterface proxy = JAXRSClientFactory.create("http://foo", BookInterface.class);
        assertNotNull(WebClient.getConfig(proxy) != null);
        // cglib
        BookStore proxy2 = JAXRSClientFactory.create("http://foo", BookStore.class);
        assertNotNull(WebClient.getConfig(proxy2) != null);
    }
View Full Code Here

Examples of org.apache.cxf.jaxrs.resources.BookStore

    public void testProxyConfiguration() {
        // interface
        BookInterface proxy = JAXRSClientFactory.create("http://foo", BookInterface.class);
        assertNotNull(WebClient.getConfig(proxy) != null);
        // cglib
        BookStore proxy2 = JAXRSClientFactory.create("http://foo", BookStore.class);
        assertNotNull(WebClient.getConfig(proxy2) != null);
    }
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.