Parse2

Trait Parse2 

Source
pub trait Parse2<'a, 'b, C>
where Self: Sized, Self::I: Display,
{ type I; // Required methods fn parse2( i: Init<C, Self::I>, k: &'static str, c: &C, p: &mut ParsedArgs<'a, 'b>, ) -> Result<Self, ArgParseErr<'b>>; fn desc2( i: Init<C, Self::I>, d: &'static str, k: &'static str, c: &C, ) -> [String; 4]; fn default2(c: &C, i: Init<C, Self::I>) -> Self; }

Required Associated Types§

Source

type I

Required Methods§

Source

fn parse2( i: Init<C, Self::I>, k: &'static str, c: &C, p: &mut ParsedArgs<'a, 'b>, ) -> Result<Self, ArgParseErr<'b>>

Source

fn desc2( i: Init<C, Self::I>, d: &'static str, k: &'static str, c: &C, ) -> [String; 4]

Source

fn default2(c: &C, i: Init<C, Self::I>) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<'a, 'b, Ctx, T: Parse<'a> + Display> Parse2<'b, 'a, Ctx> for Vec<T>

Source§

type I = DisplayVec<T>

Source§

fn parse2( i: Init<Ctx, Self::I>, k: &'static str, c: &Ctx, p: &mut ParsedArgs<'b, 'a>, ) -> Result<Self, ArgParseErr<'a>>

Source§

fn desc2( i: Init<Ctx, Self::I>, d: &'static str, k: &'static str, c: &Ctx, ) -> [String; 4]

Source§

fn default2(c: &Ctx, i: Init<Ctx, Self::I>) -> Self

Source§

impl<'a, 'b, Ctx, T: Parse<'a>> Parse2<'b, 'a, Ctx> for Option<T>

Source§

type I = T

Source§

fn parse2( i: Init<Ctx, T>, k: &'static str, c: &Ctx, p: &mut ParsedArgs<'b, 'a>, ) -> Result<Self, ArgParseErr<'a>>

Source§

fn desc2( i: Init<Ctx, T>, d: &'static str, k: &'static str, c: &Ctx, ) -> [String; 4]

Source§

fn default2(c: &Ctx, i: Init<Ctx, Self::I>) -> Self

Implementors§

Source§

impl<'a, 'b, C, T: Parse<'a> + Default> Parse2<'b, 'a, C> for T

Source§

type I = T

Source§

impl<'a, 'b, Ctx, T: Parse<'a>> Parse2<'b, 'a, Ctx> for OptVec<T>