cmdservice

package
v0.0.0-...-9648343 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2021 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Overview

Package cmdservice implements hosting of command-sets which can be called by clients via an HTTP-based API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(ctx context.Context, service string, req ipc.HostCommandSet) error

Types

type BP

type BP struct {
	Service    string
	Bind, Self string
	WS         *webservice.Server
}

func Boilerplate

func Boilerplate(sets ...Set) *BP

func (*BP) Run

func (bp *BP) Run(sets ...Set)

type Command

type Command struct {
	ipc.Command
	Handler webservice.HandlerFunc
}

type Set

type Set struct {
	ID       string
	Tag      string
	Commands []Command
	Whisper  bool
}

Jump to

Keyboard shortcuts

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