org.niggle.servlet
Class NiggleConfig

java.lang.Object
  |
  +--org.niggle.servlet.NiggleConfig
All Implemented Interfaces:
javax.servlet.ServletConfig

public class NiggleConfig
extends java.lang.Object
implements javax.servlet.ServletConfig

A custom implementation of the ServletConfig interface The default NiggleServlet initializations are delegated to this object.

Author:
Jonathan Revusky
See Also:
NiggleServlet.init(javax.servlet.ServletConfig)

Constructor Summary
NiggleConfig()
           
NiggleConfig(javax.servlet.ServletConfig nestedConfig, javax.servlet.Servlet servlet)
           
 
Method Summary
protected  void dispatchAction(ServletInteraction si)
          Dispatches the request based on the action
 java.lang.String getInitParameter(java.lang.String name)
           
 java.util.Enumeration getInitParameterNames()
           
protected  java.lang.reflect.Method getMethodFromAction(ServletInteraction si, java.lang.String action)
           
 PageFactory getPageFactory()
           
 javax.servlet.Servlet getServlet()
           
 java.lang.ClassLoader getServletClassLoader()
           
 javax.servlet.ServletContext getServletContext()
           
 java.lang.String getServletName()
           
 void init()
           
protected  void initBaseClasses()
           
protected  void initLogFile()
           
protected  void initPageFactory()
           
protected  void loadMetadata()
           
 ServletInteraction newServletInteraction(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          where the servlet gives us a transaction to process.
 void setInitParameter(java.lang.String key, java.lang.String value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NiggleConfig

public NiggleConfig()

NiggleConfig

public NiggleConfig(javax.servlet.ServletConfig nestedConfig,
                    javax.servlet.Servlet servlet)
             throws javax.servlet.ServletException
Method Detail

init

public void init()
          throws javax.servlet.ServletException
javax.servlet.ServletException

getInitParameterNames

public java.util.Enumeration getInitParameterNames()
Specified by:
getInitParameterNames in interface javax.servlet.ServletConfig

getInitParameter

public java.lang.String getInitParameter(java.lang.String name)
Specified by:
getInitParameter in interface javax.servlet.ServletConfig

getServletContext

public javax.servlet.ServletContext getServletContext()
Specified by:
getServletContext in interface javax.servlet.ServletConfig

setInitParameter

public void setInitParameter(java.lang.String key,
                             java.lang.String value)

getServletName

public java.lang.String getServletName()
Specified by:
getServletName in interface javax.servlet.ServletConfig

loadMetadata

protected void loadMetadata()
                     throws javax.servlet.ServletException
javax.servlet.ServletException

initPageFactory

protected void initPageFactory()
                        throws javax.servlet.ServletException
javax.servlet.ServletException

initLogFile

protected void initLogFile()
                    throws javax.servlet.ServletException
javax.servlet.ServletException

initBaseClasses

protected void initBaseClasses()
                        throws javax.servlet.ServletException
javax.servlet.ServletException

getPageFactory

public PageFactory getPageFactory()

newServletInteraction

public ServletInteraction newServletInteraction(javax.servlet.http.HttpServletRequest request,
                                                javax.servlet.http.HttpServletResponse response)
                                         throws java.io.IOException,
                                                javax.servlet.ServletException
where the servlet gives us a transaction to process.

Parameters:
request - the data about the user's request.
response - the HTML response.
Returns:
a ServletInteraction object to handle the work.
java.io.IOException
javax.servlet.ServletException

dispatchAction

protected void dispatchAction(ServletInteraction si)
                       throws java.io.IOException,
                              javax.servlet.ServletException
Dispatches the request based on the action

java.io.IOException
javax.servlet.ServletException

getMethodFromAction

protected java.lang.reflect.Method getMethodFromAction(ServletInteraction si,
                                                       java.lang.String action)
                                                throws java.lang.IllegalAccessException,
                                                       java.lang.NoSuchMethodException
java.lang.IllegalAccessException
java.lang.NoSuchMethodException

getServletClassLoader

public java.lang.ClassLoader getServletClassLoader()

getServlet

public javax.servlet.Servlet getServlet()