Skip to content

Package: SimulationsErgebnisBuilder

SimulationsErgebnisBuilder

nameinstructionbranchcomplexitylinemethod
auslastungProMaschine(Map)
M: 0 C: 5
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 2
100%
M: 0 C: 1
100%
auslastungProMitarbeiter(Map)
M: 0 C: 5
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 2
100%
M: 0 C: 1
100%
build()
M: 0 C: 14
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
create()
M: 0 C: 4
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
nichtEingehalteneSlas(Collection)
M: 0 C: 5
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 2
100%
M: 0 C: 1
100%
pruefErgebnis(PruefErgebnis)
M: 0 C: 5
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 2
100%
M: 0 C: 1
100%
verbrauchteZeitProProduktionsAuftrag(Map)
M: 0 C: 5
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 2
100%
M: 0 C: 1
100%

Coverage

1: package simulation;
2:
3: import auftraege.Dokumentenklasse;
4: import auftraege.ProduktionsAuftrag;
5: import maschine.Maschine;
6: import mensch.Mitarbeiter;
7: import simulation.SimulationsHelper.Auslastung;
8: import tec.uom.se.ComparableQuantity;
9:
10: import javax.measure.quantity.Time;
11: import java.util.Collection;
12: import java.util.Map;
13:
14: /**
15: * Builder nach dem Builder/Erbauer Entwurfsmuster für das SimulationsErgebnis.
16: */
17: public final class SimulationsErgebnisBuilder {
18:         
19:         private Map<ProduktionsAuftrag, ComparableQuantity<Time>> verbrauchteZeitProProduktionsAuftrag;
20:         private Map<Maschine, Auslastung> auslastungProMaschine;
21:         private Map<Mitarbeiter, Auslastung> auslastungProMitarbeiter;
22:         private Collection<Dokumentenklasse> nichtEingehalteneSlas;
23:         private PruefErgebnis pruefErgebnis;
24:         
25:         
26:         private SimulationsErgebnisBuilder() {
27:         }
28:         
29:         /**
30:          *
31:          * @return ein Builder für ein SimulationsErgebnis.
32:          */
33:         public static SimulationsErgebnisBuilder create() {
34:                 return new SimulationsErgebnisBuilder();
35:         }
36:         
37:         
38:         /**
39:          *
40:          * @return das fertig gebaute SimulationsErgebnis.
41:          */
42:         public SimulationsErgebnis build() {
43:                 return new SimulationsErgebnis(
44:                                 this.pruefErgebnis,
45:                                 this.verbrauchteZeitProProduktionsAuftrag,
46:                                 this.auslastungProMaschine,
47:                                 this.auslastungProMitarbeiter,
48:                                 this.nichtEingehalteneSlas);
49:         }
50:         /**
51:          *
52:          * @param pruefErgebnis wird gesetzt
53:          * @return Builder
54:          */
55:         public SimulationsErgebnisBuilder pruefErgebnis(final PruefErgebnis pruefErgebnis) {
56:                 this.pruefErgebnis = pruefErgebnis;
57:                 return this;
58:         }
59:         
60:         /**
61:          *
62:          * @param verbrauchteZeitProProduktionsAuftrag wird gesetzt
63:          * @return Builder
64:          */
65:         public SimulationsErgebnisBuilder verbrauchteZeitProProduktionsAuftrag(final Map<ProduktionsAuftrag,
66:                         ComparableQuantity<Time>> verbrauchteZeitProProduktionsAuftrag) {
67:                 this.verbrauchteZeitProProduktionsAuftrag = verbrauchteZeitProProduktionsAuftrag;
68:                 return this;
69:         }
70:         
71:         /**
72:          *
73:          * @param auslastungProMaschine wird gesetzt
74:          * @return Builder
75:          */
76:         public SimulationsErgebnisBuilder auslastungProMaschine(final Map<Maschine, Auslastung> auslastungProMaschine) {
77:                 this.auslastungProMaschine = auslastungProMaschine;
78:                 return this;
79:         }
80:         
81:         /**
82:          *
83:          * @param auslastungProMitarbeiter wird gesetzt
84:          * @return Builder
85:          */
86:         public SimulationsErgebnisBuilder auslastungProMitarbeiter(final Map<Mitarbeiter, Auslastung> auslastungProMitarbeiter) {
87:                 this.auslastungProMitarbeiter = auslastungProMitarbeiter;
88:                 return this;
89:         }
90:         
91:         /**
92:          *
93:          * @param nichtEingehalteneSlas wird gesetzt
94:          * @return Builder
95:          */
96:         public SimulationsErgebnisBuilder nichtEingehalteneSlas(final Collection<Dokumentenklasse> nichtEingehalteneSlas) {
97:                 this.nichtEingehalteneSlas = nichtEingehalteneSlas;
98:                 return this;
99:         }
100: }