MCPcopy Create free account
hub / github.com/SoarGroup/Soar / HandleSendClientMessage

Method HandleSendClientMessage

Core/KernelSML/src/sml_KernelSMLHandlers.cpp:659–673  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

657}
658
659bool KernelSML::HandleSendClientMessage(AgentSML* pAgentSML, char const* pCommandName, Connection* pConnection, AnalyzeXML* pIncoming, soarxml::ElementXML* pResponse)
660{
661 // Get the parameters
662 char const* pMessageType = pIncoming->GetArgString(sml_Names::kParamName) ;
663 char const* pMessage = pIncoming->GetArgString(sml_Names::kParamMessage) ;
664
665 if (!pMessageType || !pMessage)
666 {
667 return InvalidArg(pConnection, pResponse, pCommandName, "Require a message type and a message and one is missing") ;
668 }
669
670 std::string result = this->SendClientMessage(pAgentSML, pMessageType, pMessage) ;
671
672 return ReturnResult(pConnection, pResponse, result.c_str()) ;
673}
674
675// Prevent a particular event from firing when it next would normally do so
676bool KernelSML::HandleSuppressEvent(AgentSML* /*pAgentSML*/, char const* pCommandName, Connection* pConnection, AnalyzeXML* pIncoming, soarxml::ElementXML* pResponse)

Callers

nothing calls this directly

Calls 2

SendClientMessageMethod · 0.95
GetArgStringMethod · 0.80

Tested by

no test coverage detected