T
- public abstract static class Flag.DoInSync<T> extends Object
Example:
flag.inSync(
new Flag.DoInSync<Integer>(flag) {
public abstract void execute(Integer flagValue) {
setFlag(flagValue+1);
}
}
);
Flag<Integer> flag = new Flag<Integer>(10);
No need to do anything else! The class will submit itself to the flag upon construction.
Use it to create correct counters (or use directly FlagInteger class).
Constructor and Description |
---|
Flag.DoInSync() |
protected boolean isImmutable()
protected void setFlag(T value)
protected T getFlag()
public abstract void execute(T flagValue)
flag
- Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.