Documentation ¶
Index ¶
- func ClientIP(r *http.Request) string
- func Cros(w http.ResponseWriter, req *http.Request, headers ...map[string]string)
- func E(err error)
- func MetaHost(ctx context.Context) string
- func MetaInt(ctx context.Context, key string) int
- func MetaIp(ctx context.Context) string
- func MetaMethod(ctx context.Context) string
- func MetaString(ctx context.Context, key string) string
- func MetaToken(ctx context.Context) string
- func Response(w http.ResponseWriter, code int, msg ...string)
- func StargoHTTPError(ctx context.Context, mux *runtime.ServeMux, marshaler runtime.Marshaler, ...)
- func Success(w http.ResponseWriter, msg ...string)
- type APIError
- type Api
- type Config
- type Request
- type RequestData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MetaMethod ¶ added in v0.1.8
func StargoHTTPError ¶ added in v0.1.8
func Success ¶
func Success(w http.ResponseWriter, msg ...string)
Types ¶
type Api ¶ added in v0.1.6
type Api struct {
// contains filtered or unexported fields
}
func (*Api) Conn ¶ added in v0.1.6
func (e *Api) Conn() *grpc.ClientConn
func (*Api) WrapperSwagger ¶ added in v0.1.8
type Request ¶
type Request struct { Data RequestData Query url.Values // contains filtered or unexported fields }
func NewRequest ¶ added in v0.1.8
type RequestData ¶
func (RequestData) Set ¶
func (e RequestData) Set(key string, value any) RequestData
Source Files ¶
Click to show internal directories.
Click to hide internal directories.