(&self)
| 88 | /// Encodes as 12 bytes for storage. |
| 89 | #[inline] |
| 90 | pub fn to_bytes(&self) -> [u8; 12] { |
| 91 | let mut bytes = [0u8; 12]; |
| 92 | bytes[0..8].copy_from_slice(&self.change_id.get().to_le_bytes()); |
| 93 | bytes[8..12].copy_from_slice(&self.file_idx.to_le_bytes()); |
| 94 | bytes |
| 95 | } |
| 96 | |
| 97 | /// Decodes from 12 bytes. |
| 98 | #[inline] |