public class ReqContext extends Object
Request context. Context request context includes info about:
Constructor and Description |
---|
ReqContext(AccessControlContext aclCtxt) |
ReqContext(ReqContext other)
Copy Constructor.
|
ReqContext(Subject sub) |
Modifier and Type | Method and Description |
---|---|
static ReqContext |
context()
Get context.
|
boolean |
isImpersonating()
Check whether context is impersonating.
|
Principal |
principal()
The primary principal associated current subject.
|
Principal |
realPrincipal()
The real principal associated with the subject.
|
InetAddress |
remoteAddress() |
int |
requestID()
request ID of this request.
|
static void |
reset()
Reset the context back to a default.
|
void |
setRealPrincipal(Principal realPrincipal) |
void |
setRemoteAddress(InetAddress addr)
client address.
|
void |
setSubject(Subject subject)
Set remote subject explicitly.
|
Subject |
subject()
Retrieve client subject associated with this request context.
|
String |
toString() |
public ReqContext(AccessControlContext aclCtxt)
public ReqContext(Subject sub)
public ReqContext(ReqContext other)
Copy Constructor.
public static ReqContext context()
Get context.
public static void reset()
Reset the context back to a default. used for testing.
public void setRemoteAddress(InetAddress addr)
client address.
public InetAddress remoteAddress()
public void setSubject(Subject subject)
Set remote subject explicitly.
public Subject subject()
Retrieve client subject associated with this request context.
public Principal principal()
The primary principal associated current subject.
public void setRealPrincipal(Principal realPrincipal)
public Principal realPrincipal()
The real principal associated with the subject.
public boolean isImpersonating()
Check whether context is impersonating.
public int requestID()
request ID of this request.
Copyright © 2019 The Apache Software Foundation. All rights reserved.