Esempio n. 1
0
smlRunState Agent::GetRunState()
{
	AnalyzeXML response ;

	bool ok = GetConnection()->SendAgentCommand(&response, sml_Names::kCommand_GetRunState, GetAgentName(), sml_Names::kParamValue, sml_Names::kParamRunState) ;

	if (!ok)
		return smlRunState(0) ;

	return smlRunState(response.GetResultInt(0)) ;
}
Esempio n. 2
0
int Agent::GetDecisionCycleCounter()
{
	AnalyzeXML response ;

	bool ok = GetConnection()->SendAgentCommand(&response, sml_Names::kCommand_GetRunState, GetAgentName(), sml_Names::kParamValue, sml_Names::kParamDecision) ;

	if (!ok)
		return 0 ;

	return response.GetResultInt(0) ;
}
Esempio n. 3
0
smlPhase Agent::GetCurrentPhase()
{
	AnalyzeXML response ;

	bool ok = GetConnection()->SendAgentCommand(&response, sml_Names::kCommand_GetRunState, GetAgentName(), sml_Names::kParamValue, sml_Names::kParamPhase) ;

	if (!ok)
		return sml_INPUT_PHASE ;

	smlPhase phase = smlPhase(response.GetResultInt(int(sml_INPUT_PHASE))) ;

	return phase ;
}
Esempio n. 4
0
smlRunResult Agent::GetResultOfLastRun()
{
	AnalyzeXML response ;

	bool ok = GetConnection()->SendAgentCommand(&response, sml_Names::kCommand_GetResultOfLastRun, GetAgentName()) ;

	if (!ok)
		return sml_RUN_ERROR ;

	smlRunResult result = smlRunResult(response.GetResultInt(int(sml_RUN_ERROR))) ;

	return result ;
}