client

package
v0.0.0-...-9034d5a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 25, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type WmClient

type WmClient struct {
	// contains filtered or unexported fields
}

func NewWmClient

func NewWmClient() *WmClient

NewWmClient initializes the new client

func (*WmClient) Close

func (client *WmClient) Close()

Close closes the connection

func (*WmClient) Connect

func (client *WmClient) Connect() error

Connect connects to the websocket at the default port

func (*WmClient) GetMonitors

func (client *WmClient) GetMonitors() ([]shared.Monitor, error)

GetMonitors lists all monitors and puts them into the structs

func (*WmClient) GetWindows

func (client *WmClient) GetWindows() ([]shared.Window, error)

GetWindows lists all windows and puts them into the structs

func (*WmClient) GetWorkspaces

func (client *WmClient) GetWorkspaces() ([]shared.Workspace, error)

GetWorkspaces lists all workspaces and puts them into the structs

func (*WmClient) ReadMessage

func (client *WmClient) ReadMessage() (string, error)

ReadMessage interprets the message from socket and returns it as string

func (*WmClient) RunCommand

func (client *WmClient) RunCommand(command command.WmCommand) error

RunCommand runs the command

func (*WmClient) SendMessage

func (client *WmClient) SendMessage(message string) error

SendMessage takes a string and sends it to the websocket

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL