remotes

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2018 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClient

func NewClient(conn gopi.RPCClientConn) gopi.RPCClient

Types

type Client

type Client struct {
	pb.RemotesClient
	// contains filtered or unexported fields
}

func (*Client) Codecs

func (this *Client) Codecs() ([]remotes.CodecType, error)

Return array of codecs supported

func (*Client) Conn

func (this *Client) Conn() gopi.RPCClientConn

func (*Client) KeyMaps

func (this *Client) KeyMaps() ([]*KeyMapInfo, error)

Return array of keymaps learnt

func (*Client) Keys

func (this *Client) Keys(keymap string) ([]*Key, error)

Return keys learnt by keymap name

func (*Client) LookupKeys

func (this *Client) LookupKeys(keymap string, terms []string) ([]*Key, error)

Return keys with one or more search terms and optional keymap argument to narrow search to a keymap entries

func (*Client) NewContext

func (this *Client) NewContext() context.Context

func (*Client) Receive

func (this *Client) Receive(ctx context.Context, evt chan<- *Event) error

Receive remote events

func (*Client) SendKeycode

func (this *Client) SendKeycode(keymap string, keycode remotes.RemoteCode, repeats uint) error

Send a remote keycode

func (*Client) SendScancode

func (this *Client) SendScancode(codec remotes.CodecType, device, scancode uint32, repeats uint) error

Send a remote scancode

func (*Client) String

func (this *Client) String() string

type Event

type Event struct {
	InputEvent
	Key
	KeyMapInfo
}

func (*Event) String

func (this *Event) String() string

type InputEvent

type InputEvent struct {
	Timestamp  time.Duration
	DeviceType gopi.InputDeviceType
	EventType  gopi.InputEventType
	Keycode    remotes.RemoteCode
}

type Key

type Key struct {
	remotes.KeyMapEntry
}

type KeyMapInfo

type KeyMapInfo struct {
	remotes.KeyMap
	Keys uint
}

type Service

type Service struct {
	Server  gopi.RPCServer
	KeyMaps remotes.KeyMaps
}

func (Service) Open

func (config Service) Open(log gopi.Logger) (gopi.Driver, error)

Open the server

Jump to

Keyboard shortcuts

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