Documentation
¶
Overview ¶
Copyright 2026 Teradata
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Package uicmd provides UI command utilities.
Index ¶
- func FormatHelp(cmd *Command) string
- func Parse(input string) (name string, args []string)
- type Arg
- type ArgType
- type CloseArgumentsDialogMsg
- type Command
- type CommandRunCustomMsg
- type CommandType
- type Handler
- type MCPPrompt
- type Registry
- type ShowArgumentsDialogMsg
- type ShowMCPPromptArgumentsDialogMsg
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Arg ¶
type Arg struct {
Name string
Description string
Required bool
Default string
Type ArgType
Choices []string
}
Arg represents a command argument.
type CloseArgumentsDialogMsg ¶
type CloseArgumentsDialogMsg struct{}
CloseArgumentsDialogMsg is sent to close arguments dialog.
type Command ¶
type Command struct {
Name string
Description string
Title string
Shortcut string
Aliases []string
Args []Arg
Run func(args []string) error
Handler Handler
ID string
}
Command represents a UI command.
func LoadCustomCommands ¶
LoadCustomCommands loads custom commands.
type CommandRunCustomMsg ¶
CommandRunCustomMsg is sent when a custom command is run.
type CommandType ¶
type CommandType int
CommandType represents the type of command.
const ( SystemCommands CommandType = iota UserCommands MCPPrompts )
func (CommandType) String ¶
func (c CommandType) String() string
String returns a string representation of CommandType.
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry holds registered commands.