Groovy Documentation

org.gradle.api.plugins.jetty
Class AbstractJettyRunTask

java.lang.Object
  org.gradle.api.internal.AbstractTask
      org.gradle.api.DefaultTask
          org.gradle.api.internal.ConventionTask
              org.gradle.api.plugins.jetty.AbstractJettyRunTask

class AbstractJettyRunTask
extends ConventionTask

Field Summary
java.lang.String PORT_SYSPROPERTY

protected java.lang.Thread consoleScanner

A scanner to check ENTER hits on the console

protected java.lang.String reload

reload can be set to either 'automatic' or 'manual'

if 'manual' then the context can be reloaded by a linefeed in the console if 'automatic' then traditional reloading on changed files is enabled.

protected ArrayList scannerListeners

List of Listeners for the scanner

 
Constructor Summary
AbstractJettyRunTask(Project project, java.lang.String name)

 
Method Summary
void applyJettyXml()

void configureScanner()

void configureWebApplication()

Subclasses should invoke this to setup basic info on the webapp

JettyPluginServer createServer()

create a proxy that wraps a particular jetty version Server object

File findJettyWebXmlFile(File webInfDir)

Try and find a jetty-web.xml file, using some historical naming conventions if necessary.

void finishConfigurationBeforeStart()

java.lang.Iterable getAdditionalRuntimeJars()

Connector[] getConnectors()

java.lang.String getContextPath()

java.lang.Integer getHttpPort()

File getJettyConfig()

File getOverrideWebXml()

java.lang.String getReload()

RequestLog getRequestLog()

int getScanIntervalSeconds()

Scanner getScanner()

ArrayList getScannerListeners()

JettyPluginServer getServer()

java.lang.String getStopKey()

java.lang.Integer getStopPort()

File getTmpDirectory()

UserRealm[] getUserRealms()

JettyPluginWebAppContext getWebAppConfig()

File getWebDefaultXml()

boolean isDaemon()

void restartWebApp(boolean reconfigureScanner)

void setAdditionalRuntimeJars(java.lang.Iterable additionalRuntimeJars)

void setConnectors(Connector[] connectors)

void setContextPath(java.lang.String contextPath)

void setDaemon(boolean daemon)

void setHttpPort(java.lang.Integer httpPort)

void setJettyConfig(File jettyConfig)

void setOverrideWebXml(File overrideWebXml)

void setReload(java.lang.String reload)

void setRequestLog(RequestLog requestLog)

void setScanIntervalSeconds(int scanIntervalSeconds)

void setScannerListeners(ArrayList listeners)

void setServer(JettyPluginServer server)

void setStopKey(java.lang.String stopKey)

void setStopPort(java.lang.Integer stopPort)

void setTmpDirectory(File tmpDirectory)

void setUserRealms(UserRealm[] userRealms)

void setWebAppConfig(JettyPluginWebAppContext webAppConfig)

void setWebDefaultXml(File webDefaultXml)

protected void startConsoleScanner()

Run a thread that monitors the console input to detect ENTER hits.

void startJetty()

void startJettyInternal()

void validateConfiguration()

 
Methods inherited from class ConventionTask
conv, conventionMapping, conventionMapping, conventionProperty, getConventionAwareHelper, getConventionMapping, setConventionAwareHelper, setConventionMapping
 
Methods inherited from class DefaultTask
leftShift, methodMissing, propertyMissing
 
Methods inherited from class AbstractTask
captureStandardOutput, compareTo, defineProperty, deleteAllActions, dependsOn, dependsOnTaskDidWork, disableStandardOutputCapture, doFirst, doLast, equals, execute, getActions, getAdditionalProperties, getAnt, getConvention, getDependsOn, getDescription, getDidWork, getDynamicObjectHelper, getEnabled, getExecuted, getLogger, getName, getPath, getProject, getSkipProperties, getStandardOutputCapture, getTaskDependencies, hasProperty, hashCode, isDidWork, isEnabled, isExecuted, onlyIf, onlyIf, property, setActions, setAdditionalProperties, setDependsOn, setDescription, setDidWork, setEnabled, setExecuted, setName, setProject, setProperty, setSkipProperties, setStandardOutputCapture, toString
 
Methods inherited from class java.lang.Object
hashCode, getClass, equals, toString, wait, wait, wait, notify, notifyAll
 

Field Detail

PORT_SYSPROPERTY

java.lang.String PORT_SYSPROPERTY


consoleScanner

protected java.lang.Thread consoleScanner
A scanner to check ENTER hits on the console


reload

protected java.lang.String reload
reload can be set to either 'automatic' or 'manual'

if 'manual' then the context can be reloaded by a linefeed in the console if 'automatic' then traditional reloading on changed files is enabled.


scannerListeners

protected ArrayList scannerListeners
List of Listeners for the scanner


 
Constructor Detail

AbstractJettyRunTask

public AbstractJettyRunTask(Project project, java.lang.String name)


 
Method Detail

applyJettyXml

public void applyJettyXml()


configureScanner

public void configureScanner()


configureWebApplication

public void configureWebApplication()
Subclasses should invoke this to setup basic info on the webapp


createServer

public JettyPluginServer createServer()
create a proxy that wraps a particular jetty version Server object
return:
The Jetty Plugin Server


findJettyWebXmlFile

public File findJettyWebXmlFile(File webInfDir)
Try and find a jetty-web.xml file, using some historical naming conventions if necessary.
param:
webInfDir
return:
File object to the location of the jetty-web.xml


finishConfigurationBeforeStart

public void finishConfigurationBeforeStart()


getAdditionalRuntimeJars

public java.lang.Iterable getAdditionalRuntimeJars()


getConnectors

public Connector[] getConnectors()


getContextPath

public java.lang.String getContextPath()


getHttpPort

public java.lang.Integer getHttpPort()


getJettyConfig

public File getJettyConfig()


getOverrideWebXml

public File getOverrideWebXml()


getReload

public java.lang.String getReload()


getRequestLog

public RequestLog getRequestLog()


getScanIntervalSeconds

public int getScanIntervalSeconds()


getScanner

public Scanner getScanner()


getScannerListeners

public ArrayList getScannerListeners()


getServer

public JettyPluginServer getServer()


getStopKey

public java.lang.String getStopKey()


getStopPort

public java.lang.Integer getStopPort()


getTmpDirectory

public File getTmpDirectory()


getUserRealms

public UserRealm[] getUserRealms()


getWebAppConfig

public JettyPluginWebAppContext getWebAppConfig()


getWebDefaultXml

public File getWebDefaultXml()


isDaemon

public boolean isDaemon()


restartWebApp

public void restartWebApp(boolean reconfigureScanner)


setAdditionalRuntimeJars

public void setAdditionalRuntimeJars(java.lang.Iterable additionalRuntimeJars)


setConnectors

public void setConnectors(Connector[] connectors)


setContextPath

public void setContextPath(java.lang.String contextPath)


setDaemon

public void setDaemon(boolean daemon)


setHttpPort

public void setHttpPort(java.lang.Integer httpPort)


setJettyConfig

public void setJettyConfig(File jettyConfig)


setOverrideWebXml

public void setOverrideWebXml(File overrideWebXml)


setReload

public void setReload(java.lang.String reload)


setRequestLog

public void setRequestLog(RequestLog requestLog)


setScanIntervalSeconds

public void setScanIntervalSeconds(int scanIntervalSeconds)


setScannerListeners

public void setScannerListeners(ArrayList listeners)


setServer

public void setServer(JettyPluginServer server)


setStopKey

public void setStopKey(java.lang.String stopKey)


setStopPort

public void setStopPort(java.lang.Integer stopPort)


setTmpDirectory

public void setTmpDirectory(File tmpDirectory)


setUserRealms

public void setUserRealms(UserRealm[] userRealms)


setWebAppConfig

public void setWebAppConfig(JettyPluginWebAppContext webAppConfig)


setWebDefaultXml

public void setWebDefaultXml(File webDefaultXml)


startConsoleScanner

protected void startConsoleScanner()
Run a thread that monitors the console input to detect ENTER hits.


startJetty

public void startJetty()


startJettyInternal

public void startJettyInternal()


validateConfiguration

public void validateConfiguration()


 

Groovy Documentation