Resource

class Resource(resourcePath: String, inputStream: InputStream = ResourceLoader.getResourceAsStream(resourcePath) ?: throw IllegalStateException("Resource $resourcePath not found."))(source)

Constructors

Link copied to clipboard
constructor(resourcePath: String, inputStream: InputStream = ResourceLoader.getResourceAsStream(resourcePath) ?: throw IllegalStateException("Resource $resourcePath not found."))

Properties

Link copied to clipboard
val file: File

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Resource.asLines(charset: Charset = Charsets.UTF_8): Sequence<String>
Link copied to clipboard
fun Resource.asReader(charset: Charset = Charsets.UTF_8): InputStreamReader
Link copied to clipboard
fun Resource.asText(charset: Charset = Charsets.UTF_8): String