
com.atlassian.connect.spring.internal.jwt.CanonicalHttpServletRequest Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of atlassian-connect-spring-boot-jwt Show documentation
Show all versions of atlassian-connect-spring-boot-jwt Show documentation
Provides JSON Web Token handling for Atlassian Connect for Spring Boot
package com.atlassian.connect.spring.internal.jwt;
import org.apache.commons.lang3.StringUtils;
import javax.servlet.http.HttpServletRequest;
import java.util.Map;
public class CanonicalHttpServletRequest implements CanonicalHttpRequest {
private final HttpServletRequest request;
public CanonicalHttpServletRequest(final HttpServletRequest request) {
this.request = request;
}
@Override
public String getMethod() {
return request.getMethod();
}
@Override
public String getRelativePath() {
return StringUtils.removeStart(request.getRequestURI(), request.getContextPath());
}
@Override
@SuppressWarnings("unchecked")
// the javadoc on HttpServletRequest.getParameterMap() says that the return type is Map
public Map getParameterMap() {
return request.getParameterMap();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy