|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.wso2.carbon.registry.core.jdbc.handlers.EditProcessor
public abstract class EditProcessor
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.
Constructor Summary | |
---|---|
EditProcessor()
|
Method Summary | |
---|---|
protected Registry |
getRegistry(javax.servlet.http.HttpServletRequest request)
Obtains an instance of the Registry that the user can work with. |
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)
Redirects the incoming request to the given URL. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EditProcessor()
Method Detail |
---|
public abstract boolean processEditContent(java.lang.String path, java.lang.String editViewKey, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws RegistryException
path
- Path of the edited resource.editViewKey
- UI key of the edit UI.request
- HttpServletRequest received from the the CustomUIServletresponse
- HttpServletResponse to be sent the the CustomUIServlet
RegistryException
- if an error occurs while processing content.public abstract boolean processNewContent(java.lang.String parentPath, java.lang.String newViewKey, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws RegistryException
parentPath
- Path of the parent collection of new resource.newViewKey
- UI key of the new UI.request
- HttpServletRequest received from the the CustomUIServletresponse
- HttpServletResponse to be sent the the CustomUIServlet
RegistryException
- if an error occurs while processing content.protected Registry getRegistry(javax.servlet.http.HttpServletRequest request) throws RegistryException
request
- the HTTP Servlet Request.
RegistryException
- if an error occurs.protected void redirect(java.lang.String url, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
url
- the target URL.request
- the HTTP Servlet Request.response
- the HTTP Servlet Response.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |