1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-11 05:55:57 +00:00

add Context.ReadJSONProtobuf method

Former-commit-id: 9c7f268c0d7be7e405ea97a5ac12257beba3a4f3
This commit is contained in:
Gerasimos (Makis) Maropoulos
2020-06-28 23:05:07 +03:00
parent cdf0fe24e9
commit 871b4ef7fc
11 changed files with 362 additions and 6 deletions

View File

@@ -445,6 +445,7 @@ New Context Methods:
- `Context.Protobuf(proto.Message)` sends protobuf to the client
- `Context.MsgPack(interface{})` sends msgpack format data to the client
- `Context.ReadProtobuf(ptr)` binds request body to a proto message
- `Context.ReadJSONProtobuf(ptr, ...options)` binds JSON request body to a proto message
- `Context.ReadMsgPack(ptr)` binds request body of a msgpack format to a struct
- `Context.ReadBody(ptr)` binds the request body to the "ptr" depending on the request's Method and Content-Type
- `Context.Defer(Handler)` works like `Party.Done` but for the request life-cycle instead