Microsoft.Maui.Devices Namespace

Provides interfaces, classes and supporting types to work with common device functionality across all supported platforms. E.g. battery, vibration, flashlight, etc.

Classes

Battery

Methods and properties for battery and charging information of the device.

BatteryInfoChangedEventArgs

Event arguments containing the current reading of IBattery.

DeviceDisplay

Represents information about the device screen.

DeviceInfo

Represents information about the device.

DisplayInfoChangedEventArgs

Main display information event arguments.

EnergySaverStatusChangedEventArgs

Event arguments when the energy saver status changes.

Flashlight

The Flashlight API has the ability to turn on or off the device's camera flash to turn it into a flashlight.

HapticFeedback

The HapticFeedback API lets you control haptic feedback on the device.

Vibration

The Vibration API provides an easy way to make the device vibrate.

VibrationExtensions

Static class with extension methods for the IVibration APIs.

Structs

DeviceIdiom

Represents the idiom (form factor) of the device.

DevicePlatform

Represents the device platform that the application is running on.

DisplayInfo

Represents information about the device's screen.

Interfaces

IBattery

Methods and properties for battery and charging information of the device.

IDeviceDisplay

Represents information about the device screen.

IDeviceInfo

Represents information about the device.

IFlashlight

The Flashlight API has the ability to turn on or off the device's camera flash to turn it into a flashlight.

IHapticFeedback

The HapticFeedback API lets you control haptic feedback on the device.

IVibration

The Vibration API provides an easy way to make the device vibrate.

Enums

BatteryPowerSource

Enumerates power sources with which the device and battery can be powered or charged.

BatteryState

Describes possible states of the battery.

DeviceType

Types of devices.

DisplayOrientation

Represents the orientation a device display can have.

DisplayRotation

Represents the rotation a device display can have.

EnergySaverStatus

Enumerates states that the energy saver van have on the device.

HapticFeedbackType

Enumerates the possible types of IHapticFeedback response.

Remarks

The functionality in this namespace is formerly known as (Xamarin) Essentials.