sessionutil

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 2, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package sessionutil contains utility methods required to start session.

Package sessionutil provides utility for sessions.

Package sessionutil provides utility for sessions.

Index

Constants

This section is empty.

Variables

ControlSignals contains the list of signals that can be used to control the session.

View Source
var SignalsByteMap = map[os.Signal]byte{
	syscall.SIGINT:  '\003',
	syscall.SIGQUIT: '\x1c',
	syscall.SIGTSTP: '\032',
}

SignalsByteMap maps OS signals to their corresponding byte values. SIGINT captures Ctrl+C SIGQUIT captures Ctrl+\ SIGTSTP captures Ctrl+Z.

Functions

func NewListener

func NewListener(address string) (net.Listener, error)

NewListener starts a new socket listener on the address.

Types

type DisplayMode

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

DisplayMode represents a display mode for Unix-like systems.

func NewDisplayMode

func NewDisplayMode(logger log.T) DisplayMode

NewDisplayMode creates and initializes a new DisplayMode instance.

func (*DisplayMode) DisplayMessage

func (d *DisplayMode) DisplayMessage(message message.ClientMessage)

DisplayMessage function displays the output on the screen.

Jump to

Keyboard shortcuts

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