C, E printing, etc.
This commit is contained in:
@@ -93,6 +93,13 @@ std::string FormRSCTLK::toStr(void) const
|
||||
else if (oper == RSCTLK_UK) {
|
||||
return "K[" + getSingleAgent() + "](" + arg[0]->toStr() + ")";
|
||||
}
|
||||
else if (oper == RSCTLK_NC) {
|
||||
return "NC[" + getAgentsStr() + "](" + arg[0]->toStr() + ")";
|
||||
}
|
||||
else if (oper == RSCTLK_UC) {
|
||||
return "C[" + getAgentsStr() + "](" + arg[0]->toStr() + ")";
|
||||
}
|
||||
|
||||
|
||||
else {
|
||||
return "??";
|
||||
@@ -252,6 +259,21 @@ void FormRSCTLK::encodeActions(const SymRS *srs)
|
||||
}
|
||||
}
|
||||
|
||||
std::string FormRSCTLK::getAgentsStr(void) const
|
||||
{
|
||||
std::string r = "";
|
||||
bool first = true;
|
||||
for (const auto &a : agents)
|
||||
{
|
||||
if (first)
|
||||
first = false;
|
||||
else
|
||||
r += " ";
|
||||
r += a;
|
||||
}
|
||||
return r;
|
||||
}
|
||||
|
||||
ProcSet FormRSCTLK::getAgentsAsProcSet(RctSys *rs) const
|
||||
{
|
||||
ProcSet processes;
|
||||
|
||||
@@ -292,6 +292,7 @@ class FormRSCTLK
|
||||
assert(oper == RSCTLK_NK || oper == RSCTLK_UK);
|
||||
return *(agents.begin());
|
||||
}
|
||||
std::string getAgentsStr(void) const;
|
||||
ProcSet getAgentsAsProcSet(RctSys *rs) const;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user