1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
use crateResult;
/// Trait for types that can be serialized to/from bytes with explicit byte order.
///
/// This trait uses **LITTLE-ENDIAN** byte order for all numeric types, making the data
/// **portable across different endianness systems** (x86, ARM, etc.). This is the key
/// difference from `ZeroCopyVec`, which uses native byte order and is not portable.
///
/// Use this trait when:
/// - You need cross-platform compatibility
/// - You're sharing data between systems with different endianness
/// - You need custom serialization logic
///
/// For maximum performance on a single system, use `ZeroCopyVec` instead.