cosmos-sdk/api/cosmos/gov/v1/gov.pulsar.go

10974 lines
411 KiB
Go

// Code generated by protoc-gen-go-pulsar. DO NOT EDIT.
package govv1
import (
_ "cosmossdk.io/api/amino"
v1beta1 "cosmossdk.io/api/cosmos/base/v1beta1"
fmt "fmt"
_ "github.com/cosmos/cosmos-proto"
runtime "github.com/cosmos/cosmos-proto/runtime"
_ "github.com/cosmos/gogoproto/gogoproto"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoiface "google.golang.org/protobuf/runtime/protoiface"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
anypb "google.golang.org/protobuf/types/known/anypb"
durationpb "google.golang.org/protobuf/types/known/durationpb"
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
io "io"
reflect "reflect"
sync "sync"
)
var (
md_WeightedVoteOption protoreflect.MessageDescriptor
fd_WeightedVoteOption_option protoreflect.FieldDescriptor
fd_WeightedVoteOption_weight protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_WeightedVoteOption = File_cosmos_gov_v1_gov_proto.Messages().ByName("WeightedVoteOption")
fd_WeightedVoteOption_option = md_WeightedVoteOption.Fields().ByName("option")
fd_WeightedVoteOption_weight = md_WeightedVoteOption.Fields().ByName("weight")
}
var _ protoreflect.Message = (*fastReflection_WeightedVoteOption)(nil)
type fastReflection_WeightedVoteOption WeightedVoteOption
func (x *WeightedVoteOption) ProtoReflect() protoreflect.Message {
return (*fastReflection_WeightedVoteOption)(x)
}
func (x *WeightedVoteOption) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_WeightedVoteOption_messageType fastReflection_WeightedVoteOption_messageType
var _ protoreflect.MessageType = fastReflection_WeightedVoteOption_messageType{}
type fastReflection_WeightedVoteOption_messageType struct{}
func (x fastReflection_WeightedVoteOption_messageType) Zero() protoreflect.Message {
return (*fastReflection_WeightedVoteOption)(nil)
}
func (x fastReflection_WeightedVoteOption_messageType) New() protoreflect.Message {
return new(fastReflection_WeightedVoteOption)
}
func (x fastReflection_WeightedVoteOption_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_WeightedVoteOption
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_WeightedVoteOption) Descriptor() protoreflect.MessageDescriptor {
return md_WeightedVoteOption
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_WeightedVoteOption) Type() protoreflect.MessageType {
return _fastReflection_WeightedVoteOption_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_WeightedVoteOption) New() protoreflect.Message {
return new(fastReflection_WeightedVoteOption)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_WeightedVoteOption) Interface() protoreflect.ProtoMessage {
return (*WeightedVoteOption)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_WeightedVoteOption) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.Option != 0 {
value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Option))
if !f(fd_WeightedVoteOption_option, value) {
return
}
}
if x.Weight != "" {
value := protoreflect.ValueOfString(x.Weight)
if !f(fd_WeightedVoteOption_weight, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_WeightedVoteOption) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
return x.Option != 0
case "cosmos.gov.v1.WeightedVoteOption.weight":
return x.Weight != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_WeightedVoteOption) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
x.Option = 0
case "cosmos.gov.v1.WeightedVoteOption.weight":
x.Weight = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_WeightedVoteOption) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
value := x.Option
return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value))
case "cosmos.gov.v1.WeightedVoteOption.weight":
value := x.Weight
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_WeightedVoteOption) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
x.Option = (VoteOption)(value.Enum())
case "cosmos.gov.v1.WeightedVoteOption.weight":
x.Weight = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_WeightedVoteOption) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
panic(fmt.Errorf("field option of message cosmos.gov.v1.WeightedVoteOption is not mutable"))
case "cosmos.gov.v1.WeightedVoteOption.weight":
panic(fmt.Errorf("field weight of message cosmos.gov.v1.WeightedVoteOption is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_WeightedVoteOption) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.WeightedVoteOption.option":
return protoreflect.ValueOfEnum(0)
case "cosmos.gov.v1.WeightedVoteOption.weight":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.WeightedVoteOption"))
}
panic(fmt.Errorf("message cosmos.gov.v1.WeightedVoteOption does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_WeightedVoteOption) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.WeightedVoteOption", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_WeightedVoteOption) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_WeightedVoteOption) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_WeightedVoteOption) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_WeightedVoteOption) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*WeightedVoteOption)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.Option != 0 {
n += 1 + runtime.Sov(uint64(x.Option))
}
l = len(x.Weight)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*WeightedVoteOption)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.Weight) > 0 {
i -= len(x.Weight)
copy(dAtA[i:], x.Weight)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Weight)))
i--
dAtA[i] = 0x12
}
if x.Option != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.Option))
i--
dAtA[i] = 0x8
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*WeightedVoteOption)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WeightedVoteOption: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: WeightedVoteOption: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Option", wireType)
}
x.Option = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.Option |= VoteOption(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Weight = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var _ protoreflect.List = (*_Deposit_3_list)(nil)
type _Deposit_3_list struct {
list *[]*v1beta1.Coin
}
func (x *_Deposit_3_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Deposit_3_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Deposit_3_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
(*x.list)[i] = concreteValue
}
func (x *_Deposit_3_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
*x.list = append(*x.list, concreteValue)
}
func (x *_Deposit_3_list) AppendMutable() protoreflect.Value {
v := new(v1beta1.Coin)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Deposit_3_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Deposit_3_list) NewElement() protoreflect.Value {
v := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Deposit_3_list) IsValid() bool {
return x.list != nil
}
var (
md_Deposit protoreflect.MessageDescriptor
fd_Deposit_proposal_id protoreflect.FieldDescriptor
fd_Deposit_depositor protoreflect.FieldDescriptor
fd_Deposit_amount protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_Deposit = File_cosmos_gov_v1_gov_proto.Messages().ByName("Deposit")
fd_Deposit_proposal_id = md_Deposit.Fields().ByName("proposal_id")
fd_Deposit_depositor = md_Deposit.Fields().ByName("depositor")
fd_Deposit_amount = md_Deposit.Fields().ByName("amount")
}
var _ protoreflect.Message = (*fastReflection_Deposit)(nil)
type fastReflection_Deposit Deposit
func (x *Deposit) ProtoReflect() protoreflect.Message {
return (*fastReflection_Deposit)(x)
}
func (x *Deposit) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_Deposit_messageType fastReflection_Deposit_messageType
var _ protoreflect.MessageType = fastReflection_Deposit_messageType{}
type fastReflection_Deposit_messageType struct{}
func (x fastReflection_Deposit_messageType) Zero() protoreflect.Message {
return (*fastReflection_Deposit)(nil)
}
func (x fastReflection_Deposit_messageType) New() protoreflect.Message {
return new(fastReflection_Deposit)
}
func (x fastReflection_Deposit_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_Deposit
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_Deposit) Descriptor() protoreflect.MessageDescriptor {
return md_Deposit
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_Deposit) Type() protoreflect.MessageType {
return _fastReflection_Deposit_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_Deposit) New() protoreflect.Message {
return new(fastReflection_Deposit)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_Deposit) Interface() protoreflect.ProtoMessage {
return (*Deposit)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_Deposit) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.ProposalId != uint64(0) {
value := protoreflect.ValueOfUint64(x.ProposalId)
if !f(fd_Deposit_proposal_id, value) {
return
}
}
if x.Depositor != "" {
value := protoreflect.ValueOfString(x.Depositor)
if !f(fd_Deposit_depositor, value) {
return
}
}
if len(x.Amount) != 0 {
value := protoreflect.ValueOfList(&_Deposit_3_list{list: &x.Amount})
if !f(fd_Deposit_amount, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_Deposit) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.Deposit.proposal_id":
return x.ProposalId != uint64(0)
case "cosmos.gov.v1.Deposit.depositor":
return x.Depositor != ""
case "cosmos.gov.v1.Deposit.amount":
return len(x.Amount) != 0
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Deposit) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.Deposit.proposal_id":
x.ProposalId = uint64(0)
case "cosmos.gov.v1.Deposit.depositor":
x.Depositor = ""
case "cosmos.gov.v1.Deposit.amount":
x.Amount = nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_Deposit) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.Deposit.proposal_id":
value := x.ProposalId
return protoreflect.ValueOfUint64(value)
case "cosmos.gov.v1.Deposit.depositor":
value := x.Depositor
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Deposit.amount":
if len(x.Amount) == 0 {
return protoreflect.ValueOfList(&_Deposit_3_list{})
}
listValue := &_Deposit_3_list{list: &x.Amount}
return protoreflect.ValueOfList(listValue)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Deposit) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.Deposit.proposal_id":
x.ProposalId = value.Uint()
case "cosmos.gov.v1.Deposit.depositor":
x.Depositor = value.Interface().(string)
case "cosmos.gov.v1.Deposit.amount":
lv := value.List()
clv := lv.(*_Deposit_3_list)
x.Amount = *clv.list
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Deposit) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Deposit.amount":
if x.Amount == nil {
x.Amount = []*v1beta1.Coin{}
}
value := &_Deposit_3_list{list: &x.Amount}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Deposit.proposal_id":
panic(fmt.Errorf("field proposal_id of message cosmos.gov.v1.Deposit is not mutable"))
case "cosmos.gov.v1.Deposit.depositor":
panic(fmt.Errorf("field depositor of message cosmos.gov.v1.Deposit is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_Deposit) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Deposit.proposal_id":
return protoreflect.ValueOfUint64(uint64(0))
case "cosmos.gov.v1.Deposit.depositor":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Deposit.amount":
list := []*v1beta1.Coin{}
return protoreflect.ValueOfList(&_Deposit_3_list{list: &list})
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Deposit"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Deposit does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_Deposit) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.Deposit", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_Deposit) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Deposit) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_Deposit) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_Deposit) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*Deposit)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.ProposalId != 0 {
n += 1 + runtime.Sov(uint64(x.ProposalId))
}
l = len(x.Depositor)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if len(x.Amount) > 0 {
for _, e := range x.Amount {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*Deposit)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.Amount) > 0 {
for iNdEx := len(x.Amount) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.Amount[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x1a
}
}
if len(x.Depositor) > 0 {
i -= len(x.Depositor)
copy(dAtA[i:], x.Depositor)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Depositor)))
i--
dAtA[i] = 0x12
}
if x.ProposalId != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.ProposalId))
i--
dAtA[i] = 0x8
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*Deposit)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Deposit: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Deposit: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalId", wireType)
}
x.ProposalId = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.ProposalId |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Depositor", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Depositor = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Amount = append(x.Amount, &v1beta1.Coin{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Amount[len(x.Amount)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var _ protoreflect.List = (*_Proposal_2_list)(nil)
type _Proposal_2_list struct {
list *[]*anypb.Any
}
func (x *_Proposal_2_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Proposal_2_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Proposal_2_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*anypb.Any)
(*x.list)[i] = concreteValue
}
func (x *_Proposal_2_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*anypb.Any)
*x.list = append(*x.list, concreteValue)
}
func (x *_Proposal_2_list) AppendMutable() protoreflect.Value {
v := new(anypb.Any)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Proposal_2_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Proposal_2_list) NewElement() protoreflect.Value {
v := new(anypb.Any)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Proposal_2_list) IsValid() bool {
return x.list != nil
}
var _ protoreflect.List = (*_Proposal_7_list)(nil)
type _Proposal_7_list struct {
list *[]*v1beta1.Coin
}
func (x *_Proposal_7_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Proposal_7_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Proposal_7_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
(*x.list)[i] = concreteValue
}
func (x *_Proposal_7_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
*x.list = append(*x.list, concreteValue)
}
func (x *_Proposal_7_list) AppendMutable() protoreflect.Value {
v := new(v1beta1.Coin)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Proposal_7_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Proposal_7_list) NewElement() protoreflect.Value {
v := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Proposal_7_list) IsValid() bool {
return x.list != nil
}
var (
md_Proposal protoreflect.MessageDescriptor
fd_Proposal_id protoreflect.FieldDescriptor
fd_Proposal_messages protoreflect.FieldDescriptor
fd_Proposal_status protoreflect.FieldDescriptor
fd_Proposal_final_tally_result protoreflect.FieldDescriptor
fd_Proposal_submit_time protoreflect.FieldDescriptor
fd_Proposal_deposit_end_time protoreflect.FieldDescriptor
fd_Proposal_total_deposit protoreflect.FieldDescriptor
fd_Proposal_voting_start_time protoreflect.FieldDescriptor
fd_Proposal_voting_end_time protoreflect.FieldDescriptor
fd_Proposal_metadata protoreflect.FieldDescriptor
fd_Proposal_title protoreflect.FieldDescriptor
fd_Proposal_summary protoreflect.FieldDescriptor
fd_Proposal_proposer protoreflect.FieldDescriptor
fd_Proposal_expedited protoreflect.FieldDescriptor
fd_Proposal_failed_reason protoreflect.FieldDescriptor
fd_Proposal_proposal_type protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_Proposal = File_cosmos_gov_v1_gov_proto.Messages().ByName("Proposal")
fd_Proposal_id = md_Proposal.Fields().ByName("id")
fd_Proposal_messages = md_Proposal.Fields().ByName("messages")
fd_Proposal_status = md_Proposal.Fields().ByName("status")
fd_Proposal_final_tally_result = md_Proposal.Fields().ByName("final_tally_result")
fd_Proposal_submit_time = md_Proposal.Fields().ByName("submit_time")
fd_Proposal_deposit_end_time = md_Proposal.Fields().ByName("deposit_end_time")
fd_Proposal_total_deposit = md_Proposal.Fields().ByName("total_deposit")
fd_Proposal_voting_start_time = md_Proposal.Fields().ByName("voting_start_time")
fd_Proposal_voting_end_time = md_Proposal.Fields().ByName("voting_end_time")
fd_Proposal_metadata = md_Proposal.Fields().ByName("metadata")
fd_Proposal_title = md_Proposal.Fields().ByName("title")
fd_Proposal_summary = md_Proposal.Fields().ByName("summary")
fd_Proposal_proposer = md_Proposal.Fields().ByName("proposer")
fd_Proposal_expedited = md_Proposal.Fields().ByName("expedited")
fd_Proposal_failed_reason = md_Proposal.Fields().ByName("failed_reason")
fd_Proposal_proposal_type = md_Proposal.Fields().ByName("proposal_type")
}
var _ protoreflect.Message = (*fastReflection_Proposal)(nil)
type fastReflection_Proposal Proposal
func (x *Proposal) ProtoReflect() protoreflect.Message {
return (*fastReflection_Proposal)(x)
}
func (x *Proposal) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_Proposal_messageType fastReflection_Proposal_messageType
var _ protoreflect.MessageType = fastReflection_Proposal_messageType{}
type fastReflection_Proposal_messageType struct{}
func (x fastReflection_Proposal_messageType) Zero() protoreflect.Message {
return (*fastReflection_Proposal)(nil)
}
func (x fastReflection_Proposal_messageType) New() protoreflect.Message {
return new(fastReflection_Proposal)
}
func (x fastReflection_Proposal_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_Proposal
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_Proposal) Descriptor() protoreflect.MessageDescriptor {
return md_Proposal
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_Proposal) Type() protoreflect.MessageType {
return _fastReflection_Proposal_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_Proposal) New() protoreflect.Message {
return new(fastReflection_Proposal)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_Proposal) Interface() protoreflect.ProtoMessage {
return (*Proposal)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_Proposal) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.Id != uint64(0) {
value := protoreflect.ValueOfUint64(x.Id)
if !f(fd_Proposal_id, value) {
return
}
}
if len(x.Messages) != 0 {
value := protoreflect.ValueOfList(&_Proposal_2_list{list: &x.Messages})
if !f(fd_Proposal_messages, value) {
return
}
}
if x.Status != 0 {
value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Status))
if !f(fd_Proposal_status, value) {
return
}
}
if x.FinalTallyResult != nil {
value := protoreflect.ValueOfMessage(x.FinalTallyResult.ProtoReflect())
if !f(fd_Proposal_final_tally_result, value) {
return
}
}
if x.SubmitTime != nil {
value := protoreflect.ValueOfMessage(x.SubmitTime.ProtoReflect())
if !f(fd_Proposal_submit_time, value) {
return
}
}
if x.DepositEndTime != nil {
value := protoreflect.ValueOfMessage(x.DepositEndTime.ProtoReflect())
if !f(fd_Proposal_deposit_end_time, value) {
return
}
}
if len(x.TotalDeposit) != 0 {
value := protoreflect.ValueOfList(&_Proposal_7_list{list: &x.TotalDeposit})
if !f(fd_Proposal_total_deposit, value) {
return
}
}
if x.VotingStartTime != nil {
value := protoreflect.ValueOfMessage(x.VotingStartTime.ProtoReflect())
if !f(fd_Proposal_voting_start_time, value) {
return
}
}
if x.VotingEndTime != nil {
value := protoreflect.ValueOfMessage(x.VotingEndTime.ProtoReflect())
if !f(fd_Proposal_voting_end_time, value) {
return
}
}
if x.Metadata != "" {
value := protoreflect.ValueOfString(x.Metadata)
if !f(fd_Proposal_metadata, value) {
return
}
}
if x.Title != "" {
value := protoreflect.ValueOfString(x.Title)
if !f(fd_Proposal_title, value) {
return
}
}
if x.Summary != "" {
value := protoreflect.ValueOfString(x.Summary)
if !f(fd_Proposal_summary, value) {
return
}
}
if x.Proposer != "" {
value := protoreflect.ValueOfString(x.Proposer)
if !f(fd_Proposal_proposer, value) {
return
}
}
if x.Expedited != false {
value := protoreflect.ValueOfBool(x.Expedited)
if !f(fd_Proposal_expedited, value) {
return
}
}
if x.FailedReason != "" {
value := protoreflect.ValueOfString(x.FailedReason)
if !f(fd_Proposal_failed_reason, value) {
return
}
}
if x.ProposalType != 0 {
value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.ProposalType))
if !f(fd_Proposal_proposal_type, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_Proposal) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.Proposal.id":
return x.Id != uint64(0)
case "cosmos.gov.v1.Proposal.messages":
return len(x.Messages) != 0
case "cosmos.gov.v1.Proposal.status":
return x.Status != 0
case "cosmos.gov.v1.Proposal.final_tally_result":
return x.FinalTallyResult != nil
case "cosmos.gov.v1.Proposal.submit_time":
return x.SubmitTime != nil
case "cosmos.gov.v1.Proposal.deposit_end_time":
return x.DepositEndTime != nil
case "cosmos.gov.v1.Proposal.total_deposit":
return len(x.TotalDeposit) != 0
case "cosmos.gov.v1.Proposal.voting_start_time":
return x.VotingStartTime != nil
case "cosmos.gov.v1.Proposal.voting_end_time":
return x.VotingEndTime != nil
case "cosmos.gov.v1.Proposal.metadata":
return x.Metadata != ""
case "cosmos.gov.v1.Proposal.title":
return x.Title != ""
case "cosmos.gov.v1.Proposal.summary":
return x.Summary != ""
case "cosmos.gov.v1.Proposal.proposer":
return x.Proposer != ""
case "cosmos.gov.v1.Proposal.expedited":
return x.Expedited != false
case "cosmos.gov.v1.Proposal.failed_reason":
return x.FailedReason != ""
case "cosmos.gov.v1.Proposal.proposal_type":
return x.ProposalType != 0
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Proposal) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.Proposal.id":
x.Id = uint64(0)
case "cosmos.gov.v1.Proposal.messages":
x.Messages = nil
case "cosmos.gov.v1.Proposal.status":
x.Status = 0
case "cosmos.gov.v1.Proposal.final_tally_result":
x.FinalTallyResult = nil
case "cosmos.gov.v1.Proposal.submit_time":
x.SubmitTime = nil
case "cosmos.gov.v1.Proposal.deposit_end_time":
x.DepositEndTime = nil
case "cosmos.gov.v1.Proposal.total_deposit":
x.TotalDeposit = nil
case "cosmos.gov.v1.Proposal.voting_start_time":
x.VotingStartTime = nil
case "cosmos.gov.v1.Proposal.voting_end_time":
x.VotingEndTime = nil
case "cosmos.gov.v1.Proposal.metadata":
x.Metadata = ""
case "cosmos.gov.v1.Proposal.title":
x.Title = ""
case "cosmos.gov.v1.Proposal.summary":
x.Summary = ""
case "cosmos.gov.v1.Proposal.proposer":
x.Proposer = ""
case "cosmos.gov.v1.Proposal.expedited":
x.Expedited = false
case "cosmos.gov.v1.Proposal.failed_reason":
x.FailedReason = ""
case "cosmos.gov.v1.Proposal.proposal_type":
x.ProposalType = 0
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_Proposal) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.Proposal.id":
value := x.Id
return protoreflect.ValueOfUint64(value)
case "cosmos.gov.v1.Proposal.messages":
if len(x.Messages) == 0 {
return protoreflect.ValueOfList(&_Proposal_2_list{})
}
listValue := &_Proposal_2_list{list: &x.Messages}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Proposal.status":
value := x.Status
return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value))
case "cosmos.gov.v1.Proposal.final_tally_result":
value := x.FinalTallyResult
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Proposal.submit_time":
value := x.SubmitTime
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Proposal.deposit_end_time":
value := x.DepositEndTime
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Proposal.total_deposit":
if len(x.TotalDeposit) == 0 {
return protoreflect.ValueOfList(&_Proposal_7_list{})
}
listValue := &_Proposal_7_list{list: &x.TotalDeposit}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Proposal.voting_start_time":
value := x.VotingStartTime
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Proposal.voting_end_time":
value := x.VotingEndTime
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Proposal.metadata":
value := x.Metadata
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Proposal.title":
value := x.Title
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Proposal.summary":
value := x.Summary
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Proposal.proposer":
value := x.Proposer
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Proposal.expedited":
value := x.Expedited
return protoreflect.ValueOfBool(value)
case "cosmos.gov.v1.Proposal.failed_reason":
value := x.FailedReason
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Proposal.proposal_type":
value := x.ProposalType
return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value))
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Proposal) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.Proposal.id":
x.Id = value.Uint()
case "cosmos.gov.v1.Proposal.messages":
lv := value.List()
clv := lv.(*_Proposal_2_list)
x.Messages = *clv.list
case "cosmos.gov.v1.Proposal.status":
x.Status = (ProposalStatus)(value.Enum())
case "cosmos.gov.v1.Proposal.final_tally_result":
x.FinalTallyResult = value.Message().Interface().(*TallyResult)
case "cosmos.gov.v1.Proposal.submit_time":
x.SubmitTime = value.Message().Interface().(*timestamppb.Timestamp)
case "cosmos.gov.v1.Proposal.deposit_end_time":
x.DepositEndTime = value.Message().Interface().(*timestamppb.Timestamp)
case "cosmos.gov.v1.Proposal.total_deposit":
lv := value.List()
clv := lv.(*_Proposal_7_list)
x.TotalDeposit = *clv.list
case "cosmos.gov.v1.Proposal.voting_start_time":
x.VotingStartTime = value.Message().Interface().(*timestamppb.Timestamp)
case "cosmos.gov.v1.Proposal.voting_end_time":
x.VotingEndTime = value.Message().Interface().(*timestamppb.Timestamp)
case "cosmos.gov.v1.Proposal.metadata":
x.Metadata = value.Interface().(string)
case "cosmos.gov.v1.Proposal.title":
x.Title = value.Interface().(string)
case "cosmos.gov.v1.Proposal.summary":
x.Summary = value.Interface().(string)
case "cosmos.gov.v1.Proposal.proposer":
x.Proposer = value.Interface().(string)
case "cosmos.gov.v1.Proposal.expedited":
x.Expedited = value.Bool()
case "cosmos.gov.v1.Proposal.failed_reason":
x.FailedReason = value.Interface().(string)
case "cosmos.gov.v1.Proposal.proposal_type":
x.ProposalType = (ProposalType)(value.Enum())
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Proposal) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Proposal.messages":
if x.Messages == nil {
x.Messages = []*anypb.Any{}
}
value := &_Proposal_2_list{list: &x.Messages}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Proposal.final_tally_result":
if x.FinalTallyResult == nil {
x.FinalTallyResult = new(TallyResult)
}
return protoreflect.ValueOfMessage(x.FinalTallyResult.ProtoReflect())
case "cosmos.gov.v1.Proposal.submit_time":
if x.SubmitTime == nil {
x.SubmitTime = new(timestamppb.Timestamp)
}
return protoreflect.ValueOfMessage(x.SubmitTime.ProtoReflect())
case "cosmos.gov.v1.Proposal.deposit_end_time":
if x.DepositEndTime == nil {
x.DepositEndTime = new(timestamppb.Timestamp)
}
return protoreflect.ValueOfMessage(x.DepositEndTime.ProtoReflect())
case "cosmos.gov.v1.Proposal.total_deposit":
if x.TotalDeposit == nil {
x.TotalDeposit = []*v1beta1.Coin{}
}
value := &_Proposal_7_list{list: &x.TotalDeposit}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Proposal.voting_start_time":
if x.VotingStartTime == nil {
x.VotingStartTime = new(timestamppb.Timestamp)
}
return protoreflect.ValueOfMessage(x.VotingStartTime.ProtoReflect())
case "cosmos.gov.v1.Proposal.voting_end_time":
if x.VotingEndTime == nil {
x.VotingEndTime = new(timestamppb.Timestamp)
}
return protoreflect.ValueOfMessage(x.VotingEndTime.ProtoReflect())
case "cosmos.gov.v1.Proposal.id":
panic(fmt.Errorf("field id of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.status":
panic(fmt.Errorf("field status of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.metadata":
panic(fmt.Errorf("field metadata of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.title":
panic(fmt.Errorf("field title of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.summary":
panic(fmt.Errorf("field summary of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.proposer":
panic(fmt.Errorf("field proposer of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.expedited":
panic(fmt.Errorf("field expedited of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.failed_reason":
panic(fmt.Errorf("field failed_reason of message cosmos.gov.v1.Proposal is not mutable"))
case "cosmos.gov.v1.Proposal.proposal_type":
panic(fmt.Errorf("field proposal_type of message cosmos.gov.v1.Proposal is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_Proposal) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Proposal.id":
return protoreflect.ValueOfUint64(uint64(0))
case "cosmos.gov.v1.Proposal.messages":
list := []*anypb.Any{}
return protoreflect.ValueOfList(&_Proposal_2_list{list: &list})
case "cosmos.gov.v1.Proposal.status":
return protoreflect.ValueOfEnum(0)
case "cosmos.gov.v1.Proposal.final_tally_result":
m := new(TallyResult)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Proposal.submit_time":
m := new(timestamppb.Timestamp)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Proposal.deposit_end_time":
m := new(timestamppb.Timestamp)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Proposal.total_deposit":
list := []*v1beta1.Coin{}
return protoreflect.ValueOfList(&_Proposal_7_list{list: &list})
case "cosmos.gov.v1.Proposal.voting_start_time":
m := new(timestamppb.Timestamp)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Proposal.voting_end_time":
m := new(timestamppb.Timestamp)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Proposal.metadata":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Proposal.title":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Proposal.summary":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Proposal.proposer":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Proposal.expedited":
return protoreflect.ValueOfBool(false)
case "cosmos.gov.v1.Proposal.failed_reason":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Proposal.proposal_type":
return protoreflect.ValueOfEnum(0)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Proposal"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Proposal does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_Proposal) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.Proposal", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_Proposal) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Proposal) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_Proposal) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*Proposal)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.Id != 0 {
n += 1 + runtime.Sov(uint64(x.Id))
}
if len(x.Messages) > 0 {
for _, e := range x.Messages {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.Status != 0 {
n += 1 + runtime.Sov(uint64(x.Status))
}
if x.FinalTallyResult != nil {
l = options.Size(x.FinalTallyResult)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.SubmitTime != nil {
l = options.Size(x.SubmitTime)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.DepositEndTime != nil {
l = options.Size(x.DepositEndTime)
n += 1 + l + runtime.Sov(uint64(l))
}
if len(x.TotalDeposit) > 0 {
for _, e := range x.TotalDeposit {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.VotingStartTime != nil {
l = options.Size(x.VotingStartTime)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.VotingEndTime != nil {
l = options.Size(x.VotingEndTime)
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Metadata)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Title)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Summary)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Proposer)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.Expedited {
n += 2
}
l = len(x.FailedReason)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.ProposalType != 0 {
n += 2 + runtime.Sov(uint64(x.ProposalType))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*Proposal)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if x.ProposalType != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.ProposalType))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0x80
}
if len(x.FailedReason) > 0 {
i -= len(x.FailedReason)
copy(dAtA[i:], x.FailedReason)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.FailedReason)))
i--
dAtA[i] = 0x7a
}
if x.Expedited {
i--
if x.Expedited {
dAtA[i] = 1
} else {
dAtA[i] = 0
}
i--
dAtA[i] = 0x70
}
if len(x.Proposer) > 0 {
i -= len(x.Proposer)
copy(dAtA[i:], x.Proposer)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Proposer)))
i--
dAtA[i] = 0x6a
}
if len(x.Summary) > 0 {
i -= len(x.Summary)
copy(dAtA[i:], x.Summary)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Summary)))
i--
dAtA[i] = 0x62
}
if len(x.Title) > 0 {
i -= len(x.Title)
copy(dAtA[i:], x.Title)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Title)))
i--
dAtA[i] = 0x5a
}
if len(x.Metadata) > 0 {
i -= len(x.Metadata)
copy(dAtA[i:], x.Metadata)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Metadata)))
i--
dAtA[i] = 0x52
}
if x.VotingEndTime != nil {
encoded, err := options.Marshal(x.VotingEndTime)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x4a
}
if x.VotingStartTime != nil {
encoded, err := options.Marshal(x.VotingStartTime)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x42
}
if len(x.TotalDeposit) > 0 {
for iNdEx := len(x.TotalDeposit) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.TotalDeposit[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x3a
}
}
if x.DepositEndTime != nil {
encoded, err := options.Marshal(x.DepositEndTime)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x32
}
if x.SubmitTime != nil {
encoded, err := options.Marshal(x.SubmitTime)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x2a
}
if x.FinalTallyResult != nil {
encoded, err := options.Marshal(x.FinalTallyResult)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x22
}
if x.Status != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.Status))
i--
dAtA[i] = 0x18
}
if len(x.Messages) > 0 {
for iNdEx := len(x.Messages) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.Messages[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x12
}
}
if x.Id != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.Id))
i--
dAtA[i] = 0x8
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*Proposal)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Proposal: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Proposal: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
}
x.Id = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.Id |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Messages", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Messages = append(x.Messages, &anypb.Any{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Messages[len(x.Messages)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 3:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
}
x.Status = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.Status |= ProposalStatus(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FinalTallyResult", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.FinalTallyResult == nil {
x.FinalTallyResult = &TallyResult{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.FinalTallyResult); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SubmitTime", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.SubmitTime == nil {
x.SubmitTime = &timestamppb.Timestamp{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.SubmitTime); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 6:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field DepositEndTime", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.DepositEndTime == nil {
x.DepositEndTime = &timestamppb.Timestamp{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.DepositEndTime); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 7:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TotalDeposit", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.TotalDeposit = append(x.TotalDeposit, &v1beta1.Coin{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.TotalDeposit[len(x.TotalDeposit)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 8:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingStartTime", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.VotingStartTime == nil {
x.VotingStartTime = &timestamppb.Timestamp{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.VotingStartTime); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 9:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingEndTime", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.VotingEndTime == nil {
x.VotingEndTime = &timestamppb.Timestamp{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.VotingEndTime); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 10:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Metadata = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 11:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Title = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 12:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Summary", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Summary = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 13:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Proposer", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Proposer = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 14:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Expedited", wireType)
}
var v int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
v |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
x.Expedited = bool(v != 0)
case 15:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FailedReason", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.FailedReason = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 16:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalType", wireType)
}
x.ProposalType = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.ProposalType |= ProposalType(b&0x7F) << shift
if b < 0x80 {
break
}
}
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var (
md_ProposalVoteOptions protoreflect.MessageDescriptor
fd_ProposalVoteOptions_option_one protoreflect.FieldDescriptor
fd_ProposalVoteOptions_option_two protoreflect.FieldDescriptor
fd_ProposalVoteOptions_option_three protoreflect.FieldDescriptor
fd_ProposalVoteOptions_option_four protoreflect.FieldDescriptor
fd_ProposalVoteOptions_option_spam protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_ProposalVoteOptions = File_cosmos_gov_v1_gov_proto.Messages().ByName("ProposalVoteOptions")
fd_ProposalVoteOptions_option_one = md_ProposalVoteOptions.Fields().ByName("option_one")
fd_ProposalVoteOptions_option_two = md_ProposalVoteOptions.Fields().ByName("option_two")
fd_ProposalVoteOptions_option_three = md_ProposalVoteOptions.Fields().ByName("option_three")
fd_ProposalVoteOptions_option_four = md_ProposalVoteOptions.Fields().ByName("option_four")
fd_ProposalVoteOptions_option_spam = md_ProposalVoteOptions.Fields().ByName("option_spam")
}
var _ protoreflect.Message = (*fastReflection_ProposalVoteOptions)(nil)
type fastReflection_ProposalVoteOptions ProposalVoteOptions
func (x *ProposalVoteOptions) ProtoReflect() protoreflect.Message {
return (*fastReflection_ProposalVoteOptions)(x)
}
func (x *ProposalVoteOptions) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_ProposalVoteOptions_messageType fastReflection_ProposalVoteOptions_messageType
var _ protoreflect.MessageType = fastReflection_ProposalVoteOptions_messageType{}
type fastReflection_ProposalVoteOptions_messageType struct{}
func (x fastReflection_ProposalVoteOptions_messageType) Zero() protoreflect.Message {
return (*fastReflection_ProposalVoteOptions)(nil)
}
func (x fastReflection_ProposalVoteOptions_messageType) New() protoreflect.Message {
return new(fastReflection_ProposalVoteOptions)
}
func (x fastReflection_ProposalVoteOptions_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_ProposalVoteOptions
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_ProposalVoteOptions) Descriptor() protoreflect.MessageDescriptor {
return md_ProposalVoteOptions
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_ProposalVoteOptions) Type() protoreflect.MessageType {
return _fastReflection_ProposalVoteOptions_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_ProposalVoteOptions) New() protoreflect.Message {
return new(fastReflection_ProposalVoteOptions)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_ProposalVoteOptions) Interface() protoreflect.ProtoMessage {
return (*ProposalVoteOptions)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_ProposalVoteOptions) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.OptionOne != "" {
value := protoreflect.ValueOfString(x.OptionOne)
if !f(fd_ProposalVoteOptions_option_one, value) {
return
}
}
if x.OptionTwo != "" {
value := protoreflect.ValueOfString(x.OptionTwo)
if !f(fd_ProposalVoteOptions_option_two, value) {
return
}
}
if x.OptionThree != "" {
value := protoreflect.ValueOfString(x.OptionThree)
if !f(fd_ProposalVoteOptions_option_three, value) {
return
}
}
if x.OptionFour != "" {
value := protoreflect.ValueOfString(x.OptionFour)
if !f(fd_ProposalVoteOptions_option_four, value) {
return
}
}
if x.OptionSpam != "" {
value := protoreflect.ValueOfString(x.OptionSpam)
if !f(fd_ProposalVoteOptions_option_spam, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_ProposalVoteOptions) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
return x.OptionOne != ""
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
return x.OptionTwo != ""
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
return x.OptionThree != ""
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
return x.OptionFour != ""
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
return x.OptionSpam != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_ProposalVoteOptions) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
x.OptionOne = ""
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
x.OptionTwo = ""
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
x.OptionThree = ""
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
x.OptionFour = ""
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
x.OptionSpam = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_ProposalVoteOptions) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
value := x.OptionOne
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
value := x.OptionTwo
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
value := x.OptionThree
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
value := x.OptionFour
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
value := x.OptionSpam
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_ProposalVoteOptions) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
x.OptionOne = value.Interface().(string)
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
x.OptionTwo = value.Interface().(string)
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
x.OptionThree = value.Interface().(string)
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
x.OptionFour = value.Interface().(string)
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
x.OptionSpam = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_ProposalVoteOptions) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
panic(fmt.Errorf("field option_one of message cosmos.gov.v1.ProposalVoteOptions is not mutable"))
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
panic(fmt.Errorf("field option_two of message cosmos.gov.v1.ProposalVoteOptions is not mutable"))
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
panic(fmt.Errorf("field option_three of message cosmos.gov.v1.ProposalVoteOptions is not mutable"))
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
panic(fmt.Errorf("field option_four of message cosmos.gov.v1.ProposalVoteOptions is not mutable"))
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
panic(fmt.Errorf("field option_spam of message cosmos.gov.v1.ProposalVoteOptions is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_ProposalVoteOptions) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.ProposalVoteOptions.option_one":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.ProposalVoteOptions.option_two":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.ProposalVoteOptions.option_three":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.ProposalVoteOptions.option_four":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.ProposalVoteOptions.option_spam":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.ProposalVoteOptions"))
}
panic(fmt.Errorf("message cosmos.gov.v1.ProposalVoteOptions does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_ProposalVoteOptions) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.ProposalVoteOptions", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_ProposalVoteOptions) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_ProposalVoteOptions) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_ProposalVoteOptions) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_ProposalVoteOptions) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*ProposalVoteOptions)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
l = len(x.OptionOne)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionTwo)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionThree)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionFour)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionSpam)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*ProposalVoteOptions)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.OptionSpam) > 0 {
i -= len(x.OptionSpam)
copy(dAtA[i:], x.OptionSpam)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionSpam)))
i--
dAtA[i] = 0x2a
}
if len(x.OptionFour) > 0 {
i -= len(x.OptionFour)
copy(dAtA[i:], x.OptionFour)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionFour)))
i--
dAtA[i] = 0x22
}
if len(x.OptionThree) > 0 {
i -= len(x.OptionThree)
copy(dAtA[i:], x.OptionThree)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionThree)))
i--
dAtA[i] = 0x1a
}
if len(x.OptionTwo) > 0 {
i -= len(x.OptionTwo)
copy(dAtA[i:], x.OptionTwo)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionTwo)))
i--
dAtA[i] = 0x12
}
if len(x.OptionOne) > 0 {
i -= len(x.OptionOne)
copy(dAtA[i:], x.OptionOne)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionOne)))
i--
dAtA[i] = 0xa
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*ProposalVoteOptions)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalVoteOptions: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: ProposalVoteOptions: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionOne", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionOne = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionTwo", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionTwo = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionThree", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionThree = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionFour", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionFour = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionSpam", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionSpam = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var (
md_TallyResult protoreflect.MessageDescriptor
fd_TallyResult_yes_count protoreflect.FieldDescriptor
fd_TallyResult_abstain_count protoreflect.FieldDescriptor
fd_TallyResult_no_count protoreflect.FieldDescriptor
fd_TallyResult_no_with_veto_count protoreflect.FieldDescriptor
fd_TallyResult_option_one_count protoreflect.FieldDescriptor
fd_TallyResult_option_two_count protoreflect.FieldDescriptor
fd_TallyResult_option_three_count protoreflect.FieldDescriptor
fd_TallyResult_option_four_count protoreflect.FieldDescriptor
fd_TallyResult_spam_count protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_TallyResult = File_cosmos_gov_v1_gov_proto.Messages().ByName("TallyResult")
fd_TallyResult_yes_count = md_TallyResult.Fields().ByName("yes_count")
fd_TallyResult_abstain_count = md_TallyResult.Fields().ByName("abstain_count")
fd_TallyResult_no_count = md_TallyResult.Fields().ByName("no_count")
fd_TallyResult_no_with_veto_count = md_TallyResult.Fields().ByName("no_with_veto_count")
fd_TallyResult_option_one_count = md_TallyResult.Fields().ByName("option_one_count")
fd_TallyResult_option_two_count = md_TallyResult.Fields().ByName("option_two_count")
fd_TallyResult_option_three_count = md_TallyResult.Fields().ByName("option_three_count")
fd_TallyResult_option_four_count = md_TallyResult.Fields().ByName("option_four_count")
fd_TallyResult_spam_count = md_TallyResult.Fields().ByName("spam_count")
}
var _ protoreflect.Message = (*fastReflection_TallyResult)(nil)
type fastReflection_TallyResult TallyResult
func (x *TallyResult) ProtoReflect() protoreflect.Message {
return (*fastReflection_TallyResult)(x)
}
func (x *TallyResult) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_TallyResult_messageType fastReflection_TallyResult_messageType
var _ protoreflect.MessageType = fastReflection_TallyResult_messageType{}
type fastReflection_TallyResult_messageType struct{}
func (x fastReflection_TallyResult_messageType) Zero() protoreflect.Message {
return (*fastReflection_TallyResult)(nil)
}
func (x fastReflection_TallyResult_messageType) New() protoreflect.Message {
return new(fastReflection_TallyResult)
}
func (x fastReflection_TallyResult_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_TallyResult
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_TallyResult) Descriptor() protoreflect.MessageDescriptor {
return md_TallyResult
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_TallyResult) Type() protoreflect.MessageType {
return _fastReflection_TallyResult_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_TallyResult) New() protoreflect.Message {
return new(fastReflection_TallyResult)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_TallyResult) Interface() protoreflect.ProtoMessage {
return (*TallyResult)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_TallyResult) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.YesCount != "" {
value := protoreflect.ValueOfString(x.YesCount)
if !f(fd_TallyResult_yes_count, value) {
return
}
}
if x.AbstainCount != "" {
value := protoreflect.ValueOfString(x.AbstainCount)
if !f(fd_TallyResult_abstain_count, value) {
return
}
}
if x.NoCount != "" {
value := protoreflect.ValueOfString(x.NoCount)
if !f(fd_TallyResult_no_count, value) {
return
}
}
if x.NoWithVetoCount != "" {
value := protoreflect.ValueOfString(x.NoWithVetoCount)
if !f(fd_TallyResult_no_with_veto_count, value) {
return
}
}
if x.OptionOneCount != "" {
value := protoreflect.ValueOfString(x.OptionOneCount)
if !f(fd_TallyResult_option_one_count, value) {
return
}
}
if x.OptionTwoCount != "" {
value := protoreflect.ValueOfString(x.OptionTwoCount)
if !f(fd_TallyResult_option_two_count, value) {
return
}
}
if x.OptionThreeCount != "" {
value := protoreflect.ValueOfString(x.OptionThreeCount)
if !f(fd_TallyResult_option_three_count, value) {
return
}
}
if x.OptionFourCount != "" {
value := protoreflect.ValueOfString(x.OptionFourCount)
if !f(fd_TallyResult_option_four_count, value) {
return
}
}
if x.SpamCount != "" {
value := protoreflect.ValueOfString(x.SpamCount)
if !f(fd_TallyResult_spam_count, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_TallyResult) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
return x.YesCount != ""
case "cosmos.gov.v1.TallyResult.abstain_count":
return x.AbstainCount != ""
case "cosmos.gov.v1.TallyResult.no_count":
return x.NoCount != ""
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
return x.NoWithVetoCount != ""
case "cosmos.gov.v1.TallyResult.option_one_count":
return x.OptionOneCount != ""
case "cosmos.gov.v1.TallyResult.option_two_count":
return x.OptionTwoCount != ""
case "cosmos.gov.v1.TallyResult.option_three_count":
return x.OptionThreeCount != ""
case "cosmos.gov.v1.TallyResult.option_four_count":
return x.OptionFourCount != ""
case "cosmos.gov.v1.TallyResult.spam_count":
return x.SpamCount != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyResult) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
x.YesCount = ""
case "cosmos.gov.v1.TallyResult.abstain_count":
x.AbstainCount = ""
case "cosmos.gov.v1.TallyResult.no_count":
x.NoCount = ""
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
x.NoWithVetoCount = ""
case "cosmos.gov.v1.TallyResult.option_one_count":
x.OptionOneCount = ""
case "cosmos.gov.v1.TallyResult.option_two_count":
x.OptionTwoCount = ""
case "cosmos.gov.v1.TallyResult.option_three_count":
x.OptionThreeCount = ""
case "cosmos.gov.v1.TallyResult.option_four_count":
x.OptionFourCount = ""
case "cosmos.gov.v1.TallyResult.spam_count":
x.SpamCount = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_TallyResult) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
value := x.YesCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.abstain_count":
value := x.AbstainCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.no_count":
value := x.NoCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
value := x.NoWithVetoCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.option_one_count":
value := x.OptionOneCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.option_two_count":
value := x.OptionTwoCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.option_three_count":
value := x.OptionThreeCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.option_four_count":
value := x.OptionFourCount
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyResult.spam_count":
value := x.SpamCount
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyResult) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
x.YesCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.abstain_count":
x.AbstainCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.no_count":
x.NoCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
x.NoWithVetoCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.option_one_count":
x.OptionOneCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.option_two_count":
x.OptionTwoCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.option_three_count":
x.OptionThreeCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.option_four_count":
x.OptionFourCount = value.Interface().(string)
case "cosmos.gov.v1.TallyResult.spam_count":
x.SpamCount = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyResult) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
panic(fmt.Errorf("field yes_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.abstain_count":
panic(fmt.Errorf("field abstain_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.no_count":
panic(fmt.Errorf("field no_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
panic(fmt.Errorf("field no_with_veto_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.option_one_count":
panic(fmt.Errorf("field option_one_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.option_two_count":
panic(fmt.Errorf("field option_two_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.option_three_count":
panic(fmt.Errorf("field option_three_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.option_four_count":
panic(fmt.Errorf("field option_four_count of message cosmos.gov.v1.TallyResult is not mutable"))
case "cosmos.gov.v1.TallyResult.spam_count":
panic(fmt.Errorf("field spam_count of message cosmos.gov.v1.TallyResult is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_TallyResult) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.TallyResult.yes_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.abstain_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.no_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.no_with_veto_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.option_one_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.option_two_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.option_three_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.option_four_count":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyResult.spam_count":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyResult"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyResult does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_TallyResult) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.TallyResult", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_TallyResult) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyResult) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_TallyResult) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_TallyResult) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*TallyResult)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
l = len(x.YesCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.AbstainCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.NoCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.NoWithVetoCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionOneCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionTwoCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionThreeCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.OptionFourCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.SpamCount)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*TallyResult)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.SpamCount) > 0 {
i -= len(x.SpamCount)
copy(dAtA[i:], x.SpamCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.SpamCount)))
i--
dAtA[i] = 0x4a
}
if len(x.OptionFourCount) > 0 {
i -= len(x.OptionFourCount)
copy(dAtA[i:], x.OptionFourCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionFourCount)))
i--
dAtA[i] = 0x42
}
if len(x.OptionThreeCount) > 0 {
i -= len(x.OptionThreeCount)
copy(dAtA[i:], x.OptionThreeCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionThreeCount)))
i--
dAtA[i] = 0x3a
}
if len(x.OptionTwoCount) > 0 {
i -= len(x.OptionTwoCount)
copy(dAtA[i:], x.OptionTwoCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionTwoCount)))
i--
dAtA[i] = 0x32
}
if len(x.OptionOneCount) > 0 {
i -= len(x.OptionOneCount)
copy(dAtA[i:], x.OptionOneCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptionOneCount)))
i--
dAtA[i] = 0x2a
}
if len(x.NoWithVetoCount) > 0 {
i -= len(x.NoWithVetoCount)
copy(dAtA[i:], x.NoWithVetoCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.NoWithVetoCount)))
i--
dAtA[i] = 0x22
}
if len(x.NoCount) > 0 {
i -= len(x.NoCount)
copy(dAtA[i:], x.NoCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.NoCount)))
i--
dAtA[i] = 0x1a
}
if len(x.AbstainCount) > 0 {
i -= len(x.AbstainCount)
copy(dAtA[i:], x.AbstainCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.AbstainCount)))
i--
dAtA[i] = 0x12
}
if len(x.YesCount) > 0 {
i -= len(x.YesCount)
copy(dAtA[i:], x.YesCount)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.YesCount)))
i--
dAtA[i] = 0xa
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*TallyResult)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: TallyResult: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: TallyResult: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field YesCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.YesCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field AbstainCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.AbstainCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field NoCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.NoCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field NoWithVetoCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.NoWithVetoCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionOneCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionOneCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 6:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionTwoCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionTwoCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 7:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionThreeCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionThreeCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 8:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptionFourCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptionFourCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 9:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field SpamCount", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.SpamCount = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var _ protoreflect.List = (*_Vote_4_list)(nil)
type _Vote_4_list struct {
list *[]*WeightedVoteOption
}
func (x *_Vote_4_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Vote_4_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Vote_4_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*WeightedVoteOption)
(*x.list)[i] = concreteValue
}
func (x *_Vote_4_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*WeightedVoteOption)
*x.list = append(*x.list, concreteValue)
}
func (x *_Vote_4_list) AppendMutable() protoreflect.Value {
v := new(WeightedVoteOption)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Vote_4_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Vote_4_list) NewElement() protoreflect.Value {
v := new(WeightedVoteOption)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Vote_4_list) IsValid() bool {
return x.list != nil
}
var (
md_Vote protoreflect.MessageDescriptor
fd_Vote_proposal_id protoreflect.FieldDescriptor
fd_Vote_voter protoreflect.FieldDescriptor
fd_Vote_options protoreflect.FieldDescriptor
fd_Vote_metadata protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_Vote = File_cosmos_gov_v1_gov_proto.Messages().ByName("Vote")
fd_Vote_proposal_id = md_Vote.Fields().ByName("proposal_id")
fd_Vote_voter = md_Vote.Fields().ByName("voter")
fd_Vote_options = md_Vote.Fields().ByName("options")
fd_Vote_metadata = md_Vote.Fields().ByName("metadata")
}
var _ protoreflect.Message = (*fastReflection_Vote)(nil)
type fastReflection_Vote Vote
func (x *Vote) ProtoReflect() protoreflect.Message {
return (*fastReflection_Vote)(x)
}
func (x *Vote) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_Vote_messageType fastReflection_Vote_messageType
var _ protoreflect.MessageType = fastReflection_Vote_messageType{}
type fastReflection_Vote_messageType struct{}
func (x fastReflection_Vote_messageType) Zero() protoreflect.Message {
return (*fastReflection_Vote)(nil)
}
func (x fastReflection_Vote_messageType) New() protoreflect.Message {
return new(fastReflection_Vote)
}
func (x fastReflection_Vote_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_Vote
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_Vote) Descriptor() protoreflect.MessageDescriptor {
return md_Vote
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_Vote) Type() protoreflect.MessageType {
return _fastReflection_Vote_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_Vote) New() protoreflect.Message {
return new(fastReflection_Vote)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_Vote) Interface() protoreflect.ProtoMessage {
return (*Vote)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_Vote) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.ProposalId != uint64(0) {
value := protoreflect.ValueOfUint64(x.ProposalId)
if !f(fd_Vote_proposal_id, value) {
return
}
}
if x.Voter != "" {
value := protoreflect.ValueOfString(x.Voter)
if !f(fd_Vote_voter, value) {
return
}
}
if len(x.Options) != 0 {
value := protoreflect.ValueOfList(&_Vote_4_list{list: &x.Options})
if !f(fd_Vote_options, value) {
return
}
}
if x.Metadata != "" {
value := protoreflect.ValueOfString(x.Metadata)
if !f(fd_Vote_metadata, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_Vote) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.Vote.proposal_id":
return x.ProposalId != uint64(0)
case "cosmos.gov.v1.Vote.voter":
return x.Voter != ""
case "cosmos.gov.v1.Vote.options":
return len(x.Options) != 0
case "cosmos.gov.v1.Vote.metadata":
return x.Metadata != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Vote) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.Vote.proposal_id":
x.ProposalId = uint64(0)
case "cosmos.gov.v1.Vote.voter":
x.Voter = ""
case "cosmos.gov.v1.Vote.options":
x.Options = nil
case "cosmos.gov.v1.Vote.metadata":
x.Metadata = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_Vote) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.Vote.proposal_id":
value := x.ProposalId
return protoreflect.ValueOfUint64(value)
case "cosmos.gov.v1.Vote.voter":
value := x.Voter
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Vote.options":
if len(x.Options) == 0 {
return protoreflect.ValueOfList(&_Vote_4_list{})
}
listValue := &_Vote_4_list{list: &x.Options}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Vote.metadata":
value := x.Metadata
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Vote) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.Vote.proposal_id":
x.ProposalId = value.Uint()
case "cosmos.gov.v1.Vote.voter":
x.Voter = value.Interface().(string)
case "cosmos.gov.v1.Vote.options":
lv := value.List()
clv := lv.(*_Vote_4_list)
x.Options = *clv.list
case "cosmos.gov.v1.Vote.metadata":
x.Metadata = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Vote) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Vote.options":
if x.Options == nil {
x.Options = []*WeightedVoteOption{}
}
value := &_Vote_4_list{list: &x.Options}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Vote.proposal_id":
panic(fmt.Errorf("field proposal_id of message cosmos.gov.v1.Vote is not mutable"))
case "cosmos.gov.v1.Vote.voter":
panic(fmt.Errorf("field voter of message cosmos.gov.v1.Vote is not mutable"))
case "cosmos.gov.v1.Vote.metadata":
panic(fmt.Errorf("field metadata of message cosmos.gov.v1.Vote is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_Vote) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Vote.proposal_id":
return protoreflect.ValueOfUint64(uint64(0))
case "cosmos.gov.v1.Vote.voter":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Vote.options":
list := []*WeightedVoteOption{}
return protoreflect.ValueOfList(&_Vote_4_list{list: &list})
case "cosmos.gov.v1.Vote.metadata":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Vote"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Vote does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_Vote) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.Vote", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_Vote) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Vote) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_Vote) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*Vote)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.ProposalId != 0 {
n += 1 + runtime.Sov(uint64(x.ProposalId))
}
l = len(x.Voter)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if len(x.Options) > 0 {
for _, e := range x.Options {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
l = len(x.Metadata)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*Vote)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.Metadata) > 0 {
i -= len(x.Metadata)
copy(dAtA[i:], x.Metadata)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Metadata)))
i--
dAtA[i] = 0x2a
}
if len(x.Options) > 0 {
for iNdEx := len(x.Options) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.Options[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x22
}
}
if len(x.Voter) > 0 {
i -= len(x.Voter)
copy(dAtA[i:], x.Voter)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Voter)))
i--
dAtA[i] = 0x12
}
if x.ProposalId != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.ProposalId))
i--
dAtA[i] = 0x8
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*Vote)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Vote: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Vote: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalId", wireType)
}
x.ProposalId = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.ProposalId |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Voter", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Voter = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Options", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Options = append(x.Options, &WeightedVoteOption{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.Options[len(x.Options)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Metadata = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var _ protoreflect.List = (*_DepositParams_1_list)(nil)
type _DepositParams_1_list struct {
list *[]*v1beta1.Coin
}
func (x *_DepositParams_1_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_DepositParams_1_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_DepositParams_1_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
(*x.list)[i] = concreteValue
}
func (x *_DepositParams_1_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
*x.list = append(*x.list, concreteValue)
}
func (x *_DepositParams_1_list) AppendMutable() protoreflect.Value {
v := new(v1beta1.Coin)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_DepositParams_1_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_DepositParams_1_list) NewElement() protoreflect.Value {
v := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_DepositParams_1_list) IsValid() bool {
return x.list != nil
}
var (
md_DepositParams protoreflect.MessageDescriptor
fd_DepositParams_min_deposit protoreflect.FieldDescriptor
fd_DepositParams_max_deposit_period protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_DepositParams = File_cosmos_gov_v1_gov_proto.Messages().ByName("DepositParams")
fd_DepositParams_min_deposit = md_DepositParams.Fields().ByName("min_deposit")
fd_DepositParams_max_deposit_period = md_DepositParams.Fields().ByName("max_deposit_period")
}
var _ protoreflect.Message = (*fastReflection_DepositParams)(nil)
type fastReflection_DepositParams DepositParams
func (x *DepositParams) ProtoReflect() protoreflect.Message {
return (*fastReflection_DepositParams)(x)
}
func (x *DepositParams) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_DepositParams_messageType fastReflection_DepositParams_messageType
var _ protoreflect.MessageType = fastReflection_DepositParams_messageType{}
type fastReflection_DepositParams_messageType struct{}
func (x fastReflection_DepositParams_messageType) Zero() protoreflect.Message {
return (*fastReflection_DepositParams)(nil)
}
func (x fastReflection_DepositParams_messageType) New() protoreflect.Message {
return new(fastReflection_DepositParams)
}
func (x fastReflection_DepositParams_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_DepositParams
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_DepositParams) Descriptor() protoreflect.MessageDescriptor {
return md_DepositParams
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_DepositParams) Type() protoreflect.MessageType {
return _fastReflection_DepositParams_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_DepositParams) New() protoreflect.Message {
return new(fastReflection_DepositParams)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_DepositParams) Interface() protoreflect.ProtoMessage {
return (*DepositParams)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_DepositParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if len(x.MinDeposit) != 0 {
value := protoreflect.ValueOfList(&_DepositParams_1_list{list: &x.MinDeposit})
if !f(fd_DepositParams_min_deposit, value) {
return
}
}
if x.MaxDepositPeriod != nil {
value := protoreflect.ValueOfMessage(x.MaxDepositPeriod.ProtoReflect())
if !f(fd_DepositParams_max_deposit_period, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_DepositParams) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
return len(x.MinDeposit) != 0
case "cosmos.gov.v1.DepositParams.max_deposit_period":
return x.MaxDepositPeriod != nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_DepositParams) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
x.MinDeposit = nil
case "cosmos.gov.v1.DepositParams.max_deposit_period":
x.MaxDepositPeriod = nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_DepositParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
if len(x.MinDeposit) == 0 {
return protoreflect.ValueOfList(&_DepositParams_1_list{})
}
listValue := &_DepositParams_1_list{list: &x.MinDeposit}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.DepositParams.max_deposit_period":
value := x.MaxDepositPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_DepositParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
lv := value.List()
clv := lv.(*_DepositParams_1_list)
x.MinDeposit = *clv.list
case "cosmos.gov.v1.DepositParams.max_deposit_period":
x.MaxDepositPeriod = value.Message().Interface().(*durationpb.Duration)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_DepositParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
if x.MinDeposit == nil {
x.MinDeposit = []*v1beta1.Coin{}
}
value := &_DepositParams_1_list{list: &x.MinDeposit}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.DepositParams.max_deposit_period":
if x.MaxDepositPeriod == nil {
x.MaxDepositPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.MaxDepositPeriod.ProtoReflect())
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_DepositParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.DepositParams.min_deposit":
list := []*v1beta1.Coin{}
return protoreflect.ValueOfList(&_DepositParams_1_list{list: &list})
case "cosmos.gov.v1.DepositParams.max_deposit_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.DepositParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.DepositParams does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_DepositParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.DepositParams", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_DepositParams) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_DepositParams) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_DepositParams) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_DepositParams) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*DepositParams)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if len(x.MinDeposit) > 0 {
for _, e := range x.MinDeposit {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.MaxDepositPeriod != nil {
l = options.Size(x.MaxDepositPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*DepositParams)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if x.MaxDepositPeriod != nil {
encoded, err := options.Marshal(x.MaxDepositPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x12
}
if len(x.MinDeposit) > 0 {
for iNdEx := len(x.MinDeposit) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.MinDeposit[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0xa
}
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*DepositParams)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositParams: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: DepositParams: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinDeposit", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.MinDeposit = append(x.MinDeposit, &v1beta1.Coin{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MinDeposit[len(x.MinDeposit)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxDepositPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.MaxDepositPeriod == nil {
x.MaxDepositPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MaxDepositPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var (
md_VotingParams protoreflect.MessageDescriptor
fd_VotingParams_voting_period protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_VotingParams = File_cosmos_gov_v1_gov_proto.Messages().ByName("VotingParams")
fd_VotingParams_voting_period = md_VotingParams.Fields().ByName("voting_period")
}
var _ protoreflect.Message = (*fastReflection_VotingParams)(nil)
type fastReflection_VotingParams VotingParams
func (x *VotingParams) ProtoReflect() protoreflect.Message {
return (*fastReflection_VotingParams)(x)
}
func (x *VotingParams) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_VotingParams_messageType fastReflection_VotingParams_messageType
var _ protoreflect.MessageType = fastReflection_VotingParams_messageType{}
type fastReflection_VotingParams_messageType struct{}
func (x fastReflection_VotingParams_messageType) Zero() protoreflect.Message {
return (*fastReflection_VotingParams)(nil)
}
func (x fastReflection_VotingParams_messageType) New() protoreflect.Message {
return new(fastReflection_VotingParams)
}
func (x fastReflection_VotingParams_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_VotingParams
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_VotingParams) Descriptor() protoreflect.MessageDescriptor {
return md_VotingParams
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_VotingParams) Type() protoreflect.MessageType {
return _fastReflection_VotingParams_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_VotingParams) New() protoreflect.Message {
return new(fastReflection_VotingParams)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_VotingParams) Interface() protoreflect.ProtoMessage {
return (*VotingParams)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_VotingParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.VotingPeriod != nil {
value := protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
if !f(fd_VotingParams_voting_period, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_VotingParams) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
return x.VotingPeriod != nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_VotingParams) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
x.VotingPeriod = nil
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_VotingParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
value := x.VotingPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_VotingParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
x.VotingPeriod = value.Message().Interface().(*durationpb.Duration)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_VotingParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
if x.VotingPeriod == nil {
x.VotingPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_VotingParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.VotingParams.voting_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.VotingParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.VotingParams does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_VotingParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.VotingParams", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_VotingParams) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_VotingParams) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_VotingParams) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_VotingParams) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*VotingParams)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.VotingPeriod != nil {
l = options.Size(x.VotingPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*VotingParams)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if x.VotingPeriod != nil {
encoded, err := options.Marshal(x.VotingPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0xa
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*VotingParams)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: VotingParams: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: VotingParams: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.VotingPeriod == nil {
x.VotingPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.VotingPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var (
md_TallyParams protoreflect.MessageDescriptor
fd_TallyParams_quorum protoreflect.FieldDescriptor
fd_TallyParams_threshold protoreflect.FieldDescriptor
fd_TallyParams_veto_threshold protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_TallyParams = File_cosmos_gov_v1_gov_proto.Messages().ByName("TallyParams")
fd_TallyParams_quorum = md_TallyParams.Fields().ByName("quorum")
fd_TallyParams_threshold = md_TallyParams.Fields().ByName("threshold")
fd_TallyParams_veto_threshold = md_TallyParams.Fields().ByName("veto_threshold")
}
var _ protoreflect.Message = (*fastReflection_TallyParams)(nil)
type fastReflection_TallyParams TallyParams
func (x *TallyParams) ProtoReflect() protoreflect.Message {
return (*fastReflection_TallyParams)(x)
}
func (x *TallyParams) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[8]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_TallyParams_messageType fastReflection_TallyParams_messageType
var _ protoreflect.MessageType = fastReflection_TallyParams_messageType{}
type fastReflection_TallyParams_messageType struct{}
func (x fastReflection_TallyParams_messageType) Zero() protoreflect.Message {
return (*fastReflection_TallyParams)(nil)
}
func (x fastReflection_TallyParams_messageType) New() protoreflect.Message {
return new(fastReflection_TallyParams)
}
func (x fastReflection_TallyParams_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_TallyParams
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_TallyParams) Descriptor() protoreflect.MessageDescriptor {
return md_TallyParams
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_TallyParams) Type() protoreflect.MessageType {
return _fastReflection_TallyParams_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_TallyParams) New() protoreflect.Message {
return new(fastReflection_TallyParams)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_TallyParams) Interface() protoreflect.ProtoMessage {
return (*TallyParams)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_TallyParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.Quorum != "" {
value := protoreflect.ValueOfString(x.Quorum)
if !f(fd_TallyParams_quorum, value) {
return
}
}
if x.Threshold != "" {
value := protoreflect.ValueOfString(x.Threshold)
if !f(fd_TallyParams_threshold, value) {
return
}
}
if x.VetoThreshold != "" {
value := protoreflect.ValueOfString(x.VetoThreshold)
if !f(fd_TallyParams_veto_threshold, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_TallyParams) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
return x.Quorum != ""
case "cosmos.gov.v1.TallyParams.threshold":
return x.Threshold != ""
case "cosmos.gov.v1.TallyParams.veto_threshold":
return x.VetoThreshold != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyParams) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
x.Quorum = ""
case "cosmos.gov.v1.TallyParams.threshold":
x.Threshold = ""
case "cosmos.gov.v1.TallyParams.veto_threshold":
x.VetoThreshold = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_TallyParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
value := x.Quorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyParams.threshold":
value := x.Threshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.TallyParams.veto_threshold":
value := x.VetoThreshold
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
x.Quorum = value.Interface().(string)
case "cosmos.gov.v1.TallyParams.threshold":
x.Threshold = value.Interface().(string)
case "cosmos.gov.v1.TallyParams.veto_threshold":
x.VetoThreshold = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
panic(fmt.Errorf("field quorum of message cosmos.gov.v1.TallyParams is not mutable"))
case "cosmos.gov.v1.TallyParams.threshold":
panic(fmt.Errorf("field threshold of message cosmos.gov.v1.TallyParams is not mutable"))
case "cosmos.gov.v1.TallyParams.veto_threshold":
panic(fmt.Errorf("field veto_threshold of message cosmos.gov.v1.TallyParams is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_TallyParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.TallyParams.quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyParams.threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.TallyParams.veto_threshold":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.TallyParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.TallyParams does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_TallyParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.TallyParams", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_TallyParams) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_TallyParams) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_TallyParams) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_TallyParams) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*TallyParams)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
l = len(x.Quorum)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Threshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.VetoThreshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*TallyParams)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.VetoThreshold) > 0 {
i -= len(x.VetoThreshold)
copy(dAtA[i:], x.VetoThreshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.VetoThreshold)))
i--
dAtA[i] = 0x1a
}
if len(x.Threshold) > 0 {
i -= len(x.Threshold)
copy(dAtA[i:], x.Threshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Threshold)))
i--
dAtA[i] = 0x12
}
if len(x.Quorum) > 0 {
i -= len(x.Quorum)
copy(dAtA[i:], x.Quorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Quorum)))
i--
dAtA[i] = 0xa
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*TallyParams)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: TallyParams: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: TallyParams: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Quorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Quorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Threshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Threshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VetoThreshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.VetoThreshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var _ protoreflect.List = (*_Params_1_list)(nil)
type _Params_1_list struct {
list *[]*v1beta1.Coin
}
func (x *_Params_1_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Params_1_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Params_1_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
(*x.list)[i] = concreteValue
}
func (x *_Params_1_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
*x.list = append(*x.list, concreteValue)
}
func (x *_Params_1_list) AppendMutable() protoreflect.Value {
v := new(v1beta1.Coin)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Params_1_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Params_1_list) NewElement() protoreflect.Value {
v := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Params_1_list) IsValid() bool {
return x.list != nil
}
var _ protoreflect.List = (*_Params_12_list)(nil)
type _Params_12_list struct {
list *[]*v1beta1.Coin
}
func (x *_Params_12_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Params_12_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect())
}
func (x *_Params_12_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
(*x.list)[i] = concreteValue
}
func (x *_Params_12_list) Append(value protoreflect.Value) {
valueUnwrapped := value.Message()
concreteValue := valueUnwrapped.Interface().(*v1beta1.Coin)
*x.list = append(*x.list, concreteValue)
}
func (x *_Params_12_list) AppendMutable() protoreflect.Value {
v := new(v1beta1.Coin)
*x.list = append(*x.list, v)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Params_12_list) Truncate(n int) {
for i := n; i < len(*x.list); i++ {
(*x.list)[i] = nil
}
*x.list = (*x.list)[:n]
}
func (x *_Params_12_list) NewElement() protoreflect.Value {
v := new(v1beta1.Coin)
return protoreflect.ValueOfMessage(v.ProtoReflect())
}
func (x *_Params_12_list) IsValid() bool {
return x.list != nil
}
var _ protoreflect.List = (*_Params_18_list)(nil)
type _Params_18_list struct {
list *[]string
}
func (x *_Params_18_list) Len() int {
if x.list == nil {
return 0
}
return len(*x.list)
}
func (x *_Params_18_list) Get(i int) protoreflect.Value {
return protoreflect.ValueOfString((*x.list)[i])
}
func (x *_Params_18_list) Set(i int, value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
(*x.list)[i] = concreteValue
}
func (x *_Params_18_list) Append(value protoreflect.Value) {
valueUnwrapped := value.String()
concreteValue := valueUnwrapped
*x.list = append(*x.list, concreteValue)
}
func (x *_Params_18_list) AppendMutable() protoreflect.Value {
panic(fmt.Errorf("AppendMutable can not be called on message Params at list field OptimisticAuthorizedAddresses as it is not of Message kind"))
}
func (x *_Params_18_list) Truncate(n int) {
*x.list = (*x.list)[:n]
}
func (x *_Params_18_list) NewElement() protoreflect.Value {
v := ""
return protoreflect.ValueOfString(v)
}
func (x *_Params_18_list) IsValid() bool {
return x.list != nil
}
var (
md_Params protoreflect.MessageDescriptor
fd_Params_min_deposit protoreflect.FieldDescriptor
fd_Params_max_deposit_period protoreflect.FieldDescriptor
fd_Params_voting_period protoreflect.FieldDescriptor
fd_Params_quorum protoreflect.FieldDescriptor
fd_Params_threshold protoreflect.FieldDescriptor
fd_Params_veto_threshold protoreflect.FieldDescriptor
fd_Params_min_initial_deposit_ratio protoreflect.FieldDescriptor
fd_Params_proposal_cancel_ratio protoreflect.FieldDescriptor
fd_Params_proposal_cancel_dest protoreflect.FieldDescriptor
fd_Params_expedited_voting_period protoreflect.FieldDescriptor
fd_Params_expedited_threshold protoreflect.FieldDescriptor
fd_Params_expedited_min_deposit protoreflect.FieldDescriptor
fd_Params_burn_vote_quorum protoreflect.FieldDescriptor
fd_Params_burn_proposal_deposit_prevote protoreflect.FieldDescriptor
fd_Params_burn_vote_veto protoreflect.FieldDescriptor
fd_Params_min_deposit_ratio protoreflect.FieldDescriptor
fd_Params_proposal_cancel_max_period protoreflect.FieldDescriptor
fd_Params_optimistic_authorized_addresses protoreflect.FieldDescriptor
fd_Params_optimistic_rejected_threshold protoreflect.FieldDescriptor
fd_Params_yes_quorum protoreflect.FieldDescriptor
fd_Params_expedited_quorum protoreflect.FieldDescriptor
fd_Params_proposal_execution_gas protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_Params = File_cosmos_gov_v1_gov_proto.Messages().ByName("Params")
fd_Params_min_deposit = md_Params.Fields().ByName("min_deposit")
fd_Params_max_deposit_period = md_Params.Fields().ByName("max_deposit_period")
fd_Params_voting_period = md_Params.Fields().ByName("voting_period")
fd_Params_quorum = md_Params.Fields().ByName("quorum")
fd_Params_threshold = md_Params.Fields().ByName("threshold")
fd_Params_veto_threshold = md_Params.Fields().ByName("veto_threshold")
fd_Params_min_initial_deposit_ratio = md_Params.Fields().ByName("min_initial_deposit_ratio")
fd_Params_proposal_cancel_ratio = md_Params.Fields().ByName("proposal_cancel_ratio")
fd_Params_proposal_cancel_dest = md_Params.Fields().ByName("proposal_cancel_dest")
fd_Params_expedited_voting_period = md_Params.Fields().ByName("expedited_voting_period")
fd_Params_expedited_threshold = md_Params.Fields().ByName("expedited_threshold")
fd_Params_expedited_min_deposit = md_Params.Fields().ByName("expedited_min_deposit")
fd_Params_burn_vote_quorum = md_Params.Fields().ByName("burn_vote_quorum")
fd_Params_burn_proposal_deposit_prevote = md_Params.Fields().ByName("burn_proposal_deposit_prevote")
fd_Params_burn_vote_veto = md_Params.Fields().ByName("burn_vote_veto")
fd_Params_min_deposit_ratio = md_Params.Fields().ByName("min_deposit_ratio")
fd_Params_proposal_cancel_max_period = md_Params.Fields().ByName("proposal_cancel_max_period")
fd_Params_optimistic_authorized_addresses = md_Params.Fields().ByName("optimistic_authorized_addresses")
fd_Params_optimistic_rejected_threshold = md_Params.Fields().ByName("optimistic_rejected_threshold")
fd_Params_yes_quorum = md_Params.Fields().ByName("yes_quorum")
fd_Params_expedited_quorum = md_Params.Fields().ByName("expedited_quorum")
fd_Params_proposal_execution_gas = md_Params.Fields().ByName("proposal_execution_gas")
}
var _ protoreflect.Message = (*fastReflection_Params)(nil)
type fastReflection_Params Params
func (x *Params) ProtoReflect() protoreflect.Message {
return (*fastReflection_Params)(x)
}
func (x *Params) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[9]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_Params_messageType fastReflection_Params_messageType
var _ protoreflect.MessageType = fastReflection_Params_messageType{}
type fastReflection_Params_messageType struct{}
func (x fastReflection_Params_messageType) Zero() protoreflect.Message {
return (*fastReflection_Params)(nil)
}
func (x fastReflection_Params_messageType) New() protoreflect.Message {
return new(fastReflection_Params)
}
func (x fastReflection_Params_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_Params
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_Params) Descriptor() protoreflect.MessageDescriptor {
return md_Params
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_Params) Type() protoreflect.MessageType {
return _fastReflection_Params_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_Params) New() protoreflect.Message {
return new(fastReflection_Params)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage {
return (*Params)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if len(x.MinDeposit) != 0 {
value := protoreflect.ValueOfList(&_Params_1_list{list: &x.MinDeposit})
if !f(fd_Params_min_deposit, value) {
return
}
}
if x.MaxDepositPeriod != nil {
value := protoreflect.ValueOfMessage(x.MaxDepositPeriod.ProtoReflect())
if !f(fd_Params_max_deposit_period, value) {
return
}
}
if x.VotingPeriod != nil {
value := protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
if !f(fd_Params_voting_period, value) {
return
}
}
if x.Quorum != "" {
value := protoreflect.ValueOfString(x.Quorum)
if !f(fd_Params_quorum, value) {
return
}
}
if x.Threshold != "" {
value := protoreflect.ValueOfString(x.Threshold)
if !f(fd_Params_threshold, value) {
return
}
}
if x.VetoThreshold != "" {
value := protoreflect.ValueOfString(x.VetoThreshold)
if !f(fd_Params_veto_threshold, value) {
return
}
}
if x.MinInitialDepositRatio != "" {
value := protoreflect.ValueOfString(x.MinInitialDepositRatio)
if !f(fd_Params_min_initial_deposit_ratio, value) {
return
}
}
if x.ProposalCancelRatio != "" {
value := protoreflect.ValueOfString(x.ProposalCancelRatio)
if !f(fd_Params_proposal_cancel_ratio, value) {
return
}
}
if x.ProposalCancelDest != "" {
value := protoreflect.ValueOfString(x.ProposalCancelDest)
if !f(fd_Params_proposal_cancel_dest, value) {
return
}
}
if x.ExpeditedVotingPeriod != nil {
value := protoreflect.ValueOfMessage(x.ExpeditedVotingPeriod.ProtoReflect())
if !f(fd_Params_expedited_voting_period, value) {
return
}
}
if x.ExpeditedThreshold != "" {
value := protoreflect.ValueOfString(x.ExpeditedThreshold)
if !f(fd_Params_expedited_threshold, value) {
return
}
}
if len(x.ExpeditedMinDeposit) != 0 {
value := protoreflect.ValueOfList(&_Params_12_list{list: &x.ExpeditedMinDeposit})
if !f(fd_Params_expedited_min_deposit, value) {
return
}
}
if x.BurnVoteQuorum != false {
value := protoreflect.ValueOfBool(x.BurnVoteQuorum)
if !f(fd_Params_burn_vote_quorum, value) {
return
}
}
if x.BurnProposalDepositPrevote != false {
value := protoreflect.ValueOfBool(x.BurnProposalDepositPrevote)
if !f(fd_Params_burn_proposal_deposit_prevote, value) {
return
}
}
if x.BurnVoteVeto != false {
value := protoreflect.ValueOfBool(x.BurnVoteVeto)
if !f(fd_Params_burn_vote_veto, value) {
return
}
}
if x.MinDepositRatio != "" {
value := protoreflect.ValueOfString(x.MinDepositRatio)
if !f(fd_Params_min_deposit_ratio, value) {
return
}
}
if x.ProposalCancelMaxPeriod != "" {
value := protoreflect.ValueOfString(x.ProposalCancelMaxPeriod)
if !f(fd_Params_proposal_cancel_max_period, value) {
return
}
}
if len(x.OptimisticAuthorizedAddresses) != 0 {
value := protoreflect.ValueOfList(&_Params_18_list{list: &x.OptimisticAuthorizedAddresses})
if !f(fd_Params_optimistic_authorized_addresses, value) {
return
}
}
if x.OptimisticRejectedThreshold != "" {
value := protoreflect.ValueOfString(x.OptimisticRejectedThreshold)
if !f(fd_Params_optimistic_rejected_threshold, value) {
return
}
}
if x.YesQuorum != "" {
value := protoreflect.ValueOfString(x.YesQuorum)
if !f(fd_Params_yes_quorum, value) {
return
}
}
if x.ExpeditedQuorum != "" {
value := protoreflect.ValueOfString(x.ExpeditedQuorum)
if !f(fd_Params_expedited_quorum, value) {
return
}
}
if x.ProposalExecutionGas != uint64(0) {
value := protoreflect.ValueOfUint64(x.ProposalExecutionGas)
if !f(fd_Params_proposal_execution_gas, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
return len(x.MinDeposit) != 0
case "cosmos.gov.v1.Params.max_deposit_period":
return x.MaxDepositPeriod != nil
case "cosmos.gov.v1.Params.voting_period":
return x.VotingPeriod != nil
case "cosmos.gov.v1.Params.quorum":
return x.Quorum != ""
case "cosmos.gov.v1.Params.threshold":
return x.Threshold != ""
case "cosmos.gov.v1.Params.veto_threshold":
return x.VetoThreshold != ""
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
return x.MinInitialDepositRatio != ""
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
return x.ProposalCancelRatio != ""
case "cosmos.gov.v1.Params.proposal_cancel_dest":
return x.ProposalCancelDest != ""
case "cosmos.gov.v1.Params.expedited_voting_period":
return x.ExpeditedVotingPeriod != nil
case "cosmos.gov.v1.Params.expedited_threshold":
return x.ExpeditedThreshold != ""
case "cosmos.gov.v1.Params.expedited_min_deposit":
return len(x.ExpeditedMinDeposit) != 0
case "cosmos.gov.v1.Params.burn_vote_quorum":
return x.BurnVoteQuorum != false
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
return x.BurnProposalDepositPrevote != false
case "cosmos.gov.v1.Params.burn_vote_veto":
return x.BurnVoteVeto != false
case "cosmos.gov.v1.Params.min_deposit_ratio":
return x.MinDepositRatio != ""
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
return x.ProposalCancelMaxPeriod != ""
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
return len(x.OptimisticAuthorizedAddresses) != 0
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
return x.OptimisticRejectedThreshold != ""
case "cosmos.gov.v1.Params.yes_quorum":
return x.YesQuorum != ""
case "cosmos.gov.v1.Params.expedited_quorum":
return x.ExpeditedQuorum != ""
case "cosmos.gov.v1.Params.proposal_execution_gas":
return x.ProposalExecutionGas != uint64(0)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
x.MinDeposit = nil
case "cosmos.gov.v1.Params.max_deposit_period":
x.MaxDepositPeriod = nil
case "cosmos.gov.v1.Params.voting_period":
x.VotingPeriod = nil
case "cosmos.gov.v1.Params.quorum":
x.Quorum = ""
case "cosmos.gov.v1.Params.threshold":
x.Threshold = ""
case "cosmos.gov.v1.Params.veto_threshold":
x.VetoThreshold = ""
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
x.MinInitialDepositRatio = ""
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
x.ProposalCancelRatio = ""
case "cosmos.gov.v1.Params.proposal_cancel_dest":
x.ProposalCancelDest = ""
case "cosmos.gov.v1.Params.expedited_voting_period":
x.ExpeditedVotingPeriod = nil
case "cosmos.gov.v1.Params.expedited_threshold":
x.ExpeditedThreshold = ""
case "cosmos.gov.v1.Params.expedited_min_deposit":
x.ExpeditedMinDeposit = nil
case "cosmos.gov.v1.Params.burn_vote_quorum":
x.BurnVoteQuorum = false
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
x.BurnProposalDepositPrevote = false
case "cosmos.gov.v1.Params.burn_vote_veto":
x.BurnVoteVeto = false
case "cosmos.gov.v1.Params.min_deposit_ratio":
x.MinDepositRatio = ""
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
x.ProposalCancelMaxPeriod = ""
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
x.OptimisticAuthorizedAddresses = nil
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
x.OptimisticRejectedThreshold = ""
case "cosmos.gov.v1.Params.yes_quorum":
x.YesQuorum = ""
case "cosmos.gov.v1.Params.expedited_quorum":
x.ExpeditedQuorum = ""
case "cosmos.gov.v1.Params.proposal_execution_gas":
x.ProposalExecutionGas = uint64(0)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
if len(x.MinDeposit) == 0 {
return protoreflect.ValueOfList(&_Params_1_list{})
}
listValue := &_Params_1_list{list: &x.MinDeposit}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Params.max_deposit_period":
value := x.MaxDepositPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Params.voting_period":
value := x.VotingPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Params.quorum":
value := x.Quorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.threshold":
value := x.Threshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.veto_threshold":
value := x.VetoThreshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
value := x.MinInitialDepositRatio
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
value := x.ProposalCancelRatio
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.proposal_cancel_dest":
value := x.ProposalCancelDest
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.expedited_voting_period":
value := x.ExpeditedVotingPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.Params.expedited_threshold":
value := x.ExpeditedThreshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.expedited_min_deposit":
if len(x.ExpeditedMinDeposit) == 0 {
return protoreflect.ValueOfList(&_Params_12_list{})
}
listValue := &_Params_12_list{list: &x.ExpeditedMinDeposit}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Params.burn_vote_quorum":
value := x.BurnVoteQuorum
return protoreflect.ValueOfBool(value)
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
value := x.BurnProposalDepositPrevote
return protoreflect.ValueOfBool(value)
case "cosmos.gov.v1.Params.burn_vote_veto":
value := x.BurnVoteVeto
return protoreflect.ValueOfBool(value)
case "cosmos.gov.v1.Params.min_deposit_ratio":
value := x.MinDepositRatio
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
value := x.ProposalCancelMaxPeriod
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
if len(x.OptimisticAuthorizedAddresses) == 0 {
return protoreflect.ValueOfList(&_Params_18_list{})
}
listValue := &_Params_18_list{list: &x.OptimisticAuthorizedAddresses}
return protoreflect.ValueOfList(listValue)
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
value := x.OptimisticRejectedThreshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.yes_quorum":
value := x.YesQuorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.expedited_quorum":
value := x.ExpeditedQuorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.Params.proposal_execution_gas":
value := x.ProposalExecutionGas
return protoreflect.ValueOfUint64(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
lv := value.List()
clv := lv.(*_Params_1_list)
x.MinDeposit = *clv.list
case "cosmos.gov.v1.Params.max_deposit_period":
x.MaxDepositPeriod = value.Message().Interface().(*durationpb.Duration)
case "cosmos.gov.v1.Params.voting_period":
x.VotingPeriod = value.Message().Interface().(*durationpb.Duration)
case "cosmos.gov.v1.Params.quorum":
x.Quorum = value.Interface().(string)
case "cosmos.gov.v1.Params.threshold":
x.Threshold = value.Interface().(string)
case "cosmos.gov.v1.Params.veto_threshold":
x.VetoThreshold = value.Interface().(string)
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
x.MinInitialDepositRatio = value.Interface().(string)
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
x.ProposalCancelRatio = value.Interface().(string)
case "cosmos.gov.v1.Params.proposal_cancel_dest":
x.ProposalCancelDest = value.Interface().(string)
case "cosmos.gov.v1.Params.expedited_voting_period":
x.ExpeditedVotingPeriod = value.Message().Interface().(*durationpb.Duration)
case "cosmos.gov.v1.Params.expedited_threshold":
x.ExpeditedThreshold = value.Interface().(string)
case "cosmos.gov.v1.Params.expedited_min_deposit":
lv := value.List()
clv := lv.(*_Params_12_list)
x.ExpeditedMinDeposit = *clv.list
case "cosmos.gov.v1.Params.burn_vote_quorum":
x.BurnVoteQuorum = value.Bool()
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
x.BurnProposalDepositPrevote = value.Bool()
case "cosmos.gov.v1.Params.burn_vote_veto":
x.BurnVoteVeto = value.Bool()
case "cosmos.gov.v1.Params.min_deposit_ratio":
x.MinDepositRatio = value.Interface().(string)
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
x.ProposalCancelMaxPeriod = value.Interface().(string)
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
lv := value.List()
clv := lv.(*_Params_18_list)
x.OptimisticAuthorizedAddresses = *clv.list
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
x.OptimisticRejectedThreshold = value.Interface().(string)
case "cosmos.gov.v1.Params.yes_quorum":
x.YesQuorum = value.Interface().(string)
case "cosmos.gov.v1.Params.expedited_quorum":
x.ExpeditedQuorum = value.Interface().(string)
case "cosmos.gov.v1.Params.proposal_execution_gas":
x.ProposalExecutionGas = value.Uint()
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
if x.MinDeposit == nil {
x.MinDeposit = []*v1beta1.Coin{}
}
value := &_Params_1_list{list: &x.MinDeposit}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Params.max_deposit_period":
if x.MaxDepositPeriod == nil {
x.MaxDepositPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.MaxDepositPeriod.ProtoReflect())
case "cosmos.gov.v1.Params.voting_period":
if x.VotingPeriod == nil {
x.VotingPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
case "cosmos.gov.v1.Params.expedited_voting_period":
if x.ExpeditedVotingPeriod == nil {
x.ExpeditedVotingPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.ExpeditedVotingPeriod.ProtoReflect())
case "cosmos.gov.v1.Params.expedited_min_deposit":
if x.ExpeditedMinDeposit == nil {
x.ExpeditedMinDeposit = []*v1beta1.Coin{}
}
value := &_Params_12_list{list: &x.ExpeditedMinDeposit}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
if x.OptimisticAuthorizedAddresses == nil {
x.OptimisticAuthorizedAddresses = []string{}
}
value := &_Params_18_list{list: &x.OptimisticAuthorizedAddresses}
return protoreflect.ValueOfList(value)
case "cosmos.gov.v1.Params.quorum":
panic(fmt.Errorf("field quorum of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.threshold":
panic(fmt.Errorf("field threshold of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.veto_threshold":
panic(fmt.Errorf("field veto_threshold of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
panic(fmt.Errorf("field min_initial_deposit_ratio of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
panic(fmt.Errorf("field proposal_cancel_ratio of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.proposal_cancel_dest":
panic(fmt.Errorf("field proposal_cancel_dest of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.expedited_threshold":
panic(fmt.Errorf("field expedited_threshold of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.burn_vote_quorum":
panic(fmt.Errorf("field burn_vote_quorum of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
panic(fmt.Errorf("field burn_proposal_deposit_prevote of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.burn_vote_veto":
panic(fmt.Errorf("field burn_vote_veto of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.min_deposit_ratio":
panic(fmt.Errorf("field min_deposit_ratio of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
panic(fmt.Errorf("field proposal_cancel_max_period of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
panic(fmt.Errorf("field optimistic_rejected_threshold of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.yes_quorum":
panic(fmt.Errorf("field yes_quorum of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.expedited_quorum":
panic(fmt.Errorf("field expedited_quorum of message cosmos.gov.v1.Params is not mutable"))
case "cosmos.gov.v1.Params.proposal_execution_gas":
panic(fmt.Errorf("field proposal_execution_gas of message cosmos.gov.v1.Params is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.Params.min_deposit":
list := []*v1beta1.Coin{}
return protoreflect.ValueOfList(&_Params_1_list{list: &list})
case "cosmos.gov.v1.Params.max_deposit_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Params.voting_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Params.quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.veto_threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.min_initial_deposit_ratio":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.proposal_cancel_ratio":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.proposal_cancel_dest":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.expedited_voting_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.Params.expedited_threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.expedited_min_deposit":
list := []*v1beta1.Coin{}
return protoreflect.ValueOfList(&_Params_12_list{list: &list})
case "cosmos.gov.v1.Params.burn_vote_quorum":
return protoreflect.ValueOfBool(false)
case "cosmos.gov.v1.Params.burn_proposal_deposit_prevote":
return protoreflect.ValueOfBool(false)
case "cosmos.gov.v1.Params.burn_vote_veto":
return protoreflect.ValueOfBool(false)
case "cosmos.gov.v1.Params.min_deposit_ratio":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.proposal_cancel_max_period":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.optimistic_authorized_addresses":
list := []string{}
return protoreflect.ValueOfList(&_Params_18_list{list: &list})
case "cosmos.gov.v1.Params.optimistic_rejected_threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.yes_quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.expedited_quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.Params.proposal_execution_gas":
return protoreflect.ValueOfUint64(uint64(0))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.Params"))
}
panic(fmt.Errorf("message cosmos.gov.v1.Params does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_Params) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.Params", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_Params) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_Params) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_Params) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*Params)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if len(x.MinDeposit) > 0 {
for _, e := range x.MinDeposit {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.MaxDepositPeriod != nil {
l = options.Size(x.MaxDepositPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
if x.VotingPeriod != nil {
l = options.Size(x.VotingPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Quorum)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Threshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.VetoThreshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.MinInitialDepositRatio)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.ProposalCancelRatio)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.ProposalCancelDest)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.ExpeditedVotingPeriod != nil {
l = options.Size(x.ExpeditedVotingPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.ExpeditedThreshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if len(x.ExpeditedMinDeposit) > 0 {
for _, e := range x.ExpeditedMinDeposit {
l = options.Size(e)
n += 1 + l + runtime.Sov(uint64(l))
}
}
if x.BurnVoteQuorum {
n += 2
}
if x.BurnProposalDepositPrevote {
n += 2
}
if x.BurnVoteVeto {
n += 2
}
l = len(x.MinDepositRatio)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
l = len(x.ProposalCancelMaxPeriod)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
if len(x.OptimisticAuthorizedAddresses) > 0 {
for _, s := range x.OptimisticAuthorizedAddresses {
l = len(s)
n += 2 + l + runtime.Sov(uint64(l))
}
}
l = len(x.OptimisticRejectedThreshold)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
l = len(x.YesQuorum)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
l = len(x.ExpeditedQuorum)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
if x.ProposalExecutionGas != 0 {
n += 2 + runtime.Sov(uint64(x.ProposalExecutionGas))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*Params)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if x.ProposalExecutionGas != 0 {
i = runtime.EncodeVarint(dAtA, i, uint64(x.ProposalExecutionGas))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0xb0
}
if len(x.ExpeditedQuorum) > 0 {
i -= len(x.ExpeditedQuorum)
copy(dAtA[i:], x.ExpeditedQuorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ExpeditedQuorum)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0xaa
}
if len(x.YesQuorum) > 0 {
i -= len(x.YesQuorum)
copy(dAtA[i:], x.YesQuorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.YesQuorum)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0xa2
}
if len(x.OptimisticRejectedThreshold) > 0 {
i -= len(x.OptimisticRejectedThreshold)
copy(dAtA[i:], x.OptimisticRejectedThreshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptimisticRejectedThreshold)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0x9a
}
if len(x.OptimisticAuthorizedAddresses) > 0 {
for iNdEx := len(x.OptimisticAuthorizedAddresses) - 1; iNdEx >= 0; iNdEx-- {
i -= len(x.OptimisticAuthorizedAddresses[iNdEx])
copy(dAtA[i:], x.OptimisticAuthorizedAddresses[iNdEx])
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OptimisticAuthorizedAddresses[iNdEx])))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0x92
}
}
if len(x.ProposalCancelMaxPeriod) > 0 {
i -= len(x.ProposalCancelMaxPeriod)
copy(dAtA[i:], x.ProposalCancelMaxPeriod)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposalCancelMaxPeriod)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0x8a
}
if len(x.MinDepositRatio) > 0 {
i -= len(x.MinDepositRatio)
copy(dAtA[i:], x.MinDepositRatio)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MinDepositRatio)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0x82
}
if x.BurnVoteVeto {
i--
if x.BurnVoteVeto {
dAtA[i] = 1
} else {
dAtA[i] = 0
}
i--
dAtA[i] = 0x78
}
if x.BurnProposalDepositPrevote {
i--
if x.BurnProposalDepositPrevote {
dAtA[i] = 1
} else {
dAtA[i] = 0
}
i--
dAtA[i] = 0x70
}
if x.BurnVoteQuorum {
i--
if x.BurnVoteQuorum {
dAtA[i] = 1
} else {
dAtA[i] = 0
}
i--
dAtA[i] = 0x68
}
if len(x.ExpeditedMinDeposit) > 0 {
for iNdEx := len(x.ExpeditedMinDeposit) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.ExpeditedMinDeposit[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x62
}
}
if len(x.ExpeditedThreshold) > 0 {
i -= len(x.ExpeditedThreshold)
copy(dAtA[i:], x.ExpeditedThreshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ExpeditedThreshold)))
i--
dAtA[i] = 0x5a
}
if x.ExpeditedVotingPeriod != nil {
encoded, err := options.Marshal(x.ExpeditedVotingPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x52
}
if len(x.ProposalCancelDest) > 0 {
i -= len(x.ProposalCancelDest)
copy(dAtA[i:], x.ProposalCancelDest)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposalCancelDest)))
i--
dAtA[i] = 0x4a
}
if len(x.ProposalCancelRatio) > 0 {
i -= len(x.ProposalCancelRatio)
copy(dAtA[i:], x.ProposalCancelRatio)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ProposalCancelRatio)))
i--
dAtA[i] = 0x42
}
if len(x.MinInitialDepositRatio) > 0 {
i -= len(x.MinInitialDepositRatio)
copy(dAtA[i:], x.MinInitialDepositRatio)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.MinInitialDepositRatio)))
i--
dAtA[i] = 0x3a
}
if len(x.VetoThreshold) > 0 {
i -= len(x.VetoThreshold)
copy(dAtA[i:], x.VetoThreshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.VetoThreshold)))
i--
dAtA[i] = 0x32
}
if len(x.Threshold) > 0 {
i -= len(x.Threshold)
copy(dAtA[i:], x.Threshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Threshold)))
i--
dAtA[i] = 0x2a
}
if len(x.Quorum) > 0 {
i -= len(x.Quorum)
copy(dAtA[i:], x.Quorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Quorum)))
i--
dAtA[i] = 0x22
}
if x.VotingPeriod != nil {
encoded, err := options.Marshal(x.VotingPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x1a
}
if x.MaxDepositPeriod != nil {
encoded, err := options.Marshal(x.MaxDepositPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0x12
}
if len(x.MinDeposit) > 0 {
for iNdEx := len(x.MinDeposit) - 1; iNdEx >= 0; iNdEx-- {
encoded, err := options.Marshal(x.MinDeposit[iNdEx])
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0xa
}
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*Params)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinDeposit", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.MinDeposit = append(x.MinDeposit, &v1beta1.Coin{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MinDeposit[len(x.MinDeposit)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MaxDepositPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.MaxDepositPeriod == nil {
x.MaxDepositPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.MaxDepositPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.VotingPeriod == nil {
x.VotingPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.VotingPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Quorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Quorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 5:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Threshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Threshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 6:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VetoThreshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.VetoThreshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 7:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinInitialDepositRatio", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.MinInitialDepositRatio = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 8:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalCancelRatio", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ProposalCancelRatio = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 9:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalCancelDest", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ProposalCancelDest = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 10:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExpeditedVotingPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.ExpeditedVotingPeriod == nil {
x.ExpeditedVotingPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ExpeditedVotingPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 11:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExpeditedThreshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ExpeditedThreshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 12:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExpeditedMinDeposit", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ExpeditedMinDeposit = append(x.ExpeditedMinDeposit, &v1beta1.Coin{})
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.ExpeditedMinDeposit[len(x.ExpeditedMinDeposit)-1]); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 13:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BurnVoteQuorum", wireType)
}
var v int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
v |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
x.BurnVoteQuorum = bool(v != 0)
case 14:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BurnProposalDepositPrevote", wireType)
}
var v int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
v |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
x.BurnProposalDepositPrevote = bool(v != 0)
case 15:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field BurnVoteVeto", wireType)
}
var v int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
v |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
x.BurnVoteVeto = bool(v != 0)
case 16:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field MinDepositRatio", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.MinDepositRatio = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 17:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalCancelMaxPeriod", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ProposalCancelMaxPeriod = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 18:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptimisticAuthorizedAddresses", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptimisticAuthorizedAddresses = append(x.OptimisticAuthorizedAddresses, string(dAtA[iNdEx:postIndex]))
iNdEx = postIndex
case 19:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OptimisticRejectedThreshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.OptimisticRejectedThreshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 20:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field YesQuorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.YesQuorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 21:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExpeditedQuorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.ExpeditedQuorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 22:
if wireType != 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ProposalExecutionGas", wireType)
}
x.ProposalExecutionGas = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
x.ProposalExecutionGas |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
var (
md_MessageBasedParams protoreflect.MessageDescriptor
fd_MessageBasedParams_voting_period protoreflect.FieldDescriptor
fd_MessageBasedParams_quorum protoreflect.FieldDescriptor
fd_MessageBasedParams_yes_quorum protoreflect.FieldDescriptor
fd_MessageBasedParams_threshold protoreflect.FieldDescriptor
fd_MessageBasedParams_veto_threshold protoreflect.FieldDescriptor
)
func init() {
file_cosmos_gov_v1_gov_proto_init()
md_MessageBasedParams = File_cosmos_gov_v1_gov_proto.Messages().ByName("MessageBasedParams")
fd_MessageBasedParams_voting_period = md_MessageBasedParams.Fields().ByName("voting_period")
fd_MessageBasedParams_quorum = md_MessageBasedParams.Fields().ByName("quorum")
fd_MessageBasedParams_yes_quorum = md_MessageBasedParams.Fields().ByName("yes_quorum")
fd_MessageBasedParams_threshold = md_MessageBasedParams.Fields().ByName("threshold")
fd_MessageBasedParams_veto_threshold = md_MessageBasedParams.Fields().ByName("veto_threshold")
}
var _ protoreflect.Message = (*fastReflection_MessageBasedParams)(nil)
type fastReflection_MessageBasedParams MessageBasedParams
func (x *MessageBasedParams) ProtoReflect() protoreflect.Message {
return (*fastReflection_MessageBasedParams)(x)
}
func (x *MessageBasedParams) slowProtoReflect() protoreflect.Message {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[10]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
var _fastReflection_MessageBasedParams_messageType fastReflection_MessageBasedParams_messageType
var _ protoreflect.MessageType = fastReflection_MessageBasedParams_messageType{}
type fastReflection_MessageBasedParams_messageType struct{}
func (x fastReflection_MessageBasedParams_messageType) Zero() protoreflect.Message {
return (*fastReflection_MessageBasedParams)(nil)
}
func (x fastReflection_MessageBasedParams_messageType) New() protoreflect.Message {
return new(fastReflection_MessageBasedParams)
}
func (x fastReflection_MessageBasedParams_messageType) Descriptor() protoreflect.MessageDescriptor {
return md_MessageBasedParams
}
// Descriptor returns message descriptor, which contains only the protobuf
// type information for the message.
func (x *fastReflection_MessageBasedParams) Descriptor() protoreflect.MessageDescriptor {
return md_MessageBasedParams
}
// Type returns the message type, which encapsulates both Go and protobuf
// type information. If the Go type information is not needed,
// it is recommended that the message descriptor be used instead.
func (x *fastReflection_MessageBasedParams) Type() protoreflect.MessageType {
return _fastReflection_MessageBasedParams_messageType
}
// New returns a newly allocated and mutable empty message.
func (x *fastReflection_MessageBasedParams) New() protoreflect.Message {
return new(fastReflection_MessageBasedParams)
}
// Interface unwraps the message reflection interface and
// returns the underlying ProtoMessage interface.
func (x *fastReflection_MessageBasedParams) Interface() protoreflect.ProtoMessage {
return (*MessageBasedParams)(x)
}
// Range iterates over every populated field in an undefined order,
// calling f for each field descriptor and value encountered.
// Range returns immediately if f returns false.
// While iterating, mutating operations may only be performed
// on the current field descriptor.
func (x *fastReflection_MessageBasedParams) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {
if x.VotingPeriod != nil {
value := protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
if !f(fd_MessageBasedParams_voting_period, value) {
return
}
}
if x.Quorum != "" {
value := protoreflect.ValueOfString(x.Quorum)
if !f(fd_MessageBasedParams_quorum, value) {
return
}
}
if x.YesQuorum != "" {
value := protoreflect.ValueOfString(x.YesQuorum)
if !f(fd_MessageBasedParams_yes_quorum, value) {
return
}
}
if x.Threshold != "" {
value := protoreflect.ValueOfString(x.Threshold)
if !f(fd_MessageBasedParams_threshold, value) {
return
}
}
if x.VetoThreshold != "" {
value := protoreflect.ValueOfString(x.VetoThreshold)
if !f(fd_MessageBasedParams_veto_threshold, value) {
return
}
}
}
// Has reports whether a field is populated.
//
// Some fields have the property of nullability where it is possible to
// distinguish between the default value of a field and whether the field
// was explicitly populated with the default value. Singular message fields,
// member fields of a oneof, and proto2 scalar fields are nullable. Such
// fields are populated only if explicitly set.
//
// In other cases (aside from the nullable cases above),
// a proto3 scalar field is populated if it contains a non-zero value, and
// a repeated field is populated if it is non-empty.
func (x *fastReflection_MessageBasedParams) Has(fd protoreflect.FieldDescriptor) bool {
switch fd.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
return x.VotingPeriod != nil
case "cosmos.gov.v1.MessageBasedParams.quorum":
return x.Quorum != ""
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
return x.YesQuorum != ""
case "cosmos.gov.v1.MessageBasedParams.threshold":
return x.Threshold != ""
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
return x.VetoThreshold != ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", fd.FullName()))
}
}
// Clear clears the field such that a subsequent Has call reports false.
//
// Clearing an extension field clears both the extension type and value
// associated with the given field number.
//
// Clear is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_MessageBasedParams) Clear(fd protoreflect.FieldDescriptor) {
switch fd.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
x.VotingPeriod = nil
case "cosmos.gov.v1.MessageBasedParams.quorum":
x.Quorum = ""
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
x.YesQuorum = ""
case "cosmos.gov.v1.MessageBasedParams.threshold":
x.Threshold = ""
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
x.VetoThreshold = ""
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", fd.FullName()))
}
}
// Get retrieves the value for a field.
//
// For unpopulated scalars, it returns the default value, where
// the default value of a bytes scalar is guaranteed to be a copy.
// For unpopulated composite types, it returns an empty, read-only view
// of the value; to obtain a mutable reference, use Mutable.
func (x *fastReflection_MessageBasedParams) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value {
switch descriptor.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
value := x.VotingPeriod
return protoreflect.ValueOfMessage(value.ProtoReflect())
case "cosmos.gov.v1.MessageBasedParams.quorum":
value := x.Quorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
value := x.YesQuorum
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.MessageBasedParams.threshold":
value := x.Threshold
return protoreflect.ValueOfString(value)
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
value := x.VetoThreshold
return protoreflect.ValueOfString(value)
default:
if descriptor.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", descriptor.FullName()))
}
}
// Set stores the value for a field.
//
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType.
// When setting a composite type, it is unspecified whether the stored value
// aliases the source's memory in any way. If the composite value is an
// empty, read-only value, then it panics.
//
// Set is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_MessageBasedParams) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) {
switch fd.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
x.VotingPeriod = value.Message().Interface().(*durationpb.Duration)
case "cosmos.gov.v1.MessageBasedParams.quorum":
x.Quorum = value.Interface().(string)
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
x.YesQuorum = value.Interface().(string)
case "cosmos.gov.v1.MessageBasedParams.threshold":
x.Threshold = value.Interface().(string)
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
x.VetoThreshold = value.Interface().(string)
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", fd.FullName()))
}
}
// Mutable returns a mutable reference to a composite type.
//
// If the field is unpopulated, it may allocate a composite value.
// For a field belonging to a oneof, it implicitly clears any other field
// that may be currently set within the same oneof.
// For extension fields, it implicitly stores the provided ExtensionType
// if not already stored.
// It panics if the field does not contain a composite type.
//
// Mutable is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_MessageBasedParams) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
if x.VotingPeriod == nil {
x.VotingPeriod = new(durationpb.Duration)
}
return protoreflect.ValueOfMessage(x.VotingPeriod.ProtoReflect())
case "cosmos.gov.v1.MessageBasedParams.quorum":
panic(fmt.Errorf("field quorum of message cosmos.gov.v1.MessageBasedParams is not mutable"))
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
panic(fmt.Errorf("field yes_quorum of message cosmos.gov.v1.MessageBasedParams is not mutable"))
case "cosmos.gov.v1.MessageBasedParams.threshold":
panic(fmt.Errorf("field threshold of message cosmos.gov.v1.MessageBasedParams is not mutable"))
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
panic(fmt.Errorf("field veto_threshold of message cosmos.gov.v1.MessageBasedParams is not mutable"))
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", fd.FullName()))
}
}
// NewField returns a new value that is assignable to the field
// for the given descriptor. For scalars, this returns the default value.
// For lists, maps, and messages, this returns a new, empty, mutable value.
func (x *fastReflection_MessageBasedParams) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value {
switch fd.FullName() {
case "cosmos.gov.v1.MessageBasedParams.voting_period":
m := new(durationpb.Duration)
return protoreflect.ValueOfMessage(m.ProtoReflect())
case "cosmos.gov.v1.MessageBasedParams.quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.MessageBasedParams.yes_quorum":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.MessageBasedParams.threshold":
return protoreflect.ValueOfString("")
case "cosmos.gov.v1.MessageBasedParams.veto_threshold":
return protoreflect.ValueOfString("")
default:
if fd.IsExtension() {
panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1.MessageBasedParams"))
}
panic(fmt.Errorf("message cosmos.gov.v1.MessageBasedParams does not contain field %s", fd.FullName()))
}
}
// WhichOneof reports which field within the oneof is populated,
// returning nil if none are populated.
// It panics if the oneof descriptor does not belong to this message.
func (x *fastReflection_MessageBasedParams) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor {
switch d.FullName() {
default:
panic(fmt.Errorf("%s is not a oneof field in cosmos.gov.v1.MessageBasedParams", d.FullName()))
}
panic("unreachable")
}
// GetUnknown retrieves the entire list of unknown fields.
// The caller may only mutate the contents of the RawFields
// if the mutated bytes are stored back into the message with SetUnknown.
func (x *fastReflection_MessageBasedParams) GetUnknown() protoreflect.RawFields {
return x.unknownFields
}
// SetUnknown stores an entire list of unknown fields.
// The raw fields must be syntactically valid according to the wire format.
// An implementation may panic if this is not the case.
// Once stored, the caller must not mutate the content of the RawFields.
// An empty RawFields may be passed to clear the fields.
//
// SetUnknown is a mutating operation and unsafe for concurrent use.
func (x *fastReflection_MessageBasedParams) SetUnknown(fields protoreflect.RawFields) {
x.unknownFields = fields
}
// IsValid reports whether the message is valid.
//
// An invalid message is an empty, read-only value.
//
// An invalid message often corresponds to a nil pointer of the concrete
// message type, but the details are implementation dependent.
// Validity is not part of the protobuf data model, and may not
// be preserved in marshaling or other operations.
func (x *fastReflection_MessageBasedParams) IsValid() bool {
return x != nil
}
// ProtoMethods returns optional fastReflectionFeature-path implementations of various operations.
// This method may return nil.
//
// The returned methods type is identical to
// "google.golang.org/protobuf/runtime/protoiface".Methods.
// Consult the protoiface package documentation for details.
func (x *fastReflection_MessageBasedParams) ProtoMethods() *protoiface.Methods {
size := func(input protoiface.SizeInput) protoiface.SizeOutput {
x := input.Message.Interface().(*MessageBasedParams)
if x == nil {
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: 0,
}
}
options := runtime.SizeInputToOptions(input)
_ = options
var n int
var l int
_ = l
if x.VotingPeriod != nil {
l = options.Size(x.VotingPeriod)
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.Quorum)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.YesQuorum)
if l > 0 {
n += 2 + l + runtime.Sov(uint64(l))
}
l = len(x.Threshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
l = len(x.VetoThreshold)
if l > 0 {
n += 1 + l + runtime.Sov(uint64(l))
}
if x.unknownFields != nil {
n += len(x.unknownFields)
}
return protoiface.SizeOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Size: n,
}
}
marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) {
x := input.Message.Interface().(*MessageBasedParams)
if x == nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
options := runtime.MarshalInputToOptions(input)
_ = options
size := options.Size(x)
dAtA := make([]byte, size)
i := len(dAtA)
_ = i
var l int
_ = l
if x.unknownFields != nil {
i -= len(x.unknownFields)
copy(dAtA[i:], x.unknownFields)
}
if len(x.YesQuorum) > 0 {
i -= len(x.YesQuorum)
copy(dAtA[i:], x.YesQuorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.YesQuorum)))
i--
dAtA[i] = 0x1
i--
dAtA[i] = 0xa2
}
if len(x.VetoThreshold) > 0 {
i -= len(x.VetoThreshold)
copy(dAtA[i:], x.VetoThreshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.VetoThreshold)))
i--
dAtA[i] = 0x22
}
if len(x.Threshold) > 0 {
i -= len(x.Threshold)
copy(dAtA[i:], x.Threshold)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Threshold)))
i--
dAtA[i] = 0x1a
}
if len(x.Quorum) > 0 {
i -= len(x.Quorum)
copy(dAtA[i:], x.Quorum)
i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Quorum)))
i--
dAtA[i] = 0x12
}
if x.VotingPeriod != nil {
encoded, err := options.Marshal(x.VotingPeriod)
if err != nil {
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, err
}
i -= len(encoded)
copy(dAtA[i:], encoded)
i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded)))
i--
dAtA[i] = 0xa
}
if input.Buf != nil {
input.Buf = append(input.Buf, dAtA...)
} else {
input.Buf = dAtA
}
return protoiface.MarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Buf: input.Buf,
}, nil
}
unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) {
x := input.Message.Interface().(*MessageBasedParams)
if x == nil {
return protoiface.UnmarshalOutput{
NoUnkeyedLiterals: input.NoUnkeyedLiterals,
Flags: input.Flags,
}, nil
}
options := runtime.UnmarshalInputToOptions(input)
_ = options
dAtA := input.Buf
l := len(dAtA)
iNdEx := 0
for iNdEx < l {
preIndex := iNdEx
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
wire |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
fieldNum := int32(wire >> 3)
wireType := int(wire & 0x7)
if wireType == 4 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MessageBasedParams: wiretype end group for non-group")
}
if fieldNum <= 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MessageBasedParams: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingPeriod", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if x.VotingPeriod == nil {
x.VotingPeriod = &durationpb.Duration{}
}
if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.VotingPeriod); err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
iNdEx = postIndex
case 2:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Quorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Quorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 20:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field YesQuorum", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.YesQuorum = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 3:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Threshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.Threshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 4:
if wireType != 2 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VetoThreshold", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow
}
if iNdEx >= l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
intStringLen := int(stringLen)
if intStringLen < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if postIndex > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
x.VetoThreshold = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := runtime.Skip(dAtA[iNdEx:])
if err != nil {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err
}
if (skippy < 0) || (iNdEx+skippy) < 0 {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength
}
if (iNdEx + skippy) > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
if !options.DiscardUnknown {
x.unknownFields = append(x.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
}
iNdEx += skippy
}
}
if iNdEx > l {
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF
}
return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, nil
}
return &protoiface.Methods{
NoUnkeyedLiterals: struct{}{},
Flags: protoiface.SupportMarshalDeterministic | protoiface.SupportUnmarshalDiscardUnknown,
Size: size,
Marshal: marshal,
Unmarshal: unmarshal,
Merge: nil,
CheckInitialized: nil,
}
}
// Since: cosmos-sdk 0.46
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.27.0
// protoc (unknown)
// source: cosmos/gov/v1/gov.proto
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// ProposalType enumerates the valid proposal types.
// All proposal types are v1.Proposal which have different voting periods or tallying logic.
type ProposalType int32
const (
// PROPOSAL_TYPE_UNSPECIFIED defines no proposal type, which fallback to PROPOSAL_TYPE_STANDARD.
ProposalType_PROPOSAL_TYPE_UNSPECIFIED ProposalType = 0
// PROPOSAL_TYPE_STANDARD defines the type for a standard proposal.
ProposalType_PROPOSAL_TYPE_STANDARD ProposalType = 1
// PROPOSAL_TYPE_MULTIPLE_CHOICE defines the type for a multiple choice proposal.
ProposalType_PROPOSAL_TYPE_MULTIPLE_CHOICE ProposalType = 2
// PROPOSAL_TYPE_OPTIMISTIC defines the type for an optimistic proposal.
ProposalType_PROPOSAL_TYPE_OPTIMISTIC ProposalType = 3
// PROPOSAL_TYPE_EXPEDITED defines the type for an expedited proposal.
ProposalType_PROPOSAL_TYPE_EXPEDITED ProposalType = 4
)
// Enum value maps for ProposalType.
var (
ProposalType_name = map[int32]string{
0: "PROPOSAL_TYPE_UNSPECIFIED",
1: "PROPOSAL_TYPE_STANDARD",
2: "PROPOSAL_TYPE_MULTIPLE_CHOICE",
3: "PROPOSAL_TYPE_OPTIMISTIC",
4: "PROPOSAL_TYPE_EXPEDITED",
}
ProposalType_value = map[string]int32{
"PROPOSAL_TYPE_UNSPECIFIED": 0,
"PROPOSAL_TYPE_STANDARD": 1,
"PROPOSAL_TYPE_MULTIPLE_CHOICE": 2,
"PROPOSAL_TYPE_OPTIMISTIC": 3,
"PROPOSAL_TYPE_EXPEDITED": 4,
}
)
func (x ProposalType) Enum() *ProposalType {
p := new(ProposalType)
*p = x
return p
}
func (x ProposalType) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (ProposalType) Descriptor() protoreflect.EnumDescriptor {
return file_cosmos_gov_v1_gov_proto_enumTypes[0].Descriptor()
}
func (ProposalType) Type() protoreflect.EnumType {
return &file_cosmos_gov_v1_gov_proto_enumTypes[0]
}
func (x ProposalType) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use ProposalType.Descriptor instead.
func (ProposalType) EnumDescriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{0}
}
// VoteOption enumerates the valid vote options for a given governance proposal.
type VoteOption int32
const (
// VOTE_OPTION_UNSPECIFIED defines a no-op vote option.
VoteOption_VOTE_OPTION_UNSPECIFIED VoteOption = 0
// VOTE_OPTION_YES defines the yes proposal vote option.
VoteOption_VOTE_OPTION_YES VoteOption = 1
// VOTE_OPTION_ONE defines the first proposal vote option.
VoteOption_VOTE_OPTION_ONE VoteOption = 1
// VOTE_OPTION_ABSTAIN defines the abstain proposal vote option.
VoteOption_VOTE_OPTION_ABSTAIN VoteOption = 2
// VOTE_OPTION_TWO defines the second proposal vote option.
VoteOption_VOTE_OPTION_TWO VoteOption = 2
// VOTE_OPTION_NO defines the no proposal vote option.
VoteOption_VOTE_OPTION_NO VoteOption = 3
// VOTE_OPTION_THREE defines the third proposal vote option.
VoteOption_VOTE_OPTION_THREE VoteOption = 3
// VOTE_OPTION_NO_WITH_VETO defines the no with veto proposal vote option.
VoteOption_VOTE_OPTION_NO_WITH_VETO VoteOption = 4
// VOTE_OPTION_FOUR defines the fourth proposal vote option.
VoteOption_VOTE_OPTION_FOUR VoteOption = 4
// VOTE_OPTION_SPAM defines the spam proposal vote option.
VoteOption_VOTE_OPTION_SPAM VoteOption = 5
)
// Enum value maps for VoteOption.
var (
VoteOption_name = map[int32]string{
0: "VOTE_OPTION_UNSPECIFIED",
1: "VOTE_OPTION_YES",
// Duplicate value: 1: "VOTE_OPTION_ONE",
2: "VOTE_OPTION_ABSTAIN",
// Duplicate value: 2: "VOTE_OPTION_TWO",
3: "VOTE_OPTION_NO",
// Duplicate value: 3: "VOTE_OPTION_THREE",
4: "VOTE_OPTION_NO_WITH_VETO",
// Duplicate value: 4: "VOTE_OPTION_FOUR",
5: "VOTE_OPTION_SPAM",
}
VoteOption_value = map[string]int32{
"VOTE_OPTION_UNSPECIFIED": 0,
"VOTE_OPTION_YES": 1,
"VOTE_OPTION_ONE": 1,
"VOTE_OPTION_ABSTAIN": 2,
"VOTE_OPTION_TWO": 2,
"VOTE_OPTION_NO": 3,
"VOTE_OPTION_THREE": 3,
"VOTE_OPTION_NO_WITH_VETO": 4,
"VOTE_OPTION_FOUR": 4,
"VOTE_OPTION_SPAM": 5,
}
)
func (x VoteOption) Enum() *VoteOption {
p := new(VoteOption)
*p = x
return p
}
func (x VoteOption) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (VoteOption) Descriptor() protoreflect.EnumDescriptor {
return file_cosmos_gov_v1_gov_proto_enumTypes[1].Descriptor()
}
func (VoteOption) Type() protoreflect.EnumType {
return &file_cosmos_gov_v1_gov_proto_enumTypes[1]
}
func (x VoteOption) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use VoteOption.Descriptor instead.
func (VoteOption) EnumDescriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{1}
}
// ProposalStatus enumerates the valid statuses of a proposal.
type ProposalStatus int32
const (
// PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status.
ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED ProposalStatus = 0
// PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit
// period.
ProposalStatus_PROPOSAL_STATUS_DEPOSIT_PERIOD ProposalStatus = 1
// PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting
// period.
ProposalStatus_PROPOSAL_STATUS_VOTING_PERIOD ProposalStatus = 2
// PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has
// passed.
ProposalStatus_PROPOSAL_STATUS_PASSED ProposalStatus = 3
// PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has
// been rejected.
ProposalStatus_PROPOSAL_STATUS_REJECTED ProposalStatus = 4
// PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has
// failed.
ProposalStatus_PROPOSAL_STATUS_FAILED ProposalStatus = 5
)
// Enum value maps for ProposalStatus.
var (
ProposalStatus_name = map[int32]string{
0: "PROPOSAL_STATUS_UNSPECIFIED",
1: "PROPOSAL_STATUS_DEPOSIT_PERIOD",
2: "PROPOSAL_STATUS_VOTING_PERIOD",
3: "PROPOSAL_STATUS_PASSED",
4: "PROPOSAL_STATUS_REJECTED",
5: "PROPOSAL_STATUS_FAILED",
}
ProposalStatus_value = map[string]int32{
"PROPOSAL_STATUS_UNSPECIFIED": 0,
"PROPOSAL_STATUS_DEPOSIT_PERIOD": 1,
"PROPOSAL_STATUS_VOTING_PERIOD": 2,
"PROPOSAL_STATUS_PASSED": 3,
"PROPOSAL_STATUS_REJECTED": 4,
"PROPOSAL_STATUS_FAILED": 5,
}
)
func (x ProposalStatus) Enum() *ProposalStatus {
p := new(ProposalStatus)
*p = x
return p
}
func (x ProposalStatus) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (ProposalStatus) Descriptor() protoreflect.EnumDescriptor {
return file_cosmos_gov_v1_gov_proto_enumTypes[2].Descriptor()
}
func (ProposalStatus) Type() protoreflect.EnumType {
return &file_cosmos_gov_v1_gov_proto_enumTypes[2]
}
func (x ProposalStatus) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use ProposalStatus.Descriptor instead.
func (ProposalStatus) EnumDescriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{2}
}
// WeightedVoteOption defines a unit of vote for vote split.
type WeightedVoteOption struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// option defines the valid vote options, it must not contain duplicate vote options.
Option VoteOption `protobuf:"varint,1,opt,name=option,proto3,enum=cosmos.gov.v1.VoteOption" json:"option,omitempty"`
// weight is the vote weight associated with the vote option.
Weight string `protobuf:"bytes,2,opt,name=weight,proto3" json:"weight,omitempty"`
}
func (x *WeightedVoteOption) Reset() {
*x = WeightedVoteOption{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *WeightedVoteOption) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*WeightedVoteOption) ProtoMessage() {}
// Deprecated: Use WeightedVoteOption.ProtoReflect.Descriptor instead.
func (*WeightedVoteOption) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{0}
}
func (x *WeightedVoteOption) GetOption() VoteOption {
if x != nil {
return x.Option
}
return VoteOption_VOTE_OPTION_UNSPECIFIED
}
func (x *WeightedVoteOption) GetWeight() string {
if x != nil {
return x.Weight
}
return ""
}
// Deposit defines an amount deposited by an account address to an active
// proposal.
type Deposit struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// proposal_id defines the unique id of the proposal.
ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"`
// depositor defines the deposit addresses from the proposals.
Depositor string `protobuf:"bytes,2,opt,name=depositor,proto3" json:"depositor,omitempty"`
// amount to be deposited by depositor.
Amount []*v1beta1.Coin `protobuf:"bytes,3,rep,name=amount,proto3" json:"amount,omitempty"`
}
func (x *Deposit) Reset() {
*x = Deposit{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Deposit) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Deposit) ProtoMessage() {}
// Deprecated: Use Deposit.ProtoReflect.Descriptor instead.
func (*Deposit) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{1}
}
func (x *Deposit) GetProposalId() uint64 {
if x != nil {
return x.ProposalId
}
return 0
}
func (x *Deposit) GetDepositor() string {
if x != nil {
return x.Depositor
}
return ""
}
func (x *Deposit) GetAmount() []*v1beta1.Coin {
if x != nil {
return x.Amount
}
return nil
}
// Proposal defines the core field members of a governance proposal.
type Proposal struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// id defines the unique id of the proposal.
Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
// messages are the arbitrary messages to be executed if the proposal passes.
Messages []*anypb.Any `protobuf:"bytes,2,rep,name=messages,proto3" json:"messages,omitempty"`
// status defines the proposal status.
Status ProposalStatus `protobuf:"varint,3,opt,name=status,proto3,enum=cosmos.gov.v1.ProposalStatus" json:"status,omitempty"`
// final_tally_result is the final tally result of the proposal. When
// querying a proposal via gRPC, this field is not populated until the
// proposal's voting period has ended.
FinalTallyResult *TallyResult `protobuf:"bytes,4,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result,omitempty"`
// submit_time is the time of proposal submission.
SubmitTime *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=submit_time,json=submitTime,proto3" json:"submit_time,omitempty"`
// deposit_end_time is the end time for deposition.
DepositEndTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=deposit_end_time,json=depositEndTime,proto3" json:"deposit_end_time,omitempty"`
// total_deposit is the total deposit on the proposal.
TotalDeposit []*v1beta1.Coin `protobuf:"bytes,7,rep,name=total_deposit,json=totalDeposit,proto3" json:"total_deposit,omitempty"`
// voting_start_time is the starting time to vote on a proposal.
VotingStartTime *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=voting_start_time,json=votingStartTime,proto3" json:"voting_start_time,omitempty"`
// voting_end_time is the end time of voting on a proposal.
VotingEndTime *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=voting_end_time,json=votingEndTime,proto3" json:"voting_end_time,omitempty"`
// metadata is any arbitrary metadata attached to the proposal.
// the recommended format of the metadata is to be found here:
// https://docs.cosmos.network/v0.47/modules/gov#proposal-3
Metadata string `protobuf:"bytes,10,opt,name=metadata,proto3" json:"metadata,omitempty"`
// title is the title of the proposal
Title string `protobuf:"bytes,11,opt,name=title,proto3" json:"title,omitempty"`
// summary is a short summary of the proposal
Summary string `protobuf:"bytes,12,opt,name=summary,proto3" json:"summary,omitempty"`
// proposer is the address of the proposal sumbitter
Proposer string `protobuf:"bytes,13,opt,name=proposer,proto3" json:"proposer,omitempty"`
// expedited defines if the proposal is expedited
//
// Deprecated: Use ProposalType instead.
//
// Deprecated: Do not use.
Expedited bool `protobuf:"varint,14,opt,name=expedited,proto3" json:"expedited,omitempty"`
// failed_reason defines the reason why the proposal failed
FailedReason string `protobuf:"bytes,15,opt,name=failed_reason,json=failedReason,proto3" json:"failed_reason,omitempty"`
// proposal_type defines the type of the proposal
ProposalType ProposalType `protobuf:"varint,16,opt,name=proposal_type,json=proposalType,proto3,enum=cosmos.gov.v1.ProposalType" json:"proposal_type,omitempty"`
}
func (x *Proposal) Reset() {
*x = Proposal{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Proposal) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Proposal) ProtoMessage() {}
// Deprecated: Use Proposal.ProtoReflect.Descriptor instead.
func (*Proposal) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{2}
}
func (x *Proposal) GetId() uint64 {
if x != nil {
return x.Id
}
return 0
}
func (x *Proposal) GetMessages() []*anypb.Any {
if x != nil {
return x.Messages
}
return nil
}
func (x *Proposal) GetStatus() ProposalStatus {
if x != nil {
return x.Status
}
return ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED
}
func (x *Proposal) GetFinalTallyResult() *TallyResult {
if x != nil {
return x.FinalTallyResult
}
return nil
}
func (x *Proposal) GetSubmitTime() *timestamppb.Timestamp {
if x != nil {
return x.SubmitTime
}
return nil
}
func (x *Proposal) GetDepositEndTime() *timestamppb.Timestamp {
if x != nil {
return x.DepositEndTime
}
return nil
}
func (x *Proposal) GetTotalDeposit() []*v1beta1.Coin {
if x != nil {
return x.TotalDeposit
}
return nil
}
func (x *Proposal) GetVotingStartTime() *timestamppb.Timestamp {
if x != nil {
return x.VotingStartTime
}
return nil
}
func (x *Proposal) GetVotingEndTime() *timestamppb.Timestamp {
if x != nil {
return x.VotingEndTime
}
return nil
}
func (x *Proposal) GetMetadata() string {
if x != nil {
return x.Metadata
}
return ""
}
func (x *Proposal) GetTitle() string {
if x != nil {
return x.Title
}
return ""
}
func (x *Proposal) GetSummary() string {
if x != nil {
return x.Summary
}
return ""
}
func (x *Proposal) GetProposer() string {
if x != nil {
return x.Proposer
}
return ""
}
// Deprecated: Do not use.
func (x *Proposal) GetExpedited() bool {
if x != nil {
return x.Expedited
}
return false
}
func (x *Proposal) GetFailedReason() string {
if x != nil {
return x.FailedReason
}
return ""
}
func (x *Proposal) GetProposalType() ProposalType {
if x != nil {
return x.ProposalType
}
return ProposalType_PROPOSAL_TYPE_UNSPECIFIED
}
// ProposalVoteOptions defines the stringified vote options for proposals.
// This allows to support multiple choice options for a given proposal.
type ProposalVoteOptions struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// option_one is the first option of the proposal
OptionOne string `protobuf:"bytes,1,opt,name=option_one,json=optionOne,proto3" json:"option_one,omitempty"`
// option_two is the second option of the proposal
OptionTwo string `protobuf:"bytes,2,opt,name=option_two,json=optionTwo,proto3" json:"option_two,omitempty"`
// option_three is the third option of the proposal
OptionThree string `protobuf:"bytes,3,opt,name=option_three,json=optionThree,proto3" json:"option_three,omitempty"`
// option_four is the fourth option of the proposal
OptionFour string `protobuf:"bytes,4,opt,name=option_four,json=optionFour,proto3" json:"option_four,omitempty"`
// option_spam is always present for all proposals.
OptionSpam string `protobuf:"bytes,5,opt,name=option_spam,json=optionSpam,proto3" json:"option_spam,omitempty"`
}
func (x *ProposalVoteOptions) Reset() {
*x = ProposalVoteOptions{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *ProposalVoteOptions) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ProposalVoteOptions) ProtoMessage() {}
// Deprecated: Use ProposalVoteOptions.ProtoReflect.Descriptor instead.
func (*ProposalVoteOptions) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{3}
}
func (x *ProposalVoteOptions) GetOptionOne() string {
if x != nil {
return x.OptionOne
}
return ""
}
func (x *ProposalVoteOptions) GetOptionTwo() string {
if x != nil {
return x.OptionTwo
}
return ""
}
func (x *ProposalVoteOptions) GetOptionThree() string {
if x != nil {
return x.OptionThree
}
return ""
}
func (x *ProposalVoteOptions) GetOptionFour() string {
if x != nil {
return x.OptionFour
}
return ""
}
func (x *ProposalVoteOptions) GetOptionSpam() string {
if x != nil {
return x.OptionSpam
}
return ""
}
// TallyResult defines a standard tally for a governance proposal.
type TallyResult struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// yes_count is the number of yes votes on a proposal.
//
// Deprecated: Do not use.
YesCount string `protobuf:"bytes,1,opt,name=yes_count,json=yesCount,proto3" json:"yes_count,omitempty"` // option 1
// abstain_count is the number of abstain votes on a proposal.
//
// Deprecated: Do not use.
AbstainCount string `protobuf:"bytes,2,opt,name=abstain_count,json=abstainCount,proto3" json:"abstain_count,omitempty"` // option 2
// no_count is the number of no votes on a proposal.
//
// Deprecated: Do not use.
NoCount string `protobuf:"bytes,3,opt,name=no_count,json=noCount,proto3" json:"no_count,omitempty"` // option 3
// no_with_veto_count is the number of no with veto votes on a proposal.
//
// Deprecated: Do not use.
NoWithVetoCount string `protobuf:"bytes,4,opt,name=no_with_veto_count,json=noWithVetoCount,proto3" json:"no_with_veto_count,omitempty"` // option 4
// option_one_count corresponds to the number of votes for option one (= yes_count for non multiple choice proposals).
OptionOneCount string `protobuf:"bytes,5,opt,name=option_one_count,json=optionOneCount,proto3" json:"option_one_count,omitempty"`
// option_two_count corresponds to the number of votes for option two (= abstain_count for non multiple choice
// proposals).
OptionTwoCount string `protobuf:"bytes,6,opt,name=option_two_count,json=optionTwoCount,proto3" json:"option_two_count,omitempty"`
// option_three_count corresponds to the number of votes for option three (= no_count for non multiple choice
// proposals).
OptionThreeCount string `protobuf:"bytes,7,opt,name=option_three_count,json=optionThreeCount,proto3" json:"option_three_count,omitempty"`
// option_four_count corresponds to the number of votes for option four (= no_with_veto_count for non multiple choice
// proposals).
OptionFourCount string `protobuf:"bytes,8,opt,name=option_four_count,json=optionFourCount,proto3" json:"option_four_count,omitempty"`
// spam_count is the number of spam votes on a proposal.
SpamCount string `protobuf:"bytes,9,opt,name=spam_count,json=spamCount,proto3" json:"spam_count,omitempty"`
}
func (x *TallyResult) Reset() {
*x = TallyResult{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *TallyResult) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*TallyResult) ProtoMessage() {}
// Deprecated: Use TallyResult.ProtoReflect.Descriptor instead.
func (*TallyResult) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{4}
}
// Deprecated: Do not use.
func (x *TallyResult) GetYesCount() string {
if x != nil {
return x.YesCount
}
return ""
}
// Deprecated: Do not use.
func (x *TallyResult) GetAbstainCount() string {
if x != nil {
return x.AbstainCount
}
return ""
}
// Deprecated: Do not use.
func (x *TallyResult) GetNoCount() string {
if x != nil {
return x.NoCount
}
return ""
}
// Deprecated: Do not use.
func (x *TallyResult) GetNoWithVetoCount() string {
if x != nil {
return x.NoWithVetoCount
}
return ""
}
func (x *TallyResult) GetOptionOneCount() string {
if x != nil {
return x.OptionOneCount
}
return ""
}
func (x *TallyResult) GetOptionTwoCount() string {
if x != nil {
return x.OptionTwoCount
}
return ""
}
func (x *TallyResult) GetOptionThreeCount() string {
if x != nil {
return x.OptionThreeCount
}
return ""
}
func (x *TallyResult) GetOptionFourCount() string {
if x != nil {
return x.OptionFourCount
}
return ""
}
func (x *TallyResult) GetSpamCount() string {
if x != nil {
return x.SpamCount
}
return ""
}
// Vote defines a vote on a governance proposal.
// A Vote consists of a proposal ID, the voter, and the vote option.
type Vote struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// proposal_id defines the unique id of the proposal.
ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"`
// voter is the voter address of the proposal.
Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"`
// options is the weighted vote options.
Options []*WeightedVoteOption `protobuf:"bytes,4,rep,name=options,proto3" json:"options,omitempty"`
// metadata is any arbitrary metadata attached to the vote.
// the recommended format of the metadata is to be found here: https://docs.cosmos.network/v0.47/modules/gov#vote-5
Metadata string `protobuf:"bytes,5,opt,name=metadata,proto3" json:"metadata,omitempty"`
}
func (x *Vote) Reset() {
*x = Vote{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Vote) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Vote) ProtoMessage() {}
// Deprecated: Use Vote.ProtoReflect.Descriptor instead.
func (*Vote) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{5}
}
func (x *Vote) GetProposalId() uint64 {
if x != nil {
return x.ProposalId
}
return 0
}
func (x *Vote) GetVoter() string {
if x != nil {
return x.Voter
}
return ""
}
func (x *Vote) GetOptions() []*WeightedVoteOption {
if x != nil {
return x.Options
}
return nil
}
func (x *Vote) GetMetadata() string {
if x != nil {
return x.Metadata
}
return ""
}
// DepositParams defines the params for deposits on governance proposals.
//
// Deprecated: Do not use.
type DepositParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Minimum deposit for a proposal to enter voting period.
MinDeposit []*v1beta1.Coin `protobuf:"bytes,1,rep,name=min_deposit,json=minDeposit,proto3" json:"min_deposit,omitempty"`
// Maximum period for Atom holders to deposit on a proposal. Initial value: 2
// months.
MaxDepositPeriod *durationpb.Duration `protobuf:"bytes,2,opt,name=max_deposit_period,json=maxDepositPeriod,proto3" json:"max_deposit_period,omitempty"`
}
func (x *DepositParams) Reset() {
*x = DepositParams{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DepositParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DepositParams) ProtoMessage() {}
// Deprecated: Use DepositParams.ProtoReflect.Descriptor instead.
func (*DepositParams) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{6}
}
func (x *DepositParams) GetMinDeposit() []*v1beta1.Coin {
if x != nil {
return x.MinDeposit
}
return nil
}
func (x *DepositParams) GetMaxDepositPeriod() *durationpb.Duration {
if x != nil {
return x.MaxDepositPeriod
}
return nil
}
// VotingParams defines the params for voting on governance proposals.
//
// Deprecated: Do not use.
type VotingParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Duration of the voting period.
VotingPeriod *durationpb.Duration `protobuf:"bytes,1,opt,name=voting_period,json=votingPeriod,proto3" json:"voting_period,omitempty"`
}
func (x *VotingParams) Reset() {
*x = VotingParams{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *VotingParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*VotingParams) ProtoMessage() {}
// Deprecated: Use VotingParams.ProtoReflect.Descriptor instead.
func (*VotingParams) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{7}
}
func (x *VotingParams) GetVotingPeriod() *durationpb.Duration {
if x != nil {
return x.VotingPeriod
}
return nil
}
// TallyParams defines the params for tallying votes on governance proposals.
//
// Deprecated: Do not use.
type TallyParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Minimum percentage of total stake needed to vote for a result to be
// considered valid.
Quorum string `protobuf:"bytes,1,opt,name=quorum,proto3" json:"quorum,omitempty"`
// Minimum proportion of Yes votes for proposal to pass. Default value: 0.5.
Threshold string `protobuf:"bytes,2,opt,name=threshold,proto3" json:"threshold,omitempty"`
// Minimum value of Veto votes to Total votes ratio for proposal to be
// vetoed. Default value: 1/3.
VetoThreshold string `protobuf:"bytes,3,opt,name=veto_threshold,json=vetoThreshold,proto3" json:"veto_threshold,omitempty"`
}
func (x *TallyParams) Reset() {
*x = TallyParams{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *TallyParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*TallyParams) ProtoMessage() {}
// Deprecated: Use TallyParams.ProtoReflect.Descriptor instead.
func (*TallyParams) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{8}
}
func (x *TallyParams) GetQuorum() string {
if x != nil {
return x.Quorum
}
return ""
}
func (x *TallyParams) GetThreshold() string {
if x != nil {
return x.Threshold
}
return ""
}
func (x *TallyParams) GetVetoThreshold() string {
if x != nil {
return x.VetoThreshold
}
return ""
}
// Params defines the parameters for the x/gov module.
type Params struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Minimum deposit for a proposal to enter voting period.
MinDeposit []*v1beta1.Coin `protobuf:"bytes,1,rep,name=min_deposit,json=minDeposit,proto3" json:"min_deposit,omitempty"`
// Maximum period for stake holders to deposit on a proposal. Initial value: 2
// months.
MaxDepositPeriod *durationpb.Duration `protobuf:"bytes,2,opt,name=max_deposit_period,json=maxDepositPeriod,proto3" json:"max_deposit_period,omitempty"`
// Duration of the voting period.
VotingPeriod *durationpb.Duration `protobuf:"bytes,3,opt,name=voting_period,json=votingPeriod,proto3" json:"voting_period,omitempty"`
// Minimum percentage of total stake needed to vote for a result to be
// considered valid.
Quorum string `protobuf:"bytes,4,opt,name=quorum,proto3" json:"quorum,omitempty"`
// Minimum proportion of Yes votes for proposal to pass. Default value: 0.5.
Threshold string `protobuf:"bytes,5,opt,name=threshold,proto3" json:"threshold,omitempty"`
// Minimum value of Veto votes to Total votes ratio for proposal to be
// vetoed. Default value: 1/3.
VetoThreshold string `protobuf:"bytes,6,opt,name=veto_threshold,json=vetoThreshold,proto3" json:"veto_threshold,omitempty"`
// The ratio representing the proportion of the deposit value that must be paid at proposal submission.
MinInitialDepositRatio string `protobuf:"bytes,7,opt,name=min_initial_deposit_ratio,json=minInitialDepositRatio,proto3" json:"min_initial_deposit_ratio,omitempty"`
// The cancel ratio which will not be returned back to the depositors when a proposal is cancelled.
ProposalCancelRatio string `protobuf:"bytes,8,opt,name=proposal_cancel_ratio,json=proposalCancelRatio,proto3" json:"proposal_cancel_ratio,omitempty"`
// The address which will receive (proposal_cancel_ratio * deposit) proposal deposits.
// If empty, the (proposal_cancel_ratio * deposit) proposal deposits will be burned.
ProposalCancelDest string `protobuf:"bytes,9,opt,name=proposal_cancel_dest,json=proposalCancelDest,proto3" json:"proposal_cancel_dest,omitempty"`
// Duration of the voting period of an expedited proposal.
ExpeditedVotingPeriod *durationpb.Duration `protobuf:"bytes,10,opt,name=expedited_voting_period,json=expeditedVotingPeriod,proto3" json:"expedited_voting_period,omitempty"`
// Minimum proportion of Yes votes for proposal to pass. Default value: 0.67.
ExpeditedThreshold string `protobuf:"bytes,11,opt,name=expedited_threshold,json=expeditedThreshold,proto3" json:"expedited_threshold,omitempty"`
// Minimum expedited deposit for a proposal to enter voting period.
ExpeditedMinDeposit []*v1beta1.Coin `protobuf:"bytes,12,rep,name=expedited_min_deposit,json=expeditedMinDeposit,proto3" json:"expedited_min_deposit,omitempty"`
// burn deposits if a proposal does not meet quorum
BurnVoteQuorum bool `protobuf:"varint,13,opt,name=burn_vote_quorum,json=burnVoteQuorum,proto3" json:"burn_vote_quorum,omitempty"`
// burn deposits if the proposal does not enter voting period
BurnProposalDepositPrevote bool `protobuf:"varint,14,opt,name=burn_proposal_deposit_prevote,json=burnProposalDepositPrevote,proto3" json:"burn_proposal_deposit_prevote,omitempty"`
// burn deposits if quorum with vote type no_veto is met
BurnVoteVeto bool `protobuf:"varint,15,opt,name=burn_vote_veto,json=burnVoteVeto,proto3" json:"burn_vote_veto,omitempty"`
// The ratio representing the proportion of the deposit value minimum that must be met when making a deposit.
// Default value: 0.01. Meaning that for a chain with a min_deposit of 100stake, a deposit of 1stake would be
// required.
MinDepositRatio string `protobuf:"bytes,16,opt,name=min_deposit_ratio,json=minDepositRatio,proto3" json:"min_deposit_ratio,omitempty"`
// proposal_cancel_max_period defines how far in the voting period a proposer can cancel a proposal.
// If the proposal is cancelled before the max cancel period, the deposit will be returned/burn to the
// depositors, according to the proposal_cancel_ratio and proposal_cancel_dest parameters.
// After the max cancel period, the proposal cannot be cancelled anymore.
ProposalCancelMaxPeriod string `protobuf:"bytes,17,opt,name=proposal_cancel_max_period,json=proposalCancelMaxPeriod,proto3" json:"proposal_cancel_max_period,omitempty"`
// optimistic_authorized_addresses is an optional governance parameter that limits the authorized accounts than can
// submit optimistic proposals
OptimisticAuthorizedAddresses []string `protobuf:"bytes,18,rep,name=optimistic_authorized_addresses,json=optimisticAuthorizedAddresses,proto3" json:"optimistic_authorized_addresses,omitempty"`
// optimistic rejected threshold defines at which percentage of NO votes, the optimistic proposal should fail and be
// converted to a standard proposal. The threshold is expressed as a percentage of the total bonded tokens.
OptimisticRejectedThreshold string `protobuf:"bytes,19,opt,name=optimistic_rejected_threshold,json=optimisticRejectedThreshold,proto3" json:"optimistic_rejected_threshold,omitempty"`
// yes_quorum defines the minimum percentage of Yes votes in quorum for proposal to pass.
// Default value: 0 (disabled).
YesQuorum string `protobuf:"bytes,20,opt,name=yes_quorum,json=yesQuorum,proto3" json:"yes_quorum,omitempty"`
// Minimum percentage of total stake needed to vote for a result to be
// considered valid for an expedited proposal.
ExpeditedQuorum string `protobuf:"bytes,21,opt,name=expedited_quorum,json=expeditedQuorum,proto3" json:"expedited_quorum,omitempty"`
ProposalExecutionGas uint64 `protobuf:"varint,22,opt,name=proposal_execution_gas,json=proposalExecutionGas,proto3" json:"proposal_execution_gas,omitempty"`
}
func (x *Params) Reset() {
*x = Params{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Params) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Params) ProtoMessage() {}
// Deprecated: Use Params.ProtoReflect.Descriptor instead.
func (*Params) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{9}
}
func (x *Params) GetMinDeposit() []*v1beta1.Coin {
if x != nil {
return x.MinDeposit
}
return nil
}
func (x *Params) GetMaxDepositPeriod() *durationpb.Duration {
if x != nil {
return x.MaxDepositPeriod
}
return nil
}
func (x *Params) GetVotingPeriod() *durationpb.Duration {
if x != nil {
return x.VotingPeriod
}
return nil
}
func (x *Params) GetQuorum() string {
if x != nil {
return x.Quorum
}
return ""
}
func (x *Params) GetThreshold() string {
if x != nil {
return x.Threshold
}
return ""
}
func (x *Params) GetVetoThreshold() string {
if x != nil {
return x.VetoThreshold
}
return ""
}
func (x *Params) GetMinInitialDepositRatio() string {
if x != nil {
return x.MinInitialDepositRatio
}
return ""
}
func (x *Params) GetProposalCancelRatio() string {
if x != nil {
return x.ProposalCancelRatio
}
return ""
}
func (x *Params) GetProposalCancelDest() string {
if x != nil {
return x.ProposalCancelDest
}
return ""
}
func (x *Params) GetExpeditedVotingPeriod() *durationpb.Duration {
if x != nil {
return x.ExpeditedVotingPeriod
}
return nil
}
func (x *Params) GetExpeditedThreshold() string {
if x != nil {
return x.ExpeditedThreshold
}
return ""
}
func (x *Params) GetExpeditedMinDeposit() []*v1beta1.Coin {
if x != nil {
return x.ExpeditedMinDeposit
}
return nil
}
func (x *Params) GetBurnVoteQuorum() bool {
if x != nil {
return x.BurnVoteQuorum
}
return false
}
func (x *Params) GetBurnProposalDepositPrevote() bool {
if x != nil {
return x.BurnProposalDepositPrevote
}
return false
}
func (x *Params) GetBurnVoteVeto() bool {
if x != nil {
return x.BurnVoteVeto
}
return false
}
func (x *Params) GetMinDepositRatio() string {
if x != nil {
return x.MinDepositRatio
}
return ""
}
func (x *Params) GetProposalCancelMaxPeriod() string {
if x != nil {
return x.ProposalCancelMaxPeriod
}
return ""
}
func (x *Params) GetOptimisticAuthorizedAddresses() []string {
if x != nil {
return x.OptimisticAuthorizedAddresses
}
return nil
}
func (x *Params) GetOptimisticRejectedThreshold() string {
if x != nil {
return x.OptimisticRejectedThreshold
}
return ""
}
func (x *Params) GetYesQuorum() string {
if x != nil {
return x.YesQuorum
}
return ""
}
func (x *Params) GetExpeditedQuorum() string {
if x != nil {
return x.ExpeditedQuorum
}
return ""
}
func (x *Params) GetProposalExecutionGas() uint64 {
if x != nil {
return x.ProposalExecutionGas
}
return 0
}
// MessageBasedParams defines the parameters of specific messages in a proposal.
// It is used to define the parameters of a proposal that is based on a specific message.
// Once a message has message based params, it only supports a standard proposal type.
type MessageBasedParams struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Duration of the voting period.
VotingPeriod *durationpb.Duration `protobuf:"bytes,1,opt,name=voting_period,json=votingPeriod,proto3" json:"voting_period,omitempty"`
// Minimum percentage of total stake needed to vote for a result to be considered valid.
Quorum string `protobuf:"bytes,2,opt,name=quorum,proto3" json:"quorum,omitempty"`
// yes_quorum defines the minimum percentage of Yes votes in quorum for proposal to pass.
// If zero then the yes_quorum is disabled.
YesQuorum string `protobuf:"bytes,20,opt,name=yes_quorum,json=yesQuorum,proto3" json:"yes_quorum,omitempty"`
// Minimum proportion of Yes votes for proposal to pass.
Threshold string `protobuf:"bytes,3,opt,name=threshold,proto3" json:"threshold,omitempty"`
// Minimum value of Veto votes to Total votes ratio for proposal to be vetoed.
VetoThreshold string `protobuf:"bytes,4,opt,name=veto_threshold,json=vetoThreshold,proto3" json:"veto_threshold,omitempty"`
}
func (x *MessageBasedParams) Reset() {
*x = MessageBasedParams{}
if protoimpl.UnsafeEnabled {
mi := &file_cosmos_gov_v1_gov_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *MessageBasedParams) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*MessageBasedParams) ProtoMessage() {}
// Deprecated: Use MessageBasedParams.ProtoReflect.Descriptor instead.
func (*MessageBasedParams) Descriptor() ([]byte, []int) {
return file_cosmos_gov_v1_gov_proto_rawDescGZIP(), []int{10}
}
func (x *MessageBasedParams) GetVotingPeriod() *durationpb.Duration {
if x != nil {
return x.VotingPeriod
}
return nil
}
func (x *MessageBasedParams) GetQuorum() string {
if x != nil {
return x.Quorum
}
return ""
}
func (x *MessageBasedParams) GetYesQuorum() string {
if x != nil {
return x.YesQuorum
}
return ""
}
func (x *MessageBasedParams) GetThreshold() string {
if x != nil {
return x.Threshold
}
return ""
}
func (x *MessageBasedParams) GetVetoThreshold() string {
if x != nil {
return x.VetoThreshold
}
return ""
}
var File_cosmos_gov_v1_gov_proto protoreflect.FileDescriptor
var file_cosmos_gov_v1_gov_proto_rawDesc = []byte{
0x0a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, 0x6f, 0x76, 0x2f, 0x76, 0x31, 0x2f,
0x67, 0x6f, 0x76, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0d, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x1a, 0x1e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x63, 0x6f,
0x69, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f,
0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f,
0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a,
0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67,
0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x64, 0x75, 0x72, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d,
0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69,
0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6f, 0x0a, 0x12, 0x57, 0x65, 0x69, 0x67,
0x68, 0x74, 0x65, 0x64, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x31,
0x0a, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x19,
0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x2e, 0x56,
0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f,
0x6e, 0x12, 0x26, 0x0a, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28,
0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65,
0x63, 0x52, 0x06, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0xa0, 0x01, 0x0a, 0x07, 0x44, 0x65,
0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61,
0x6c, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x61, 0x6c, 0x49, 0x64, 0x12, 0x36, 0x0a, 0x09, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69,
0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72,
0x69, 0x6e, 0x67, 0x52, 0x09, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, 0x12, 0x3c,
0x0a, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19,
0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62,
0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8,
0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x06, 0x61, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xc1, 0x07, 0x0a,
0x08, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, 0x64, 0x12, 0x30, 0x0a, 0x08, 0x6d, 0x65, 0x73,
0x73, 0x61, 0x67, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f,
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e,
0x79, 0x52, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x12, 0x35, 0x0a, 0x06, 0x73,
0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1d, 0x2e, 0x63, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74,
0x75, 0x73, 0x12, 0x48, 0x0a, 0x12, 0x66, 0x69, 0x6e, 0x61, 0x6c, 0x5f, 0x74, 0x61, 0x6c, 0x6c,
0x79, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a,
0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x2e, 0x54,
0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x10, 0x66, 0x69, 0x6e, 0x61,
0x6c, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x41, 0x0a, 0x0b,
0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90,
0xdf, 0x1f, 0x01, 0x52, 0x0a, 0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12,
0x4a, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x65, 0x6e, 0x64, 0x5f, 0x74,
0x69, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65,
0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0e, 0x64, 0x65, 0x70,
0x6f, 0x73, 0x69, 0x74, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x49, 0x0a, 0x0d, 0x74,
0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x07, 0x20, 0x03,
0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65,
0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09, 0xc8,
0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0c, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x44,
0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x4c, 0x0a, 0x11, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67,
0x5f, 0x73, 0x74, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90,
0xdf, 0x1f, 0x01, 0x52, 0x0f, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x53, 0x74, 0x61, 0x72, 0x74,
0x54, 0x69, 0x6d, 0x65, 0x12, 0x48, 0x0a, 0x0f, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x65,
0x6e, 0x64, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e,
0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e,
0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x04, 0x90, 0xdf, 0x1f, 0x01, 0x52,
0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x45, 0x6e, 0x64, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a,
0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09,
0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x29, 0x0a, 0x05, 0x74, 0x69,
0x74, 0x6c, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x42, 0x13, 0xda, 0xb4, 0x2d, 0x0f, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x34, 0x37, 0x52, 0x05,
0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x2d, 0x0a, 0x07, 0x73, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79,
0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x42, 0x13, 0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d,
0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x34, 0x37, 0x52, 0x07, 0x73, 0x75, 0x6d,
0x6d, 0x61, 0x72, 0x79, 0x12, 0x47, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72,
0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2b, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d,
0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67,
0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30,
0x2e, 0x34, 0x37, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x12, 0x33, 0x0a,
0x09, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74, 0x65, 0x64, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x08,
0x42, 0x15, 0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b,
0x20, 0x30, 0x2e, 0x35, 0x30, 0x18, 0x01, 0x52, 0x09, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74,
0x65, 0x64, 0x12, 0x38, 0x0a, 0x0d, 0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x61,
0x73, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x42, 0x13, 0xda, 0xb4, 0x2d, 0x0f, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35, 0x30, 0x52, 0x0c,
0x66, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x52, 0x0a, 0x0d,
0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x10, 0x20,
0x01, 0x28, 0x0e, 0x32, 0x1b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76,
0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65,
0x42, 0x10, 0xda, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x30, 0x2e, 0x32,
0x2e, 0x30, 0x52, 0x0c, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65,
0x22, 0xca, 0x01, 0x0a, 0x13, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x56, 0x6f, 0x74,
0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x6f, 0x70, 0x74, 0x69,
0x6f, 0x6e, 0x5f, 0x6f, 0x6e, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x4f, 0x6e, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x6f, 0x70, 0x74, 0x69, 0x6f,
0x6e, 0x5f, 0x74, 0x77, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x6f, 0x70, 0x74,
0x69, 0x6f, 0x6e, 0x54, 0x77, 0x6f, 0x12, 0x21, 0x0a, 0x0c, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e,
0x5f, 0x74, 0x68, 0x72, 0x65, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x54, 0x68, 0x72, 0x65, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x70, 0x74,
0x69, 0x6f, 0x6e, 0x5f, 0x66, 0x6f, 0x75, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a,
0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x46, 0x6f, 0x75, 0x72, 0x12, 0x1f, 0x0a, 0x0b, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x73, 0x70, 0x61, 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0a, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x53, 0x70, 0x61, 0x6d, 0x3a, 0x10, 0xd2, 0xb4, 0x2d,
0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x30, 0x2e, 0x32, 0x2e, 0x30, 0x22, 0xfc, 0x03,
0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x2d, 0x0a,
0x09, 0x79, 0x65, 0x73, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x42, 0x10, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74,
0x18, 0x01, 0x52, 0x08, 0x79, 0x65, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x35, 0x0a, 0x0d,
0x61, 0x62, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20,
0x01, 0x28, 0x09, 0x42, 0x10, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e,
0x49, 0x6e, 0x74, 0x18, 0x01, 0x52, 0x0c, 0x61, 0x62, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x43, 0x6f,
0x75, 0x6e, 0x74, 0x12, 0x2b, 0x0a, 0x08, 0x6e, 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18,
0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x10, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2e, 0x49, 0x6e, 0x74, 0x18, 0x01, 0x52, 0x07, 0x6e, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74,
0x12, 0x3d, 0x0a, 0x12, 0x6e, 0x6f, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x5f, 0x76, 0x65, 0x74, 0x6f,
0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x10, 0xd2, 0xb4,
0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74, 0x18, 0x01, 0x52, 0x0f,
0x6e, 0x6f, 0x57, 0x69, 0x74, 0x68, 0x56, 0x65, 0x74, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12,
0x38, 0x0a, 0x10, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6f, 0x6e, 0x65, 0x5f, 0x63, 0x6f,
0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0e, 0x6f, 0x70, 0x74, 0x69, 0x6f,
0x6e, 0x4f, 0x6e, 0x65, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x38, 0x0a, 0x10, 0x6f, 0x70, 0x74,
0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x77, 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x06, 0x20,
0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e,
0x49, 0x6e, 0x74, 0x52, 0x0e, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x77, 0x6f, 0x43, 0x6f,
0x75, 0x6e, 0x74, 0x12, 0x3c, 0x0a, 0x12, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x68,
0x72, 0x65, 0x65, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42,
0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74, 0x52,
0x10, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x68, 0x72, 0x65, 0x65, 0x43, 0x6f, 0x75, 0x6e,
0x74, 0x12, 0x3a, 0x0a, 0x11, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x66, 0x6f, 0x75, 0x72,
0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4,
0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0f, 0x6f, 0x70,
0x74, 0x69, 0x6f, 0x6e, 0x46, 0x6f, 0x75, 0x72, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2d, 0x0a,
0x0a, 0x73, 0x70, 0x61, 0x6d, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28,
0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e,
0x74, 0x52, 0x09, 0x73, 0x70, 0x61, 0x6d, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xb6, 0x01, 0x0a,
0x04, 0x56, 0x6f, 0x74, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61,
0x6c, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x70,
0x6f, 0x73, 0x61, 0x6c, 0x49, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x18,
0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52,
0x05, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x12, 0x3b, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e,
0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x2e, 0x57, 0x65, 0x69, 0x67, 0x68, 0x74, 0x65, 0x64,
0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69,
0x6f, 0x6e, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18,
0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x4a,
0x04, 0x08, 0x03, 0x10, 0x04, 0x22, 0xdd, 0x01, 0x0a, 0x0d, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69,
0x74, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x59, 0x0a, 0x0b, 0x6d, 0x69, 0x6e, 0x5f, 0x64,
0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74,
0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xea, 0xde, 0x1f,
0x15, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x2c, 0x6f, 0x6d, 0x69,
0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x52, 0x0a, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73,
0x69, 0x74, 0x12, 0x6d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69,
0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19,
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x24, 0xea, 0xde, 0x1f, 0x1c, 0x6d,
0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f,
0x64, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x98, 0xdf, 0x1f, 0x01, 0x52,
0x10, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f,
0x64, 0x3a, 0x02, 0x18, 0x01, 0x22, 0x58, 0x0a, 0x0c, 0x56, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50,
0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x44, 0x0a, 0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f,
0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67,
0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44,
0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x0c, 0x76,
0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x3a, 0x02, 0x18, 0x01, 0x22,
0x9e, 0x01, 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12,
0x26, 0x0a, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42,
0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52,
0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, 0x2c, 0x0a, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73,
0x68, 0x6f, 0x6c, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a,
0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x09, 0x74, 0x68, 0x72, 0x65,
0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x35, 0x0a, 0x0e, 0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68,
0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2,
0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0d, 0x76,
0x65, 0x74, 0x6f, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x3a, 0x02, 0x18, 0x01,
0x22, 0xc7, 0x0d, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x45, 0x0a, 0x0b, 0x6d,
0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b,
0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,
0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x09, 0xc8, 0xde, 0x1f,
0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x0a, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73,
0x69, 0x74, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69,
0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19,
0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66,
0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52,
0x10, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f,
0x64, 0x12, 0x44, 0x0a, 0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69,
0x6f, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x0c, 0x76, 0x6f, 0x74, 0x69, 0x6e,
0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12, 0x26, 0x0a, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75,
0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73,
0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12,
0x2c, 0x0a, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x05, 0x20, 0x01,
0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44,
0x65, 0x63, 0x52, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x35, 0x0a,
0x0e, 0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18,
0x06, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0d, 0x76, 0x65, 0x74, 0x6f, 0x54, 0x68, 0x72, 0x65, 0x73,
0x68, 0x6f, 0x6c, 0x64, 0x12, 0x49, 0x0a, 0x19, 0x6d, 0x69, 0x6e, 0x5f, 0x69, 0x6e, 0x69, 0x74,
0x69, 0x61, 0x6c, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x72, 0x61, 0x74, 0x69,
0x6f, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73,
0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x16, 0x6d, 0x69, 0x6e, 0x49, 0x6e, 0x69, 0x74,
0x69, 0x61, 0x6c, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x61, 0x74, 0x69, 0x6f, 0x12,
0x55, 0x0a, 0x15, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x63, 0x61, 0x6e, 0x63,
0x65, 0x6c, 0x5f, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x21,
0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4,
0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35,
0x30, 0x52, 0x13, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x43, 0x61, 0x6e, 0x63, 0x65,
0x6c, 0x52, 0x61, 0x74, 0x69, 0x6f, 0x12, 0x5d, 0x0a, 0x14, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73,
0x61, 0x6c, 0x5f, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x5f, 0x64, 0x65, 0x73, 0x74, 0x18, 0x09,
0x20, 0x01, 0x28, 0x09, 0x42, 0x2b, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0xda, 0xb4,
0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35,
0x30, 0x52, 0x12, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x43, 0x61, 0x6e, 0x63, 0x65,
0x6c, 0x44, 0x65, 0x73, 0x74, 0x12, 0x6a, 0x0a, 0x17, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74,
0x65, 0x64, 0x5f, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64,
0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f,
0x6e, 0x42, 0x17, 0x98, 0xdf, 0x1f, 0x01, 0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35, 0x30, 0x52, 0x15, 0x65, 0x78, 0x70, 0x65,
0x64, 0x69, 0x74, 0x65, 0x64, 0x56, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x65, 0x72, 0x69, 0x6f,
0x64, 0x12, 0x52, 0x0a, 0x13, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74, 0x65, 0x64, 0x5f, 0x74,
0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x42, 0x21,
0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4,
0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35,
0x30, 0x52, 0x12, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74, 0x65, 0x64, 0x54, 0x68, 0x72, 0x65,
0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x58, 0x0a, 0x15, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74,
0x65, 0x64, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x0c,
0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61,
0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42,
0x09, 0xc8, 0xde, 0x1f, 0x00, 0xa8, 0xe7, 0xb0, 0x2a, 0x01, 0x52, 0x13, 0x65, 0x78, 0x70, 0x65,
0x64, 0x69, 0x74, 0x65, 0x64, 0x4d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12,
0x3d, 0x0a, 0x10, 0x62, 0x75, 0x72, 0x6e, 0x5f, 0x76, 0x6f, 0x74, 0x65, 0x5f, 0x71, 0x75, 0x6f,
0x72, 0x75, 0x6d, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x42, 0x13, 0xda, 0xb4, 0x2d, 0x0f, 0x63,
0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x34, 0x37, 0x52, 0x0e,
0x62, 0x75, 0x72, 0x6e, 0x56, 0x6f, 0x74, 0x65, 0x51, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, 0x56,
0x0a, 0x1d, 0x62, 0x75, 0x72, 0x6e, 0x5f, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f,
0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x70, 0x72, 0x65, 0x76, 0x6f, 0x74, 0x65, 0x18,
0x0e, 0x20, 0x01, 0x28, 0x08, 0x42, 0x13, 0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x34, 0x37, 0x52, 0x1a, 0x62, 0x75, 0x72, 0x6e,
0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50,
0x72, 0x65, 0x76, 0x6f, 0x74, 0x65, 0x12, 0x39, 0x0a, 0x0e, 0x62, 0x75, 0x72, 0x6e, 0x5f, 0x76,
0x6f, 0x74, 0x65, 0x5f, 0x76, 0x65, 0x74, 0x6f, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x42, 0x13,
0xda, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30,
0x2e, 0x34, 0x37, 0x52, 0x0c, 0x62, 0x75, 0x72, 0x6e, 0x56, 0x6f, 0x74, 0x65, 0x56, 0x65, 0x74,
0x6f, 0x12, 0x4d, 0x0a, 0x11, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74,
0x5f, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x42, 0x21, 0xd2, 0xb4,
0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4, 0x2d, 0x0f,
0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x35, 0x30, 0x52,
0x0f, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x52, 0x61, 0x74, 0x69, 0x6f,
0x12, 0x5b, 0x0a, 0x1a, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x63, 0x61, 0x6e,
0x63, 0x65, 0x6c, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x11,
0x20, 0x01, 0x28, 0x09, 0x42, 0x1e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x30,
0x2e, 0x32, 0x2e, 0x30, 0x52, 0x17, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x43, 0x61,
0x6e, 0x63, 0x65, 0x6c, 0x4d, 0x61, 0x78, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12, 0x70, 0x0a,
0x1f, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x5f, 0x61, 0x75, 0x74, 0x68,
0x6f, 0x72, 0x69, 0x7a, 0x65, 0x64, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73,
0x18, 0x12, 0x20, 0x03, 0x28, 0x09, 0x42, 0x28, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d,
0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67,
0xda, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x30, 0x2e, 0x32, 0x2e, 0x30,
0x52, 0x1d, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x41, 0x75, 0x74, 0x68,
0x6f, 0x72, 0x69, 0x7a, 0x65, 0x64, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x65, 0x73, 0x12,
0x62, 0x0a, 0x1d, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74, 0x69, 0x63, 0x5f, 0x72, 0x65,
0x6a, 0x65, 0x63, 0x74, 0x65, 0x64, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64,
0x18, 0x13, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d,
0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20,
0x76, 0x30, 0x2e, 0x32, 0x2e, 0x30, 0x52, 0x1b, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x73, 0x74,
0x69, 0x63, 0x52, 0x65, 0x6a, 0x65, 0x63, 0x74, 0x65, 0x64, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68,
0x6f, 0x6c, 0x64, 0x12, 0x3d, 0x0a, 0x0a, 0x79, 0x65, 0x73, 0x5f, 0x71, 0x75, 0x6f, 0x72, 0x75,
0x6d, 0x18, 0x14, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73,
0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76,
0x20, 0x76, 0x30, 0x2e, 0x32, 0x2e, 0x30, 0x52, 0x09, 0x79, 0x65, 0x73, 0x51, 0x75, 0x6f, 0x72,
0x75, 0x6d, 0x12, 0x49, 0x0a, 0x10, 0x65, 0x78, 0x70, 0x65, 0x64, 0x69, 0x74, 0x65, 0x64, 0x5f,
0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x18, 0x15, 0x20, 0x01, 0x28, 0x09, 0x42, 0x1e, 0xd2, 0xb4,
0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0xda, 0xb4, 0x2d, 0x0c,
0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x31, 0x2e, 0x30, 0x2e, 0x30, 0x52, 0x0f, 0x65, 0x78,
0x70, 0x65, 0x64, 0x69, 0x74, 0x65, 0x64, 0x51, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, 0x46, 0x0a,
0x16, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74,
0x69, 0x6f, 0x6e, 0x5f, 0x67, 0x61, 0x73, 0x18, 0x16, 0x20, 0x01, 0x28, 0x04, 0x42, 0x10, 0xda,
0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76, 0x30, 0x2e, 0x32, 0x2e, 0x30, 0x52,
0x14, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x69,
0x6f, 0x6e, 0x47, 0x61, 0x73, 0x3a, 0x13, 0xd2, 0xb4, 0x2d, 0x0f, 0x63, 0x6f, 0x73, 0x6d, 0x6f,
0x73, 0x2d, 0x73, 0x64, 0x6b, 0x20, 0x30, 0x2e, 0x34, 0x37, 0x22, 0xa8, 0x02, 0x0a, 0x12, 0x4d,
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x42, 0x61, 0x73, 0x65, 0x64, 0x50, 0x61, 0x72, 0x61, 0x6d,
0x73, 0x12, 0x44, 0x0a, 0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69,
0x6f, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c,
0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74,
0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x0c, 0x76, 0x6f, 0x74, 0x69, 0x6e,
0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x12, 0x26, 0x0a, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75,
0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73,
0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12,
0x2d, 0x0a, 0x0a, 0x79, 0x65, 0x73, 0x5f, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x18, 0x14, 0x20,
0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e,
0x44, 0x65, 0x63, 0x52, 0x09, 0x79, 0x65, 0x73, 0x51, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, 0x2c,
0x0a, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28,
0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65,
0x63, 0x52, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x35, 0x0a, 0x0e,
0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x04,
0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x2e, 0x44, 0x65, 0x63, 0x52, 0x0d, 0x76, 0x65, 0x74, 0x6f, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68,
0x6f, 0x6c, 0x64, 0x3a, 0x10, 0xd2, 0xb4, 0x2d, 0x0c, 0x78, 0x2f, 0x67, 0x6f, 0x76, 0x20, 0x76,
0x30, 0x2e, 0x32, 0x2e, 0x30, 0x2a, 0xa7, 0x01, 0x0a, 0x0c, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73,
0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1d, 0x0a, 0x19, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53,
0x41, 0x4c, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46,
0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41,
0x4c, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x54, 0x41, 0x4e, 0x44, 0x41, 0x52, 0x44, 0x10,
0x01, 0x12, 0x21, 0x0a, 0x1d, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x54, 0x59,
0x50, 0x45, 0x5f, 0x4d, 0x55, 0x4c, 0x54, 0x49, 0x50, 0x4c, 0x45, 0x5f, 0x43, 0x48, 0x4f, 0x49,
0x43, 0x45, 0x10, 0x02, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c,
0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4d, 0x49, 0x53, 0x54, 0x49, 0x43,
0x10, 0x03, 0x12, 0x1b, 0x0a, 0x17, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x54,
0x59, 0x50, 0x45, 0x5f, 0x45, 0x58, 0x50, 0x45, 0x44, 0x49, 0x54, 0x45, 0x44, 0x10, 0x04, 0x2a,
0xfa, 0x01, 0x0a, 0x0a, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b,
0x0a, 0x17, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e,
0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x56,
0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x59, 0x45, 0x53, 0x10, 0x01,
0x12, 0x13, 0x0a, 0x0f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f,
0x4f, 0x4e, 0x45, 0x10, 0x01, 0x12, 0x17, 0x0a, 0x13, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50,
0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x41, 0x42, 0x53, 0x54, 0x41, 0x49, 0x4e, 0x10, 0x02, 0x12, 0x13,
0x0a, 0x0f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x57,
0x4f, 0x10, 0x02, 0x12, 0x12, 0x0a, 0x0e, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49,
0x4f, 0x4e, 0x5f, 0x4e, 0x4f, 0x10, 0x03, 0x12, 0x15, 0x0a, 0x11, 0x56, 0x4f, 0x54, 0x45, 0x5f,
0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x48, 0x52, 0x45, 0x45, 0x10, 0x03, 0x12, 0x1c,
0x0a, 0x18, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4e, 0x4f,
0x5f, 0x57, 0x49, 0x54, 0x48, 0x5f, 0x56, 0x45, 0x54, 0x4f, 0x10, 0x04, 0x12, 0x14, 0x0a, 0x10,
0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x46, 0x4f, 0x55, 0x52,
0x10, 0x04, 0x12, 0x14, 0x0a, 0x10, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f,
0x4e, 0x5f, 0x53, 0x50, 0x41, 0x4d, 0x10, 0x05, 0x1a, 0x02, 0x10, 0x01, 0x2a, 0xce, 0x01, 0x0a,
0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12,
0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54,
0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00,
0x12, 0x22, 0x0a, 0x1e, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41,
0x54, 0x55, 0x53, 0x5f, 0x44, 0x45, 0x50, 0x4f, 0x53, 0x49, 0x54, 0x5f, 0x50, 0x45, 0x52, 0x49,
0x4f, 0x44, 0x10, 0x01, 0x12, 0x21, 0x0a, 0x1d, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c,
0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x56, 0x4f, 0x54, 0x49, 0x4e, 0x47, 0x5f, 0x50,
0x45, 0x52, 0x49, 0x4f, 0x44, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f,
0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x50, 0x41, 0x53, 0x53, 0x45,
0x44, 0x10, 0x03, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f,
0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, 0x54, 0x45, 0x44, 0x10,
0x04, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54,
0x41, 0x54, 0x55, 0x53, 0x5f, 0x46, 0x41, 0x49, 0x4c, 0x45, 0x44, 0x10, 0x05, 0x42, 0x99, 0x01,
0x0a, 0x11, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76,
0x2e, 0x76, 0x31, 0x42, 0x08, 0x47, 0x6f, 0x76, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a,
0x24, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70,
0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, 0x6f, 0x76, 0x2f, 0x76, 0x31, 0x3b,
0x67, 0x6f, 0x76, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x0d, 0x43, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x6f, 0x76, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0d, 0x43, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x6f, 0x76, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x19, 0x43, 0x6f,
0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x6f, 0x76, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d,
0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73,
0x3a, 0x3a, 0x47, 0x6f, 0x76, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x33,
}
var (
file_cosmos_gov_v1_gov_proto_rawDescOnce sync.Once
file_cosmos_gov_v1_gov_proto_rawDescData = file_cosmos_gov_v1_gov_proto_rawDesc
)
func file_cosmos_gov_v1_gov_proto_rawDescGZIP() []byte {
file_cosmos_gov_v1_gov_proto_rawDescOnce.Do(func() {
file_cosmos_gov_v1_gov_proto_rawDescData = protoimpl.X.CompressGZIP(file_cosmos_gov_v1_gov_proto_rawDescData)
})
return file_cosmos_gov_v1_gov_proto_rawDescData
}
var file_cosmos_gov_v1_gov_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
var file_cosmos_gov_v1_gov_proto_msgTypes = make([]protoimpl.MessageInfo, 11)
var file_cosmos_gov_v1_gov_proto_goTypes = []interface{}{
(ProposalType)(0), // 0: cosmos.gov.v1.ProposalType
(VoteOption)(0), // 1: cosmos.gov.v1.VoteOption
(ProposalStatus)(0), // 2: cosmos.gov.v1.ProposalStatus
(*WeightedVoteOption)(nil), // 3: cosmos.gov.v1.WeightedVoteOption
(*Deposit)(nil), // 4: cosmos.gov.v1.Deposit
(*Proposal)(nil), // 5: cosmos.gov.v1.Proposal
(*ProposalVoteOptions)(nil), // 6: cosmos.gov.v1.ProposalVoteOptions
(*TallyResult)(nil), // 7: cosmos.gov.v1.TallyResult
(*Vote)(nil), // 8: cosmos.gov.v1.Vote
(*DepositParams)(nil), // 9: cosmos.gov.v1.DepositParams
(*VotingParams)(nil), // 10: cosmos.gov.v1.VotingParams
(*TallyParams)(nil), // 11: cosmos.gov.v1.TallyParams
(*Params)(nil), // 12: cosmos.gov.v1.Params
(*MessageBasedParams)(nil), // 13: cosmos.gov.v1.MessageBasedParams
(*v1beta1.Coin)(nil), // 14: cosmos.base.v1beta1.Coin
(*anypb.Any)(nil), // 15: google.protobuf.Any
(*timestamppb.Timestamp)(nil), // 16: google.protobuf.Timestamp
(*durationpb.Duration)(nil), // 17: google.protobuf.Duration
}
var file_cosmos_gov_v1_gov_proto_depIdxs = []int32{
1, // 0: cosmos.gov.v1.WeightedVoteOption.option:type_name -> cosmos.gov.v1.VoteOption
14, // 1: cosmos.gov.v1.Deposit.amount:type_name -> cosmos.base.v1beta1.Coin
15, // 2: cosmos.gov.v1.Proposal.messages:type_name -> google.protobuf.Any
2, // 3: cosmos.gov.v1.Proposal.status:type_name -> cosmos.gov.v1.ProposalStatus
7, // 4: cosmos.gov.v1.Proposal.final_tally_result:type_name -> cosmos.gov.v1.TallyResult
16, // 5: cosmos.gov.v1.Proposal.submit_time:type_name -> google.protobuf.Timestamp
16, // 6: cosmos.gov.v1.Proposal.deposit_end_time:type_name -> google.protobuf.Timestamp
14, // 7: cosmos.gov.v1.Proposal.total_deposit:type_name -> cosmos.base.v1beta1.Coin
16, // 8: cosmos.gov.v1.Proposal.voting_start_time:type_name -> google.protobuf.Timestamp
16, // 9: cosmos.gov.v1.Proposal.voting_end_time:type_name -> google.protobuf.Timestamp
0, // 10: cosmos.gov.v1.Proposal.proposal_type:type_name -> cosmos.gov.v1.ProposalType
3, // 11: cosmos.gov.v1.Vote.options:type_name -> cosmos.gov.v1.WeightedVoteOption
14, // 12: cosmos.gov.v1.DepositParams.min_deposit:type_name -> cosmos.base.v1beta1.Coin
17, // 13: cosmos.gov.v1.DepositParams.max_deposit_period:type_name -> google.protobuf.Duration
17, // 14: cosmos.gov.v1.VotingParams.voting_period:type_name -> google.protobuf.Duration
14, // 15: cosmos.gov.v1.Params.min_deposit:type_name -> cosmos.base.v1beta1.Coin
17, // 16: cosmos.gov.v1.Params.max_deposit_period:type_name -> google.protobuf.Duration
17, // 17: cosmos.gov.v1.Params.voting_period:type_name -> google.protobuf.Duration
17, // 18: cosmos.gov.v1.Params.expedited_voting_period:type_name -> google.protobuf.Duration
14, // 19: cosmos.gov.v1.Params.expedited_min_deposit:type_name -> cosmos.base.v1beta1.Coin
17, // 20: cosmos.gov.v1.MessageBasedParams.voting_period:type_name -> google.protobuf.Duration
21, // [21:21] is the sub-list for method output_type
21, // [21:21] is the sub-list for method input_type
21, // [21:21] is the sub-list for extension type_name
21, // [21:21] is the sub-list for extension extendee
0, // [0:21] is the sub-list for field type_name
}
func init() { file_cosmos_gov_v1_gov_proto_init() }
func file_cosmos_gov_v1_gov_proto_init() {
if File_cosmos_gov_v1_gov_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_cosmos_gov_v1_gov_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*WeightedVoteOption); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Deposit); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Proposal); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*ProposalVoteOptions); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*TallyResult); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Vote); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*DepositParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*VotingParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*TallyParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*Params); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_cosmos_gov_v1_gov_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*MessageBasedParams); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_cosmos_gov_v1_gov_proto_rawDesc,
NumEnums: 3,
NumMessages: 11,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_cosmos_gov_v1_gov_proto_goTypes,
DependencyIndexes: file_cosmos_gov_v1_gov_proto_depIdxs,
EnumInfos: file_cosmos_gov_v1_gov_proto_enumTypes,
MessageInfos: file_cosmos_gov_v1_gov_proto_msgTypes,
}.Build()
File_cosmos_gov_v1_gov_proto = out.File
file_cosmos_gov_v1_gov_proto_rawDesc = nil
file_cosmos_gov_v1_gov_proto_goTypes = nil
file_cosmos_gov_v1_gov_proto_depIdxs = nil
}