MyPlatform class sealed

Available extensions
Annotations
  • @freezed

Constructors

MyPlatform.android()
const
factory
MyPlatform.fuchsia()
const
factory
MyPlatform.ios()
const
factory
MyPlatform.linux()
const
factory
MyPlatform.macos()
const
factory
MyPlatform.web()
const
factory
MyPlatform.windows()
const
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
isAndroid bool

Available on MyPlatform, provided by the MyPlatformEx extension

no setter
isDesktop bool

Available on MyPlatform, provided by the MyPlatformEx extension

no setter
isIos bool

Available on MyPlatform, provided by the MyPlatformEx extension

判断是否为 ios 平台
no setter
isMacos bool

Available on MyPlatform, provided by the MyPlatformEx extension

no setter
isMobile bool

Available on MyPlatform, provided by the MyPlatformEx extension

no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
runInAndroid(VoidCallback call) Future<void>

Available on MyPlatform, provided by the MyPlatformEx extension

runInAndroidAndIos<T>(Future<T> call()) Future<T?>

Available on MyPlatform, provided by the MyPlatformEx extension

runInAndroidAndIos2<T>({Future<T?> ios()?, Future<T?> android()?}) Future<T?>

Available on MyPlatform, provided by the MyPlatformEx extension

runInAndroidAndIos3<T>({T? ios()?, T? android()?}) → T?

Available on MyPlatform, provided by the MyPlatformEx extension

runInIos(VoidCallback call) Future<void>

Available on MyPlatform, provided by the MyPlatformEx extension

toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited