public abstract class PluginService
extends java.lang.Object
Services are invoked from the JavaScript functions that are defined for the plug-in by using the
ecm.model.Request.invokePluginService function.
| Constructor and Description |
|---|
PluginService() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
execute(PluginServiceCallbacks callbacks,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Performs the action of this service.
|
abstract java.lang.String |
getId()
Returns the unique identifier for this service.
|
java.lang.String |
getOverriddenService()
Deprecated.
This method is not used. To override a service, use a request filter, returning the alternate JSON response.
|
boolean |
isSecureService(javax.servlet.http.HttpServletRequest request)
Check if secure service is enabled.
|
public abstract java.lang.String getId()
Important: This identifier is used in URLs so it must contain only alphanumeric characters.
String that is used to identify the service.public java.lang.String getOverriddenService()
null.public abstract void execute(PluginServiceCallbacks callbacks, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws java.lang.Exception
callbacks - An instance of the PluginServiceCallbacks class that contains several functions that can
be used by the service. These functions provide access to the plug-in configuration and content server
APIs.request - The HttpServletRequest object that provides the request. The service can access the
invocation parameters from the request.response - The HttpServletResponse object that is generated by the service. The service can get the
output stream and write the response. The response must be in JSON format.java.lang.Exception - For exceptions that occur when the service is running. If the logging level is high enough to log
errors, information about the exception is logged by IBM Content Navigator.public boolean isSecureService(javax.servlet.http.HttpServletRequest request)
request - The HttpServletRequest object that provides the request.