remote_conn

package
v0.0.0-...-32d88a2 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DialogueTypeMain = DialogueType(iota)
	DialogueTypeSkusForFilter
	DialogueTypeObjects
	DialogueTypeBlobs
	DialogueTypeObjectReader
	DialogueTypeBlobReader
	DialogueTypeObjectWriter
	DialogueTypeBlobWriter
	DialogueTypePull
	DialogueTypePullBLob
	DialogueTypePush
	DialogueTypePushObjects
	DialogueTypePushBlob
	DialogueTypeGetNeededSkus
)

Variables

This section is empty.

Functions

func ReturnConnLicense

func ReturnConnLicense()

func WaitForConnectionLicense

func WaitForConnectionLicense()

Types

type Dialogue

type Dialogue struct {
	Angeboren interfaces.ImmutableConfig
	// contains filtered or unexported fields
}

func (Dialogue) Close

func (s Dialogue) Close() (err error)

func (Dialogue) GetAngeboren

func (d Dialogue) GetAngeboren() interfaces.ImmutableConfig

func (Dialogue) Read

func (s Dialogue) Read(p []byte) (n int, err error)

func (Dialogue) Receive

func (s Dialogue) Receive(e any) (err error)

func (Dialogue) Send

func (s Dialogue) Send(e any) (err error)

func (Dialogue) Type

func (s Dialogue) Type() DialogueType

func (Dialogue) Write

func (s Dialogue) Write(p []byte) (n int, err error)

type DialogueType

type DialogueType int

TODO-P4 rename to RemoteRequest

func (DialogueType) String

func (i DialogueType) String() string

type Listener

type Listener interface {
	Listen() error
}

type MessageHiCommander

type MessageHiCommander struct {
	DialogueType
	CliKonfig mutable_config_blobs.Cli
	Angeboren interfaces.ImmutableConfig
}

type MessageHiSoldier

type MessageHiSoldier struct {
	Angeboren interfaces.ImmutableConfig
}

type Script

type Script interface {
	HandleSenderDialogue(Dialogue) error
	HandleReceiverDialogue(Dialogue) error
}

type SoldierDialogueChanElement

type SoldierDialogueChanElement struct {
	Dialogue
	MessageHiCommander
	// contains filtered or unexported fields
}

type StageCommander

type StageCommander struct {
	Angeboren interfaces.ImmutableConfigGetter
	// contains filtered or unexported fields
}

func MakeStageCommander

func MakeStageCommander(
	u *env.Env,
	from string,
	command string,
) (s *StageCommander, err error)

func (StageCommander) ChanRemoteCommandDone

func (s StageCommander) ChanRemoteCommandDone() <-chan struct{}

func (StageCommander) Close

func (s StageCommander) Close() (err error)

func (StageCommander) MainDialogue

func (s StageCommander) MainDialogue() Dialogue

func (StageCommander) ShouldIgnoreConnectionError

func (c StageCommander) ShouldIgnoreConnectionError(in error) (ok bool)

func (*StageCommander) StartDialogue

func (s *StageCommander) StartDialogue(t DialogueType) (d Dialogue, err error)

type StageSoldier

type StageSoldier struct {
	Angeboren interfaces.ImmutableConfigGetter
	// contains filtered or unexported fields
}

func MakeStageSoldier

func MakeStageSoldier(u *env.Env) (
	s *StageSoldier,
	err error,
)

func (*StageSoldier) AwaitDialogue

func (s *StageSoldier) AwaitDialogue() (out SoldierDialogueChanElement)

func (StageSoldier) Close

func (s StageSoldier) Close() (err error)

func (*StageSoldier) Listen

func (s *StageSoldier) Listen() (err error)

func (StageSoldier) MainDialogue

func (s StageSoldier) MainDialogue() Dialogue

func (*StageSoldier) RegisterHandler

func (s *StageSoldier) RegisterHandler(
	t DialogueType,
	h func(Dialogue) error,
)

Jump to

Keyboard shortcuts

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