Trait polars_time::chunkedarray::utf8::Utf8Methods
source · pub trait Utf8Methods: AsUtf8 {
fn as_time(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<TimeChunked> { ... }
fn as_date_not_exact(&self, fmt: Option<&str>) -> PolarsResult<DateChunked> { ... }
fn as_datetime_not_exact(
&self,
fmt: Option<&str>,
tu: TimeUnit
) -> PolarsResult<DatetimeChunked> { ... }
fn as_date(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<DateChunked> { ... }
fn as_datetime(
&self,
fmt: Option<&str>,
tu: TimeUnit,
cache: bool,
tz_aware: bool
) -> PolarsResult<DatetimeChunked> { ... }
}
Provided Methods§
sourcefn as_time(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<TimeChunked>
fn as_time(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<TimeChunked>
Available on crate feature
dtype-time
only.Parsing string values and return a TimeChunked
sourcefn as_date_not_exact(&self, fmt: Option<&str>) -> PolarsResult<DateChunked>
fn as_date_not_exact(&self, fmt: Option<&str>) -> PolarsResult<DateChunked>
Available on crate feature
dtype-date
only.Parsing string values and return a DateChunked
Different from as_date
this function allows matches that not contain the whole string
e.g. “foo-2021-01-01-bar” could match “2021-01-01”
sourcefn as_datetime_not_exact(
&self,
fmt: Option<&str>,
tu: TimeUnit
) -> PolarsResult<DatetimeChunked>
fn as_datetime_not_exact(
&self,
fmt: Option<&str>,
tu: TimeUnit
) -> PolarsResult<DatetimeChunked>
Available on crate feature
dtype-datetime
only.Parsing string values and return a DatetimeChunked
Different from as_datetime
this function allows matches that not contain the whole string
e.g. “foo-2021-01-01-bar” could match “2021-01-01”
sourcefn as_date(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<DateChunked>
fn as_date(&self, fmt: Option<&str>, cache: bool) -> PolarsResult<DateChunked>
Available on crate feature
dtype-date
only.Parsing string values and return a DateChunked
sourcefn as_datetime(
&self,
fmt: Option<&str>,
tu: TimeUnit,
cache: bool,
tz_aware: bool
) -> PolarsResult<DatetimeChunked>
fn as_datetime(
&self,
fmt: Option<&str>,
tu: TimeUnit,
cache: bool,
tz_aware: bool
) -> PolarsResult<DatetimeChunked>
Available on crate feature
dtype-datetime
only.Parsing string values and return a DatetimeChunked