Package org.springframework.security.web.access.intercept

# Class RequestAuthorizationContext

java.lang.Object
org.springframework.security.web.access.intercept.RequestAuthorizationContext

public final class RequestAuthorizationContext extends Object
An `HttpServletRequest` authorization context.

Since:
  5.5

## Constructor Summary

Constructors
Constructor
Description
`RequestAuthorizationContext(jakarta.servlet.http.HttpServletRequest request)`
Creates an instance.
`RequestAuthorizationContext(jakarta.servlet.http.HttpServletRequest request, Map<String,String> variables)`
Creates an instance.

## Method Summary

Modifier and Type
Method
Description
`jakarta.servlet.http.HttpServletRequest`
`getRequest()`
Returns the `HttpServletRequest`.
`Map<String,String>`
`getVariables()`
Returns the extracted variable values where the key is the variable name and the value is the variable value.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### RequestAuthorizationContext

public RequestAuthorizationContext(jakarta.servlet.http.HttpServletRequest request)
Creates an instance.

Parameters:
  `request` - the `HttpServletRequest` to use

### RequestAuthorizationContext

public RequestAuthorizationContext(jakarta.servlet.http.HttpServletRequest request, Map<String,String> variables)
Creates an instance.

Parameters:
  `request` - the `HttpServletRequest` to use
  `variables` - a map containing key-value pairs representing extracted variable names and variable values

## Method Details

### getRequest

public jakarta.servlet.http.HttpServletRequest getRequest()
Returns the `HttpServletRequest`.

Returns:
  the `HttpServletRequest` to use

### getVariables

public Map<String,String> getVariables()
Returns the extracted variable values where the key is the variable name and the value is the variable value.

Returns:
  a map containing key-value pairs representing extracted variable names and variable values