com.plumtree.portalpages.browsing.editors.userprofile
Class UserProfileModel

java.lang.Object
  extended by com.plumtree.uiinfrastructure.editor.EditorModel
      extended by com.plumtree.portalpages.browsing.editors.userprofile.UserProfileModel
All Implemented Interfaces:
IManagedObject, IModel, IModelRO, IMVCObject, IEditorModelRO, IRepostModel
Direct Known Subclasses:
PasswordManagerModel

public class UserProfileModel
extends EditorModel

Author:
DanD, jennifersu

Field Summary
protected  XPArrayList m_alProfilePages
           
protected  int m_currProfilePage
           
protected  XPHashtable m_htPageToPortletMapping
           
protected  XPHashtable m_htPropTypeTable
           
protected  XPHashtable m_htPropValueTable
           
protected  int m_numProfilePages
           
protected  XPHashtable m_numProfileSectionsTable
          Web Service ID for User Profile Portlets.
static java.lang.String STR_MVC_CLASS_NAME
          object name
 
Fields inherited from class com.plumtree.uiinfrastructure.editor.EditorModel
isReadAccessAvailable, m_asOwner, m_bCloseOnDone, m_bDeleteOnCancel, m_bEnableApplyButton, m_bEnableCancelButton, m_bHideLeftNav, m_bIsEditorReadOnly, m_bUserHasAccessToEditor, m_nEditorType
 
Constructor Summary
UserProfileModel()
           
 
Method Summary
 boolean CheckEditorAccessAndStart(XPHashtable _htFormData)
          Code executed when the Editor is starting.
 java.lang.Object Create()
          This method is used by the ASManager to return new instances of managed objects.
 void DoTaskOnChangePage(java.lang.String _sNewSpaceName, java.lang.String _sNewPageName)
          This method can be implemented by classes extending this one.
 void Finish()
          Code executed in finish.
 java.lang.String GetName()
          Returns the Class name.
 java.lang.String GetNameFromObjectID(int nClassID, int nObjectID)
          Returns the name for an object
 int GetNumProfilePages()
           
 int GetNumProfileSections(int _profilePageIndex)
           
protected  IASQueryResult GetObjectPropData(IPTObjectProperties _ptObjProp)
          Return object property non-reference data
protected  IASQueryResult GetObjectPropRefData(IPTObjectProperties _ptObjProp)
          Return object property reference data
 XPArrayList GetProfilePages()
          Returns an XPHashtable, with portlet ID as the key, profile page ID as the value.
 Redirect GetRedirectAfterFinish()
          DCA - The 508 has a different logic than standard.
 XPHashtable GetUserValues()
           
 void Init(AActivitySpace aspace)
          Inits the Model with the Activity Space.
 IPTGadget LookupPortlet(IPTProfilePage _ptProfilePage)
           
protected  XPHashtable PutUserPropertiesIntoHashtable()
           
 int SavePage(java.lang.String _sPageName, XPHashtable _htFormData)
          Calls the right save function according to the page name passed in argument.
 void SetCurrentProfilePage(int index)
           
 void SetNumProfileSectionsTable(int profilePageNum, int numProfileSections)
           
 
Methods inherited from class com.plumtree.uiinfrastructure.editor.EditorModel
Cancel, CleanupAllData, CleanupTempData, DoTaskAfterStore, DoTaskBeforeStore, DoTaskOnComeBackFromSubEditor, DoTaskOnStartEditor, GetAccessToEditorPriviledges, GetCloseOnDone, GetCurrentRepostAction, GetDeleteOnCancel, GetEditorType, GetEnableApplyButton, GetEnableCancelButton, GetHideLeftNav, GetIsEditorReadOnly, GetUserHasAccessToEditor, SetCloseOnDone, SetDeleteOnCancel, SetEditorType, SetEnableApplyButton, SetHideLeftNav, SetPageStatus, SetUserHasAccessToEditor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STR_MVC_CLASS_NAME

public static final java.lang.String STR_MVC_CLASS_NAME
object name

See Also:
Constant Field Values

m_numProfileSectionsTable

protected XPHashtable m_numProfileSectionsTable
Web Service ID for User Profile Portlets.


m_htPropValueTable

protected XPHashtable m_htPropValueTable

m_htPropTypeTable

protected XPHashtable m_htPropTypeTable

m_numProfilePages

protected int m_numProfilePages

m_currProfilePage

protected int m_currProfilePage

m_htPageToPortletMapping

protected XPHashtable m_htPageToPortletMapping

m_alProfilePages

protected XPArrayList m_alProfilePages
Constructor Detail

UserProfileModel

public UserProfileModel()
Method Detail

CheckEditorAccessAndStart

public boolean CheckEditorAccessAndStart(XPHashtable _htFormData)
Code executed when the Editor is starting. Get all of the property information for the user

Specified by:
CheckEditorAccessAndStart in class EditorModel
Returns:
boolean Is true if the current user has the rights to access this Editor.

GetProfilePages

public XPArrayList GetProfilePages()
Returns an XPHashtable, with portlet ID as the key, profile page ID as the value.

Returns:

LookupPortlet

public IPTGadget LookupPortlet(IPTProfilePage _ptProfilePage)

Init

public void Init(AActivitySpace aspace)
Description copied from class: EditorModel
Inits the Model with the Activity Space.

Specified by:
Init in interface IModel
Overrides:
Init in class EditorModel
Parameters:
aspace -

DoTaskOnChangePage

public void DoTaskOnChangePage(java.lang.String _sNewSpaceName,
                               java.lang.String _sNewPageName)
Description copied from class: EditorModel
This method can be implemented by classes extending this one. It will be executed each time the user changes page on the left navigation menu.

Overrides:
DoTaskOnChangePage in class EditorModel
Parameters:
_sNewSpaceName -
_sNewPageName -

SetCurrentProfilePage

public void SetCurrentProfilePage(int index)
Parameters:
index -

GetUserValues

public XPHashtable GetUserValues()
Returns:

GetObjectPropData

protected IASQueryResult GetObjectPropData(IPTObjectProperties _ptObjProp)
Return object property non-reference data

Parameters:
_ptObjProp - IPTObjectProperties
Returns:
Data in query result
Throws:
XPException

GetObjectPropRefData

protected IASQueryResult GetObjectPropRefData(IPTObjectProperties _ptObjProp)
Return object property reference data

Parameters:
_ptObjProp - IPTObjectProperties
Returns:
Data in query result
Throws:
XPException

PutUserPropertiesIntoHashtable

protected XPHashtable PutUserPropertiesIntoHashtable()
Parameters:
ptSession -
profileUserID -
Returns:

Create

public java.lang.Object Create()
Description copied from class: EditorModel
This method is used by the ASManager to return new instances of managed objects.

Specified by:
Create in interface IManagedObject
Specified by:
Create in class EditorModel
Returns:
A new instance of the managed class (i.e. return new Foo();)
See Also:
IManagedObject.Create()

Finish

public void Finish()
Code executed in finish. Loop through the current properties and store them in the Plumtree Database

Specified by:
Finish in interface IRepostModel
Specified by:
Finish in class EditorModel

GetName

public java.lang.String GetName()
Returns the Class name.

Specified by:
GetName in interface IMVCObject
Specified by:
GetName in class EditorModel
Returns:
String

SavePage

public int SavePage(java.lang.String _sPageName,
                    XPHashtable _htFormData)
Calls the right save function according to the page name passed in argument.

Specified by:
SavePage in interface IRepostModel
Specified by:
SavePage in class EditorModel
Parameters:
_sPageName -
_htFormData -
Returns:
int Page status for server side validation

GetNumProfilePages

public int GetNumProfilePages()
Returns:

SetNumProfileSectionsTable

public void SetNumProfileSectionsTable(int profilePageNum,
                                       int numProfileSections)
Parameters:
sectionNum -
numCategories -

GetNumProfileSections

public int GetNumProfileSections(int _profilePageIndex)
Parameters:
_sectionIndex -
Returns:

GetRedirectAfterFinish

public Redirect GetRedirectAfterFinish()
DCA - The 508 has a different logic than standard.

Specified by:
GetRedirectAfterFinish in interface IRepostModel
Overrides:
GetRedirectAfterFinish in class EditorModel
Returns:
Redirect

GetNameFromObjectID

public java.lang.String GetNameFromObjectID(int nClassID,
                                            int nObjectID)
Returns the name for an object

Parameters:
nClassID - Class ID of object
nObjectID - Object ID of object
Returns:
Name of object.



Copyright © 2002,2003,2004,2005 Plumtree Software, Inc., All Rights Reserved.