BundleAssetSource class final

A model in the Flutter asset bundle.

Reading the bundle from a background isolate needs the platform channel to be wired up there; decodeModelInIsolate passes the root isolate token that makes that possible.

Named Flutter, which is why it lives here rather than in flutter3d_core (mcp-03n). FileAssetSource, its dart:io sibling, made the move; this is the one AssetSource that could not.

Inheritance

Constructors

BundleAssetSource(String assetPath)
A source for the bundle key assetPath.
const

Properties

assetPath → String
The key the model is declared under in the asset bundle, such as assets/models/crate.f3d; relative URIs inside the model resolve against its directory.
final
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
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>
A generated file (isGeneratedAsset) is read with loadRevalidatedAsset, so on the web a cached copy from an older deploy is never paired with newer code — A4.18.
override
toString() → String
A string representation of this object.
inherited

Operators

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