Commander-API  V2.1.0
Simple Command Parser
Loading...
Searching...
No Matches
Commander-API.hpp File Reference
#include "stdint.h"
#include "string.h"
#include "Commander-Settings.hpp"
#include "Commander-IO.hpp"
#include "Arduino.h"
#include "Stream.h"
#include <ESP8266WiFi.h>
#include <WiFi.h>
#include <avr/pgmspace.h>

Go to the source code of this file.

Classes

class  Commander
 Commander class. More...
 
struct  Commander::API_t
 Structure for command data. More...
 

Macros

#define COMMANDER_API_VERSION   (const char*)"2.1.0"
 
#define apiElement(name, desc, func)   { 0, NULL, NULL, (const char*)name, (const char*)desc, func }
 Arduino detection. More...
 
#define apiElement_P(element, name, desc, func_arg)   { element.name_P = F( name ); element.desc_P = F( desc ); element.func = func_arg; }
 This macro simplifies the API element creation for PROGMEM implementation. More...
 
#define attachTree(name)   attachTreeFunction( name, sizeof( name ) / sizeof( name[ 0 ] ) )
 This macro simplifies the attachment of the API-tree. More...
 

Macro Definition Documentation

◆ apiElement

#define apiElement (   name,
  desc,
  func 
)    { 0, NULL, NULL, (const char*)name, (const char*)desc, func }

Arduino detection.

This macro simplifies the API element creation.

With this macro you can fill the API tree structure easily.

Definition at line 70 of file Commander-API.hpp.

◆ apiElement_P

#define apiElement_P (   element,
  name,
  desc,
  func_arg 
)    { element.name_P = F( name ); element.desc_P = F( desc ); element.func = func_arg; }

This macro simplifies the API element creation for PROGMEM implementation.

With this macro you can fill the API tree structure easily. It is used for PROGMEM implementation.

Definition at line 78 of file Commander-API.hpp.

◆ attachTree

#define attachTree (   name)    attachTreeFunction( name, sizeof( name ) / sizeof( name[ 0 ] ) )

This macro simplifies the attachment of the API-tree.

With this macro you can attach the API-tree to the class easier and faster than with attachTreeFunction.

Definition at line 86 of file Commander-API.hpp.

◆ COMMANDER_API_VERSION

#define COMMANDER_API_VERSION   (const char*)"2.1.0"

Definition at line 38 of file Commander-API.hpp.