UIKit.UIDevice.BatteryMonitoringEnabled Property
Controls battery monitoring. When set, you can receive battery level change events.

Syntax

[get: Foundation.Export("isBatteryMonitoringEnabled")]
[set: Foundation.Export("setBatteryMonitoringEnabled:")]
public virtual bool BatteryMonitoringEnabled { get; set; }

Value

The default value is false.

Remarks

When set to the default value of false, applications cannot read the UIDevice.BatteryLevel, UIDevice.BatteryState, or receive battery-state change notifications (UIDevice.BatteryStateDidChangeNotification).

This can be used from a background thread.

Requirements

Namespace: UIKit
Assembly: Xamarin.iOS (in Xamarin.iOS.dll)
Assembly Versions: 0.0.0.0