Spring Framework ServletWrappingController - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Spring Framework ServletWrappingController class.

This code example shows how to use the following methods:setServletClass, setServletName, setSupportedMethods
/** 
 * @author Spencer Gibb 
 */ 
public class ZuulController extends ServletWrappingController { 
 
    public ZuulController() { 
        setServletClass(ZuulServlet.class); 
        setServletName("zuul"); 
        setSupportedMethods((String[])null); // Allow all 
    } 
 
    @Override 
    protected ModelAndView handleRequestInternal(HttpServletRequest request, HttpServletResponse response) throws Exception { 
        try { 
            return super.handleRequestInternal(request, response); 
        } finally { 
            // @see com.netflix.zuul.context.ContextLifecycleFilter.doFilter 
            RequestContext.getCurrentContext().unset(); 
        } 
    } 
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:setServletClass, setServletName
 
    protected String path; 
    protected boolean sensitive; 
    protected boolean enabled = true; 
 
    protected final ServletWrappingController controller = new ServletWrappingController(); 
 
    @Override 
    public void afterPropertiesSet() throws Exception { 
        this.controller.afterPropertiesSet(); 
    } 
 
    @Override 
    public void setServletContext(ServletContext servletContext) { 
        this.controller.setServletContext(servletContext); 
    } 
 
    @Override 
    public void setApplicationContext(ApplicationContext applicationContext) throws BeansException { 
        this.controller.setApplicationContext(applicationContext); 

5
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 * Wrapper for Spring's ServletWrappingController to allow use of GeoServer's config dir. 
 *  
 * @author Alan Gerber, The Open Planning Project 
 * 
 */ 
public class PrintingServletWrappingController extends 
ServletWrappingController { 
 
    private Logger LOG = org.geotools.util.logging.Logging.getLogger("org.geoserver.printing"); 
 
    public void setInitParameters(Properties initParameters) { 
        // find the config parameter and update it so it points to $GEOSERVER_DATA_DIR/printing/$CONFIG 
        String configProp = initParameters.getProperty("config"); 
 
        try { 
            GeoServerResourceLoader loader = GeoServerExtensions.bean(GeoServerResourceLoader.class); 
            String configPath = Paths.path("printing", Paths.convert(configProp)); 
            Resource config = loader.get(configPath); 
 
            if (config.getType() == Type.UNDEFINED) { 
5
CodeRank
Experience pair programming with AI  Get Codota for Java
See Code Examples for Spring Framework ServletWrappingController Methods: