risingwave_common::types

Type Alias DatumRef

source
pub type DatumRef<'a> = Option<ScalarRefImpl<'a>>;

Aliased Type§

enum DatumRef<'a> {
    None,
    Some(ScalarRefImpl<'a>),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(ScalarRefImpl<'a>)

Some value of type T.

Trait Implementations§

source§

impl DefaultOrd for DatumRef<'_>

source§

fn default_cmp(&self, other: &Self) -> Ordering

source§

impl DefaultPartialOrd for DatumRef<'_>

source§

fn default_partial_cmp(&self, other: &Self) -> Option<Ordering>

source§

impl ToDatumRef for DatumRef<'_>

source§

fn to_datum_ref(&self) -> DatumRef<'_>

Convert the datum to DatumRef.
source§

impl ToText for DatumRef<'_>

source§

fn write<W: Write>(&self, f: &mut W) -> Result

Write the text to the writer regardless of its data type Read more
source§

fn write_with_type<W: Write>(&self, ty: &DataType, f: &mut W) -> Result

Write the text to the writer according to its data type
source§

fn to_text_with_type(&self, ty: &DataType) -> String

Convert to text according to its data type
source§

fn to_text(&self) -> String

to_text is a special version of to_text_with_type, it convert the scalar to default type text. E.g. for Int64, it will convert to text as a Int64 type. We should prefer to use to_text_with_type because it’s more clear and readable. Read more