Companion

object Companion

Properties

Link copied to clipboard
const val CHUNK_SIZE: Int = 8192

The maximum chunk size is 8192 bytes, because file channel mallocs a native buffer outside of stack if the write buffer size is larger.

Functions

Link copied to clipboard
fun listAll(dir: Path): Array<String>
Link copied to clipboard
fun open(path: Path, lockFactory: LockFactory = FSLockFactory.default): FSDirectory

Creates an FSDirectory instance, trying to pick the best implementation given the current environment. The directory returned uses the NativeFSLockFactory. The directory is created at the named location if it does not yet exist.