[klibs] Allow resolving klibs which names are not valid file names

This commit is contained in:
Ilya Matveev
2020-04-17 12:42:18 +07:00
parent 3a99b3d5a4
commit 5f53986f47
2 changed files with 48 additions and 20 deletions
@@ -19,6 +19,7 @@ import java.nio.file.attribute.BasicFileAttributes
data class File constructor(internal val javaPath: Path) {
constructor(parent: Path, child: String): this(parent.resolve(child))
constructor(parent: File, child: String): this(parent.javaPath.resolve(child))
constructor(parent: File, child: File): this(parent.javaPath.resolve(child.javaPath))
constructor(path: String): this(Paths.get(path))
constructor(parent: String, child: String): this(Paths.get(parent, child))