Table of Contents

Class ParsedCommand

Namespace
MiniTui
Assembly
MiniTui.dll

A parsed command with name and arguments.

public record ParsedCommand : IEquatable<ParsedCommand>
Inheritance
ParsedCommand
Implements
Inherited Members

Constructors

ParsedCommand(string, string[], string)

A parsed command with name and arguments.

public ParsedCommand(string Name, string[] Args, string Raw)

Parameters

Name string
Args string[]
Raw string

Properties

Args

public string[] Args { get; init; }

Property Value

string[]

ArgsAsString

Get all arguments as a single string (useful for commands like ":add person note text here").

public string ArgsAsString { get; }

Property Value

string

Name

public string Name { get; init; }

Property Value

string

Raw

public string Raw { get; init; }

Property Value

string

Methods

GetArg(int)

Get argument at index, or null if not present.

public string? GetArg(int index)

Parameters

index int

Returns

string

GetArgsFrom(int)

Get all arguments starting from index as a single string.

public string? GetArgsFrom(int index)

Parameters

index int

Returns

string

Parse(string)

Parse a colon-prefixed command string (e.g., ":add self Fixed bug"). Returns null if the input doesn't start with a colon.

public static ParsedCommand? Parse(string input)

Parameters

input string

Returns

ParsedCommand