com.plumtree.portalpages.admin.editors.lockbox
Class LockboxEditorModel

java.lang.Object
  extended by com.plumtree.uiinfrastructure.editor.EditorModel
      extended by com.plumtree.portaluiinfrastructure.editor.ObjEditorModel
          extended by com.plumtree.portalpages.admin.editors.lockbox.LockboxEditorModel
All Implemented Interfaces:
ILockboxEditorModelRO, IDescriptionModelRO, IMigrationModelRO, IObjEditorModelRO, IManagedObject, IModel, IModelRO, IMVCObject, IEditorModelRO, IRepostModel

public class LockboxEditorModel
extends ObjEditorModel
implements ILockboxEditorModelRO

Author:
jennifersu

Field Summary
protected  boolean m_bNewLockbox
           
protected  int m_nPasswordPropID
           
protected  int m_nRow
           
protected  int m_nUsernamePropID
           
protected  java.lang.String m_strPasswordPropName
           
protected  java.lang.String m_strUsernamePropName
           
static java.lang.String STR_MVC_CLASS_NAME
           
 
Fields inherited from class com.plumtree.portaluiinfrastructure.editor.ObjEditorModel
EDITOR_CLASSID_UNKNOWN, EDITOR_FOLDERID_UNKNOWN, EDITOR_OBJECTID_UNKNOWN, EDITOR_QS_BOL_QS_FORCESAVEINFOLDER, EDITOR_QS_INT_CLASS_ID, EDITOR_QS_INT_QS_FOLDER_ID, EDITOR_QS_INT_QS_OBJECT_ID, m_bDisableDescription, m_bDisableSecurity, m_bForceSavedInSuppliedFolder, m_bIsSysAdmin, m_nClassID, m_nFolderID, m_nFolderType, m_nObjectID, m_ptObject, m_Session, m_sFolderName, OBJECT_NAME_TRUNCATE
 
Fields inherited from class com.plumtree.uiinfrastructure.editor.EditorModel
m_asOwner, m_bCloseOnDone, m_bDeleteOnCancel, m_bEnableApplyButton, m_bHideLeftNav, m_bIsEditorReadOnly, m_bUserHasAccessToEditor, m_nEditorType
 
Constructor Summary
LockboxEditorModel()
           
 
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 DoTaskBeforeStore()
          Adding a new Lockbox object requires a number of steps under the covers: 1.
 void DoTaskOnComeBackFromSubEditor()
          This method will be called when you come back to the main Editor from a sub Editor.
 void DoTaskOnStartEditor(XPHashtable _htFormData)
          That method contains the code that should be executed just after the object has been initialized when the new editor is started.
 void Finish()
          That method is called by the EditorFinishControl.
 ASURL GetEditPropertyURL(int _nPropertyID)
          Returns the URL to edit the object.
 java.lang.String GetName()
          Returns the Class name.
 int GetPasswordPropID()
          Get property object ID of the lockbox's password property.
 java.lang.String GetPasswordPropName()
          Get property object name of the lockbox's password property.
 int GetRow()
          Get Row index of Lockbox in the main Lockbox list of Credential Vault Manager.
 int GetUsernamePropID()
          Get property object ID of the lockbox's username property.
 java.lang.String GetUsernamePropName()
          Get property object name of the lockbox's username property.
 boolean IsNewLockbox()
          Returns true if the lockbox was just created.
 void ResetInputs()
           
 int SavePage(java.lang.String _sPageName, XPHashtable _htFormData)
          Calls the right save function according to the page name passed in argument.
 
Methods inherited from class com.plumtree.portaluiinfrastructure.editor.ObjEditorModel
CheckEditorAccess, CheckFolderType, DisableSecurity, ForceSaveInFolder, GetClassID, GetFolderID, GetFolderName, GetIsSysAdmin, GetMigrationStatus, GetObject, GetObjectDescription, GetObjectID, GetObjectName, GetParentFolderPath, GetPTSession, Init, InitIsSysAdminFlag, InitPTObject, IsDescriptionDisabled, IsMigrationApproved, SaveMigrationStatus, SetDisableDescription, SetEditorToReadOnly, SetMemberVariablesFromQS, SetMigrationStatus, StartKeywords, StartLocNamesList, StartMigrationHistory, StartObjectProp, StartSecurityList, StoreObject
 
Methods inherited from class com.plumtree.uiinfrastructure.editor.EditorModel
Cancel, CleanupAllData, CleanupTempData, DoTaskAfterStore, DoTaskOnChangePage, GetCloseOnDone, GetCurrentRepostAction, GetDeleteOnCancel, GetEditorType, GetEnableApplyButton, GetHideLeftNav, GetIsEditorReadOnly, GetRedirectAfterFinish, 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
 
Methods inherited from interface com.plumtree.uiinfrastructure.editor.IEditorModelRO
GetEditorType, GetEnableApplyButton, GetHideLeftNav, GetIsEditorReadOnly
 

Field Detail

STR_MVC_CLASS_NAME

public static final java.lang.String STR_MVC_CLASS_NAME
See Also:
Constant Field Values

m_bNewLockbox

protected boolean m_bNewLockbox

m_nRow

protected int m_nRow

m_nUsernamePropID

protected int m_nUsernamePropID

m_nPasswordPropID

protected int m_nPasswordPropID

m_strUsernamePropName

protected java.lang.String m_strUsernamePropName

m_strPasswordPropName

protected java.lang.String m_strPasswordPropName
Constructor Detail

LockboxEditorModel

public LockboxEditorModel()
Method Detail

CheckEditorAccessAndStart

public boolean CheckEditorAccessAndStart(XPHashtable _htFormData)
Code executed when the Editor is starting.

Overrides:
CheckEditorAccessAndStart in class ObjEditorModel
Returns:
boolean Is true if the current user has the rights to access this Editor.

DoTaskOnStartEditor

public void DoTaskOnStartEditor(XPHashtable _htFormData)
Description copied from class: EditorModel
That method contains the code that should be executed just after the object has been initialized when the new editor is started.

Overrides:
DoTaskOnStartEditor in class EditorModel

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()

IsNewLockbox

public boolean IsNewLockbox()
Description copied from interface: ILockboxEditorModelRO
Returns true if the lockbox was just created.

Specified by:
IsNewLockbox in interface ILockboxEditorModelRO
Returns:

GetRow

public int GetRow()
Description copied from interface: ILockboxEditorModelRO
Get Row index of Lockbox in the main Lockbox list of Credential Vault Manager.

Specified by:
GetRow in interface ILockboxEditorModelRO
Returns:

ResetInputs

public void ResetInputs()

GetName

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

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

DoTaskBeforeStore

public void DoTaskBeforeStore()
Adding a new Lockbox object requires a number of steps under the covers: 1. Create a new Profile Section object. 2. Create two new Property objects (user name and password). 3. Add these Properties to the Profile Section object. 4. Map these Properties to the User object in the Global Object Properties map. 5. Add these Properties to the User Info Property Map.

Overrides:
DoTaskBeforeStore in class EditorModel

Finish

public void Finish()
That method is called by the EditorFinishControl. It takes care of storing the IPTObject in the DB when the user finishes the Editor.

Specified by:
Finish in interface IRepostModel
Overrides:
Finish in class ObjEditorModel
Throws:
XPException

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
Overrides:
SavePage in class ObjEditorModel
Parameters:
_sPageName -
_htFormData -
Returns:
int Page status for server side validation

GetUsernamePropID

public int GetUsernamePropID()
Description copied from interface: ILockboxEditorModelRO
Get property object ID of the lockbox's username property.

Specified by:
GetUsernamePropID in interface ILockboxEditorModelRO
Returns:

GetPasswordPropID

public int GetPasswordPropID()
Description copied from interface: ILockboxEditorModelRO
Get property object ID of the lockbox's password property.

Specified by:
GetPasswordPropID in interface ILockboxEditorModelRO
Returns:

GetUsernamePropName

public java.lang.String GetUsernamePropName()
Description copied from interface: ILockboxEditorModelRO
Get property object name of the lockbox's username property.

Specified by:
GetUsernamePropName in interface ILockboxEditorModelRO
Returns:

GetPasswordPropName

public java.lang.String GetPasswordPropName()
Description copied from interface: ILockboxEditorModelRO
Get property object name of the lockbox's password property.

Specified by:
GetPasswordPropName in interface ILockboxEditorModelRO
Returns:

GetEditPropertyURL

public ASURL GetEditPropertyURL(int _nPropertyID)
Returns the URL to edit the object.

Specified by:
GetEditPropertyURL in interface ILockboxEditorModelRO
Parameters:
_nClassID -
_nObjectID -
_sEditorASName -
Returns:
ASURL URL to the Editor

DoTaskOnComeBackFromSubEditor

public void DoTaskOnComeBackFromSubEditor()
This method will be called when you come back to the main Editor from a sub Editor.

Overrides:
DoTaskOnComeBackFromSubEditor in class ObjEditorModel



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