com.plumtree.portalpages.admin.editors.webservice.plugins
Class RemotePageletPickerPluginModel

java.lang.Object
  extended by com.plumtree.uiinfrastructure.editor.EditorHelperModel
      extended by com.plumtree.portalpages.admin.editors.webservice.plugins.RemotePageletPickerPluginModel
All Implemented Interfaces:
IWSSubModel, IManagedObject, IModel, IModelRO, IMVCObject

public class RemotePageletPickerPluginModel
extends EditorHelperModel
implements IWSSubModel

Author:
rozhang

Field Summary
static java.lang.String INPUTNAME_SELECTEDLIB
           
static java.lang.String INPUTNAME_SELECTEDPAGELET
           
protected  boolean m_ensembleServerValid
           
protected  XPHashtable m_libCollection
           
protected  java.lang.String[] m_libNames
           
protected  XPHashtable m_pageletData
           
protected  java.lang.String[] m_pageletParamDescriptions
           
protected  java.lang.String[] m_pageletParamNames
           
protected  EnsemblePageletRestData[] m_pagelets
           
protected  int m_selectedLibIndex
           
protected  java.lang.String m_selectedLibraryName
           
protected  java.lang.String m_selectedPageletDesc
           
protected  java.lang.String m_selectedPageletId
           
protected  java.lang.String m_selectedPageletName
           
protected  IPTWebService m_webService
           
static java.lang.String STR_MVC_CLASS_NAME
           
 
Fields inherited from class com.plumtree.uiinfrastructure.editor.EditorHelperModel
m_asOwner
 
Constructor Summary
RemotePageletPickerPluginModel()
           
 
Method Summary
protected  java.lang.String ClearSelectedPagelet()
           
 java.lang.Object Create()
          This method is used by the ASManager to return new instances of managed objects.
 void DoTaskBeforeWSStore()
          Store the library name and pagelet name in the webservice webservice property bag
 void DoTaskOnRemoteServerUpdate(java.lang.String strRemoteServerID, java.lang.String strRemoteServerName, java.lang.String strRemoteServerBaseURL)
          Called when the Remote Server is changed.
 void DoTaskOnWSModeUpdate(int nNewWSMode)
          Called when the Web Service type is changed.
 java.lang.String GetName()
          Returns the Class name.
 java.lang.String[] GetPageletLibraries()
           
 java.lang.String[] GetPageletParameterDescriptions()
           
 java.lang.String[] GetPageletParameterNames()
           
 EnsemblePageletRestData[] GetPagelets()
           
 XPArrayList GetPageletsInCurrentLibrary()
           
 int GetSelectedLibraryIndex()
           
 java.lang.String GetSelectedLibraryName()
           
 java.lang.String GetSelectedPageletDescription()
           
 java.lang.String GetSelectedPageletIndex()
           
 java.lang.String GetSelectedPageletName()
           
 java.lang.String GetValidationFunction()
          This returns the name of the client-side validation function that the model wants added to the page-level validation funtion.
 void HandleUIError(java.lang.String errorMessage)
           
 void InitWSModel(IPTWebService ptWebService)
          Loads stored data and retrieves list of pagelets from ensemble This method is called once editor is started
 void RefreshSelectedPageletLibraryName()
          Sets the name of the selected library
 int SaveSection(XPHashtable _htFormData)
          Save reposted page data to model Called on every page reload and before switching pages
 
Methods inherited from class com.plumtree.uiinfrastructure.editor.EditorHelperModel
CleanupAllData, CleanupTempData, Init
 
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
See Also:
Constant Field Values

INPUTNAME_SELECTEDLIB

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

INPUTNAME_SELECTEDPAGELET

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

m_webService

protected IPTWebService m_webService

m_ensembleServerValid

protected boolean m_ensembleServerValid

m_pagelets

protected EnsemblePageletRestData[] m_pagelets

m_libCollection

protected XPHashtable m_libCollection

m_pageletData

protected XPHashtable m_pageletData

m_libNames

protected java.lang.String[] m_libNames

m_pageletParamNames

protected java.lang.String[] m_pageletParamNames

m_pageletParamDescriptions

protected java.lang.String[] m_pageletParamDescriptions

m_selectedLibraryName

protected java.lang.String m_selectedLibraryName

m_selectedPageletName

protected java.lang.String m_selectedPageletName

m_selectedPageletDesc

protected java.lang.String m_selectedPageletDesc

m_selectedLibIndex

protected int m_selectedLibIndex

m_selectedPageletId

protected java.lang.String m_selectedPageletId
Constructor Detail

RemotePageletPickerPluginModel

public RemotePageletPickerPluginModel()
Method Detail

InitWSModel

public void InitWSModel(IPTWebService ptWebService)
Loads stored data and retrieves list of pagelets from ensemble This method is called once editor is started

Specified by:
InitWSModel in interface IWSSubModel
See Also:
com.plumtree.portalpages.admin.editors.webservice.IWSSubModel#InitWSModel(com.plumtree.server.IPTWebService)

SaveSection

public int SaveSection(XPHashtable _htFormData)
Save reposted page data to model Called on every page reload and before switching pages

Specified by:
SaveSection in class EditorHelperModel
Parameters:
_htFormData - Form posted data.
Returns:
int Status for server side validation
See Also:
com.plumtree.uiinfrastructure.editor.EditorHelperModel#SaveSection(com.plumtree.openfoundation.util.XPHashtable)

DoTaskBeforeWSStore

public void DoTaskBeforeWSStore()
Store the library name and pagelet name in the webservice webservice property bag

Specified by:
DoTaskBeforeWSStore in interface IWSSubModel
See Also:
IWSSubModel.DoTaskBeforeWSStore()

RefreshSelectedPageletLibraryName

public void RefreshSelectedPageletLibraryName()
Sets the name of the selected library


GetPagelets

public EnsemblePageletRestData[] GetPagelets()

GetPageletsInCurrentLibrary

public XPArrayList GetPageletsInCurrentLibrary()

GetSelectedLibraryName

public java.lang.String GetSelectedLibraryName()

GetSelectedLibraryIndex

public int GetSelectedLibraryIndex()

GetSelectedPageletIndex

public java.lang.String GetSelectedPageletIndex()

GetSelectedPageletName

public java.lang.String GetSelectedPageletName()

GetSelectedPageletDescription

public java.lang.String GetSelectedPageletDescription()

GetPageletParameterNames

public java.lang.String[] GetPageletParameterNames()

GetPageletParameterDescriptions

public java.lang.String[] GetPageletParameterDescriptions()

ClearSelectedPagelet

protected java.lang.String ClearSelectedPagelet()

GetPageletLibraries

public java.lang.String[] GetPageletLibraries()
Returns:

HandleUIError

public void HandleUIError(java.lang.String errorMessage)
Parameters:
errorMessage -

DoTaskOnRemoteServerUpdate

public void DoTaskOnRemoteServerUpdate(java.lang.String strRemoteServerID,
                                       java.lang.String strRemoteServerName,
                                       java.lang.String strRemoteServerBaseURL)
Description copied from interface: IWSSubModel
Called when the Remote Server is changed. This is mostly used to update the base-url displayed before URL edit boxes.

Specified by:
DoTaskOnRemoteServerUpdate in interface IWSSubModel
See Also:
IWSSubModel.DoTaskOnRemoteServerUpdate(java.lang.String, java.lang.String, java.lang.String)

DoTaskOnWSModeUpdate

public void DoTaskOnWSModeUpdate(int nNewWSMode)
Description copied from interface: IWSSubModel
Called when the Web Service type is changed.

Specified by:
DoTaskOnWSModeUpdate in interface IWSSubModel
See Also:
IWSSubModel.DoTaskOnWSModeUpdate(int)

GetValidationFunction

public java.lang.String GetValidationFunction()
Description copied from interface: IWSSubModel
This returns the name of the client-side validation function that the model wants added to the page-level validation funtion. Models return null or "" if they don't have a validation function.

Specified by:
GetValidationFunction in interface IWSSubModel
See Also:
IWSSubModel.GetValidationFunction()

Create

public java.lang.Object Create()
Description copied from class: EditorHelperModel
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 EditorHelperModel
Returns:
A new instance of the managed class (i.e. return new Foo();)
See Also:
EditorHelperModel.Create()

GetName

public java.lang.String GetName()
Description copied from class: EditorHelperModel
Returns the Class name.

Specified by:
GetName in interface IMVCObject
Specified by:
GetName in class EditorHelperModel
Returns:
String
See Also:
EditorHelperModel.GetName()



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