|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openmuc.mux.dbprovider.SlotsDatabaseLayer
public class SlotsDatabaseLayer
Constructor Summary | |
---|---|
SlotsDatabaseLayer()
|
Method Summary | |
---|---|
void |
addChannel(ChannelConfiguration channel)
Add a new item (measurement channel) to the database |
Value |
getValue(java.lang.String label,
long timestamp)
Gets a single value with a specified timestamp from the database. |
java.util.List<Value> |
getValues(java.lang.String label,
long startTime)
Gets all values (time series) of a channel from startTime until now. |
java.util.List<Value> |
getValues(java.lang.String label,
long startTime,
long endTime)
Gets all values (time series) of a channel from startTime until endTime. |
void |
insertValue(java.lang.String label,
Value reading)
Insert a value into the database. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SlotsDatabaseLayer()
Method Detail |
---|
public void addChannel(ChannelConfiguration channel) throws java.io.IOException
DatabaseInterface
addChannel
in interface DatabaseInterface
channel
- unique identifier of the item
java.io.IOException
public Value getValue(java.lang.String label, long timestamp) throws java.io.IOException
DatabaseInterface
getValue
in interface DatabaseInterface
label
- unique identifier of the itemtimestamp
- timestamp of the value (ms since epoche)
java.io.IOException
public java.util.List<Value> getValues(java.lang.String label, long startTime) throws java.io.IOException
DatabaseInterface
getValues
in interface DatabaseInterface
label
- unique identifier of the itemstartTime
- Time of the first value in the time series in ms since epoche.
java.io.IOException
public java.util.List<Value> getValues(java.lang.String label, long startTime, long endTime) throws java.io.IOException
DatabaseInterface
getValues
in interface DatabaseInterface
label
- unique identifier of the itemstartTime
- Time of the first value in the time series in ms since epoche.endTime
- Time of the last value in the time series in ms since epoche
java.io.IOException
public void insertValue(java.lang.String label, Value reading) throws java.io.IOException
DatabaseInterface
insertValue
in interface DatabaseInterface
label
- label unique identifier of the itemreading
- a Value object
java.io.IOException
- Will be thrown if there is a problem with
the underlying database layer
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |