public class ApiUserSession extends Object
A user may have more than one active session. Each such session will have its own session object.
Constructor and Description |
---|
ApiUserSession() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
Date |
getLastRequest()
The date and time of the last request received as part of this session.
|
String |
getName()
The username associated with the session.
|
String |
getRemoteAddr()
The remote IP address for the session.
|
int |
hashCode() |
void |
setLastRequest(Date lastRequest) |
void |
setName(String name) |
void |
setRemoteAddr(String remoteAddr) |
String |
toString() |
public String getName()
This will be the same value shown to the logged in user in the UI, which will normally be the same value they typed when logging in, but it is possible that in certain external authentication scenarios, it will differ from that value.
public void setName(String name)
public String getRemoteAddr()
This will be the remote IP address for the last request made as part of this session. It is not guaranteed to be the same IP address as was previously used, or the address used to initiate the session.
public void setRemoteAddr(String remoteAddr)
public Date getLastRequest()
This will be returned in ISO 8601 format from the REST API.
public void setLastRequest(Date lastRequest)
Copyright © Cloudera, Inc. Released under Apache License, Version 2.0.