| 201 | void Reset() { memset(buf_, 0, sizeof(buf_)); } |
| 202 | |
| 203 | [[nodiscard]] Status Set(uint32_t byte_offset, uint32_t bytes, const uint8_t *src) { |
| 204 | Status bound_status(checkLegalBound(byte_offset, bytes)); |
| 205 | if (!bound_status) { |
| 206 | return bound_status; |
| 207 | } |
| 208 | byte_offset -= byte_offset_; |
| 209 | memcpy(buf_ + byte_offset, src, bytes); |
| 210 | return Status::OK(); |
| 211 | } |
| 212 | |
| 213 | [[nodiscard]] Status Get(uint32_t byte_offset, uint32_t bytes, uint8_t *dst) const { |
| 214 | Status bound_status(checkLegalBound(byte_offset, bytes)); |