org.openmuc.framework.datalogger.spi
Interface LogSourceService


public interface LogSourceService


Method Summary
 java.lang.String getId()
           
 Record getValue(java.lang.String label, long timestamp)
          Gets a single value with a specified timestamp from the database.
 java.util.List<Record> getValues(java.lang.String label, long startTimestamp)
          Gets all values (time series) of a channel from startTime until now.
 java.util.List<Record> getValues(java.lang.String label, long startTimestamp, long endTimestamp)
          Gets all values (time series) of a channel from startTime until endTime.
 

Method Detail

getId

java.lang.String getId()

getValues

java.util.List<Record> getValues(java.lang.String label,
                                 long startTimestamp)
                                 throws java.io.IOException
Gets all values (time series) of a channel from startTime until now. It is the same as the call getValues(label, startTime, System.currentTimeMillies)

Parameters:
label - unique identifier of the item
startTimestamp - Time of the first value in the time series in ms since epoche.
Returns:
A List of value objects or an empty list if now matching object have been found.
Throws:
java.io.IOException

getValues

java.util.List<Record> getValues(java.lang.String label,
                                 long startTimestamp,
                                 long endTimestamp)
                                 throws java.io.IOException
Gets all values (time series) of a channel from startTime until endTime.

Parameters:
label - unique identifier of the item
startTimestamp - Time of the first value in the time series in ms since epoche.
endTimestamp - Time of the last value in the time series in ms since epoche
Returns:
A List of value objects or an empty list if now matching object have been found.
Throws:
java.io.IOException

getValue

Record getValue(java.lang.String label,
                long timestamp)
                throws java.io.IOException
Gets a single value with a specified timestamp from the database.

Parameters:
label - unique identifier of the item
timestamp - timestamp of the value (ms since epoche)
Returns:
a Value object if to has been found or null
Throws:
java.io.IOException