org.wso2.registry.jdbc.handlers
Class EditProcessor
java.lang.Object
org.wso2.registry.jdbc.handlers.EditProcessor
- Direct Known Subclasses:
- TextEditProcessor
public abstract class EditProcessor
- extends java.lang.Object
Base class for edit processors of custom UIs. Handlers that generate edit or new resource
UIs should have an associated EditProcessor implementation. Custom UIs generated by
UIEnabledHandlers may have various input controls to get user input for filling up the resource
content. EditProcessor implementations should extract these inputs from the request and build
the resource content. Once the resource content is built, it should store the resource in the
registry.
Field Summary |
protected static org.apache.commons.logging.Log |
log
|
Method Summary |
protected Registry |
getRegistry(javax.servlet.http.HttpServletRequest request)
|
abstract boolean |
processEditContent(java.lang.String path,
java.lang.String editViewKey,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Implementations of this method should extract input parameters from edit view and update the
resource content. |
abstract boolean |
processNewContent(java.lang.String parentPath,
java.lang.String newViewKey,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Implementations of this method should extract input parameters from new view and create a
new resource with that content. |
protected void |
redirect(java.lang.String url,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
log
protected static final org.apache.commons.logging.Log log
EditProcessor
public EditProcessor()
processEditContent
public abstract boolean processEditContent(java.lang.String path,
java.lang.String editViewKey,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws RegistryException
- Implementations of this method should extract input parameters from edit view and update the
resource content.
- Parameters:
path
- Path of the edited resource.editViewKey
- UI key of the edit UI.request
- HttpServletRequest recieved from the the CustomUIServletresponse
- HttpServletResponse to be sent the the CustomUIServlet
- Returns:
- true if response is sent within the EditProcessor implementation.
- Throws:
RegistryException
processNewContent
public abstract boolean processNewContent(java.lang.String parentPath,
java.lang.String newViewKey,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws RegistryException
- Implementations of this method should extract input parameters from new view and create a
new resource with that content.
- Parameters:
parentPath
- Path of the parent collection of new resource.newViewKey
- UI key of the new UI.request
- HttpServletRequest recieved from the the CustomUIServletresponse
- HttpServletResponse to be sent the the CustomUIServlet
- Returns:
- true if response is sent within the EditProcessor implementation.
- Throws:
RegistryException
getRegistry
protected Registry getRegistry(javax.servlet.http.HttpServletRequest request)
throws RegistryException
- Throws:
RegistryException
redirect
protected void redirect(java.lang.String url,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Copyright © 2007 Apache Web Services Project. All Rights Reserved.