Struct mortal::screen::ScreenReadGuard [] [src]

pub struct ScreenReadGuard<'a>(_);

Holds an exclusive lock for read operations on a Screen

See Screen documentation for details on locking.

Methods

impl<'a> ScreenReadGuard<'a>
[src]

[src]

Waits for an event from the terminal.

Returns Ok(false) if timeout elapses without an event occurring.

If timeout is None, this method will wait indefinitely.

Notes

Some low-level terminal events may not generate an Event value. Therefore, this method may return Ok(true), while a follow-up call to read_event may not immediately return an event.

[src]

Reads an event from the terminal.

If timeout elapses without an event occurring, this method will return Ok(None).

If timeout is None, this method will wait indefinitely.

Trait Implementations

impl<'a> TerminalExt for ScreenReadGuard<'a>
[src]

[src]

Reads raw data from the terminal. Read more

Auto Trait Implementations

impl<'a> !Send for ScreenReadGuard<'a>

impl<'a> Sync for ScreenReadGuard<'a>