pub struct I3EventListener { /* private fields */ }Expand description
Abstraction over an ipc socket to i3. Handles events.
Implementations§
Source§impl I3EventListener
impl I3EventListener
Sourcepub fn connect() -> Result<I3EventListener, EstablishError>
pub fn connect() -> Result<I3EventListener, EstablishError>
Establishes the IPC connection.
Sourcepub fn subscribe(
&mut self,
events: &[Subscription],
) -> Result<Subscribe, MessageError>
pub fn subscribe( &mut self, events: &[Subscription], ) -> Result<Subscribe, MessageError>
Subscribes your connection to certain events.
Sourcepub fn listen(&mut self) -> EventIterator<'_> ⓘ
pub fn listen(&mut self) -> EventIterator<'_> ⓘ
Iterate over subscribed events forever.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for I3EventListener
impl RefUnwindSafe for I3EventListener
impl Send for I3EventListener
impl Sync for I3EventListener
impl Unpin for I3EventListener
impl UnwindSafe for I3EventListener
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