|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.servlet.GenericServlet
org.apache.bsf.utils.http.HttpScriptServlet
public class HttpScriptServlet
HttpScriptServlet contains method which allows execution of scripts written in one or more languages. It uses a ScriptEngine supplied by calling its getEngine method to execute a script in a HttpScriptContext supplied by calling its getContext method.
| Constructor Summary | |
|---|---|
HttpScriptServlet()
|
|
| Method Summary | |
|---|---|
HttpScriptContext |
getContext(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
Retrieves a HttpScriptContext initialized using specified HttpServletRequest, HttpServletResponse and a reference to this HttpScriptServlet. |
ScriptEngine |
getEngine(javax.servlet.http.HttpServletRequest req)
Returns a ScriptEngine instance which is used by the HttpScriptServlet to executes a single request. |
void |
releaseEngine(ScriptEngine eng)
Called to indicate that the ScriptEngine returned by call to getEngine() is no longer in use. |
void |
service(javax.servlet.ServletRequest req,
javax.servlet.ServletResponse res)
Executes a script using the HttpScriptContext obtained by a call to getContext() and the ScriptEngine obtained by a call to getEngine(). |
| Methods inherited from class javax.servlet.GenericServlet |
|---|
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public HttpScriptServlet()
| Method Detail |
|---|
public HttpScriptContext getContext(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
throws javax.servlet.ServletException
req - the supplied HttpServletRequest instanceres - the supplied HttpServletResponse instance
javax.servlet.ServletException - if an error occurspublic ScriptEngine getEngine(javax.servlet.http.HttpServletRequest req)
req - the current request
public void releaseEngine(ScriptEngine eng)
eng - the ScriptEngine which is no longer in use
public void service(javax.servlet.ServletRequest req,
javax.servlet.ServletResponse res)
throws java.lang.IllegalArgumentException,
java.io.IOException,
javax.servlet.ServletException
service in interface javax.servlet.Servletservice in class javax.servlet.GenericServletreq - the current requestres - the current response
java.lang.IllegalArgumentException - if the req is not an
instance of HttpServletRequest or if the res is not an
instance of HttpServletResponse
java.io.IOException - if an input, output error occurs
javax.servlet.ServletException - if error occurs in processing the
request
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||