Oracle Collaboration Suite Discussions Java API Reference
10g (10.1.1)

Part No. B16232-01


oracle.discussions.sdk
Class TdUser

java.lang.Object
  extended byoracle.discussions.sdk.TdUser


public class TdUser
extends java.lang.Object

Represents a oracle discussions user. Holds user related information like User DN, User Guid, User Email ID, UserName and others.

Sample code snippet illustrating the usage of TdUser

 //Extract the user information from the oracle internet directory.
 UserInfo usrInfo = LdapUtils.getUserInfoByName(username);
 //Construct a oracle discussions user with the information extracted.
 TdUser tdu = new TdUser(username, usrInfo.getDn(), usrInfo.getEmail(), usrInfo.getGuid());
 
Since:
OCS 10.1.1
See Also:
UserInfo.java, LdapUtils.java

Field Summary
static java.lang.String SSO_SESSION_ID
Represents a user's single sign on session identifier.
static java.lang.String USER_AGENT
Browser which the user is using.
static java.lang.String USER_CHAR_SET
Represents the character set a oracle discussions user is using.
static java.lang.String USER_REFERRER
Represents the url from which the user request is coming in.
static java.lang.String USER_REMOTE_ADDRESS
Represents a user's remote machine address.

Method Summary
boolean equals(java.lang.Object obj)
Compares two threaded discussions user objects and returns a boolean variable indicating the comparison status.
java.lang.String getDomain()
Returns a user's domain name.
java.lang.String getUserDN()
Returns user's distinguished name
java.lang.String getUserEmail()
Returns a user's secondary email address.
java.lang.String getUserGuid()
Returns a user's global userid
java.lang.String getUserNickname()
Returns a user's nickname
java.lang.String getUserPrimaryEmail()
Returns a user's oracle email address
java.util.Properties getUserSessionProperties()
Returns the user's session properties object.
java.lang.String getUserSessionProperty(java.lang.String propName)
Returns a user session value corresponding to the key supplied.
int hashCode()
Generates a hash code corresponding to a user guid.
void setUserSessionProperty(java.lang.String name, java.lang.String value)
Custom user's properties for one user's session.
java.lang.String toString()
Converts a user object into a string representation

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

Field Detail

USER_AGENT

public static final java.lang.String USER_AGENT
Browser which the user is using.
See Also:
Constant Field Values

USER_REFERRER

public static final java.lang.String USER_REFERRER
Represents the url from which the user request is coming in.
See Also:
Constant Field Values

USER_CHAR_SET

public static final java.lang.String USER_CHAR_SET
Represents the character set a oracle discussions user is using.
See Also:
Constant Field Values

USER_REMOTE_ADDRESS

public static final java.lang.String USER_REMOTE_ADDRESS
Represents a user's remote machine address.
See Also:
Constant Field Values

SSO_SESSION_ID

public static final java.lang.String SSO_SESSION_ID
Represents a user's single sign on session identifier.
See Also:
Constant Field Values

Method Detail

getUserDN

public java.lang.String getUserDN()
Returns user's distinguished name
Returns:
String

getUserGuid

public java.lang.String getUserGuid()
Returns a user's global userid
Returns:
String

getUserNickname

public java.lang.String getUserNickname()
Returns a user's nickname
Returns:
String

getUserPrimaryEmail

public java.lang.String getUserPrimaryEmail()
Returns a user's oracle email address
Returns:
String

getUserEmail

public java.lang.String getUserEmail()
Returns a user's secondary email address. A secondary email address is optional.Can be another email address apart from oracle email address.
Returns:
String

getDomain

public java.lang.String getDomain()
Returns a user's domain name. The domain name can be derived from user email
Returns:
String

toString

public java.lang.String toString()
Converts a user object into a string representation
Returns:
String

equals

public boolean equals(java.lang.Object obj)
Compares two threaded discussions user objects and returns a boolean variable indicating the comparison status. The comparison is done by comparing the user global user ids. The methid returns true is they are equal and false otherwise.
Parameters:
obj - An object which is compared with the user object
Returns:
boolean

hashCode

public int hashCode()
Generates a hash code corresponding to a user guid.
Returns:
int

setUserSessionProperty

public void setUserSessionProperty(java.lang.String name,
                                   java.lang.String value)
Custom user's properties for one user's session. These properties may include values such as the IP address of the machine the user used to establish a connection or his browser.
Parameters:
name - key of the properties entry
value - value of the properties entry

getUserSessionProperty

public java.lang.String getUserSessionProperty(java.lang.String propName)
Returns a user session value corresponding to the key supplied. If a value is not found for the key, then null is returned.
Parameters:
propName - the key to which a value is returned
Returns:
String

getUserSessionProperties

public java.util.Properties getUserSessionProperties()
Returns the user's session properties object.
Returns:
properties

Copyright © 2005, Oracle. All rights reserved.