cn.ocoop.framework.safe.ex.ExceptionAdviceHandler Maven / Gradle / Ivy
package cn.ocoop.framework.safe.ex;
import cn.ocoop.framework.safe.ex.authz.AuthorizingException;
import cn.ocoop.framework.safe.ex.authz.InvalidCaptchaException;
import cn.ocoop.framework.safe.ex.authz.InvalidSessionStateException;
import cn.ocoop.framework.safe.ex.authz.LackPermissionException;
import com.google.common.collect.Maps;
import lombok.extern.slf4j.Slf4j;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.lang.Nullable;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.context.request.WebRequest;
import org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandler;
import org.springframework.web.util.WebUtils;
import java.util.Map;
@Slf4j
public class ExceptionAdviceHandler extends ResponseEntityExceptionHandler {
@ExceptionHandler(AuthorizingException.class)
public ResponseEntity © 2015 - 2025 Weber Informatics LLC | Privacy Policy