RandomAccessFile inherits from InputStream and is a base class for: ReadableFile for reading from a file; MemoryMappedFile for the same but with memory mapping; and BufferReader for reading from a buffer. Use these with the various table readers.

Factory

The $create() factory methods instantiate the InputStream object and take the following arguments, depending on the subclass:

  • path For ReadableFile, a character file name

  • x For BufferReader, a Buffer or an object that can be made into a buffer via buffer().

To instantiate a MemoryMappedFile, call mmap_open().

Methods

  • $GetSize():

  • $supports_zero_copy(): Logical

  • $seek(position): go to that position in the stream

  • $tell(): return the position in the stream

  • $close(): close the stream

  • $Read(nbytes): read data from the stream, either a specified nbytes or all, if nbytes is not provided

  • $ReadAt(position, nbytes): similar to $seek(position)$Read(nbytes)

  • $Resize(size): for a MemoryMappedFile that is writeable

Super classes

arrow::Object -> arrow::Readable -> InputStream

Methods

Public methods

Inherited methods

Method close()

Usage

InputStream$close()


Method clone()

The objects of this class are cloneable with this method.

Usage

InputStream$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Super classes

arrow::Object -> arrow::Readable -> arrow::InputStream -> RandomAccessFile

Methods

Public methods

Inherited methods

Method GetSize()

Usage

RandomAccessFile$GetSize()


Method supports_zero_copy()

Usage

RandomAccessFile$supports_zero_copy()


Method seek()

Usage

RandomAccessFile$seek(position)


Method tell()

Usage

RandomAccessFile$tell()


Method Read()

Usage

RandomAccessFile$Read(nbytes = NULL)


Method ReadAt()

Usage

RandomAccessFile$ReadAt(position, nbytes = NULL)


Method clone()

The objects of this class are cloneable with this method.

Usage

RandomAccessFile$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Super classes

arrow::Object -> arrow::Readable -> arrow::InputStream -> arrow::RandomAccessFile -> MemoryMappedFile

Methods

Public methods

Inherited methods

Method Resize()

Usage

MemoryMappedFile$Resize(size)


Method clone()

The objects of this class are cloneable with this method.

Usage

MemoryMappedFile$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Super classes

arrow::Object -> arrow::Readable -> arrow::InputStream -> arrow::RandomAccessFile -> ReadableFile

Methods

Public methods

Inherited methods

Method clone()

The objects of this class are cloneable with this method.

Usage

ReadableFile$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.

Super classes

arrow::Object -> arrow::Readable -> arrow::InputStream -> arrow::RandomAccessFile -> BufferReader

Methods

Public methods

Inherited methods

Method clone()

The objects of this class are cloneable with this method.

Usage

BufferReader$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.