pub struct CmdOptCache {
opt_names: Vec<String>,
lns: HashMap<String, (bool, usize)>,
ilns: HashMap<String, (bool, usize)>,
ln_aliases: HashMap<String, (bool, usize)>,
sns: HashMap<char, (bool, usize)>,
sn_aliases: HashMap<char, (bool, usize)>,
ext_opt_names: IndexMap<String, usize>,
exts: Vec<String>,
cmd_path: String,
last_needs_visible_full_name: bool,
current: String,
}Fields§
§opt_names: Vec<String>§lns: HashMap<String, (bool, usize)>§ilns: HashMap<String, (bool, usize)>§ln_aliases: HashMap<String, (bool, usize)>§sns: HashMap<char, (bool, usize)>§sn_aliases: HashMap<char, (bool, usize)>§ext_opt_names: IndexMap<String, usize>§exts: Vec<String>§cmd_path: String§last_needs_visible_full_name: bool§current: StringImplementations§
Source§impl CmdOptCache
impl CmdOptCache
pub fn new(cmd_path: String) -> Self
pub fn unchecked_populated(cmd: &App, cmd_path: String) -> Self
pub fn register(&mut self, name: &String, ext: Option<&Extension>) -> bool
pub fn iln_conflicts(&mut self, iln: &String) -> bool
pub fn ln_conflicts(&mut self, ln: &String) -> bool
pub fn sn_conflicts(&mut self, sn: char) -> bool
pub fn non_conflicting_snas(&mut self, snas: &Vec<char>) -> Vec<char>
pub fn non_conflicting_lnas(&mut self, lnas: &Vec<String>) -> Vec<String>
pub fn needs_visible_full_name(&mut self) -> bool
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CmdOptCache
impl RefUnwindSafe for CmdOptCache
impl Send for CmdOptCache
impl Sync for CmdOptCache
impl Unpin for CmdOptCache
impl UnwindSafe for CmdOptCache
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more