Documentation
¶
Index ¶
Constants ¶
View Source
const ( // Success(httpCode,msg,data) HTTPEVENT_SUCCESS uint8 = 0x00 // Failure(httpCode,code, msg) HTTPEVENT_FAILURE uint8 = 0x01 // Error(httpCode,msg) HTTPEVENT_ERROR uint8 = 0xf0 // status text default DEFAULT_STATUS_TEXT = "" )
Variables ¶
This section is empty.
Functions ¶
func PutEchoResponder ¶
func PutEchoResponder(r *EchoResponder)
Types ¶
type EchoResponder ¶
type EchoResponder struct {
// contains filtered or unexported fields
}
func GetEchoResponder ¶
func GetEchoResponder(c echo.Context) *EchoResponder
func NewEchoResponder ¶
func NewEchoResponder(c echo.Context) EchoResponder
func (*EchoResponder) Failure ¶
func (rd *EchoResponder) Failure(httpCode, code int, msg string) error
func (*EchoResponder) ResponseHttp ¶
func (rd *EchoResponder) ResponseHttp(re HttpEvent) error
type EchoServer ¶
type EchoServer struct {
// contains filtered or unexported fields
}
web server echo encapsulation
func InitEchoServer ¶
func InitEchoServer() *EchoServer
func (*EchoServer) MountRoute ¶
func (es *EchoServer) MountRoute() router.Route[router.EchoPack]
MountRoute return the default gateway to mount the specified echo instance. The Gateway Routing from prefix==""
func (*EchoServer) SetupEchoServer ¶
func (es *EchoServer) SetupEchoServer(opts ...EchoServerOption)
func (*EchoServer) Start ¶
func (es *EchoServer) Start()
func (*EchoServer) Stop ¶
func (es *EchoServer) Stop()
func (*EchoServer) WithPeer ¶
func (es *EchoServer) WithPeer(p ...any)
func (*EchoServer) WithRoute ¶
func (es *EchoServer) WithRoute(r ...any)
type EchoServerOption ¶
type EchoServerOption func(es *EchoServer)
Functional echo server configuration.
Click to show internal directories.
Click to hide internal directories.