public class ProgressObjectSink extends DFProgressObject implements javax.enterprise.deploy.spi.status.ProgressListener
Whenever this class receives a progress event from one of its sources (one of the deploymentFacility actions) it forwards that event on to the sink's listeners, changing the state of the event to "running." Then, after the sink receives the completion or failure event from the last source, it forwards that event as running (as it had all earlier events) and then sends one final aggregate completion or failure event.
The sink always follows this pattern, even if it encapsulates only a single source. JSR88 clients should be aware of this behavior.
Constructor and Description |
---|
ProgressObjectSink() |
Modifier and Type | Method and Description |
---|---|
void |
addProgressListener(javax.enterprise.deploy.spi.status.ProgressListener progressListener)
Register a new ProgressListener
|
void |
cancel() |
javax.enterprise.deploy.spi.status.ClientConfiguration |
getClientConfiguration(javax.enterprise.deploy.spi.TargetModuleID targetModuleID) |
DFDeploymentStatus |
getCompletedStatus()
Report completed status for deploytool.
|
javax.enterprise.deploy.spi.status.DeploymentStatus |
getDeploymentStatus() |
javax.enterprise.deploy.spi.TargetModuleID[] |
getResultTargetModuleIDs() |
void |
handleProgressEvent(javax.enterprise.deploy.spi.status.ProgressEvent progressEvent)
receives notification of a progress event from one of our
registered interface.
|
boolean |
isCancelSupported() |
boolean |
isStopSupported() |
void |
removeProgressListener(javax.enterprise.deploy.spi.status.ProgressListener progressListener)
removes a ProgressListener from our list of listeners
|
void |
sinkProgressObject(javax.enterprise.deploy.spi.status.ProgressObject source)
register to a new ProgressObject for ProgressEvent notifications
|
void |
stop() |
waitFor
public void sinkProgressObject(javax.enterprise.deploy.spi.status.ProgressObject source)
public void handleProgressEvent(javax.enterprise.deploy.spi.status.ProgressEvent progressEvent)
handleProgressEvent
in interface javax.enterprise.deploy.spi.status.ProgressListener
public void addProgressListener(javax.enterprise.deploy.spi.status.ProgressListener progressListener)
addProgressListener
in interface javax.enterprise.deploy.spi.status.ProgressObject
the
- new listener instancepublic void removeProgressListener(javax.enterprise.deploy.spi.status.ProgressListener progressListener)
removeProgressListener
in interface javax.enterprise.deploy.spi.status.ProgressObject
the
- ProgressListener to removepublic javax.enterprise.deploy.spi.status.ClientConfiguration getClientConfiguration(javax.enterprise.deploy.spi.TargetModuleID targetModuleID)
getClientConfiguration
in interface javax.enterprise.deploy.spi.status.ProgressObject
public javax.enterprise.deploy.spi.status.DeploymentStatus getDeploymentStatus()
getDeploymentStatus
in interface javax.enterprise.deploy.spi.status.ProgressObject
public javax.enterprise.deploy.spi.TargetModuleID[] getResultTargetModuleIDs()
getResultTargetModuleIDs
in interface javax.enterprise.deploy.spi.status.ProgressObject
public boolean isCancelSupported()
isCancelSupported
in interface javax.enterprise.deploy.spi.status.ProgressObject
public boolean isStopSupported()
isStopSupported
in interface javax.enterprise.deploy.spi.status.ProgressObject
public void cancel() throws javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException
cancel
in interface javax.enterprise.deploy.spi.status.ProgressObject
javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException
public void stop() throws javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException
stop
in interface javax.enterprise.deploy.spi.status.ProgressObject
javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException
public DFDeploymentStatus getCompletedStatus()
getCompletedStatus
in class DFProgressObject
Copyright © 2021. All rights reserved.