pub struct Date32Type {}Expand description
32-bit date type: the elapsed time since UNIX epoch in days (32 bits).
Implementations§
Source§impl Date32Type
impl Date32Type
Sourcepub fn to_naive_date(i: <Date32Type as ArrowPrimitiveType>::Native) -> NaiveDate
👎Deprecated since 58.0.0: Use to_naive_date_opt instead.
pub fn to_naive_date(i: <Date32Type as ArrowPrimitiveType>::Native) -> NaiveDate
Use to_naive_date_opt instead.
Sourcepub fn to_naive_date_opt(
i: <Date32Type as ArrowPrimitiveType>::Native,
) -> Option<NaiveDate>
pub fn to_naive_date_opt( i: <Date32Type as ArrowPrimitiveType>::Native, ) -> Option<NaiveDate>
Converts an arrow Date32Type into a chrono::NaiveDate
§Arguments
i- The Date32Type to convert
Returns Some(NaiveDate) if it fits, None otherwise.
Sourcepub fn from_naive_date(
d: NaiveDate,
) -> <Date32Type as ArrowPrimitiveType>::Native
pub fn from_naive_date( d: NaiveDate, ) -> <Date32Type as ArrowPrimitiveType>::Native
Sourcepub fn add_year_months(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use add_year_months_opt instead, which returns an Option to handle overflow.
pub fn add_year_months( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use add_year_months_opt instead, which returns an Option to handle overflow.
Adds the given IntervalYearMonthType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Sourcepub fn add_year_months_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn add_year_months_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Adds the given IntervalYearMonthType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Returns Some(Date32Type) if it fits, None otherwise.
Sourcepub fn add_day_time(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use add_day_time_opt instead, which returns an Option to handle overflow.
pub fn add_day_time( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use add_day_time_opt instead, which returns an Option to handle overflow.
Adds the given IntervalDayTimeType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Sourcepub fn add_day_time_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn add_day_time_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Adds the given IntervalDayTimeType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Returns Some(Date32Type) if it fits, None otherwise.
Sourcepub fn add_month_day_nano(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use add_month_day_nano_opt instead, which returns an Option to handle overflow.
pub fn add_month_day_nano( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use add_month_day_nano_opt instead, which returns an Option to handle overflow.
Adds the given IntervalMonthDayNanoType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Sourcepub fn add_month_day_nano_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn add_month_day_nano_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Adds the given IntervalMonthDayNanoType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to add
Returns Some(Date32Type) if it fits, None otherwise.
Sourcepub fn subtract_year_months(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use subtract_year_months_opt instead, which returns an Option to handle overflow.
pub fn subtract_year_months( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use subtract_year_months_opt instead, which returns an Option to handle overflow.
Subtract the given IntervalYearMonthType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Sourcepub fn subtract_year_months_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn subtract_year_months_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalYearMonthType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Subtract the given IntervalYearMonthType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Returns Some(Date32Type) if it fits, None otherwise.
Sourcepub fn subtract_day_time(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use subtract_day_time_opt instead, which returns an Option to handle overflow.
pub fn subtract_day_time( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use subtract_day_time_opt instead, which returns an Option to handle overflow.
Subtract the given IntervalDayTimeType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Sourcepub fn subtract_day_time_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn subtract_day_time_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalDayTimeType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Subtract the given IntervalDayTimeType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Returns Some(Date32Type) if it fits, None otherwise.
Sourcepub fn subtract_month_day_nano(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native,
) -> <Date32Type as ArrowPrimitiveType>::Native
👎Deprecated since 58.0.0: Use subtract_month_day_nano_opt instead, which returns an Option to handle overflow.
pub fn subtract_month_day_nano( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native, ) -> <Date32Type as ArrowPrimitiveType>::Native
Use subtract_month_day_nano_opt instead, which returns an Option to handle overflow.
Subtract the given IntervalMonthDayNanoType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Sourcepub fn subtract_month_day_nano_opt(
date: <Date32Type as ArrowPrimitiveType>::Native,
delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native,
) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
pub fn subtract_month_day_nano_opt( date: <Date32Type as ArrowPrimitiveType>::Native, delta: <IntervalMonthDayNanoType as ArrowPrimitiveType>::Native, ) -> Option<<Date32Type as ArrowPrimitiveType>::Native>
Subtract the given IntervalMonthDayNanoType to an arrow Date32Type
§Arguments
date- The date on which to perform the operationdelta- The interval to subtract
Returns Some(Date32Type) if it fits, None otherwise.
Trait Implementations§
Source§impl ArrowPrimitiveType for Date32Type
impl ArrowPrimitiveType for Date32Type
Source§impl Debug for Date32Type
impl Debug for Date32Type
Source§impl Parser for Date32Type
impl Parser for Date32Type
Source§impl RandomTemporalValue for Date32Type
Available on crate feature test_utils only.
impl RandomTemporalValue for Date32Type
test_utils only.Source§fn value_range() -> impl SampleRange<Self::Native>
fn value_range() -> impl SampleRange<Self::Native>
Range of values representing the elapsed time since UNIX epoch in days. The range begins at the start of the unix epoch and continues for 100 years.