FullLcpResource class Null safety

A LCP resource that is read, decrypted and cached fully before reading requested ranges.

Can be used when it's impossible to map a read range (byte range request) to the encrypted resource, for example when the resource is deflated before encryption.

Inheritance

Constructors

FullLcpResource(Resource resource, LcpLicense license)

Properties

file File?
Direct file to this resource, when available.
read-onlyinherited
hashCode int
The hash code for this object.
read-onlyinherited
license LcpLicense
final
resource Resource
finalinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited

Methods

bytes() Future<ResourceTry<ByteData>>
inherited
cached() Resource
Creates a cached resource wrapping this resource.
inherited
close() Future<void>
Closes any opened file handles.
inherited
length() Future<ResourceTry<int>>
Returns data length from metadata if available, or calculated from reading the bytes otherwise.
override
Returns the link from which the resource was retrieved.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
read({IntRange? range}) Future<ResourceTry<ByteData>>
Reads the bytes at the given range.
inherited
readAsJson() Future<ResourceTry<Map<String, dynamic>>>
Reads the full content as a JSON object.
inherited
readAsString({String? charset}) Future<ResourceTry<String>>
Reads the full content as a String.
inherited
readAsXml() Future<ResourceTry<XmlDocument>>
Reads the full content as an XML document.
inherited
toString() String
A string representation of this object.
inherited
transform(ResourceTry<ByteData> data) Future<ResourceTry<ByteData>>
override
use<R>(Future<R> block(Resource resource)) Future<R>
Executes the given block function on this resource and then closes it down correctly whether an exception is thrown or not.
inherited

Operators

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