MCPcopy Create free account
hub / github.com/DanielOgorchock/ST_Anything / addExecutor

Method addExecutor

Arduino/libraries/ST_Anything/Everything.cpp:285–311  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

283 }
284
285 bool Everything::addExecutor(Executor *executor)
286 {
287 if(m_nExecutorCount>=Constants::MAX_EXECUTOR_COUNT)
288 {
289 if(debug)
290 {
291 Serial.print(F("Did not add executor named "));
292 Serial.print(executor->getName());
293 Serial.println(F("(You've exceeded maximum number of executors; edit Constants.h)"));
294 }
295 return false;
296 }
297 else
298 {
299 m_Executors[m_nExecutorCount]=executor;
300 ++m_nExecutorCount;
301 }
302
303 if(debug)
304 {
305 Serial.print(F("Everything: adding executor named "));
306 Serial.println(executor->getName());
307 Serial.print(F("Everything: Free RAM = "));
308 Serial.println(freeRam());
309 }
310 return true;
311 }
312
313 //friends!
314 void receiveSmartString(String message)

Callers

nothing calls this directly

Calls 4

freeRamFunction · 0.85
printMethod · 0.80
getNameMethod · 0.80
printlnMethod · 0.80

Tested by

no test coverage detected