package classes; import java.awt.Color; public class TrackedDataSet { //Property Integers public static final int CONSUMPTION = 0; public static final int PRODUCTION = 1; public static final int ACTIVATED_ELEMENTS = 2; public static final int ON_OFF = 3; public static final int TOTAL_PRODUCTION = 4; public static final int TOTAL_CONSUMPTION = 5; public static final int PERCENT_SUPPLIED = 6; public static final int PERCENT_NOT_SUPPLIED = 7; public static final int PERCENT_PARTIAL_SUPPLIED = 8; public static final int GROUP_PRODUCTION = 9; public static final int GROUP_CONSUMPTION = 10; public static final int AMOUNT_SUBNETS = 11; //Variables of the Data Set private AbstractCpsObject cps; private int property; private Color color; //Value for each timeStep private float values[]; /** * Data Set for the StatisticGraoh * * @param cps * the cps Object * @param property * which value should be tracked * @param color * color of the line in the graph */ public TrackedDataSet(AbstractCpsObject cps, int property, Color color) { this.cps = cps; this.property = property; this.color = color; this.values = new float[100]; for (int i = 0; i < values.length; i++) { values[i] = -1; } } public AbstractCpsObject getCpsObject() { return this.cps; } public int getProperty() { return this.property; } public Color getColor() { return this.color; } public float[] getValues() { return this.values; } public void setValAt(float val, int at){ this.values[at] = val; } }