package itest

import "github.com/libp2p/go-libp2p/p2p/test/resource-manager"

Index

Constants

const (
	EchoService = "test.echo"
	EchoProtoID = "/test/echo"
)

Types

type Echo

type Echo struct {
	Host host.Host
	// contains filtered or unexported fields
}

func NewEcho

func NewEcho(h host.Host) *Echo

func (*Echo) BeforeDone

func (e *Echo) BeforeDone(f func() error)

func (*Echo) BeforeRead

func (e *Echo) BeforeRead(f func() error)

func (*Echo) BeforeReserve

func (e *Echo) BeforeReserve(f func() error)

func (*Echo) BeforeWrite

func (e *Echo) BeforeWrite(f func() error)

func (*Echo) Done

func (e *Echo) Done(f func())

func (*Echo) Echo

func (e *Echo) Echo(p peer.ID, what string) error

func (*Echo) Status

func (e *Echo) Status() EchoStatus

type EchoStatus

type EchoStatus struct {
	StreamsIn                 int
	EchosIn, EchosOut         int
	IOErrors                  int
	ResourceServiceErrors     int
	ResourceReservationErrors int
}

Source Files

echo.go

Version
v0.42.0 (latest)
Published
Jun 18, 2025
Platform
linux/amd64
Imports
9 packages
Last checked
1 week ago

Tools for package owners.