org.placelab.test
Class FakeSpotter

java.lang.Object
  extended byorg.placelab.spotter.AbstractSpotter
      extended byorg.placelab.spotter.SyncSpotter
          extended byorg.placelab.test.FakeSpotter
All Implemented Interfaces:
Spotter

public class FakeSpotter
extends SyncSpotter

Used for testing.


Field Summary
static java.lang.String LAB_AP_0_MAC
           
static java.lang.String LAB_AP_1_MAC
           
 
Constructor Summary
FakeSpotter()
           
 
Method Summary
 void close()
          Unloads resources used by the spotter.
 void fakeLab()
           
protected  Measurement getMeasurementImpl()
          Collects and returns a single Measurement.
protected  long nextScanInterval()
           
 void open()
          Load resources used by the spotter.
 
Methods inherited from class org.placelab.spotter.SyncSpotter
errorInBackgroundThreadAndThreadDeath, getMeasurement, scanUsingBackgroundThread, scanUsingEventSystem, startScanning, startScanning, stopScanning
 
Methods inherited from class org.placelab.spotter.AbstractSpotter
addListener, notifyEndOfScan, notifyEndOfScan, notifyGotException, notifyGotException, notifyGotMeasurement, notifyGotMeasurement, removeListener, scanOnce, scanOnce, waitForThread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LAB_AP_0_MAC

public static final java.lang.String LAB_AP_0_MAC
See Also:
Constant Field Values

LAB_AP_1_MAC

public static final java.lang.String LAB_AP_1_MAC
See Also:
Constant Field Values
Constructor Detail

FakeSpotter

public FakeSpotter()
Method Detail

fakeLab

public void fakeLab()

getMeasurementImpl

protected Measurement getMeasurementImpl()
Description copied from class: SyncSpotter
Collects and returns a single Measurement.

Specified by:
getMeasurementImpl in class SyncSpotter

open

public void open()
Description copied from interface: Spotter
Load resources used by the spotter. Applications should be able to invoke this methods multiple times in sequence and have the "right" things happen. All Spotters should be opened before being used.


close

public void close()
Description copied from interface: Spotter
Unloads resources used by the spotter. Multiple calls to close are ok.


nextScanInterval

protected long nextScanInterval()
Specified by:
nextScanInterval in class SyncSpotter
Returns:
the interval that the spotter should wait before invoking the next scan