(
path: string,
info: FileSystem.File.Info,
options?: {
readonly bytesToRead?: FileSystem.SizeInput | undefined
readonly chunkSize?: FileSystem.SizeInput | undefined
readonly offset?: FileSystem.SizeInput | undefined
readonly contentType?: string | undefined
}
)
| 540 | * @since 4.0.0 |
| 541 | */ |
| 542 | export const fileFromInfo = ( |
| 543 | path: string, |
| 544 | info: FileSystem.File.Info, |
| 545 | options?: { |
| 546 | readonly bytesToRead?: FileSystem.SizeInput | undefined |
| 547 | readonly chunkSize?: FileSystem.SizeInput | undefined |
| 548 | readonly offset?: FileSystem.SizeInput | undefined |
| 549 | readonly contentType?: string | undefined |
| 550 | } |
| 551 | ): Effect.Effect<Stream, PlatformError.PlatformError, FileSystem.FileSystem> => |
| 552 | Effect.map( |
| 553 | FileSystem.FileSystem, |
| 554 | (fs) => |
| 555 | stream( |
| 556 | fs.stream(path, options), |
| 557 | options?.contentType, |
| 558 | fileContentLength(info.size, options) |
| 559 | ) |
| 560 | ) |
nothing calls this directly
no test coverage detected