super("RefreshSensorWorker");
}
@Override
public SensorReport doInBackground() {
SensorReport report;
factoryClassName = SalsaDAOFactory.class.getName();
sensorKRead = new SensorKey(sensor, factoryClassName, SensorKey.DataMode.READ);
sensorKWrite = new SensorKey(sensor, factoryClassName, SensorKey.DataMode.WRITE);
sensorStateKey = new SensorStateKey(sensor, factoryClassName);
try {
report = SensorDeviceApi.getSensorReport(sensor.getName());
DimensionType dimensionType = report.getDimensionType();
if (allowScalar || report == null
|| report.getDimensionType() != DimensionType.SCALAR) {
// Resume the DAO if they were suspended.
// Also, it makes the DAO factory initialize them and store them in the cache if
// this was not done already, lessening the work done on the EDT.
AbstractDAOFactory factory = DAOFactoryManager