pilot

package
v0.0.0-...-854bc80 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GodotPilot

type GodotPilot struct {
	Cmd      *exec.Cmd
	Chans    *StandardChans
	Pipes    *StandardPipes
	OnStdOut func(line string)
	OnStdErr func(line string)
	// contains filtered or unexported fields
}

GodotPilot manages the execution of a Godot executable and handles its I/O streams.

func NewGodotPilot

func NewGodotPilot(onStdOut func(line string), onStdErr func(line string), executablePath string, arguments ...string) *GodotPilot

NewGodotPilot initializes and returns a new GodotPilot instance.

func (*GodotPilot) Start

func (gp *GodotPilot) Start() error

Start begins the execution of the Godot executable and starts goroutines to handle its I/O streams.

type StandardChans

type StandardChans struct {
	In   chan string
	Out  chan string
	Err  chan string
	Quit chan struct{}
}

StandardChans holds channels for communication between the GodotPilot and the Go application.

func NewStandardChans

func NewStandardChans() *StandardChans

NewStandardChans initializes and returns a new StandardChans instance.

type StandardPipes

type StandardPipes struct {
	In  io.WriteCloser
	Out io.ReadCloser
	Err io.ReadCloser
}

StandardPipes holds the standard input, output, and error pipes.

Jump to

Keyboard shortcuts

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