FileMetadata class

Describes a file stored by Nhost.

The fields of this class can be used to fetch the file's contents (key), as well as populate the headers of an HttpResponse if you were to serve this file to a client.

Constructors

FileMetadata({required String key, String? acceptRanges, DateTime? lastModified, int? contentLength, String? eTag, String? contentType, FileNhostMetadata? nhostMetadata})

Properties

acceptRanges String?
accept-ranges value for HTTP response header
final
contentLength int?
content-length value for HTTP response header
final
contentType String?
content-type value for HTTP response header
final
eTag String?
etag value for HTTP response header
final
hashCode int
The hash code for this object.
no setterinherited
key String
Path to file
final
lastModified DateTime?
last-modified value for HTTP response header
final
nhostMetadata FileNhostMetadata?
Additional Nhost-specific metadata associated with this file
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

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

Static Methods

fromJson(dynamic json) FileMetadata