mirror of
https://github.com/Noratrieb/haesli.git
synced 2026-01-16 04:35:03 +01:00
split generated code so that methods are now in core
This commit is contained in:
parent
3b656b911a
commit
c333f20531
20 changed files with 1337 additions and 1206 deletions
31
amqp_core/src/methods/mod.rs
Normal file
31
amqp_core/src/methods/mod.rs
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
mod generated;
|
||||
|
||||
use std::collections::HashMap;
|
||||
|
||||
pub use generated::*;
|
||||
|
||||
pub type TableFieldName = String;
|
||||
|
||||
pub type Table = HashMap<TableFieldName, FieldValue>;
|
||||
|
||||
#[derive(Debug, Clone, PartialEq)]
|
||||
pub enum FieldValue {
|
||||
Boolean(bool),
|
||||
ShortShortInt(i8),
|
||||
ShortShortUInt(u8),
|
||||
ShortInt(i16),
|
||||
ShortUInt(u16),
|
||||
LongInt(i32),
|
||||
LongUInt(u32),
|
||||
LongLongInt(i64),
|
||||
LongLongUInt(u64),
|
||||
Float(f32),
|
||||
Double(f64),
|
||||
DecimalValue(u8, u32),
|
||||
ShortString(Shortstr),
|
||||
LongString(Longstr),
|
||||
FieldArray(Vec<FieldValue>),
|
||||
Timestamp(u64),
|
||||
FieldTable(Table),
|
||||
Void,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue