org.klomp.snark.web
public class I2PSnarkServlet extends Default
Modifier and Type | Field and Description |
---|---|
static String |
PROP_CONFIG_FILE |
Constructor and Description |
---|
I2PSnarkServlet() |
Modifier and Type | Method and Description |
---|---|
void |
destroy() |
protected Resource |
getResource(String pathInContext)
We override this instead of passing a resource base to super(), because
if a resource base is set, super.getResource() always uses that base,
and we can't get any resources (like icons) out of the .war
|
void |
handleGet(HttpServletRequest request,
HttpServletResponse response,
String pathInContext,
Resource resource,
boolean endsWithSlash)
Tell the browser to cache the icons
|
void |
init(ServletConfig cfg) |
void |
service(HttpServletRequest req,
HttpServletResponse resp)
Some parts modified from:
|
handleDelete, handleMove, handleOptions, handlePut, init, passConditionalHeaders, sendData, sendDirectory, writeHeaders
doDelete, doGet, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, log, log
public static final String PROP_CONFIG_FILE
public void init(ServletConfig cfg) throws ServletException
init
in interface Servlet
init
in class GenericServlet
ServletException
public void destroy()
destroy
in interface Servlet
destroy
in class GenericServlet
protected Resource getResource(String pathInContext) throws IOException
getResource
in class Default
IOException
public void handleGet(HttpServletRequest request, HttpServletResponse response, String pathInContext, Resource resource, boolean endsWithSlash) throws ServletException, IOException
handleGet
in class Default
ServletException
IOException
public void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
// ======================================================================== // $Id: Default.java,v 1.51 2006/10/08 14:13:18 gregwilkins Exp $ // Copyright 199-2004 Mort Bay Consulting Pty. Ltd. // ------------------------------------------------------------------------ // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // ========================================================================
service
in class Default
ServletException
IOException