2020-08-13 12:43:47 +00:00
|
|
|
package refs
|
2020-08-12 19:06:10 +00:00
|
|
|
|
|
|
|
// SetValue sets container identifier in a binary format.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *ContainerID) SetValue(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Value = v
|
2020-08-12 19:06:10 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetValue sets object identifier in a binary format.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *ObjectID) SetValue(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Value = v
|
2020-08-12 19:06:10 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetValue sets owner identifier in a binary format.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *OwnerID) SetValue(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Value = v
|
2020-08-12 19:06:10 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetContainerId sets container identifier of the address.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Address) SetContainerId(v *ContainerID) {
|
|
|
|
if x != nil {
|
|
|
|
x.ContainerId = v
|
2020-08-12 19:06:10 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetObjectId sets object identifier of the address.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Address) SetObjectId(v *ObjectID) {
|
|
|
|
if x != nil {
|
|
|
|
x.ObjectId = v
|
2020-08-12 19:06:10 +00:00
|
|
|
}
|
|
|
|
}
|
2020-08-20 07:59:45 +00:00
|
|
|
|
|
|
|
// SetChecksumType in generic checksum structure.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Checksum) SetChecksumType(v ChecksumType) {
|
|
|
|
if x != nil {
|
|
|
|
x.Type = v
|
2020-08-20 07:59:45 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-02-22 11:14:33 +00:00
|
|
|
// SetSum in generic checksum structure.
|
|
|
|
func (x *Checksum) SetSum(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Sum = v
|
2020-08-20 07:59:45 +00:00
|
|
|
}
|
|
|
|
}
|
2020-08-20 09:43:47 +00:00
|
|
|
|
|
|
|
// SetMajor sets major version number.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Version) SetMajor(v uint32) {
|
|
|
|
if x != nil {
|
|
|
|
x.Major = v
|
2020-08-20 09:43:47 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetMinor sets minor version number.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Version) SetMinor(v uint32) {
|
|
|
|
if x != nil {
|
|
|
|
x.Minor = v
|
2020-08-20 09:43:47 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetKey sets public key in a binary format.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Signature) SetKey(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Key = v
|
2020-08-20 09:43:47 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetSign sets signature.
|
2022-02-22 11:14:33 +00:00
|
|
|
func (x *Signature) SetSign(v []byte) {
|
|
|
|
if x != nil {
|
|
|
|
x.Sign = v
|
2020-08-20 09:43:47 +00:00
|
|
|
}
|
|
|
|
}
|
2021-06-18 12:27:01 +00:00
|
|
|
|
|
|
|
// FromString parses ChecksumType from a string representation,
|
|
|
|
// It is a reverse action to String().
|
|
|
|
//
|
|
|
|
// Returns true if s was parsed successfully.
|
|
|
|
func (x *ChecksumType) FromString(s string) bool {
|
|
|
|
i, ok := ChecksumType_value[s]
|
|
|
|
if ok {
|
|
|
|
*x = ChecksumType(i)
|
|
|
|
}
|
|
|
|
|
|
|
|
return ok
|
|
|
|
}
|
2021-11-18 13:32:09 +00:00
|
|
|
|
|
|
|
// SetValue sets subnet identifier in a base-10 integer format.
|
|
|
|
func (x *SubnetID) SetValue(v uint32) {
|
|
|
|
if x != nil {
|
|
|
|
x.Value = v
|
|
|
|
}
|
|
|
|
}
|