com.raritantechnologies.searchApp.database
Class RunSQLHandler
java.lang.Object
com.raritantechnologies.searchApp.database.RunSQLHandler
- All Implemented Interfaces:
- IConfigurable, IServletHandler
- public class RunSQLHandler
- extends java.lang.Object
- implements IServletHandler
Implementation of IServletHandler that executes a query.
web.xml configuration:
<servlet>
<servlet-name>RunSQLServlet</servlet-name>
<servlet-class>com.raritantechnologies.quickstart.userInterface.SearchServlet
<init-param>
<param-name>ServletHandler</param-name>
<param-value>[ name of ServletHandler here ]</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>RunSQLServlet</servlet-name>
<url-pattern>doQuery</url-pattern>
</servlet-mapping>
XML Configuration Template:
<SystemObject type="ServletHandler" name="[ name of this ServletHandler - needs to match param-value in web.xml ]"
configurableClass="com.raritantechnologies.searchApp.database.RunSQLHandler"
databaseManagerName="[ name of database manager ]" >
<Template>
</Template>
</SystemObject>
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RunSQLHandler
public RunSQLHandler()
service
public void service(DynamicHttpServletRequest pReq,
HttpServletResponse pRes)
throws ServletException,
java.io.IOException
- Delegate the service request to the IServletHandler.
- Specified by:
service in interface IServletHandler
- Throws:
a - ServletException if the IServletHandler is not defined.
ServletException
java.io.IOException
init
public void init(SearchServlet searchServlet)
- Specified by:
init in interface IServletHandler
initialize
public void initialize(org.w3c.dom.Element elem)
- Description copied from interface:
IConfigurable
- Initializes the object from an XML tag or element.
This method is called by the Framework as part of the application initializtion.
see ConfigurationManager, XMLConfigurationManager, XMLSearchFieldMapFactory, XMLSearchSourceFactory.
Configurable objects that are owned or contained by other configurable objects will be initialized
in by the parent object.
- Specified by:
initialize in interface IConfigurable