MCPcopy Create free account
hub / github.com/daniele77/cli / Exec

Method Exec

include/cli/cli.h:835–845  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

833 }
834
835 bool Exec(const std::vector< std::string >& cmdLine, CliSession& session) override
836 {
837 if (!IsEnabled()) return false;
838 assert(!cmdLine.empty());
839 if (Name() == cmdLine[0])
840 {
841 func(session.OutStream(), std::vector<std::string>(std::next(cmdLine.begin()), cmdLine.end()));
842 return true;
843 }
844 return false;
845 }
846 void Help(std::ostream& out) const override
847 {
848 if (!IsEnabled()) return;

Callers

nothing calls this directly

Calls 1

OutStreamMethod · 0.80

Tested by

no test coverage detected