optionallyProvideExistingFile

fun optionallyProvideExistingFile(resolverReference: ResolverReference, successHandler: (UUID, AvailFile) -> Unit, failureHandler: (ErrorCode, Throwable?) -> Unit): Boolean

Attempt to provide a file if it already exists in this FileManager without directly requesting it be added.

Return

true if file is available and being provided to consumer or false if the file is not present.

Parameters

resolverReference

The ResolverReference that identifies the target file to read.

successHandler

A function that accepts the FileManager.fileCache that uniquely identifies the file and the AvailFile.

failureHandler

A function that accepts a ErrorCode that describes the nature of the failure and an optional Throwable.