go-waku/waku/v2/node/service.go

21 lines
336 B
Go
Raw Normal View History

2023-01-06 22:37:57 +00:00
package node
import (
"context"
2023-04-17 00:04:12 +00:00
"github.com/libp2p/go-libp2p/core/host"
2023-05-05 09:49:15 +00:00
"github.com/waku-org/go-waku/waku/v2/protocol/relay"
2023-01-06 22:37:57 +00:00
)
type Service interface {
2023-04-17 00:04:12 +00:00
SetHost(h host.Host)
2023-05-05 09:49:15 +00:00
Start(context.Context) error
2023-01-06 22:37:57 +00:00
Stop()
}
type ReceptorService interface {
2023-05-05 09:49:15 +00:00
SetHost(h host.Host)
Stop()
Start(context.Context, relay.Subscription) error
2023-01-06 22:37:57 +00:00
}