[#186] sdk/netmap: Use JSON placement policy converters in SDK

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
Alex Vanin 2020-11-02 18:17:15 +03:00 committed by Alex Vanin
parent e4d94bbe03
commit 3fb3cfd1a5

View file

@ -11,3 +11,11 @@ type Filter = netmap.Filter
type Replica = netmap.Replica
type Clause = netmap.Clause
type Operation = netmap.Operation
func PlacementPolicyToJSON(p *PlacementPolicy) ([]byte, error) {
return netmap.PlacementPolicyToJSON(p)
}
func PlacementPolicyFromJSON(data []byte) (*PlacementPolicy, error) {
return netmap.PlacementPolicyFromJSON(data)
}