From b543735628584d689705c26a3145e57cd5563066 Mon Sep 17 00:00:00 2001 From: Kirill Grachev Date: Mon, 24 Apr 2023 00:37:14 +0300 Subject: [PATCH] SNRK-67: Make implementation private --- .../kotlin/space/kscience/snark/storage/local/LocalDriver.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/snark-storage-driver/src/main/kotlin/space/kscience/snark/storage/local/LocalDriver.kt b/snark-storage-driver/src/main/kotlin/space/kscience/snark/storage/local/LocalDriver.kt index d75db16..324267c 100644 --- a/snark-storage-driver/src/main/kotlin/space/kscience/snark/storage/local/LocalDriver.kt +++ b/snark-storage-driver/src/main/kotlin/space/kscience/snark/storage/local/LocalDriver.kt @@ -10,14 +10,14 @@ public fun localStorage(rootPath: Path): Directory { return LocalDirectory(rootPath, ".") } -public class LocalFile(private val path: String) : FileReader, FileWriter { +private class LocalFile(private val path: String) : FileReader, FileWriter { override fun close() {} override suspend fun readAll(): ByteArray = File(this.path).readBytes() override suspend fun write(bytes: ByteArray) = File(this.path).writeBytes(bytes) } -public class LocalDirectory(private val root: Path, path: String) : Directory { +private class LocalDirectory(private val root: Path, path: String) : Directory { private val current = "$root/$path" private fun child(child: String): String = "$current/$child"