Package javax.xml.ws

Examples of javax.xml.ws.WebServiceContext


        serviceFactory.setInvoker(new BeanInvoker(greeter));
        serviceFactory.setServiceClass(GreeterImpl.class);
       
        EndpointImpl endpoint = new EndpointImpl(getBus(), greeter, serviceFactory);
        WebServiceContext ctx = greeter.getContext();
        assertNull(ctx);
        try {
            String address = "http://localhost:8080/test";
            endpoint.publish(address);
        } catch (IllegalArgumentException ex) {
View Full Code Here


    @Test
    public void testEndpoint() throws Exception {  
        GreeterImpl greeter = new GreeterImpl();
        EndpointImpl endpoint = new EndpointImpl(getBus(), greeter, (String)null);
        WebServiceContext ctx = greeter.getContext();
        assertNull(ctx);
        try {
            String address = "http://localhost:8080/test";
            endpoint.publish(address);
        } catch (IllegalArgumentException ex) {
View Full Code Here

    @Test
    public void testEndpointStop() throws Exception {  
        GreeterImpl greeter = new GreeterImpl();
        EndpointImpl endpoint = new EndpointImpl(getBus(), greeter, (String)null);
        WebServiceContext ctx = greeter.getContext();
        assertNull(ctx);
        try {
            String address = "http://localhost:8080/test";
            endpoint.publish(address);
        } catch (IllegalArgumentException ex) {
View Full Code Here

        serviceFactory.setServiceClass(GreeterImpl.class);
       
        EndpointImpl endpoint = new EndpointImpl(getBus(), greeter,
                                                 new JaxWsServerFactoryBean(serviceFactory));
        WebServiceContext ctx = greeter.getContext();
        assertNull(ctx);
        try {
            String address = "http://localhost:8080/test";
            endpoint.publish(address);
        } catch (IllegalArgumentException ex) {
View Full Code Here

      {
         if (ep.getService().getDeployment().getType() == DeploymentType.JAXWS_JSE)
         {
            if (msgContext.get(MessageContext.SERVLET_REQUEST) != null)
            {
               WebServiceContext wsContext = contextFactory.newWebServiceContext(InvocationType.JAXWS_JSE, (SOAPMessageContextJAXWS)msgContext);
               invContext.addAttachment(WebServiceContext.class, wsContext);
            }
            else
            {
               log.warn("Cannot provide WebServiceContext, since the current MessageContext does not provide a ServletRequest");
View Full Code Here

      {
         if (ep.getService().getDeployment().getType() == DeploymentType.JAXWS_JSE)
         {
            if (msgContext.get(MessageContext.SERVLET_REQUEST) != null)
            {
               WebServiceContext wsContext = contextFactory.newWebServiceContext(InvocationType.JAXWS_JSE, (SOAPMessageContextJAXWS)msgContext);
               invContext.addAttachment(WebServiceContext.class, wsContext);
            }
            else
            {
               log.warn("Cannot provide WebServiceContext, since the current MessageContext does not provide a ServletRequest");
View Full Code Here

      {
         if (ep.getService().getDeployment().getType() == DeploymentType.JAXWS_JSE)
         {
            if (msgContext.get(MessageContext.SERVLET_REQUEST) != null)
            {
               WebServiceContext wsContext = contextFactory.newWebServiceContext(InvocationType.JAXWS_JSE, (SOAPMessageContextJAXWS)msgContext);
               invContext.addAttachment(WebServiceContext.class, wsContext);
            }
            else
            {
               log.warn("Cannot provide WebServiceContext, since the current MessageContext does not provide a ServletRequest");
View Full Code Here

    *
    *  @param invocation current invocation
    */
   @Override
   public void onBeforeInvocation(final Invocation invocation) {
      final WebServiceContext wsContext = getWebServiceContext(invocation);
      ThreadLocalAwareWebServiceContext.getInstance().setMessageContext(wsContext);
   }
View Full Code Here

        if (this.annotationProcessor != null) {
            // assume injection was already done
            return;
        }
       
        WebServiceContext wsContext = null;
        try {
            InitialContext ctx = new InitialContext();
            wsContext = (WebServiceContext) ctx.lookup("java:comp/WebServiceContext");
        } catch (NamingException e) {
            throw new WebServiceException("Failed to lookup WebServiceContext", e);
View Full Code Here

        if (this.annotationProcessor != null) {
            // assume injection was already done
            return;
        }
       
        WebServiceContext wsContext = null;
        try {
            InitialContext ctx = new InitialContext();
            wsContext = (WebServiceContext) ctx.lookup("java:comp/WebServiceContext");
        } catch (NamingException e) {
            throw new WebServiceException("Failed to lookup WebServiceContext", e);
View Full Code Here

TOP

Related Classes of javax.xml.ws.WebServiceContext

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.