Ejemplo n.º 1
0
 public void publish(javax.xml.ws.spi.http.HttpContext context) {
   ServerFactoryBean sf = getServerFactory();
   if (sf.getDestinationFactory() == null) {
     sf.setDestinationFactory(new JAXWSHttpSpiTransportFactory(context));
   }
   publish(context.getPath());
 }
Ejemplo n.º 2
0
 protected void run() {
   Object implementor = new HelloImpl();
   String address = "http://localhost:" + PORT + "/wsa/responses";
   EndpointImpl ep =
       new EndpointImpl(BusFactory.getThreadDefaultBus(), implementor, null, getWsdl());
   ep.publish(address);
 }
Ejemplo n.º 3
0
 // Replaces cxf-servlet.xml
 @Bean
 // <jaxws:endpoint id="helloWorld" implementor="demo.spring.service.HelloWorldImpl"
 // address="/HelloWorld"/>
 public EndpointImpl helloWorldService(LoggingInInterceptor logIn, LoggingOutInterceptor logOut) {
   EndpointImpl endpoint = new EndpointImpl(getBus(), new HelloWorldService());
   endpoint.publish("/helloservice");
   endpoint.getServer().getEndpoint().getInInterceptors().add(logIn);
   endpoint.getServer().getEndpoint().getOutInterceptors().add(logOut);
   return endpoint;
 }
Ejemplo n.º 4
0
  protected void initDefaultServant() {
    servant = new HttpNumberImpl();

    String wsdlLocation = "testutils/factory_pattern.wsdl";
    String bindingId = null;
    EndpointImpl ep =
        new EndpointImpl(BusFactory.getDefaultBus(), servant, bindingId, wsdlLocation);
    ep.setEndpointName(new QName(NUMBER_SERVICE_QNAME.getNamespaceURI(), "NumberPort"));
    ep.publish();
    templateEpr = ep.getServer().getDestination().getAddress();
  }
Ejemplo n.º 5
0
  private EndpointImpl generateEndPointImpl(Class<?> cl, String endPoint) {
    Bus bus = (Bus) applicationContext.getBean(Bus.DEFAULT_BUS_ID);
    if (!bus.getInInterceptors()
        .contains(applicationContext.getBean(HeaderServiceValidator.class))) {
      bus.getInInterceptors().add(applicationContext.getBean(HeaderServiceValidator.class));
    }

    Object implementor = applicationContext.getBean(cl);
    EndpointImpl endpoint = new EndpointImpl(bus, implementor);
    endpoint.publish(endPoint);
    endpoint.getServer().getEndpoint().getInInterceptors().add(new LoggingInInterceptor());
    endpoint.getServer().getEndpoint().getOutInterceptors().add(new LoggingOutInterceptor());
    return endpoint;
  }
Ejemplo n.º 6
0
 public void publish() {
   publish(getAddress());
 }