Package ipfs.gomobile.android.bledriver
Class BleQueue
- java.lang.Object
-
- ipfs.gomobile.android.bledriver.BleQueue
-
public class BleQueue extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BleQueue.Callback
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
add(java.lang.Runnable r, BleQueue.Callback callback, long delay, java.lang.Runnable cancel)
void
clear()
void
completedCommand(int status)
The current command has been completed, move to the next command in the queue (if any)void
nextCommand()
Execute the next command in the subscribe queue.void
retryCommand()
Retry the current command.void
setId(java.lang.String id)
-
-
-
Constructor Detail
-
BleQueue
public BleQueue(Logger logger, android.os.Handler handler)
-
-
Method Detail
-
setId
public void setId(java.lang.String id)
-
add
public boolean add(java.lang.Runnable r, BleQueue.Callback callback, long delay, java.lang.Runnable cancel)
-
completedCommand
public void completedCommand(int status)
The current command has been completed, move to the next command in the queue (if any)
-
retryCommand
public void retryCommand()
Retry the current command. Typically used when a read/write fails and triggers a bonding procedure
-
nextCommand
public void nextCommand()
Execute the next command in the subscribe queue. A queue is used because the calls have to be executed sequentially. If the read or write fails, the next command in the queue is executed.
-
clear
public void clear()
-
-