commgrids.users
Class CGPersonal

java.lang.Object
  |
  +--commgrids.users.CGPersonal
All Implemented Interfaces:
PersonalInfo

public class CGPersonal
extends java.lang.Object
implements PersonalInfo

Virtual Classroom personal information provider.

$Id: CGPersonal.java,v 1.1 2001/09/27 19:37:30 balsoy Exp $


Constructor Summary
CGPersonal()
           
 
Method Summary
 void constructFromHashtable(UserObject parm1, java.util.Hashtable parm2)
          Fills the fields of a user object with values given in a hashtable.
 void constructPersonalInfo(UserObject user, java.lang.String userID, java.lang.String pwd, java.lang.String firstName, java.lang.String midName, java.lang.String lastName, java.lang.String pres, java.lang.String sufs, java.lang.String email)
          Method for user personal information implementer.
 void constructPersonalInfo(UserObject user, java.lang.String department, YearType year, java.lang.String photo, java.lang.String homePage, java.lang.String phone, Address address)
          Method for user personal information implementer.
 PersonalInfoTypeType getInfoType()
          Returns PersonalInfoTypeType for this implementer, which is
 UserObject getUserObject()
          Returns an empty User object which complies with this personal information standards.
 boolean hasEmail(UserObject user, java.lang.String email)
          Checks if a user has the given e-mail address
 java.util.Hashtable returnHashtable(UserObject parm1)
          Returns a hashtable whose values are retrieved from the given user object.
 boolean securityCheck(UserObject user, java.lang.String password, java.lang.String access)
          Checks if this user is authorized to perform a certain group of tasks.
 void updateFromHashtable(UserObject parm1, java.util.Hashtable parm2)
          Updates the fields of a user object with values given in a hashtable.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CGPersonal

public CGPersonal()
Method Detail

getInfoType

public PersonalInfoTypeType getInfoType()
Returns PersonalInfoTypeType for this implementer, which is
PersonalInfoTypeType.VC
Specified by:
getInfoType in interface PersonalInfo
Returns:
infoType One of VC for VirtualClassroom, IMS for IMS Enterprise Info Model, and PAPI for PAPI model.
See Also:
PersonalInfoTypeType

getUserObject

public UserObject getUserObject()
Returns an empty User object which complies with this personal information standards.
Specified by:
getUserObject in interface PersonalInfo
Returns:
a user object whose parameters are not set.

constructPersonalInfo

public void constructPersonalInfo(UserObject user,
                                  java.lang.String userID,
                                  java.lang.String pwd,
                                  java.lang.String firstName,
                                  java.lang.String midName,
                                  java.lang.String lastName,
                                  java.lang.String pres,
                                  java.lang.String sufs,
                                  java.lang.String email)
Method for user personal information implementer.
Specified by:
constructPersonalInfo in interface PersonalInfo
Parameters:
user - User object whose personal information will be set.
userID - User identifier for this user
pwd - Password information for this user
firstName - first name of this user
midName - middle name of this user
lastName - last name of this user
pres - prefix for the name if any, i.e. Prof Dr. separated space or period.
sufs - suffix for the name if any, i.e. Jr separated space,comma or period.
email - primary e-mail address of this user

constructPersonalInfo

public void constructPersonalInfo(UserObject user,
                                  java.lang.String department,
                                  YearType year,
                                  java.lang.String photo,
                                  java.lang.String homePage,
                                  java.lang.String phone,
                                  Address address)
Method for user personal information implementer.
Parameters:
user - User object whose personal information will be added.
department - Department of this user
year - Class information of this user, i.e. Freshman, Senior. See YearType for more information.
photo - URL or
midName - middle name of this user
lastName - last name of this user
pres - prefix for the name if any, i.e. Prof Dr. separated space or period.
sufs - suffix for the name if any, i.e. Jr separated space,comma or period.
email - primary e-mail address of this user

constructFromHashtable

public void constructFromHashtable(UserObject parm1,
                                   java.util.Hashtable parm2)
Fills the fields of a user object with values given in a hashtable.

NOT IMPLEMENTED

Specified by:
constructFromHashtable in interface PersonalInfo
Parameters:
user - user object whose personal information will be set.
values - a hashtable with values. ITS FORMAT IS NOT KNOWN NOW!

updateFromHashtable

public void updateFromHashtable(UserObject parm1,
                                java.util.Hashtable parm2)
                         throws GxException
Updates the fields of a user object with values given in a hashtable.

NOT IMPLEMENTED

Specified by:
updateFromHashtable in interface PersonalInfo
Parameters:
user - user object whose personal information will be set.
values - a hashtable with values given
Throws:
GxException - if any error is encountered i.e.
  • user parameter is null
  • user ID of this user object is different than the one in values.
  • any other problem

  • returnHashtable

    public java.util.Hashtable returnHashtable(UserObject parm1)
    Returns a hashtable whose values are retrieved from the given user object. The following are the keys of the hashtable: ...

    NOT IMPLEMENTED

    Specified by:
    returnHashtable in interface PersonalInfo
    Parameters:
    user - user object whose personal information will be returned.
    Returns:
    hashtable with above fields.

    hasEmail

    public boolean hasEmail(UserObject user,
                            java.lang.String email)
    Checks if a user has the given e-mail address
    Specified by:
    hasEmail in interface PersonalInfo
    Parameters:
    email - e-mail address of this user.
    Returns:
    true if e-mail address equals user's address; false otherwise.

    securityCheck

    public boolean securityCheck(UserObject user,
                                 java.lang.String password,
                                 java.lang.String access)
    Checks if this user is authorized to perform a certain group of tasks.
    Specified by:
    securityCheck in interface PersonalInfo
    Parameters:
    user - user whose information will be validated.
    password - password which is assigned to this user.
    access - security domain where user tries to access, i.e. account information, meeting information system configuration, user management
    Returns:
    true if this user passes security check; false otherwise.