public class DelegatingSecurityContextTaskExecutor extends DelegatingSecurityContextExecutor implements org.springframework.core.task.TaskExecutor
Constructor and Description |
---|
DelegatingSecurityContextTaskExecutor(org.springframework.core.task.TaskExecutor delegate)
Creates a new
DelegatingSecurityContextTaskExecutor that uses the current SecurityContext from
the SecurityContextHolder . |
DelegatingSecurityContextTaskExecutor(org.springframework.core.task.TaskExecutor delegateTaskExecutor,
SecurityContext securityContext)
Creates a new
DelegatingSecurityContextTaskExecutor that uses the specified SecurityContext . |
Modifier and Type | Method and Description |
---|---|
protected <T> Callable<T> |
wrap(Callable<T> delegate) |
protected Runnable |
wrap(Runnable delegate) |
execute, getDelegateExecutor
public DelegatingSecurityContextTaskExecutor(org.springframework.core.task.TaskExecutor delegateTaskExecutor, SecurityContext securityContext)
DelegatingSecurityContextTaskExecutor
that uses the specified SecurityContext
.delegateTaskExecutor
- the TaskExecutor
to delegate to. Cannot be null.securityContext
- the SecurityContext
to use for each DelegatingSecurityContextRunnable
public DelegatingSecurityContextTaskExecutor(org.springframework.core.task.TaskExecutor delegate)
DelegatingSecurityContextTaskExecutor
that uses the current SecurityContext
from
the SecurityContextHolder
.delegateTaskExecutor
- the TaskExecutor
to delegate to. Cannot be null.Copyright © 2019. All rights reserved.