Documentation
¶
Index ¶
Constants ¶
View Source
const ( SplitCommandStr = "InBugW_H_A_Z" CommandEndStr = "========InBugCommandRunEnd========" )
Variables ¶
View Source
var (
DefaultTerminalConfig = &TerminalConfig{
BufferSize: 1024 * 4,
}
)
Functions ¶
Types ¶
type ITerminal ¶
type ITerminal interface { Exec(command string, isWaitInput ...bool) error Terminate() error Close() error GetID() string SetID(id string) }
func NewTerminal ¶
func NewTerminal(handleMsg func(id string, msgBytes []byte), terminalConfig ...*TerminalConfig) ITerminal
type LinuxTerminal ¶
type LinuxTerminal struct {
Terminal
}
func NewLinuxTerminal ¶
func NewLinuxTerminal(handleMsg func(id string, msgBytes []byte), terminalConfig *TerminalConfig, terminalId ...string) *LinuxTerminal
type Terminal ¶
type TerminalConfig ¶
type TerminalConfig struct {
BufferSize int32
}
type TerminalManagerStruct ¶
func GetTerminalManager ¶
func GetTerminalManager() *TerminalManagerStruct
func (*TerminalManagerStruct) CloseAll ¶
func (b *TerminalManagerStruct) CloseAll() bool
func (*TerminalManagerStruct) Exec ¶
func (b *TerminalManagerStruct) Exec(id string, command string) error
func (*TerminalManagerStruct) Get ¶
func (b *TerminalManagerStruct) Get(id string) ITerminal
func (*TerminalManagerStruct) GetAll ¶
func (b *TerminalManagerStruct) GetAll() map[string]ITerminal
type WindowsTerminal ¶
type WindowsTerminal struct {
Terminal
}
func NewWindowsTerminal ¶
func NewWindowsTerminal(handleMsg func(id string, msgBytes []byte), terminalConfig *TerminalConfig, terminalId ...string) *WindowsTerminal
Click to show internal directories.
Click to hide internal directories.