github.com/Finschia/finschia-sdk@v0.48.1/x/stakingplus/authz.pb.go (about) 1 // Code generated by protoc-gen-gogo. DO NOT EDIT. 2 // source: lbm/stakingplus/v1/authz.proto 3 4 package stakingplus 5 6 import ( 7 fmt "fmt" 8 _ "github.com/gogo/protobuf/gogoproto" 9 proto "github.com/gogo/protobuf/proto" 10 _ "github.com/regen-network/cosmos-proto" 11 io "io" 12 math "math" 13 math_bits "math/bits" 14 ) 15 16 // Reference imports to suppress errors if they are not otherwise used. 17 var _ = proto.Marshal 18 var _ = fmt.Errorf 19 var _ = math.Inf 20 21 // This is a compile-time assertion to ensure that this generated file 22 // is compatible with the proto package it is being compiled against. 23 // A compilation error at this line likely means your copy of the 24 // proto package needs to be updated. 25 const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package 26 27 // CreateValidatorAuthorization allows the grantee to create a new validator. 28 type CreateValidatorAuthorization struct { 29 // redundant, but good for the query. 30 ValidatorAddress string `protobuf:"bytes,1,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` 31 } 32 33 func (m *CreateValidatorAuthorization) Reset() { *m = CreateValidatorAuthorization{} } 34 func (m *CreateValidatorAuthorization) String() string { return proto.CompactTextString(m) } 35 func (*CreateValidatorAuthorization) ProtoMessage() {} 36 func (*CreateValidatorAuthorization) Descriptor() ([]byte, []int) { 37 return fileDescriptor_85cae299ee13354e, []int{0} 38 } 39 func (m *CreateValidatorAuthorization) XXX_Unmarshal(b []byte) error { 40 return m.Unmarshal(b) 41 } 42 func (m *CreateValidatorAuthorization) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { 43 if deterministic { 44 return xxx_messageInfo_CreateValidatorAuthorization.Marshal(b, m, deterministic) 45 } else { 46 b = b[:cap(b)] 47 n, err := m.MarshalToSizedBuffer(b) 48 if err != nil { 49 return nil, err 50 } 51 return b[:n], nil 52 } 53 } 54 func (m *CreateValidatorAuthorization) XXX_Merge(src proto.Message) { 55 xxx_messageInfo_CreateValidatorAuthorization.Merge(m, src) 56 } 57 func (m *CreateValidatorAuthorization) XXX_Size() int { 58 return m.Size() 59 } 60 func (m *CreateValidatorAuthorization) XXX_DiscardUnknown() { 61 xxx_messageInfo_CreateValidatorAuthorization.DiscardUnknown(m) 62 } 63 64 var xxx_messageInfo_CreateValidatorAuthorization proto.InternalMessageInfo 65 66 func (m *CreateValidatorAuthorization) GetValidatorAddress() string { 67 if m != nil { 68 return m.ValidatorAddress 69 } 70 return "" 71 } 72 73 func init() { 74 proto.RegisterType((*CreateValidatorAuthorization)(nil), "lbm.stakingplus.v1.CreateValidatorAuthorization") 75 } 76 77 func init() { proto.RegisterFile("lbm/stakingplus/v1/authz.proto", fileDescriptor_85cae299ee13354e) } 78 79 var fileDescriptor_85cae299ee13354e = []byte{ 80 // 241 bytes of a gzipped FileDescriptorProto 81 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xcb, 0x49, 0xca, 0xd5, 82 0x2f, 0x2e, 0x49, 0xcc, 0xce, 0xcc, 0x4b, 0x2f, 0xc8, 0x29, 0x2d, 0xd6, 0x2f, 0x33, 0xd4, 0x4f, 83 0x2c, 0x2d, 0xc9, 0xa8, 0xd2, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0xca, 0x49, 0xca, 0xd5, 84 0x43, 0x92, 0xd7, 0x2b, 0x33, 0x94, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x4b, 0xeb, 0x83, 0x58, 85 0x10, 0x95, 0x52, 0x92, 0xc9, 0xf9, 0xc5, 0xb9, 0xf9, 0xc5, 0xf1, 0x10, 0x09, 0x08, 0x07, 0x22, 86 0xa5, 0xd4, 0xc3, 0xc8, 0x25, 0xe3, 0x5c, 0x94, 0x9a, 0x58, 0x92, 0x1a, 0x96, 0x98, 0x93, 0x99, 87 0x92, 0x58, 0x92, 0x5f, 0xe4, 0x58, 0x5a, 0x92, 0x91, 0x5f, 0x94, 0x59, 0x95, 0x58, 0x92, 0x99, 88 0x9f, 0x27, 0xa4, 0xcd, 0x25, 0x58, 0x06, 0x93, 0x89, 0x4f, 0x4c, 0x49, 0x29, 0x4a, 0x2d, 0x2e, 89 0x96, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x0c, 0x12, 0x80, 0x4b, 0x38, 0x42, 0xc4, 0xad, 0xec, 0x2f, 90 0x6d, 0xd1, 0xb5, 0x4e, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x77, 0xcb, 91 0xcc, 0x2b, 0x4e, 0xce, 0xc8, 0x4c, 0xd4, 0x4f, 0x83, 0x32, 0x74, 0x8b, 0x53, 0xb2, 0xf5, 0x2b, 92 0xf4, 0xd3, 0xf2, 0x4b, 0xf3, 0x52, 0xc0, 0xe6, 0xeb, 0xa1, 0xd8, 0xe6, 0xe4, 0x71, 0xe2, 0x91, 93 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, 94 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0x7a, 0x44, 0x18, 0x8b, 0x14, 0x18, 0x49, 0x6c, 95 0x60, 0xff, 0x19, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0x10, 0x9b, 0x46, 0xf1, 0x46, 0x01, 0x00, 96 0x00, 97 } 98 99 func (m *CreateValidatorAuthorization) Marshal() (dAtA []byte, err error) { 100 size := m.Size() 101 dAtA = make([]byte, size) 102 n, err := m.MarshalToSizedBuffer(dAtA[:size]) 103 if err != nil { 104 return nil, err 105 } 106 return dAtA[:n], nil 107 } 108 109 func (m *CreateValidatorAuthorization) MarshalTo(dAtA []byte) (int, error) { 110 size := m.Size() 111 return m.MarshalToSizedBuffer(dAtA[:size]) 112 } 113 114 func (m *CreateValidatorAuthorization) MarshalToSizedBuffer(dAtA []byte) (int, error) { 115 i := len(dAtA) 116 _ = i 117 var l int 118 _ = l 119 if len(m.ValidatorAddress) > 0 { 120 i -= len(m.ValidatorAddress) 121 copy(dAtA[i:], m.ValidatorAddress) 122 i = encodeVarintAuthz(dAtA, i, uint64(len(m.ValidatorAddress))) 123 i-- 124 dAtA[i] = 0xa 125 } 126 return len(dAtA) - i, nil 127 } 128 129 func encodeVarintAuthz(dAtA []byte, offset int, v uint64) int { 130 offset -= sovAuthz(v) 131 base := offset 132 for v >= 1<<7 { 133 dAtA[offset] = uint8(v&0x7f | 0x80) 134 v >>= 7 135 offset++ 136 } 137 dAtA[offset] = uint8(v) 138 return base 139 } 140 func (m *CreateValidatorAuthorization) Size() (n int) { 141 if m == nil { 142 return 0 143 } 144 var l int 145 _ = l 146 l = len(m.ValidatorAddress) 147 if l > 0 { 148 n += 1 + l + sovAuthz(uint64(l)) 149 } 150 return n 151 } 152 153 func sovAuthz(x uint64) (n int) { 154 return (math_bits.Len64(x|1) + 6) / 7 155 } 156 func sozAuthz(x uint64) (n int) { 157 return sovAuthz(uint64((x << 1) ^ uint64((int64(x) >> 63)))) 158 } 159 func (m *CreateValidatorAuthorization) Unmarshal(dAtA []byte) error { 160 l := len(dAtA) 161 iNdEx := 0 162 for iNdEx < l { 163 preIndex := iNdEx 164 var wire uint64 165 for shift := uint(0); ; shift += 7 { 166 if shift >= 64 { 167 return ErrIntOverflowAuthz 168 } 169 if iNdEx >= l { 170 return io.ErrUnexpectedEOF 171 } 172 b := dAtA[iNdEx] 173 iNdEx++ 174 wire |= uint64(b&0x7F) << shift 175 if b < 0x80 { 176 break 177 } 178 } 179 fieldNum := int32(wire >> 3) 180 wireType := int(wire & 0x7) 181 if wireType == 4 { 182 return fmt.Errorf("proto: CreateValidatorAuthorization: wiretype end group for non-group") 183 } 184 if fieldNum <= 0 { 185 return fmt.Errorf("proto: CreateValidatorAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) 186 } 187 switch fieldNum { 188 case 1: 189 if wireType != 2 { 190 return fmt.Errorf("proto: wrong wireType = %d for field ValidatorAddress", wireType) 191 } 192 var stringLen uint64 193 for shift := uint(0); ; shift += 7 { 194 if shift >= 64 { 195 return ErrIntOverflowAuthz 196 } 197 if iNdEx >= l { 198 return io.ErrUnexpectedEOF 199 } 200 b := dAtA[iNdEx] 201 iNdEx++ 202 stringLen |= uint64(b&0x7F) << shift 203 if b < 0x80 { 204 break 205 } 206 } 207 intStringLen := int(stringLen) 208 if intStringLen < 0 { 209 return ErrInvalidLengthAuthz 210 } 211 postIndex := iNdEx + intStringLen 212 if postIndex < 0 { 213 return ErrInvalidLengthAuthz 214 } 215 if postIndex > l { 216 return io.ErrUnexpectedEOF 217 } 218 m.ValidatorAddress = string(dAtA[iNdEx:postIndex]) 219 iNdEx = postIndex 220 default: 221 iNdEx = preIndex 222 skippy, err := skipAuthz(dAtA[iNdEx:]) 223 if err != nil { 224 return err 225 } 226 if (skippy < 0) || (iNdEx+skippy) < 0 { 227 return ErrInvalidLengthAuthz 228 } 229 if (iNdEx + skippy) > l { 230 return io.ErrUnexpectedEOF 231 } 232 iNdEx += skippy 233 } 234 } 235 236 if iNdEx > l { 237 return io.ErrUnexpectedEOF 238 } 239 return nil 240 } 241 func skipAuthz(dAtA []byte) (n int, err error) { 242 l := len(dAtA) 243 iNdEx := 0 244 depth := 0 245 for iNdEx < l { 246 var wire uint64 247 for shift := uint(0); ; shift += 7 { 248 if shift >= 64 { 249 return 0, ErrIntOverflowAuthz 250 } 251 if iNdEx >= l { 252 return 0, io.ErrUnexpectedEOF 253 } 254 b := dAtA[iNdEx] 255 iNdEx++ 256 wire |= (uint64(b) & 0x7F) << shift 257 if b < 0x80 { 258 break 259 } 260 } 261 wireType := int(wire & 0x7) 262 switch wireType { 263 case 0: 264 for shift := uint(0); ; shift += 7 { 265 if shift >= 64 { 266 return 0, ErrIntOverflowAuthz 267 } 268 if iNdEx >= l { 269 return 0, io.ErrUnexpectedEOF 270 } 271 iNdEx++ 272 if dAtA[iNdEx-1] < 0x80 { 273 break 274 } 275 } 276 case 1: 277 iNdEx += 8 278 case 2: 279 var length int 280 for shift := uint(0); ; shift += 7 { 281 if shift >= 64 { 282 return 0, ErrIntOverflowAuthz 283 } 284 if iNdEx >= l { 285 return 0, io.ErrUnexpectedEOF 286 } 287 b := dAtA[iNdEx] 288 iNdEx++ 289 length |= (int(b) & 0x7F) << shift 290 if b < 0x80 { 291 break 292 } 293 } 294 if length < 0 { 295 return 0, ErrInvalidLengthAuthz 296 } 297 iNdEx += length 298 case 3: 299 depth++ 300 case 4: 301 if depth == 0 { 302 return 0, ErrUnexpectedEndOfGroupAuthz 303 } 304 depth-- 305 case 5: 306 iNdEx += 4 307 default: 308 return 0, fmt.Errorf("proto: illegal wireType %d", wireType) 309 } 310 if iNdEx < 0 { 311 return 0, ErrInvalidLengthAuthz 312 } 313 if depth == 0 { 314 return iNdEx, nil 315 } 316 } 317 return 0, io.ErrUnexpectedEOF 318 } 319 320 var ( 321 ErrInvalidLengthAuthz = fmt.Errorf("proto: negative length found during unmarshaling") 322 ErrIntOverflowAuthz = fmt.Errorf("proto: integer overflow") 323 ErrUnexpectedEndOfGroupAuthz = fmt.Errorf("proto: unexpected end of group") 324 )