forked from TrueCloudLab/frostfs-api-go
Evgenii Stratonikov
4a330a5706
gopatch: ``` @@ var err, msg, data, t, protojson identifier var obj expression @@ +import "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/rpc/message" -import protojson "google.golang.org/protobuf/encoding/protojson" -msg := obj -if err := protojson.Unmarshal(data, msg); err != nil { -return err -} -return t.FromGRPCMessage(msg) +return message.UnmarshalJSON(t, data, obj) @@ var err, msg, data, t, goproto identifier var obj expression @@ +import "git.frostfs.info/TrueCloudLab/frostfs-api-go/v2/rpc/message" -import goproto "google.golang.org/protobuf/proto" -msg := obj -if err := goproto.Unmarshal(data, msg); err != nil { -return err -} -return t.FromGRPCMessage(msg) +return message.Unmarshal(t, data, obj) ``` Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com> |
||
---|---|---|
.. | ||
grpc | ||
test | ||
convert.go | ||
json.go | ||
marshal.go | ||
message_test.go | ||
status.go | ||
status_test.go | ||
string.go | ||
types.go | ||
util.go | ||
xheaders.go |