MCPcopy Create free account
hub / github.com/apache/arrow / DuckReader

Class DuckReader

python/pyarrow/tests/test_io.py:225–235  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

223 dst_buf = bytearray(data)
224
225 class DuckReader:
226 def close(self):
227 pass
228
229 @property
230 def closed(self):
231 return False
232
233 def read_buffer(self, nbytes):
234 assert nbytes == length
235 return memoryview(dst_buf)[:nbytes]
236
237 duck_reader = DuckReader()
238 with pa.PythonFile(duck_reader, mode='r') as f:

Callers 2

Calls

no outgoing calls

Tested by 2