Accessor

An accessor that allows for easier FS manipulations

Functions

Link copied to clipboard
fun access(relative: String): Path

Returns the path relative to the current FS path (usually $server_path/macrocosm)

Link copied to clipboard
fun init()

Initializes the accessor.

Link copied to clipboard
inline fun overwrite(file: String, crossinline writer: (DataOutputStream) -> Unit = { })

Overwrites the file with the provided writer, deleting it if it exists

fun overwrite(file: String, value: String)

Overwrites the file, deleting it if it exists

Link copied to clipboard

Reads the file data only if file exists, and wraps the result in ConditionalValueCallback

Properties

Link copied to clipboard

True if Macrocosm has not started before