org.sakaiproject.tool.sample
Class BrowserTool

java.lang.Object
  extended byjavax.servlet.GenericServlet
      extended byjavax.servlet.http.HttpServlet
          extended byorg.sakaiproject.tool.sample.BrowserTool
All Implemented Interfaces:
Serializable, Servlet, ServletConfig

public class BrowserTool
extends HttpServlet

Sakai browser sample tool.

Version:
$Revision: 632 $
Author:
University of Michigan, Sakai Software Development Team
See Also:
Serialized Form

Nested Class Summary
 class BrowserTool.BrowserItem
           
 
Field Summary
protected  Map m_items
           
protected static String OPTIONS_HELPER
          Helper tool for options.
 
Constructor Summary
BrowserTool()
           
 
Method Summary
 void destroy()
          Shutdown the servlet.
protected  void doGet(HttpServletRequest req, HttpServletResponse res)
          Respond to requests.
protected  void doPost(HttpServletRequest req, HttpServletResponse res)
          Respond to data posting requests.
protected  BrowserTool.BrowserItem getItem(String id)
           
protected  Collection getItems()
           
 String getServletInfo()
          Access the Servlet's information display.
 void init(ServletConfig config)
          Initialize the servlet.
protected  void sendEdit(PrintWriter out, HttpServletRequest req, HttpServletResponse res, String id)
           
protected  void sendList(PrintWriter out, HttpServletRequest req, HttpServletResponse res)
           
protected  void sendView(PrintWriter out, HttpServletRequest req, HttpServletResponse res, String id)
           
protected  void showSession(PrintWriter out, boolean html, String context)
           
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
 
Methods inherited from class javax.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OPTIONS_HELPER

protected static final String OPTIONS_HELPER
Helper tool for options.

See Also:
Constant Field Values

m_items

protected Map m_items
Constructor Detail

BrowserTool

public BrowserTool()
Method Detail

getServletInfo

public String getServletInfo()
Access the Servlet's information display.

Returns:
servlet information.

init

public void init(ServletConfig config)
          throws ServletException
Initialize the servlet.

Parameters:
config - The servlet config.
Throws:
ServletException

destroy

public void destroy()
Shutdown the servlet.


doGet

protected void doGet(HttpServletRequest req,
                     HttpServletResponse res)
              throws ServletException,
                     IOException
Respond to requests.

Parameters:
req - The servlet request.
res - The servlet response.
Throws:
ServletException.
IOException.
ServletException
IOException

doPost

protected void doPost(HttpServletRequest req,
                      HttpServletResponse res)
               throws ServletException,
                      IOException
Respond to data posting requests.

Parameters:
req - The servlet request.
res - The servlet response.
Throws:
ServletException.
IOException.
ServletException
IOException

sendList

protected void sendList(PrintWriter out,
                        HttpServletRequest req,
                        HttpServletResponse res)

sendView

protected void sendView(PrintWriter out,
                        HttpServletRequest req,
                        HttpServletResponse res,
                        String id)

sendEdit

protected void sendEdit(PrintWriter out,
                        HttpServletRequest req,
                        HttpServletResponse res,
                        String id)

getItems

protected Collection getItems()

getItem

protected BrowserTool.BrowserItem getItem(String id)

showSession

protected void showSession(PrintWriter out,
                           boolean html,
                           String context)