
Facilitates efficient read-only random access to binary data with suspend and blocking APIs. Offers platform-specific implementations and compatibility with existing APIs, including ByteBuffer and InputStream.
[!CAUTION] ⚠ Work-In-Progress. API may be not completely stable yet!
Benchmarks and complete test coverage are coming.
// in the `build.gradle.kts` of the target module.
plugins {
kotlin("multiplatform") version "2.0.21"
}
dependencies {
implementation("io.github.fluxo-kt:fluxo-io:0.1.0") // <-- add here
}You can also use snapshots from Maven Central or JitPack:
Library provides cross-platform RandomAccessData
abstraction for effective read-only random access to binary data.
Both suspend and blocking APIs are provided.
Different platform-specific implementations are provided.
[!TIP] For JVM and Android, compatibility with
ByteBufferreads and writes is provided.
AnInputStreamview is also provided for compatibility with existing APIs.
| API | Platform | Supported for |
|---|---|---|
| ByteArray | All | All |
| ByteBuffer | JVM, Android | JVM, Android |
|
ByteBufferMmap (memory-mapped file) |
JVM, Android | JVM, Android |
| FileChannel | JVM, Android | JVM, Android |
| RandomAccessFile | JVM, Android | JVM, Android |
| SeekableByteChannel | JVM, Android | JVM, Android |
| () -> InputStream Factory | JVM, Android | JVM, Android |
| () -> DataInput Factory | JVM, Android | JVM, Android |
| () -> ReadableByteChannel Factory | JVM, Android | JVM, Android |
| AsynchronousFileChannel | JVM, Android | JVM, Android |
[!IMPORTANT] For using AsynchronousFileChannel, you need to add Kotlin Coroutines dependency to your project.
The first steps of the implementation were dated 2021-03-31 (2d87ec044f5801cd3ad8cc31ac380b17fa31d44a).
Open-source since 2024-06-16.
Uses SemVer for versioning.
For the versions available, see the tags on this repository.
This project is licensed under the Apache License, Version 2.0 — see the license file for details.
[!CAUTION] ⚠ Work-In-Progress. API may be not completely stable yet!
Benchmarks and complete test coverage are coming.
// in the `build.gradle.kts` of the target module.
plugins {
kotlin("multiplatform") version "2.0.21"
}
dependencies {
implementation("io.github.fluxo-kt:fluxo-io:0.1.0") // <-- add here
}You can also use snapshots from Maven Central or JitPack:
Library provides cross-platform RandomAccessData
abstraction for effective read-only random access to binary data.
Both suspend and blocking APIs are provided.
Different platform-specific implementations are provided.
[!TIP] For JVM and Android, compatibility with
ByteBufferreads and writes is provided.
AnInputStreamview is also provided for compatibility with existing APIs.
| API | Platform | Supported for |
|---|---|---|
| ByteArray | All | All |
| ByteBuffer | JVM, Android | JVM, Android |
|
ByteBufferMmap (memory-mapped file) |
JVM, Android | JVM, Android |
| FileChannel | JVM, Android | JVM, Android |
| RandomAccessFile | JVM, Android | JVM, Android |
| SeekableByteChannel | JVM, Android | JVM, Android |
| () -> InputStream Factory | JVM, Android | JVM, Android |
| () -> DataInput Factory | JVM, Android | JVM, Android |
| () -> ReadableByteChannel Factory | JVM, Android | JVM, Android |
| AsynchronousFileChannel | JVM, Android | JVM, Android |
[!IMPORTANT] For using AsynchronousFileChannel, you need to add Kotlin Coroutines dependency to your project.
The first steps of the implementation were dated 2021-03-31 (2d87ec044f5801cd3ad8cc31ac380b17fa31d44a).
Open-source since 2024-06-16.
Uses SemVer for versioning.
For the versions available, see the tags on this repository.
This project is licensed under the Apache License, Version 2.0 — see the license file for details.