All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.sprint.framework.web.service.handler.RequestHandlerRegistry Maven / Gradle / Ivy

The newest version!
package com.sprint.framework.web.service.handler;


import com.sprint.common.microkernel.extension.SPI;
import com.sprint.framework.web.service.handler.annotation.MatchingPattern;
import org.springframework.web.context.ServletContextAware;

import javax.servlet.FilterChain;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;


/**
 * {@link RequestHandler} 注册器。
 *
 * @author hongfeng.li
 * @since 2023/1/29
 */
@SPI
public interface RequestHandlerRegistry extends ServletContextAware {

    void register(RequestHandler handler);

    void register(MatchingPattern.Scope scope, String matchingPattern, RequestHandler requestHandler);

    void unregister(RequestHandler handler);

    void unregister(MatchingPattern.Scope scope, String matchingPattern);

    boolean handle(MatchingPattern.Scope scope, HttpServletRequest request, HttpServletResponse response, FilterChain chain) throws ServletException,
            IOException;

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy