public enum NearbyPermission
- Object
- Enum<NearbyPermission>
- NearbyPermission
ImplementsComparable<NearbyPermission>
The runtime permissions the com.codename1.nearby APIs may need, named
by what the app is trying to do rather than by any one platform’s
permission string.
Each entry point takes these as varargs in its requestPermissions
method and maps them to whatever the running platform actually asks for:
on Android a set of manifest permissions, on iOS an authorization prompt
raised by the first call that needs it. A port that needs no permission
for a given constant reports it granted rather than failing.
Enum constants
RANGING | Precision ranging. |
DISCOVERY | Discovering nearby devices to advertise to or range against. |
ADVERTISE | Advertising this device so others can find it. |
CONNECT | Connecting to a discovered device and moving payloads. |
Methods
public static NearbyPermission[] values() | |
public static NearbyPermission valueOf(String name) |
Inherited methods
Enum constant details
RANGING
RANGINGPrecision ranging. Android
UWB_RANGING; on iOS the Nearby
Interaction authorization prompted by the first session.DISCOVERY
DISCOVERYDiscovering nearby devices to advertise to or range against. Android
BLUETOOTH_SCAN plus NEARBY_WIFI_DEVICES (or location below API
33); on iOS the local network authorization.ADVERTISE
ADVERTISEAdvertising this device so others can find it. Android
BLUETOOTH_ADVERTISE; no iOS equivalent.CONNECT
CONNECTConnecting to a discovered device and moving payloads. Android
BLUETOOTH_CONNECT; no iOS equivalent.Method details
values
public static NearbyPermission[] values()valueOf
public static NearbyPermission valueOf(String name)