Package org.apache.cxf.jaxws22

Examples of org.apache.cxf.jaxws22.EndpointImpl


    protected org.apache.cxf.jaxws.EndpointImpl createEndpointImpl(Bus bus,
                                              String bindingId,
                                              Object implementor,
                                              WebServiceFeature ... features) {
        if (isJaxWs22()) {
            return new EndpointImpl(bus, implementor, bindingId, features);
        }
        //couldn't find the 2.2 stuff, assume 2.1 behavior
        return super.createEndpointImpl(bus, bindingId, implementor, features);
    }
View Full Code Here


                } catch (Exception e) {
                    throw new WebServiceException(new Message("ENDPOINT_CREATION_FAILED_MSG",
                                                              LOG).toString(), e);
                }
            }
            EndpointImpl ep = new EndpointImpl(bus, null, factory);
            ep.setImplementorClass(implementorClass);
            return ep;
        } else {
            throw new WebServiceException(new Message("INVALID_IMPLEMENTOR_EXC", LOG).toString());
        }
    }
View Full Code Here

            JaxWsServerFactoryBean factory = new JaxWsServerFactoryBean();
            if (features != null) {
                factory.getJaxWsServiceFactory().setWsFeatures(Arrays.asList(features));
            }
            if (invoker != null) {
                factory.setInvoker(new JAXWS22Invoker(invoker));
                try {
                    invoker.inject(new WebServiceContextImpl());
                } catch (Exception e) {
                    throw new WebServiceException(new Message("ENDPOINT_CREATION_FAILED_MSG",
                                                              LOG).toString(), e);
View Full Code Here

  public void testTestAssertionEndpoint1061()
  {
    // Test that the assertion returns true for an endpoint with an absolute address.
  try
  {
    EndpointImpl endpoint = new EndpointImpl();
    endpoint.setAddress(new URI("http://www.sample.org"));
    if(!val.testAssertionEndpoint1061(endpoint, reporter))
    {
      fail("The testAssertionEndpoint1061 method returned false for an endpoint with an absolute address.");
    }
  }
  catch(URISyntaxException e)
  {
    fail("There was a problem creating the address URI for the test method " + e);
  }
  catch(WSDLException e)
  {
    fail("There was a problem running the test assertion method " + e);
  }
 
    // Test that the assertion returns false for an endpoint with a relative address.
  try
  {
    EndpointImpl endpoint = new EndpointImpl();
    endpoint.setAddress(new URI("sample.org"));
    if(val.testAssertionEndpoint1061(endpoint, reporter))
    {
      fail("The testAssertionEndpoint1061 method returned true for an endpoint with a relative address.");
    }
  }
  catch(URISyntaxException e)
  {
    fail("There was a problem creating the address URI for the test method " + e);
  }
  catch(WSDLException e)
  {
    fail("There was a problem running the test assertion method " + e);
  }
 
    // Test that the assertion returns true for an endpoint with a null address. This will be
  // caught be schema validation.
  try
  {
    EndpointImpl endpoint = new EndpointImpl();
    if(!val.testAssertionEndpoint1061(endpoint, reporter))
    {
      fail("The testAssertionEndpoint1061 method returned false for an endpoint with a null address.");
    }
  }
View Full Code Here

     */
    protected void setUp() throws Exception
    {
        super.setUp();
        fURI = new URI("http://apache.org/endpointURI");
      fEndpointImpl = new EndpointImpl();
      fEndpoint = fEndpointImpl;
    }
View Full Code Here

    /**
     * Test that the NCName specified on the setName method is returned by getName.
     */
    public void testSetAndGetName()
    {
        EndpointElement endpoint = new EndpointImpl();
        NCName ncName = new NCName("dummy");

        endpoint.setName(ncName);
        assertTrue("NCName returned by EndpointElement.getName() was not the one set by setName().",
                ncName.equals(endpoint.getName()));
    }
View Full Code Here

     * Test that the QName specified on the setBindingName method is returned by
     * the getBindingName method.
     */
    public void testSetAndGetBindingName()
    {
        EndpointElement endpoint = new EndpointImpl();
        QName qname = new QName("urn:woden","dummy");
        endpoint.setBindingName(qname);
        QName returnedQN = endpoint.getBindingName();
        assertTrue("QName returned by EndpointElement.getBindingName() was not the one set by setBindingName().",
                   returnedQN.equals(qname));
    }
View Full Code Here

    /**
     * Test that the URI specified on the setAddress method is returned by getAddress.
     */
    public void testSetAndGetAddress() throws Exception
    {
        EndpointElement endpoint = new EndpointImpl();
        URI uri = new URI("urn:dummy");
        endpoint.setAddress(uri);
        assertTrue("URI returned by EndpointElement.getAddress() was not the one set by setAddress().",
                   "urn:dummy".equals(endpoint.getAddress().toString()));
    }
View Full Code Here

    /**
     * Test that the NCName specified on the setName method is returned by getName.
     */
    public void testSetAndGetNameFromOM(){
        EndpointElement endpoint = new EndpointImpl();
        NCName ncName = new NCName("dummy");

        endpoint.setName(ncName);
        assertTrue("NCName returned by EndpointElement.getName() was not the one set by setName().",
                ncName.equals(endpoint.getName()));
    }
View Full Code Here

    /**
     * Test that the QName specified on the setBindingName method is returned by
     * the getBindingName method.
     */
    public void testSetAndGetBindingNameFromOM(){
        EndpointElement endpoint = new EndpointImpl();
        QName qname = new QName("urn:woden","dummy");
        endpoint.setBindingName(qname);
        QName returnedQN = endpoint.getBindingName();
        assertTrue("QName returned by EndpointElement.getBindingName() was not the one set by setBindingName().",
                   returnedQN.equals(qname));
    }
View Full Code Here

TOP

Related Classes of org.apache.cxf.jaxws22.EndpointImpl

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.