Type Definition arrow_array::array::ArrayRef

source ·
pub type ArrayRef = Arc<dyn Array>;
Expand description

A reference-counted reference to a generic Array.

Trait Implementations§

source§

impl Array for ArrayRef

Ergonomics: Allow use of an ArrayRef as an &dyn Array

source§

fn as_any(&self) -> &dyn Any

Returns the array as Any so that it can be downcasted to a specific implementation. Read more
source§

fn data(&self) -> &ArrayData

Returns a reference to the underlying data of this array.
source§

fn into_data(self) -> ArrayData

Returns the underlying data of this array.
source§

fn data_ref(&self) -> &ArrayData

Returns a reference-counted pointer to the underlying data of this array.
source§

fn data_type(&self) -> &DataType

Returns a reference to the DataType of this array. Read more
source§

fn slice(&self, offset: usize, length: usize) -> ArrayRef

Returns a zero-copy slice of this array with the indicated offset and length. Read more
source§

fn len(&self) -> usize

Returns the length (i.e., number of elements) of this array. Read more
source§

fn is_empty(&self) -> bool

Returns whether this array is empty. Read more
source§

fn offset(&self) -> usize

Returns the offset into the underlying data used by this array(-slice). Note that the underlying data can be shared by many arrays. This defaults to 0. Read more
source§

fn is_null(&self, index: usize) -> bool

Returns whether the element at index is null. When using this function on a slice, the index is relative to the slice. Read more
source§

fn is_valid(&self, index: usize) -> bool

Returns whether the element at index is not null. When using this function on a slice, the index is relative to the slice. Read more
source§

fn null_count(&self) -> usize

Returns the total number of null values in this array. Read more
source§

fn get_buffer_memory_size(&self) -> usize

Returns the total number of bytes of memory pointed to by this array. The buffers store bytes in the Arrow memory format, and include the data as well as the validity map.
source§

fn get_array_memory_size(&self) -> usize

Returns the total number of bytes of memory occupied physically by this array. This value will always be greater than returned by get_buffer_memory_size() and includes the overhead of the data structures that contain the pointers to the various buffers.