From a382841dc7d554b2ba3920d52f73e4cec428743e Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Mon, 12 Aug 2019 16:01:51 +0200 Subject: Basic parser functions --- src/Loader.kt | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/Loader.kt (limited to 'src/Loader.kt') diff --git a/src/Loader.kt b/src/Loader.kt new file mode 100644 index 0000000..2161c51 --- /dev/null +++ b/src/Loader.kt @@ -0,0 +1,12 @@ +import java.io.File +import java.io.InputStream + +class Loader(path: String) { + private val inputStream: InputStream = File(path).inputStream() + private val inputString = inputStream.bufferedReader().use { it.readText() } + + // TODO: Add preprocessor managing imports + fun load(): String { + return inputString + } +} \ No newline at end of file -- cgit v1.2.3