public class AntPlusWatchDownloaderPcc extends AntPluginPcc
Modifier and Type | Class and Description |
---|---|
static class |
AntPlusWatchDownloaderPcc.DeviceInfo
Device information, used in available devices list and making requests
|
static class |
AntPlusWatchDownloaderPcc.DeviceListUpdateCode
Defines the codes explaining the changes occurring to the device list received by
the
AntPlusWatchDownloaderPcc.IAvailableDeviceListReceiver . |
static interface |
AntPlusWatchDownloaderPcc.IAvailableDeviceListReceiver
Receiver for the AvailableDeviceList event, which is:
Broadcasts the current list of devices available to connect to along with information identifying any change since the last update, if applicable.
|
static interface |
AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver
Receiver for the download activity commands.
|
class |
AntPlusWatchDownloaderPcc.IpcDefines
Defines the keys and values used to communicate between the PCC and plugin.
|
AntPluginPcc.IDeviceStateChangeReceiver, AntPluginPcc.IPluginAccessResultReceiver<T extends AntPluginPcc>
PATH_ANTPLUS_PLUGINS_PKG
Modifier and Type | Method and Description |
---|---|
boolean |
cancelListenForNewActivities(java.util.UUID targetDeviceUUID)
Cancels any listenForNewActivities commands pending for the given device for your application, or cancels all listenForNewActivities commands for all devices if UUID is null.
|
boolean |
listenForNewActivities(java.util.UUID targetDeviceUUID,
AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver,
FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver)
Submits a request to download all new activities from the target device until the request is cancelled.
|
void |
requestCurrentDeviceList()
Requests the current device list.
|
static PccReleaseHandle<AntPlusWatchDownloaderPcc> |
requestDeviceListAccess(Context bindToContext,
AntPluginPcc.IPluginAccessResultReceiver<AntPlusWatchDownloaderPcc> resultReceiver,
AntPluginPcc.IDeviceStateChangeReceiver stateReceiver,
AntPlusWatchDownloaderPcc.IAvailableDeviceListReceiver availableDeviceListRecevier)
Send a request to the plugin for access to receive device list updates and make requests.
|
boolean |
requestDownloadAllActivities(java.util.UUID targetDeviceUUID,
AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver,
FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver,
AntFsCommon.IAntFsProgressUpdateReceiver antFsProgressUpdateRecevier)
Requests a download of all activities from the device.
|
boolean |
requestDownloadNewActivities(java.util.UUID targetDeviceUUID,
AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver,
FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver,
AntFsCommon.IAntFsProgressUpdateReceiver antFsProgressUpdateRecevier)
Requests a download of all new activities from the device.
|
getAntDeviceNumber, getCurrentDeviceState, getDeviceName, getInstalledPluginsVersionNumber, getInstalledPluginsVersionString, getMissingDependencyName, getMissingDependencyPackageName, isUserPreferredDeviceForPlugin, isUserRecognizedDevice, releaseAccess, startPluginManagerActivity
public static PccReleaseHandle<AntPlusWatchDownloaderPcc> requestDeviceListAccess(Context bindToContext, AntPluginPcc.IPluginAccessResultReceiver<AntPlusWatchDownloaderPcc> resultReceiver, AntPluginPcc.IDeviceStateChangeReceiver stateReceiver, AntPlusWatchDownloaderPcc.IAvailableDeviceListReceiver availableDeviceListRecevier)
bindToContext
- The context to which the plugin will be bound. Used for plugin lifecycle management.resultReceiver
- The receiver to receive the results of the request. Possible returns include:
stateReceiver
- The receiver to receive the state updates of the accessed device, if successful.
This receiver will receive notifications of all state changes to the device that occur subsequent
to the initial state returned in the result receiver.availableDeviceListRecevier
- Receives the available device list and updates to that list.
Call requestCurrentDeviceList()
after receiving access to get the current list.public void requestCurrentDeviceList()
#requestDeviceListAccess(Context, IPluginAccessResultReceiver, IDeviceStateChangeReceiver, IAvailableDeviceListReceiver)
.public boolean requestDownloadAllActivities(java.util.UUID targetDeviceUUID, AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver, FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver, AntFsCommon.IAntFsProgressUpdateReceiver antFsProgressUpdateRecevier)
targetDeviceUUID
- The target device to make the request on.downloadActivitiesFinishedReceiver
- The receiver to receive the status of the file download.fitFileDownloadedReceiver
- The receiver to receive each downloaded file from the device as it is downloaded over ANT-FS.antFsProgressUpdateRecevier
- Optional. The receiver to receive the state updates of the ANT-FS connection or null.public boolean requestDownloadNewActivities(java.util.UUID targetDeviceUUID, AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver, FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver, AntFsCommon.IAntFsProgressUpdateReceiver antFsProgressUpdateRecevier)
targetDeviceUUID
- The target device to make the request on.downloadActivitiesFinishedReceiver
- The receiver to receive the status of the file download.fitFileDownloadedReceiver
- The receiver to receive each downloaded file from the device as it is downloaded over ANT-FS.antFsProgressUpdateRecevier
- Optional. The receiver to receive the state updates of the ANT-FS connection or null.public boolean listenForNewActivities(java.util.UUID targetDeviceUUID, AntPlusWatchDownloaderPcc.IDownloadActivitiesFinishedReceiver downloadActivitiesFinishedReceiver, FitFileCommon.IFitFileDownloadedReceiver fitFileDownloadedReceiver)
targetDeviceUUID
- The target device to make the request on.downloadActivitiesFinishedReceiver
- The receiver to receive the status of the file download.fitFileDownloadedReceiver
- The receiver to receive each downloaded file from the device as it is downloaded over ANT-FS.public boolean cancelListenForNewActivities(java.util.UUID targetDeviceUUID)
targetDeviceUUID
- The target device to cancel commands for, or null to cancel all commands from your application.Copyright © 2015 Dynastream Innovations Inc. All Rights Reserved.