AssetLoaderException class
An exception thrown when an asset cannot be loaded by the JetLeaf bundler.
This exception typically occurs when trying to read or resolve a file that does not exist, is inaccessible, or fails during the bundling process.
The assetPath provides the full relative or absolute path of the asset
that failed to load, and the optional cause
can point to the underlying
exception that triggered the failure.
Example usage:
throw AssetLoaderException('Failed to load template', 'templates/home.html');
Constructors
- AssetLoaderException(String message, String assetPath, {Object? cause})
- An exception thrown when an asset cannot be loaded by the JetLeaf bundler.
Properties
- assetPath → String
-
The full path to the asset that could not be loaded.
final
- cause → Object?
-
The underlying cause of this exception, if any.
finalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- message → String
-
The message describing the error.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stackTrace → StackTrace
-
The associated stack trace.
finalinherited
Methods
-
getCause(
) → Object -
The cause of this exception, if any.
inherited
-
getMessage(
) → String -
The message associated with this exception.
inherited
-
getStackTrace(
) → StackTrace -
The stack trace associated with this exception.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String - Returns a human-readable string representation of the exception, including the asset path and the underlying cause, if present.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited