Beaconstac Android  0.9.9
com.mobstac.beaconstac.core.MSBLEService Class Reference
Inheritance diagram for com.mobstac.beaconstac.core.MSBLEService:

Classes

enum  MSBeaconAffinity
 
class  MSBLEServiceBinder
 

Public Member Functions

void init ()
 
void triggeredRule (final String ruleName, final ArrayList< MSAction > actionarray)
 
void onCreate ()
 
IBinder onBind (Intent intent)
 
int onStartCommand (Intent intent, int flags, int startId)
 
void onDestroy ()
 

Static Public Member Functions

static MSBLEService getInstance ()
 

Member Function Documentation

static MSBLEService com.mobstac.beaconstac.core.MSBLEService.getInstance ( )
static

getter for the singleton instance

Returns
service instance
void com.mobstac.beaconstac.core.MSBLEService.init ( )

Function initialize the MSBLEService, Obtain the BluetoothAdapter instance

Callback when a BLE advertisement has been found.

Parameters
callbackTypeDetermines how this callback was triggered. Currently could only be android.bluetooth.le.ScanSettings#CALLBACK_TYPE_ALL_MATCHES.
resultA Bluetooth LE scan result.

Callback when batch results are delivered.

Parameters
resultsList of scan results that are previously scanned.

Callback when scan could not be started.

Parameters
errorCodeError code (one of SCAN_FAILED_*) for scan failure.

Callback when BLE scan data is received

Parameters
devicebluetooth device
rssicurrent rssi value
scanRecordthe bytestream of scan data
IBinder com.mobstac.beaconstac.core.MSBLEService.onBind ( Intent  intent)
Parameters
intentThe Intent that was used to bind to this service, as given to Context.bindService. Note that any extras that were included with the Intent at that point will not be seen here.
Returns
Return an IBinder through which clients can call on to the service.
void com.mobstac.beaconstac.core.MSBLEService.onDestroy ( )

Called by the system to notify a Service that it is no longer used and is being removed. The service should clean up any resources it holds (threads, registered receivers, etc) at this point. Upon return, there will be no more calls in to this Service object and it is effectively dead. Do not call this method directly.

int com.mobstac.beaconstac.core.MSBLEService.onStartCommand ( Intent  intent,
int  flags,
int  startId 
)
Parameters
intentThe Intent supplied to android.content.Context#startService, as given. This may be null if the service is being restarted after its process has gone away, and it had previously returned anything except START_STICKY_COMPATIBILITY.
flagsAdditional data about this start request. Currently either 0, START_FLAG_REDELIVERY, or START_FLAG_RETRY.
startIdA unique integer representing this specific request to start. Use with stopSelfResult(int).
Returns
The return value indicates what semantics the system should use for the service's current started state. It may be one of the constants associated with the START_CONTINUATION_MASK bits.
See also
#stopSelfResult(int)
void com.mobstac.beaconstac.core.MSBLEService.triggeredRule ( final String  ruleName,
final ArrayList< MSAction actionarray 
)

callback when rule is triggered

Parameters
ruleNamename of the rule being triggered
actionarrayarray of actions for the rule

The documentation for this class was generated from the following file: