Top Description Fields Constructors Methods
org.eclipse.collections.impl.block.procedure

public final Class CounterProcedure<T>

extends Object
implements Procedure<T>
Class Inheritance
All Implemented Interfaces
org.eclipse.collections.api.block.procedure.Procedure, java.io.Serializable, java.util.function.Consumer
Imports
org.eclipse.collections.api.block.procedure.Procedure

CounterProcedure wraps a specified procedure and keeps track of the number of times it is executed.

Field Summary

Modifier and TypeField and Description
private int
private final Procedure<T>
private static final long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public int
private void
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

public void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

countback to summary
private int count
procedureback to summary
private final Procedure<T> procedure
serialVersionUIDback to summary
private static final long serialVersionUID

Constructor Detail

CounterProcedureback to summary
public CounterProcedure(Procedure<T> procedure)

Method Detail

getCountback to summary
public int getCount()
incrementCounterback to summary
private void incrementCounter()
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override
valueback to summary
public void value(T object)

Implements org.eclipse.collections.api.block.procedure.Procedure.value.

Annotations
@Override