DeviceCapability

Enum DeviceCapability 

Source
pub enum DeviceCapability {
Show 27 variants Accelerometer, ARKit, Armv7, Arm64, AutoFocusCamera, BluetoothLE, CameraFlash, FrontFacingCamera, GameKit, GPS, Gyroscope, HealthKit, IPhoneIPadMinimumPerformanceA12, LocationServices, Magnetometer, Metal, Microphone, NFC, OpenGLES1, OpenGLES2, OpenGLES3, PeerPeer, SMS, StillCamera, Telephony, VideoCamera, WiFi,
}
Expand description

Device-related feature that an app may require to run.

Variants§

§

Accelerometer

The presence of accelerometers. Use he Core Motion framework to receive accelerometer events. You don’t need to include this value if your app detects only device orientation changes. Available in iOS 3.0 and later.

§

ARKit

Support for ARKit. Available in iOS 11.0 and later.

§

Armv7

Compilation for the armv7 instruction set, or as a 32/64-bit universal app. Available in iOS 3.1 and later.

§

Arm64

Compilation for the arm64 instruction set. Include this key for all 64-bit apps and embedded bundles, like extensions and frameworks. Available in iOS 8.0 and later.

§

AutoFocusCamera

Autofocus capabilities in the device’s still camera. You might need to include this value if your app supports macro photography or requires sharper images to perform certain image-processing tasks. Available in iOS 3.0 and later.

§

BluetoothLE

Bluetooth low-energy hardware. Available in iOS 5.0 and later.

§

CameraFlash

A camera flash. Use the cameraFlashMode property of a UIImagePickerController instance to control the camera’s flash. Available in iOS 3.0 and later.

§

FrontFacingCamera

A forward-facing camera. Use the cameraDevice property of a UIImagePickerController instance to select the device’s camera. Available in iOS 3.0 and later.

§

GameKit

Access to the Game Center service. Enable the Game Center capability in Xcode to add this value to your app. Available in iOS 4.1 and later.

§

GPS

GPS (or AGPS) hardware for tracking locations. If you include this value, you should also include the location-services value. Require GPS only if your app needs location data more accurate than the cellular or Wi-Fi radios provide. Available in iOS 3.0 and later.

§

Gyroscope

A gyroscope. Use the Core Motion framework to retrieve information from gyroscope hardware. Available in iOS 3.0 and later.

§

HealthKit

Support for HealthKit. Available in iOS 8.0 and later.

§

IPhoneIPadMinimumPerformanceA12

Performance and capabilities of the A12 Bionic and later chips. Available in iOS 12.0 and later.

§

LocationServices

Access to the device’s current location using the Core Location framework. This value refers to the general location services feature. If you specifically need GPS-level accuracy, also include the gps feature. Available in iOS 3.0 and later.

§

Magnetometer

Magnetometer hardware. Apps use this hardware to receive heading-related events through the Core Location framework. Available in iOS 3.0 and later.

§

Metal

Support for graphics processing with Metal. Available in iOS 8.0 and later.

§

Microphone

The built-in microphone or accessories that provide a microphone. Available in iOS 3.0 and later.

§

NFC

Near Field Communication (NFC) tag detection and access to messages that contain NFC Data Exchange Format data. Use the Core NFC framework to detect and read NFC tags. Available in iOS 11.0 and later.

§

OpenGLES1

The OpenGL ES 1.1 interface. Available in iOS 3.0 and later.

§

OpenGLES2

The OpenGL ES 2.0 interface. Available in iOS 3.0 and later.

§

OpenGLES3

The OpenGL ES 3.0 interface. Available in iOS 7.0 and later.

§

PeerPeer

Peer-to-peer connectivity over a Bluetooth network. Available in iOS 3.1 and later.

§

SMS

The Messages app. You might require this feature if your app opens URLs with the sms scheme. Available in iOS 3.0 and later.

§

StillCamera

A camera on the device. Use the UIImagePickerController interface to capture images from the device’s still camera. Available in iOS 3.0 and later.

§

Telephony

The Phone app. You might require this feature if your app opens URLs with the tel scheme. Available in iOS 3.0 and later.

§

VideoCamera

A camera with video capabilities on the device. Use the UIImagePickerController interface to capture video from the device’s camera. Available in iOS 3.0 and later.

§

WiFi

Networking features related to Wi-Fi access. Available in iOS 3.0 and later.

Trait Implementations§

Source§

impl Clone for DeviceCapability

Source§

fn clone(&self) -> DeviceCapability

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DeviceCapability

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for DeviceCapability

Source§

fn eq(&self, other: &DeviceCapability) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for DeviceCapability

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl Copy for DeviceCapability

Source§

impl Eq for DeviceCapability

Source§

impl StructuralPartialEq for DeviceCapability

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V