public class I2PSnarkServlet extends BasicServlet
BasicServlet.HttpContent| Modifier and Type | Field and Description |
|---|---|
static String |
PROP_CONFIG_FILE |
_context, _log, _resourceBase| Constructor and Description |
|---|
I2PSnarkServlet() |
| Modifier and Type | Method and Description |
|---|---|
void |
destroy() |
void |
doGet(HttpServletRequest request,
HttpServletResponse response)
Handle what we can here, calling super.doGet() for the rest.
|
void |
doPost(HttpServletRequest request,
HttpServletResponse response)
Handle what we can here, calling super.doPost() for the rest.
|
File |
getResource(String pathInContext)
We override this to set the file relative to the storage dirctory
for the torrent.
|
void |
init(ServletConfig cfg) |
(package private) String |
toIcon(String path)
Pick an icon; try to catch the common types in an i2p environment
Pkg private for FileTypeSorter.
|
(package private) static String |
urlify(String s)
This is for a full URL.
|
addMimeMapping, addPaths, decodePath, doDelete, doOptions, doTrace, encodePath, getContent, getMimeType, loadMimeMap, passConditionalHeaders, sendData, setResourceBase, setWarBase, writeHeadersdoHead, doPut, getLastModified, service, servicegetInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, logpublic static final String PROP_CONFIG_FILE
public void init(ServletConfig cfg) throws ServletException
init in interface Servletinit in class BasicServletServletExceptionpublic void destroy()
destroy in interface Servletdestroy in class GenericServletpublic File getResource(String pathInContext)
getResource in class BasicServletpathInContext - should always start with /public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
doGet in class BasicServletServletExceptionIOExceptionpublic void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
doPost in class BasicServletServletExceptionIOExceptionstatic String urlify(String s)