org.jcoderz.phoenix.servlet
Class PingServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
org.jcoderz.phoenix.servlet.PingServlet
- All Implemented Interfaces:
- Serializable, Servlet, ServletConfig
public final class PingServlet
- extends HttpServlet
This servlet sends a simple ping to the given host and returns a
1 pixel image with a color representing the host status.
- Author:
- Andreas Mandel
- See Also:
- Serialized Form
- web.servlet
- name="ping"
- web.servlet-mapping
- url-pattern="/ping/*"
| Methods inherited from class javax.servlet.GenericServlet |
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TIME_ZONE
public static final TimeZone TIME_ZONE
- Timezone used by the protocol.
DATE_TIME_FORMAT
public static final String DATE_TIME_FORMAT
- The format used to write date values.
- See Also:
- Constant Field Values
PingServlet
public PingServlet()
doPost
protected void doPost(HttpServletRequest req,
HttpServletResponse rsp)
throws IOException
- Overrides:
doPost in class HttpServlet
- Throws:
IOException
doGet
protected void doGet(HttpServletRequest req,
HttpServletResponse rsp)
throws IOException
- Overrides:
doGet in class HttpServlet
- Throws:
IOException
check
protected org.jcoderz.phoenix.servlet.PingServlet.PingResult check(String host)
ping
protected static long ping(String hostname)
ping
protected static long ping(InetAddress host)
Copyright 2007 The jCoderZ Project.