esphome-api-client 0.5.0
Modern C++17 client for the ESPHome native API (plaintext + Noise)
Loading...
Searching...
No Matches
Classes | Namespaces | Enumerations | Functions
model.hpp File Reference

protogen AST for the proto3 subset the ESPHome native API uses — populated by the parser, consumed by the emitters. More...

#include <cstdint>
#include <string>
#include <vector>
Include dependency graph for model.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  protogen::ProtoField
 
struct  protogen::ProtoEnumValue
 
struct  protogen::ProtoEnum
 
struct  protogen::ProtoMessageDef
 
struct  protogen::ProtoFile
 

Namespaces

namespace  protogen
 

Enumerations

enum class  protogen::FieldType {
  protogen::Double , protogen::Float , protogen::Int32 , protogen::Int64 ,
  protogen::Uint32 , protogen::Uint64 , protogen::Sint32 , protogen::Sint64 ,
  protogen::Fixed32 , protogen::Fixed64 , protogen::Sfixed32 , protogen::Sfixed64 ,
  protogen::Bool , protogen::String , protogen::Bytes , protogen::Enum ,
  protogen::Message
}
 

Functions

bool protogen::is_scalar_type (const std::string &t)
 True for the 15 proto3 scalar keywords.
 
int protogen::wire_type_of (const ProtoField &f)
 Wire type number (0/1/2/5) for a resolved field.
 
bool protogen::is_packed (const ProtoField &f)
 True if a repeated field of this type is packed (honoring explicit flag).
 

Detailed Description

protogen AST for the proto3 subset the ESPHome native API uses — populated by the parser, consumed by the emitters.