2017-07-13 19:50:11 +02:00
|
|
|
package de.jotomo.ruffyscripter.commands;
|
|
|
|
|
2017-07-17 10:27:39 +02:00
|
|
|
import java.util.List;
|
|
|
|
|
2017-07-19 12:52:19 +02:00
|
|
|
import de.jotomo.ruffyscripter.PumpState;
|
2017-07-13 19:50:11 +02:00
|
|
|
import de.jotomo.ruffyscripter.RuffyScripter;
|
|
|
|
|
2017-07-26 15:50:07 +02:00
|
|
|
/**
|
|
|
|
* Interface for all commands to be executed by the pump.
|
|
|
|
*
|
|
|
|
* Note on cammond methods and timing: a method shall wait before and after executing
|
|
|
|
* as necessary to not cause timing issues, so the caller can just call methods in
|
|
|
|
* sequence, letting the methods take care of waits.
|
|
|
|
*/
|
2017-07-13 19:50:11 +02:00
|
|
|
public interface Command {
|
2017-08-23 12:10:50 +02:00
|
|
|
CommandResult execute(PumpState initialPumpState);
|
2017-07-17 10:27:39 +02:00
|
|
|
List<String> validateArguments();
|
2017-08-23 12:10:50 +02:00
|
|
|
void setScripter(RuffyScripter scripter);
|
2017-07-13 19:50:11 +02:00
|
|
|
}
|