Package org.apache.uima.util
Class ProgressImpl
java.lang.Object
org.apache.uima.util.ProgressImpl
- All Implemented Interfaces:
Serializable,Cloneable,Progress
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionProgressImpl(int aCompleted, int aTotal, String aUnit) ProgressImpl(int aCompleted, int aTotal, String aUnit, boolean aApproximate) -
Method Summary
Modifier and TypeMethodDescriptionclone()longThe amount completed, in terms of units specified byProgress.getUnit().longgetTotal()The total amount being processed, in terms of units specified byProgress.getUnit().getUnit()The unit type represented by theProgress.getCompleted()andProgress.getTotal()numbers.voidincrement(int aIncrement) booleanReturns true if the progress statistics are approximate, for example if the total number of entities in the collection is not known.voidsetCompleted(int aCompleted) voidsetTotal(int aTotal) toString()
-
Constructor Details
-
ProgressImpl
-
ProgressImpl
-
-
Method Details
-
getCompleted
public long getCompleted()Description copied from interface:ProgressThe amount completed, in terms of units specified byProgress.getUnit().- Specified by:
getCompletedin interfaceProgress- Returns:
- the amount completed
-
getTotal
public long getTotal()Description copied from interface:ProgressThe total amount being processed, in terms of units specified byProgress.getUnit(). For some processes, this information may not be available - in these cases, -1 will be returned. -
getUnit
Description copied from interface:ProgressThe unit type represented by theProgress.getCompleted()andProgress.getTotal()numbers. There are some predefined unit types (Progress.BYTES,Progress.ENTITIES), but any unit can be used. -
setCompleted
public void setCompleted(int aCompleted) -
setTotal
public void setTotal(int aTotal) -
isApproximate
public boolean isApproximate()Description copied from interface:ProgressReturns true if the progress statistics are approximate, for example if the total number of entities in the collection is not known.- Specified by:
isApproximatein interfaceProgress- Returns:
- true if the statistics are approximate, false if they are exact
-
increment
public void increment(int aIncrement) -
clone
- Overrides:
clonein classObject- Throws:
CloneNotSupportedException
-
toString
-