Crate bebop

source ·

Modules§

Macros§

  • The macro used to generate the flag structures.
  • Macro to define collections easily. Very useful when testing. Copied from https://stackoverflow.com/a/27582993/4404257
  • Ensure the alignment of a type is a certain value at compile time.
  • Assert that a type or value implements a given list of traits at compile time.
  • Serialize values from a packed type. Use fn _serialize_chained to generate a chain serialization function for use within SubRecord, or just pass the type, value, and field to chain serialize a given value.
  • The type must be Copy. Creates an aligned copy of a field on the stack for easy reading.
  • Macro to make writing tests easier since most of them follow the same pattern
  • Reads a possibly unaligned pointer as a value and passes it to a closure.
  • The type must be Copy. Creates an aligned copy of a field on the stack for easy reading.
  • Reads a possibly unaligned pointer as a reference.

Structs§

  • A date is stored as a 64-bit integer amount of “ticks” since 00:00:00 UTC on January 1 of year 1 A.D. in the Gregorian calendar, where a “tick” is 100 nanoseconds.
  • A GUID is a unique identifier. Stored internally in the Microsoft Guid format to support zero-copy deserialization

Enums§

Constants§

Traits§

  • A trait which should be given to any type which will always take up the same amount of space when serialized. This goes one step beyond the Sized trait which only requires it to take up a set amount of space on the stack. This is saying that the total data it contains and points to must always be of the exact same size for every instance.
  • Bebop message type which can be serialized and deserialized.
  • Internal trait used to reduce the amount of code that needs to be generated.

Functions§

  • Read a 4-byte length value from the front of the raw data.
  • Write a 4-byte length value to the writer.

Type Aliases§