[New] added TimeVariable.clear()-method

Can be used to remove all currently existing TimedValues
This commit is contained in:
Robert von Burg 2014-10-04 23:58:03 +02:00
parent 8f50a159b1
commit b77f4b204f
2 changed files with 10 additions and 0 deletions

View File

@ -84,6 +84,11 @@ public interface ITimeVariable<T extends IValue> {
*/
void compact();
/**
* Clears all values on this time variable
*/
void clear();
/**
* @return a copy of this time variable
*/

View File

@ -118,6 +118,11 @@ public class TimeVariable<T extends IValue> implements ITimeVariable<T>, Seriali
}
}
@Override
public void clear() {
this.container.clear();
}
@Override
public ITimeVariable<T> getCopy() {
TimeVariable<T> clone = new TimeVariable<>();