connections

package
v0.0.0-...-a02e82a Latest Latest
Warning

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

Go to latest
Published: Sep 25, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Connection

type Connection interface {
	Connect() error
	Disconnect()
	Read() (string, error)
	Write(cmd string) int
	SetTimeout(timeout uint8)
}

func NewConnection

func NewConnection(host string, username string, password string, protocol string, port uint8) (Connection, error)

type SSHConn

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

func NewSSHConn

func NewSSHConn(hostname string, username string, password string, port uint8) (SSHConn, error)

func (*SSHConn) Connect

func (c *SSHConn) Connect() error

func (*SSHConn) Disconnect

func (c *SSHConn) Disconnect()

func (*SSHConn) Read

func (c *SSHConn) Read() (string, error)

func (*SSHConn) SetTimeout

func (c *SSHConn) SetTimeout(timeout uint8)

func (*SSHConn) Write

func (c *SSHConn) Write(cmd string) int

Jump to

Keyboard shortcuts

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