当前位置: 首页>>代码示例>>Java>>正文


Java MessageDispatcherServlet类代码示例

本文整理汇总了Java中org.springframework.ws.transport.http.MessageDispatcherServlet的典型用法代码示例。如果您正苦于以下问题:Java MessageDispatcherServlet类的具体用法?Java MessageDispatcherServlet怎么用?Java MessageDispatcherServlet使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


MessageDispatcherServlet类属于org.springframework.ws.transport.http包,在下文中一共展示了MessageDispatcherServlet类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
	MessageDispatcherServlet servlet = new MessageDispatcherServlet();
	servlet.setApplicationContext(applicationContext);
	servlet.setTransformWsdlLocations(true);
	return new ServletRegistrationBean(servlet, "/ws/*");
}
 
开发者ID:vrk-kpa,项目名称:xroad-catalog,代码行数:8,代码来源:WebServiceConfig.java

示例2: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
    log.info("Registering message dispatcher servlet.");
    MessageDispatcherServlet servlet = new MessageDispatcherServlet();
    servlet.setApplicationContext(applicationContext);
    servlet.setTransformWsdlLocations(true);
    return new ServletRegistrationBean(servlet, "/soap-api/*");
}
 
开发者ID:VHAINNOVATIONS,项目名称:BCDS,代码行数:9,代码来源:WebServiceConfiguration.java

示例3: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(
		ApplicationContext applicationContext) {
	MessageDispatcherServlet servlet = new MessageDispatcherServlet();
	servlet.setApplicationContext(applicationContext);
	String path = this.properties.getPath();
	String urlMapping = (path.endsWith("/") ? path + "*" : path + "/*");
	ServletRegistrationBean registration = new ServletRegistrationBean(servlet,
			urlMapping);
	WebServicesProperties.Servlet servletProperties = this.properties.getServlet();
	registration.setLoadOnStartup(servletProperties.getLoadOnStartup());
	for (Map.Entry<String, String> entry : servletProperties.getInit().entrySet()) {
		registration.addInitParameter(entry.getKey(), entry.getValue());
	}
	return registration;
}
 
开发者ID:vikrammane23,项目名称:https-github.com-g0t4-jenkins2-course-spring-boot,代码行数:17,代码来源:WebServicesAutoConfiguration.java

示例4: onStartup

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Override
public void onStartup(ServletContext servletContext) throws ServletException {
	AnnotationConfigWebApplicationContext applicationContext = buildApplicationContext();
	Dynamic appServlet = servletContext.addServlet("appServlet", new DispatcherServlet(applicationContext));
	appServlet.setLoadOnStartup(1);
	appServlet.addMapping("/api/*", "/app/*");
	
	MessageDispatcherServlet messageDispatcherServlet = new MessageDispatcherServlet(applicationContext);
	messageDispatcherServlet.setTransformWsdlLocations(true);
	Dynamic wsServlet = servletContext.addServlet("wsServlet", messageDispatcherServlet);
	wsServlet.setLoadOnStartup(2);
	wsServlet.addMapping("/ws/*");
	
	FilterRegistration.Dynamic filter = servletContext.addFilter("openEntityManagerInViewFilter", buildOpenEntityManagerFilter());
	filter.addMappingForUrlPatterns(getDispatcherTypes(), false, "/api/*", "/app/*","/ws/*");
	
	servletContext.addListener(new ContextLoaderListener(applicationContext));
}
 
开发者ID:leosilvadev,项目名称:simplebank,代码行数:19,代码来源:Application.java

示例5: before

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Before
public void before() throws Exception {
	// Start jetty to provide spring webservice
	server = new Server(new InetSocketAddress("127.0.0.1", 0));
	ServletContextHandler contextHandler = new ServletContextHandler(ServletContextHandler.NO_SECURITY);
	contextHandler.setContextPath("/");
	final MessageDispatcherServlet messageDispatcherServlet = new MessageDispatcherServlet();
	messageDispatcherServlet.setContextConfigLocation("classpath:springWsServer.xml");
	messageDispatcherServlet.setTransformWsdlLocations(true);
	contextHandler.addServlet(new ServletHolder(messageDispatcherServlet), "/*");
	server.setHandler(contextHandler);
	server.start();
	final String serverUrl = "http://" + server.getConnectors()[0].getName() + "/springws/TestserviceEndpoint";

	// Init jaxws client with TraceeClientHandler
	final JaxwsTestserviceEndpointService endpointService = new JaxwsTestserviceEndpointService();
	endpointService.setHandlerResolver(new TraceeClientHandlerResolver());
	testservice = endpointService.getCurrentTraceeContextPort();
	((BindingProvider) testservice).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, serverUrl);
}
 
开发者ID:tracee,项目名称:tracee,代码行数:21,代码来源:JaxWsClientToSpringWsServerIT.java

示例6: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
    MessageDispatcherServlet servlet = new MessageDispatcherServlet();
    servlet.setApplicationContext(applicationContext);
    servlet.setTransformWsdlLocations(true);
    return new ServletRegistrationBean(servlet, "/ws/*");
}
 
开发者ID:daishicheng,项目名称:outcomes,代码行数:8,代码来源:WebServiceConfig.java

示例7: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
    MessageDispatcherServlet servlet = new MessageDispatcherServlet();
    servlet.setApplicationContext(applicationContext);
    servlet.setTransformWsdlLocations(true);
    return new ServletRegistrationBean(servlet, "/v1/customers/*");
}
 
开发者ID:kbastani,项目名称:cloud-native-microservice-strangler-example,代码行数:8,代码来源:WebServiceConfig.java

示例8: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
  MessageDispatcherServlet servlet = new MessageDispatcherServlet();
  servlet.setApplicationContext(applicationContext);

  return new ServletRegistrationBean(servlet, "/codenotfound/ws/*");
}
 
开发者ID:code-not-found,项目名称:spring-ws,代码行数:8,代码来源:WebServiceConfig.java

示例9: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {

  MessageDispatcherServlet servlet = new MessageDispatcherServlet();
  servlet.setApplicationContext(applicationContext);

  return new ServletRegistrationBean(servlet, "/codenotfound/ws/*");
}
 
开发者ID:code-not-found,项目名称:spring-ws,代码行数:9,代码来源:WebServiceConfig.java

示例10: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(
        ApplicationContext applicationContext) {

    MessageDispatcherServlet servlet = new MessageDispatcherServlet();
    servlet.setApplicationContext(applicationContext);

    return new ServletRegistrationBean(servlet,
            "/codenotfound/ws/*");
}
 
开发者ID:code-not-found,项目名称:spring-ws,代码行数:11,代码来源:WebServiceConfig.java

示例11: dispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean dispatcherServlet(
		ApplicationContext applicationContext) {
	MessageDispatcherServlet servlet = new MessageDispatcherServlet();
	servlet.setApplicationContext(applicationContext);
	return new ServletRegistrationBean(servlet, "/services/*");
}
 
开发者ID:Nephilim84,项目名称:contestparser,代码行数:8,代码来源:WebServiceConfig.java

示例12: addServiceDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
private void addServiceDispatcherServlet(ServletContext container, AnnotationConfigWebApplicationContext rootContext) {
    MessageDispatcherServlet messageDispatcherServlet = new MessageDispatcherServlet(rootContext);
    messageDispatcherServlet.setTransformWsdlLocations(true);
    ServletRegistration.Dynamic dispatcher = container.addServlet("spring-ws", messageDispatcherServlet);
    dispatcher.setLoadOnStartup(1);
    Set<String> mappingConflicts = dispatcher.addMapping(SERVICES_MAPPING);

    if (!mappingConflicts.isEmpty()) {
        for (String s : mappingConflicts) {
            LOG.error("Mapping conflict: " + s);
        }
        throw new IllegalStateException("'spring-ws' could not be mapped to '" + SERVICES_MAPPING + "'");
    }
}
 
开发者ID:jensalm,项目名称:ws-loadbalancer,代码行数:15,代码来源:MyWebAppInitializer.java

示例13: messageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Bean
public ServletRegistrationBean messageDispatcherServlet(ApplicationContext applicationContext) {
    MessageDispatcherServlet servlet = new MessageDispatcherServlet();
    servlet.setApplicationContext(applicationContext);
    servlet.setTransformWsdlLocations(true);
    return new ServletRegistrationBean(servlet, getServletMapping());
}
 
开发者ID:christophd,项目名称:citrus-simulator,代码行数:8,代码来源:SimulatorWebServiceAutoConfiguration.java

示例14: testCreateConnection

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
@Test
public void testCreateConnection() throws Exception
{
	assertNotNull(messageSender);
	assertSame(applicationContext.getBean(MessageDispatcherServlet.DEFAULT_MESSAGE_FACTORY_BEAN_NAME), messageSender.getMessageFactory());
	assertSame(applicationContext.getBean(MessageDispatcherServlet.DEFAULT_MESSAGE_RECEIVER_BEAN_NAME), messageSender.getWebServiceMessageReceiver());
}
 
开发者ID:lukas-krecan,项目名称:spring-ws-test,代码行数:8,代码来源:InMemoryWebServiceMessageSenderSpringTest.java

示例15: createMessageDispatcherServlet

import org.springframework.ws.transport.http.MessageDispatcherServlet; //导入依赖的package包/类
/**
 * Creates a spring-ws message dispatcher servlet
 * @param contextConfigLocation The spring configuration classes
 * @return A message dispatcher servlet based on the supplied configuration
 */
public static MessageDispatcherServlet createMessageDispatcherServlet(Class... contextConfigLocation) {
    StringBuilder items = new StringBuilder();
    for (Class aClass : contextConfigLocation) {
        items.append( aClass.getName());
        items.append(",");
    }
    MessageDispatcherServlet messageDispatcherServlet = new MessageDispatcherServlet();
    messageDispatcherServlet.setContextClass(AnnotationConfigWebApplicationContext.class);
    messageDispatcherServlet.setContextConfigLocation(removeEnd(items.toString(), "," ));
    messageDispatcherServlet.setTransformWsdlLocations(true);
    return messageDispatcherServlet;
}
 
开发者ID:NetsOSS,项目名称:embedded-jetty,代码行数:18,代码来源:EmbeddedSpringWsBuilder.java


注:本文中的org.springframework.ws.transport.http.MessageDispatcherServlet类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。