org.h2gis.h2spatialapi
Class EmptyProgressVisitor

java.lang.Object
  extended by org.h2gis.h2spatialapi.EmptyProgressVisitor
All Implemented Interfaces:
ProgressVisitor

public class EmptyProgressVisitor
extends Object
implements ProgressVisitor

A progress visitor that do nothing.

Author:
Nicolas Fortin

Field Summary
 
Fields inherited from interface org.h2gis.h2spatialapi.ProgressVisitor
PROPERTY_CANCELED
 
Constructor Summary
EmptyProgressVisitor()
           
 
Method Summary
 void addPropertyChangeListener(String property, PropertyChangeListener listener)
          Listen for this visitor properties
 void cancel()
          Call this method to cancel the operation
 void endOfProgress()
          Same thing as call ProgressVisitor.setStep(int) with step count.
 void endStep()
          Same as ProgressVisitor.setStep(int) with currentStep++
 double getProgression()
           
 int getStepCount()
           
 boolean isCanceled()
           
 void removePropertyChangeListener(PropertyChangeListener listener)
           
 void setStep(int idStep)
           
 ProgressVisitor subProcess(int stepCount)
          Create a sub process.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EmptyProgressVisitor

public EmptyProgressVisitor()
Method Detail

endOfProgress

public void endOfProgress()
Description copied from interface: ProgressVisitor
Same thing as call ProgressVisitor.setStep(int) with step count.

Specified by:
endOfProgress in interface ProgressVisitor

subProcess

public ProgressVisitor subProcess(int stepCount)
Description copied from interface: ProgressVisitor
Create a sub process. When this sub process finish it will count as a single step in this process.

Specified by:
subProcess in interface ProgressVisitor
Parameters:
stepCount - Number of step into the sub-process.
Returns:

endStep

public void endStep()
Description copied from interface: ProgressVisitor
Same as ProgressVisitor.setStep(int) with currentStep++

Specified by:
endStep in interface ProgressVisitor

setStep

public void setStep(int idStep)
Specified by:
setStep in interface ProgressVisitor
Parameters:
idStep - Set the current step, must be in [0-stepCount]

getStepCount

public int getStepCount()
Specified by:
getStepCount in interface ProgressVisitor
Returns:
The step count of this progress

getProgression

public double getProgression()
Specified by:
getProgression in interface ProgressVisitor
Returns:
This step progression [O-1], take account sub process progression.

isCanceled

public boolean isCanceled()
Specified by:
isCanceled in interface ProgressVisitor
Returns:
True if the process has been canceled

cancel

public void cancel()
Description copied from interface: ProgressVisitor
Call this method to cancel the operation

Specified by:
cancel in interface ProgressVisitor

addPropertyChangeListener

public void addPropertyChangeListener(String property,
                                      PropertyChangeListener listener)
Description copied from interface: ProgressVisitor
Listen for this visitor properties

Specified by:
addPropertyChangeListener in interface ProgressVisitor
Parameters:
property - Property name one of ProgressVisitor.PROPERTY_CANCELED
listener - Listener instance

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)
Specified by:
removePropertyChangeListener in interface ProgressVisitor
Parameters:
listener - Listener instance


Copyright © 2015 IRSTV CNRS-FR-2488. All Rights Reserved.