Enum Class RequestAccessResult
- All Implemented Interfaces:
Serializable
,Comparable<RequestAccessResult>
,Constable
Result codes for the request access functions
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe Ant Radio Service has reported that there are not ANT adapters present to provide ANT channels.This application is already actively granted access from a previous request.Bad Parameters.The ANT Radio Service reports that no free channels are available.Indicates a dependency was not installed.For plugin device types which do not allow sharing devices this indicates the requested device is already accessed by another application.Indicates there was a critical or unexpected error in the Plugins, check logcat output for details.The search did not find the requested device before the timeout period.Access is granted and the device can now be usedThe value sent by the plugin service was unrecognized indicating an upgrade of the PCC may be required to handle the value.The request was cancelled -
Method Summary
Modifier and TypeMethodDescriptionint
Convert enum to equivalent int valuestatic RequestAccessResult
getValueFromInt
(int intValue) Convert int to equivalent enum valuestatic RequestAccessResult
Returns the enum constant of this class with the specified name.static RequestAccessResult[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
SUCCESS
Access is granted and the device can now be used -
USER_CANCELLED
The request was cancelled -
CHANNEL_NOT_AVAILABLE
The ANT Radio Service reports that no free channels are available. -
OTHER_FAILURE
Indicates there was a critical or unexpected error in the Plugins, check logcat output for details. -
DEPENDENCY_NOT_INSTALLED
Indicates a dependency was not installed. TheAntPluginPcc.getMissingDependencyName()
andAntPluginPcc.getMissingDependencyPackageName()
functions can be used to determine which dependency is missing and prompt the user to install it. -
DEVICE_ALREADY_IN_USE
For plugin device types which do not allow sharing devices this indicates the requested device is already accessed by another application. -
SEARCH_TIMEOUT
The search did not find the requested device before the timeout period. -
ALREADY_SUBSCRIBED
This application is already actively granted access from a previous request. The plugins service only grants one PCC access per application (the PCC must then be released when it is no longer in use). This result indicates a failure and does not return a reference to the active PCC. -
BAD_PARAMS
Bad Parameters.- Since:
- Plugins v.2.1.0 [Older plugins versions will return OTHER_FAILURE or crash instead]
-
ADAPTER_NOT_DETECTED
The Ant Radio Service has reported that there are not ANT adapters present to provide ANT channels.- Since:
- Plugins v.2.1.0 [Older plugins versions will return CHANNEL_NOT_AVAILABLE instead]
-
UNRECOGNIZED
The value sent by the plugin service was unrecognized indicating an upgrade of the PCC may be required to handle the value.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getIntValue
public int getIntValue()Convert enum to equivalent int value- Returns:
- integer value equivalent
-
getValueFromInt
Convert int to equivalent enum value- Parameters:
intValue
- integer to convert- Returns:
- enum value equivalent
-