FileAssetSource class final

A model on the filesystem. Unavailable on web, which is why it is a separate source rather than a flag.

Inheritance

Constructors

FileAssetSource(String path)
A source reading the file at path.
const

Properties

contentHash → String?
The SHA-256 of the file read returns, as 64 lowercase hexadecimal digits, when the source knows it ahead of reading; null when it does not, which is every source that reads a file it did not publish.
no setterinherited
fileName → String
Everything after the last path separator.
no setterinherited
hashCode → int
The hash code for this object.
no setterinherited
key → String
Stable identity, used as the cache key.
no setteroverride
path → String
The file's path, as the platform's file API takes it.
final
resolveUri → AssetUriResolver
Resolves files referenced from inside the model, relative to its directory.
no setteroverride
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
version → int?
The asset's version in the place it comes from (a model's version on the hub, a store's revision), from 1; null for a source with no versions, which is a file on disk or in a bundle.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
read(AssetRead request) → Future<Uint8List>
The file itself, read as request asks.
override
toString() → String
A string representation of this object.
inherited

Operators

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