Package org.opends.server.backends.task
Class Task.WorkCounters
- java.lang.Object
-
- org.opends.server.backends.task.Task.WorkCounters
-
-
Constructor Summary
Constructors Constructor Description WorkCounters()
Initializes work counters to a total of zero.WorkCounters(long totalCount)
Initializes work counters to the provided total.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
completed(long deltaDone)
Updates the number of elements done by adding the provided delta.long
getDoneCount()
Returns the number of entries that have been processed so far.long
getTodoCount()
Returns the number of entries that remain to be processed.long
getTotalCount()
Returns the total number of elements to process.void
setTotalCount(long totalCount)
Sets the total count, and resets the number of elements done to 0.String
toString()
-
-
-
Method Detail
-
setTotalCount
public void setTotalCount(long totalCount)
Sets the total count, and resets the number of elements done to 0.- Parameters:
totalCount
- the total count
-
completed
public void completed(long deltaDone)
Updates the number of elements done by adding the provided delta.- Parameters:
deltaDone
- the additional number of elements done.
-
getTotalCount
public long getTotalCount()
Returns the total number of elements to process.- Returns:
- the total number of elements to process
-
getTodoCount
public long getTodoCount()
Returns the number of entries that remain to be processed.- Returns:
- the number of entries that remain to be processed
-
getDoneCount
public long getDoneCount()
Returns the number of entries that have been processed so far.- Returns:
- the number of entries that have been processed so far
-
-