MCPcopy Create free account
hub / github.com/AI45Lab/Code / list

Method list

core/src/commands.rs:180–188  ·  view source on GitHub ↗

Get all registered command names and descriptions.

(&self)

Source from the content-addressed store, hash-verified

178
179 /// Get all registered command names and descriptions.
180 pub fn list(&self) -> Vec<(&str, &str)> {
181 let mut cmds: Vec<_> = self
182 .commands
183 .values()
184 .map(|c| (c.name(), c.description()))
185 .collect();
186 cmds.sort_by_key(|(name, _)| *name);
187 cmds
188 }
189
190 /// Get all registered commands with name, description, and optional usage hint.
191 pub fn list_full(&self) -> Vec<(String, String, Option<String>)> {

Callers 1

test_list_commandsFunction · 0.45

Calls 2

nameMethod · 0.45
descriptionMethod · 0.45

Tested by 1

test_list_commandsFunction · 0.36