Documentation ¶ Index ¶ func Call[A, B, C any](...) func ParseRequest[T any](c *gin.Context) (*T, error) func ParseRequestNotCheck[T any](c *gin.Context) (*T, error) type Option func NewNilReplaceOption[A, B, C any](...) *Option[A, B] Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func Call ¶ func Call[A, B, C any](rpc func(client C, ctx context.Context, req *A, options ...grpc.CallOption) (*B, error), client C, c *gin.Context, opts ...*Option[A, B]) func ParseRequest ¶ func ParseRequest[T any](c *gin.Context) (*T, error) func ParseRequestNotCheck ¶ func ParseRequestNotCheck[T any](c *gin.Context) (*T, error) Types ¶ type Option ¶ type Option[A, B any] struct { // BindAfter is called after the req is bind from ctx. BindAfter func(*A) error // RespAfter is called after the resp is return from rpc. RespAfter func(*B) error } func NewNilReplaceOption ¶ added in v1.1.0 func NewNilReplaceOption[A, B, C any](_ func(client C, ctx context.Context, req *A, options ...grpc.CallOption) (*B, error)) *Option[A, B] Source Files ¶ View all Source files api2rpc.go option.go Click to show internal directories. Click to hide internal directories.