Class Collector.CsvDatapointConstructor
java.lang.Object
de.iip_ecosphere.platform.support.collector.Collector.CsvDatapointConstructor
- All Implemented Interfaces:
Collector.DatapointConstructor
- Enclosing class:
Collector
private static class Collector.CsvDatapointConstructor
extends Object
implements Collector.DatapointConstructor
A CSV datapoint constructor.
- Author:
- Holger Eichelberger, SSE
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateCreates a collector constructor. -
Method Summary
Modifier and TypeMethodDescriptionaddExecutionTimeMs(long execTimeMs) Adds an execution time in milliseconds.voidclose()Closes the collector, tries to persist it.private StringComposes entries to an output line.private StringQuotes a string text.private StringTurns an object into a string for output.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.iip_ecosphere.platform.support.collector.Collector.DatapointConstructor
measureMs
-
Field Details
-
tag
-
timestamp
private long timestamp -
buildId
-
execTimeMs
-
-
Constructor Details
-
CsvDatapointConstructor
Creates a collector constructor.- Parameters:
tag- data collection tag
-
-
Method Details
-
addExecutionTimeMs
Description copied from interface:Collector.DatapointConstructorAdds an execution time in milliseconds.- Specified by:
addExecutionTimeMsin interfaceCollector.DatapointConstructor- Parameters:
execTimeMs- the execution time in milliseconds- Returns:
- this (builder style)
-
close
public void close()Description copied from interface:Collector.DatapointConstructorCloses the collector, tries to persist it.- Specified by:
closein interfaceCollector.DatapointConstructor
-
compose
Composes entries to an output line.- Parameters:
entries- the individual entries- Returns:
- the composed line
-
toString
Turns an object into a string for output.- Parameters:
entry- the entry- Returns:
- the corresponding string
-
quote
Quotes a string text.- Parameters:
text- the text to be quoted- Returns:
- the quoted text
-