Fragment class Null safety Document

Provides readonly access to data value.

Fragment also provides subscript access by either key or index to the nested values which are wrapped by Fragment objects.

Implemented types
Implementers

Constructors

Fragment()

Properties

array Array?
The value of this fragment as an Array.
read-only, inherited
blob Blob?
The value of this fragment as a Blob.
read-only, inherited
boolean bool
The value of this fragment as a bool.
read-only, inherited
date DateTime?
The value of this fragment as a DateTime.
read-only, inherited
dictionary Dictionary?
The value of this fragment as a Dictionary.
read-only, inherited
exists bool
Whether the value of this fragment exists.
read-only, inherited
float double
The value of this fragment as a floating point number.
read-only, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
integer int
The value of this fragment as an integer number.
read-only, inherited
number num?
The value of this fragment as a num.
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
string String?
The value of this fragment as a String.
read-only, inherited
value Object?
The value of this fragment.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
A string representation of this object. [...]
inherited
valueAs<T extends Object>() → T?
The value of this fragment as a value of type T.
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited
operator [](Object indexOrKey) Fragment
Returns a Fragment for the value at the given index.
override