Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cors ¶
func Cors() gin.HandlerFunc
Types ¶
type GrpcWebServer ¶
type GrpcWebServer struct {
StreamInterceptor grpc.StreamServerInterceptor
UnaryInterceptor grpc.UnaryServerInterceptor
AllowedOrigins []string
AllowAllOrigins bool
WrappedGrpc *grpcweb.WrappedGrpcServer
GrpcServer *grpc.Server
}
func (*GrpcWebServer) Serve ¶
func (server *GrpcWebServer) Serve() error
Serve start GrpcServer,GrpcWebServer with defined options
type RESTfulMux ¶
type WebServer ¶
type WebServer struct {
GrpcWebServer *GrpcWebServer
Router *gin.Engine
// contains filtered or unexported fields
}
func NewServer ¶
func NewServer(grpcWebServer *GrpcWebServer, allowCross bool) *WebServer
func (*WebServer) SetRESTfulMux ¶
func (s *WebServer) SetRESTfulMux(mux *RESTfulMux)
Click to show internal directories.
Click to hide internal directories.