Package org.apache.wiki.xmlrpc
Class RPCServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.apache.wiki.xmlrpc.RPCServlet
- All Implemented Interfaces:
java.io.Serializable
,javax.servlet.Servlet
,javax.servlet.ServletConfig
public class RPCServlet extends javax.servlet.http.HttpServlet
Handles all incoming servlet requests for XML-RPC calls.
Uses two initialization parameters:
- handler : the class which is used to handle the RPC calls.
- prefix : The command prefix for that particular handler.
- Since:
- 1.6.6
- See Also:
- Serialized Form
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
XMLRPC_PREFIX
This is what is appended to each command, if the handler has not been specified. -
Constructor Summary
Constructors Constructor Description RPCServlet()
-
Method Summary
Modifier and Type Method Description void
doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
Handles HTTP GET.void
doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
Handle HTTP POST.void
init(javax.servlet.ServletConfig config)
Initializes the servlet.void
initHandler(java.lang.String prefix, java.lang.String handlerName)
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
XMLRPC_PREFIX
This is what is appended to each command, if the handler has not been specified.- See Also:
- Constant Field Values
-
-
Constructor Details
-
RPCServlet
public RPCServlet()
-
-
Method Details
-
initHandler
public void initHandler(java.lang.String prefix, java.lang.String handlerName) throws java.lang.ClassNotFoundException- Throws:
java.lang.ClassNotFoundException
-
init
Initializes the servlet.- Specified by:
init
in interfacejavax.servlet.Servlet
- Overrides:
init
in classjavax.servlet.GenericServlet
- Throws:
javax.servlet.ServletException
-
doPost
public void doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletExceptionHandle HTTP POST. This is an XML-RPC call, and we'll just forward the query to an XmlRpcServer.- Overrides:
doPost
in classjavax.servlet.http.HttpServlet
- Throws:
javax.servlet.ServletException
-
doGet
public void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletExceptionHandles HTTP GET. However, we do not respond to GET requests, other than to show an explanatory text.- Overrides:
doGet
in classjavax.servlet.http.HttpServlet
- Throws:
javax.servlet.ServletException
-