Skip to content
Snippets Groups Projects
Commit f42d157e authored by Christian Wulf's avatar Christian Wulf
Browse files

fixed Counter

parent 1df08c1d
Branches
Tags
No related merge requests found
#FindBugs User Preferences
#Wed May 13 15:54:28 CEST 2015
#Fri Jun 12 08:15:02 CEST 2015
detector_threshold=2
effort=max
excludefilter0=.fbExcludeFilterFile|true
......
......@@ -31,8 +31,10 @@ public final class Counter<T> extends AbstractConsumerStage<T> {
outputPort.send(element);
}
// BETTER find a solution w/o any thread-safe code in this stage
public synchronized int getNumElementsPassed() {
/**
* <i>Hint:</i> This method may not be invoked by another thread since it is not thread-safe.
*/
public int getNumElementsPassed() {
return this.numElementsPassed;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment