session

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2026 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 BaseSession

type BaseSession struct {
	sync.WaitGroup // For no-copy status

	ID       uuid.UUID // Internal ID
	Peer     domain.Peer
	Incoming bool // Indicate that the instance was created by an external connection
	LastDial time.Time
}

type Session

type Session interface {
	GetID() uuid.UUID
	GetLastDial() time.Time
	GetReadChannel(context.Context) (<-chan *pb.Message, error)
	GetWriteChannel(context.Context) (chan<- *pb.Message, error)
	GetPeerID() uuid.UUID
	IsIncoming() bool
	IsOpen() bool
	Close(context.Context)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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