[][src]Trait pgx::inoutfuncs::PgVarlenaInOutFuncs

pub trait PgVarlenaInOutFuncs {
    fn input(input: &CStr) -> PgVarlena<Self>
    where
        Self: Copy + Sized
;
fn output(&self, buffer: &mut StringInfo); }

#[derive(Copy, Clone, PostgresType)] types need to implement this trait to provide the text input/output functions for that type

Required methods

fn input(input: &CStr) -> PgVarlena<Self> where
    Self: Copy + Sized

Given a string representation of Self, parse it into a PgVarlena<Self>.

It is expected that malformed input will raise an error!() or panic!()

fn output(&self, buffer: &mut StringInfo)

Convert Self into text by writing to the supplied StringInfo buffer

Loading content...

Implementors

Loading content...