public class ReqContext extends Object
context request context includes info about:
Constructor and Description |
---|
ReqContext(AccessControlContext acl_ctxt) |
ReqContext(Subject sub) |
Modifier and Type | Method and Description |
---|---|
static ReqContext |
context() |
boolean |
isImpersonating() |
Principal |
principal()
The primary principal associated current subject
|
Principal |
realPrincipal()
The real principal associated with the subject.
|
InetAddress |
remoteAddress() |
Integer |
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 acl_ctxt)
public ReqContext(Subject sub)
public static ReqContext 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()
public Integer requestID()
request ID of this request
Copyright © 2019 The Apache Software Foundation. All Rights Reserved.