frostfs-api-go/tombstone/grpc/types.go
Evgenii Stratonikov 732dd51b1b [#388] *: Remove nil check from setters
I knew one day `sed` would save me an hour of manual work:
```
sed -i -n -e '
s/) Set/) Set/
p
t setter
b end
:setter
    n
    s/nil/nil/
    t hasif
    p
    b end
    :hasif
        n
        :loop
        p
        n
        s/}/}/
        t end
        b loop
        :end
' $@
goimports -w $@
```

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2022-03-31 11:32:04 +03:00

20 lines
466 B
Go

package tombstone
import (
refs "github.com/nspcc-dev/neofs-api-go/v2/refs/grpc"
)
// SetExpirationEpoch sets number of tombstone expiration epoch.
func (x *Tombstone) SetExpirationEpoch(v uint64) {
x.ExpirationEpoch = v
}
// SetSplitId sets identifier of split object hierarchy.
func (x *Tombstone) SetSplitId(v []byte) {
x.SplitId = v
}
// SetMembers sets list of objects to be deleted.
func (x *Tombstone) SetMembers(v []*refs.ObjectID) {
x.Members = v
}