Logical

Struct Logical 

Source
pub struct Logical<Logical, Physical>
where Logical: PolarsDataType, Physical: PolarsDataType,
{ pub phys: ChunkedArray<Physical>, pub dtype: DataType, /* private fields */ }
Expand description

Maps a logical type to a chunked array implementation of the physical type. This saves a lot of compiler bloat and allows us to reuse functionality.

Fields§

§phys: ChunkedArray<Physical>§dtype: DataType

Implementations§

Source§

impl<T> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source

pub fn sort_with( &self, options: SortOptions, ) -> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source

pub fn sort( &self, descending: bool, ) -> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Returned a sorted ChunkedArray.

Source

pub fn arg_sort(&self, options: SortOptions) -> ChunkedArray<UInt32Type>

Retrieve the indexes needed to sort this array.

Source§

impl Logical<DecimalType, Int128Type>

Source

pub fn precision(&self) -> usize

Source

pub fn scale(&self) -> usize

Source

pub fn with_prec_scale( &self, prec: usize, scale: usize, strict: bool, ) -> Result<Cow<'_, Logical<DecimalType, Int128Type>>, PolarsError>

Source

pub fn into_phys_with_prec_scale_or_sentinel( &self, prec: usize, scale: usize, sentinel: i128, ) -> ChunkedArray<Int128Type>

Converts self to a physical representation with the given precision and scale, returning the given sentinel value instead for values which don’t fit in the given precision and scale. This can be useful for comparisons.

Source§

impl<T> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source

pub fn is_enum(&self) -> bool

Source

pub fn uses_lexical_ordering(&self) -> bool

Return whether or not the CategoricalChunked uses the lexical order of the string values when sorting.

Source

pub fn full_null_with_dtype( name: PlSmallStr, length: usize, dtype: DataType, ) -> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source

pub fn from_cats_and_dtype( cat_ids: ChunkedArray<<T as PolarsCategoricalType>::PolarsPhysical>, dtype: DataType, ) -> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Create a CategoricalChunked from a physical array and dtype.

Checks that all the category ids are valid, mapping invalid ones to nulls.

Source

pub unsafe fn from_cats_and_dtype_unchecked( cat_ids: ChunkedArray<<T as PolarsCategoricalType>::PolarsPhysical>, dtype: DataType, ) -> Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Create a CategoricalChunked from a physical array and dtype.

§Safety

It’s not checked that the indices are in-bounds or that the dtype is correct.

Source

pub fn get_mapping(&self) -> &Arc<CategoricalMapping>

Get a reference to the mapping of categorical types to the string values.

Source

pub fn iter_str(&self) -> impl PolarsIterator

Create an Iterator that iterates over the &str values of the CategoricalChunked.

Source

pub fn from_str_iter<'a, I>( name: PlSmallStr, dtype: DataType, strings: I, ) -> Result<Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>, PolarsError>
where I: IntoIterator<Item = Option<&'a str>>,

Converts from strings to this CategoricalChunked.

If this dtype is an Enum any non-existing strings get mapped to null.

Source

pub fn to_arrow( &self, compat_level: CompatLevel, ) -> DictionaryArray<<T as PolarsCategoricalType>::Native>

Source§

impl<K, T> Logical<K, T>

Source

pub unsafe fn new_logical( phys: ChunkedArray<T>, dtype: DataType, ) -> Logical<K, T>

§Safety

You must uphold the logical types’ invariants.

Source§

impl<K, T> Logical<K, T>

Source

pub fn name(&self) -> &PlSmallStr

Source

pub fn rename(&mut self, name: PlSmallStr)

Source

pub fn len(&self) -> usize

Source

pub fn is_empty(&self) -> bool

Source

pub fn null_count(&self) -> usize

Source

pub fn has_nulls(&self) -> bool

Source

pub fn is_null(&self) -> ChunkedArray<BooleanType>

Source

pub fn is_not_null(&self) -> ChunkedArray<BooleanType>

Source

pub fn split_at(&self, offset: i64) -> (Logical<K, T>, Logical<K, T>)

Source

pub fn slice(&self, offset: i64, length: usize) -> Logical<K, T>

Source

pub fn field(&self) -> Field

Source

pub fn physical(&self) -> &ChunkedArray<T>

Source

pub fn physical_mut(&mut self) -> &mut ChunkedArray<T>

Source

pub fn into_physical(self) -> ChunkedArray<T>

Source§

impl Logical<DateType, Int32Type>

Source

pub fn as_date_iter(&self) -> impl TrustedLen

Source

pub fn from_naive_date<I>( name: PlSmallStr, v: I, ) -> Logical<DateType, Int32Type>
where I: IntoIterator<Item = NaiveDate>,

Construct a new DateChunked from an iterator over NaiveDate.

Source

pub fn to_string( &self, format: &str, ) -> Result<ChunkedArray<StringType>, PolarsError>

Convert from Date into String with the given format. See chrono strftime/strptime.

Source

pub fn strftime( &self, format: &str, ) -> Result<ChunkedArray<StringType>, PolarsError>

Convert from Date into String with the given format. See chrono strftime/strptime.

Alias for to_string.

Source

pub fn from_naive_date_options<I>( name: PlSmallStr, v: I, ) -> Logical<DateType, Int32Type>
where I: IntoIterator<Item = Option<NaiveDate>>,

Construct a new DateChunked from an iterator over optional NaiveDate.

Source§

impl Logical<DatetimeType, Int64Type>

Source

pub fn as_datetime_iter(&self) -> impl TrustedLen

Source

pub fn time_unit(&self) -> TimeUnit

Source

pub fn time_zone(&self) -> &Option<TimeZone>

Source

pub fn to_string( &self, format: &str, ) -> Result<ChunkedArray<StringType>, PolarsError>

Convert from Datetime into String with the given format. See chrono strftime/strptime.

Source

pub fn strftime( &self, format: &str, ) -> Result<ChunkedArray<StringType>, PolarsError>

Convert from Datetime into String with the given format. See chrono strftime/strptime.

Alias for to_string.

Source

pub fn from_naive_datetime<I>( name: PlSmallStr, v: I, tu: TimeUnit, ) -> Logical<DatetimeType, Int64Type>
where I: IntoIterator<Item = NaiveDateTime>,

Construct a new DatetimeChunked from an iterator over NaiveDateTime.

Source

pub fn from_naive_datetime_options<I>( name: PlSmallStr, v: I, tu: TimeUnit, ) -> Logical<DatetimeType, Int64Type>
where I: IntoIterator<Item = Option<NaiveDateTime>>,

Source

pub fn cast_time_unit(&self, tu: TimeUnit) -> Logical<DatetimeType, Int64Type>

Change the underlying TimeUnit. And update the data accordingly.

Source

pub fn set_time_unit(&mut self, time_unit: TimeUnit)

Change the underlying TimeUnit. This does not modify the data.

Source

pub fn set_time_zone(&mut self, time_zone: TimeZone) -> Result<(), PolarsError>

Change the underlying TimeZone. This does not modify the data. This does not validate the time zone - it’s up to the caller to verify that it’s already been validated.

Source

pub fn set_time_unit_and_time_zone( &mut self, time_unit: TimeUnit, time_zone: TimeZone, ) -> Result<(), PolarsError>

Change the underlying TimeUnit and TimeZone. This does not modify the data. This does not validate the time zone - it’s up to the caller to verify that it’s already been validated.

Source§

impl Logical<DurationType, Int64Type>

Source

pub fn time_unit(&self) -> TimeUnit

Source

pub fn cast_time_unit(&self, tu: TimeUnit) -> Logical<DurationType, Int64Type>

Change the underlying TimeUnit. And update the data accordingly.

Source

pub fn set_time_unit(&mut self, tu: TimeUnit)

Change the underlying TimeUnit. This does not modify the data.

Source

pub fn to_string( &self, format: &str, ) -> Result<ChunkedArray<StringType>, PolarsError>

Convert from Duration to String; note that strftime format strings are not supported, only the specifiers ‘iso’ and ‘polars’.

Source

pub fn from_duration<I>( name: PlSmallStr, v: I, tu: TimeUnit, ) -> Logical<DurationType, Int64Type>
where I: IntoIterator<Item = TimeDelta>,

Construct a new DurationChunked from an iterator over ChronoDuration.

Source

pub fn from_duration_options<I>( name: PlSmallStr, v: I, tu: TimeUnit, ) -> Logical<DurationType, Int64Type>
where I: IntoIterator<Item = Option<TimeDelta>>,

Construct a new DurationChunked from an iterator over optional ChronoDuration.

Source§

impl Logical<TimeType, Int64Type>

Source

pub fn to_string(&self, format: &str) -> ChunkedArray<StringType>

Convert from Time into String with the given format. See chrono strftime/strptime.

Source

pub fn strftime(&self, format: &str) -> ChunkedArray<StringType>

Convert from Time into String with the given format. See chrono strftime/strptime.

Alias for to_string.

Source

pub fn as_time_iter(&self) -> impl TrustedLen

Source

pub fn from_naive_time<I>( name: PlSmallStr, v: I, ) -> Logical<TimeType, Int64Type>
where I: IntoIterator<Item = NaiveTime>,

Construct a new TimeChunked from an iterator over NaiveTime.

Source

pub fn from_naive_time_options<I>( name: PlSmallStr, v: I, ) -> Logical<TimeType, Int64Type>
where I: IntoIterator<Item = Option<NaiveTime>>,

Construct a new TimeChunked from an iterator over optional NaiveTime.

Trait Implementations§

Source§

impl Add for &Logical<DecimalType, Int128Type>

Source§

type Output = Result<Logical<DecimalType, Int128Type>, PolarsError>

The resulting type after applying the + operator.
Source§

fn add( self, rhs: &Logical<DecimalType, Int128Type>, ) -> <&Logical<DecimalType, Int128Type> as Add>::Output

Performs the + operation. Read more
Source§

impl<T> ChunkAggSeries for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

fn min_reduce(&self) -> Scalar

Get the min of the ChunkedArray as a new Series of length 1.
Source§

fn max_reduce(&self) -> Scalar

Get the max of the ChunkedArray as a new Series of length 1.
Source§

fn sum_reduce(&self) -> Scalar

Get the sum of the ChunkedArray as a new Series of length 1.
Source§

fn prod_reduce(&self) -> Scalar

Get the product of the ChunkedArray as a new Series of length 1.
Source§

impl<T> ChunkCompareEq<&ChunkedArray<StringType>> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

impl<T> ChunkCompareEq<&Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

impl<T> ChunkCompareEq<&str> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

type Item = ChunkedArray<BooleanType>

Source§

fn equal( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareEq<&str>>::Item

Check for equality.
Source§

fn equal_missing( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareEq<&str>>::Item

Check for equality where None == None.
Source§

fn not_equal( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareEq<&str>>::Item

Check for inequality.
Source§

fn not_equal_missing( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareEq<&str>>::Item

Check for inequality where None == None.
Source§

impl<T> ChunkCompareIneq<&ChunkedArray<StringType>> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

impl<T> ChunkCompareIneq<&Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

impl<T> ChunkCompareIneq<&str> for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

type Item = ChunkedArray<BooleanType>

Source§

fn gt( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareIneq<&str>>::Item

Greater than comparison.
Source§

fn gt_eq( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareIneq<&str>>::Item

Greater than or equal comparison.
Source§

fn lt( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareIneq<&str>>::Item

Less than comparison.
Source§

fn lt_eq( &self, rhs: &str, ) -> <Logical<T, <T as PolarsCategoricalType>::PolarsPhysical> as ChunkCompareIneq<&str>>::Item

Less than or equal comparison
Source§

impl<K, T> Clone for Logical<K, T>

Source§

fn clone(&self) -> Logical<K, T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl DateMethods for Logical<DateType, Int32Type>

Source§

fn parse_from_str_slice( name: PlSmallStr, v: &[&str], fmt: &str, ) -> Logical<DateType, Int32Type>

Source§

fn year(&self) -> ChunkedArray<Int32Type>

Extract month from underlying NaiveDate representation. Returns the year number in the calendar date.
Source§

fn is_leap_year(&self) -> ChunkedArray<BooleanType>

Extract year from underlying NaiveDate representation. Returns whether the year is a leap year.
Source§

fn iso_year(&self) -> ChunkedArray<Int32Type>

This year number might not match the calendar year number.
Source§

fn quarter(&self) -> ChunkedArray<Int8Type>

Extract month from underlying NaiveDateTime representation. Quarters range from 1 to 4.
Source§

fn month(&self) -> ChunkedArray<Int8Type>

Extract month from underlying NaiveDateTime representation. Returns the month number starting from 1. Read more
Source§

fn days_in_month(&self) -> ChunkedArray<Int8Type>

Returns the number of days in the month of the underlying NaiveDate representation.
Source§

fn week(&self) -> ChunkedArray<Int8Type>

Returns the ISO week number starting from 1. The return value ranges from 1 to 53. (The last week of year differs by years.)
Source§

fn day(&self) -> ChunkedArray<Int8Type>

Extract day from underlying NaiveDate representation. Returns the day of month starting from 1. Read more
Source§

fn ordinal(&self) -> ChunkedArray<Int16Type>

Returns the day of year starting from 1. Read more
Source§

fn new_from_parts( year: &ChunkedArray<Int32Type>, month: &ChunkedArray<Int8Type>, day: &ChunkedArray<Int8Type>, name: PlSmallStr, ) -> Result<Logical<DateType, Int32Type>, PolarsError>

Construct a date ChunkedArray from individual time components.
Source§

impl DatetimeMethods for Logical<DatetimeType, Int64Type>

Source§

fn year(&self) -> ChunkedArray<Int32Type>

Extract month from underlying NaiveDateTime representation. Returns the year number in the calendar date.
Source§

fn is_leap_year(&self) -> ChunkedArray<BooleanType>

Extract year from underlying NaiveDate representation. Returns whether the year is a leap year.
Source§

fn iso_year(&self) -> ChunkedArray<Int32Type>

Source§

fn quarter(&self) -> ChunkedArray<Int8Type>

Extract quarter from underlying NaiveDateTime representation. Quarters range from 1 to 4.
Source§

fn month(&self) -> ChunkedArray<Int8Type>

Extract month from underlying NaiveDateTime representation. Returns the month number starting from 1. Read more
Source§

fn days_in_month(&self) -> ChunkedArray<Int8Type>

Returns the number of days in the month of the underlying NaiveDateTime representation.
Source§

fn weekday(&self) -> ChunkedArray<Int8Type>

Extract ISO weekday from underlying NaiveDateTime representation. Returns the weekday number where monday = 1 and sunday = 7
Source§

fn week(&self) -> ChunkedArray<Int8Type>

Returns the ISO week number starting from 1. The return value ranges from 1 to 53. (The last week of year differs by years.)
Source§

fn day(&self) -> ChunkedArray<Int8Type>

Extract day from underlying NaiveDateTime representation. Returns the day of month starting from 1. Read more
Source§

fn hour(&self) -> ChunkedArray<Int8Type>

Extract hour from underlying NaiveDateTime representation. Returns the hour number from 0 to 23.
Source§

fn minute(&self) -> ChunkedArray<Int8Type>

Extract minute from underlying NaiveDateTime representation. Returns the minute number from 0 to 59.
Source§

fn second(&self) -> ChunkedArray<Int8Type>

Extract second from underlying NaiveDateTime representation. Returns the second number from 0 to 59.
Source§

fn nanosecond(&self) -> ChunkedArray<Int32Type>

Extract second from underlying NaiveDateTime representation. Returns the number of nanoseconds since the whole non-leap second. The range from 1,000,000,000 to 1,999,999,999 represents the leap second.
Source§

fn ordinal(&self) -> ChunkedArray<Int16Type>

Returns the day of year starting from 1. Read more
Source§

fn parse_from_str_slice( name: PlSmallStr, v: &[&str], fmt: &str, tu: TimeUnit, ) -> Logical<DatetimeType, Int64Type>

Source§

fn new_from_parts( year: &ChunkedArray<Int32Type>, month: &ChunkedArray<Int8Type>, day: &ChunkedArray<Int8Type>, hour: &ChunkedArray<Int8Type>, minute: &ChunkedArray<Int8Type>, second: &ChunkedArray<Int8Type>, nanosecond: &ChunkedArray<Int32Type>, ambiguous: &ChunkedArray<StringType>, time_unit: &TimeUnit, time_zone: Option<TimeZone>, name: PlSmallStr, ) -> Result<Logical<DatetimeType, Int64Type>, PolarsError>

Construct a datetime ChunkedArray from individual time components.
Source§

impl Div for &Logical<DecimalType, Int128Type>

Source§

type Output = Result<Logical<DecimalType, Int128Type>, PolarsError>

The resulting type after applying the / operator.
Source§

fn div( self, rhs: &Logical<DecimalType, Int128Type>, ) -> <&Logical<DecimalType, Int128Type> as Div>::Output

Performs the / operation. Read more
Source§

impl DurationMethods for Logical<DurationType, Int64Type>

Source§

fn hours(&self) -> ChunkedArray<Int64Type>

Extract the hours from a Duration

Source§

fn days(&self) -> ChunkedArray<Int64Type>

Extract the days from a Duration

Source§

fn minutes(&self) -> ChunkedArray<Int64Type>

Extract the seconds from a Duration

Source§

fn seconds(&self) -> ChunkedArray<Int64Type>

Extract the seconds from a Duration

Source§

fn milliseconds(&self) -> ChunkedArray<Int64Type>

Extract the milliseconds from a Duration

Source§

fn microseconds(&self) -> ChunkedArray<Int64Type>

Extract the microseconds from a Duration

Source§

fn nanoseconds(&self) -> ChunkedArray<Int64Type>

Extract the nanoseconds from a Duration

Source§

impl From<Logical<DateType, Int32Type>> for Series

Source§

fn from(a: Logical<DateType, Int32Type>) -> Series

Converts to this type from the input type.
Source§

impl From<Logical<DatetimeType, Int64Type>> for Series

Source§

fn from(a: Logical<DatetimeType, Int64Type>) -> Series

Converts to this type from the input type.
Source§

impl From<Logical<DurationType, Int64Type>> for Series

Source§

fn from(a: Logical<DurationType, Int64Type>) -> Series

Converts to this type from the input type.
Source§

impl From<Logical<TimeType, Int64Type>> for Series

Source§

fn from(a: Logical<TimeType, Int64Type>) -> Series

Converts to this type from the input type.
Source§

impl IntoSeries for Logical<DateType, Int32Type>

Source§

impl IntoSeries for Logical<DatetimeType, Int64Type>

Source§

impl IntoSeries for Logical<DecimalType, Int128Type>

Source§

impl IntoSeries for Logical<DurationType, Int64Type>

Source§

impl<T> IntoSeries for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

impl IntoSeries for Logical<TimeType, Int64Type>

Source§

impl LogicalType for Logical<DateType, Int32Type>

Source§

fn dtype(&self) -> &DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, cast_options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl LogicalType for Logical<DatetimeType, Int64Type>

Source§

fn dtype(&self) -> &DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, cast_options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl LogicalType for Logical<DecimalType, Int128Type>

Source§

fn dtype(&self) -> &DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, cast_options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl LogicalType for Logical<DurationType, Int64Type>

Source§

fn dtype(&self) -> &DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, cast_options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl<T> LogicalType for Logical<T, <T as PolarsCategoricalType>::PolarsPhysical>

Source§

fn dtype(&self) -> &DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl LogicalType for Logical<TimeType, Int64Type>

Source§

fn dtype(&self) -> &'static DataType

Get data type of ChunkedArray.
Source§

fn get_any_value(&self, i: usize) -> Result<AnyValue<'_>, PolarsError>

Source§

unsafe fn get_any_value_unchecked(&self, i: usize) -> AnyValue<'_>

Safety Read more
Source§

fn cast_with_options( &self, dtype: &DataType, cast_options: CastOptions, ) -> Result<Series, PolarsError>

Source§

fn cast(&self, dtype: &DataType) -> Result<Series, PolarsError>

Source§

impl Mul for &Logical<DecimalType, Int128Type>

Source§

type Output = Result<Logical<DecimalType, Int128Type>, PolarsError>

The resulting type after applying the * operator.
Source§

fn mul( self, rhs: &Logical<DecimalType, Int128Type>, ) -> <&Logical<DecimalType, Int128Type> as Mul>::Output

Performs the * operation. Read more
Source§

impl<T> NamedFrom<T, [NaiveDate]> for Logical<DateType, Int32Type>
where T: AsRef<[NaiveDate]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DateType, Int32Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [NaiveDateTime]> for Logical<DatetimeType, Int64Type>
where T: AsRef<[NaiveDateTime]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DatetimeType, Int64Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [NaiveTime]> for Logical<TimeType, Int64Type>
where T: AsRef<[NaiveTime]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<TimeType, Int64Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [Option<NaiveDate>]> for Logical<DateType, Int32Type>
where T: AsRef<[Option<NaiveDate>]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DateType, Int32Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [Option<NaiveDateTime>]> for Logical<DatetimeType, Int64Type>
where T: AsRef<[Option<NaiveDateTime>]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DatetimeType, Int64Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [Option<NaiveTime>]> for Logical<TimeType, Int64Type>
where T: AsRef<[Option<NaiveTime>]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<TimeType, Int64Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [Option<TimeDelta>]> for Logical<DurationType, Int64Type>
where T: AsRef<[Option<TimeDelta>]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DurationType, Int64Type>

Initialize by name and values.
Source§

impl<T> NamedFrom<T, [TimeDelta]> for Logical<DurationType, Int64Type>
where T: AsRef<[TimeDelta]>,

Source§

fn new(name: PlSmallStr, v: T) -> Logical<DurationType, Int64Type>

Initialize by name and values.
Source§

impl PolarsRound for Logical<DateType, Int32Type>

Source§

impl PolarsRound for Logical<DatetimeType, Int64Type>

Source§

impl PolarsTruncate for Logical<DateType, Int32Type>

Source§

impl PolarsTruncate for Logical<DatetimeType, Int64Type>

Source§

impl Sub for &Logical<DecimalType, Int128Type>

Source§

type Output = Result<Logical<DecimalType, Int128Type>, PolarsError>

The resulting type after applying the - operator.
Source§

fn sub( self, rhs: &Logical<DecimalType, Int128Type>, ) -> <&Logical<DecimalType, Int128Type> as Sub>::Output

Performs the - operation. Read more
Source§

impl TimeMethods for Logical<TimeType, Int64Type>

Source§

fn hour(&self) -> ChunkedArray<Int8Type>

Extract hour from underlying NaiveDateTime representation. Returns the hour number from 0 to 23.

Source§

fn minute(&self) -> ChunkedArray<Int8Type>

Extract minute from underlying NaiveDateTime representation. Returns the minute number from 0 to 59.

Source§

fn second(&self) -> ChunkedArray<Int8Type>

Extract second from underlying NaiveDateTime representation. Returns the second number from 0 to 59.

Source§

fn nanosecond(&self) -> ChunkedArray<Int32Type>

Extract second from underlying NaiveDateTime representation. Returns the number of nanoseconds since the whole non-leap second. The range from 1,000,000,000 to 1,999,999,999 represents the leap second.

Source§

fn parse_from_str_slice( name: PlSmallStr, v: &[&str], fmt: &str, ) -> Logical<TimeType, Int64Type>

Auto Trait Implementations§

§

impl<Logical, Physical> !Freeze for Logical<Logical, Physical>

§

impl<Logical, Physical> !RefUnwindSafe for Logical<Logical, Physical>

§

impl<Logical, Physical> Send for Logical<Logical, Physical>

§

impl<Logical, Physical> Sync for Logical<Logical, Physical>

§

impl<Logical, Physical> Unpin for Logical<Logical, Physical>
where Logical: Unpin, Physical: Unpin,

§

impl<Logical, Physical> !UnwindSafe for Logical<Logical, Physical>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DynClone for T
where T: Clone,

Source§

fn __clone_box(&self, _: Private) -> *mut ()

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoColumn for T
where T: IntoSeries,

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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 more
Source§

impl<T> Key for T
where T: Clone,

Source§

fn align() -> usize

The alignment necessary for the key. Must return a power of two.
Source§

fn size(&self) -> usize

The size of the key in bytes.
Source§

unsafe fn init(&self, ptr: *mut u8)

Initialize the key in the given memory location. Read more
Source§

unsafe fn get<'a>(ptr: *const u8) -> &'a T

Get a reference to the key from the given memory location. Read more
Source§

unsafe fn drop_in_place(ptr: *mut u8)

Drop the key in place. Read more
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> PolicyExt for T
where T: ?Sized,

§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] only if self and other return Action::Follow. Read more
§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

impl<T> ErasedDestructor for T
where T: 'static,

§

impl<T> PlanCallbackArgs for T

§

impl<T> PlanCallbackOut for T