devices property

List<CaptureDevice> devices
final

A list of currently available devices matching the session’s criteria.

This property contains only capture devices that are currently available and that meet the criteria you specified when creating the device discovery session with discoverySessionWithDeviceTypes.

In iOS 11.0 and later, the order of this list matches that of the deviceTypes parameter that you used to create the discovery session, so you can quickly choose a device matching your preferred types (see Sort and Filter Devices with a Discovery Session). In older iOS versions, search the entire array to find preferred devices.

Implementation

final List<CaptureDevice> devices;