RiveFile class
Constructors
- RiveFile.import(ByteData bytes, {@Deprecated('Use `assetLoader` instead.') FileAssetResolver? assetResolver, FileAssetLoader? assetLoader, bool loadCdnAssets = true})
-
Imports a Rive file from an array of bytes.
factory
Properties
-
artboards
→ List<
Artboard> -
Returns all artboards in the file
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- header → RuntimeHeader
-
Contains the RiveFile's version information.
final
- mainArtboard → Artboard
-
Returns the first (main) artboard
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
artboardByName(
String name) → Artboard? - Returns an artboard from the specified name, or null if no artboard with that name exists in the file
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
-
indexToField
→ List<
CoreFieldType< Object> > -
final
Static Methods
-
asset(
String bundleKey, {AssetBundle? bundle, FileAssetLoader? assetLoader, bool loadCdnAssets = true}) → Future< RiveFile> - Imports a Rive file from an asset bundle.
-
file(
String path, {FileAssetLoader? assetLoader, bool loadCdnAssets = true}) → Future< RiveFile> - Imports a Rive file from local path
-
initializeText(
) → Future< void> - Initialize Rive's text engine if it hasn't been yet.
-
needsTextRuntime(
ByteData bytes) → bool -
network(
String url, {Map< String, String> ? headers, FileAssetResolver? assetResolver, FileAssetLoader? assetLoader, bool loadCdnAssets = true}) → Future<RiveFile> -
Imports a Rive file from a
url
over HTTP.