public class InheritableThreadLocalSecurityContextHolderStrategy extends Object implements SecurityContextHolderStrategy
InheritableThreadLocal
-based implementation of SecurityContextHolderStrategy
.ThreadLocal
,
HttpSessionContextIntegrationFilter
Constructor and Description |
---|
InheritableThreadLocalSecurityContextHolderStrategy() |
Modifier and Type | Method and Description |
---|---|
void |
clearContext()
Clears the current context.
|
SecurityContext |
getContext()
Obtains the current context.
|
void |
setContext(SecurityContext context)
Sets the current context.
|
public InheritableThreadLocalSecurityContextHolderStrategy()
public void clearContext()
SecurityContextHolderStrategy
clearContext
in interface SecurityContextHolderStrategy
public SecurityContext getContext()
SecurityContextHolderStrategy
getContext
in interface SecurityContextHolderStrategy
null
- create a default implementation if necessary)public void setContext(SecurityContext context)
SecurityContextHolderStrategy
setContext
in interface SecurityContextHolderStrategy
context
- to the new argument (should never be null
, although implementations must check if
null
has been passed and throw an IllegalArgumentException
in such cases)Copyright © 2015. All rights reserved.