Class MemoryBinaryMeasurementsDaoImpl<V,Q extends javax.measure.quantity.Quantity>
- java.lang.Object
-
- org.palladiosimulator.edp2.dao.impl.Edp2DaoImpl
-
- org.palladiosimulator.edp2.dao.impl.AbstractMeasurementsDaoImpl<V,Q>
-
- org.palladiosimulator.edp2.dao.memory.impl.MemoryBinaryMeasurementsDaoImpl<V,Q>
-
- All Implemented Interfaces:
BinaryMeasurementsDao<V,Q>
,Edp2Dao
,MeasurementsDao<V,Q>
public class MemoryBinaryMeasurementsDaoImpl<V,Q extends javax.measure.quantity.Quantity> extends AbstractMeasurementsDaoImpl<V,Q> implements BinaryMeasurementsDao<V,Q>
-
-
Constructor Summary
Constructors Constructor Description MemoryBinaryMeasurementsDaoImpl(javax.measure.unit.Unit<Q> storageUnit)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Closes the connection to the data store.void
flush()
Write all non-persisted data to disk.List<javax.measure.Measure<V,Q>>
getMeasurements()
javax.measure.unit.Unit<Q>
getUnit()
Returns the unit in which all measurements are stored.void
open()
Opens the connection to the data store and makes it's data accessible.void
setUnit(javax.measure.unit.Unit<Q> unit)
Sets the unit in which all measurements are stored.-
Methods inherited from class org.palladiosimulator.edp2.dao.impl.AbstractMeasurementsDaoImpl
deserialize, serialize
-
Methods inherited from class org.palladiosimulator.edp2.dao.impl.Edp2DaoImpl
canClose, canDelete, canOpen, delete, isDeleted, isOpen, setClosed, setDeleted, setOpen
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.palladiosimulator.edp2.dao.Edp2Dao
canClose, canDelete, canOpen, delete, isDeleted, isOpen
-
Methods inherited from interface org.palladiosimulator.edp2.dao.MeasurementsDao
deserialize, serialize
-
-
-
-
Constructor Detail
-
MemoryBinaryMeasurementsDaoImpl
public MemoryBinaryMeasurementsDaoImpl(javax.measure.unit.Unit<Q> storageUnit)
-
-
Method Detail
-
getMeasurements
public List<javax.measure.Measure<V,Q>> getMeasurements()
- Specified by:
getMeasurements
in interfaceMeasurementsDao<V,Q extends javax.measure.quantity.Quantity>
- Returns:
- Observed measurements.
-
flush
public void flush()
Description copied from interface:Edp2Dao
Write all non-persisted data to disk.
-
open
public void open() throws DataNotAccessibleException
Description copied from interface:Edp2Dao
Opens the connection to the data store and makes it's data accessible.- Specified by:
open
in interfaceEdp2Dao
- Overrides:
open
in classEdp2DaoImpl
- Throws:
DataNotAccessibleException
- Errors when initializing the data access.
-
close
public void close() throws DataNotAccessibleException
Description copied from interface:Edp2Dao
Closes the connection to the data store. If necessary, data is persisted before closing.- Specified by:
close
in interfaceEdp2Dao
- Overrides:
close
in classEdp2DaoImpl
- Throws:
DataNotAccessibleException
- Errors when accessing data.
-
getUnit
public javax.measure.unit.Unit<Q> getUnit()
Description copied from interface:BinaryMeasurementsDao
Returns the unit in which all measurements are stored.- Specified by:
getUnit
in interfaceBinaryMeasurementsDao<V,Q extends javax.measure.quantity.Quantity>
- Returns:
- The unit.
-
setUnit
public void setUnit(javax.measure.unit.Unit<Q> unit)
Description copied from interface:BinaryMeasurementsDao
Sets the unit in which all measurements are stored.- Specified by:
setUnit
in interfaceBinaryMeasurementsDao<V,Q extends javax.measure.quantity.Quantity>
- Parameters:
unit
- The unit.
-
-