public interface WattDepotInterface
Modifier and Type | Method and Description |
---|---|
void |
deleteCollectorProcessDefinition(CollectorProcessDefinition process)
Deletes the given CollectorProcessDefinitionData.
|
void |
deleteDepository(Depository depository)
Deletes the given Depository.
|
void |
deleteMeasurement(Depository depository,
Measurement measurement)
Deletes the given measurement from the given depository.
|
void |
deleteMeasurementPruningDefinition(MeasurementPruningDefinition gcd)
Deletes the given MeasurementPruningDefinition from the WattDepotServer.
|
void |
deleteMeasurementType(MeasurementType type)
Deletes the given MeasurementType.
|
void |
deleteSensor(Sensor sensor)
Deletes the given Sensor.
|
void |
deleteSensorGroup(SensorGroup group)
Deletes the given SensorGroup.
|
void |
deleteSensorModel(SensorModel model)
Deletes the given SensorModel.
|
InterpolatedValueList |
getAverageValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
InterpolatedValueList |
getAverageValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
CollectorProcessDefinition |
getCollectorProcessDefinition(String id)
Retrieves the CollectorProcessDefinitionData with the given id from the
WattDepot Server.
|
CollectorProcessDefinitionList |
getCollectorProcessDefinitions() |
InterpolatedValueList |
getDailyValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Boolean usePointValues) |
InterpolatedValueList |
getDailyValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Boolean usePointValues) |
DepositoryList |
getDepositories() |
Depository |
getDepository(String id)
Retrieves the Depository with the given id from the WattDepot Server.
|
SensorList |
getDepositorySensors(String id) |
DescriptiveStats |
getDescriptiveStats(Depository depository,
Sensor sensor,
Date timestamp,
Boolean daily,
Integer samples,
Boolean pointValues) |
DescriptiveStats |
getDescriptiveStats(Depository depository,
SensorGroup group,
Date timestamp,
Boolean daily,
Integer samples,
Boolean pointValues) |
InterpolatedValue |
getEarliestValue(Depository depository,
Sensor sensor) |
InterpolatedValue |
getEarliestValue(Depository depository,
SensorGroup group) |
InterpolatedValueList |
getHistoricalValues(Depository depository,
Sensor sensor,
Date timestamp,
Boolean daily,
Integer samples,
Boolean pointValues) |
InterpolatedValueList |
getHistoricalValues(Depository depository,
SensorGroup group,
Date timestamp,
Boolean daily,
Integer samples,
Boolean pointValues) |
InterpolatedValueList |
getHourlyValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Boolean usePointValues) |
InterpolatedValueList |
getHourlyValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Boolean usePointValues) |
InterpolatedValue |
getLatestValue(Depository depository,
Sensor sensor) |
InterpolatedValue |
getLatestValue(Depository depository,
SensorGroup group) |
InterpolatedValueList |
getMaximumValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
InterpolatedValueList |
getMaximumValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
MeasurementPruningDefinition |
getMeasurementPruningDefinition(String id) |
MeasurementPruningDefinitionList |
getMeasurementPruningDefinitions() |
MeasurementList |
getMeasurements(Depository depository,
Sensor sensor,
Date start,
Date end) |
MeasurementList |
getMeasurements(Depository depository,
SensorGroup group,
Date start,
Date end) |
MeasurementType |
getMeasurementType(String id) |
MeasurementTypeList |
getMeasurementTypes() |
InterpolatedValueList |
getMinimumValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
InterpolatedValueList |
getMinimumValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
Sensor |
getSensor(String id)
Retrieves the Sensor with the given id from the WattDepot Server.
|
SensorGroup |
getSensorGroup(String id)
Retrieves the SensorGroup with the given id from the WattDepot Server.
|
SensorGroupList |
getSensorGroups() |
SensorModel |
getSensorModel(String id)
Retrieves the SensorModel with the given id from the WattDepot Server.
|
SensorModelList |
getSensorModels() |
SensorList |
getSensors() |
SensorStatus |
getSensorStatus(Depository depository,
Sensor sensor) |
SensorStatusList |
getSensorStatuses(Depository depository,
SensorGroup group) |
Double |
getValue(Depository depository,
Sensor sensor,
Date timestamp) |
Double |
getValue(Depository depository,
Sensor sensor,
Date start,
Date end) |
Double |
getValue(Depository depository,
Sensor sensor,
Date start,
Date end,
Long gapSeconds) |
Double |
getValue(Depository depository,
Sensor sensor,
Date timestamp,
Long gapSeconds) |
Double |
getValue(Depository depository,
SensorGroup group,
Date timestamp) |
Double |
getValue(Depository depository,
SensorGroup group,
Date start,
Date end) |
Double |
getValue(Depository depository,
SensorGroup group,
Date start,
Date end,
Long gapSeconds) |
Double |
getValue(Depository depository,
SensorGroup group,
Date timestamp,
Long gapSeconds) |
InterpolatedValueList |
getValues(Depository depository,
Sensor sensor,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
InterpolatedValueList |
getValues(Depository depository,
SensorGroup group,
Date start,
Date end,
Integer interval,
Boolean usePointValues) |
boolean |
isDefinedCollectorProcessDefinition(String id)
Checks to see if the given id is a defined CollectorProcessDefinition id.
|
boolean |
isDefinedDepository(String id)
Checks to see if the given id is a defined Depository id.
|
boolean |
isDefinedMeasurementPruningDefinition(String id)
Checks to see if the given id is a defined MeasurementPruningDefinition id.
|
boolean |
isDefinedMeasurementType(String id)
Checks to see if the given id is a defined MeasurementType id.
|
boolean |
isDefinedSensor(String id)
Checks to see if the given id is a defined Sensor id.
|
boolean |
isDefinedSensorGroup(String id)
Checks to see if the given id is a defined SensorGroup id.
|
boolean |
isDefinedSensorModel(String id)
Checks to see if the given id is a defined SensorModel id.
|
boolean |
isHealthy()
Determines the health of the WattDepot server the client is communicating
with.
|
void |
putCollectorProcessDefinition(CollectorProcessDefinition process)
Stores the given CollectorProcessDefinitionData in the WattDepot Server.
|
void |
putDepository(Depository depository)
Stores the given Depository in the WattDepot Server.
|
void |
putMeasurement(Depository depository,
Measurement measurement) |
void |
putMeasurementPruningDefinition(MeasurementPruningDefinition gcd)
Stores the given MeasurementPruningDefinition in the WattDepot Server.
|
void |
putMeasurements(Depository depository,
MeasurementList measurementList) |
void |
putMeasurementType(MeasurementType type)
Stores the given MeasurementType in the WattDepot Server.
|
void |
putSensor(Sensor sensor)
Stores the given Sensor in the WattDepot Server.
|
void |
putSensorGroup(SensorGroup group)
Stores the given SensorGroup in the WattDepot Server.
|
void |
putSensorModel(SensorModel model)
Stores the given SensorModel in the WattDepot Server.
|
void |
updateCollectorProcessDefinition(CollectorProcessDefinition process)
Updates the given CollectorProcessDefinitionData in the WattDepot Server.
|
void |
updateDepository(Depository depository)
Updates the given Depository in the WattDepot Server.
|
void |
updateMeasurementPruningDefinition(MeasurementPruningDefinition gcd)
Updates the given MeasurementPruningDefinition in the WattDepot Server.
|
void |
updateMeasurementType(MeasurementType type)
Updates the given MeasurementType in the WattDepot Server.
|
void |
updateSensor(Sensor sensor)
Updates the given Sensor in the WattDepot Server.
|
void |
updateSensorGroup(SensorGroup group)
Updates the given SensorGroup in the WattDepot Server.
|
void |
updateSensorModel(SensorModel model)
Updates the given SensorModel in the WattDepot Server.
|
void deleteCollectorProcessDefinition(CollectorProcessDefinition process) throws IdNotFoundException
process
- the CollectorProcessDefinitionData to delete.IdNotFoundException
- if the CollectorProcessDefinitionData is not
found in the server.void deleteDepository(Depository depository) throws IdNotFoundException
depository
- the Depository to delete.IdNotFoundException
- if the Depository is not found in the server.void deleteMeasurement(Depository depository, Measurement measurement) throws IdNotFoundException
depository
- the Depository that stores the measurement.measurement
- the Measurement to delete.IdNotFoundException
- if the Measurement is not found in the
Depository.void deleteMeasurementPruningDefinition(MeasurementPruningDefinition gcd) throws IdNotFoundException
gcd
- The MeasurementPruningDefinition to delete.IdNotFoundException
- if the MPD is not
found.void deleteMeasurementType(MeasurementType type) throws IdNotFoundException
type
- the measurement type to delete.IdNotFoundException
- if the MeasurementType is not found in the
Depository.void deleteSensor(Sensor sensor) throws IdNotFoundException
sensor
- the Sensor to delete.IdNotFoundException
- if the Sensor is not found in the server.void deleteSensorGroup(SensorGroup group) throws IdNotFoundException
group
- the SensorGroup to delete.IdNotFoundException
- if the SensorGroup is not found in the server.void deleteSensorModel(SensorModel model) throws IdNotFoundException
model
- the SensorModel to delete.IdNotFoundException
- if the SensorModel is not found in the server.InterpolatedValueList getAverageValues(Depository depository, Sensor sensor, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.InterpolatedValueList getAverageValues(Depository depository, SensorGroup group, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.CollectorProcessDefinition getCollectorProcessDefinition(String id) throws IdNotFoundException
id
- The CollectorProcessDefinitionData's id.IdNotFoundException
- if the given id is not a
CollectorProcessDefinitionData's id.CollectorProcessDefinitionList getCollectorProcessDefinitions()
InterpolatedValueList getDailyValues(Depository depository, Sensor sensor, Date start, Date end, Boolean usePointValues)
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.InterpolatedValueList getDailyValues(Depository depository, SensorGroup group, Date start, Date end, Boolean usePointValues)
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.DepositoryList getDepositories()
Depository getDepository(String id) throws IdNotFoundException
id
- The Depository's id.IdNotFoundException
- if the given id is not a Depository's id.SensorList getDepositorySensors(String id) throws IdNotFoundException
id
- The depository id.IdNotFoundException
- if the id is not defined.DescriptiveStats getDescriptiveStats(Depository depository, Sensor sensor, Date timestamp, Boolean daily, Integer samples, Boolean pointValues)
depository
- The Depository storing the Measurements.sensor
- The Sensor making the Measurements.timestamp
- The time to base the historical values calculation on.daily
- if true, use daily grouping of values, if false use hourly grouping.samples
- How many samples to use to calculate the values. Corresponds to weeks.pointValues
- if true use point value, use difference values otherwise.DescriptiveStats getDescriptiveStats(Depository depository, SensorGroup group, Date timestamp, Boolean daily, Integer samples, Boolean pointValues)
depository
- The Depository storing the Measurements.group
- The SensorGroup whose sensors are making the Measurements.timestamp
- The time to base the historical values calculation on.daily
- if true, use daily grouping of values, if false use hourly grouping.samples
- How many samples to use to calculate the values. Corresponds to weeks.pointValues
- if true use point value, use difference values otherwise.InterpolatedValue getEarliestValue(Depository depository, Sensor sensor)
depository
- The Depository storing the Measurements.sensor
- The Sensor making the Measurements.InterpolatedValue getEarliestValue(Depository depository, SensorGroup group)
depository
- The Depository storing the Measurements.group
- The SensorGroup whose sensors are making the Measurements.InterpolatedValueList getHistoricalValues(Depository depository, Sensor sensor, Date timestamp, Boolean daily, Integer samples, Boolean pointValues)
depository
- The Depository storing the Measurements.sensor
- The Sensor making the Measurements.timestamp
- The time to base the historical values calculation on.daily
- if true, use daily grouping of values, if false use hourly grouping.samples
- How many samples to use to calculate the values. Corresponds to weeks.pointValues
- if true use point value, use difference values otherwise.InterpolatedValueList getHistoricalValues(Depository depository, SensorGroup group, Date timestamp, Boolean daily, Integer samples, Boolean pointValues)
depository
- The Depository storing the Measurements.group
- The SensorGroup whose sensors are making the Measurements.timestamp
- The time to base the historical values calculation on.daily
- if true, use daily grouping of values, if false use hourly grouping.samples
- How many samples to use to calculate the values. Corresponds to weeks.pointValues
- if true use point value, use difference values otherwise.InterpolatedValueList getHourlyValues(Depository depository, Sensor sensor, Date start, Date end, Boolean usePointValues)
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.InterpolatedValueList getHourlyValues(Depository depository, SensorGroup group, Date start, Date end, Boolean usePointValues)
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.InterpolatedValue getLatestValue(Depository depository, Sensor sensor)
depository
- The Depository storing the Measurements.sensor
- The Sensor making the Measurements.InterpolatedValue getLatestValue(Depository depository, SensorGroup group)
depository
- The Depository storing the Measurements.group
- The SensorGroup whose sensors are making the Measurements.InterpolatedValueList getMaximumValues(Depository depository, Sensor sensor, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.InterpolatedValueList getMaximumValues(Depository depository, SensorGroup group, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.MeasurementPruningDefinition getMeasurementPruningDefinition(String id) throws IdNotFoundException
id
- The MeasurementPruningDefinition id.IdNotFoundException
- if id is not defined.MeasurementPruningDefinitionList getMeasurementPruningDefinitions()
MeasurementType getMeasurementType(String id) throws IdNotFoundException
id
- the unique id for the MeasurementType.IdNotFoundException
- if the given id is not a MeasurementType's
id.MeasurementTypeList getMeasurementTypes()
MeasurementList getMeasurements(Depository depository, Sensor sensor, Date start, Date end)
depository
- The Depository storing the Measurements.sensor
- The Sensor that made the measurements.start
- The start time.end
- The end time.MeasurementList getMeasurements(Depository depository, SensorGroup group, Date start, Date end)
depository
- The Depository storing the Measurements.group
- The SensorGroup whose sensors made the measurements.start
- The start time.end
- The end time.InterpolatedValueList getMinimumValues(Depository depository, Sensor sensor, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.InterpolatedValueList getMinimumValues(Depository depository, SensorGroup group, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.Sensor getSensor(String id) throws IdNotFoundException
id
- The Sensor's id.IdNotFoundException
- if the given id is not a Sensor's id.SensorGroup getSensorGroup(String id) throws IdNotFoundException
id
- The SensorGroup's id.IdNotFoundException
- if the given id is not a SensorGroup's id.SensorGroupList getSensorGroups()
SensorModel getSensorModel(String id) throws IdNotFoundException
id
- The SensorModel's id.IdNotFoundException
- if the given id is not a SensorModel's id.SensorModelList getSensorModels()
SensorStatus getSensorStatus(Depository depository, Sensor sensor)
depository
- The depository to check.sensor
- The Sensor.SensorStatusList getSensorStatuses(Depository depository, SensorGroup group)
depository
- The depository to check.group
- The SensorGroup.SensorList getSensors()
Double getValue(Depository depository, Sensor sensor, Date timestamp) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.timestamp
- The time for the measured value.NoMeasurementException
- if there aren't any measurements around the
timestamp.Double getValue(Depository depository, Sensor sensor, Date start, Date end) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.NoMeasurementException
- if there are no measurements around the
start or end time.Double getValue(Depository depository, Sensor sensor, Date start, Date end, Long gapSeconds) throws NoMeasurementException, MeasurementGapException
depository
- The Depository storing the measurements.sensor
- The Sensor making the measurements.start
- The start of the interval.end
- The end of the intervalgapSeconds
- The maximum number of seconds that measurements need to
be within the start and end.NoMeasurementException
- if there are no measurements around the
start or end time.MeasurementGapException
- if the measurements around start or end are
too far apart.Double getValue(Depository depository, Sensor sensor, Date timestamp, Long gapSeconds) throws NoMeasurementException, MeasurementGapException
depository
- The Depository storing the measurements.sensor
- The Sensor making the measurements.timestamp
- The time of the value.gapSeconds
- The maximum number of seconds that measurements need to
be within the start and end.NoMeasurementException
- If there aren't any measurements around the
time.MeasurementGapException
- if the measurements around timestamp are
too far apart.Double getValue(Depository depository, SensorGroup group, Date timestamp) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The SensorGroup whose sensors are making the measurements.timestamp
- The time for the measured value.NoMeasurementException
- if there aren't any measurements around the
timestamp.Double getValue(Depository depository, SensorGroup group, Date start, Date end) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The SensorGroup whose Sensors are making the measurements.start
- The start of the period.end
- The end of the period.NoMeasurementException
- if there are no measurements around the
start or end time.Double getValue(Depository depository, SensorGroup group, Date start, Date end, Long gapSeconds) throws NoMeasurementException, MeasurementGapException
depository
- The Depository storing the measurements.group
- The SensorGroup whose Sensors are making the measurements.start
- The start of the interval.end
- The end of the intervalgapSeconds
- The maximum number of seconds that measurements need to
be within the start and end.NoMeasurementException
- if there are no measurements around the
start or end time.MeasurementGapException
- if the measurements around start or end are
too far apart.Double getValue(Depository depository, SensorGroup group, Date timestamp, Long gapSeconds) throws NoMeasurementException, MeasurementGapException
depository
- The Depository storing the measurements.group
- The SensorGroup whose Sensors are making the measurements.timestamp
- The time of the value.gapSeconds
- The maximum number of seconds that measurements need to
be within the start and end.NoMeasurementException
- If there aren't any measurements around the
time.MeasurementGapException
- if the measurements around timestamp are
too far apart.InterpolatedValueList getValues(Depository depository, Sensor sensor, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.sensor
- The sensor making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.InterpolatedValueList getValues(Depository depository, SensorGroup group, Date start, Date end, Integer interval, Boolean usePointValues) throws NoMeasurementException
depository
- The Depository storing the measurements.group
- The sensor group making the measurements.start
- The start of the period.end
- The end of the period.interval
- The sample interval in minutes.usePointValues
- Use point values or difference values, if true point values are used, otherwise difference values.NoMeasurementException
- if there are no measurements around the
start or end time.boolean isDefinedCollectorProcessDefinition(String id)
id
- the id to check.boolean isDefinedDepository(String id)
id
- the id to check.boolean isDefinedMeasurementPruningDefinition(String id)
id
- the id to check.boolean isDefinedMeasurementType(String id)
id
- the id to check.boolean isDefinedSensor(String id)
id
- the id to check.boolean isDefinedSensorGroup(String id)
id
- the id to check.boolean isDefinedSensorModel(String id)
id
- the id to check.boolean isHealthy()
void putCollectorProcessDefinition(CollectorProcessDefinition process)
process
- the CollectorProcessDefinitionData.void putDepository(Depository depository)
depository
- the Depository.void putMeasurement(Depository depository, Measurement measurement) throws MeasurementTypeException
depository
- The Depository to store the Measurement.measurement
- The Measurement to store.MeasurementTypeException
- if the type of the measurement doesn't
match the type of the depository.void putMeasurementPruningDefinition(MeasurementPruningDefinition gcd)
gcd
- the MeasurementPruningDefinition.void putMeasurementType(MeasurementType type)
type
- the MeasurementType.void putMeasurements(Depository depository, MeasurementList measurementList) throws MeasurementTypeException, MeasurementListSizeExceededException
depository
- The Depository to store the Measurement.measurementList
- The MeasurementList to be stored.MeasurementTypeException
- if the type of a measurement doesn't
match the type of the depository.MeasurementListSizeExceededException
- if list size requirement is
exceeded.void putSensor(Sensor sensor)
sensor
- the Sensor.void putSensorGroup(SensorGroup group)
group
- the SensorGroup.void putSensorModel(SensorModel model)
model
- the SensorModel.void updateCollectorProcessDefinition(CollectorProcessDefinition process)
process
- The CollectorProcessDefinitionData to update.void updateDepository(Depository depository)
depository
- The Depository to update.void updateMeasurementPruningDefinition(MeasurementPruningDefinition gcd)
gcd
- The MeasurementPruningDefinition to update.void updateMeasurementType(MeasurementType type)
type
- the MeasurementType to update.void updateSensor(Sensor sensor)
sensor
- The Sensor to update.void updateSensorGroup(SensorGroup group)
group
- The SensorGroup to update.void updateSensorModel(SensorModel model)
model
- the SensorModel to update.Copyright © 2015 Collaborative Software Development Laboratory. All rights reserved.