FirestoreDocumentModel<T> constructor
FirestoreDocumentModel<T> (
- String path,
- T value
Base class for holding and manipulating data from a firestore database as a document of T
.
You can monitor for real-time updates by running listen().
In addition, since it can be used as Map, it is possible to operate the content as it is.
Implementation
FirestoreDocumentModel(String path, T value)
: assert(
!(path.splitLength() <= 0 || path.splitLength() % 2 != 0),
"The path hierarchy must be an even number: $path",
),
_rawPath = path,
path = path.trimQuery(),
parameters = _getParameters(path),
super(value);