|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.grid.jgdi.security.JGDIPrincipal
public class JGDIPrincipal
Field Summary | |
---|---|
static java.lang.String |
SESSION_ID_PREFIX
|
static java.lang.String |
SESSION_ID_SUFFIX
|
Constructor Summary | |
---|---|
JGDIPrincipal(java.lang.String username,
long sessionId)
Create a JGDIPrincipal with a username. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object o)
Compares the specified Object with this JGDIPrincipal
for equality. |
java.lang.String |
getName()
Return the username for this JGDIPrincipal . |
long |
getSessionId()
Get the session id |
java.lang.String |
getUsername()
Get the username |
int |
hashCode()
Return a hash code for this JGDIPrincipal . |
java.lang.String |
toString()
Return a string representation of this JGDIPrincipal . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String SESSION_ID_PREFIX
public static final java.lang.String SESSION_ID_SUFFIX
Constructor Detail |
---|
public JGDIPrincipal(java.lang.String username, long sessionId)
username
- the username for this user.sessionId
- the id of the session
java.lang.NullPointerException
- if the name
is null
.Method Detail |
---|
public java.lang.String getName()
JGDIPrincipal
.
getName
in interface java.security.Principal
JGDIPrincipal
public java.lang.String toString()
JGDIPrincipal
.
toString
in interface java.security.Principal
toString
in class java.lang.Object
JGDIPrincipal
.public boolean equals(java.lang.Object o)
JGDIPrincipal
for equality. Returns true if the given object is also a
JGDIPrincipal
and the two JGDIPrincipals
have the same username.
equals
in interface java.security.Principal
equals
in class java.lang.Object
o
- Object to be compared for equality with this
JGDIPrincipal
.
JGDIPrincipal
.public int hashCode()
JGDIPrincipal
.
hashCode
in interface java.security.Principal
hashCode
in class java.lang.Object
JGDIPrincipal
.public long getSessionId()
public java.lang.String getUsername()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |