Revision 656232633437 () - Diff

Link to this snippet: https://friendpaste.com/21WFtusmIesUcgQ8erTzT9
Embed:
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
public Simulation getSimulation() throws ClassNotFoundException {

ArrayList<Operation> listOp2 = new ArrayList<Operation>();
operationsPrioriteToDoListModel = dyndefn.getOperationList();

for (int i = 0; i < operationsPrioriteToDoListModel.size(); i++) {
listOp2.add((AbstractOperation) operationsPrioriteToDoListModel.get(i));
if (operationsPrioriteToDoListModel.get(i) instanceof OperationSuccession) {
listOp2.add((OperationSuccession) operationsPrioriteToDoListModel.get(i));
}
}
int duration = simDef.getDuration();
int visu = simDef.getFrequenceVisu();
Simulation c2 = new Simulation(listOp2, duration, visu, simDef.getMatrixWidth(), simDef.getMatrixHeight());
if(simDef.getCalcul() != null){
c2.NUM--;
}
if(landscapeDefinition != null)
c2.setMerges(landscapeDefinition.getMerges());
return c2;
}

public int getReturnStatus() {
return returnStatus;
}

public int getMatrixHeight() {
return matrixHeight;
}

public int getMatrixWidth() {
return matrixWidth;
}

public String getTimer() {
return strTimer;
}