Struct WayfireSocket

Source
pub struct WayfireSocket { /* private fields */ }

Implementations§

Source§

impl WayfireSocket

Source

pub async fn connect() -> Result<Self>

Source

pub async fn send_json(&mut self, msg: &MsgTemplate) -> Result<Value>

Source

pub async fn read_exact(&mut self, n: usize) -> Result<Vec<u8>>

Source

pub async fn read_message(&mut self) -> Result<Value>

Source

pub async fn list_views(&mut self) -> Result<Vec<View>>

Source

pub async fn list_outputs(&mut self) -> Result<Vec<Output>>

Source

pub async fn list_wsets(&mut self) -> Result<Vec<WorkspaceSet>>

Source

pub async fn list_input_devices(&mut self) -> Result<Vec<InputDevice>>

Source

pub async fn get_configuration(&mut self) -> Result<WayfireConfiguration>

Source

pub async fn get_option_value( &mut self, option: &str, ) -> Result<OptionValueResponse>

Source

pub async fn get_output(&mut self, output_id: i64) -> Result<Output>

Source

pub async fn get_view(&mut self, view_id: i64) -> Result<View>

Source

pub async fn get_focused_view(&mut self) -> Result<View, Box<dyn Error>>

Source

pub async fn get_focused_output(&mut self) -> Result<Output, Box<dyn Error>>

Source

pub async fn get_view_alpha(&mut self, view_id: i64) -> Result<ViewAlpha>

Source

pub async fn set_view_alpha( &mut self, view_id: i64, alpha: f64, ) -> Result<Value>

Source

pub async fn get_tiling_layout( &mut self, wset: i64, x: i64, y: i64, ) -> Result<Layout>

Source

pub async fn set_tiling_layout( &mut self, wset: i64, x: i64, y: i64, layout: &Layout, ) -> Result<Value>

Source

pub async fn set_view_fullscreen( &mut self, view_id: i64, state: bool, ) -> Result<Value>

Source

pub async fn expo_toggle(&mut self) -> Result<Value>

Source

pub async fn scale_toggle(&mut self) -> Result<Value>

Source

pub async fn scale_toggle_all(&mut self) -> Result<Value>

Source

pub async fn cube_activate(&mut self) -> Result<Value>

Source

pub async fn cube_rotate_left(&mut self) -> Result<Value>

Source

pub async fn cube_rotate_right(&mut self) -> Result<Value>

Source

pub async fn toggle_showdesktop(&mut self) -> Result<Value>

Source

pub async fn set_view_sticky( &mut self, view_id: i64, state: bool, ) -> Result<Value>

Source

pub async fn send_view_to_back( &mut self, view_id: i64, state: bool, ) -> Result<Value>

Source

pub async fn set_view_minimized( &mut self, view_id: i64, state: bool, ) -> Result<Value>

Source

pub async fn configure_input_device( &mut self, id: i64, enabled: bool, ) -> Result<Value>

Source

pub async fn close_view(&mut self, view_id: i64) -> Result<Value>

Source

pub async fn wset_info(&mut self, id: i64) -> Result<Value>

Source

pub async fn watch(&mut self, events: Option<Vec<String>>) -> Result<Value>

Source

pub async fn configure_view( &mut self, view_id: i64, x: i64, y: i64, w: i64, h: i64, output_id: Option<i64>, ) -> Result<Value>

Source

pub async fn assign_slot(&mut self, view_id: i64, slot: &str) -> Result<Value>

Source

pub async fn set_focus(&mut self, view_id: i64) -> Result<Value>

Source

pub async fn set_workspace( &mut self, x: i64, y: i64, view_id: i64, output_id: i64, ) -> Result<Value>

Source

pub async fn create_headless_output( &mut self, width: u32, height: u32, ) -> Result<Value>

Source

pub async fn destroy_headless_output( &mut self, output_name: Option<String>, output_id: Option<i64>, ) -> Result<Value>

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.