pub enum ArrayImpl {
Show 20 variants
Int16(I16Array),
Int32(I32Array),
Int64(I64Array),
Int256(Int256Array),
Float32(F32Array),
Float64(F64Array),
Utf8(Utf8Array),
Bool(BoolArray),
Decimal(DecimalArray),
Interval(IntervalArray),
Date(DateArray),
Time(TimeArray),
Timestamp(TimestampArray),
Timestamptz(TimestamptzArray),
Jsonb(JsonbArray),
Serial(SerialArray),
Struct(StructArray),
List(ListArray),
Map(MapArray),
Bytea(BytesArray),
}
Expand description
ArrayImpl
embeds all possible array in array
module.
Variants§
Int16(I16Array)
Int32(I32Array)
Int64(I64Array)
Int256(Int256Array)
Float32(F32Array)
Float64(F64Array)
Utf8(Utf8Array)
Bool(BoolArray)
Decimal(DecimalArray)
Interval(IntervalArray)
Date(DateArray)
Time(TimeArray)
Timestamp(TimestampArray)
Timestamptz(TimestamptzArray)
Jsonb(JsonbArray)
Serial(SerialArray)
Struct(StructArray)
List(ListArray)
Map(MapArray)
Bytea(BytesArray)
Implementations§
source§impl ArrayImpl
impl ArrayImpl
pub fn from_protobuf(array: &PbArray, cardinality: usize) -> ArrayResult<Self>
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_int256(&self) -> &Int256Array
pub fn as_int256(&self) -> &Int256Array
§Panics
Panics if type mismatches.
sourcepub fn into_int256(self) -> Int256Array
pub fn into_int256(self) -> Int256Array
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_float32(&self) -> &F32Array
pub fn as_float32(&self) -> &F32Array
§Panics
Panics if type mismatches.
sourcepub fn into_float32(self) -> F32Array
pub fn into_float32(self) -> F32Array
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_float64(&self) -> &F64Array
pub fn as_float64(&self) -> &F64Array
§Panics
Panics if type mismatches.
sourcepub fn into_float64(self) -> F64Array
pub fn into_float64(self) -> F64Array
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_decimal(&self) -> &DecimalArray
pub fn as_decimal(&self) -> &DecimalArray
§Panics
Panics if type mismatches.
sourcepub fn into_decimal(self) -> DecimalArray
pub fn into_decimal(self) -> DecimalArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_interval(&self) -> &IntervalArray
pub fn as_interval(&self) -> &IntervalArray
§Panics
Panics if type mismatches.
sourcepub fn into_interval(self) -> IntervalArray
pub fn into_interval(self) -> IntervalArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_timestamp(&self) -> &TimestampArray
pub fn as_timestamp(&self) -> &TimestampArray
§Panics
Panics if type mismatches.
sourcepub fn into_timestamp(self) -> TimestampArray
pub fn into_timestamp(self) -> TimestampArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_timestamptz(&self) -> &TimestamptzArray
pub fn as_timestamptz(&self) -> &TimestamptzArray
§Panics
Panics if type mismatches.
sourcepub fn into_timestamptz(self) -> TimestamptzArray
pub fn into_timestamptz(self) -> TimestamptzArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_jsonb(&self) -> &JsonbArray
pub fn as_jsonb(&self) -> &JsonbArray
§Panics
Panics if type mismatches.
sourcepub fn into_jsonb(self) -> JsonbArray
pub fn into_jsonb(self) -> JsonbArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_serial(&self) -> &SerialArray
pub fn as_serial(&self) -> &SerialArray
§Panics
Panics if type mismatches.
sourcepub fn into_serial(self) -> SerialArray
pub fn into_serial(self) -> SerialArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_struct(&self) -> &StructArray
pub fn as_struct(&self) -> &StructArray
§Panics
Panics if type mismatches.
sourcepub fn into_struct(self) -> StructArray
pub fn into_struct(self) -> StructArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
sourcepub fn as_bytea(&self) -> &BytesArray
pub fn as_bytea(&self) -> &BytesArray
§Panics
Panics if type mismatches.
sourcepub fn into_bytea(self) -> BytesArray
pub fn into_bytea(self) -> BytesArray
§Panics
Panics if type mismatches.
source§impl ArrayImpl
impl ArrayImpl
pub fn is_empty(&self) -> bool
sourcepub fn null_bitmap(&self) -> &Bitmap
pub fn null_bitmap(&self) -> &Bitmap
Get the null Bitmap
of the array.
pub fn into_null_bitmap(self) -> Bitmap
pub fn to_protobuf(&self) -> PbArray
pub fn hash_at<H: Hasher>(&self, idx: usize, state: &mut H)
pub fn hash_vec<H: Hasher>(&self, hashers: &mut [H], vis: &Bitmap)
sourcepub fn compact(&self, visibility: &Bitmap, cardinality: usize) -> Self
pub fn compact(&self, visibility: &Bitmap, cardinality: usize) -> Self
Select some elements from Array
based on visibility
bitmap.
pub fn get_ident(&self) -> &'static str
sourcepub fn to_datum(&self) -> Datum
pub fn to_datum(&self) -> Datum
If the array only have one single element, convert it to Datum
.
sourcepub fn value_at(&self, idx: usize) -> DatumRef<'_>
pub fn value_at(&self, idx: usize) -> DatumRef<'_>
Get the enum-wrapped ScalarRefImpl
out of the Array
.
sourcepub unsafe fn value_at_unchecked(&self, idx: usize) -> DatumRef<'_>
pub unsafe fn value_at_unchecked(&self, idx: usize) -> DatumRef<'_>
§Safety
This function is unsafe because it does not check the validity of idx
. It is caller’s
responsibility to ensure the validity of idx
.
Unsafe version of getting the enum-wrapped ScalarRefImpl
out of the Array
.
pub fn set_bitmap(&mut self, bitmap: Bitmap)
pub fn create_builder(&self, capacity: usize) -> ArrayBuilderImpl
pub fn into_ref(self) -> ArrayRef
pub fn iter( &self, ) -> impl DoubleEndedIterator<Item = DatumRef<'_>> + ExactSizeIterator
Trait Implementations§
source§impl EstimateSize for ArrayImpl
impl EstimateSize for ArrayImpl
source§fn estimated_heap_size(&self) -> usize
fn estimated_heap_size(&self) -> usize
source§fn estimated_size(&self) -> usizewhere
Self: Sized,
fn estimated_size(&self) -> usizewhere
Self: Sized,
estimated_heap_size
and the size of Self
.source§impl<'a> From<&'a ArrayImpl> for &'a BytesArray
impl<'a> From<&'a ArrayImpl> for &'a BytesArray
source§impl<'a> From<&'a ArrayImpl> for &'a Int256Array
impl<'a> From<&'a ArrayImpl> for &'a Int256Array
source§impl<'a> From<&'a ArrayImpl> for &'a JsonbArray
impl<'a> From<&'a ArrayImpl> for &'a JsonbArray
source§impl<'a> From<&'a ArrayImpl> for &'a DecimalArray
impl<'a> From<&'a ArrayImpl> for &'a DecimalArray
source§impl<'a> From<&'a ArrayImpl> for &'a IntervalArray
impl<'a> From<&'a ArrayImpl> for &'a IntervalArray
source§impl<'a> From<&'a ArrayImpl> for &'a SerialArray
impl<'a> From<&'a ArrayImpl> for &'a SerialArray
source§impl<'a> From<&'a ArrayImpl> for &'a TimestampArray
impl<'a> From<&'a ArrayImpl> for &'a TimestampArray
source§impl<'a> From<&'a ArrayImpl> for &'a TimestamptzArray
impl<'a> From<&'a ArrayImpl> for &'a TimestamptzArray
source§impl<'a> From<&'a ArrayImpl> for &'a StructArray
impl<'a> From<&'a ArrayImpl> for &'a StructArray
source§impl From<ArrayImpl> for BytesArray
impl From<ArrayImpl> for BytesArray
source§impl From<ArrayImpl> for Int256Array
impl From<ArrayImpl> for Int256Array
source§impl From<ArrayImpl> for JsonbArray
impl From<ArrayImpl> for JsonbArray
source§impl From<ArrayImpl> for DecimalArray
impl From<ArrayImpl> for DecimalArray
source§impl From<ArrayImpl> for IntervalArray
impl From<ArrayImpl> for IntervalArray
source§impl From<ArrayImpl> for SerialArray
impl From<ArrayImpl> for SerialArray
source§impl From<ArrayImpl> for TimestampArray
impl From<ArrayImpl> for TimestampArray
source§impl From<ArrayImpl> for TimestamptzArray
impl From<ArrayImpl> for TimestamptzArray
source§impl From<ArrayImpl> for StructArray
impl From<ArrayImpl> for StructArray
source§impl From<BytesArray> for ArrayImpl
impl From<BytesArray> for ArrayImpl
source§fn from(arr: BytesArray) -> Self
fn from(arr: BytesArray) -> Self
source§impl From<Int256Array> for ArrayImpl
impl From<Int256Array> for ArrayImpl
source§fn from(arr: Int256Array) -> Self
fn from(arr: Int256Array) -> Self
source§impl From<JsonbArray> for ArrayImpl
impl From<JsonbArray> for ArrayImpl
source§fn from(arr: JsonbArray) -> Self
fn from(arr: JsonbArray) -> Self
source§impl<T: PrimitiveArrayItemType> From<PrimitiveArray<T>> for ArrayImpl
impl<T: PrimitiveArrayItemType> From<PrimitiveArray<T>> for ArrayImpl
source§fn from(arr: PrimitiveArray<T>) -> Self
fn from(arr: PrimitiveArray<T>) -> Self
source§impl From<StructArray> for ArrayImpl
impl From<StructArray> for ArrayImpl
source§fn from(arr: StructArray) -> Self
fn from(arr: StructArray) -> Self
impl Eq for ArrayImpl
Auto Trait Implementations§
impl Freeze for ArrayImpl
impl RefUnwindSafe for ArrayImpl
impl Send for ArrayImpl
impl Sync for ArrayImpl
impl Unpin for ArrayImpl
impl UnwindSafe for ArrayImpl
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request
§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
type Err = Infallible
fn into_result(self) -> Result<T, <T as IntoResult<T>>::Err>
source§impl<M> MetricVecRelabelExt for M
impl<M> MetricVecRelabelExt for M
source§fn relabel(
self,
metric_level: MetricLevel,
relabel_threshold: MetricLevel,
) -> RelabeledMetricVec<M>
fn relabel( self, metric_level: MetricLevel, relabel_threshold: MetricLevel, ) -> RelabeledMetricVec<M>
RelabeledMetricVec::with_metric_level
.source§fn relabel_n(
self,
metric_level: MetricLevel,
relabel_threshold: MetricLevel,
relabel_num: usize,
) -> RelabeledMetricVec<M>
fn relabel_n( self, metric_level: MetricLevel, relabel_threshold: MetricLevel, relabel_num: usize, ) -> RelabeledMetricVec<M>
RelabeledMetricVec::with_metric_level_relabel_n
.source§fn relabel_debug_1(
self,
relabel_threshold: MetricLevel,
) -> RelabeledMetricVec<M>
fn relabel_debug_1( self, relabel_threshold: MetricLevel, ) -> RelabeledMetricVec<M>
RelabeledMetricVec::with_metric_level_relabel_n
with metric_level
set to
MetricLevel::Debug
and relabel_num
set to 1.