Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IServer ¶
type IServer interface {
Start() error
}
IServer to specify the Server functionalities
type Server ¶
type Server struct {
IServer
// in case you call Server.Start
Addr string
LogAdapter adapter.LogAdapter
// contains filtered or unexported fields
}
Server is the base for the complete implementation of our nostr relay It will handle the incoming requests and delegate it to the corresponding functionalities in the backend e.g. relay
func (*Server) HandleWebsocket ¶
func (s *Server) HandleWebsocket(w http.ResponseWriter, r *http.Request)
HandleWebsocket function to exract and delegate traffic from websockets.
func (*Server) InjectHandler ¶
InjectHandler allows to inject custom http.Handlers into the server on a given path this will panic if the pattern is already registered
Click to show internal directories.
Click to hide internal directories.