mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-26 00:00:02 +02:00
added function to read depreciated commands
This commit is contained in:
parent
d93fd4c655
commit
139db216fe
@ -51,4 +51,10 @@ int main() {
|
||||
auto help = replace_all(tmp, "\n\t", "\n\t\t| ");
|
||||
fs << '\t' << cmd << usage << help << "\n";
|
||||
}
|
||||
|
||||
std::ofstream fs2("depreciated.txt");
|
||||
auto cmds = proxy.GetDepreciatedCommands();
|
||||
for (auto it : cmds){
|
||||
fs2 << it.first << ", " << it.second << '\n';
|
||||
}
|
||||
}
|
||||
|
@ -74,6 +74,10 @@ std::vector<std::string> CmdProxy::GetProxyCommands() {
|
||||
return commands;
|
||||
}
|
||||
|
||||
std::map<std::string, std::string> CmdProxy::GetDepreciatedCommands(){
|
||||
return depreciated_functions;
|
||||
}
|
||||
|
||||
void CmdProxy::WrongNumberOfParameters(size_t expected) {
|
||||
throw RuntimeError(
|
||||
"Command " + cmd + " expected <=" + std::to_string(expected) +
|
||||
|
@ -534,6 +534,7 @@ class CmdProxy {
|
||||
bool ReplaceIfDepreciated(std::string &command);
|
||||
size_t GetFunctionMapSize() const noexcept { return functions.size(); };
|
||||
std::vector<std::string> GetProxyCommands();
|
||||
std::map<std::string, std::string> GetDepreciatedCommands();
|
||||
|
||||
private:
|
||||
Detector *det;
|
||||
|
Loading…
x
Reference in New Issue
Block a user