Type Alias TimeChunked

Source
pub type TimeChunked = Logical<TimeType, Int64Type>;

Aliased Type§

struct TimeChunked(pub ChunkedArray<Int64Type>, _, pub Option<DataType>);

Fields§

§0: ChunkedArray<Int64Type>§2: Option<DataType>

Implementations

Source§

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

Source

pub fn new_logical<J>(ca: ChunkedArray<T>) -> Logical<J, T>
where J: PolarsDataType,

Source§

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

Source

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

Source

pub fn field(&self) -> Field

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<K, T> Clone for Logical<K, T>

Source§

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

Returns a copy 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<K, T> Default for Logical<K, T>

Source§

fn default() -> Logical<K, T>

Returns the “default value” for a type. Read more
Source§

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

Source§

type Target = ChunkedArray<T>

The resulting type after dereferencing.
Source§

fn deref(&self) -> &<Logical<K, T> as Deref>::Target

Dereferences the value.
Source§

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

Source§

fn deref_mut(&mut self) -> &mut <Logical<K, T> as Deref>::Target

Mutably dereferences the value.
Source§

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

Source§

fn from(ca: ChunkedArray<Int64Type>) -> Logical<TimeType, Int64Type>

Converts to this type from the input type.
Source§

impl IntoSeries for Logical<TimeType, Int64Type>

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<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<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 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>