Skip to main content
pub enum ColumnType 
Integer,
    Long,
    Float,
    Double,
    String,
    Bytes,
    Boolean,
    Int8,
    Int16,
    Timestamp,
    Array,
    Date,
    DateTime,
    Time,
    Decimal,
    Char1,
    Char2,
    Char4,
    Char8,
    Char16,
    Char32,
    Char64,
    Char128,
    Char256,
    Ipv4,
    Json,
    Ulong,
    Uuid,
    Wkt,
    Vector,
    Wkb,

Column types including subtypes determined by properties

Variants

Integer

Long

Float

Double

String

Bytes

Boolean

Int8

Int16

Timestamp

Array

Date

DateTime

Time

Decimal

Char1

Char2

Char4

Char8

Char16

Char32

Char64

Char128

Char256

Ipv4

Json

Ulong

Uuid

Wkt

Vector

Wkb

Implementations

Source

pub fn property(&self) -> Option<&‘static str>

The property that makes a column of this sub-type, where that one property alone does: boolean, timestamp, char16, decimal (18,4), wkt and so on. None for a base type, and for an array or a vector, whose property names its element type or dimensions.

Get the base type for this column type

Source

pub fn from_avro_and_properties(avro_type: &str, properties: &[String]) -> Self

Resolves a column’s type from its Avro type and properties: the base type from the Avro type, overridden by the first sub-type property in a fixed order of precedence (wkt giving WKT on a string column and WKB on a bytes one), and failing those by the first property starting array, vector or decimal.

Trait Implementations

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source

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

Performs copy-assignment from source. Read more
Source

fn fmt(&self, f: &mut Formatter<’_>) -> Result

Formats the value using the given formatter. Read more
Source

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source

fn eq(&self, other: &ColumnType) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.