Skip navigation links


com.bea.p13n.usermgmt.profile
Class ProfileIdentity

java.lang.Object
  extended by com.bea.p13n.usermgmt.profile.ProfileIdentity

All Implemented Interfaces
Serializable
Direct Known Subclasses:
MixedProfileIdentity

public class ProfileIdentity
extends Object
implements Serializable

Lightweight object to represent a profile's identity. This will contain some combination of username and groupname. If both are provided, the profile represents the user's profile, and the group is used as an explicit successor. If only a username is provided, it simply represents the user's profile. If only a groupname is proivded, it represents the group's profile.

See Also
ProfileWrapper, Serialized Form

Constructor Summary
ProfileIdentity()
           

 

Method Summary
 boolean equals(Object other)
           
 String getGroupname()
          retrieve the groupname
 ProfileType getProfileType()
          Determine whether this user is anonymous, tracked, or registered
 String getUsername()
          retrieve the username
 int hashCode()
           
 String toString()
           

 

Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait

 

Constructor Detail

ProfileIdentity

public ProfileIdentity()

Method Detail

getProfileType

public ProfileType getProfileType()
Determine whether this user is anonymous, tracked, or registered
Returns
Returns ProfileType.REGISTERED if the user has registered and has a valid username. Returns ProfileType.ANONYMOUS if the user is anonymous. Anonymous users have no username or groupname. Returns ProfileType.TRACKED if the user is tracked. The username will actually be the trackingId on the AnonymousProfileWrapper or TrackedProfileWrapper.
See Also
ProfileType

getUsername

public String getUsername()
retrieve the username

getGroupname

public String getGroupname()
retrieve the groupname

toString

public String toString()
Overrides:
toString in class Object
Returns
a string representation

hashCode

public int hashCode()
Overrides:
hashCode in class Object
Returns
a hashCode based on the string representation

equals

public boolean equals(Object other)
Overrides:
equals in class Object
Returns
true if the argument is a ProfileIdentity that is equal to this one

Skip navigation links


Copyright © 2010, Oracle. All rights reserved.