1 package SteeringProperties;
2
3 import XMLSteeringProperties.XMLForcePoint;
4
5
6
7
8
9 public class ForcePoint {
10
11
12 public int distance;
13
14
15 public int forceValue;
16
17
18 public boolean continues;
19
20 public ForcePoint(int distance, int forceValue, boolean continues) {
21 this.distance = distance;
22 this.forceValue = forceValue;
23 this.continues = continues;
24 }
25
26 public ForcePoint(XMLForcePoint xml) {
27 this.distance = xml.distance;
28 this.forceValue = xml.forceValue;
29 this.continues = xml.continues;
30 }
31
32 public ForcePoint(ForcePoint fPoint) {
33 this.distance = fPoint.distance;
34 this.forceValue = fPoint.forceValue;
35 this.continues = fPoint.continues;
36 }
37
38 public String getSpecialText() {
39 String result = "";
40 result += " * Distance: " + distance + "\n";
41 result += " * Value: " + forceValue + "\n";
42 result += " * Continues: " + continues + "\n";
43 return result;
44 }
45
46 public XMLForcePoint getXMLForcePoint() {
47 XMLForcePoint xmlForce = new XMLForcePoint();
48 xmlForce.distance = distance;
49 xmlForce.forceValue = forceValue;
50 xmlForce.continues = continues;
51 return xmlForce;
52 }
53 }