Documentation ¶
Index ¶
- type QuicHandler
- type QuicReadHandler
- type QuicWriteHandler
- type Server
- func (s *Server) Addr() string
- func (s *Server) DeregisterHandler(actionType types.HandlerType)
- func (s *Server) RegisterHandler(actionType types.HandlerType, handler QuicHandler)
- func (s *Server) Start(ctx context.Context) error
- func (s *Server) Stop() error
- func (s *Server) WaitStarted() <-chan struct{}
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type QuicHandler ¶
QuicHandler function type for QUIC
type QuicReadHandler ¶
type QuicReadHandler struct {
// contains filtered or unexported fields
}
QuicReadHandler struct with MDBX database passed in
func NewQuicReadHandler ¶
func NewQuicReadHandler(db db.Provider) *QuicReadHandler
NewQuicReadHandler creates a new QuicReadHandler with an MDBX database
func (*QuicReadHandler) HandleMessage ¶
func (rh *QuicReadHandler) HandleMessage(conn quic.Connection, stream quic.Stream, message *messages.Message)
HandleMessage processes the incoming message using the QuicReadHandler
type QuicWriteHandler ¶
type QuicWriteHandler struct {
// contains filtered or unexported fields
}
QuicWriteHandler struct with MDBX database passed in
func NewQuicWriteHandler ¶
func NewQuicWriteHandler(db db.Provider, batchWriter *db.BatchWriter) *QuicWriteHandler
NewQuicWriteHandler creates a new QuicWriteHandler with an MDBX database
func (*QuicWriteHandler) HandleMessage ¶
func (wh *QuicWriteHandler) HandleMessage(conn quic.Connection, stream quic.Stream, message *messages.Message)
HandleMessage processes the incoming message using the QuicWriteHandler
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server struct represents the QUIC server
func (*Server) DeregisterHandler ¶
func (s *Server) DeregisterHandler(actionType types.HandlerType)
DeregisterHandler deregisters a handler for a specific action
func (*Server) RegisterHandler ¶
func (s *Server) RegisterHandler(actionType types.HandlerType, handler QuicHandler)
RegisterHandler registers a handler for a specific action
func (*Server) WaitStarted ¶
func (s *Server) WaitStarted() <-chan struct{}
WaitStarted returns a channel that is closed when the server has started