forked from TrueCloudLab/frostfs-node
[#33] placement: Add public constructor for netmap placement builder
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>support/v0.27
parent
900949c648
commit
12e5e4e2d8
|
@ -10,6 +10,12 @@ type netMapBuilder struct {
|
|||
nm *netmap.Netmap
|
||||
}
|
||||
|
||||
func NewNetworkMapBuilder(nm *netmap.Netmap) Builder {
|
||||
return &netMapBuilder{
|
||||
nm: nm,
|
||||
}
|
||||
}
|
||||
|
||||
func (b *netMapBuilder) BuildPlacement(a *object.Address, p *netmap.PlacementPolicy) ([]netmap.Nodes, error) {
|
||||
aV2 := a.ToV2()
|
||||
|
||||
|
|
Loading…
Reference in New Issue