NitroNullableBool class

Collision-free nullable bool for Nitro bridges.

Wire format: 1B: value (bool) = 2 bytes

Unlike bool? (platform-specific -1/jboolean workarounds), this type works identically on iOS, Android, and macOS with zero platform differences.

Available extensions

Constructors

NitroNullableBool({required bool hasValue, required bool value})
const
NitroNullableBool.fromNullable(bool? v)
factory

Properties

asBool bool?

Available on NitroNullableBool, provided by the NitroNullableBoolExt extension

no setter
hashCode int
The hash code for this object.
no setteroverride
hasValue bool
final
nullable bool?
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value bool
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toNative(Allocator alloc) Pointer<Uint8>

Available on NitroNullableBool, provided by the NitroNullableBoolNative extension

toString() String
A string representation of this object.
override
writeFields(RecordWriterBase writer) → void

Operators

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

Constants

nullValue → const NitroNullableBool