(self, obj)
| 29 | self.schema_hash: bytes = pyfory.format.infer.compute_schema_hash(self.schema) |
| 30 | |
| 31 | def encode(self, obj): |
| 32 | row = self.row_encoder.to_row(obj) |
| 33 | buffer = pyfory.Buffer.allocate(8 + row.size_bytes()) |
| 34 | buffer.write_int64(self.schema_hash) |
| 35 | row_bytes = row.to_bytes() |
| 36 | buffer.write_bytes(row_bytes) |
| 37 | return buffer.to_bytes(0, buffer.get_writer_index()) |
| 38 | |
| 39 | def decode(self, binary: bytes): |
| 40 | buf = pyfory.Buffer(binary, 0, len(binary)) |
nothing calls this directly
no test coverage detected