Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MustMarshal ¶
MustMarshal marshals an object and panics if it failures. This function should only be used when the object being passed in does not have any chance of failing (i.e. you constructed the object yourself)
Types ¶
type JSONMarshaler ¶ added in v1.0.0
type JSONMarshaler struct{}
JSONMarshaler is a type which satisfies the grpc-gateway Marshaler interface
func (*JSONMarshaler) ContentType ¶ added in v1.0.0
func (j *JSONMarshaler) ContentType() string
ContentType implements gwruntime.Marshaler.
func (*JSONMarshaler) Marshal ¶ added in v1.0.0
func (j *JSONMarshaler) Marshal(v any) ([]byte, error)
Marshal implements gwruntime.Marshaler.
func (*JSONMarshaler) NewDecoder ¶ added in v1.0.0
func (j *JSONMarshaler) NewDecoder(r io.Reader) gwruntime.Decoder
NewDecoder implements gwruntime.Marshaler.
func (*JSONMarshaler) NewEncoder ¶ added in v1.0.0
func (j *JSONMarshaler) NewEncoder(w io.Writer) gwruntime.Encoder
NewEncoder implements gwruntime.Marshaler.
Click to show internal directories.
Click to hide internal directories.