UnusedAssetItem class

Represents an unused asset file discovered during auditing.

Constructors

UnusedAssetItem({required String path, required String packageRelativePath, required String absolutePath, required String fileUri, required int sizeInBytes, required String sizeFormatted, required AssetCategory category, required PackageDescriptor ownerPackage, required bool isExplicitInPubspec})
Creates a new UnusedAssetItem.

Properties

absolutePath → String
Absolute file system path.
final
category → AssetCategory
Category of the asset.
final
fileUri → String
Clickable file:// URI string for IDE navigation.
final
hashCode → int
The hash code for this object.
no setterinherited
isExplicitInPubspec → bool
Whether this specific file was explicitly listed by full path in pubspec.yaml.
final
ownerPackage → PackageDescriptor
The package owning this asset.
final
packageRelativePath → String
File path relative to the owning package root.
final
path → String
File path relative to the root workspace.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sizeFormatted → String
Human-readable formatted size (e.g. 1.45 MB, 320.0 KB).
final
sizeInBytes → int
Size of the asset file in bytes.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
Serializes the unused asset item into a JSON-compatible map.
toString() → String
A string representation of this object.
inherited

Operators

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