MCPcopy Index your code
hub / github.com/endbasic/endbasic / new

Method new

std/src/console/cmds.rs:63–72  ·  view source on GitHub ↗

Creates a new `CLS` command that clears the `console`.

(console: Rc<RefCell<dyn Console>>)

Source from the content-addressed store, hash-verified

61impl ClsCommand {
62 /// Creates a new `CLS` command that clears the `console`.
63 pub fn new(console: Rc<RefCell<dyn Console>>) -> Rc<Self> {
64 Rc::from(Self {
65 metadata: CallableMetadataBuilder::new("CLS")
66 .with_syntax(&[(&[], None)])
67 .with_category(CATEGORY)
68 .with_description("Clears the screen.")
69 .build(),
70 console,
71 })
72 }
73}
74
75#[async_trait(?Send)]

Callers

nothing calls this directly

Calls 6

with_descriptionMethod · 0.80
with_categoryMethod · 0.80
with_syntaxMethod · 0.80
with_return_typeMethod · 0.80
with_asyncMethod · 0.80
buildMethod · 0.45

Tested by

no test coverage detected