operatingSystem top-level property

String get operatingSystem

Identification of the current operating system or platform.

Specific known operating systems are reported by a unique known string, and all the is<Name> values are computed by comparing the operatingSystem string against those known strings. That means that at most one of those value can be true, and usually precisely one will be true.

Notice: Programs running in a browser will report their operating system as "browser", not the operating system that browser is running on. See isBrowser.

Implementation

String get operatingSystem => OperatingSystem.current.id;