-
Notifications
You must be signed in to change notification settings - Fork 1
/
CarBridge.java
62 lines (60 loc) · 1.45 KB
/
CarBridge.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
public abstract class CarBridge<E> implements Bridge<E>
{
protected E length;
protected String[] materials = new String[2];
protected E height;
protected E weightLimit;
protected int numLanes;
protected E speedLimit;
public CarBridge(E len, String[] mat, E h, E wl, int nL, E sL) {
length = len;
materials = mat;
height = h;
weightLimit = wl;
numLanes = nL;
speedLimit = sL;
}
public void bridgeLength(E len) {
len = length;
}
public E getBridgeLength() {
return length;
}
public void materials(String[] mat) {
mat = materials;
}
public String getMaterials() {
String temp = "";
for(String str: materials) {
temp += str + ", ";
}
return temp;
}
public void bridgeHeight(E h) {
h = height;
}
public E getBridgeHeight() {
return height;
}
public void weightLimit(E wl) {
weightLimit = wl;
}
public E getWeightLimit() {
return weightLimit;
}
public void numLanes(int nL) {
numLanes = nL;
}
public int getNumLanes() {
return numLanes;
}
public void speedLimit(E lim) {
lim = speedLimit;
}
public E getSpeedLimit() {
return speedLimit;
}
public abstract void tensions(double[] ten);
public abstract void cantileverLength(E len);
public abstract void arcRad(E rad);
}