public class Aggregator
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
private class |
Aggregator.Interval |
Modifier and Type | Field and Description |
---|---|
private java.util.List<java.util.List<Aggregation>> |
_aggrAllAttribute
Aggregationen für Gesamt Spalte
|
private java.util.List<java.util.List<Aggregation>> |
_aggrAllObject
Aggregationen für Gesamt Objekt
|
private java.util.List<java.util.List<Aggregation>> |
_aggrIntervalAttribute
Aggregationen für Intervall Spalte.
|
private java.util.List<java.util.List<Aggregation>> |
_aggrIntervalObject
Aggregationen für Intervall Objekt.
|
private java.util.Map<java.util.List<java.util.List<Aggregation>>,Aggregator.Interval> |
_intervals |
private int[] |
_linkedAttributes
Zeigt an welche Attribute durch die Aggregation
spalte zusammengefasst werden. |
private boolean |
_list
Anwendung "Liste"
|
private java.util.List<BaseDataSet> |
_mostRecent
Zuletzt erhaltener Ausgangsdatensatz
|
private java.util.List<BaseDataSet> |
_mostRecentIntervalAttributeData
Zuletzt erstellte Ausgangsdatensatz für Interval-Spalte-Aggregation.
|
private java.util.List<BaseDataSet> |
_mostRecentIntervalObjectData
Zuletzt erstellte Ausgangsdatensatz für Interval-Objekt-Aggregation.
|
private int |
_numColumns
Anzahl der Spalten
|
private ProtocolType |
_protocolType
Änderungsprotokoll oder Zustandsprotokoll.
|
Constructor and Description |
---|
Aggregator(ProcessingInformation pi) |
Modifier and Type | Method and Description |
---|---|
private void |
addAggregationResult(java.util.List<ResultValue> rv,
Aggregation aggregation)
Fügt das Ergebnis einer Aggregation zu einer Liste hinzu
|
private void |
aggregate(java.util.List<Aggregation> aggregations,
ResultValue value) |
boolean |
aggregate(java.util.List<BaseDataSet> bds)
Führt die Aggregation durch.
|
private IntermediateDataSet |
aggregateInterval(byte status,
int currentPeriod,
ProcessingInformation.ApplyAggregation order)
Erstellt einen neuen Ausgangsdatensatz mit den Aggregationsdaten.
|
private void |
aggregateList(int i,
BaseDataSet dataSet,
java.util.List<java.util.List<Aggregation>> attribute) |
private java.util.List<java.util.List<Aggregation>> |
createAggregationForEveryAttribute(java.util.List<Elements> elements)
Legt ein Aggregationsobjekt pro Systemobjekt an.
|
private java.util.List<Aggregation> |
createAggregationList(Elements element) |
private java.util.List<java.util.List<Aggregation>> |
createAggregationPerColumn(java.util.List<Elements> elements)
Ordnet jedem Attribut eine Aggregation zu.
|
private BaseDataSet |
createBaseDataSet(java.util.List<java.util.List<Aggregation>> aggregations,
int i,
ResultValue rv) |
IntermediateDataSet[] |
endOfInterval(byte status,
int currentPeriod)
Aggregationsdatensätze abrufen, die zum Ende eines Intervalls vorliegen.
|
IntermediateDataSet[] |
endOfProtocol(int currentPeriod)
Aggregationsdatensätze abrufen, die zum Ende der Protokollerstellung vorliegen.
|
int[] |
getLinkedAttributes()
Zeigt an welche Attribute durch die Aggregation
spalte zusammengefasst werden. |
boolean |
isListAggregation()
Werden auch nicht aggregierte Daten versendet?
|
private final java.util.List<java.util.List<Aggregation>> _aggrIntervalAttribute
private final java.util.List<java.util.List<Aggregation>> _aggrIntervalObject
private final java.util.List<java.util.List<Aggregation>> _aggrAllAttribute
private final java.util.List<java.util.List<Aggregation>> _aggrAllObject
private final boolean _list
private java.util.List<BaseDataSet> _mostRecent
private java.util.List<BaseDataSet> _mostRecentIntervalAttributeData
private java.util.List<BaseDataSet> _mostRecentIntervalObjectData
private final ProtocolType _protocolType
private final int _numColumns
private int[] _linkedAttributes
spalte
zusammengefasst werden. Zusammengehörige Spalten werden duch die gleichen Nummern
gekennzeichnet.private final java.util.Map<java.util.List<java.util.List<Aggregation>>,Aggregator.Interval> _intervals
public Aggregator(ProcessingInformation pi) throws FailureException
pi
- Informationen für die Datenaufbereitung.FailureException
- Fehler beim Anlegen von neuen Instanzen.private java.util.List<java.util.List<Aggregation>> createAggregationPerColumn(java.util.List<Elements> elements) throws FailureException
elements
- AttributeFailureException
- Fehler beim Erzeugen von neuen Instanzenprivate java.util.List<java.util.List<Aggregation>> createAggregationForEveryAttribute(java.util.List<Elements> elements) throws FailureException
elements
- DatenidentifikationenFailureException
- Fehler beim Instanziieren von Aggregationsobjekten.private java.util.List<Aggregation> createAggregationList(Elements element) throws FailureException
FailureException
public boolean aggregate(java.util.List<BaseDataSet> bds)
bds
- private void aggregateList(int i, BaseDataSet dataSet, java.util.List<java.util.List<Aggregation>> attribute)
private void aggregate(java.util.List<Aggregation> aggregations, ResultValue value)
public IntermediateDataSet[] endOfInterval(byte status, int currentPeriod)
status
- Status der dem Ausgangsadtensatz zugewiesen wird.currentPeriod
- Aktueller Zeitbereich0
, und dem Ergebnis der Aggregation für Intervall_Spalte in 1
.
Die Einträge können null
sein, falls keine Aggregationsdaten vorliegen.private IntermediateDataSet aggregateInterval(byte status, int currentPeriod, ProcessingInformation.ApplyAggregation order)
status
- StatuscurrentPeriod
- Aktueller Zeitbereichorder
- Aggregationsanwendung @return Ausgangsdatensatz oder null
falls sich im Vergleich zum letzten Ausgangsdatensatz nicht geändert hat, und ein Deltaprotokoll erstellt
werden soll.private BaseDataSet createBaseDataSet(java.util.List<java.util.List<Aggregation>> aggregations, int i, ResultValue rv)
public IntermediateDataSet[] endOfProtocol(int currentPeriod)
currentPeriod
- Aktueller Zeitbereich[0]
und denm Ergebnis der Aggregation für Gesamt_Spalte in [1]
.
Einträge können null
sein, falls keine Aggregationsdaten vorliegen.private void addAggregationResult(java.util.List<ResultValue> rv, Aggregation aggregation)
rv
- Listeaggregation
- Aggregationpublic boolean isListAggregation()
true
falls liste
eine der ausgewählten die Aggregationsanwendungen ist.public int[] getLinkedAttributes()
spalte
zusammengefasst werden. Zusammengehörige Spalten werden duch die gleichen Nummern
gekennzeichnet.null
falls die spalten
Aggregation nicht verwendet wird.