|
|
|
|
@ -1,5 +1,7 @@
|
|
|
|
|
package seng302.Model;
|
|
|
|
|
|
|
|
|
|
import javafx.beans.property.DoubleProperty;
|
|
|
|
|
import javafx.beans.property.SimpleDoubleProperty;
|
|
|
|
|
import javafx.beans.property.SimpleStringProperty;
|
|
|
|
|
import javafx.beans.property.StringProperty;
|
|
|
|
|
|
|
|
|
|
@ -11,6 +13,7 @@ import java.util.ArrayList;
|
|
|
|
|
public class Boat {
|
|
|
|
|
private StringProperty name;
|
|
|
|
|
private double velocity;
|
|
|
|
|
private StringProperty velocityProp;
|
|
|
|
|
private String abbrev;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
@ -20,6 +23,7 @@ public class Boat {
|
|
|
|
|
*/
|
|
|
|
|
public Boat(String name, double velocity, String abbrev){
|
|
|
|
|
this.velocity = velocity;
|
|
|
|
|
this.velocityProp = new SimpleStringProperty(String.valueOf(velocity));
|
|
|
|
|
this.abbrev = abbrev;
|
|
|
|
|
this.name = new SimpleStringProperty(name);
|
|
|
|
|
}
|
|
|
|
|
@ -52,6 +56,10 @@ public class Boat {
|
|
|
|
|
return getName().getValue();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public StringProperty getVelocityProp() {
|
|
|
|
|
return velocityProp;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public String getAbbrev() { return abbrev; }
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|