\r\n

51Degrees Geo-Location Java  4.3Newer Version 4.4

Geo-location services for 51Degrees Pipeline

fiftyone.geolocation.web.examples.shared.EmbedTomcat Class Reference

Collaboration diagram for fiftyone.geolocation.web.examples.shared.EmbedTomcat:

[legend]

Static Public Member Functions

static Context  startTomcat (String servletName, String urlPattern, HttpServlet servlet, int port) throws LifecycleException, IOException
Utility to start Tomcat with the servlet supplied. More...
static void  stopTomcat ()
Utility to shut Tomcat down.
static void  runWebApp (String pathname, String workingDir, int port) throws LifecycleException
Utility to run a servlet in Tomcat at the server root address - wait and then shut down. More...
static void  runServlet (HttpServlet servlet, String workingDir, String urlPattern, int port) throws LifecycleException
Utility to run a webapp in Tomcat - wait and then shut down. More...

Static Public Attributes

static Tomcat  tomcat

Member Function Documentation

◆ runServlet()

static void fiftyone.geolocation.web.examples.shared.EmbedTomcat.runServlet ( HttpServlet   servlet,
String   workingDir,
String   urlPattern,
int   port  
) throws LifecycleException
static

Utility to run a webapp in Tomcat - wait and then shut down.

Parameters
servlet - a servlet
workingDir - where Tomcat should put its temp files etc
urlPattern - where servlet should be releative to server root
port - the port to listen on

◆ runWebApp()

static void fiftyone.geolocation.web.examples.shared.EmbedTomcat.runWebApp ( String   pathname,
String   workingDir,
int   port  
) throws LifecycleException
static

Utility to run a servlet in Tomcat at the server root address - wait and then shut down.

Parameters
pathname - path to the webapp folder from project root
workingDir - where Tomcat should put its temp files etc
port - the port to listen on

◆ startTomcat()

static Context fiftyone.geolocation.web.examples.shared.EmbedTomcat.startTomcat ( String   servletName,
String   urlPattern,
HttpServlet   servlet,
int   port  
) throws LifecycleException, IOException
static

Utility to start Tomcat with the servlet supplied.

Parameters
servletName - a name
urlPattern - a mapping for the addresses the servlet will respond to
servlet - an instantiated servlet
Returns
a server context