privatestaticfinallong serialVersionUID = 1L;
Controller ctrl;
Model model; public Value init() {
ctrl = new Controller();
model = ctrl.getModel(); returnnew VoidValue();
}
public Value sleep(){ try { Thread.sleep(750);
} catch (InterruptedException e) {
e.printStackTrace();
}
returnnew VoidValue();
}
public Value addVehicle(Value vecID) throws ValueException {
model.addVehicle(vecID.intValue(null)); returnnew VoidValue();
}
public Value connectVehicles(Value vecID, Value vecID2) throws ValueException {
public Value disconnectVehicles(Value vecID, Value vecID2) throws ValueException {
model.disconnectVehicles(vecID.intValue(null), vecID2.intValue(null)); returnnew VoidValue();
}
public Value updatePosition(Value vecID, Value x, Value y) throws ValueException {
model.updatePosition(vecID.intValue(null), (int) x.intValue(null), (int) y.intValue(null));
model.refresh(); returnnew VoidValue();
}
public Value updateDirection(Value vecID, Value dir) throws ValueException {
model.updateDirection(vecID.intValue(null), (int) dir.intValue(null)); returnnew VoidValue();
}
public Value receivedMessage(Value vecID) throws ValueException {
model.receivedMessage(vecID.intValue(null)); returnnew VoidValue();
}
}
Messung V0.5
¤ Dauer der Verarbeitung: 0.12 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.