UnitsOverride

The user's in-app units choice. SYSTEM follows the OS locale; the other two force one system everywhere.

This exists because following the OS is not reachable for everyone: One UI ships no regional-preferences page, some OEM builds offer no region choice at all (#6840), the UK's CLDR data is imperial for every length usage even though altitude there is conventionally metres, and Android 16's Measurement system setting never reaches devices that stopped at 15. The override is the escape hatch those users cannot get from the platform.

Entries

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Returns a representation of an immutable list of all enum entries, in the order they're declared.

Link copied to clipboard
expect val name: String
Link copied to clipboard
expect val ordinal: Int
Link copied to clipboard
val value: Int

Functions

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared.