GraphMine

graphmine-core / io.github.sof3.graphmine.command.args / StringArg

StringArg

class StringArg : CommandArg<String>

Accepts the next value in the line. Multi-word arguments can be quoted by "" or their spaces escaped by \ before.

Constructors

<init> StringArg()
Accepts the next value in the line. Multi-word arguments can be quoted by "" or their spaces escaped by \ before.

Inherited Properties

default var default: T?
Sets the default value of the command. Implicitly sets optional to true (even if the set value is null)
optional var optional: Boolean
Whether the command arg can be skipped
value lateinit var value: T
The received value of the argument

Functions

parse fun parse(parser: FormattedStringReader): String?
Reads the next value in the parser into the value for the argument

Inherited Functions

accept fun accept(parser: FormattedStringReader): Boolean
Reads the next value in the parser into the value for the argument.
default fun default(value: T): CommandArg<T>
Sets the default value of the command. Implicitly sets optional to true (even if the set value is null)
provideDelegate open fun provideDelegate(thisRef: Overload, property: KProperty<*>): ReadOnlyProperty<Overload, T>