|
Oracle Fusion Middleware Java API Reference for Oracle PDK Java 11g Release 1 (11.1.1) E10691-01 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.webdb.provider.v2.utils.BaseProviderUser oracle.portal.provider.v2.ProviderUser
public abstract class ProviderUser
Represents the Portal user. Additionally provides the methods for establishing and reaquiring the user's session.
Some Providers have a distinct notion users. Providers are able to configure the Portal (using a login server) to map between the Portal user and the application (Provider) user. The ProviderUser interface provides access to both the Portal user information and this mapped information.
The portal runs in a default public mode. This occurs when a user accesses the portal without logging in. This is represented by a special ProviderUser whose portal user name is defined by the String ProviderUser.PUBLIC. The convenience method isPublicUser() is provided to simplify this check.
Field Summary | |
---|---|
static int |
AUTH_LEVEL_NOT_DETERMINED
Authentication level has not yet been determined. |
static int |
AUTH_LEVEL_NOT_SUPPORTED
JPDK is running against a version of portal that does not support authentication level |
static java.lang.String |
DEFAULT_SUBSCRIBER_NAME
Name used for default portal user's realm, implied when no specific realm information is sent by portal. |
static int |
NOT_AUTHENTICATED
User is not logged on and does not have a persistent cookie |
static java.lang.String |
PORTAL_PUBLIC
Constant (string) representing the public user. |
static java.lang.String |
PUBLIC
Constant (string) representing the public user. |
static int |
PUBLIC_STRONG_AUTH
User has logged into the portal, using the user id PUBLIC, and been authenticated by the login server within the current session. |
static java.lang.String |
PUBLIC_USERNAME
Constant (string) representing the public user. |
static int |
PUBLIC_WEAK_AUTH
User is not logged on. |
static int |
USER_STRONG_AUTH
User has logged into the portal, using a user id other than PUBLIC, and been authenticated by the login server within the current session. |
static int |
USER_WEAK_AUTH
User is not logged on. |
Constructor Summary | |
---|---|
ProviderUser()
|
Method Summary | |
---|---|
abstract int |
getAuthenticationLevel()
Gets the authentication level for the user. |
abstract java.lang.String |
getEmail()
Get the portal user's email address. |
abstract java.lang.String |
getFirstName()
Get the portal user's first name. |
abstract java.lang.String |
getLastName()
Get the portal user's last name. |
abstract UserLocation |
getLocation()
Gets the user's location. |
abstract java.util.Calendar |
getLoginTime()
Gets the time when this user logged into the Portal. |
abstract java.lang.String |
getMappedName()
Gets the external application username that is mapped to this portal user. |
abstract java.lang.String |
getName()
Gets the name of the portal user represented by this object. |
abstract PortalRealm |
getPortalRealm()
Get the portal user's realm. |
abstract java.lang.String |
getPortalSessionId()
Gets the Portal session ID for this user. |
abstract java.lang.String |
getPropertyValue(java.lang.String propertyName)
Get a named property value of the user as stored in OID. |
abstract ProviderSubscription |
getProviderSubscription()
Gets subscription information related to this user/request Note, the subscription information is specific to the ProviderInstance the current request was received for. |
java.lang.String |
getProviderSubscriptionKey()
Gets the subscription key from the ProviderSubscription. |
java.lang.String |
getQualifiedName()
Gets the qualified username, ie username appended with company name separated by "@@". |
abstract ProviderSession |
getSession()
Used to create and/or reacquire the user session. |
abstract ProviderSession |
getSession(boolean create)
Used to create and/or reacquire the user session. |
abstract java.lang.String |
getSubscriberDN()
Get the portal user's Subscription distinguished name. |
abstract java.lang.String |
getSubscriberGUID()
Get the portal user's subscriber GUID. |
abstract java.lang.String |
getSubscriberName()
Get the portal user's subscriber name. |
abstract java.lang.String |
getUserDN()
Get the portal user's distinguished name. |
abstract java.lang.String |
getUserGUID()
Get the portal user's GUID. |
abstract boolean |
isLDAPEnabled()
Determine if the OidManager is configured. |
boolean |
isLoggedOn()
Indicates if the user has logged onto the portal in the current session (true). |
boolean |
isPublicUser()
Indicates if this request is from a public user, i.e. the user has not logged in and is not weakly authenticated based on a prior login. |
abstract boolean |
isUserInGroup(java.lang.String groupName)
check if this user is a member of a group. |
boolean |
isWeaklyAuthenticated()
Indicates if the current user is at least weakly authenticated. |
Methods inherited from class oracle.webdb.provider.v2.utils.BaseProviderUser |
---|
equals, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String PUBLIC
public static final java.lang.String PORTAL_PUBLIC
public static final java.lang.String PUBLIC_USERNAME
public static final java.lang.String DEFAULT_SUBSCRIBER_NAME
public static final int AUTH_LEVEL_NOT_DETERMINED
public static final int AUTH_LEVEL_NOT_SUPPORTED
public static final int NOT_AUTHENTICATED
public static final int PUBLIC_WEAK_AUTH
public static final int USER_WEAK_AUTH
public static final int PUBLIC_STRONG_AUTH
public static final int USER_STRONG_AUTH
Constructor Detail |
---|
public ProviderUser()
Method Detail |
---|
public abstract java.lang.String getName()
getName
in interface java.security.Principal
getName
in class oracle.webdb.provider.v2.utils.BaseProviderUser
public abstract java.lang.String getMappedName()
public abstract ProviderSubscription getProviderSubscription()
public java.lang.String getProviderSubscriptionKey()
public abstract PortalRealm getPortalRealm()
PortalRealm
implementation.
public java.lang.String getQualifiedName()
public abstract java.util.Calendar getLoginTime()
public abstract UserLocation getLocation()
null
,
which means the information is not available.
UserLocation
object representing the user's location.public abstract java.lang.String getPortalSessionId()
public abstract int getAuthenticationLevel()
public boolean isLoggedOn()
true
if the user has logged onto the portal,
false
otherwise.public boolean isWeaklyAuthenticated()
true
if the current user is at least weakly
authenticated, false
otherwise.public boolean isPublicUser()
true
if the user is accessing the portal in public
mode, false
otherwise.public abstract ProviderSession getSession(boolean create) throws java.lang.IllegalStateException
Note: this method can throw an llegalStateException. This occurs if the user object has become stale. I.e. no longer contains the state that it needs to acquire/create the session.
As all Provider/Portlet APIs give you access to the User object per request you should not (need to) retain the user object via reference in cross-request object (like the session itself). This only leads to possibilities of memory leaks.
create
- if true then a session is created for the user if it
doesn't currently exist.
java.lang.IllegalStateException
public abstract ProviderSession getSession() throws java.lang.IllegalStateException
If running as a Servlet and sessions are maintained via cookies then the sessions must only be created in Provider.initSession().
Note: this method can throw an llegalStateException. This occurs if the user object has become stale. I.e. no longer contains the state that it needs to acquire/create the session.
As all Provider/Portlet APIs give you access to the User object per request you should not (need to) retain the user object via reference in cross-request object (like the session itself). This only leads to possibilities of memory leaks.
java.lang.IllegalStateException
public abstract java.lang.String getUserDN()
public abstract java.lang.String getSubscriberDN()
public abstract java.lang.String getUserGUID()
public abstract java.lang.String getSubscriberGUID()
public abstract java.lang.String getSubscriberName()
public abstract java.lang.String getFirstName()
public abstract java.lang.String getLastName()
public abstract java.lang.String getEmail()
public abstract java.lang.String getPropertyValue(java.lang.String propertyName)
propertyName
- of a user property
public abstract boolean isUserInGroup(java.lang.String groupName)
groupName
- the name of the group
public abstract boolean isLDAPEnabled()
|
Oracle Fusion Middleware Java API Reference for Oracle PDK Java 11g Release 1 (11.1.1) E10691-01 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |