de.unikassel.android.sdcframework.devices
Class SampleTakingTask
java.lang.Object
de.unikassel.android.sdcframework.devices.SampleTakingTask
- All Implemented Interfaces:
- Runnable
public final class SampleTakingTask
- extends Object
- implements Runnable
This class does implement a runnable task to be executed delayed by an OS
handler in the service context.
Every time this runnable is executed, it will post itself for another delayed
execution using the current configured frequency. Further more, each time it
is executed the linked scanner is invoked to take a sample from its
associated device.
- See Also:
SampleTakingDeviceScanner
Method Summary |
void |
run()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
scanner
private final SampleTakingDeviceScanner scanner
- The scanner taking the samples on runnable execution
handler
private final Handler handler
- The handler to repost the task to for delayed runnable execution
SampleTakingTask
public SampleTakingTask(SampleTakingDeviceScanner scanner,
Handler handler)
- Constructor
- Parameters:
scanner
- the scanner taking the samples on runnable executionhandler
- the handler to repost the task to for delayed runnable execution
run
public final void run()
- Specified by:
run
in interface Runnable