/// Cast to some primitive type.
Cast to some primitive type.
Cast to some primitive type .
pub fn cast<N>(&self) -> Result<Self>
    where
        N: PolarsDataType,
    {
        let s = match self {
            Series::Bool(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Utf8(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::UInt8(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::UInt16(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::UInt32(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::UInt64(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Int8(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Int16(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Int32(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Int64(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Float32(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Float64(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Date32(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Date64(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Time32Millisecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Time32Second(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Time64Nanosecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::Time64Microsecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::DurationNanosecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::DurationMicrosecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::DurationMillisecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::DurationSecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::TimestampNanosecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::TimestampMicrosecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::TimestampMillisecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::TimestampSecond(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::IntervalDayTime(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::IntervalYearMonth(arr) => pack_ca_to_series(arr.cast::<N>()?),
            Series::LargeList(arr) => pack_ca_to_series(arr.cast::<N>()?),
        };
        Ok(s)
    }
pub fn cast < N > ( & self ) -> Result < Self > where N : PolarsDataType , { let s = match self { Series :: Bool ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Utf8 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: UInt8 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: UInt16 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: UInt32 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: UInt64 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Int8 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Int16 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Int32 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Int64 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Float32 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Float64 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Date32 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Date64 ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Time32Millisecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Time32Second ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Time64Nanosecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: Time64Microsecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: DurationNanosecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: DurationMicrosecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: DurationMillisecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: DurationSecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: TimestampNanosecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: TimestampMicrosecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: TimestampMillisecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: TimestampSecond ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: IntervalDayTime ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: IntervalYearMonth ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , Series :: LargeList ( arr ) => pack_ca_to_series ( arr . cast :: < N > ( ) ? ) , } ; Ok ( s ) }
Cast to some primitive type.
Cast to some primitive type .
&self