|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.cactus.container.ContainerRunner
public final class ContainerRunner
Support class that handles the lifecycle of a container, which basically consists of startup and shutdown.
| Constructor Summary | |
|---|---|
ContainerRunner(ContainerWrapper theContainerWrapper)
Constructor. |
|
| Method Summary | |
|---|---|
java.lang.String |
getServerName()
Returns the server name as reported in the 'Server' header of HTTP responses from the server. |
void |
setCheckInterval(long theCheckInterval)
Sets the time interval to sleep between polling the container. |
void |
setLogger(org.codehaus.cargo.util.log.Logger theLogger)
Sets the log to write to. |
void |
setShutDownWait(long theShutDownWait)
Sets the time to wait after the container has been shut down. |
void |
setTimeout(long theTimeout)
Sets the timeout after which to stop trying to call the container. |
void |
setURL(java.net.URL theTestURL)
Sets the HTTP/HTTPS URL that will be continuously pinged to check if the container is running. |
void |
shutDownContainer()
Method called by the task to perform the stopping of the container. |
void |
startUpContainer()
Method called by the task to perform the startup of the container. |
int |
testConnectivity(java.net.URL theUrl)
Tests whether we are able to connect to the HTTP server identified by the specified URL. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ContainerRunner(ContainerWrapper theContainerWrapper)
theContainerWrapper - The container to run| Method Detail |
|---|
public java.lang.String getServerName()
public void startUpContainer()
throws java.lang.IllegalStateException
java.lang.IllegalStateException - If the 'url' property is null
public void shutDownContainer()
throws java.lang.IllegalStateException
java.lang.IllegalStateException - If the 'url' property is nullpublic void setCheckInterval(long theCheckInterval)
theCheckInterval - The interval in millisecondspublic void setLogger(org.codehaus.cargo.util.log.Logger theLogger)
theLogger - The log to setpublic void setShutDownWait(long theShutDownWait)
theShutDownWait - The time to wait in millisecondspublic void setTimeout(long theTimeout)
theTimeout - The timeout in millisecondspublic void setURL(java.net.URL theTestURL)
theTestURL - The URL to setpublic int testConnectivity(java.net.URL theUrl)
theUrl - The URL to check
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||