[][src]Struct term::terminfo::TermInfo

pub struct TermInfo {
    pub names: Vec<String>,
    pub bools: HashMap<&'static str, bool>,
    pub numbers: HashMap<&'static str, u32>,
    pub strings: HashMap<&'static str, Vec<u8>>,
}

A parsed terminfo database entry.

Fields

names: Vec<String>

Names for the terminal

bools: HashMap<&'static str, bool>

Map of capability name to boolean value

numbers: HashMap<&'static str, u32>

Map of capability name to numeric value

strings: HashMap<&'static str, Vec<u8>>

Map of capability name to raw (unexpanded) string

Implementations

impl TermInfo[src]

pub fn from_env() -> Result<TermInfo>[src]

Create a TermInfo based on current environment.

pub fn from_name(name: &str) -> Result<TermInfo>[src]

Create a TermInfo for the named terminal.

pub fn from_path<P: AsRef<Path>>(path: P) -> Result<TermInfo>[src]

Parse the given TermInfo.

pub fn apply_cap(
    &self,
    cmd: &str,
    params: &[Param],
    out: &mut dyn Write
) -> Result<()>
[src]

Retrieve a capability cmd and expand it with params, writing result to out.

pub fn reset(&self, out: &mut dyn Write) -> Result<()>[src]

Write the reset string to out.

Trait Implementations

impl Clone for TermInfo[src]

impl Debug for TermInfo[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.