StorageObject class

Reference to a Cloud Storage object.

Inheritance

Properties

bucket → Bucket
Bucket this entry belongs to.
finalinherited
delimiter → String
Delimiter that defines the virtual directory tree for this item.
finalinherited
hashCode → int
The hash code for this object.
no setterinherited
isDirectory → bool
True for Prefix, false for StorageObject.
no setteroverride
isObject → bool
True for StorageObject, false for Prefix.
no setterinherited
name → String
Object name, or common-prefix string (usually ends with the delimiter).
finalinherited
parent → Prefix?
Parent Prefix in this item's delimiter hierarchy, or null at the root / when delimiter is empty (flat listing — no hierarchy).
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

copy(StorageObject destination, {String? contentType, String? contentEncoding, String? cacheControl, String? contentDisposition, String? contentLanguage, Map<String, String>? metadata}) → Future<ObjectInfo>
Copies this object to destination.
createDownloadURL() → Future<Uri>
Creates a new Firebase download token and returns its download URL.
delete() → Future<void>
Deletes this object.
exists() → Future<bool>
Whether this object exists.
getDownloadURL() → Future<Uri>
Returns the Firebase download URL for this object.
getSignedUrl({SignedUrlAction action = SignedUrlAction.read, required Duration expires, String? contentType, Map<String, String>? headers, Map<String, String>? queryParams}) → Future<Uri>
Creates a V4 signed URL for this object.
info() → Future<ObjectInfo>
Looks up metadata for this object.
listDownloadURLs() → Future<List<Uri>>
Lists all Firebase download URLs for this object (may be empty).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
read({int? offset, int? length}) → Stream<List<int>>
Reads this object's content as a byte stream.
revokeDownloadURL([Uri? url]) → Future<void>
Revokes Firebase download URL access for this object.
toString() → String
A string representation of this object.
inherited
updateMetadata({String? contentType, String? contentEncoding, String? cacheControl, String? contentDisposition, String? contentLanguage, Map<String, String>? metadata}) → Future<ObjectInfo>
Updates mutable metadata for this object.
write({int? length, String contentType = 'application/octet-stream', Map<String, String>? metadata}) → ObjectWriteSink
Opens a sink to write this object's content, replacing any existing object.
writeBytes(List<int> bytes, {String contentType = 'application/octet-stream', Map<String, String>? metadata}) → Future<ObjectInfo>
Writes bytes as this object's content, replacing any existing object.

Operators

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