Groovy Documentation

src.groovy.org.grails.tomcat
Class TomcatServer

java.lang.Object
  src.groovy.org.grails.tomcat.TomcatServer

class TomcatServer

Property Summary
protected def buildSettings

StandardContext context

def eventListener

def grailsConfig

protected java.lang.String keyPassword

protected java.lang.String keystore

protected java.io.File keystoreFile

org.apache.catalina.startup.Tomcat tomcat

 
Constructor Summary
TomcatServer(java.lang.String basedir, java.lang.String webXml, java.lang.String contextPath, java.lang.ClassLoader classLoader)

TomcatServer(java.lang.String warPath, java.lang.String contextPath)

 
Method Summary
protected def createSSLCertificate()

Creates the necessary SSL certificate for running in HTTPS mode

protected def initialize()

private def preStart()

void restart()

Typically combines the stop() and start() methods in order to restart the container

void start()

Starts the container on the default port

void start(int port)

Starts the container on the given port

void start(java.lang.String host, int port)

Starts the container on the given port

void startSecure()

Starts a secure container running over HTTPS

void startSecure(int port)

Starts a secure container running over HTTPS for the given port

void startSecure(java.lang.String host, int httpPort, int httpsPort)

Starts a secure container running over HTTPS for the given port and host.

void stop()

Stops the container

 
Methods inherited from class java.lang.Object
wait, wait, wait, hashCode, getClass, equals, toString, notify, notifyAll
 

Property Detail

buildSettings

protected def buildSettings


context

StandardContext context


eventListener

def eventListener


grailsConfig

def grailsConfig


keyPassword

protected java.lang.String keyPassword


keystore

protected java.lang.String keystore


keystoreFile

protected java.io.File keystoreFile


tomcat

org.apache.catalina.startup.Tomcat tomcat


 
Constructor Detail

TomcatServer

public TomcatServer(java.lang.String basedir, java.lang.String webXml, java.lang.String contextPath, java.lang.ClassLoader classLoader)


TomcatServer

public TomcatServer(java.lang.String warPath, java.lang.String contextPath)


 
Method Detail

createSSLCertificate

protected def createSSLCertificate()
Creates the necessary SSL certificate for running in HTTPS mode


initialize

protected def initialize()


preStart

private def preStart()


restart

void restart()
Typically combines the stop() and start() methods in order to restart the container


start

void start()
Starts the container on the default port


start

void start(int port)
Starts the container on the given port
param:
port The port number


start

void start(java.lang.String host, int port)
Starts the container on the given port
param:
host The host to start on
param:
port The port number


startSecure

void startSecure()
Starts a secure container running over HTTPS


startSecure

void startSecure(int port)
Starts a secure container running over HTTPS for the given port
param:
port The port


startSecure

void startSecure(java.lang.String host, int httpPort, int httpsPort)
Starts a secure container running over HTTPS for the given port and host.
param:
host The server host
param:
httpPort The port for HTTP traffic.
param:
httpsPort The port for HTTPS traffic.


stop

void stop()
Stops the container


 

Groovy Documentation