HardwareException class

Exception thrown when a native hardware operation fails.

Implemented types
Implementers

Constructors

HardwareException({required HardwareErrorCode code, required String message, Object? details})
Base constructor for hardware exceptions.
const
HardwareException.fromPlatformException(PlatformException error)
Maps a native PlatformException into a specialized HardwareException.
factory
HardwareException.unsupported(String feature)
Creates a specific unsupported exception subclass.
factory

Properties

code HardwareErrorCode
The standardized error code for the failure.
final
details Object?
Optional platform-specific details regarding the error.
final
hashCode int
The hash code for this object.
no setterinherited
isPermissionDenied bool
Checks if this exception indicates missing permissions.
no setter
isUnsupported bool
Checks if this exception indicates the feature is not supported.
no setter
message String
A human-readable description of the error.
final
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
toString() String
A string representation of this object.
override

Operators

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