Code generator for C++ from YAML to generate network protocol parsers
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 

71 righe
1.4 KiB

includes:
- <array>
classes:
-
name: record_identifier
attributes:
-
name: uuid
out_type: std::array<unsigned char, 16>
start: 0
-
name: x
out_type: uint32_t
start: 16
-
name: y
out_type: uint32_t
start: 20
-
name: record
attributes:
-
name: record_id
out_type: std::array<unsigned char, 24>
start: 0
-
name: timestamp
out_type: uint64_t
start: 24
attributeafters:
-
name: offset
out_type: uint64_t
after_name: timestamp
bitfields:
-
name: flags
out_type: uint16_t
start: 40
mask: 0b0000000000000111
-
name: v_flag
out_type: uint16_t
after_name: offset
start: 40
mask: 0b0000000000000100
-
name: r_flags
out_type: uint16_t
start: 40
mask: 0b0000000000000010
-
name: c_flags
out_type: uint16_t
start: 40
mask: 0b0000000000000001
-
name: confirmed
out_type: uint16_t
start: 40
mask: 0b0000000000000001
-
name: validated
out_type: uint16_t
start: 40
mask: 0b0000000000000101
-
name: removed
out_type: uint16_t
start: 40
mask: 0b0000000000000010