org.snapscript.common.command.CommandOperation Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of snap Show documentation
Show all versions of snap Show documentation
Dynamic scripting for the JVM
package org.snapscript.common.command;
import java.util.concurrent.Callable;
public class CommandOperation implements Callable {
private final Environment environment;
private final Command command;
public CommandOperation(Command command, Environment environment) {
this.environment = environment;
this.command = command;
}
@Override
public Console call() throws Exception {
return command.execute(environment);
}
}