[#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>
This commit is contained in:
Evgenii Stratonikov 2022-03-23 14:42:57 +03:00 committed by Alex Vanin
parent 50162741ac
commit 732dd51b1b
32 changed files with 714 additions and 2104 deletions

View file

@ -40,10 +40,8 @@ func (b *BalanceRequestBody) GetOwnerID() *refs.OwnerID {
}
func (b *BalanceRequestBody) SetOwnerID(v *refs.OwnerID) {
if b != nil {
b.ownerID = v
}
}
func (b *BalanceRequest) GetBody() *BalanceRequestBody {
if b != nil {
@ -54,10 +52,8 @@ func (b *BalanceRequest) GetBody() *BalanceRequestBody {
}
func (b *BalanceRequest) SetBody(v *BalanceRequestBody) {
if b != nil {
b.body = v
}
}
func (d *Decimal) GetValue() int64 {
if d != nil {
@ -68,10 +64,8 @@ func (d *Decimal) GetValue() int64 {
}
func (d *Decimal) SetValue(v int64) {
if d != nil {
d.val = v
}
}
func (d *Decimal) GetPrecision() uint32 {
if d != nil {
@ -82,10 +76,8 @@ func (d *Decimal) GetPrecision() uint32 {
}
func (d *Decimal) SetPrecision(v uint32) {
if d != nil {
d.prec = v
}
}
func (br *BalanceResponseBody) GetBalance() *Decimal {
if br != nil {
@ -96,10 +88,8 @@ func (br *BalanceResponseBody) GetBalance() *Decimal {
}
func (br *BalanceResponseBody) SetBalance(v *Decimal) {
if br != nil {
br.bal = v
}
}
func (br *BalanceResponse) GetBody() *BalanceResponseBody {
if br != nil {
@ -110,7 +100,5 @@ func (br *BalanceResponse) GetBody() *BalanceResponseBody {
}
func (br *BalanceResponse) SetBody(v *BalanceResponseBody) {
if br != nil {
br.body = v
}
}

View file

@ -7,56 +7,40 @@ import (
// SetOwnerId sets identifier of the account owner.
func (m *BalanceRequest_Body) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetBody sets body of the request.
func (m *BalanceRequest) SetBody(v *BalanceRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *BalanceRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *BalanceRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetBalance sets balance value of the response.
func (m *BalanceResponse_Body) SetBalance(v *Decimal) {
if m != nil {
m.Balance = v
}
}
// SetBody sets body of the response.
func (m *BalanceResponse) SetBody(v *BalanceResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *BalanceResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *BalanceResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}

View file

@ -2,14 +2,10 @@ package accounting
// SetValue sets value of the decimal number.
func (m *Decimal) SetValue(v int64) {
if m != nil {
m.Value = v
}
}
// SetPrecision sets precision of the decimal number.
func (m *Decimal) SetPrecision(v uint32) {
if m != nil {
m.Precision = v
}
}

View file

@ -6,150 +6,108 @@ import (
// SetVersion sets version of EACL rules in table.
func (m *EACLTable) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetContainerId sets container identifier of the eACL table.
func (m *EACLTable) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetRecords sets record list of the eACL table.
func (m *EACLTable) SetRecords(v []*EACLRecord) {
if m != nil {
m.Records = v
}
}
// SetOperation sets operation of the eACL record.
func (m *EACLRecord) SetOperation(v Operation) {
if m != nil {
m.Operation = v
}
}
// SetAction sets action of the eACL record.
func (m *EACLRecord) SetAction(v Action) {
if m != nil {
m.Action = v
}
}
// SetFilters sets filter list of the eACL record.
func (m *EACLRecord) SetFilters(v []*EACLRecord_Filter) {
if m != nil {
m.Filters = v
}
}
// SetTargets sets target list of the eACL record.
func (m *EACLRecord) SetTargets(v []*EACLRecord_Target) {
if m != nil {
m.Targets = v
}
}
// SetHeader sets header type of the eACL filter.
func (m *EACLRecord_Filter) SetHeader(v HeaderType) {
if m != nil {
m.HeaderType = v
}
}
// SetMatchType sets match type of the eACL filter.
func (m *EACLRecord_Filter) SetMatchType(v MatchType) {
if m != nil {
m.MatchType = v
}
}
// SetKey sets key of the eACL filter.
func (m *EACLRecord_Filter) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the eACL filter.
func (m *EACLRecord_Filter) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetRole sets target group of the eACL target.
func (m *EACLRecord_Target) SetRole(v Role) {
if m != nil {
m.Role = v
}
}
// SetKeys of the eACL target.
func (m *EACLRecord_Target) SetKeys(v [][]byte) {
if m != nil {
m.Keys = v
}
}
// SetEaclTable sets eACL table of the bearer token.
func (m *BearerToken_Body) SetEaclTable(v *EACLTable) {
if m != nil {
m.EaclTable = v
}
}
// SetOwnerId sets identifier of the bearer token owner.
func (m *BearerToken_Body) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetLifetime sets lifetime of the bearer token.
func (m *BearerToken_Body) SetLifetime(v *BearerToken_Body_TokenLifetime) {
if m != nil {
m.Lifetime = v
}
}
// SetBody sets bearer token body.
func (m *BearerToken) SetBody(v *BearerToken_Body) {
if m != nil {
m.Body = v
}
}
// SetSignature sets bearer token signature.
func (m *BearerToken) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetExp sets epoch number of the token expiration.
func (m *BearerToken_Body_TokenLifetime) SetExp(v uint64) {
if m != nil {
m.Exp = v
}
}
// SetNbf sets starting epoch number of the token.
func (m *BearerToken_Body_TokenLifetime) SetNbf(v uint64) {
if m != nil {
m.Nbf = v
}
}
// SetIat sets the number of the epoch in which the token was issued.
func (m *BearerToken_Body_TokenLifetime) SetIat(v uint64) {
if m != nil {
m.Iat = v
}
}
// FromString parses Action from a string representation,
// It is a reverse action to String().

View file

@ -121,10 +121,8 @@ func (f *HeaderFilter) GetHeaderType() HeaderType {
}
func (f *HeaderFilter) SetHeaderType(v HeaderType) {
if f != nil {
f.hdrType = v
}
}
func (f *HeaderFilter) GetMatchType() MatchType {
if f != nil {
@ -135,10 +133,8 @@ func (f *HeaderFilter) GetMatchType() MatchType {
}
func (f *HeaderFilter) SetMatchType(v MatchType) {
if f != nil {
f.matchType = v
}
}
func (f *HeaderFilter) GetKey() string {
if f != nil {
@ -149,10 +145,8 @@ func (f *HeaderFilter) GetKey() string {
}
func (f *HeaderFilter) SetKey(v string) {
if f != nil {
f.key = v
}
}
func (f *HeaderFilter) GetValue() string {
if f != nil {
@ -163,10 +157,8 @@ func (f *HeaderFilter) GetValue() string {
}
func (f *HeaderFilter) SetValue(v string) {
if f != nil {
f.value = v
}
}
func (t *Target) GetRole() Role {
if t != nil {
@ -177,10 +169,8 @@ func (t *Target) GetRole() Role {
}
func (t *Target) SetRole(v Role) {
if t != nil {
t.role = v
}
}
func (t *Target) GetKeys() [][]byte {
if t != nil {
@ -191,10 +181,8 @@ func (t *Target) GetKeys() [][]byte {
}
func (t *Target) SetKeys(v [][]byte) {
if t != nil {
t.keys = v
}
}
func (r *Record) GetOperation() Operation {
if r != nil {
@ -205,10 +193,8 @@ func (r *Record) GetOperation() Operation {
}
func (r *Record) SetOperation(v Operation) {
if r != nil {
r.op = v
}
}
func (r *Record) GetAction() Action {
if r != nil {
@ -219,10 +205,8 @@ func (r *Record) GetAction() Action {
}
func (r *Record) SetAction(v Action) {
if r != nil {
r.action = v
}
}
func (r *Record) GetFilters() []HeaderFilter {
if r != nil {
@ -233,10 +217,8 @@ func (r *Record) GetFilters() []HeaderFilter {
}
func (r *Record) SetFilters(v []HeaderFilter) {
if r != nil {
r.filters = v
}
}
func (r *Record) GetTargets() []Target {
if r != nil {
@ -247,10 +229,8 @@ func (r *Record) GetTargets() []Target {
}
func (r *Record) SetTargets(v []Target) {
if r != nil {
r.targets = v
}
}
func (t *Table) GetVersion() *refs.Version {
if t != nil {
@ -261,10 +241,8 @@ func (t *Table) GetVersion() *refs.Version {
}
func (t *Table) SetVersion(v *refs.Version) {
if t != nil {
t.version = v
}
}
func (t *Table) GetContainerID() *refs.ContainerID {
if t != nil {
@ -275,10 +253,8 @@ func (t *Table) GetContainerID() *refs.ContainerID {
}
func (t *Table) SetContainerID(v *refs.ContainerID) {
if t != nil {
t.cid = v
}
}
func (t *Table) GetRecords() []Record {
if t != nil {
@ -289,10 +265,8 @@ func (t *Table) GetRecords() []Record {
}
func (t *Table) SetRecords(v []Record) {
if t != nil {
t.records = v
}
}
func (l *TokenLifetime) GetExp() uint64 {
if l != nil {
@ -303,10 +277,8 @@ func (l *TokenLifetime) GetExp() uint64 {
}
func (l *TokenLifetime) SetExp(v uint64) {
if l != nil {
l.exp = v
}
}
func (l *TokenLifetime) GetNbf() uint64 {
if l != nil {
@ -317,10 +289,8 @@ func (l *TokenLifetime) GetNbf() uint64 {
}
func (l *TokenLifetime) SetNbf(v uint64) {
if l != nil {
l.nbf = v
}
}
func (l *TokenLifetime) GetIat() uint64 {
if l != nil {
@ -331,10 +301,8 @@ func (l *TokenLifetime) GetIat() uint64 {
}
func (l *TokenLifetime) SetIat(v uint64) {
if l != nil {
l.iat = v
}
}
func (bt *BearerTokenBody) GetEACL() *Table {
if bt != nil {
@ -345,10 +313,8 @@ func (bt *BearerTokenBody) GetEACL() *Table {
}
func (bt *BearerTokenBody) SetEACL(v *Table) {
if bt != nil {
bt.eacl = v
}
}
func (bt *BearerTokenBody) GetOwnerID() *refs.OwnerID {
if bt != nil {
@ -359,10 +325,8 @@ func (bt *BearerTokenBody) GetOwnerID() *refs.OwnerID {
}
func (bt *BearerTokenBody) SetOwnerID(v *refs.OwnerID) {
if bt != nil {
bt.ownerID = v
}
}
func (bt *BearerTokenBody) GetLifetime() *TokenLifetime {
if bt != nil {
@ -373,10 +337,8 @@ func (bt *BearerTokenBody) GetLifetime() *TokenLifetime {
}
func (bt *BearerTokenBody) SetLifetime(v *TokenLifetime) {
if bt != nil {
bt.lifetime = v
}
}
func (bt *BearerToken) GetBody() *BearerTokenBody {
if bt != nil {
@ -387,10 +349,8 @@ func (bt *BearerToken) GetBody() *BearerTokenBody {
}
func (bt *BearerToken) SetBody(v *BearerTokenBody) {
if bt != nil {
bt.body = v
}
}
func (bt *BearerToken) GetSignature() *refs.Signature {
if bt != nil {
@ -401,7 +361,5 @@ func (bt *BearerToken) GetSignature() *refs.Signature {
}
func (bt *BearerToken) SetSignature(v *refs.Signature) {
if bt != nil {
bt.sig = v
}
}

View file

@ -6,98 +6,70 @@ import (
// SetVersion is a Version field setter.
func (x *DataAuditResult) SetVersion(v *refs.Version) {
if x != nil {
x.Version = v
}
}
// SetAuditEpoch is an AuditEpoch field setter.
func (x *DataAuditResult) SetAuditEpoch(v uint64) {
if x != nil {
x.AuditEpoch = v
}
}
// SetContainerId is a ContainerId field setter.
func (x *DataAuditResult) SetContainerId(v *refs.ContainerID) {
if x != nil {
x.ContainerId = v
}
}
// SetPublicKey is a PublicKey field setter.
func (x *DataAuditResult) SetPublicKey(v []byte) {
if x != nil {
x.PublicKey = v
}
}
// SetComplete is a Complete field setter.
func (x *DataAuditResult) SetComplete(v bool) {
if x != nil {
x.Complete = v
}
}
// SetRequests is a Requests field setter.
func (x *DataAuditResult) SetRequests(v uint32) {
if x != nil {
x.Requests = v
}
}
// SetRetries is a Retries field setter.
func (x *DataAuditResult) SetRetries(v uint32) {
if x != nil {
x.Retries = v
}
}
// SetPassSg is a PassSg field setter.
func (x *DataAuditResult) SetPassSg(v []*refs.ObjectID) {
if x != nil {
x.PassSg = v
}
}
// SetFailSg is a FailSg field setter.
func (x *DataAuditResult) SetFailSg(v []*refs.ObjectID) {
if x != nil {
x.FailSg = v
}
}
// SetHit is a Hit field setter.
func (x *DataAuditResult) SetHit(v uint32) {
if x != nil {
x.Hit = v
}
}
// SetMiss is a Miss field setter.
func (x *DataAuditResult) SetMiss(v uint32) {
if x != nil {
x.Miss = v
}
}
// SetFail is a Fail field setter.
func (x *DataAuditResult) SetFail(v uint32) {
if x != nil {
x.Fail = v
}
}
// SetPassNodes is a PassNodes field setter.
func (x *DataAuditResult) SetPassNodes(v [][]byte) {
if x != nil {
x.PassNodes = v
}
}
// SetFailNodes is a FailNodes field setter.
func (x *DataAuditResult) SetFailNodes(v [][]byte) {
if x != nil {
x.FailNodes = v
}
}

View file

@ -37,10 +37,8 @@ func (a *DataAuditResult) GetVersion() *refs.Version {
// SetVersion sets version of Data Audit structure.
func (a *DataAuditResult) SetVersion(v *refs.Version) {
if a != nil {
a.version = v
}
}
// GetAuditEpoch returns epoch number when the Data Audit was conducted.
func (a *DataAuditResult) GetAuditEpoch() uint64 {
@ -53,10 +51,8 @@ func (a *DataAuditResult) GetAuditEpoch() uint64 {
// SetAuditEpoch sets epoch number when the Data Audit was conducted.
func (a *DataAuditResult) SetAuditEpoch(v uint64) {
if a != nil {
a.auditEpoch = v
}
}
// GetContainerID returns container under audit.
func (a *DataAuditResult) GetContainerID() *refs.ContainerID {
@ -69,10 +65,8 @@ func (a *DataAuditResult) GetContainerID() *refs.ContainerID {
// SetContainerID sets container under audit.
func (a *DataAuditResult) SetContainerID(v *refs.ContainerID) {
if a != nil {
a.cid = v
}
}
// GetPublicKey returns public key of the auditing InnerRing node in a binary format.
func (a *DataAuditResult) GetPublicKey() []byte {
@ -85,10 +79,8 @@ func (a *DataAuditResult) GetPublicKey() []byte {
// SetPublicKey sets public key of the auditing InnerRing node in a binary format.
func (a *DataAuditResult) SetPublicKey(v []byte) {
if a != nil {
a.pubKey = v
}
}
// GetPassSG returns list of Storage Groups that passed audit PoR stage.
func (a *DataAuditResult) GetPassSG() []refs.ObjectID {
@ -101,10 +93,8 @@ func (a *DataAuditResult) GetPassSG() []refs.ObjectID {
// SetPassSG sets list of Storage Groups that passed audit PoR stage.
func (a *DataAuditResult) SetPassSG(v []refs.ObjectID) {
if a != nil {
a.passSG = v
}
}
// GetFailSG returns list of Storage Groups that failed audit PoR stage.
func (a *DataAuditResult) GetFailSG() []refs.ObjectID {
@ -117,10 +107,8 @@ func (a *DataAuditResult) GetFailSG() []refs.ObjectID {
// SetFailSG sets list of Storage Groups that failed audit PoR stage.
func (a *DataAuditResult) SetFailSG(v []refs.ObjectID) {
if a != nil {
a.failSG = v
}
}
// GetRequests returns number of requests made by PoR audit check to get
// all headers of the objects inside storage groups.
@ -135,10 +123,8 @@ func (a *DataAuditResult) GetRequests() uint32 {
// SetRequests sets number of requests made by PoR audit check to get
// all headers of the objects inside storage groups.
func (a *DataAuditResult) SetRequests(v uint32) {
if a != nil {
a.requests = v
}
}
// GetRetries returns number of retries made by PoR audit check to get
// all headers of the objects inside storage groups.
@ -153,10 +139,8 @@ func (a *DataAuditResult) GetRetries() uint32 {
// SetRetries sets number of retries made by PoR audit check to get
// all headers of the objects inside storage groups.
func (a *DataAuditResult) SetRetries(v uint32) {
if a != nil {
a.retries = v
}
}
// GetHit returns number of sampled objects under audit placed
// in an optimal way according to the containers placement policy
@ -173,10 +157,8 @@ func (a *DataAuditResult) GetHit() uint32 {
// in an optimal way according to the containers placement policy
// when checking PoP.
func (a *DataAuditResult) SetHit(v uint32) {
if a != nil {
a.hit = v
}
}
// GetMiss returns number of sampled objects under audit placed
// in suboptimal way according to the containers placement policy,
@ -193,10 +175,8 @@ func (a *DataAuditResult) GetMiss() uint32 {
// in suboptimal way according to the containers placement policy,
// but still at a satisfactory level when checking PoP.
func (a *DataAuditResult) SetMiss(v uint32) {
if a != nil {
a.miss = v
}
}
// GetFail returns number of sampled objects under audit stored
// in a way not confirming placement policy or not found at all
@ -213,10 +193,8 @@ func (a *DataAuditResult) GetFail() uint32 {
// in a way not confirming placement policy or not found at all
// when checking PoP.
func (a *DataAuditResult) SetFail(v uint32) {
if a != nil {
a.fail = v
}
}
// GetPassNodes returns list of storage node public keys that
// passed at least one PDP.
@ -231,10 +209,8 @@ func (a *DataAuditResult) GetPassNodes() [][]byte {
// SetPassNodes sets list of storage node public keys that
// passed at least one PDP.
func (a *DataAuditResult) SetPassNodes(v [][]byte) {
if a != nil {
a.passNodes = v
}
}
// GetFailNodes returns list of storage node public keys that
// failed at least one PDP.
@ -249,10 +225,8 @@ func (a *DataAuditResult) GetFailNodes() [][]byte {
// SetFailNodes sets list of storage node public keys that
// failed at least one PDP.
func (a *DataAuditResult) SetFailNodes(v [][]byte) {
if a != nil {
a.failNodes = v
}
}
// GetComplete returns boolean completion statement of audit result.
func (a *DataAuditResult) GetComplete() bool {
@ -265,7 +239,5 @@ func (a *DataAuditResult) GetComplete() bool {
// SetComplete sets boolean completion statement of audit result.
func (a *DataAuditResult) SetComplete(v bool) {
if a != nil {
a.complete = v
}
}

View file

@ -8,122 +8,88 @@ import (
// SetContainer sets container of the request.
func (m *PutRequest_Body) SetContainer(v *Container) {
if m != nil {
m.Container = v
}
}
// SetSignature sets signature of the container structure.
func (m *PutRequest_Body) SetSignature(v *refs.SignatureRFC6979) {
if m != nil {
m.Signature = v
}
}
// SetBody sets body of the request.
func (m *PutRequest) SetBody(v *PutRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *PutRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *PutRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainerId sets identifier of the container.
func (m *PutResponse_Body) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetBody sets body of the response.
func (m *PutResponse) SetBody(v *PutResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *PutResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *PutResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainerId sets identifier of the container.
func (m *DeleteRequest_Body) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetSignature sets signature of the container identifier.
func (m *DeleteRequest_Body) SetSignature(v *refs.SignatureRFC6979) {
if m != nil {
m.Signature = v
}
}
// SetBody sets body of the request.
func (m *DeleteRequest) SetBody(v *DeleteRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *DeleteRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *DeleteRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetBody sets body of the response.
func (m *DeleteResponse) SetBody(v *DeleteResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *DeleteResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *DeleteResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainerId sets identifier of the container.
func (m *GetRequest_Body) SetContainerId(v *refs.ContainerID) {
@ -132,317 +98,227 @@ func (m *GetRequest_Body) SetContainerId(v *refs.ContainerID) {
// SetBody sets body of the request.
func (m *GetRequest) SetBody(v *GetRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *GetRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *GetRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainer sets the container structure.
func (m *GetResponse_Body) SetContainer(v *Container) {
if m != nil {
m.Container = v
}
}
// SetSessionToken sets token of the session within which requested
// container was created.
func (m *GetResponse_Body) SetSessionToken(v *session.SessionToken) {
if m != nil {
m.SessionToken = v
}
}
// SetSignature sets signature of the container structure.
func (m *GetResponse_Body) SetSignature(v *refs.SignatureRFC6979) {
if m != nil {
m.Signature = v
}
}
// SetBody sets body of the response.
func (m *GetResponse) SetBody(v *GetResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *GetResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *GetResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetOwnerId sets identifier of the container owner.
func (m *ListRequest_Body) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetBody sets body of the request.
func (m *ListRequest) SetBody(v *ListRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *ListRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *ListRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainerIds sets list of the container identifiers.
func (m *ListResponse_Body) SetContainerIds(v []*refs.ContainerID) {
if m != nil {
m.ContainerIds = v
}
}
// SetBody sets body of the response.
func (m *ListResponse) SetBody(v *ListResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *ListResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *ListResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetEacl sets eACL table structure.
func (m *SetExtendedACLRequest_Body) SetEacl(v *acl.EACLTable) {
if m != nil {
m.Eacl = v
}
}
// SetSignature sets signature of the eACL table structure.
func (m *SetExtendedACLRequest_Body) SetSignature(v *refs.SignatureRFC6979) {
if m != nil {
m.Signature = v
}
}
// SetBody sets body of the request.
func (m *SetExtendedACLRequest) SetBody(v *SetExtendedACLRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *SetExtendedACLRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *SetExtendedACLRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetBody sets body of the response.
func (m *SetExtendedACLResponse) SetBody(v *SetExtendedACLResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *SetExtendedACLResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *SetExtendedACLResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetContainerId sets identifier of the container.
func (m *GetExtendedACLRequest_Body) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetBody sets body of the request.
func (m *GetExtendedACLRequest) SetBody(v *GetExtendedACLRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *GetExtendedACLRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *GetExtendedACLRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetEacl sets eACL table structure.
func (m *GetExtendedACLResponse_Body) SetEacl(v *acl.EACLTable) {
if m != nil {
m.Eacl = v
}
}
// SetSignature sets signature of the eACL table structure.
func (m *GetExtendedACLResponse_Body) SetSignature(v *refs.SignatureRFC6979) {
if m != nil {
m.Signature = v
}
}
// SetSessionToken sets token of the session within which requested
// eACl table was set.
func (m *GetExtendedACLResponse_Body) SetSessionToken(v *session.SessionToken) {
if m != nil {
m.SessionToken = v
}
}
// SetBody sets body of the response.
func (m *GetExtendedACLResponse) SetBody(v *GetExtendedACLResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *GetExtendedACLResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *GetExtendedACLResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetEpoch sets epoch of the size estimation.
func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetEpoch(v uint64) {
if m != nil {
m.Epoch = v
}
}
// SetContainerId sets identifier of the container.
func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetUsedSpace sets used space value of the container.
func (m *AnnounceUsedSpaceRequest_Body_Announcement) SetUsedSpace(v uint64) {
if m != nil {
m.UsedSpace = v
}
}
// SetAnnouncements sets list of announcement for shared containers between nodes.
func (m *AnnounceUsedSpaceRequest_Body) SetAnnouncements(v []*AnnounceUsedSpaceRequest_Body_Announcement) {
if m != nil {
m.Announcements = v
}
}
// SetBody sets body of the request.
func (m *AnnounceUsedSpaceRequest) SetBody(v *AnnounceUsedSpaceRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *AnnounceUsedSpaceRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *AnnounceUsedSpaceRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetBody sets body of the response.
func (m *AnnounceUsedSpaceResponse) SetBody(v *AnnounceUsedSpaceResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *AnnounceUsedSpaceResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *AnnounceUsedSpaceResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}

View file

@ -7,56 +7,40 @@ import (
// SetKey sets key to the container attribute.
func (m *Container_Attribute) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the container attribute.
func (m *Container_Attribute) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetOwnerId sets identifier of the container owner,
func (m *Container) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetNonce sets nonce of the container structure.
func (m *Container) SetNonce(v []byte) {
if m != nil {
m.Nonce = v
}
}
// SetBasicAcl sets basic ACL of the container.
func (m *Container) SetBasicAcl(v uint32) {
if m != nil {
m.BasicAcl = v
}
}
// SetAttributes sets list of the container attributes.
func (m *Container) SetAttributes(v []*Container_Attribute) {
if m != nil {
m.Attributes = v
}
}
// SetPlacementPolicy sets placement policy of the container.
func (m *Container) SetPlacementPolicy(v *netmap.PlacementPolicy) {
if m != nil {
m.PlacementPolicy = v
}
}
// SetVersion sets version of the container.
func (m *Container) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}

View file

@ -189,10 +189,8 @@ func (a *Attribute) GetKey() string {
}
func (a *Attribute) SetKey(v string) {
if a != nil {
a.key = v
}
}
func (a *Attribute) GetValue() string {
if a != nil {
@ -203,10 +201,8 @@ func (a *Attribute) GetValue() string {
}
func (a *Attribute) SetValue(v string) {
if a != nil {
a.val = v
}
}
func (c *Container) GetVersion() *refs.Version {
if c != nil {
@ -217,10 +213,8 @@ func (c *Container) GetVersion() *refs.Version {
}
func (c *Container) SetVersion(v *refs.Version) {
if c != nil {
c.version = v
}
}
func (c *Container) GetOwnerID() *refs.OwnerID {
if c != nil {
@ -231,10 +225,8 @@ func (c *Container) GetOwnerID() *refs.OwnerID {
}
func (c *Container) SetOwnerID(v *refs.OwnerID) {
if c != nil {
c.ownerID = v
}
}
func (c *Container) GetNonce() []byte {
if c != nil {
@ -245,10 +237,8 @@ func (c *Container) GetNonce() []byte {
}
func (c *Container) SetNonce(v []byte) {
if c != nil {
c.nonce = v
}
}
func (c *Container) GetBasicACL() uint32 {
if c != nil {
@ -259,10 +249,8 @@ func (c *Container) GetBasicACL() uint32 {
}
func (c *Container) SetBasicACL(v uint32) {
if c != nil {
c.basicACL = v
}
}
func (c *Container) GetAttributes() []Attribute {
if c != nil {
@ -273,10 +261,8 @@ func (c *Container) GetAttributes() []Attribute {
}
func (c *Container) SetAttributes(v []Attribute) {
if c != nil {
c.attr = v
}
}
func (c *Container) GetPlacementPolicy() *netmap.PlacementPolicy {
if c != nil {
@ -287,10 +273,8 @@ func (c *Container) GetPlacementPolicy() *netmap.PlacementPolicy {
}
func (c *Container) SetPlacementPolicy(v *netmap.PlacementPolicy) {
if c != nil {
c.policy = v
}
}
func (r *PutRequestBody) GetContainer() *Container {
if r != nil {
@ -301,10 +285,8 @@ func (r *PutRequestBody) GetContainer() *Container {
}
func (r *PutRequestBody) SetContainer(v *Container) {
if r != nil {
r.cnr = v
}
}
func (r *PutRequestBody) GetSignature() *refs.Signature {
if r != nil {
@ -315,12 +297,10 @@ func (r *PutRequestBody) GetSignature() *refs.Signature {
}
func (r *PutRequestBody) SetSignature(v *refs.Signature) {
if r != nil {
// TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type)
v.SetScheme(0)
r.sig = v
}
}
func (r *PutRequest) GetBody() *PutRequestBody {
if r != nil {
@ -331,10 +311,8 @@ func (r *PutRequest) GetBody() *PutRequestBody {
}
func (r *PutRequest) SetBody(v *PutRequestBody) {
if r != nil {
r.body = v
}
}
func (r *PutResponseBody) GetContainerID() *refs.ContainerID {
if r != nil {
@ -345,10 +323,8 @@ func (r *PutResponseBody) GetContainerID() *refs.ContainerID {
}
func (r *PutResponseBody) SetContainerID(v *refs.ContainerID) {
if r != nil {
r.cid = v
}
}
func (r *PutResponse) GetBody() *PutResponseBody {
if r != nil {
@ -359,10 +335,8 @@ func (r *PutResponse) GetBody() *PutResponseBody {
}
func (r *PutResponse) SetBody(v *PutResponseBody) {
if r != nil {
r.body = v
}
}
func (r *GetRequestBody) GetContainerID() *refs.ContainerID {
if r != nil {
@ -373,10 +347,8 @@ func (r *GetRequestBody) GetContainerID() *refs.ContainerID {
}
func (r *GetRequestBody) SetContainerID(v *refs.ContainerID) {
if r != nil {
r.cid = v
}
}
func (r *GetRequest) GetBody() *GetRequestBody {
if r != nil {
@ -387,10 +359,8 @@ func (r *GetRequest) GetBody() *GetRequestBody {
}
func (r *GetRequest) SetBody(v *GetRequestBody) {
if r != nil {
r.body = v
}
}
func (r *GetResponseBody) GetContainer() *Container {
if r != nil {
@ -401,10 +371,8 @@ func (r *GetResponseBody) GetContainer() *Container {
}
func (r *GetResponseBody) SetContainer(v *Container) {
if r != nil {
r.cnr = v
}
}
// GetSessionToken returns token of the session within which requested
// container was created.
@ -419,10 +387,8 @@ func (r *GetResponseBody) GetSessionToken() *session.Token {
// SetSessionToken sets token of the session within which requested
// container was created.
func (r *GetResponseBody) SetSessionToken(v *session.Token) {
if r != nil {
r.token = v
}
}
// GetSignature returns signature of the requested container.
func (r *GetResponseBody) GetSignature() *refs.Signature {
@ -435,12 +401,10 @@ func (r *GetResponseBody) GetSignature() *refs.Signature {
// SetSignature sets signature of the requested container.
func (r *GetResponseBody) SetSignature(v *refs.Signature) {
if r != nil {
// TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type)
v.SetScheme(0)
r.sig = v
}
}
func (r *GetResponse) GetBody() *GetResponseBody {
if r != nil {
@ -451,10 +415,8 @@ func (r *GetResponse) GetBody() *GetResponseBody {
}
func (r *GetResponse) SetBody(v *GetResponseBody) {
if r != nil {
r.body = v
}
}
func (r *DeleteRequestBody) GetContainerID() *refs.ContainerID {
if r != nil {
@ -465,10 +427,8 @@ func (r *DeleteRequestBody) GetContainerID() *refs.ContainerID {
}
func (r *DeleteRequestBody) SetContainerID(v *refs.ContainerID) {
if r != nil {
r.cid = v
}
}
func (r *DeleteRequestBody) GetSignature() *refs.Signature {
if r != nil {
@ -479,12 +439,10 @@ func (r *DeleteRequestBody) GetSignature() *refs.Signature {
}
func (r *DeleteRequestBody) SetSignature(v *refs.Signature) {
if r != nil {
// TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type)
v.SetScheme(0)
r.sig = v
}
}
func (r *DeleteRequest) GetBody() *DeleteRequestBody {
if r != nil {
@ -495,10 +453,8 @@ func (r *DeleteRequest) GetBody() *DeleteRequestBody {
}
func (r *DeleteRequest) SetBody(v *DeleteRequestBody) {
if r != nil {
r.body = v
}
}
func (r *DeleteResponse) GetBody() *DeleteResponseBody {
if r != nil {
@ -509,10 +465,8 @@ func (r *DeleteResponse) GetBody() *DeleteResponseBody {
}
func (r *DeleteResponse) SetBody(v *DeleteResponseBody) {
if r != nil {
r.body = v
}
}
func (r *ListRequestBody) GetOwnerID() *refs.OwnerID {
if r != nil {
@ -523,10 +477,8 @@ func (r *ListRequestBody) GetOwnerID() *refs.OwnerID {
}
func (r *ListRequestBody) SetOwnerID(v *refs.OwnerID) {
if r != nil {
r.ownerID = v
}
}
func (r *ListRequest) GetBody() *ListRequestBody {
if r != nil {
@ -537,10 +489,8 @@ func (r *ListRequest) GetBody() *ListRequestBody {
}
func (r *ListRequest) SetBody(v *ListRequestBody) {
if r != nil {
r.body = v
}
}
func (r *ListResponseBody) GetContainerIDs() []refs.ContainerID {
if r != nil {
@ -551,10 +501,8 @@ func (r *ListResponseBody) GetContainerIDs() []refs.ContainerID {
}
func (r *ListResponseBody) SetContainerIDs(v []refs.ContainerID) {
if r != nil {
r.cidList = v
}
}
func (r *ListResponse) GetBody() *ListResponseBody {
if r != nil {
@ -565,10 +513,8 @@ func (r *ListResponse) GetBody() *ListResponseBody {
}
func (r *ListResponse) SetBody(v *ListResponseBody) {
if r != nil {
r.body = v
}
}
func (r *SetExtendedACLRequestBody) GetEACL() *acl.Table {
if r != nil {
@ -579,10 +525,8 @@ func (r *SetExtendedACLRequestBody) GetEACL() *acl.Table {
}
func (r *SetExtendedACLRequestBody) SetEACL(v *acl.Table) {
if r != nil {
r.eacl = v
}
}
func (r *SetExtendedACLRequestBody) GetSignature() *refs.Signature {
if r != nil {
@ -593,12 +537,10 @@ func (r *SetExtendedACLRequestBody) GetSignature() *refs.Signature {
}
func (r *SetExtendedACLRequestBody) SetSignature(v *refs.Signature) {
if r != nil {
// TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type)
v.SetScheme(0)
r.sig = v
}
}
func (r *SetExtendedACLRequest) GetBody() *SetExtendedACLRequestBody {
if r != nil {
@ -609,10 +551,8 @@ func (r *SetExtendedACLRequest) GetBody() *SetExtendedACLRequestBody {
}
func (r *SetExtendedACLRequest) SetBody(v *SetExtendedACLRequestBody) {
if r != nil {
r.body = v
}
}
func (r *SetExtendedACLResponse) GetBody() *SetExtendedACLResponseBody {
if r != nil {
@ -623,10 +563,8 @@ func (r *SetExtendedACLResponse) GetBody() *SetExtendedACLResponseBody {
}
func (r *SetExtendedACLResponse) SetBody(v *SetExtendedACLResponseBody) {
if r != nil {
r.body = v
}
}
func (r *GetExtendedACLRequestBody) GetContainerID() *refs.ContainerID {
if r != nil {
@ -637,10 +575,8 @@ func (r *GetExtendedACLRequestBody) GetContainerID() *refs.ContainerID {
}
func (r *GetExtendedACLRequestBody) SetContainerID(v *refs.ContainerID) {
if r != nil {
r.cid = v
}
}
func (r *GetExtendedACLRequest) GetBody() *GetExtendedACLRequestBody {
if r != nil {
@ -651,10 +587,8 @@ func (r *GetExtendedACLRequest) GetBody() *GetExtendedACLRequestBody {
}
func (r *GetExtendedACLRequest) SetBody(v *GetExtendedACLRequestBody) {
if r != nil {
r.body = v
}
}
func (r *GetExtendedACLResponseBody) GetEACL() *acl.Table {
if r != nil {
@ -665,10 +599,8 @@ func (r *GetExtendedACLResponseBody) GetEACL() *acl.Table {
}
func (r *GetExtendedACLResponseBody) SetEACL(v *acl.Table) {
if r != nil {
r.eacl = v
}
}
func (r *GetExtendedACLResponseBody) GetSignature() *refs.Signature {
if r != nil {
@ -679,12 +611,10 @@ func (r *GetExtendedACLResponseBody) GetSignature() *refs.Signature {
}
func (r *GetExtendedACLResponseBody) SetSignature(v *refs.Signature) {
if r != nil {
// TODO: (neofs-api-go#381) avoid this hack (e.g. create refs.SignatureRFC6979 type)
v.SetScheme(0)
r.sig = v
}
}
// GetSessionToken returns token of the session within which requested
// eACL table was set.
@ -699,10 +629,8 @@ func (r *GetExtendedACLResponseBody) GetSessionToken() *session.Token {
// SetSessionToken sets token of the session within which requested
// eACL table was set.
func (r *GetExtendedACLResponseBody) SetSessionToken(v *session.Token) {
if r != nil {
r.token = v
}
}
func (r *GetExtendedACLResponse) GetBody() *GetExtendedACLResponseBody {
if r != nil {
@ -713,10 +641,8 @@ func (r *GetExtendedACLResponse) GetBody() *GetExtendedACLResponseBody {
}
func (r *GetExtendedACLResponse) SetBody(v *GetExtendedACLResponseBody) {
if r != nil {
r.body = v
}
}
func (a *UsedSpaceAnnouncement) GetEpoch() uint64 {
if a != nil {
@ -727,10 +653,8 @@ func (a *UsedSpaceAnnouncement) GetEpoch() uint64 {
}
func (a *UsedSpaceAnnouncement) SetEpoch(v uint64) {
if a != nil {
a.epoch = v
}
}
func (a *UsedSpaceAnnouncement) GetUsedSpace() uint64 {
if a != nil {
@ -741,10 +665,8 @@ func (a *UsedSpaceAnnouncement) GetUsedSpace() uint64 {
}
func (a *UsedSpaceAnnouncement) SetUsedSpace(v uint64) {
if a != nil {
a.usedSpace = v
}
}
func (a *UsedSpaceAnnouncement) GetContainerID() *refs.ContainerID {
if a != nil {
@ -755,10 +677,8 @@ func (a *UsedSpaceAnnouncement) GetContainerID() *refs.ContainerID {
}
func (a *UsedSpaceAnnouncement) SetContainerID(v *refs.ContainerID) {
if a != nil {
a.cid = v
}
}
func (r *AnnounceUsedSpaceRequestBody) GetAnnouncements() []UsedSpaceAnnouncement {
if r != nil {
@ -769,10 +689,8 @@ func (r *AnnounceUsedSpaceRequestBody) GetAnnouncements() []UsedSpaceAnnouncemen
}
func (r *AnnounceUsedSpaceRequestBody) SetAnnouncements(v []UsedSpaceAnnouncement) {
if r != nil {
r.announcements = v
}
}
func (r *AnnounceUsedSpaceRequest) GetBody() *AnnounceUsedSpaceRequestBody {
if r != nil {
@ -783,10 +701,8 @@ func (r *AnnounceUsedSpaceRequest) GetBody() *AnnounceUsedSpaceRequestBody {
}
func (r *AnnounceUsedSpaceRequest) SetBody(v *AnnounceUsedSpaceRequestBody) {
if r != nil {
r.body = v
}
}
func (r *AnnounceUsedSpaceResponse) GetBody() *AnnounceUsedSpaceResponseBody {
if r != nil {
@ -797,7 +713,5 @@ func (r *AnnounceUsedSpaceResponse) GetBody() *AnnounceUsedSpaceResponseBody {
}
func (r *AnnounceUsedSpaceResponse) SetBody(v *AnnounceUsedSpaceResponseBody) {
if r != nil {
r.body = v
}
}

View file

@ -7,105 +7,75 @@ import (
// SetBody sets body of the request.
func (m *LocalNodeInfoRequest) SetBody(v *LocalNodeInfoRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *LocalNodeInfoRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *LocalNodeInfoRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetVersion sets version of response body.
func (m *LocalNodeInfoResponse_Body) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetNodeInfo sets node info of response body.
func (m *LocalNodeInfoResponse_Body) SetNodeInfo(v *NodeInfo) {
if m != nil {
m.NodeInfo = v
}
}
// SetBody sets body of the response.
func (m *LocalNodeInfoResponse) SetBody(v *LocalNodeInfoResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *LocalNodeInfoResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *LocalNodeInfoResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetBody sets body of the request.
func (x *NetworkInfoRequest) SetBody(v *NetworkInfoRequest_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (x *NetworkInfoRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (x *NetworkInfoRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}
// SetNetworkInfo sets information about the network.
func (x *NetworkInfoResponse_Body) SetNetworkInfo(v *NetworkInfo) {
if x != nil {
x.NetworkInfo = v
}
}
// SetBody sets body of the response.
func (x *NetworkInfoResponse) SetBody(v *NetworkInfoResponse_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (x *NetworkInfoResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (x *NetworkInfoResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}

View file

@ -4,143 +4,103 @@ import refs "github.com/nspcc-dev/neofs-api-go/v2/refs/grpc"
// SetReplicas of placement policy.
func (m *PlacementPolicy) SetReplicas(v []*Replica) {
if m != nil {
m.Replicas = v
}
}
// SetContainerBackupFactor of placement policy.
func (m *PlacementPolicy) SetContainerBackupFactor(v uint32) {
if m != nil {
m.ContainerBackupFactor = v
}
}
// SetSelectors of placement policy.
func (m *PlacementPolicy) SetSelectors(v []*Selector) {
if m != nil {
m.Selectors = v
}
}
// SetFilters of placement policy.
func (m *PlacementPolicy) SetFilters(v []*Filter) {
if m != nil {
m.Filters = v
}
}
// SetSubnetID sets ID of subnet.
func (m *PlacementPolicy) SetSubnetID(v *refs.SubnetID) {
if m != nil {
m.SubnetId = v
}
}
// SetName of placement filter.
func (m *Filter) SetName(v string) {
if m != nil {
m.Name = v
}
}
// SetKey of placement filter.
func (m *Filter) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetOperation of placement filter.
func (m *Filter) SetOp(v Operation) {
if m != nil {
m.Op = v
}
}
// SetValue of placement filter.
func (m *Filter) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetFilters sets sub-filters of placement filter.
func (m *Filter) SetFilters(v []*Filter) {
if m != nil {
m.Filters = v
}
}
// SetName of placement selector.
func (m *Selector) SetName(v string) {
if m != nil {
m.Name = v
}
}
// SetCount of nodes of placement selector.
func (m *Selector) SetCount(v uint32) {
if m != nil {
m.Count = v
}
}
// SetAttribute of nodes of placement selector.
func (m *Selector) SetAttribute(v string) {
if m != nil {
m.Attribute = v
}
}
// SetFilter of placement selector.
func (m *Selector) SetFilter(v string) {
if m != nil {
m.Filter = v
}
}
// SetClause of placement selector.
func (m *Selector) SetClause(v Clause) {
if m != nil {
m.Clause = v
}
}
// SetCount of object replica.
func (m *Replica) SetCount(v uint32) {
if m != nil {
m.Count = v
}
}
// SetSelector of object replica.
func (m *Replica) SetSelector(v string) {
if m != nil {
m.Selector = v
}
}
// SetKey sets key to the node attribute.
func (m *NodeInfo_Attribute) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the node attribute.
func (m *NodeInfo_Attribute) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetParent sets value of the node parents.
func (m *NodeInfo_Attribute) SetParents(v []string) {
if m != nil {
m.Parents = v
}
}
// SetAddress sets node network address.
//
@ -151,59 +111,43 @@ func (m *NodeInfo) SetAddress(v string) {
// SetAddresses sets list of network addresses of the node.
func (m *NodeInfo) SetAddresses(v []string) {
if m != nil {
m.Addresses = v
}
}
// SetPublicKey sets node public key in a binary format.
func (m *NodeInfo) SetPublicKey(v []byte) {
if m != nil {
m.PublicKey = v
}
}
// SetAttributes sets list of the node attributes.
func (m *NodeInfo) SetAttributes(v []*NodeInfo_Attribute) {
if m != nil {
m.Attributes = v
}
}
// SetState sets node state.
func (m *NodeInfo) SetState(v NodeInfo_State) {
if m != nil {
m.State = v
}
}
// SetCurrentEpoch sets number of the current epoch.
func (x *NetworkInfo) SetCurrentEpoch(v uint64) {
if x != nil {
x.CurrentEpoch = v
}
}
// SetMagicNumber sets magic number of the sidechain.
func (x *NetworkInfo) SetMagicNumber(v uint64) {
if x != nil {
x.MagicNumber = v
}
}
// SetMsPerBlock sets MillisecondsPerBlock network parameter.
func (x *NetworkInfo) SetMsPerBlock(v int64) {
if x != nil {
x.MsPerBlock = v
}
}
// SetNetworkConfig sets NeoFS network configuration.
func (x *NetworkInfo) SetNetworkConfig(v *NetworkConfig) {
if x != nil {
x.NetworkConfig = v
}
}
// FromString parses Clause from a string representation,
// It is a reverse action to String().
@ -246,21 +190,15 @@ func (x *NodeInfo_State) FromString(s string) bool {
// SetKey sets parameter key.
func (x *NetworkConfig_Parameter) SetKey(v []byte) {
if x != nil {
x.Key = v
}
}
// SetValue sets parameter value.
func (x *NetworkConfig_Parameter) SetValue(v []byte) {
if x != nil {
x.Value = v
}
}
// SetParameters sets NeoFS network parameters.
func (x *NetworkConfig) SetParameters(v []*NetworkConfig_Parameter) {
if x != nil {
x.Parameters = v
}
}

View file

@ -123,10 +123,8 @@ func (f *Filter) GetFilters() []Filter {
}
func (f *Filter) SetFilters(filters []Filter) {
if f != nil {
f.filters = filters
}
}
func (f *Filter) GetValue() string {
if f != nil {
@ -137,10 +135,8 @@ func (f *Filter) GetValue() string {
}
func (f *Filter) SetValue(value string) {
if f != nil {
f.value = value
}
}
func (f *Filter) GetOp() Operation {
if f != nil {
@ -150,10 +146,8 @@ func (f *Filter) GetOp() Operation {
}
func (f *Filter) SetOp(op Operation) {
if f != nil {
f.op = op
}
}
func (f *Filter) GetKey() string {
if f != nil {
@ -164,10 +158,8 @@ func (f *Filter) GetKey() string {
}
func (f *Filter) SetKey(key string) {
if f != nil {
f.key = key
}
}
func (f *Filter) GetName() string {
if f != nil {
@ -178,10 +170,8 @@ func (f *Filter) GetName() string {
}
func (f *Filter) SetName(name string) {
if f != nil {
f.name = name
}
}
func (s *Selector) GetFilter() string {
if s != nil {
@ -192,10 +182,8 @@ func (s *Selector) GetFilter() string {
}
func (s *Selector) SetFilter(filter string) {
if s != nil {
s.filter = filter
}
}
func (s *Selector) GetAttribute() string {
if s != nil {
@ -206,10 +194,8 @@ func (s *Selector) GetAttribute() string {
}
func (s *Selector) SetAttribute(attribute string) {
if s != nil {
s.attribute = attribute
}
}
func (s *Selector) GetClause() Clause {
if s != nil {
@ -220,10 +206,8 @@ func (s *Selector) GetClause() Clause {
}
func (s *Selector) SetClause(clause Clause) {
if s != nil {
s.clause = clause
}
}
func (s *Selector) GetCount() uint32 {
if s != nil {
@ -234,10 +218,8 @@ func (s *Selector) GetCount() uint32 {
}
func (s *Selector) SetCount(count uint32) {
if s != nil {
s.count = count
}
}
func (s *Selector) GetName() string {
if s != nil {
@ -248,10 +230,8 @@ func (s *Selector) GetName() string {
}
func (s *Selector) SetName(name string) {
if s != nil {
s.name = name
}
}
func (r *Replica) GetSelector() string {
if r != nil {
@ -262,10 +242,8 @@ func (r *Replica) GetSelector() string {
}
func (r *Replica) SetSelector(selector string) {
if r != nil {
r.selector = selector
}
}
func (r *Replica) GetCount() uint32 {
if r != nil {
@ -276,10 +254,8 @@ func (r *Replica) GetCount() uint32 {
}
func (r *Replica) SetCount(count uint32) {
if r != nil {
r.count = count
}
}
func (p *PlacementPolicy) GetFilters() []Filter {
if p != nil {
@ -290,10 +266,8 @@ func (p *PlacementPolicy) GetFilters() []Filter {
}
func (p *PlacementPolicy) SetFilters(filters []Filter) {
if p != nil {
p.filters = filters
}
}
func (p *PlacementPolicy) GetSelectors() []Selector {
if p != nil {
@ -304,10 +278,8 @@ func (p *PlacementPolicy) GetSelectors() []Selector {
}
func (p *PlacementPolicy) SetSelectors(selectors []Selector) {
if p != nil {
p.selectors = selectors
}
}
func (p *PlacementPolicy) GetContainerBackupFactor() uint32 {
if p != nil {
@ -318,10 +290,8 @@ func (p *PlacementPolicy) GetContainerBackupFactor() uint32 {
}
func (p *PlacementPolicy) SetContainerBackupFactor(backupFactor uint32) {
if p != nil {
p.backupFactor = backupFactor
}
}
func (p *PlacementPolicy) GetReplicas() []Replica {
return p.replicas
@ -348,10 +318,8 @@ func (a *Attribute) GetKey() string {
}
func (a *Attribute) SetKey(v string) {
if a != nil {
a.key = v
}
}
func (a *Attribute) GetValue() string {
if a != nil {
@ -362,10 +330,8 @@ func (a *Attribute) GetValue() string {
}
func (a *Attribute) SetValue(v string) {
if a != nil {
a.value = v
}
}
func (a *Attribute) GetParents() []string {
if a != nil {
@ -376,10 +342,8 @@ func (a *Attribute) GetParents() []string {
}
func (a *Attribute) SetParents(parent []string) {
if a != nil {
a.parents = parent
}
}
func (ni *NodeInfo) GetPublicKey() []byte {
if ni != nil {
@ -390,10 +354,8 @@ func (ni *NodeInfo) GetPublicKey() []byte {
}
func (ni *NodeInfo) SetPublicKey(v []byte) {
if ni != nil {
ni.publicKey = v
}
}
// GetAddress returns node's network address.
//
@ -416,10 +378,8 @@ func (ni *NodeInfo) SetAddress(v string) {
// SetAddresses sets list of network addresses of the node.
func (ni *NodeInfo) SetAddresses(v ...string) {
if ni != nil {
ni.addresses = v
}
}
// NumberOfAddresses returns number of network addresses of the node.
func (ni *NodeInfo) NumberOfAddresses() int {
@ -453,10 +413,8 @@ func (ni *NodeInfo) GetAttributes() []Attribute {
}
func (ni *NodeInfo) SetAttributes(v []Attribute) {
if ni != nil {
ni.attributes = v
}
}
func (ni *NodeInfo) GetState() NodeState {
if ni != nil {
@ -467,10 +425,8 @@ func (ni *NodeInfo) GetState() NodeState {
}
func (ni *NodeInfo) SetState(state NodeState) {
if ni != nil {
ni.state = state
}
}
func (l *LocalNodeInfoResponseBody) GetVersion() *refs.Version {
if l != nil {
@ -481,10 +437,8 @@ func (l *LocalNodeInfoResponseBody) GetVersion() *refs.Version {
}
func (l *LocalNodeInfoResponseBody) SetVersion(version *refs.Version) {
if l != nil {
l.version = version
}
}
func (l *LocalNodeInfoResponseBody) GetNodeInfo() *NodeInfo {
if l != nil {
@ -495,10 +449,8 @@ func (l *LocalNodeInfoResponseBody) GetNodeInfo() *NodeInfo {
}
func (l *LocalNodeInfoResponseBody) SetNodeInfo(nodeInfo *NodeInfo) {
if l != nil {
l.nodeInfo = nodeInfo
}
}
func (l *LocalNodeInfoRequest) GetBody() *LocalNodeInfoRequestBody {
if l != nil {
@ -508,10 +460,8 @@ func (l *LocalNodeInfoRequest) GetBody() *LocalNodeInfoRequestBody {
}
func (l *LocalNodeInfoRequest) SetBody(body *LocalNodeInfoRequestBody) {
if l != nil {
l.body = body
}
}
func (l *LocalNodeInfoResponse) GetBody() *LocalNodeInfoResponseBody {
if l != nil {
@ -521,10 +471,8 @@ func (l *LocalNodeInfoResponse) GetBody() *LocalNodeInfoResponseBody {
}
func (l *LocalNodeInfoResponse) SetBody(body *LocalNodeInfoResponseBody) {
if l != nil {
l.body = body
}
}
// NetworkParameter represents NeoFS network parameter.
type NetworkParameter struct {
@ -542,10 +490,8 @@ func (x *NetworkParameter) GetKey() []byte {
// SetKey sets parameter key.
func (x *NetworkParameter) SetKey(k []byte) {
if x != nil {
x.k = k
}
}
// GetValue returns parameter value.
func (x *NetworkParameter) GetValue() []byte {
@ -558,10 +504,8 @@ func (x *NetworkParameter) GetValue() []byte {
// SetValue sets parameter value.
func (x *NetworkParameter) SetValue(v []byte) {
if x != nil {
x.v = v
}
}
// NetworkConfig represents NeoFS network configuration.
type NetworkConfig struct {
@ -593,10 +537,8 @@ func (x *NetworkConfig) IterateParameters(f func(*NetworkParameter) bool) {
// SetParameters sets list of network parameters.
func (x *NetworkConfig) SetParameters(v ...NetworkParameter) {
if x != nil {
x.ps = v
}
}
// NetworkInfo groups information about
// NeoFS network.
@ -619,10 +561,8 @@ func (i *NetworkInfo) GetCurrentEpoch() uint64 {
// SetCurrentEpoch sets number of the current epoch.
func (i *NetworkInfo) SetCurrentEpoch(epoch uint64) {
if i != nil {
i.curEpoch = epoch
}
}
// GetMagicNumber returns magic number of the sidechain.
func (i *NetworkInfo) GetMagicNumber() uint64 {
@ -635,10 +575,8 @@ func (i *NetworkInfo) GetMagicNumber() uint64 {
// SetMagicNumber sets magic number of the sidechain.
func (i *NetworkInfo) SetMagicNumber(magic uint64) {
if i != nil {
i.magicNum = magic
}
}
// GetMsPerBlock returns MillisecondsPerBlock network parameter.
func (i *NetworkInfo) GetMsPerBlock() int64 {
@ -651,10 +589,8 @@ func (i *NetworkInfo) GetMsPerBlock() int64 {
// SetMsPerBlock sets MillisecondsPerBlock network parameter.
func (i *NetworkInfo) SetMsPerBlock(v int64) {
if i != nil {
i.msPerBlock = v
}
}
// GetNetworkConfig returns NeoFS network configuration.
func (i *NetworkInfo) GetNetworkConfig() *NetworkConfig {
@ -667,10 +603,8 @@ func (i *NetworkInfo) GetNetworkConfig() *NetworkConfig {
// SetNetworkConfig sets NeoFS network configuration.
func (i *NetworkInfo) SetNetworkConfig(v *NetworkConfig) {
if i != nil {
i.netCfg = v
}
}
// NetworkInfoRequestBody is a structure of NetworkInfo request body.
type NetworkInfoRequestBody struct{}
@ -691,10 +625,8 @@ func (i *NetworkInfoResponseBody) GetNetworkInfo() *NetworkInfo {
// SetNetworkInfo sets information about the NeoFS network.
func (i *NetworkInfoResponseBody) SetNetworkInfo(netInfo *NetworkInfo) {
if i != nil {
i.netInfo = netInfo
}
}
func (l *NetworkInfoRequest) GetBody() *NetworkInfoRequestBody {
if l != nil {
@ -704,10 +636,8 @@ func (l *NetworkInfoRequest) GetBody() *NetworkInfoRequestBody {
}
func (l *NetworkInfoRequest) SetBody(body *NetworkInfoRequestBody) {
if l != nil {
l.body = body
}
}
func (l *NetworkInfoResponse) GetBody() *NetworkInfoResponseBody {
if l != nil {
@ -717,7 +647,5 @@ func (l *NetworkInfoResponse) GetBody() *NetworkInfoResponseBody {
}
func (l *NetworkInfoResponse) SetBody(body *NetworkInfoResponseBody) {
if l != nil {
l.body = body
}
}

View file

@ -7,59 +7,43 @@ import (
// SetAddress sets address of the requested object.
func (m *GetRequest_Body) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetRaw sets raw flag of the request.
func (m *GetRequest_Body) SetRaw(v bool) {
if m != nil {
m.Raw = v
}
}
// SetBody sets body of the request.
func (m *GetRequest) SetBody(v *GetRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *GetRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *GetRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetObjectId sets identifier of the object.
func (m *GetResponse_Body_Init) SetObjectId(v *refs.ObjectID) {
if m != nil {
m.ObjectId = v
}
}
// SetSignature sets signature of the object identifier.
func (m *GetResponse_Body_Init) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetHeader sets header of the object.
func (m *GetResponse_Body_Init) SetHeader(v *Header) {
if m != nil {
m.Header = v
}
}
// GetChunk returns chunk of the object payload bytes.
func (m *GetResponse_Body_Chunk) GetChunk() []byte {
@ -72,84 +56,62 @@ func (m *GetResponse_Body_Chunk) GetChunk() []byte {
// SetChunk sets chunk of the object payload bytes.
func (m *GetResponse_Body_Chunk) SetChunk(v []byte) {
if m != nil {
m.Chunk = v
}
}
// SetInit sets initial part of the object.
func (m *GetResponse_Body) SetInit(v *GetResponse_Body_Init) {
if m != nil {
m.ObjectPart = &GetResponse_Body_Init_{
Init: v,
}
}
}
// SetChunk sets part of the object payload.
func (m *GetResponse_Body) SetChunk(v *GetResponse_Body_Chunk) {
if m != nil {
m.ObjectPart = v
}
}
// SetSplitInfo sets part of the object payload.
func (m *GetResponse_Body) SetSplitInfo(v *SplitInfo) {
if m != nil {
m.ObjectPart = &GetResponse_Body_SplitInfo{
SplitInfo: v,
}
}
}
// SetBody sets body of the response.
func (m *GetResponse) SetBody(v *GetResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *GetResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *GetResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetObjectId sets identifier of the object.
func (m *PutRequest_Body_Init) SetObjectId(v *refs.ObjectID) {
if m != nil {
m.ObjectId = v
}
}
// SetSignature sets signature of the object identifier.
func (m *PutRequest_Body_Init) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetHeader sets header of the object.
func (m *PutRequest_Body_Init) SetHeader(v *Header) {
if m != nil {
m.Header = v
}
}
// SetCopiesNumber sets number of the copies to save.
func (m *PutRequest_Body_Init) SetCopiesNumber(v uint32) {
if m != nil {
m.CopiesNumber = v
}
}
// GetChunk returns chunk of the object payload bytes.
func (m *PutRequest_Body_Chunk) GetChunk() []byte {
@ -162,382 +124,276 @@ func (m *PutRequest_Body_Chunk) GetChunk() []byte {
// SetChunk sets chunk of the object payload bytes.
func (m *PutRequest_Body_Chunk) SetChunk(v []byte) {
if m != nil {
m.Chunk = v
}
}
// SetInit sets initial part of the object.
func (m *PutRequest_Body) SetInit(v *PutRequest_Body_Init) {
if m != nil {
m.ObjectPart = &PutRequest_Body_Init_{
Init: v,
}
}
}
// SetChunk sets part of the object payload.
func (m *PutRequest_Body) SetChunk(v *PutRequest_Body_Chunk) {
if m != nil {
m.ObjectPart = v
}
}
// SetBody sets body of the request.
func (m *PutRequest) SetBody(v *PutRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *PutRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *PutRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetObjectId sets identifier of the saved object.
func (m *PutResponse_Body) SetObjectId(v *refs.ObjectID) {
if m != nil {
m.ObjectId = v
}
}
// SetBody sets body of the response.
func (m *PutResponse) SetBody(v *PutResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *PutResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *PutResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetAddress sets address of the object to delete.
func (m *DeleteRequest_Body) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetBody sets body of the request.
func (m *DeleteRequest) SetBody(v *DeleteRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *DeleteRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *DeleteRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetTombstone sets tombstone address.
func (x *DeleteResponse_Body) SetTombstone(v *refs.Address) {
if x != nil {
x.Tombstone = v
}
}
// SetBody sets body of the response.
func (m *DeleteResponse) SetBody(v *DeleteResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *DeleteResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *DeleteResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetAddress sets address of the object with the requested header.
func (m *HeadRequest_Body) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetMainOnly sets flag to return the minimal header subset.
func (m *HeadRequest_Body) SetMainOnly(v bool) {
if m != nil {
m.MainOnly = v
}
}
// SetRaw sets raw flag of the request.
func (m *HeadRequest_Body) SetRaw(v bool) {
if m != nil {
m.Raw = v
}
}
// SetBody sets body of the request.
func (m *HeadRequest) SetBody(v *HeadRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *HeadRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *HeadRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetHeader sets object header.
func (m *HeaderWithSignature) SetHeader(v *Header) {
if m != nil {
m.Header = v
}
}
// SetSignature of the header.
func (m *HeaderWithSignature) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetHeader sets full header of the object.
func (m *HeadResponse_Body) SetHeader(v *HeaderWithSignature) {
if m != nil {
m.Head = &HeadResponse_Body_Header{
Header: v,
}
}
}
// SetShortHeader sets short header of the object.
func (m *HeadResponse_Body) SetShortHeader(v *ShortHeader) {
if m != nil {
m.Head = &HeadResponse_Body_ShortHeader{
ShortHeader: v,
}
}
}
// SetSplitInfo sets meta info about split hierarchy of the object.
func (m *HeadResponse_Body) SetSplitInfo(v *SplitInfo) {
if m != nil {
m.Head = &HeadResponse_Body_SplitInfo{
SplitInfo: v,
}
}
}
// SetBody sets body of the response.
func (m *HeadResponse) SetBody(v *HeadResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *HeadResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *HeadResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetMatchType sets match type of the filter.
func (m *SearchRequest_Body_Filter) SetMatchType(v MatchType) {
if m != nil {
m.MatchType = v
}
}
// SetKey sets key to the filtering header.
func (m *SearchRequest_Body_Filter) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the filtering header.
func (m *SearchRequest_Body_Filter) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetVersion sets version of the search query.
func (m *SearchRequest_Body) SetVersion(v uint32) {
if m != nil {
m.Version = v
}
}
// SetFilters sets list of the query filters.
func (m *SearchRequest_Body) SetFilters(v []*SearchRequest_Body_Filter) {
if m != nil {
m.Filters = v
}
}
// SetContainerId sets container ID of the search requets.
func (m *SearchRequest_Body) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetBody sets body of the request.
func (m *SearchRequest) SetBody(v *SearchRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *SearchRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *SearchRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetIdList sets list of the identifiers of the matched objects.
func (m *SearchResponse_Body) SetIdList(v []*refs.ObjectID) {
if m != nil {
m.IdList = v
}
}
// SetBody sets body of the response.
func (m *SearchResponse) SetBody(v *SearchResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *SearchResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *SearchResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetOffset sets offset of the payload range.
func (m *Range) SetOffset(v uint64) {
if m != nil {
m.Offset = v
}
}
// SetLength sets length of the payload range.
func (m *Range) SetLength(v uint64) {
if m != nil {
m.Length = v
}
}
// SetAddress sets address of the object with the request payload range.
func (m *GetRangeRequest_Body) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetRange sets range of the object payload.
func (m *GetRangeRequest_Body) SetRange(v *Range) {
if m != nil {
m.Range = v
}
}
// SetRaw sets raw flag of the request.
func (m *GetRangeRequest_Body) SetRaw(v bool) {
if m != nil {
m.Raw = v
}
}
// SetBody sets body of the request.
func (m *GetRangeRequest) SetBody(v *GetRangeRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *GetRangeRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *GetRangeRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// GetChunk returns chunk of the object payload range bytes.
func (m *GetRangeResponse_Body_Chunk) GetChunk() []byte {
@ -550,128 +406,92 @@ func (m *GetRangeResponse_Body_Chunk) GetChunk() []byte {
// SetChunk sets chunk of the object payload range bytes.
func (m *GetRangeResponse_Body_Chunk) SetChunk(v []byte) {
if m != nil {
m.Chunk = v
}
}
// SetChunk sets chunk of the object payload.
func (m *GetRangeResponse_Body) SetChunk(v *GetRangeResponse_Body_Chunk) {
if m != nil {
m.RangePart = v
}
}
// SetSplitInfo sets meta info about split hierarchy of the object.
func (m *GetRangeResponse_Body) SetSplitInfo(v *SplitInfo) {
if m != nil {
m.RangePart = &GetRangeResponse_Body_SplitInfo{
SplitInfo: v,
}
}
}
// SetBody sets body of the response.
func (m *GetRangeResponse) SetBody(v *GetRangeResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *GetRangeResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *GetRangeResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetAddress sets address of the object with the request payload range.
func (m *GetRangeHashRequest_Body) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetRanges sets list of the ranges of the object payload.
func (m *GetRangeHashRequest_Body) SetRanges(v []*Range) {
if m != nil {
m.Ranges = v
}
}
// SetSalt sets salt for the object payload ranges.
func (m *GetRangeHashRequest_Body) SetSalt(v []byte) {
if m != nil {
m.Salt = v
}
}
// Set sets salt for the object payload ranges.
func (m *GetRangeHashRequest_Body) SetType(v refs.ChecksumType) {
if m != nil {
m.Type = v
}
}
// SetBody sets body of the request.
func (m *GetRangeHashRequest) SetBody(v *GetRangeHashRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *GetRangeHashRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *GetRangeHashRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetHashList returns list of the range hashes.
func (m *GetRangeHashResponse_Body) SetHashList(v [][]byte) {
if m != nil {
m.HashList = v
}
}
// SetHashList returns list of the range hashes.
func (m *GetRangeHashResponse_Body) SetType(v refs.ChecksumType) {
if m != nil {
m.Type = v
}
}
// SetBody sets body of the response.
func (m *GetRangeHashResponse) SetBody(v *GetRangeHashResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *GetRangeHashResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *GetRangeHashResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}

View file

@ -7,234 +7,168 @@ import (
// SetKey sets key to the object attribute.
func (m *Header_Attribute) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the object attribute.
func (m *Header_Attribute) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetParent sets identifier of the parent object.
func (m *Header_Split) SetParent(v *refs.ObjectID) {
if m != nil {
m.Parent = v
}
}
// SetPrevious sets identifier of the previous object in split-chain.
func (m *Header_Split) SetPrevious(v *refs.ObjectID) {
if m != nil {
m.Previous = v
}
}
// SetParentSignature sets signature of the parent object header.
func (m *Header_Split) SetParentSignature(v *refs.Signature) {
if m != nil {
m.ParentSignature = v
}
}
// SetParentHeader sets parent header structure.
func (m *Header_Split) SetParentHeader(v *Header) {
if m != nil {
m.ParentHeader = v
}
}
// SetChildren sets list of the identifiers of the child objects.
func (m *Header_Split) SetChildren(v []*refs.ObjectID) {
if m != nil {
m.Children = v
}
}
// SetSplitId sets split ID of the object.
func (m *Header_Split) SetSplitId(v []byte) {
if m != nil {
m.SplitId = v
}
}
// SetContainerId sets identifier of the container.
func (m *Header) SetContainerId(v *refs.ContainerID) {
if m != nil {
m.ContainerId = v
}
}
// SetOwnerId sets identifier of the object owner.
func (m *Header) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetCreationEpoch sets creation epoch number.
func (m *Header) SetCreationEpoch(v uint64) {
if m != nil {
m.CreationEpoch = v
}
}
// SetVersion sets version of the object format.
func (m *Header) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetPayloadLength sets length of the object payload.
func (m *Header) SetPayloadLength(v uint64) {
if m != nil {
m.PayloadLength = v
}
}
// SetPayloadHash sets hash of the object payload.
func (m *Header) SetPayloadHash(v *refs.Checksum) {
if m != nil {
m.PayloadHash = v
}
}
// SetObjectType sets type of the object.
func (m *Header) SetObjectType(v ObjectType) {
if m != nil {
m.ObjectType = v
}
}
// SetHomomorphicHash sets homomorphic hash of the object payload.
func (m *Header) SetHomomorphicHash(v *refs.Checksum) {
if m != nil {
m.HomomorphicHash = v
}
}
// SetSessionToken sets session token.
func (m *Header) SetSessionToken(v *session.SessionToken) {
if m != nil {
m.SessionToken = v
}
}
// SetAttributes sets list of the object attributes.
func (m *Header) SetAttributes(v []*Header_Attribute) {
if m != nil {
m.Attributes = v
}
}
// SetSplit sets split header.
func (m *Header) SetSplit(v *Header_Split) {
if m != nil {
m.Split = v
}
}
// SetObjectId sets identifier of the object.
func (m *Object) SetObjectId(v *refs.ObjectID) {
if m != nil {
m.ObjectId = v
}
}
// SetSignature sets signature of the object identifier.
func (m *Object) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetHeader sets header of the object.
func (m *Object) SetHeader(v *Header) {
if m != nil {
m.Header = v
}
}
// SetPayload sets payload bytes of the object.
func (m *Object) SetPayload(v []byte) {
if m != nil {
m.Payload = v
}
}
// SetVersion sets version of the object.
func (m *ShortHeader) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetCreationEpoch sets creation epoch number.
func (m *ShortHeader) SetCreationEpoch(v uint64) {
if m != nil {
m.CreationEpoch = v
}
}
// SetOwnerId sets identifier of the object owner.
func (m *ShortHeader) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetObjectType sets type of the object.
func (m *ShortHeader) SetObjectType(v ObjectType) {
if m != nil {
m.ObjectType = v
}
}
// SetPayloadLength sets length of the object payload.
func (m *ShortHeader) SetPayloadLength(v uint64) {
if m != nil {
m.PayloadLength = v
}
}
// SetPayloadHash sets hash of the object payload.
func (m *ShortHeader) SetPayloadHash(v *refs.Checksum) {
if m != nil {
m.PayloadHash = v
}
}
// SetHomomorphicHash sets homomorphic hash of the object payload.
func (m *ShortHeader) SetHomomorphicHash(v *refs.Checksum) {
if m != nil {
m.HomomorphicHash = v
}
}
// SetSplitId sets id of split hierarchy.
func (m *SplitInfo) SetSplitId(v []byte) {
if m != nil {
m.SplitId = v
}
}
// SetLastPart sets id of most right child in split hierarchy.
func (m *SplitInfo) SetLastPart(v *refs.ObjectID) {
if m != nil {
m.LastPart = v
}
}
// SetLink sets id of linking object in split hierarchy.
func (m *SplitInfo) SetLink(v *refs.ObjectID) {
if m != nil {
m.Link = v
}
}
// FromString parses ObjectType from a string representation,
// It is a reverse action to String().

View file

@ -325,10 +325,8 @@ func (h *ShortHeader) GetVersion() *refs.Version {
}
func (h *ShortHeader) SetVersion(v *refs.Version) {
if h != nil {
h.version = v
}
}
func (h *ShortHeader) GetCreationEpoch() uint64 {
if h != nil {
@ -339,10 +337,8 @@ func (h *ShortHeader) GetCreationEpoch() uint64 {
}
func (h *ShortHeader) SetCreationEpoch(v uint64) {
if h != nil {
h.creatEpoch = v
}
}
func (h *ShortHeader) GetOwnerID() *refs.OwnerID {
if h != nil {
@ -353,10 +349,8 @@ func (h *ShortHeader) GetOwnerID() *refs.OwnerID {
}
func (h *ShortHeader) SetOwnerID(v *refs.OwnerID) {
if h != nil {
h.ownerID = v
}
}
func (h *ShortHeader) GetObjectType() Type {
if h != nil {
@ -367,10 +361,8 @@ func (h *ShortHeader) GetObjectType() Type {
}
func (h *ShortHeader) SetObjectType(v Type) {
if h != nil {
h.typ = v
}
}
func (h *ShortHeader) GetPayloadLength() uint64 {
if h != nil {
@ -381,10 +373,8 @@ func (h *ShortHeader) GetPayloadLength() uint64 {
}
func (h *ShortHeader) SetPayloadLength(v uint64) {
if h != nil {
h.payloadLen = v
}
}
func (h *ShortHeader) GetPayloadHash() *refs.Checksum {
if h != nil {
@ -395,10 +385,8 @@ func (h *ShortHeader) GetPayloadHash() *refs.Checksum {
}
func (h *ShortHeader) SetPayloadHash(v *refs.Checksum) {
if h != nil {
h.payloadHash = v
}
}
func (h *ShortHeader) GetHomomorphicHash() *refs.Checksum {
if h != nil {
@ -409,10 +397,8 @@ func (h *ShortHeader) GetHomomorphicHash() *refs.Checksum {
}
func (h *ShortHeader) SetHomomorphicHash(v *refs.Checksum) {
if h != nil {
h.homoHash = v
}
}
func (h *ShortHeader) getHeaderPart() {}
@ -425,10 +411,8 @@ func (a *Attribute) GetKey() string {
}
func (a *Attribute) SetKey(v string) {
if a != nil {
a.key = v
}
}
func (a *Attribute) GetValue() string {
if a != nil {
@ -439,10 +423,8 @@ func (a *Attribute) GetValue() string {
}
func (a *Attribute) SetValue(v string) {
if a != nil {
a.val = v
}
}
func (h *SplitHeader) GetParent() *refs.ObjectID {
if h != nil {
@ -453,10 +435,8 @@ func (h *SplitHeader) GetParent() *refs.ObjectID {
}
func (h *SplitHeader) SetParent(v *refs.ObjectID) {
if h != nil {
h.par = v
}
}
func (h *SplitHeader) GetPrevious() *refs.ObjectID {
if h != nil {
@ -467,10 +447,8 @@ func (h *SplitHeader) GetPrevious() *refs.ObjectID {
}
func (h *SplitHeader) SetPrevious(v *refs.ObjectID) {
if h != nil {
h.prev = v
}
}
func (h *SplitHeader) GetParentSignature() *refs.Signature {
if h != nil {
@ -481,10 +459,8 @@ func (h *SplitHeader) GetParentSignature() *refs.Signature {
}
func (h *SplitHeader) SetParentSignature(v *refs.Signature) {
if h != nil {
h.parSig = v
}
}
func (h *SplitHeader) GetParentHeader() *Header {
if h != nil {
@ -495,10 +471,8 @@ func (h *SplitHeader) GetParentHeader() *Header {
}
func (h *SplitHeader) SetParentHeader(v *Header) {
if h != nil {
h.parHdr = v
}
}
func (h *SplitHeader) GetChildren() []refs.ObjectID {
if h != nil {
@ -509,10 +483,8 @@ func (h *SplitHeader) GetChildren() []refs.ObjectID {
}
func (h *SplitHeader) SetChildren(v []refs.ObjectID) {
if h != nil {
h.children = v
}
}
func (h *SplitHeader) GetSplitID() []byte {
if h != nil {
@ -523,10 +495,8 @@ func (h *SplitHeader) GetSplitID() []byte {
}
func (h *SplitHeader) SetSplitID(v []byte) {
if h != nil {
h.splitID = v
}
}
func (h *Header) GetVersion() *refs.Version {
if h != nil {
@ -537,10 +507,8 @@ func (h *Header) GetVersion() *refs.Version {
}
func (h *Header) SetVersion(v *refs.Version) {
if h != nil {
h.version = v
}
}
func (h *Header) GetContainerID() *refs.ContainerID {
if h != nil {
@ -551,10 +519,8 @@ func (h *Header) GetContainerID() *refs.ContainerID {
}
func (h *Header) SetContainerID(v *refs.ContainerID) {
if h != nil {
h.cid = v
}
}
func (h *Header) GetOwnerID() *refs.OwnerID {
if h != nil {
@ -565,10 +531,8 @@ func (h *Header) GetOwnerID() *refs.OwnerID {
}
func (h *Header) SetOwnerID(v *refs.OwnerID) {
if h != nil {
h.ownerID = v
}
}
func (h *Header) GetCreationEpoch() uint64 {
if h != nil {
@ -579,10 +543,8 @@ func (h *Header) GetCreationEpoch() uint64 {
}
func (h *Header) SetCreationEpoch(v uint64) {
if h != nil {
h.creatEpoch = v
}
}
func (h *Header) GetPayloadLength() uint64 {
if h != nil {
@ -593,10 +555,8 @@ func (h *Header) GetPayloadLength() uint64 {
}
func (h *Header) SetPayloadLength(v uint64) {
if h != nil {
h.payloadLen = v
}
}
func (h *Header) GetPayloadHash() *refs.Checksum {
if h != nil {
@ -607,10 +567,8 @@ func (h *Header) GetPayloadHash() *refs.Checksum {
}
func (h *Header) SetPayloadHash(v *refs.Checksum) {
if h != nil {
h.payloadHash = v
}
}
func (h *Header) GetObjectType() Type {
if h != nil {
@ -621,10 +579,8 @@ func (h *Header) GetObjectType() Type {
}
func (h *Header) SetObjectType(v Type) {
if h != nil {
h.typ = v
}
}
func (h *Header) GetHomomorphicHash() *refs.Checksum {
if h != nil {
@ -635,10 +591,8 @@ func (h *Header) GetHomomorphicHash() *refs.Checksum {
}
func (h *Header) SetHomomorphicHash(v *refs.Checksum) {
if h != nil {
h.homoHash = v
}
}
func (h *Header) GetSessionToken() *session.Token {
if h != nil {
@ -649,10 +603,8 @@ func (h *Header) GetSessionToken() *session.Token {
}
func (h *Header) SetSessionToken(v *session.Token) {
if h != nil {
h.sessionToken = v
}
}
func (h *Header) GetAttributes() []Attribute {
if h != nil {
@ -663,10 +615,8 @@ func (h *Header) GetAttributes() []Attribute {
}
func (h *Header) SetAttributes(v []Attribute) {
if h != nil {
h.attr = v
}
}
func (h *Header) GetSplit() *SplitHeader {
if h != nil {
@ -677,10 +627,8 @@ func (h *Header) GetSplit() *SplitHeader {
}
func (h *Header) SetSplit(v *SplitHeader) {
if h != nil {
h.split = v
}
}
func (h *HeaderWithSignature) GetHeader() *Header {
if h != nil {
@ -691,10 +639,8 @@ func (h *HeaderWithSignature) GetHeader() *Header {
}
func (h *HeaderWithSignature) SetHeader(v *Header) {
if h != nil {
h.header = v
}
}
func (h *HeaderWithSignature) GetSignature() *refs.Signature {
if h != nil {
@ -705,10 +651,8 @@ func (h *HeaderWithSignature) GetSignature() *refs.Signature {
}
func (h *HeaderWithSignature) SetSignature(v *refs.Signature) {
if h != nil {
h.signature = v
}
}
func (h *HeaderWithSignature) getHeaderPart() {}
@ -721,10 +665,8 @@ func (o *Object) GetObjectID() *refs.ObjectID {
}
func (o *Object) SetObjectID(v *refs.ObjectID) {
if o != nil {
o.objectID = v
}
}
func (o *Object) GetSignature() *refs.Signature {
if o != nil {
@ -735,10 +677,8 @@ func (o *Object) GetSignature() *refs.Signature {
}
func (o *Object) SetSignature(v *refs.Signature) {
if o != nil {
o.idSig = v
}
}
func (o *Object) GetHeader() *Header {
if o != nil {
@ -749,10 +689,8 @@ func (o *Object) GetHeader() *Header {
}
func (o *Object) SetHeader(v *Header) {
if o != nil {
o.header = v
}
}
func (o *Object) GetPayload() []byte {
if o != nil {
@ -763,10 +701,8 @@ func (o *Object) GetPayload() []byte {
}
func (o *Object) SetPayload(v []byte) {
if o != nil {
o.payload = v
}
}
func (s *SplitInfo) GetSplitID() []byte {
if s != nil {
@ -777,10 +713,8 @@ func (s *SplitInfo) GetSplitID() []byte {
}
func (s *SplitInfo) SetSplitID(v []byte) {
if s != nil {
s.splitID = v
}
}
func (s *SplitInfo) GetLastPart() *refs.ObjectID {
if s != nil {
@ -791,10 +725,8 @@ func (s *SplitInfo) GetLastPart() *refs.ObjectID {
}
func (s *SplitInfo) SetLastPart(v *refs.ObjectID) {
if s != nil {
s.lastPart = v
}
}
func (s *SplitInfo) GetLink() *refs.ObjectID {
if s != nil {
@ -805,10 +737,8 @@ func (s *SplitInfo) GetLink() *refs.ObjectID {
}
func (s *SplitInfo) SetLink(v *refs.ObjectID) {
if s != nil {
s.link = v
}
}
func (s *SplitInfo) getObjectPart() {}
@ -825,10 +755,8 @@ func (r *GetRequestBody) GetAddress() *refs.Address {
}
func (r *GetRequestBody) SetAddress(v *refs.Address) {
if r != nil {
r.addr = v
}
}
func (r *GetRequestBody) GetRaw() bool {
if r != nil {
@ -839,10 +767,8 @@ func (r *GetRequestBody) GetRaw() bool {
}
func (r *GetRequestBody) SetRaw(v bool) {
if r != nil {
r.raw = v
}
}
func (r *GetRequest) GetBody() *GetRequestBody {
if r != nil {
@ -853,10 +779,8 @@ func (r *GetRequest) GetBody() *GetRequestBody {
}
func (r *GetRequest) SetBody(v *GetRequestBody) {
if r != nil {
r.body = v
}
}
func (r *GetObjectPartInit) GetObjectID() *refs.ObjectID {
if r != nil {
@ -867,10 +791,8 @@ func (r *GetObjectPartInit) GetObjectID() *refs.ObjectID {
}
func (r *GetObjectPartInit) SetObjectID(v *refs.ObjectID) {
if r != nil {
r.id = v
}
}
func (r *GetObjectPartInit) GetSignature() *refs.Signature {
if r != nil {
@ -881,10 +803,8 @@ func (r *GetObjectPartInit) GetSignature() *refs.Signature {
}
func (r *GetObjectPartInit) SetSignature(v *refs.Signature) {
if r != nil {
r.sig = v
}
}
func (r *GetObjectPartInit) GetHeader() *Header {
if r != nil {
@ -895,10 +815,8 @@ func (r *GetObjectPartInit) GetHeader() *Header {
}
func (r *GetObjectPartInit) SetHeader(v *Header) {
if r != nil {
r.hdr = v
}
}
func (r *GetObjectPartInit) getObjectPart() {}
@ -911,10 +829,8 @@ func (r *GetObjectPartChunk) GetChunk() []byte {
}
func (r *GetObjectPartChunk) SetChunk(v []byte) {
if r != nil {
r.chunk = v
}
}
func (r *GetObjectPartChunk) getObjectPart() {}
@ -927,10 +843,8 @@ func (r *GetResponseBody) GetObjectPart() GetObjectPart {
}
func (r *GetResponseBody) SetObjectPart(v GetObjectPart) {
if r != nil {
r.objPart = v
}
}
func (r *GetResponse) GetBody() *GetResponseBody {
if r != nil {
@ -941,10 +855,8 @@ func (r *GetResponse) GetBody() *GetResponseBody {
}
func (r *GetResponse) SetBody(v *GetResponseBody) {
if r != nil {
r.body = v
}
}
func (r *PutObjectPartInit) GetObjectID() *refs.ObjectID {
if r != nil {
@ -955,10 +867,8 @@ func (r *PutObjectPartInit) GetObjectID() *refs.ObjectID {
}
func (r *PutObjectPartInit) SetObjectID(v *refs.ObjectID) {
if r != nil {
r.id = v
}
}
func (r *PutObjectPartInit) GetSignature() *refs.Signature {
if r != nil {
@ -969,10 +879,8 @@ func (r *PutObjectPartInit) GetSignature() *refs.Signature {
}
func (r *PutObjectPartInit) SetSignature(v *refs.Signature) {
if r != nil {
r.sig = v
}
}
func (r *PutObjectPartInit) GetHeader() *Header {
if r != nil {
@ -983,10 +891,8 @@ func (r *PutObjectPartInit) GetHeader() *Header {
}
func (r *PutObjectPartInit) SetHeader(v *Header) {
if r != nil {
r.hdr = v
}
}
func (r *PutObjectPartInit) GetCopiesNumber() uint32 {
if r != nil {
@ -997,10 +903,8 @@ func (r *PutObjectPartInit) GetCopiesNumber() uint32 {
}
func (r *PutObjectPartInit) SetCopiesNumber(v uint32) {
if r != nil {
r.copyNum = v
}
}
func (r *PutObjectPartInit) putObjectPart() {}
@ -1013,10 +917,8 @@ func (r *PutObjectPartChunk) GetChunk() []byte {
}
func (r *PutObjectPartChunk) SetChunk(v []byte) {
if r != nil {
r.chunk = v
}
}
func (r *PutObjectPartChunk) putObjectPart() {}
@ -1029,10 +931,8 @@ func (r *PutRequestBody) GetObjectPart() PutObjectPart {
}
func (r *PutRequestBody) SetObjectPart(v PutObjectPart) {
if r != nil {
r.objPart = v
}
}
func (r *PutRequest) GetBody() *PutRequestBody {
if r != nil {
@ -1043,10 +943,8 @@ func (r *PutRequest) GetBody() *PutRequestBody {
}
func (r *PutRequest) SetBody(v *PutRequestBody) {
if r != nil {
r.body = v
}
}
func (r *PutResponseBody) GetObjectID() *refs.ObjectID {
if r != nil {
@ -1057,10 +955,8 @@ func (r *PutResponseBody) GetObjectID() *refs.ObjectID {
}
func (r *PutResponseBody) SetObjectID(v *refs.ObjectID) {
if r != nil {
r.id = v
}
}
func (r *PutResponse) GetBody() *PutResponseBody {
if r != nil {
@ -1071,10 +967,8 @@ func (r *PutResponse) GetBody() *PutResponseBody {
}
func (r *PutResponse) SetBody(v *PutResponseBody) {
if r != nil {
r.body = v
}
}
func (r *DeleteRequestBody) GetAddress() *refs.Address {
if r != nil {
@ -1085,10 +979,8 @@ func (r *DeleteRequestBody) GetAddress() *refs.Address {
}
func (r *DeleteRequestBody) SetAddress(v *refs.Address) {
if r != nil {
r.addr = v
}
}
func (r *DeleteRequest) GetBody() *DeleteRequestBody {
if r != nil {
@ -1099,10 +991,8 @@ func (r *DeleteRequest) GetBody() *DeleteRequestBody {
}
func (r *DeleteRequest) SetBody(v *DeleteRequestBody) {
if r != nil {
r.body = v
}
}
// GetTombstone returns tombstone address.
func (r *DeleteResponseBody) GetTombstone() *refs.Address {
@ -1115,10 +1005,8 @@ func (r *DeleteResponseBody) GetTombstone() *refs.Address {
// SetTombstone sets tombstone address.
func (r *DeleteResponseBody) SetTombstone(v *refs.Address) {
if r != nil {
r.tombstone = v
}
}
func (r *DeleteResponse) GetBody() *DeleteResponseBody {
if r != nil {
@ -1129,10 +1017,8 @@ func (r *DeleteResponse) GetBody() *DeleteResponseBody {
}
func (r *DeleteResponse) SetBody(v *DeleteResponseBody) {
if r != nil {
r.body = v
}
}
func (r *HeadRequestBody) GetAddress() *refs.Address {
if r != nil {
@ -1143,10 +1029,8 @@ func (r *HeadRequestBody) GetAddress() *refs.Address {
}
func (r *HeadRequestBody) SetAddress(v *refs.Address) {
if r != nil {
r.addr = v
}
}
func (r *HeadRequestBody) GetMainOnly() bool {
if r != nil {
@ -1157,10 +1041,8 @@ func (r *HeadRequestBody) GetMainOnly() bool {
}
func (r *HeadRequestBody) SetMainOnly(v bool) {
if r != nil {
r.mainOnly = v
}
}
func (r *HeadRequestBody) GetRaw() bool {
if r != nil {
@ -1171,10 +1053,8 @@ func (r *HeadRequestBody) GetRaw() bool {
}
func (r *HeadRequestBody) SetRaw(v bool) {
if r != nil {
r.raw = v
}
}
func (r *HeadRequest) GetBody() *HeadRequestBody {
if r != nil {
@ -1185,10 +1065,8 @@ func (r *HeadRequest) GetBody() *HeadRequestBody {
}
func (r *HeadRequest) SetBody(v *HeadRequestBody) {
if r != nil {
r.body = v
}
}
func (r *HeadResponseBody) GetHeaderPart() GetHeaderPart {
if r != nil {
@ -1199,10 +1077,8 @@ func (r *HeadResponseBody) GetHeaderPart() GetHeaderPart {
}
func (r *HeadResponseBody) SetHeaderPart(v GetHeaderPart) {
if r != nil {
r.hdrPart = v
}
}
func (r *HeadResponse) GetBody() *HeadResponseBody {
if r != nil {
@ -1213,10 +1089,8 @@ func (r *HeadResponse) GetBody() *HeadResponseBody {
}
func (r *HeadResponse) SetBody(v *HeadResponseBody) {
if r != nil {
r.body = v
}
}
func (f *SearchFilter) GetMatchType() MatchType {
if f != nil {
@ -1227,10 +1101,8 @@ func (f *SearchFilter) GetMatchType() MatchType {
}
func (f *SearchFilter) SetMatchType(v MatchType) {
if f != nil {
f.matchType = v
}
}
func (f *SearchFilter) GetKey() string {
if f != nil {
@ -1241,10 +1113,8 @@ func (f *SearchFilter) GetKey() string {
}
func (f *SearchFilter) SetKey(v string) {
if f != nil {
f.key = v
}
}
func (f *SearchFilter) GetValue() string {
if f != nil {
@ -1255,10 +1125,8 @@ func (f *SearchFilter) GetValue() string {
}
func (f *SearchFilter) SetValue(v string) {
if f != nil {
f.val = v
}
}
func (r *SearchRequestBody) GetContainerID() *refs.ContainerID {
if r != nil {
@ -1269,10 +1137,8 @@ func (r *SearchRequestBody) GetContainerID() *refs.ContainerID {
}
func (r *SearchRequestBody) SetContainerID(v *refs.ContainerID) {
if r != nil {
r.cid = v
}
}
func (r *SearchRequestBody) GetVersion() uint32 {
if r != nil {
@ -1283,10 +1149,8 @@ func (r *SearchRequestBody) GetVersion() uint32 {
}
func (r *SearchRequestBody) SetVersion(v uint32) {
if r != nil {
r.version = v
}
}
func (r *SearchRequestBody) GetFilters() []SearchFilter {
if r != nil {
@ -1297,10 +1161,8 @@ func (r *SearchRequestBody) GetFilters() []SearchFilter {
}
func (r *SearchRequestBody) SetFilters(v []SearchFilter) {
if r != nil {
r.filters = v
}
}
func (r *SearchRequest) GetBody() *SearchRequestBody {
if r != nil {
@ -1311,10 +1173,8 @@ func (r *SearchRequest) GetBody() *SearchRequestBody {
}
func (r *SearchRequest) SetBody(v *SearchRequestBody) {
if r != nil {
r.body = v
}
}
func (r *SearchResponseBody) GetIDList() []refs.ObjectID {
if r != nil {
@ -1325,10 +1185,8 @@ func (r *SearchResponseBody) GetIDList() []refs.ObjectID {
}
func (r *SearchResponseBody) SetIDList(v []refs.ObjectID) {
if r != nil {
r.idList = v
}
}
func (r *SearchResponse) GetBody() *SearchResponseBody {
if r != nil {
@ -1339,10 +1197,8 @@ func (r *SearchResponse) GetBody() *SearchResponseBody {
}
func (r *SearchResponse) SetBody(v *SearchResponseBody) {
if r != nil {
r.body = v
}
}
func (r *Range) GetOffset() uint64 {
if r != nil {
@ -1353,10 +1209,8 @@ func (r *Range) GetOffset() uint64 {
}
func (r *Range) SetOffset(v uint64) {
if r != nil {
r.off = v
}
}
func (r *Range) GetLength() uint64 {
if r != nil {
@ -1367,10 +1221,8 @@ func (r *Range) GetLength() uint64 {
}
func (r *Range) SetLength(v uint64) {
if r != nil {
r.len = v
}
}
func (r *GetRangeRequestBody) GetAddress() *refs.Address {
if r != nil {
@ -1381,10 +1233,8 @@ func (r *GetRangeRequestBody) GetAddress() *refs.Address {
}
func (r *GetRangeRequestBody) SetAddress(v *refs.Address) {
if r != nil {
r.addr = v
}
}
func (r *GetRangeRequestBody) GetRange() *Range {
if r != nil {
@ -1395,10 +1245,8 @@ func (r *GetRangeRequestBody) GetRange() *Range {
}
func (r *GetRangeRequestBody) SetRange(v *Range) {
if r != nil {
r.rng = v
}
}
func (r *GetRangeRequestBody) GetRaw() bool {
if r != nil {
@ -1409,10 +1257,8 @@ func (r *GetRangeRequestBody) GetRaw() bool {
}
func (r *GetRangeRequestBody) SetRaw(v bool) {
if r != nil {
r.raw = v
}
}
func (r *GetRangeRequest) GetBody() *GetRangeRequestBody {
if r != nil {
@ -1423,10 +1269,8 @@ func (r *GetRangeRequest) GetBody() *GetRangeRequestBody {
}
func (r *GetRangeRequest) SetBody(v *GetRangeRequestBody) {
if r != nil {
r.body = v
}
}
func (r *GetRangePartChunk) GetChunk() []byte {
if r != nil {
@ -1437,10 +1281,8 @@ func (r *GetRangePartChunk) GetChunk() []byte {
}
func (r *GetRangePartChunk) SetChunk(v []byte) {
if r != nil {
r.chunk = v
}
}
func (r *GetRangePartChunk) getRangePart() {}
@ -1453,10 +1295,8 @@ func (r *GetRangeResponseBody) GetRangePart() GetRangePart {
}
func (r *GetRangeResponseBody) SetRangePart(v GetRangePart) {
if r != nil {
r.rngPart = v
}
}
func (r *GetRangeResponse) GetBody() *GetRangeResponseBody {
if r != nil {
@ -1467,10 +1307,8 @@ func (r *GetRangeResponse) GetBody() *GetRangeResponseBody {
}
func (r *GetRangeResponse) SetBody(v *GetRangeResponseBody) {
if r != nil {
r.body = v
}
}
func (r *GetRangeHashRequestBody) GetAddress() *refs.Address {
if r != nil {
@ -1481,10 +1319,8 @@ func (r *GetRangeHashRequestBody) GetAddress() *refs.Address {
}
func (r *GetRangeHashRequestBody) SetAddress(v *refs.Address) {
if r != nil {
r.addr = v
}
}
func (r *GetRangeHashRequestBody) GetRanges() []Range {
if r != nil {
@ -1495,10 +1331,8 @@ func (r *GetRangeHashRequestBody) GetRanges() []Range {
}
func (r *GetRangeHashRequestBody) SetRanges(v []Range) {
if r != nil {
r.rngs = v
}
}
func (r *GetRangeHashRequestBody) GetSalt() []byte {
if r != nil {
@ -1509,10 +1343,8 @@ func (r *GetRangeHashRequestBody) GetSalt() []byte {
}
func (r *GetRangeHashRequestBody) SetSalt(v []byte) {
if r != nil {
r.salt = v
}
}
func (r *GetRangeHashRequestBody) GetType() refs.ChecksumType {
if r != nil {
@ -1523,10 +1355,8 @@ func (r *GetRangeHashRequestBody) GetType() refs.ChecksumType {
}
func (r *GetRangeHashRequestBody) SetType(v refs.ChecksumType) {
if r != nil {
r.typ = v
}
}
func (r *GetRangeHashRequest) GetBody() *GetRangeHashRequestBody {
if r != nil {
@ -1537,10 +1367,8 @@ func (r *GetRangeHashRequest) GetBody() *GetRangeHashRequestBody {
}
func (r *GetRangeHashRequest) SetBody(v *GetRangeHashRequestBody) {
if r != nil {
r.body = v
}
}
func (r *GetRangeHashResponseBody) GetType() refs.ChecksumType {
if r != nil {
@ -1551,10 +1379,8 @@ func (r *GetRangeHashResponseBody) GetType() refs.ChecksumType {
}
func (r *GetRangeHashResponseBody) SetType(v refs.ChecksumType) {
if r != nil {
r.typ = v
}
}
func (r *GetRangeHashResponseBody) GetHashList() [][]byte {
if r != nil {
@ -1565,10 +1391,8 @@ func (r *GetRangeHashResponseBody) GetHashList() [][]byte {
}
func (r *GetRangeHashResponseBody) SetHashList(v [][]byte) {
if r != nil {
r.hashList = v
}
}
func (r *GetRangeHashResponse) GetBody() *GetRangeHashResponseBody {
if r != nil {
@ -1579,7 +1403,5 @@ func (r *GetRangeHashResponse) GetBody() *GetRangeHashResponseBody {
}
func (r *GetRangeHashResponse) SetBody(v *GetRangeHashResponseBody) {
if r != nil {
r.body = v
}
}

View file

@ -2,101 +2,73 @@ package refs
// SetValue sets container identifier in a binary format.
func (x *ContainerID) SetValue(v []byte) {
if x != nil {
x.Value = v
}
}
// SetValue sets object identifier in a binary format.
func (x *ObjectID) SetValue(v []byte) {
if x != nil {
x.Value = v
}
}
// SetValue sets owner identifier in a binary format.
func (x *OwnerID) SetValue(v []byte) {
if x != nil {
x.Value = v
}
}
// SetContainerId sets container identifier of the address.
func (x *Address) SetContainerId(v *ContainerID) {
if x != nil {
x.ContainerId = v
}
}
// SetObjectId sets object identifier of the address.
func (x *Address) SetObjectId(v *ObjectID) {
if x != nil {
x.ObjectId = v
}
}
// SetChecksumType in generic checksum structure.
func (x *Checksum) SetChecksumType(v ChecksumType) {
if x != nil {
x.Type = v
}
}
// SetSum in generic checksum structure.
func (x *Checksum) SetSum(v []byte) {
if x != nil {
x.Sum = v
}
}
// SetMajor sets major version number.
func (x *Version) SetMajor(v uint32) {
if x != nil {
x.Major = v
}
}
// SetMinor sets minor version number.
func (x *Version) SetMinor(v uint32) {
if x != nil {
x.Minor = v
}
}
// SetKey sets public key in a binary format.
func (x *Signature) SetKey(v []byte) {
if x != nil {
x.Key = v
}
}
// SetSign sets signature.
func (x *Signature) SetSign(v []byte) {
if x != nil {
x.Sign = v
}
}
// SetScheme sets signature scheme.
func (x *Signature) SetScheme(s SignatureScheme) {
if x != nil {
x.Scheme = s
}
}
// SetKey sets public key in a binary format.
func (x *SignatureRFC6979) SetKey(v []byte) {
if x != nil {
x.Key = v
}
}
// SetSign sets signature.
func (x *SignatureRFC6979) SetSign(v []byte) {
if x != nil {
x.Sign = v
}
}
// FromString parses SignatureScheme from a string representation,
// It is a reverse action to String().
@ -126,7 +98,5 @@ func (x *ChecksumType) FromString(s string) bool {
// SetValue sets subnet identifier in a base-10 integer format.
func (x *SubnetID) SetValue(v uint32) {
if x != nil {
x.Value = v
}
}

View file

@ -67,10 +67,8 @@ func (o *OwnerID) GetValue() []byte {
}
func (o *OwnerID) SetValue(v []byte) {
if o != nil {
o.val = v
}
}
func (c *ContainerID) GetValue() []byte {
if c != nil {
@ -81,10 +79,8 @@ func (c *ContainerID) GetValue() []byte {
}
func (c *ContainerID) SetValue(v []byte) {
if c != nil {
c.val = v
}
}
func (o *ObjectID) GetValue() []byte {
if o != nil {
@ -95,10 +91,8 @@ func (o *ObjectID) GetValue() []byte {
}
func (o *ObjectID) SetValue(v []byte) {
if o != nil {
o.val = v
}
}
func (a *Address) GetContainerID() *ContainerID {
if a != nil {
@ -109,10 +103,8 @@ func (a *Address) GetContainerID() *ContainerID {
}
func (a *Address) SetContainerID(v *ContainerID) {
if a != nil {
a.cid = v
}
}
func (a *Address) GetObjectID() *ObjectID {
if a != nil {
@ -123,10 +115,8 @@ func (a *Address) GetObjectID() *ObjectID {
}
func (a *Address) SetObjectID(v *ObjectID) {
if a != nil {
a.oid = v
}
}
func (c *Checksum) GetType() ChecksumType {
if c != nil {
@ -137,10 +127,8 @@ func (c *Checksum) GetType() ChecksumType {
}
func (c *Checksum) SetType(v ChecksumType) {
if c != nil {
c.typ = v
}
}
func (c *Checksum) GetSum() []byte {
if c != nil {
@ -151,10 +139,8 @@ func (c *Checksum) GetSum() []byte {
}
func (c *Checksum) SetSum(v []byte) {
if c != nil {
c.sum = v
}
}
func (s *Signature) GetKey() []byte {
if s != nil {
@ -165,10 +151,8 @@ func (s *Signature) GetKey() []byte {
}
func (s *Signature) SetKey(v []byte) {
if s != nil {
s.key = v
}
}
func (s *Signature) GetSign() []byte {
if s != nil {
@ -179,10 +163,8 @@ func (s *Signature) GetSign() []byte {
}
func (s *Signature) SetSign(v []byte) {
if s != nil {
s.sign = v
}
}
func (s *Signature) GetScheme() SignatureScheme {
if s != nil {
@ -192,16 +174,12 @@ func (s *Signature) GetScheme() SignatureScheme {
}
func (s *Signature) SetScheme(scheme SignatureScheme) {
if s != nil {
s.scheme = scheme
}
}
func (s *SubnetID) SetValue(id uint32) {
if s != nil {
s.value = id
}
}
func (s *SubnetID) GetValue() uint32 {
if s != nil {
@ -258,10 +236,8 @@ func (v *Version) GetMajor() uint32 {
}
func (v *Version) SetMajor(val uint32) {
if v != nil {
v.major = val
}
}
func (v *Version) GetMinor() uint32 {
if v != nil {
@ -272,7 +248,5 @@ func (v *Version) GetMinor() uint32 {
}
func (v *Version) SetMinor(val uint32) {
if v != nil {
v.minor = val
}
}

View file

@ -6,119 +6,85 @@ import (
// SetEpoch sets epoch in which the trust was assessed.
func (x *AnnounceLocalTrustRequest_Body) SetEpoch(v uint64) {
if x != nil {
x.Epoch = v
}
}
// SetTrusts sets list of normalized trust values.
func (x *AnnounceLocalTrustRequest_Body) SetTrusts(v []*Trust) {
if x != nil {
x.Trusts = v
}
}
// SetBody sets body of the request.
func (x *AnnounceLocalTrustRequest) SetBody(v *AnnounceLocalTrustRequest_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (x *AnnounceLocalTrustRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (x *AnnounceLocalTrustRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}
// SetBody sets body of the response.
func (x *AnnounceLocalTrustResponse) SetBody(v *AnnounceLocalTrustResponse_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (x *AnnounceLocalTrustResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (x *AnnounceLocalTrustResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}
// SetEpoch sets epoch in which the intermediate trust was assessed.
func (x *AnnounceIntermediateResultRequest_Body) SetEpoch(v uint64) {
if x != nil {
x.Epoch = v
}
}
// SetIteration sets sequence number of the iteration.
func (x *AnnounceIntermediateResultRequest_Body) SetIteration(v uint32) {
if x != nil {
x.Iteration = v
}
}
// SetTrust sets current global trust value.
func (x *AnnounceIntermediateResultRequest_Body) SetTrust(v *PeerToPeerTrust) {
if x != nil {
x.Trust = v
}
}
// SetBody sets body of the request.
func (x *AnnounceIntermediateResultRequest) SetBody(v *AnnounceIntermediateResultRequest_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (x *AnnounceIntermediateResultRequest) SetMetaHeader(v *session.RequestMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (x *AnnounceIntermediateResultRequest) SetVerifyHeader(v *session.RequestVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}
// SetBody sets body of the response.
func (x *AnnounceIntermediateResultResponse) SetBody(v *AnnounceIntermediateResultResponse_Body) {
if x != nil {
x.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (x *AnnounceIntermediateResultResponse) SetMetaHeader(v *session.ResponseMetaHeader) {
if x != nil {
x.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (x *AnnounceIntermediateResultResponse) SetVerifyHeader(v *session.ResponseVerificationHeader) {
if x != nil {
x.VerifyHeader = v
}
}

View file

@ -6,70 +6,50 @@ import (
// SetPublicKey sets binary public key of ID.
func (x *PeerID) SetPublicKey(v []byte) {
if x != nil {
x.PublicKey = v
}
}
// SetPeer sets trusted peer's ID.
func (x *Trust) SetPeer(v *PeerID) {
if x != nil {
x.Peer = v
}
}
// SetValue sets trust value.
func (x *Trust) SetValue(v float64) {
if x != nil {
x.Value = v
}
}
// SetTrustingPeer sets trusting peer ID.
func (x *PeerToPeerTrust) SetTrustingPeer(v *PeerID) {
if x != nil {
x.TrustingPeer = v
}
}
// SetTrust sets trust value of trusting peer to the trusted one.
func (x *PeerToPeerTrust) SetTrust(v *Trust) {
if x != nil {
x.Trust = v
}
}
// SetManager sets manager ID.
func (x *GlobalTrust_Body) SetManager(v *PeerID) {
if x != nil {
x.Manager = v
}
}
// SetTrust sets global trust value.
func (x *GlobalTrust_Body) SetTrust(v *Trust) {
if x != nil {
x.Trust = v
}
}
// SetVersion sets message format version.
func (x *GlobalTrust) SetVersion(v *refs.Version) {
if x != nil {
x.Version = v
}
}
// SetBody sets message body.
func (x *GlobalTrust) SetBody(v *GlobalTrust_Body) {
if x != nil {
x.Body = v
}
}
// SetSignature sets body signature.
func (x *GlobalTrust) SetSignature(v *refs.Signature) {
if x != nil {
x.Signature = v
}
}

View file

@ -22,10 +22,8 @@ func (x *PeerID) GetPublicKey() []byte {
// SetPublicKey sets peer's binary public key of ID.
func (x *PeerID) SetPublicKey(v []byte) {
if x != nil {
x.publicKey = v
}
}
// Trust represents reputation.Trust message
// from NeoFS API v2.
@ -46,10 +44,8 @@ func (x *Trust) GetPeer() *PeerID {
// SetPeer sets trusted peer's ID.
func (x *Trust) SetPeer(v *PeerID) {
if x != nil {
x.peer = v
}
}
// GetValue returns trust value.
func (x *Trust) GetValue() float64 {
@ -62,10 +58,8 @@ func (x *Trust) GetValue() float64 {
// SetValue sets trust value.
func (x *Trust) SetValue(v float64) {
if x != nil {
x.val = v
}
}
// PeerToPeerTrust represents reputation.PeerToPeerTrust message
// from NeoFS API v2.
@ -86,10 +80,8 @@ func (x *PeerToPeerTrust) GetTrustingPeer() *PeerID {
// SetTrustingPeer sets trusting peer ID.
func (x *PeerToPeerTrust) SetTrustingPeer(v *PeerID) {
if x != nil {
x.trusting = v
}
}
// GetTrust returns trust value of trusting peer to the trusted one.
func (x *PeerToPeerTrust) GetTrust() *Trust {
@ -102,10 +94,8 @@ func (x *PeerToPeerTrust) GetTrust() *Trust {
// SetTrust sets trust value of trusting peer to the trusted one.
func (x *PeerToPeerTrust) SetTrust(v *Trust) {
if x != nil {
x.trust = v
}
}
// GlobalTrustBody represents reputation.GlobalTrust.Body message
// from NeoFS API v2.
@ -126,10 +116,8 @@ func (x *GlobalTrustBody) GetManager() *PeerID {
// SetManager sets node manager ID.
func (x *GlobalTrustBody) SetManager(v *PeerID) {
if x != nil {
x.manager = v
}
}
// GetTrust returns global trust value.
func (x *GlobalTrustBody) GetTrust() *Trust {
@ -142,10 +130,8 @@ func (x *GlobalTrustBody) GetTrust() *Trust {
// SetTrust sets global trust value.
func (x *GlobalTrustBody) SetTrust(v *Trust) {
if x != nil {
x.trust = v
}
}
// GlobalTrust represents reputation.GlobalTrust message
// from NeoFS API v2.
@ -168,10 +154,8 @@ func (x *GlobalTrust) GetVersion() *refs.Version {
// SetVersion sets message format version.
func (x *GlobalTrust) SetVersion(v *refs.Version) {
if x != nil {
x.version = v
}
}
// GetBody returns message body.
func (x *GlobalTrust) GetBody() *GlobalTrustBody {
@ -184,10 +168,8 @@ func (x *GlobalTrust) GetBody() *GlobalTrustBody {
// SetBody sets message body.
func (x *GlobalTrust) SetBody(v *GlobalTrustBody) {
if x != nil {
x.body = v
}
}
// GetSignature returns body signature.
func (x *GlobalTrust) GetSignature() *refs.Signature {
@ -200,10 +182,8 @@ func (x *GlobalTrust) GetSignature() *refs.Signature {
// SetSignature sets body signature.
func (x *GlobalTrust) SetSignature(v *refs.Signature) {
if x != nil {
x.sig = v
}
}
// AnnounceLocalTrustRequestBody is a structure of AnnounceLocalTrust request body.
type AnnounceLocalTrustRequestBody struct {
@ -223,10 +203,8 @@ func (x *AnnounceLocalTrustRequestBody) GetEpoch() uint64 {
// SetEpoch sets epoch in which the trust was assessed.
func (x *AnnounceLocalTrustRequestBody) SetEpoch(v uint64) {
if x != nil {
x.epoch = v
}
}
// GetTrusts returns list of normalized trust values.
func (x *AnnounceLocalTrustRequestBody) GetTrusts() []Trust {
@ -239,10 +217,8 @@ func (x *AnnounceLocalTrustRequestBody) GetTrusts() []Trust {
// SetTrusts sets list of normalized trust values.
func (x *AnnounceLocalTrustRequestBody) SetTrusts(v []Trust) {
if x != nil {
x.trusts = v
}
}
// AnnounceLocalTrustResponseBody is a structure of AnnounceLocalTrust response body.
type AnnounceLocalTrustResponseBody struct{}
@ -266,10 +242,8 @@ func (x *AnnounceLocalTrustRequest) GetBody() *AnnounceLocalTrustRequestBody {
// SetBody sets request body.
func (x *AnnounceLocalTrustRequest) SetBody(v *AnnounceLocalTrustRequestBody) {
if x != nil {
x.body = v
}
}
// AnnounceLocalTrustResponse represents reputation.AnnounceLocalTrustResponse
// message from NeoFS API v2.
@ -290,10 +264,8 @@ func (x *AnnounceLocalTrustResponse) GetBody() *AnnounceLocalTrustResponseBody {
// SetBody sets response body.
func (x *AnnounceLocalTrustResponse) SetBody(v *AnnounceLocalTrustResponseBody) {
if x != nil {
x.body = v
}
}
// AnnounceIntermediateResultRequestBody is a structure of AnnounceIntermediateResult request body.
type AnnounceIntermediateResultRequestBody struct {
@ -315,10 +287,8 @@ func (x *AnnounceIntermediateResultRequestBody) GetEpoch() uint64 {
// SetEpoch sets epoch number in which the intermediate trust was assessed.
func (x *AnnounceIntermediateResultRequestBody) SetEpoch(v uint64) {
if x != nil {
x.epoch = v
}
}
// GetIteration returns sequence number of the iteration.
func (x *AnnounceIntermediateResultRequestBody) GetIteration() uint32 {
@ -331,10 +301,8 @@ func (x *AnnounceIntermediateResultRequestBody) GetIteration() uint32 {
// SetIteration sets sequence number of the iteration.
func (x *AnnounceIntermediateResultRequestBody) SetIteration(v uint32) {
if x != nil {
x.iter = v
}
}
// GetTrust returns current global trust value.
func (x *AnnounceIntermediateResultRequestBody) GetTrust() *PeerToPeerTrust {
@ -347,10 +315,8 @@ func (x *AnnounceIntermediateResultRequestBody) GetTrust() *PeerToPeerTrust {
// SetTrust sets current global trust value.
func (x *AnnounceIntermediateResultRequestBody) SetTrust(v *PeerToPeerTrust) {
if x != nil {
x.trust = v
}
}
// AnnounceIntermediateResultResponseBody is a structure of AnnounceIntermediateResult response body.
type AnnounceIntermediateResultResponseBody struct{}
@ -374,10 +340,8 @@ func (x *AnnounceIntermediateResultRequest) GetBody() *AnnounceIntermediateResul
// SetBody sets request body.
func (x *AnnounceIntermediateResultRequest) SetBody(v *AnnounceIntermediateResultRequestBody) {
if x != nil {
x.body = v
}
}
// AnnounceIntermediateResultResponse represents reputation.AnnounceIntermediateResultResponse
// message from NeoFS API v2.
@ -398,7 +362,5 @@ func (x *AnnounceIntermediateResultResponse) GetBody() *AnnounceIntermediateResu
// SetBody sets response body.
func (x *AnnounceIntermediateResultResponse) SetBody(v *AnnounceIntermediateResultResponseBody) {
if x != nil {
x.body = v
}
}

View file

@ -6,70 +6,50 @@ import (
// SetOwnerId sets identifier of the session initiator.
func (m *CreateRequest_Body) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetExpiration sets lifetime of the session.
func (m *CreateRequest_Body) SetExpiration(v uint64) {
if m != nil {
m.Expiration = v
}
}
// SetBody sets body of the request.
func (m *CreateRequest) SetBody(v *CreateRequest_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the request.
func (m *CreateRequest) SetMetaHeader(v *RequestMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the request.
func (m *CreateRequest) SetVerifyHeader(v *RequestVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}
// SetId sets identifier of the session token.
func (m *CreateResponse_Body) SetId(v []byte) {
if m != nil {
m.Id = v
}
}
// SetSessionKey sets session public key in a binary format.
func (m *CreateResponse_Body) SetSessionKey(v []byte) {
if m != nil {
m.SessionKey = v
}
}
// SetBody sets body of the response.
func (m *CreateResponse) SetBody(v *CreateResponse_Body) {
if m != nil {
m.Body = v
}
}
// SetMetaHeader sets meta header of the response.
func (m *CreateResponse) SetMetaHeader(v *ResponseMetaHeader) {
if m != nil {
m.MetaHeader = v
}
}
// SetVerifyHeader sets verification header of the response.
func (m *CreateResponse) SetVerifyHeader(v *ResponseVerificationHeader) {
if m != nil {
m.VerifyHeader = v
}
}

View file

@ -8,182 +8,132 @@ import (
// SetKey sets key to the X-Header.
func (m *XHeader) SetKey(v string) {
if m != nil {
m.Key = v
}
}
// SetValue sets value of the X-Header.
func (m *XHeader) SetValue(v string) {
if m != nil {
m.Value = v
}
}
// SetExp sets epoch number of the token expiration.
func (m *SessionToken_Body_TokenLifetime) SetExp(v uint64) {
if m != nil {
m.Exp = v
}
}
// SetNbf sets starting epoch number of the token.
func (m *SessionToken_Body_TokenLifetime) SetNbf(v uint64) {
if m != nil {
m.Nbf = v
}
}
// SetIat sets the number of the epoch in which the token was issued.
func (m *SessionToken_Body_TokenLifetime) SetIat(v uint64) {
if m != nil {
m.Iat = v
}
}
// SetId sets identifier of the session token.
func (m *SessionToken_Body) SetId(v []byte) {
if m != nil {
m.Id = v
}
}
// SetOwnerId sets identifier of the session token owner.
func (m *SessionToken_Body) SetOwnerId(v *refs.OwnerID) {
if m != nil {
m.OwnerId = v
}
}
// SetLifetime sets lifetime of the session token.
func (m *SessionToken_Body) SetLifetime(v *SessionToken_Body_TokenLifetime) {
if m != nil {
m.Lifetime = v
}
}
// SetSessionKey sets public session key in a binary format.
func (m *SessionToken_Body) SetSessionKey(v []byte) {
if m != nil {
m.SessionKey = v
}
}
// SetObjectAddressContext sets object context of the session token.
func (m *SessionToken_Body) SetObjectSessionContext(v *ObjectSessionContext) {
if m != nil {
m.Context = &SessionToken_Body_Object{
Object: v,
}
}
}
// SetContainerSessionContext sets container context of the session token.
func (m *SessionToken_Body) SetContainerSessionContext(v *ContainerSessionContext) {
if m != nil {
m.Context = &SessionToken_Body_Container{
Container: v,
}
}
}
// SetAddress sets address of the object related to the session.
func (m *ObjectSessionContext) SetAddress(v *refs.Address) {
if m != nil {
m.Address = v
}
}
// SetVerb sets type of request for which the token is issued.
func (m *ObjectSessionContext) SetVerb(v ObjectSessionContext_Verb) {
if m != nil {
m.Verb = v
}
}
// SetVerb sets type of request for which the token is issued.
func (x *ContainerSessionContext) SetVerb(v ContainerSessionContext_Verb) {
if x != nil {
x.Verb = v
}
}
// SetWildcard sets wildcard flag of the container session.
func (x *ContainerSessionContext) SetWildcard(v bool) {
if x != nil {
x.Wildcard = v
}
}
// SetContainerId sets identifier of the container related to the session.
func (x *ContainerSessionContext) SetContainerId(v *refs.ContainerID) {
if x != nil {
x.ContainerId = v
}
}
// SetBody sets session token body.
func (m *SessionToken) SetBody(v *SessionToken_Body) {
if m != nil {
m.Body = v
}
}
// SetSignature sets session token signature.
func (m *SessionToken) SetSignature(v *refs.Signature) {
if m != nil {
m.Signature = v
}
}
// SetVersion sets client protocol version.
func (m *RequestMetaHeader) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetEpoch sets client local epoch.
func (m *RequestMetaHeader) SetEpoch(v uint64) {
if m != nil {
m.Epoch = v
}
}
// SetTtl sets request TTL.
func (m *RequestMetaHeader) SetTtl(v uint32) {
if m != nil {
m.Ttl = v
}
}
// SetXHeaders sets request X-Headers.
func (m *RequestMetaHeader) SetXHeaders(v []*XHeader) {
if m != nil {
m.XHeaders = v
}
}
// SetSessionToken sets session token of the request.
func (m *RequestMetaHeader) SetSessionToken(v *SessionToken) {
if m != nil {
m.SessionToken = v
}
}
// SetBearerToken sets bearer token of the request.
func (m *RequestMetaHeader) SetBearerToken(v *acl.BearerToken) {
if m != nil {
m.BearerToken = v
}
}
// SetOrigin sets origin request meta header.
func (m *RequestMetaHeader) SetOrigin(v *RequestMetaHeader) {
if m != nil {
m.Origin = v
}
}
// GetNetworkMagic returns NeoFS network magic.
func (m *RequestMetaHeader) GetNetworkMagic() uint64 {
@ -196,108 +146,78 @@ func (m *RequestMetaHeader) GetNetworkMagic() uint64 {
// SetNetworkMagic sets NeoFS network magic.
func (m *RequestMetaHeader) SetNetworkMagic(v uint64) {
if m != nil {
m.MagicNumber = v
}
}
// SetVersion sets server protocol version.
func (m *ResponseMetaHeader) SetVersion(v *refs.Version) {
if m != nil {
m.Version = v
}
}
// SetEpoch sets server local epoch.
func (m *ResponseMetaHeader) SetEpoch(v uint64) {
if m != nil {
m.Epoch = v
}
}
// SetTtl sets response TTL.
func (m *ResponseMetaHeader) SetTtl(v uint32) {
if m != nil {
m.Ttl = v
}
}
// SetXHeaders sets response X-Headers.
func (m *ResponseMetaHeader) SetXHeaders(v []*XHeader) {
if m != nil {
m.XHeaders = v
}
}
// SetOrigin sets origin response meta header.
func (m *ResponseMetaHeader) SetOrigin(v *ResponseMetaHeader) {
if m != nil {
m.Origin = v
}
}
// SetStatus sets response status.
func (m *ResponseMetaHeader) SetStatus(v *status.Status) {
if m != nil {
m.Status = v
}
}
// SetBodySignature sets signature of the request body.
func (m *RequestVerificationHeader) SetBodySignature(v *refs.Signature) {
if m != nil {
m.BodySignature = v
}
}
// SetMetaSignature sets signature of the request meta.
func (m *RequestVerificationHeader) SetMetaSignature(v *refs.Signature) {
if m != nil {
m.MetaSignature = v
}
}
// SetOriginSignature sets signature of the origin verification header of the request.
func (m *RequestVerificationHeader) SetOriginSignature(v *refs.Signature) {
if m != nil {
m.OriginSignature = v
}
}
// SetOrigin sets origin verification header of the request.
func (m *RequestVerificationHeader) SetOrigin(v *RequestVerificationHeader) {
if m != nil {
m.Origin = v
}
}
// SetBodySignature sets signature of the response body.
func (m *ResponseVerificationHeader) SetBodySignature(v *refs.Signature) {
if m != nil {
m.BodySignature = v
}
}
// SetMetaSignature sets signature of the response meta.
func (m *ResponseVerificationHeader) SetMetaSignature(v *refs.Signature) {
if m != nil {
m.MetaSignature = v
}
}
// SetOriginSignature sets signature of the origin verification header of the response.
func (m *ResponseVerificationHeader) SetOriginSignature(v *refs.Signature) {
if m != nil {
m.OriginSignature = v
}
}
// SetOrigin sets origin verification header of the response.
func (m *ResponseVerificationHeader) SetOrigin(v *ResponseVerificationHeader) {
if m != nil {
m.Origin = v
}
}
// FromString parses ObjectSessionContext_Verb from a string representation,
// It is a reverse action to String().

View file

@ -144,10 +144,8 @@ func (c *CreateRequestBody) GetOwnerID() *refs.OwnerID {
}
func (c *CreateRequestBody) SetOwnerID(v *refs.OwnerID) {
if c != nil {
c.ownerID = v
}
}
func (c *CreateRequestBody) GetExpiration() uint64 {
if c != nil {
@ -158,10 +156,8 @@ func (c *CreateRequestBody) GetExpiration() uint64 {
}
func (c *CreateRequestBody) SetExpiration(v uint64) {
if c != nil {
c.expiration = v
}
}
func (c *CreateRequest) GetBody() *CreateRequestBody {
if c != nil {
@ -172,10 +168,8 @@ func (c *CreateRequest) GetBody() *CreateRequestBody {
}
func (c *CreateRequest) SetBody(v *CreateRequestBody) {
if c != nil {
c.body = v
}
}
func (c *CreateRequest) GetMetaHeader() *RequestMetaHeader {
if c != nil {
@ -186,10 +180,8 @@ func (c *CreateRequest) GetMetaHeader() *RequestMetaHeader {
}
func (c *CreateRequest) SetMetaHeader(v *RequestMetaHeader) {
if c != nil {
c.metaHeader = v
}
}
func (c *CreateRequest) GetVerificationHeader() *RequestVerificationHeader {
if c != nil {
@ -200,10 +192,8 @@ func (c *CreateRequest) GetVerificationHeader() *RequestVerificationHeader {
}
func (c *CreateRequest) SetVerificationHeader(v *RequestVerificationHeader) {
if c != nil {
c.verifyHeader = v
}
}
func (c *CreateResponseBody) GetID() []byte {
if c != nil {
@ -214,10 +204,8 @@ func (c *CreateResponseBody) GetID() []byte {
}
func (c *CreateResponseBody) SetID(v []byte) {
if c != nil {
c.id = v
}
}
func (c *CreateResponseBody) GetSessionKey() []byte {
if c != nil {
@ -228,10 +216,8 @@ func (c *CreateResponseBody) GetSessionKey() []byte {
}
func (c *CreateResponseBody) SetSessionKey(v []byte) {
if c != nil {
c.sessionKey = v
}
}
func (c *CreateResponse) GetBody() *CreateResponseBody {
if c != nil {
@ -242,10 +228,8 @@ func (c *CreateResponse) GetBody() *CreateResponseBody {
}
func (c *CreateResponse) SetBody(v *CreateResponseBody) {
if c != nil {
c.body = v
}
}
func (c *CreateResponse) GetMetaHeader() *ResponseMetaHeader {
if c != nil {
@ -256,10 +240,8 @@ func (c *CreateResponse) GetMetaHeader() *ResponseMetaHeader {
}
func (c *CreateResponse) SetMetaHeader(v *ResponseMetaHeader) {
if c != nil {
c.metaHeader = v
}
}
func (c *CreateResponse) GetVerificationHeader() *ResponseVerificationHeader {
if c != nil {
@ -270,10 +252,8 @@ func (c *CreateResponse) GetVerificationHeader() *ResponseVerificationHeader {
}
func (c *CreateResponse) SetVerificationHeader(v *ResponseVerificationHeader) {
if c != nil {
c.verifyHeader = v
}
}
func (x *XHeader) GetKey() string {
if x != nil {
@ -284,10 +264,8 @@ func (x *XHeader) GetKey() string {
}
func (x *XHeader) SetKey(v string) {
if x != nil {
x.key = v
}
}
func (x *XHeader) GetValue() string {
if x != nil {
@ -298,10 +276,8 @@ func (x *XHeader) GetValue() string {
}
func (x *XHeader) SetValue(v string) {
if x != nil {
x.val = v
}
}
func (r *RequestVerificationHeader) GetBodySignature() *refs.Signature {
if r != nil {
@ -312,10 +288,8 @@ func (r *RequestVerificationHeader) GetBodySignature() *refs.Signature {
}
func (r *RequestVerificationHeader) SetBodySignature(v *refs.Signature) {
if r != nil {
r.bodySig = v
}
}
func (r *RequestVerificationHeader) GetMetaSignature() *refs.Signature {
if r != nil {
@ -326,10 +300,8 @@ func (r *RequestVerificationHeader) GetMetaSignature() *refs.Signature {
}
func (r *RequestVerificationHeader) SetMetaSignature(v *refs.Signature) {
if r != nil {
r.metaSig = v
}
}
func (r *RequestVerificationHeader) GetOriginSignature() *refs.Signature {
if r != nil {
@ -340,10 +312,8 @@ func (r *RequestVerificationHeader) GetOriginSignature() *refs.Signature {
}
func (r *RequestVerificationHeader) SetOriginSignature(v *refs.Signature) {
if r != nil {
r.originSig = v
}
}
func (r *RequestVerificationHeader) GetOrigin() *RequestVerificationHeader {
if r != nil {
@ -354,10 +324,8 @@ func (r *RequestVerificationHeader) GetOrigin() *RequestVerificationHeader {
}
func (r *RequestVerificationHeader) SetOrigin(v *RequestVerificationHeader) {
if r != nil {
r.origin = v
}
}
func (r *RequestMetaHeader) GetVersion() *refs.Version {
if r != nil {
@ -368,10 +336,8 @@ func (r *RequestMetaHeader) GetVersion() *refs.Version {
}
func (r *RequestMetaHeader) SetVersion(v *refs.Version) {
if r != nil {
r.version = v
}
}
func (r *RequestMetaHeader) GetTTL() uint32 {
if r != nil {
@ -382,10 +348,8 @@ func (r *RequestMetaHeader) GetTTL() uint32 {
}
func (r *RequestMetaHeader) SetTTL(v uint32) {
if r != nil {
r.ttl = v
}
}
func (r *RequestMetaHeader) GetEpoch() uint64 {
if r != nil {
@ -396,10 +360,8 @@ func (r *RequestMetaHeader) GetEpoch() uint64 {
}
func (r *RequestMetaHeader) SetEpoch(v uint64) {
if r != nil {
r.epoch = v
}
}
func (r *RequestMetaHeader) GetXHeaders() []XHeader {
if r != nil {
@ -410,10 +372,8 @@ func (r *RequestMetaHeader) GetXHeaders() []XHeader {
}
func (r *RequestMetaHeader) SetXHeaders(v []XHeader) {
if r != nil {
r.xHeaders = v
}
}
func (r *RequestMetaHeader) GetSessionToken() *Token {
if r != nil {
@ -424,10 +384,8 @@ func (r *RequestMetaHeader) GetSessionToken() *Token {
}
func (r *RequestMetaHeader) SetSessionToken(v *Token) {
if r != nil {
r.sessionToken = v
}
}
func (r *RequestMetaHeader) GetBearerToken() *acl.BearerToken {
if r != nil {
@ -438,10 +396,8 @@ func (r *RequestMetaHeader) GetBearerToken() *acl.BearerToken {
}
func (r *RequestMetaHeader) SetBearerToken(v *acl.BearerToken) {
if r != nil {
r.bearerToken = v
}
}
func (r *RequestMetaHeader) GetOrigin() *RequestMetaHeader {
if r != nil {
@ -452,10 +408,8 @@ func (r *RequestMetaHeader) GetOrigin() *RequestMetaHeader {
}
func (r *RequestMetaHeader) SetOrigin(v *RequestMetaHeader) {
if r != nil {
r.origin = v
}
}
// GetNetworkMagic returns NeoFS network magic.
func (r *RequestMetaHeader) GetNetworkMagic() uint64 {
@ -468,10 +422,8 @@ func (r *RequestMetaHeader) GetNetworkMagic() uint64 {
// SetNetworkMagic sets NeoFS network magic.
func (r *RequestMetaHeader) SetNetworkMagic(v uint64) {
if r != nil {
r.netMagic = v
}
}
func (l *TokenLifetime) GetExp() uint64 {
if l != nil {
@ -482,10 +434,8 @@ func (l *TokenLifetime) GetExp() uint64 {
}
func (l *TokenLifetime) SetExp(v uint64) {
if l != nil {
l.exp = v
}
}
func (l *TokenLifetime) GetNbf() uint64 {
if l != nil {
@ -496,10 +446,8 @@ func (l *TokenLifetime) GetNbf() uint64 {
}
func (l *TokenLifetime) SetNbf(v uint64) {
if l != nil {
l.nbf = v
}
}
func (l *TokenLifetime) GetIat() uint64 {
if l != nil {
@ -510,10 +458,8 @@ func (l *TokenLifetime) GetIat() uint64 {
}
func (l *TokenLifetime) SetIat(v uint64) {
if l != nil {
l.iat = v
}
}
func (r *ResponseVerificationHeader) GetBodySignature() *refs.Signature {
if r != nil {
@ -524,10 +470,8 @@ func (r *ResponseVerificationHeader) GetBodySignature() *refs.Signature {
}
func (r *ResponseVerificationHeader) SetBodySignature(v *refs.Signature) {
if r != nil {
r.bodySig = v
}
}
func (r *ResponseVerificationHeader) GetMetaSignature() *refs.Signature {
if r != nil {
@ -538,10 +482,8 @@ func (r *ResponseVerificationHeader) GetMetaSignature() *refs.Signature {
}
func (r *ResponseVerificationHeader) SetMetaSignature(v *refs.Signature) {
if r != nil {
r.metaSig = v
}
}
func (r *ResponseVerificationHeader) GetOriginSignature() *refs.Signature {
if r != nil {
@ -552,10 +494,8 @@ func (r *ResponseVerificationHeader) GetOriginSignature() *refs.Signature {
}
func (r *ResponseVerificationHeader) SetOriginSignature(v *refs.Signature) {
if r != nil {
r.originSig = v
}
}
func (r *ResponseVerificationHeader) GetOrigin() *ResponseVerificationHeader {
if r != nil {
@ -566,10 +506,8 @@ func (r *ResponseVerificationHeader) GetOrigin() *ResponseVerificationHeader {
}
func (r *ResponseVerificationHeader) SetOrigin(v *ResponseVerificationHeader) {
if r != nil {
r.origin = v
}
}
func (r *ResponseMetaHeader) GetVersion() *refs.Version {
if r != nil {
@ -580,10 +518,8 @@ func (r *ResponseMetaHeader) GetVersion() *refs.Version {
}
func (r *ResponseMetaHeader) SetVersion(v *refs.Version) {
if r != nil {
r.version = v
}
}
func (r *ResponseMetaHeader) GetTTL() uint32 {
if r != nil {
@ -594,10 +530,8 @@ func (r *ResponseMetaHeader) GetTTL() uint32 {
}
func (r *ResponseMetaHeader) SetTTL(v uint32) {
if r != nil {
r.ttl = v
}
}
func (r *ResponseMetaHeader) GetEpoch() uint64 {
if r != nil {
@ -608,10 +542,8 @@ func (r *ResponseMetaHeader) GetEpoch() uint64 {
}
func (r *ResponseMetaHeader) SetEpoch(v uint64) {
if r != nil {
r.epoch = v
}
}
func (r *ResponseMetaHeader) GetXHeaders() []XHeader {
if r != nil {
@ -622,10 +554,8 @@ func (r *ResponseMetaHeader) GetXHeaders() []XHeader {
}
func (r *ResponseMetaHeader) SetXHeaders(v []XHeader) {
if r != nil {
r.xHeaders = v
}
}
func (r *ResponseMetaHeader) GetOrigin() *ResponseMetaHeader {
if r != nil {
@ -636,10 +566,8 @@ func (r *ResponseMetaHeader) GetOrigin() *ResponseMetaHeader {
}
func (r *ResponseMetaHeader) SetOrigin(v *ResponseMetaHeader) {
if r != nil {
r.origin = v
}
}
// GetStatus returns response status.
func (r *ResponseMetaHeader) GetStatus() *status.Status {
@ -652,10 +580,8 @@ func (r *ResponseMetaHeader) GetStatus() *status.Status {
// SetStatus sets response status.
func (r *ResponseMetaHeader) SetStatus(v *status.Status) {
if r != nil {
r.status = v
}
}
// SetStatus sets status of the message which can carry ResponseMetaHeader.
//
@ -685,10 +611,8 @@ func (c *ObjectSessionContext) GetVerb() ObjectSessionVerb {
}
func (c *ObjectSessionContext) SetVerb(v ObjectSessionVerb) {
if c != nil {
c.verb = v
}
}
func (c *ObjectSessionContext) GetAddress() *refs.Address {
if c != nil {
@ -699,10 +623,8 @@ func (c *ObjectSessionContext) GetAddress() *refs.Address {
}
func (c *ObjectSessionContext) SetAddress(v *refs.Address) {
if c != nil {
c.addr = v
}
}
func (t *TokenBody) GetID() []byte {
if t != nil {
@ -713,10 +635,8 @@ func (t *TokenBody) GetID() []byte {
}
func (t *TokenBody) SetID(v []byte) {
if t != nil {
t.id = v
}
}
func (t *TokenBody) GetOwnerID() *refs.OwnerID {
if t != nil {
@ -727,10 +647,8 @@ func (t *TokenBody) GetOwnerID() *refs.OwnerID {
}
func (t *TokenBody) SetOwnerID(v *refs.OwnerID) {
if t != nil {
t.ownerID = v
}
}
func (t *TokenBody) GetLifetime() *TokenLifetime {
if t != nil {
@ -741,10 +659,8 @@ func (t *TokenBody) GetLifetime() *TokenLifetime {
}
func (t *TokenBody) SetLifetime(v *TokenLifetime) {
if t != nil {
t.lifetime = v
}
}
func (t *TokenBody) GetSessionKey() []byte {
if t != nil {
@ -755,10 +671,8 @@ func (t *TokenBody) GetSessionKey() []byte {
}
func (t *TokenBody) SetSessionKey(v []byte) {
if t != nil {
t.sessionKey = v
}
}
func (t *TokenBody) GetContext() TokenContext {
if t != nil {
@ -769,10 +683,8 @@ func (t *TokenBody) GetContext() TokenContext {
}
func (t *TokenBody) SetContext(v TokenContext) {
if t != nil {
t.ctx = v
}
}
func (t *Token) GetBody() *TokenBody {
if t != nil {
@ -783,10 +695,8 @@ func (t *Token) GetBody() *TokenBody {
}
func (t *Token) SetBody(v *TokenBody) {
if t != nil {
t.body = v
}
}
func (t *Token) GetSignature() *refs.Signature {
if t != nil {
@ -797,10 +707,8 @@ func (t *Token) GetSignature() *refs.Signature {
}
func (t *Token) SetSignature(v *refs.Signature) {
if t != nil {
t.sig = v
}
}
// ContainerSessionVerb represents NeoFS API v2
// session.ContainerSessionContext.Verb enumeration.
@ -843,10 +751,8 @@ func (x *ContainerSessionContext) Verb() ContainerSessionVerb {
// SetVerb sets type of request for which the token is issued.
func (x *ContainerSessionContext) SetVerb(v ContainerSessionVerb) {
if x != nil {
x.verb = v
}
}
// Wildcard returns wildcard flag of the container session.
func (x *ContainerSessionContext) Wildcard() bool {
@ -859,10 +765,8 @@ func (x *ContainerSessionContext) Wildcard() bool {
// SetWildcard sets wildcard flag of the container session.
func (x *ContainerSessionContext) SetWildcard(v bool) {
if x != nil {
x.wildcard = v
}
}
// ContainerID returns identifier of the container related to the session.
func (x *ContainerSessionContext) ContainerID() *refs.ContainerID {
@ -875,7 +779,5 @@ func (x *ContainerSessionContext) ContainerID() *refs.ContainerID {
// SetContainerID sets identifier of the container related to the session.
func (x *ContainerSessionContext) SetContainerID(v *refs.ContainerID) {
if x != nil {
x.cid = v
}
}

View file

@ -23,10 +23,8 @@ func (c *RequestHeaders) GetMetaHeader() *RequestMetaHeader {
// SetMetaHeader sets meta header of the request.
func (c *RequestHeaders) SetMetaHeader(v *RequestMetaHeader) {
if c != nil {
c.metaHeader = v
}
}
// GetVerificationHeader returns verification header of the request.
func (c *RequestHeaders) GetVerificationHeader() *RequestVerificationHeader {
@ -39,10 +37,8 @@ func (c *RequestHeaders) GetVerificationHeader() *RequestVerificationHeader {
// SetVerificationHeader sets verification header of the request.
func (c *RequestHeaders) SetVerificationHeader(v *RequestVerificationHeader) {
if c != nil {
c.verifyHeader = v
}
}
func (c *RequestHeaders) ToMessage(m interface {
SetMetaHeader(*session.RequestMetaHeader)
@ -106,10 +102,8 @@ func (c *ResponseHeaders) GetMetaHeader() *ResponseMetaHeader {
// SetMetaHeader sets meta header of the response.
func (c *ResponseHeaders) SetMetaHeader(v *ResponseMetaHeader) {
if c != nil {
c.metaHeader = v
}
}
// GetVerificationHeader returns verification header of the response.
func (c *ResponseHeaders) GetVerificationHeader() *ResponseVerificationHeader {
@ -122,10 +116,8 @@ func (c *ResponseHeaders) GetVerificationHeader() *ResponseVerificationHeader {
// SetVerificationHeader sets verification header of the response.
func (c *ResponseHeaders) SetVerificationHeader(v *ResponseVerificationHeader) {
if c != nil {
c.verifyHeader = v
}
}
func (c *ResponseHeaders) ToMessage(m interface {
SetMetaHeader(*session.ResponseMetaHeader)

View file

@ -2,35 +2,25 @@ package status
// SetId sets identifier of the Status_Detail.
func (x *Status_Detail) SetId(v uint32) {
if x != nil {
x.Id = v
}
}
// SetValue sets value of the Status_Detail.
func (x *Status_Detail) SetValue(v []byte) {
if x != nil {
x.Value = v
}
}
// SetCode sets code of the Status.
func (x *Status) SetCode(v uint32) {
if x != nil {
x.Code = v
}
}
// SetMessage sets message about the Status.
func (x *Status) SetMessage(v string) {
if x != nil {
x.Message = v
}
}
// SetDetails sets details of the Status.
func (x *Status) SetDetails(v []*Status_Detail) {
if x != nil {
x.Details = v
}
}

View file

@ -18,10 +18,8 @@ func (x *Detail) ID() uint32 {
// SetID sets identifier of the Detail.
func (x *Detail) SetID(id uint32) {
if x != nil {
x.id = id
}
}
// Value returns value of the Detail.
func (x *Detail) Value() []byte {
@ -34,10 +32,8 @@ func (x *Detail) Value() []byte {
// SetValue sets value of the Detail.
func (x *Detail) SetValue(val []byte) {
if x != nil {
x.val = val
}
}
// Code represents NeoFS API V2-compatible status code.
type Code uint32
@ -67,10 +63,8 @@ func (x *Status) Code() Code {
// SetCode sets code of the Status.
func (x *Status) SetCode(code Code) {
if x != nil {
x.code = code
}
}
// Message sets message of the Status.
func (x *Status) Message() string {
@ -83,10 +77,8 @@ func (x *Status) Message() string {
// SetMessage sets message of the Status.
func (x *Status) SetMessage(msg string) {
if x != nil {
x.msg = msg
}
}
// NumberOfParameters returns number of network parameters.
func (x *Status) NumberOfDetails() int {

View file

@ -6,28 +6,20 @@ import (
// SetValidationDataSize sets the total size of the payloads of the storage group.
func (m *StorageGroup) SetValidationDataSize(v uint64) {
if m != nil {
m.ValidationDataSize = v
}
}
// SetValidationHash sets total homomorphic hash of the storage group payloads.
func (m *StorageGroup) SetValidationHash(v *refs.Checksum) {
if m != nil {
m.ValidationHash = v
}
}
// SetExpirationEpoch sets number of the last epoch of the storage group lifetime.
func (m *StorageGroup) SetExpirationEpoch(v uint64) {
if m != nil {
m.ExpirationEpoch = v
}
}
// SetMembers sets list of the identifiers of the storage group members.
func (m *StorageGroup) SetMembers(v []*refs.ObjectID) {
if m != nil {
m.Members = v
}
}

View file

@ -27,10 +27,8 @@ func (s *StorageGroup) GetValidationDataSize() uint64 {
// SetValidationDataSize into unified storage group structure.
func (s *StorageGroup) SetValidationDataSize(v uint64) {
if s != nil {
s.size = v
}
}
// GetValidationHash of unified storage group structure.
func (s *StorageGroup) GetValidationHash() *refs.Checksum {
@ -43,10 +41,8 @@ func (s *StorageGroup) GetValidationHash() *refs.Checksum {
// SetValidationHash into unified storage group structure.
func (s *StorageGroup) SetValidationHash(v *refs.Checksum) {
if s != nil {
s.hash = v
}
}
// GetExpirationEpoch of unified storage group structure.
func (s *StorageGroup) GetExpirationEpoch() uint64 {
@ -59,10 +55,8 @@ func (s *StorageGroup) GetExpirationEpoch() uint64 {
// SetExpirationEpoch into unified storage group structure.
func (s *StorageGroup) SetExpirationEpoch(v uint64) {
if s != nil {
s.exp = v
}
}
// GetMembers of unified storage group structure. Members are objects of
// storage group.
@ -77,7 +71,5 @@ func (s *StorageGroup) GetMembers() []refs.ObjectID {
// SetMembers into unified storage group structure. Members are objects of
// storage group.
func (s *StorageGroup) SetMembers(v []refs.ObjectID) {
if s != nil {
s.members = v
}
}

View file

@ -6,14 +6,10 @@ import (
// SetID returns identifier of the subnet. Nil arg is equivalent to zero subnet ID.
func (x *SubnetInfo) SetID(id *refs.SubnetID) {
if x != nil {
x.Id = id
}
}
// SetOwner sets subnet owner's ID in NeoFS system.
func (x *SubnetInfo) SetOwner(id *refs.OwnerID) {
if x != nil {
x.Owner = id
}
}

View file

@ -6,21 +6,15 @@ import (
// SetExpirationEpoch sets number of tombstone expiration epoch.
func (x *Tombstone) SetExpirationEpoch(v uint64) {
if x != nil {
x.ExpirationEpoch = v
}
}
// SetSplitId sets identifier of split object hierarchy.
func (x *Tombstone) SetSplitId(v []byte) {
if x != nil {
x.SplitId = v
}
}
// SetMembers sets list of objects to be deleted.
func (x *Tombstone) SetMembers(v []*refs.ObjectID) {
if x != nil {
x.Members = v
}
}

View file

@ -25,10 +25,8 @@ func (s *Tombstone) GetExpirationEpoch() uint64 {
// SetExpirationEpoch sets number of tombstone expiration epoch.
func (s *Tombstone) SetExpirationEpoch(v uint64) {
if s != nil {
s.exp = v
}
}
// GetSplitID returns identifier of split object hierarchy.
func (s *Tombstone) GetSplitID() []byte {
@ -41,10 +39,8 @@ func (s *Tombstone) GetSplitID() []byte {
// SetSplitID sets identifier of split object hierarchy.
func (s *Tombstone) SetSplitID(v []byte) {
if s != nil {
s.splitID = v
}
}
// GetMembers returns list of objects to be deleted.
func (s *Tombstone) GetMembers() []refs.ObjectID {
@ -57,7 +53,5 @@ func (s *Tombstone) GetMembers() []refs.ObjectID {
// SetMembers sets list of objects to be deleted.
func (s *Tombstone) SetMembers(v []refs.ObjectID) {
if s != nil {
s.members = v
}
}