List of usage examples for org.springframework.web.servlet.handler SimpleUrlHandlerMapping setAlwaysUseFullPath
public void setAlwaysUseFullPath(boolean alwaysUseFullPath)
From source file:org.jclouds.demo.tweetstore.config.SpringServletConfig.java
@Bean public HandlerMapping handlerMapping() { SimpleUrlHandlerMapping mapping = new SimpleUrlHandlerMapping(); Map<String, Object> urlMap = Maps.newHashMapWithExpectedSize(2); urlMap.put("/store/*", storeTweetsController()); urlMap.put("/tweets/*", addTweetsController()); urlMap.put("/stores/*", enqueueStoresController()); urlMap.put("/clear/*", clearTweetsController()); mapping.setUrlMap(urlMap);//from w w w .j ava2s.c o m /* * "/store", "/tweets" and "/stores" are part of the servlet mapping and thus * stripped by the mapping if using default settings. */ mapping.setAlwaysUseFullPath(true); return mapping; }