com.sap.portal.admin.editor
Interface IDataHandler
- All Known Implementing Classes:
- PCMDataHandler
- public interface IDataHandler
IDataHandler
API for load and save the data
That this editor is dealing.
|
Method Summary |
void |
loadData(IEditorContext ctx,
com.sap.security.api.IPrincipal principal,
com.sapportals.common.PPLogger logger)
The data should be loaded and stored in the editor context
Using the API: public void setProperty(String key,Object value);
Tip: The keys of the stored data can be the same keys
as the UI components value path. |
void |
saveData(IEditorContext ctx,
com.sap.security.api.IPrincipal principal,
com.sapportals.common.PPLogger logger)
Save the edited data of this editor |
loadData
public void loadData(IEditorContext ctx,
com.sap.security.api.IPrincipal principal,
com.sapportals.common.PPLogger logger)
throws EditorDataException,
EditorResourceException
- The data should be loaded and stored in the editor context
Using the API: public void setProperty(String key,Object value);
Tip: The keys of the stored data can be the same keys
as the UI components value path. That will cause the UI to be initialized
without any special treatment!
For Example:
If there is input field with target value path: "pane1.input1", Then the loaded
data should be- setProperty("pane1.input1",data), and when the editor will be loaded,
The input field will have the data inside it.
- Parameters:
ctx - current editor context (must be used for save the loaded data)principal - The security principal that load the datalogger - Logger to send log messages- Throws:
EditorDataException - data could not be loaded or no permissions-
The editor framework presents an end user message,read only mode will be set,
but the editor UI will be presented.EditorResourceException - an error occured regarding the
resource that this editor deals with. This exception is a showstopper for the editor-
The editor framework will present the given end user message
instead of the regular editor UI.
saveData
public void saveData(IEditorContext ctx,
com.sap.security.api.IPrincipal principal,
com.sapportals.common.PPLogger logger)
throws EditorDataException,
EditorResourceException
- Save the edited data of this editor
- Parameters:
ctx - Current editor contextprincipal - The security principal that save the datalogger - Logger to send log messages
(can be used for any locking considerations during save)- Throws:
EditorDataException - data could not be saved or no permissions-
The editor framework presents an end user message,
but the editor UI will be presented.EditorResourceException - an error occured regarding the
resource that this editor deals with. This exception is a showstopper for the editor-
The editor framework will present the given end user message
instead of the regular editor UI.