ioconn

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: May 9, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dial

func Dial(in io.ReadCloser, out io.WriteCloser) (net.Conn, error)

Dial creates a new network connection using the provided input and output streams. It returns a net.Conn interface and an error, if any. The input stream is used for reading data from the connection, and the output stream is used for writing data to the connection.

func DialCmd

func DialCmd(cmd *exec.Cmd) (net.Conn, io.ReadCloser, error)

DialCmd is a function that establishes a connection to a command's standard input, output, and error streams. It takes a *exec.Cmd as input and returns a net.Conn, io.ReadCloser, and error. The net.Conn represents the connection to the command's standard input and output streams. The io.ReadCloser represents the command's standard error stream. The error represents any error that occurred during the connection establishment.

func ListenFromSingleIO

func ListenFromSingleIO(in io.ReadCloser, out io.WriteCloser) (net.Listener, error)

ListenFromSingleIO creates a net.Listener from a single input/output connection. It takes an io.ReadCloser and an io.WriteCloser as parameters and returns a net.Listener and an error. The returned net.Listener can be used to accept incoming connections.

Types

This section is empty.

Jump to

Keyboard shortcuts

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