[#186] sdk/netmap: Use JSON placement policy converters in SDK
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
This commit is contained in:
parent
e4d94bbe03
commit
3fb3cfd1a5
1 changed files with 8 additions and 0 deletions
|
@ -11,3 +11,11 @@ type Filter = netmap.Filter
|
||||||
type Replica = netmap.Replica
|
type Replica = netmap.Replica
|
||||||
type Clause = netmap.Clause
|
type Clause = netmap.Clause
|
||||||
type Operation = netmap.Operation
|
type Operation = netmap.Operation
|
||||||
|
|
||||||
|
func PlacementPolicyToJSON(p *PlacementPolicy) ([]byte, error) {
|
||||||
|
return netmap.PlacementPolicyToJSON(p)
|
||||||
|
}
|
||||||
|
|
||||||
|
func PlacementPolicyFromJSON(data []byte) (*PlacementPolicy, error) {
|
||||||
|
return netmap.PlacementPolicyFromJSON(data)
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue