You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1833 lines
46 KiB

  1. // Code generated by protoc-gen-gogo. DO NOT EDIT.
  2. // source: tendermint/state/types.proto
  3. package state
  4. import (
  5. fmt "fmt"
  6. _ "github.com/gogo/protobuf/gogoproto"
  7. proto "github.com/gogo/protobuf/proto"
  8. _ "github.com/gogo/protobuf/types"
  9. github_com_gogo_protobuf_types "github.com/gogo/protobuf/types"
  10. types "github.com/tendermint/tendermint/abci/types"
  11. types1 "github.com/tendermint/tendermint/proto/tendermint/types"
  12. version "github.com/tendermint/tendermint/proto/tendermint/version"
  13. io "io"
  14. math "math"
  15. math_bits "math/bits"
  16. time "time"
  17. )
  18. // Reference imports to suppress errors if they are not otherwise used.
  19. var _ = proto.Marshal
  20. var _ = fmt.Errorf
  21. var _ = math.Inf
  22. var _ = time.Kitchen
  23. // This is a compile-time assertion to ensure that this generated file
  24. // is compatible with the proto package it is being compiled against.
  25. // A compilation error at this line likely means your copy of the
  26. // proto package needs to be updated.
  27. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
  28. // ABCIResponses retains the responses
  29. // of the various ABCI calls during block processing.
  30. // It is persisted to disk for each height before calling Commit.
  31. type ABCIResponses struct {
  32. FinalizeBlock *types.ResponseFinalizeBlock `protobuf:"bytes,2,opt,name=finalize_block,json=finalizeBlock,proto3" json:"finalize_block,omitempty"`
  33. }
  34. func (m *ABCIResponses) Reset() { *m = ABCIResponses{} }
  35. func (m *ABCIResponses) String() string { return proto.CompactTextString(m) }
  36. func (*ABCIResponses) ProtoMessage() {}
  37. func (*ABCIResponses) Descriptor() ([]byte, []int) {
  38. return fileDescriptor_ccfacf933f22bf93, []int{0}
  39. }
  40. func (m *ABCIResponses) XXX_Unmarshal(b []byte) error {
  41. return m.Unmarshal(b)
  42. }
  43. func (m *ABCIResponses) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  44. if deterministic {
  45. return xxx_messageInfo_ABCIResponses.Marshal(b, m, deterministic)
  46. } else {
  47. b = b[:cap(b)]
  48. n, err := m.MarshalToSizedBuffer(b)
  49. if err != nil {
  50. return nil, err
  51. }
  52. return b[:n], nil
  53. }
  54. }
  55. func (m *ABCIResponses) XXX_Merge(src proto.Message) {
  56. xxx_messageInfo_ABCIResponses.Merge(m, src)
  57. }
  58. func (m *ABCIResponses) XXX_Size() int {
  59. return m.Size()
  60. }
  61. func (m *ABCIResponses) XXX_DiscardUnknown() {
  62. xxx_messageInfo_ABCIResponses.DiscardUnknown(m)
  63. }
  64. var xxx_messageInfo_ABCIResponses proto.InternalMessageInfo
  65. func (m *ABCIResponses) GetFinalizeBlock() *types.ResponseFinalizeBlock {
  66. if m != nil {
  67. return m.FinalizeBlock
  68. }
  69. return nil
  70. }
  71. // ValidatorsInfo represents the latest validator set, or the last height it changed
  72. type ValidatorsInfo struct {
  73. ValidatorSet *types1.ValidatorSet `protobuf:"bytes,1,opt,name=validator_set,json=validatorSet,proto3" json:"validator_set,omitempty"`
  74. LastHeightChanged int64 `protobuf:"varint,2,opt,name=last_height_changed,json=lastHeightChanged,proto3" json:"last_height_changed,omitempty"`
  75. }
  76. func (m *ValidatorsInfo) Reset() { *m = ValidatorsInfo{} }
  77. func (m *ValidatorsInfo) String() string { return proto.CompactTextString(m) }
  78. func (*ValidatorsInfo) ProtoMessage() {}
  79. func (*ValidatorsInfo) Descriptor() ([]byte, []int) {
  80. return fileDescriptor_ccfacf933f22bf93, []int{1}
  81. }
  82. func (m *ValidatorsInfo) XXX_Unmarshal(b []byte) error {
  83. return m.Unmarshal(b)
  84. }
  85. func (m *ValidatorsInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  86. if deterministic {
  87. return xxx_messageInfo_ValidatorsInfo.Marshal(b, m, deterministic)
  88. } else {
  89. b = b[:cap(b)]
  90. n, err := m.MarshalToSizedBuffer(b)
  91. if err != nil {
  92. return nil, err
  93. }
  94. return b[:n], nil
  95. }
  96. }
  97. func (m *ValidatorsInfo) XXX_Merge(src proto.Message) {
  98. xxx_messageInfo_ValidatorsInfo.Merge(m, src)
  99. }
  100. func (m *ValidatorsInfo) XXX_Size() int {
  101. return m.Size()
  102. }
  103. func (m *ValidatorsInfo) XXX_DiscardUnknown() {
  104. xxx_messageInfo_ValidatorsInfo.DiscardUnknown(m)
  105. }
  106. var xxx_messageInfo_ValidatorsInfo proto.InternalMessageInfo
  107. func (m *ValidatorsInfo) GetValidatorSet() *types1.ValidatorSet {
  108. if m != nil {
  109. return m.ValidatorSet
  110. }
  111. return nil
  112. }
  113. func (m *ValidatorsInfo) GetLastHeightChanged() int64 {
  114. if m != nil {
  115. return m.LastHeightChanged
  116. }
  117. return 0
  118. }
  119. // ConsensusParamsInfo represents the latest consensus params, or the last height it changed
  120. type ConsensusParamsInfo struct {
  121. ConsensusParams types1.ConsensusParams `protobuf:"bytes,1,opt,name=consensus_params,json=consensusParams,proto3" json:"consensus_params"`
  122. LastHeightChanged int64 `protobuf:"varint,2,opt,name=last_height_changed,json=lastHeightChanged,proto3" json:"last_height_changed,omitempty"`
  123. }
  124. func (m *ConsensusParamsInfo) Reset() { *m = ConsensusParamsInfo{} }
  125. func (m *ConsensusParamsInfo) String() string { return proto.CompactTextString(m) }
  126. func (*ConsensusParamsInfo) ProtoMessage() {}
  127. func (*ConsensusParamsInfo) Descriptor() ([]byte, []int) {
  128. return fileDescriptor_ccfacf933f22bf93, []int{2}
  129. }
  130. func (m *ConsensusParamsInfo) XXX_Unmarshal(b []byte) error {
  131. return m.Unmarshal(b)
  132. }
  133. func (m *ConsensusParamsInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  134. if deterministic {
  135. return xxx_messageInfo_ConsensusParamsInfo.Marshal(b, m, deterministic)
  136. } else {
  137. b = b[:cap(b)]
  138. n, err := m.MarshalToSizedBuffer(b)
  139. if err != nil {
  140. return nil, err
  141. }
  142. return b[:n], nil
  143. }
  144. }
  145. func (m *ConsensusParamsInfo) XXX_Merge(src proto.Message) {
  146. xxx_messageInfo_ConsensusParamsInfo.Merge(m, src)
  147. }
  148. func (m *ConsensusParamsInfo) XXX_Size() int {
  149. return m.Size()
  150. }
  151. func (m *ConsensusParamsInfo) XXX_DiscardUnknown() {
  152. xxx_messageInfo_ConsensusParamsInfo.DiscardUnknown(m)
  153. }
  154. var xxx_messageInfo_ConsensusParamsInfo proto.InternalMessageInfo
  155. func (m *ConsensusParamsInfo) GetConsensusParams() types1.ConsensusParams {
  156. if m != nil {
  157. return m.ConsensusParams
  158. }
  159. return types1.ConsensusParams{}
  160. }
  161. func (m *ConsensusParamsInfo) GetLastHeightChanged() int64 {
  162. if m != nil {
  163. return m.LastHeightChanged
  164. }
  165. return 0
  166. }
  167. type Version struct {
  168. Consensus version.Consensus `protobuf:"bytes,1,opt,name=consensus,proto3" json:"consensus"`
  169. Software string `protobuf:"bytes,2,opt,name=software,proto3" json:"software,omitempty"`
  170. }
  171. func (m *Version) Reset() { *m = Version{} }
  172. func (m *Version) String() string { return proto.CompactTextString(m) }
  173. func (*Version) ProtoMessage() {}
  174. func (*Version) Descriptor() ([]byte, []int) {
  175. return fileDescriptor_ccfacf933f22bf93, []int{3}
  176. }
  177. func (m *Version) XXX_Unmarshal(b []byte) error {
  178. return m.Unmarshal(b)
  179. }
  180. func (m *Version) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  181. if deterministic {
  182. return xxx_messageInfo_Version.Marshal(b, m, deterministic)
  183. } else {
  184. b = b[:cap(b)]
  185. n, err := m.MarshalToSizedBuffer(b)
  186. if err != nil {
  187. return nil, err
  188. }
  189. return b[:n], nil
  190. }
  191. }
  192. func (m *Version) XXX_Merge(src proto.Message) {
  193. xxx_messageInfo_Version.Merge(m, src)
  194. }
  195. func (m *Version) XXX_Size() int {
  196. return m.Size()
  197. }
  198. func (m *Version) XXX_DiscardUnknown() {
  199. xxx_messageInfo_Version.DiscardUnknown(m)
  200. }
  201. var xxx_messageInfo_Version proto.InternalMessageInfo
  202. func (m *Version) GetConsensus() version.Consensus {
  203. if m != nil {
  204. return m.Consensus
  205. }
  206. return version.Consensus{}
  207. }
  208. func (m *Version) GetSoftware() string {
  209. if m != nil {
  210. return m.Software
  211. }
  212. return ""
  213. }
  214. type State struct {
  215. Version Version `protobuf:"bytes,1,opt,name=version,proto3" json:"version"`
  216. // immutable
  217. ChainID string `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
  218. InitialHeight int64 `protobuf:"varint,14,opt,name=initial_height,json=initialHeight,proto3" json:"initial_height,omitempty"`
  219. // LastBlockHeight=0 at genesis (ie. block(H=0) does not exist)
  220. LastBlockHeight int64 `protobuf:"varint,3,opt,name=last_block_height,json=lastBlockHeight,proto3" json:"last_block_height,omitempty"`
  221. LastBlockID types1.BlockID `protobuf:"bytes,4,opt,name=last_block_id,json=lastBlockId,proto3" json:"last_block_id"`
  222. LastBlockTime time.Time `protobuf:"bytes,5,opt,name=last_block_time,json=lastBlockTime,proto3,stdtime" json:"last_block_time"`
  223. // LastValidators is used to validate block.LastCommit.
  224. // Validators are persisted to the database separately every time they change,
  225. // so we can query for historical validator sets.
  226. // Note that if s.LastBlockHeight causes a valset change,
  227. // we set s.LastHeightValidatorsChanged = s.LastBlockHeight + 1 + 1
  228. // Extra +1 due to nextValSet delay.
  229. NextValidators *types1.ValidatorSet `protobuf:"bytes,6,opt,name=next_validators,json=nextValidators,proto3" json:"next_validators,omitempty"`
  230. Validators *types1.ValidatorSet `protobuf:"bytes,7,opt,name=validators,proto3" json:"validators,omitempty"`
  231. LastValidators *types1.ValidatorSet `protobuf:"bytes,8,opt,name=last_validators,json=lastValidators,proto3" json:"last_validators,omitempty"`
  232. LastHeightValidatorsChanged int64 `protobuf:"varint,9,opt,name=last_height_validators_changed,json=lastHeightValidatorsChanged,proto3" json:"last_height_validators_changed,omitempty"`
  233. // Consensus parameters used for validating blocks.
  234. // Changes returned by EndBlock and updated after Commit.
  235. ConsensusParams types1.ConsensusParams `protobuf:"bytes,10,opt,name=consensus_params,json=consensusParams,proto3" json:"consensus_params"`
  236. LastHeightConsensusParamsChanged int64 `protobuf:"varint,11,opt,name=last_height_consensus_params_changed,json=lastHeightConsensusParamsChanged,proto3" json:"last_height_consensus_params_changed,omitempty"`
  237. // Merkle root of the results from executing prev block
  238. LastResultsHash []byte `protobuf:"bytes,12,opt,name=last_results_hash,json=lastResultsHash,proto3" json:"last_results_hash,omitempty"`
  239. // the latest AppHash we've received from calling abci.Commit()
  240. AppHash []byte `protobuf:"bytes,13,opt,name=app_hash,json=appHash,proto3" json:"app_hash,omitempty"`
  241. }
  242. func (m *State) Reset() { *m = State{} }
  243. func (m *State) String() string { return proto.CompactTextString(m) }
  244. func (*State) ProtoMessage() {}
  245. func (*State) Descriptor() ([]byte, []int) {
  246. return fileDescriptor_ccfacf933f22bf93, []int{4}
  247. }
  248. func (m *State) XXX_Unmarshal(b []byte) error {
  249. return m.Unmarshal(b)
  250. }
  251. func (m *State) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  252. if deterministic {
  253. return xxx_messageInfo_State.Marshal(b, m, deterministic)
  254. } else {
  255. b = b[:cap(b)]
  256. n, err := m.MarshalToSizedBuffer(b)
  257. if err != nil {
  258. return nil, err
  259. }
  260. return b[:n], nil
  261. }
  262. }
  263. func (m *State) XXX_Merge(src proto.Message) {
  264. xxx_messageInfo_State.Merge(m, src)
  265. }
  266. func (m *State) XXX_Size() int {
  267. return m.Size()
  268. }
  269. func (m *State) XXX_DiscardUnknown() {
  270. xxx_messageInfo_State.DiscardUnknown(m)
  271. }
  272. var xxx_messageInfo_State proto.InternalMessageInfo
  273. func (m *State) GetVersion() Version {
  274. if m != nil {
  275. return m.Version
  276. }
  277. return Version{}
  278. }
  279. func (m *State) GetChainID() string {
  280. if m != nil {
  281. return m.ChainID
  282. }
  283. return ""
  284. }
  285. func (m *State) GetInitialHeight() int64 {
  286. if m != nil {
  287. return m.InitialHeight
  288. }
  289. return 0
  290. }
  291. func (m *State) GetLastBlockHeight() int64 {
  292. if m != nil {
  293. return m.LastBlockHeight
  294. }
  295. return 0
  296. }
  297. func (m *State) GetLastBlockID() types1.BlockID {
  298. if m != nil {
  299. return m.LastBlockID
  300. }
  301. return types1.BlockID{}
  302. }
  303. func (m *State) GetLastBlockTime() time.Time {
  304. if m != nil {
  305. return m.LastBlockTime
  306. }
  307. return time.Time{}
  308. }
  309. func (m *State) GetNextValidators() *types1.ValidatorSet {
  310. if m != nil {
  311. return m.NextValidators
  312. }
  313. return nil
  314. }
  315. func (m *State) GetValidators() *types1.ValidatorSet {
  316. if m != nil {
  317. return m.Validators
  318. }
  319. return nil
  320. }
  321. func (m *State) GetLastValidators() *types1.ValidatorSet {
  322. if m != nil {
  323. return m.LastValidators
  324. }
  325. return nil
  326. }
  327. func (m *State) GetLastHeightValidatorsChanged() int64 {
  328. if m != nil {
  329. return m.LastHeightValidatorsChanged
  330. }
  331. return 0
  332. }
  333. func (m *State) GetConsensusParams() types1.ConsensusParams {
  334. if m != nil {
  335. return m.ConsensusParams
  336. }
  337. return types1.ConsensusParams{}
  338. }
  339. func (m *State) GetLastHeightConsensusParamsChanged() int64 {
  340. if m != nil {
  341. return m.LastHeightConsensusParamsChanged
  342. }
  343. return 0
  344. }
  345. func (m *State) GetLastResultsHash() []byte {
  346. if m != nil {
  347. return m.LastResultsHash
  348. }
  349. return nil
  350. }
  351. func (m *State) GetAppHash() []byte {
  352. if m != nil {
  353. return m.AppHash
  354. }
  355. return nil
  356. }
  357. func init() {
  358. proto.RegisterType((*ABCIResponses)(nil), "tendermint.state.ABCIResponses")
  359. proto.RegisterType((*ValidatorsInfo)(nil), "tendermint.state.ValidatorsInfo")
  360. proto.RegisterType((*ConsensusParamsInfo)(nil), "tendermint.state.ConsensusParamsInfo")
  361. proto.RegisterType((*Version)(nil), "tendermint.state.Version")
  362. proto.RegisterType((*State)(nil), "tendermint.state.State")
  363. }
  364. func init() { proto.RegisterFile("tendermint/state/types.proto", fileDescriptor_ccfacf933f22bf93) }
  365. var fileDescriptor_ccfacf933f22bf93 = []byte{
  366. // 717 bytes of a gzipped FileDescriptorProto
  367. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x4d, 0x6f, 0xd3, 0x4a,
  368. 0x14, 0x8d, 0x5f, 0x3f, 0x92, 0x4c, 0x9a, 0xa4, 0x6f, 0xfa, 0x16, 0x69, 0xfa, 0xea, 0xe4, 0x45,
  369. 0x8f, 0xaa, 0x62, 0xe1, 0x48, 0xb0, 0x40, 0x6c, 0x90, 0x9a, 0x54, 0x50, 0x4b, 0x05, 0x81, 0x8b,
  370. 0xba, 0x60, 0x81, 0x35, 0x71, 0x26, 0xf6, 0x08, 0xc7, 0xb6, 0x3c, 0x93, 0xf2, 0xb1, 0x67, 0xdf,
  371. 0x2d, 0xff, 0xa8, 0xcb, 0x2e, 0x59, 0x15, 0x48, 0xff, 0x08, 0x9a, 0x0f, 0xdb, 0x93, 0x84, 0x45,
  372. 0x11, 0xbb, 0xcc, 0x3d, 0xe7, 0x9e, 0x7b, 0xe6, 0xce, 0xbd, 0x31, 0xf8, 0x97, 0xe1, 0x68, 0x8c,
  373. 0xd3, 0x29, 0x89, 0x58, 0x9f, 0x32, 0xc4, 0x70, 0x9f, 0x7d, 0x4c, 0x30, 0xb5, 0x92, 0x34, 0x66,
  374. 0x31, 0xdc, 0x2e, 0x50, 0x4b, 0xa0, 0xed, 0x7f, 0xfc, 0xd8, 0x8f, 0x05, 0xd8, 0xe7, 0xbf, 0x24,
  375. 0xaf, 0xbd, 0xa7, 0xa9, 0xa0, 0x91, 0x47, 0x74, 0x91, 0xb6, 0x5e, 0x42, 0xc4, 0x17, 0xd0, 0xee,
  376. 0x0a, 0x7a, 0x81, 0x42, 0x32, 0x46, 0x2c, 0x4e, 0x15, 0x63, 0x7f, 0x85, 0x91, 0xa0, 0x14, 0x4d,
  377. 0x33, 0x01, 0x53, 0x83, 0x2f, 0x70, 0x4a, 0x49, 0x1c, 0x2d, 0x14, 0xe8, 0xf8, 0x71, 0xec, 0x87,
  378. 0xb8, 0x2f, 0x4e, 0xa3, 0xd9, 0xa4, 0xcf, 0xc8, 0x14, 0x53, 0x86, 0xa6, 0x89, 0x24, 0xf4, 0xde,
  379. 0x82, 0xfa, 0xd1, 0x60, 0x68, 0x3b, 0x98, 0x26, 0x71, 0x44, 0x31, 0x85, 0xcf, 0x41, 0x63, 0x42,
  380. 0x22, 0x14, 0x92, 0x4f, 0xd8, 0x1d, 0x85, 0xb1, 0xf7, 0xae, 0xf5, 0x57, 0xd7, 0x38, 0xac, 0x3d,
  381. 0x38, 0xb0, 0xb4, 0x76, 0xf0, 0x6b, 0x5a, 0x59, 0xce, 0x53, 0x45, 0x1f, 0x70, 0xb6, 0x53, 0x9f,
  382. 0xe8, 0xc7, 0xde, 0x67, 0x03, 0x34, 0xce, 0xb3, 0x3b, 0x51, 0x3b, 0x9a, 0xc4, 0x70, 0x08, 0xea,
  383. 0xf9, 0x2d, 0x5d, 0x8a, 0x59, 0xcb, 0x10, 0x05, 0x4c, 0xbd, 0x80, 0xbc, 0x43, 0x9e, 0x78, 0x86,
  384. 0x99, 0xb3, 0x75, 0xa1, 0x9d, 0xa0, 0x05, 0x76, 0x42, 0x44, 0x99, 0x1b, 0x60, 0xe2, 0x07, 0xcc,
  385. 0xf5, 0x02, 0x14, 0xf9, 0x78, 0x2c, 0xbc, 0xae, 0x39, 0x7f, 0x73, 0xe8, 0x44, 0x20, 0x43, 0x09,
  386. 0xf4, 0xbe, 0x18, 0x60, 0x67, 0xc8, 0xdd, 0x46, 0x74, 0x46, 0x5f, 0x8a, 0x16, 0x0a, 0x33, 0x0e,
  387. 0xd8, 0xf6, 0xb2, 0xb0, 0x2b, 0x5b, 0xab, 0xfc, 0xfc, 0xb7, 0xea, 0x67, 0x49, 0x60, 0xb0, 0x7e,
  388. 0x75, 0xd3, 0x29, 0x39, 0x4d, 0x6f, 0x31, 0xfc, 0xdb, 0xde, 0x02, 0x50, 0x3e, 0x97, 0x6f, 0x07,
  389. 0x8f, 0x40, 0x35, 0x57, 0x53, 0x3e, 0xf6, 0x75, 0x1f, 0xea, 0x8d, 0x0b, 0x27, 0xca, 0x43, 0x91,
  390. 0x05, 0xdb, 0xa0, 0x42, 0xe3, 0x09, 0x7b, 0x8f, 0x52, 0x2c, 0x4a, 0x56, 0x9d, 0xfc, 0xdc, 0xfb,
  391. 0xb1, 0x09, 0x36, 0xce, 0xf8, 0x28, 0xc3, 0xc7, 0xa0, 0xac, 0xb4, 0x54, 0x99, 0x5d, 0x6b, 0x79,
  392. 0xdc, 0x2d, 0x65, 0x4a, 0x95, 0xc8, 0xf8, 0xf0, 0x00, 0x54, 0xbc, 0x00, 0x91, 0xc8, 0x25, 0xf2,
  393. 0x4e, 0xd5, 0x41, 0x6d, 0x7e, 0xd3, 0x29, 0x0f, 0x79, 0xcc, 0x3e, 0x76, 0xca, 0x02, 0xb4, 0xc7,
  394. 0xf0, 0x1e, 0x68, 0x90, 0x88, 0x30, 0x82, 0x42, 0xd5, 0x89, 0x56, 0x43, 0x74, 0xa0, 0xae, 0xa2,
  395. 0xb2, 0x09, 0xf0, 0x3e, 0x10, 0x2d, 0x91, 0xc3, 0x96, 0x31, 0xd7, 0x04, 0xb3, 0xc9, 0x01, 0x31,
  396. 0x47, 0x8a, 0xeb, 0x80, 0xba, 0xc6, 0x25, 0xe3, 0xd6, 0xfa, 0xaa, 0x77, 0xf9, 0x54, 0x22, 0xcb,
  397. 0x3e, 0x1e, 0xec, 0x70, 0xef, 0xf3, 0x9b, 0x4e, 0xed, 0x34, 0x93, 0xb2, 0x8f, 0x9d, 0x5a, 0xae,
  398. 0x6b, 0x8f, 0xe1, 0x29, 0x68, 0x6a, 0x9a, 0x7c, 0x3f, 0x5a, 0x1b, 0x42, 0xb5, 0x6d, 0xc9, 0xe5,
  399. 0xb1, 0xb2, 0xe5, 0xb1, 0x5e, 0x67, 0xcb, 0x33, 0xa8, 0x70, 0xd9, 0xcb, 0x6f, 0x1d, 0xc3, 0xa9,
  400. 0xe7, 0x5a, 0x1c, 0x85, 0xcf, 0x40, 0x33, 0xc2, 0x1f, 0x98, 0x9b, 0x0f, 0x2b, 0x6d, 0x6d, 0xde,
  401. 0x69, 0xbc, 0x1b, 0x3c, 0xad, 0xd8, 0x14, 0xf8, 0x04, 0x00, 0x4d, 0xa3, 0x7c, 0x27, 0x0d, 0x2d,
  402. 0x83, 0x1b, 0x11, 0xd7, 0xd2, 0x44, 0x2a, 0x77, 0x33, 0xc2, 0xd3, 0x34, 0x23, 0x43, 0x60, 0xea,
  403. 0xd3, 0x5c, 0xe8, 0xe5, 0x83, 0x5d, 0x15, 0x8f, 0xb5, 0x57, 0x0c, 0x76, 0x91, 0xad, 0x46, 0xfc,
  404. 0x97, 0x6b, 0x06, 0xfe, 0x70, 0xcd, 0x5e, 0x80, 0xff, 0x17, 0xd6, 0x6c, 0x49, 0x3f, 0xb7, 0x57,
  405. 0x13, 0xf6, 0xba, 0xda, 0xde, 0x2d, 0x0a, 0x65, 0x1e, 0xb3, 0x41, 0x4c, 0x31, 0x9d, 0x85, 0x8c,
  406. 0xba, 0x01, 0xa2, 0x41, 0x6b, 0xab, 0x6b, 0x1c, 0x6e, 0xc9, 0x41, 0x74, 0x64, 0xfc, 0x04, 0xd1,
  407. 0x00, 0xee, 0x82, 0x0a, 0x4a, 0x12, 0x49, 0xa9, 0x0b, 0x4a, 0x19, 0x25, 0x09, 0x87, 0x06, 0xaf,
  408. 0xae, 0xe6, 0xa6, 0x71, 0x3d, 0x37, 0x8d, 0xef, 0x73, 0xd3, 0xb8, 0xbc, 0x35, 0x4b, 0xd7, 0xb7,
  409. 0x66, 0xe9, 0xeb, 0xad, 0x59, 0x7a, 0xf3, 0xc8, 0x27, 0x2c, 0x98, 0x8d, 0x2c, 0x2f, 0x9e, 0xf6,
  410. 0xf5, 0xbf, 0xf5, 0xe2, 0xa7, 0xfc, 0xb6, 0x2c, 0x7f, 0x95, 0x46, 0x9b, 0x22, 0xfe, 0xf0, 0x67,
  411. 0x00, 0x00, 0x00, 0xff, 0xff, 0x88, 0xe8, 0x4c, 0x4d, 0xb0, 0x06, 0x00, 0x00,
  412. }
  413. func (m *ABCIResponses) Marshal() (dAtA []byte, err error) {
  414. size := m.Size()
  415. dAtA = make([]byte, size)
  416. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  417. if err != nil {
  418. return nil, err
  419. }
  420. return dAtA[:n], nil
  421. }
  422. func (m *ABCIResponses) MarshalTo(dAtA []byte) (int, error) {
  423. size := m.Size()
  424. return m.MarshalToSizedBuffer(dAtA[:size])
  425. }
  426. func (m *ABCIResponses) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  427. i := len(dAtA)
  428. _ = i
  429. var l int
  430. _ = l
  431. if m.FinalizeBlock != nil {
  432. {
  433. size, err := m.FinalizeBlock.MarshalToSizedBuffer(dAtA[:i])
  434. if err != nil {
  435. return 0, err
  436. }
  437. i -= size
  438. i = encodeVarintTypes(dAtA, i, uint64(size))
  439. }
  440. i--
  441. dAtA[i] = 0x12
  442. }
  443. return len(dAtA) - i, nil
  444. }
  445. func (m *ValidatorsInfo) Marshal() (dAtA []byte, err error) {
  446. size := m.Size()
  447. dAtA = make([]byte, size)
  448. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  449. if err != nil {
  450. return nil, err
  451. }
  452. return dAtA[:n], nil
  453. }
  454. func (m *ValidatorsInfo) MarshalTo(dAtA []byte) (int, error) {
  455. size := m.Size()
  456. return m.MarshalToSizedBuffer(dAtA[:size])
  457. }
  458. func (m *ValidatorsInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  459. i := len(dAtA)
  460. _ = i
  461. var l int
  462. _ = l
  463. if m.LastHeightChanged != 0 {
  464. i = encodeVarintTypes(dAtA, i, uint64(m.LastHeightChanged))
  465. i--
  466. dAtA[i] = 0x10
  467. }
  468. if m.ValidatorSet != nil {
  469. {
  470. size, err := m.ValidatorSet.MarshalToSizedBuffer(dAtA[:i])
  471. if err != nil {
  472. return 0, err
  473. }
  474. i -= size
  475. i = encodeVarintTypes(dAtA, i, uint64(size))
  476. }
  477. i--
  478. dAtA[i] = 0xa
  479. }
  480. return len(dAtA) - i, nil
  481. }
  482. func (m *ConsensusParamsInfo) Marshal() (dAtA []byte, err error) {
  483. size := m.Size()
  484. dAtA = make([]byte, size)
  485. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  486. if err != nil {
  487. return nil, err
  488. }
  489. return dAtA[:n], nil
  490. }
  491. func (m *ConsensusParamsInfo) MarshalTo(dAtA []byte) (int, error) {
  492. size := m.Size()
  493. return m.MarshalToSizedBuffer(dAtA[:size])
  494. }
  495. func (m *ConsensusParamsInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  496. i := len(dAtA)
  497. _ = i
  498. var l int
  499. _ = l
  500. if m.LastHeightChanged != 0 {
  501. i = encodeVarintTypes(dAtA, i, uint64(m.LastHeightChanged))
  502. i--
  503. dAtA[i] = 0x10
  504. }
  505. {
  506. size, err := m.ConsensusParams.MarshalToSizedBuffer(dAtA[:i])
  507. if err != nil {
  508. return 0, err
  509. }
  510. i -= size
  511. i = encodeVarintTypes(dAtA, i, uint64(size))
  512. }
  513. i--
  514. dAtA[i] = 0xa
  515. return len(dAtA) - i, nil
  516. }
  517. func (m *Version) Marshal() (dAtA []byte, err error) {
  518. size := m.Size()
  519. dAtA = make([]byte, size)
  520. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  521. if err != nil {
  522. return nil, err
  523. }
  524. return dAtA[:n], nil
  525. }
  526. func (m *Version) MarshalTo(dAtA []byte) (int, error) {
  527. size := m.Size()
  528. return m.MarshalToSizedBuffer(dAtA[:size])
  529. }
  530. func (m *Version) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  531. i := len(dAtA)
  532. _ = i
  533. var l int
  534. _ = l
  535. if len(m.Software) > 0 {
  536. i -= len(m.Software)
  537. copy(dAtA[i:], m.Software)
  538. i = encodeVarintTypes(dAtA, i, uint64(len(m.Software)))
  539. i--
  540. dAtA[i] = 0x12
  541. }
  542. {
  543. size, err := m.Consensus.MarshalToSizedBuffer(dAtA[:i])
  544. if err != nil {
  545. return 0, err
  546. }
  547. i -= size
  548. i = encodeVarintTypes(dAtA, i, uint64(size))
  549. }
  550. i--
  551. dAtA[i] = 0xa
  552. return len(dAtA) - i, nil
  553. }
  554. func (m *State) Marshal() (dAtA []byte, err error) {
  555. size := m.Size()
  556. dAtA = make([]byte, size)
  557. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  558. if err != nil {
  559. return nil, err
  560. }
  561. return dAtA[:n], nil
  562. }
  563. func (m *State) MarshalTo(dAtA []byte) (int, error) {
  564. size := m.Size()
  565. return m.MarshalToSizedBuffer(dAtA[:size])
  566. }
  567. func (m *State) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  568. i := len(dAtA)
  569. _ = i
  570. var l int
  571. _ = l
  572. if m.InitialHeight != 0 {
  573. i = encodeVarintTypes(dAtA, i, uint64(m.InitialHeight))
  574. i--
  575. dAtA[i] = 0x70
  576. }
  577. if len(m.AppHash) > 0 {
  578. i -= len(m.AppHash)
  579. copy(dAtA[i:], m.AppHash)
  580. i = encodeVarintTypes(dAtA, i, uint64(len(m.AppHash)))
  581. i--
  582. dAtA[i] = 0x6a
  583. }
  584. if len(m.LastResultsHash) > 0 {
  585. i -= len(m.LastResultsHash)
  586. copy(dAtA[i:], m.LastResultsHash)
  587. i = encodeVarintTypes(dAtA, i, uint64(len(m.LastResultsHash)))
  588. i--
  589. dAtA[i] = 0x62
  590. }
  591. if m.LastHeightConsensusParamsChanged != 0 {
  592. i = encodeVarintTypes(dAtA, i, uint64(m.LastHeightConsensusParamsChanged))
  593. i--
  594. dAtA[i] = 0x58
  595. }
  596. {
  597. size, err := m.ConsensusParams.MarshalToSizedBuffer(dAtA[:i])
  598. if err != nil {
  599. return 0, err
  600. }
  601. i -= size
  602. i = encodeVarintTypes(dAtA, i, uint64(size))
  603. }
  604. i--
  605. dAtA[i] = 0x52
  606. if m.LastHeightValidatorsChanged != 0 {
  607. i = encodeVarintTypes(dAtA, i, uint64(m.LastHeightValidatorsChanged))
  608. i--
  609. dAtA[i] = 0x48
  610. }
  611. if m.LastValidators != nil {
  612. {
  613. size, err := m.LastValidators.MarshalToSizedBuffer(dAtA[:i])
  614. if err != nil {
  615. return 0, err
  616. }
  617. i -= size
  618. i = encodeVarintTypes(dAtA, i, uint64(size))
  619. }
  620. i--
  621. dAtA[i] = 0x42
  622. }
  623. if m.Validators != nil {
  624. {
  625. size, err := m.Validators.MarshalToSizedBuffer(dAtA[:i])
  626. if err != nil {
  627. return 0, err
  628. }
  629. i -= size
  630. i = encodeVarintTypes(dAtA, i, uint64(size))
  631. }
  632. i--
  633. dAtA[i] = 0x3a
  634. }
  635. if m.NextValidators != nil {
  636. {
  637. size, err := m.NextValidators.MarshalToSizedBuffer(dAtA[:i])
  638. if err != nil {
  639. return 0, err
  640. }
  641. i -= size
  642. i = encodeVarintTypes(dAtA, i, uint64(size))
  643. }
  644. i--
  645. dAtA[i] = 0x32
  646. }
  647. n9, err9 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.LastBlockTime, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.LastBlockTime):])
  648. if err9 != nil {
  649. return 0, err9
  650. }
  651. i -= n9
  652. i = encodeVarintTypes(dAtA, i, uint64(n9))
  653. i--
  654. dAtA[i] = 0x2a
  655. {
  656. size, err := m.LastBlockID.MarshalToSizedBuffer(dAtA[:i])
  657. if err != nil {
  658. return 0, err
  659. }
  660. i -= size
  661. i = encodeVarintTypes(dAtA, i, uint64(size))
  662. }
  663. i--
  664. dAtA[i] = 0x22
  665. if m.LastBlockHeight != 0 {
  666. i = encodeVarintTypes(dAtA, i, uint64(m.LastBlockHeight))
  667. i--
  668. dAtA[i] = 0x18
  669. }
  670. if len(m.ChainID) > 0 {
  671. i -= len(m.ChainID)
  672. copy(dAtA[i:], m.ChainID)
  673. i = encodeVarintTypes(dAtA, i, uint64(len(m.ChainID)))
  674. i--
  675. dAtA[i] = 0x12
  676. }
  677. {
  678. size, err := m.Version.MarshalToSizedBuffer(dAtA[:i])
  679. if err != nil {
  680. return 0, err
  681. }
  682. i -= size
  683. i = encodeVarintTypes(dAtA, i, uint64(size))
  684. }
  685. i--
  686. dAtA[i] = 0xa
  687. return len(dAtA) - i, nil
  688. }
  689. func encodeVarintTypes(dAtA []byte, offset int, v uint64) int {
  690. offset -= sovTypes(v)
  691. base := offset
  692. for v >= 1<<7 {
  693. dAtA[offset] = uint8(v&0x7f | 0x80)
  694. v >>= 7
  695. offset++
  696. }
  697. dAtA[offset] = uint8(v)
  698. return base
  699. }
  700. func (m *ABCIResponses) Size() (n int) {
  701. if m == nil {
  702. return 0
  703. }
  704. var l int
  705. _ = l
  706. if m.FinalizeBlock != nil {
  707. l = m.FinalizeBlock.Size()
  708. n += 1 + l + sovTypes(uint64(l))
  709. }
  710. return n
  711. }
  712. func (m *ValidatorsInfo) Size() (n int) {
  713. if m == nil {
  714. return 0
  715. }
  716. var l int
  717. _ = l
  718. if m.ValidatorSet != nil {
  719. l = m.ValidatorSet.Size()
  720. n += 1 + l + sovTypes(uint64(l))
  721. }
  722. if m.LastHeightChanged != 0 {
  723. n += 1 + sovTypes(uint64(m.LastHeightChanged))
  724. }
  725. return n
  726. }
  727. func (m *ConsensusParamsInfo) Size() (n int) {
  728. if m == nil {
  729. return 0
  730. }
  731. var l int
  732. _ = l
  733. l = m.ConsensusParams.Size()
  734. n += 1 + l + sovTypes(uint64(l))
  735. if m.LastHeightChanged != 0 {
  736. n += 1 + sovTypes(uint64(m.LastHeightChanged))
  737. }
  738. return n
  739. }
  740. func (m *Version) Size() (n int) {
  741. if m == nil {
  742. return 0
  743. }
  744. var l int
  745. _ = l
  746. l = m.Consensus.Size()
  747. n += 1 + l + sovTypes(uint64(l))
  748. l = len(m.Software)
  749. if l > 0 {
  750. n += 1 + l + sovTypes(uint64(l))
  751. }
  752. return n
  753. }
  754. func (m *State) Size() (n int) {
  755. if m == nil {
  756. return 0
  757. }
  758. var l int
  759. _ = l
  760. l = m.Version.Size()
  761. n += 1 + l + sovTypes(uint64(l))
  762. l = len(m.ChainID)
  763. if l > 0 {
  764. n += 1 + l + sovTypes(uint64(l))
  765. }
  766. if m.LastBlockHeight != 0 {
  767. n += 1 + sovTypes(uint64(m.LastBlockHeight))
  768. }
  769. l = m.LastBlockID.Size()
  770. n += 1 + l + sovTypes(uint64(l))
  771. l = github_com_gogo_protobuf_types.SizeOfStdTime(m.LastBlockTime)
  772. n += 1 + l + sovTypes(uint64(l))
  773. if m.NextValidators != nil {
  774. l = m.NextValidators.Size()
  775. n += 1 + l + sovTypes(uint64(l))
  776. }
  777. if m.Validators != nil {
  778. l = m.Validators.Size()
  779. n += 1 + l + sovTypes(uint64(l))
  780. }
  781. if m.LastValidators != nil {
  782. l = m.LastValidators.Size()
  783. n += 1 + l + sovTypes(uint64(l))
  784. }
  785. if m.LastHeightValidatorsChanged != 0 {
  786. n += 1 + sovTypes(uint64(m.LastHeightValidatorsChanged))
  787. }
  788. l = m.ConsensusParams.Size()
  789. n += 1 + l + sovTypes(uint64(l))
  790. if m.LastHeightConsensusParamsChanged != 0 {
  791. n += 1 + sovTypes(uint64(m.LastHeightConsensusParamsChanged))
  792. }
  793. l = len(m.LastResultsHash)
  794. if l > 0 {
  795. n += 1 + l + sovTypes(uint64(l))
  796. }
  797. l = len(m.AppHash)
  798. if l > 0 {
  799. n += 1 + l + sovTypes(uint64(l))
  800. }
  801. if m.InitialHeight != 0 {
  802. n += 1 + sovTypes(uint64(m.InitialHeight))
  803. }
  804. return n
  805. }
  806. func sovTypes(x uint64) (n int) {
  807. return (math_bits.Len64(x|1) + 6) / 7
  808. }
  809. func sozTypes(x uint64) (n int) {
  810. return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  811. }
  812. func (m *ABCIResponses) Unmarshal(dAtA []byte) error {
  813. l := len(dAtA)
  814. iNdEx := 0
  815. for iNdEx < l {
  816. preIndex := iNdEx
  817. var wire uint64
  818. for shift := uint(0); ; shift += 7 {
  819. if shift >= 64 {
  820. return ErrIntOverflowTypes
  821. }
  822. if iNdEx >= l {
  823. return io.ErrUnexpectedEOF
  824. }
  825. b := dAtA[iNdEx]
  826. iNdEx++
  827. wire |= uint64(b&0x7F) << shift
  828. if b < 0x80 {
  829. break
  830. }
  831. }
  832. fieldNum := int32(wire >> 3)
  833. wireType := int(wire & 0x7)
  834. if wireType == 4 {
  835. return fmt.Errorf("proto: ABCIResponses: wiretype end group for non-group")
  836. }
  837. if fieldNum <= 0 {
  838. return fmt.Errorf("proto: ABCIResponses: illegal tag %d (wire type %d)", fieldNum, wire)
  839. }
  840. switch fieldNum {
  841. case 2:
  842. if wireType != 2 {
  843. return fmt.Errorf("proto: wrong wireType = %d for field FinalizeBlock", wireType)
  844. }
  845. var msglen int
  846. for shift := uint(0); ; shift += 7 {
  847. if shift >= 64 {
  848. return ErrIntOverflowTypes
  849. }
  850. if iNdEx >= l {
  851. return io.ErrUnexpectedEOF
  852. }
  853. b := dAtA[iNdEx]
  854. iNdEx++
  855. msglen |= int(b&0x7F) << shift
  856. if b < 0x80 {
  857. break
  858. }
  859. }
  860. if msglen < 0 {
  861. return ErrInvalidLengthTypes
  862. }
  863. postIndex := iNdEx + msglen
  864. if postIndex < 0 {
  865. return ErrInvalidLengthTypes
  866. }
  867. if postIndex > l {
  868. return io.ErrUnexpectedEOF
  869. }
  870. if m.FinalizeBlock == nil {
  871. m.FinalizeBlock = &types.ResponseFinalizeBlock{}
  872. }
  873. if err := m.FinalizeBlock.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  874. return err
  875. }
  876. iNdEx = postIndex
  877. default:
  878. iNdEx = preIndex
  879. skippy, err := skipTypes(dAtA[iNdEx:])
  880. if err != nil {
  881. return err
  882. }
  883. if (skippy < 0) || (iNdEx+skippy) < 0 {
  884. return ErrInvalidLengthTypes
  885. }
  886. if (iNdEx + skippy) > l {
  887. return io.ErrUnexpectedEOF
  888. }
  889. iNdEx += skippy
  890. }
  891. }
  892. if iNdEx > l {
  893. return io.ErrUnexpectedEOF
  894. }
  895. return nil
  896. }
  897. func (m *ValidatorsInfo) Unmarshal(dAtA []byte) error {
  898. l := len(dAtA)
  899. iNdEx := 0
  900. for iNdEx < l {
  901. preIndex := iNdEx
  902. var wire uint64
  903. for shift := uint(0); ; shift += 7 {
  904. if shift >= 64 {
  905. return ErrIntOverflowTypes
  906. }
  907. if iNdEx >= l {
  908. return io.ErrUnexpectedEOF
  909. }
  910. b := dAtA[iNdEx]
  911. iNdEx++
  912. wire |= uint64(b&0x7F) << shift
  913. if b < 0x80 {
  914. break
  915. }
  916. }
  917. fieldNum := int32(wire >> 3)
  918. wireType := int(wire & 0x7)
  919. if wireType == 4 {
  920. return fmt.Errorf("proto: ValidatorsInfo: wiretype end group for non-group")
  921. }
  922. if fieldNum <= 0 {
  923. return fmt.Errorf("proto: ValidatorsInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  924. }
  925. switch fieldNum {
  926. case 1:
  927. if wireType != 2 {
  928. return fmt.Errorf("proto: wrong wireType = %d for field ValidatorSet", wireType)
  929. }
  930. var msglen int
  931. for shift := uint(0); ; shift += 7 {
  932. if shift >= 64 {
  933. return ErrIntOverflowTypes
  934. }
  935. if iNdEx >= l {
  936. return io.ErrUnexpectedEOF
  937. }
  938. b := dAtA[iNdEx]
  939. iNdEx++
  940. msglen |= int(b&0x7F) << shift
  941. if b < 0x80 {
  942. break
  943. }
  944. }
  945. if msglen < 0 {
  946. return ErrInvalidLengthTypes
  947. }
  948. postIndex := iNdEx + msglen
  949. if postIndex < 0 {
  950. return ErrInvalidLengthTypes
  951. }
  952. if postIndex > l {
  953. return io.ErrUnexpectedEOF
  954. }
  955. if m.ValidatorSet == nil {
  956. m.ValidatorSet = &types1.ValidatorSet{}
  957. }
  958. if err := m.ValidatorSet.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  959. return err
  960. }
  961. iNdEx = postIndex
  962. case 2:
  963. if wireType != 0 {
  964. return fmt.Errorf("proto: wrong wireType = %d for field LastHeightChanged", wireType)
  965. }
  966. m.LastHeightChanged = 0
  967. for shift := uint(0); ; shift += 7 {
  968. if shift >= 64 {
  969. return ErrIntOverflowTypes
  970. }
  971. if iNdEx >= l {
  972. return io.ErrUnexpectedEOF
  973. }
  974. b := dAtA[iNdEx]
  975. iNdEx++
  976. m.LastHeightChanged |= int64(b&0x7F) << shift
  977. if b < 0x80 {
  978. break
  979. }
  980. }
  981. default:
  982. iNdEx = preIndex
  983. skippy, err := skipTypes(dAtA[iNdEx:])
  984. if err != nil {
  985. return err
  986. }
  987. if (skippy < 0) || (iNdEx+skippy) < 0 {
  988. return ErrInvalidLengthTypes
  989. }
  990. if (iNdEx + skippy) > l {
  991. return io.ErrUnexpectedEOF
  992. }
  993. iNdEx += skippy
  994. }
  995. }
  996. if iNdEx > l {
  997. return io.ErrUnexpectedEOF
  998. }
  999. return nil
  1000. }
  1001. func (m *ConsensusParamsInfo) Unmarshal(dAtA []byte) error {
  1002. l := len(dAtA)
  1003. iNdEx := 0
  1004. for iNdEx < l {
  1005. preIndex := iNdEx
  1006. var wire uint64
  1007. for shift := uint(0); ; shift += 7 {
  1008. if shift >= 64 {
  1009. return ErrIntOverflowTypes
  1010. }
  1011. if iNdEx >= l {
  1012. return io.ErrUnexpectedEOF
  1013. }
  1014. b := dAtA[iNdEx]
  1015. iNdEx++
  1016. wire |= uint64(b&0x7F) << shift
  1017. if b < 0x80 {
  1018. break
  1019. }
  1020. }
  1021. fieldNum := int32(wire >> 3)
  1022. wireType := int(wire & 0x7)
  1023. if wireType == 4 {
  1024. return fmt.Errorf("proto: ConsensusParamsInfo: wiretype end group for non-group")
  1025. }
  1026. if fieldNum <= 0 {
  1027. return fmt.Errorf("proto: ConsensusParamsInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  1028. }
  1029. switch fieldNum {
  1030. case 1:
  1031. if wireType != 2 {
  1032. return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParams", wireType)
  1033. }
  1034. var msglen int
  1035. for shift := uint(0); ; shift += 7 {
  1036. if shift >= 64 {
  1037. return ErrIntOverflowTypes
  1038. }
  1039. if iNdEx >= l {
  1040. return io.ErrUnexpectedEOF
  1041. }
  1042. b := dAtA[iNdEx]
  1043. iNdEx++
  1044. msglen |= int(b&0x7F) << shift
  1045. if b < 0x80 {
  1046. break
  1047. }
  1048. }
  1049. if msglen < 0 {
  1050. return ErrInvalidLengthTypes
  1051. }
  1052. postIndex := iNdEx + msglen
  1053. if postIndex < 0 {
  1054. return ErrInvalidLengthTypes
  1055. }
  1056. if postIndex > l {
  1057. return io.ErrUnexpectedEOF
  1058. }
  1059. if err := m.ConsensusParams.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1060. return err
  1061. }
  1062. iNdEx = postIndex
  1063. case 2:
  1064. if wireType != 0 {
  1065. return fmt.Errorf("proto: wrong wireType = %d for field LastHeightChanged", wireType)
  1066. }
  1067. m.LastHeightChanged = 0
  1068. for shift := uint(0); ; shift += 7 {
  1069. if shift >= 64 {
  1070. return ErrIntOverflowTypes
  1071. }
  1072. if iNdEx >= l {
  1073. return io.ErrUnexpectedEOF
  1074. }
  1075. b := dAtA[iNdEx]
  1076. iNdEx++
  1077. m.LastHeightChanged |= int64(b&0x7F) << shift
  1078. if b < 0x80 {
  1079. break
  1080. }
  1081. }
  1082. default:
  1083. iNdEx = preIndex
  1084. skippy, err := skipTypes(dAtA[iNdEx:])
  1085. if err != nil {
  1086. return err
  1087. }
  1088. if (skippy < 0) || (iNdEx+skippy) < 0 {
  1089. return ErrInvalidLengthTypes
  1090. }
  1091. if (iNdEx + skippy) > l {
  1092. return io.ErrUnexpectedEOF
  1093. }
  1094. iNdEx += skippy
  1095. }
  1096. }
  1097. if iNdEx > l {
  1098. return io.ErrUnexpectedEOF
  1099. }
  1100. return nil
  1101. }
  1102. func (m *Version) Unmarshal(dAtA []byte) error {
  1103. l := len(dAtA)
  1104. iNdEx := 0
  1105. for iNdEx < l {
  1106. preIndex := iNdEx
  1107. var wire uint64
  1108. for shift := uint(0); ; shift += 7 {
  1109. if shift >= 64 {
  1110. return ErrIntOverflowTypes
  1111. }
  1112. if iNdEx >= l {
  1113. return io.ErrUnexpectedEOF
  1114. }
  1115. b := dAtA[iNdEx]
  1116. iNdEx++
  1117. wire |= uint64(b&0x7F) << shift
  1118. if b < 0x80 {
  1119. break
  1120. }
  1121. }
  1122. fieldNum := int32(wire >> 3)
  1123. wireType := int(wire & 0x7)
  1124. if wireType == 4 {
  1125. return fmt.Errorf("proto: Version: wiretype end group for non-group")
  1126. }
  1127. if fieldNum <= 0 {
  1128. return fmt.Errorf("proto: Version: illegal tag %d (wire type %d)", fieldNum, wire)
  1129. }
  1130. switch fieldNum {
  1131. case 1:
  1132. if wireType != 2 {
  1133. return fmt.Errorf("proto: wrong wireType = %d for field Consensus", wireType)
  1134. }
  1135. var msglen int
  1136. for shift := uint(0); ; shift += 7 {
  1137. if shift >= 64 {
  1138. return ErrIntOverflowTypes
  1139. }
  1140. if iNdEx >= l {
  1141. return io.ErrUnexpectedEOF
  1142. }
  1143. b := dAtA[iNdEx]
  1144. iNdEx++
  1145. msglen |= int(b&0x7F) << shift
  1146. if b < 0x80 {
  1147. break
  1148. }
  1149. }
  1150. if msglen < 0 {
  1151. return ErrInvalidLengthTypes
  1152. }
  1153. postIndex := iNdEx + msglen
  1154. if postIndex < 0 {
  1155. return ErrInvalidLengthTypes
  1156. }
  1157. if postIndex > l {
  1158. return io.ErrUnexpectedEOF
  1159. }
  1160. if err := m.Consensus.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1161. return err
  1162. }
  1163. iNdEx = postIndex
  1164. case 2:
  1165. if wireType != 2 {
  1166. return fmt.Errorf("proto: wrong wireType = %d for field Software", wireType)
  1167. }
  1168. var stringLen uint64
  1169. for shift := uint(0); ; shift += 7 {
  1170. if shift >= 64 {
  1171. return ErrIntOverflowTypes
  1172. }
  1173. if iNdEx >= l {
  1174. return io.ErrUnexpectedEOF
  1175. }
  1176. b := dAtA[iNdEx]
  1177. iNdEx++
  1178. stringLen |= uint64(b&0x7F) << shift
  1179. if b < 0x80 {
  1180. break
  1181. }
  1182. }
  1183. intStringLen := int(stringLen)
  1184. if intStringLen < 0 {
  1185. return ErrInvalidLengthTypes
  1186. }
  1187. postIndex := iNdEx + intStringLen
  1188. if postIndex < 0 {
  1189. return ErrInvalidLengthTypes
  1190. }
  1191. if postIndex > l {
  1192. return io.ErrUnexpectedEOF
  1193. }
  1194. m.Software = string(dAtA[iNdEx:postIndex])
  1195. iNdEx = postIndex
  1196. default:
  1197. iNdEx = preIndex
  1198. skippy, err := skipTypes(dAtA[iNdEx:])
  1199. if err != nil {
  1200. return err
  1201. }
  1202. if (skippy < 0) || (iNdEx+skippy) < 0 {
  1203. return ErrInvalidLengthTypes
  1204. }
  1205. if (iNdEx + skippy) > l {
  1206. return io.ErrUnexpectedEOF
  1207. }
  1208. iNdEx += skippy
  1209. }
  1210. }
  1211. if iNdEx > l {
  1212. return io.ErrUnexpectedEOF
  1213. }
  1214. return nil
  1215. }
  1216. func (m *State) Unmarshal(dAtA []byte) error {
  1217. l := len(dAtA)
  1218. iNdEx := 0
  1219. for iNdEx < l {
  1220. preIndex := iNdEx
  1221. var wire uint64
  1222. for shift := uint(0); ; shift += 7 {
  1223. if shift >= 64 {
  1224. return ErrIntOverflowTypes
  1225. }
  1226. if iNdEx >= l {
  1227. return io.ErrUnexpectedEOF
  1228. }
  1229. b := dAtA[iNdEx]
  1230. iNdEx++
  1231. wire |= uint64(b&0x7F) << shift
  1232. if b < 0x80 {
  1233. break
  1234. }
  1235. }
  1236. fieldNum := int32(wire >> 3)
  1237. wireType := int(wire & 0x7)
  1238. if wireType == 4 {
  1239. return fmt.Errorf("proto: State: wiretype end group for non-group")
  1240. }
  1241. if fieldNum <= 0 {
  1242. return fmt.Errorf("proto: State: illegal tag %d (wire type %d)", fieldNum, wire)
  1243. }
  1244. switch fieldNum {
  1245. case 1:
  1246. if wireType != 2 {
  1247. return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType)
  1248. }
  1249. var msglen int
  1250. for shift := uint(0); ; shift += 7 {
  1251. if shift >= 64 {
  1252. return ErrIntOverflowTypes
  1253. }
  1254. if iNdEx >= l {
  1255. return io.ErrUnexpectedEOF
  1256. }
  1257. b := dAtA[iNdEx]
  1258. iNdEx++
  1259. msglen |= int(b&0x7F) << shift
  1260. if b < 0x80 {
  1261. break
  1262. }
  1263. }
  1264. if msglen < 0 {
  1265. return ErrInvalidLengthTypes
  1266. }
  1267. postIndex := iNdEx + msglen
  1268. if postIndex < 0 {
  1269. return ErrInvalidLengthTypes
  1270. }
  1271. if postIndex > l {
  1272. return io.ErrUnexpectedEOF
  1273. }
  1274. if err := m.Version.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1275. return err
  1276. }
  1277. iNdEx = postIndex
  1278. case 2:
  1279. if wireType != 2 {
  1280. return fmt.Errorf("proto: wrong wireType = %d for field ChainID", wireType)
  1281. }
  1282. var stringLen uint64
  1283. for shift := uint(0); ; shift += 7 {
  1284. if shift >= 64 {
  1285. return ErrIntOverflowTypes
  1286. }
  1287. if iNdEx >= l {
  1288. return io.ErrUnexpectedEOF
  1289. }
  1290. b := dAtA[iNdEx]
  1291. iNdEx++
  1292. stringLen |= uint64(b&0x7F) << shift
  1293. if b < 0x80 {
  1294. break
  1295. }
  1296. }
  1297. intStringLen := int(stringLen)
  1298. if intStringLen < 0 {
  1299. return ErrInvalidLengthTypes
  1300. }
  1301. postIndex := iNdEx + intStringLen
  1302. if postIndex < 0 {
  1303. return ErrInvalidLengthTypes
  1304. }
  1305. if postIndex > l {
  1306. return io.ErrUnexpectedEOF
  1307. }
  1308. m.ChainID = string(dAtA[iNdEx:postIndex])
  1309. iNdEx = postIndex
  1310. case 3:
  1311. if wireType != 0 {
  1312. return fmt.Errorf("proto: wrong wireType = %d for field LastBlockHeight", wireType)
  1313. }
  1314. m.LastBlockHeight = 0
  1315. for shift := uint(0); ; shift += 7 {
  1316. if shift >= 64 {
  1317. return ErrIntOverflowTypes
  1318. }
  1319. if iNdEx >= l {
  1320. return io.ErrUnexpectedEOF
  1321. }
  1322. b := dAtA[iNdEx]
  1323. iNdEx++
  1324. m.LastBlockHeight |= int64(b&0x7F) << shift
  1325. if b < 0x80 {
  1326. break
  1327. }
  1328. }
  1329. case 4:
  1330. if wireType != 2 {
  1331. return fmt.Errorf("proto: wrong wireType = %d for field LastBlockID", wireType)
  1332. }
  1333. var msglen int
  1334. for shift := uint(0); ; shift += 7 {
  1335. if shift >= 64 {
  1336. return ErrIntOverflowTypes
  1337. }
  1338. if iNdEx >= l {
  1339. return io.ErrUnexpectedEOF
  1340. }
  1341. b := dAtA[iNdEx]
  1342. iNdEx++
  1343. msglen |= int(b&0x7F) << shift
  1344. if b < 0x80 {
  1345. break
  1346. }
  1347. }
  1348. if msglen < 0 {
  1349. return ErrInvalidLengthTypes
  1350. }
  1351. postIndex := iNdEx + msglen
  1352. if postIndex < 0 {
  1353. return ErrInvalidLengthTypes
  1354. }
  1355. if postIndex > l {
  1356. return io.ErrUnexpectedEOF
  1357. }
  1358. if err := m.LastBlockID.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1359. return err
  1360. }
  1361. iNdEx = postIndex
  1362. case 5:
  1363. if wireType != 2 {
  1364. return fmt.Errorf("proto: wrong wireType = %d for field LastBlockTime", wireType)
  1365. }
  1366. var msglen int
  1367. for shift := uint(0); ; shift += 7 {
  1368. if shift >= 64 {
  1369. return ErrIntOverflowTypes
  1370. }
  1371. if iNdEx >= l {
  1372. return io.ErrUnexpectedEOF
  1373. }
  1374. b := dAtA[iNdEx]
  1375. iNdEx++
  1376. msglen |= int(b&0x7F) << shift
  1377. if b < 0x80 {
  1378. break
  1379. }
  1380. }
  1381. if msglen < 0 {
  1382. return ErrInvalidLengthTypes
  1383. }
  1384. postIndex := iNdEx + msglen
  1385. if postIndex < 0 {
  1386. return ErrInvalidLengthTypes
  1387. }
  1388. if postIndex > l {
  1389. return io.ErrUnexpectedEOF
  1390. }
  1391. if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(&m.LastBlockTime, dAtA[iNdEx:postIndex]); err != nil {
  1392. return err
  1393. }
  1394. iNdEx = postIndex
  1395. case 6:
  1396. if wireType != 2 {
  1397. return fmt.Errorf("proto: wrong wireType = %d for field NextValidators", wireType)
  1398. }
  1399. var msglen int
  1400. for shift := uint(0); ; shift += 7 {
  1401. if shift >= 64 {
  1402. return ErrIntOverflowTypes
  1403. }
  1404. if iNdEx >= l {
  1405. return io.ErrUnexpectedEOF
  1406. }
  1407. b := dAtA[iNdEx]
  1408. iNdEx++
  1409. msglen |= int(b&0x7F) << shift
  1410. if b < 0x80 {
  1411. break
  1412. }
  1413. }
  1414. if msglen < 0 {
  1415. return ErrInvalidLengthTypes
  1416. }
  1417. postIndex := iNdEx + msglen
  1418. if postIndex < 0 {
  1419. return ErrInvalidLengthTypes
  1420. }
  1421. if postIndex > l {
  1422. return io.ErrUnexpectedEOF
  1423. }
  1424. if m.NextValidators == nil {
  1425. m.NextValidators = &types1.ValidatorSet{}
  1426. }
  1427. if err := m.NextValidators.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1428. return err
  1429. }
  1430. iNdEx = postIndex
  1431. case 7:
  1432. if wireType != 2 {
  1433. return fmt.Errorf("proto: wrong wireType = %d for field Validators", wireType)
  1434. }
  1435. var msglen int
  1436. for shift := uint(0); ; shift += 7 {
  1437. if shift >= 64 {
  1438. return ErrIntOverflowTypes
  1439. }
  1440. if iNdEx >= l {
  1441. return io.ErrUnexpectedEOF
  1442. }
  1443. b := dAtA[iNdEx]
  1444. iNdEx++
  1445. msglen |= int(b&0x7F) << shift
  1446. if b < 0x80 {
  1447. break
  1448. }
  1449. }
  1450. if msglen < 0 {
  1451. return ErrInvalidLengthTypes
  1452. }
  1453. postIndex := iNdEx + msglen
  1454. if postIndex < 0 {
  1455. return ErrInvalidLengthTypes
  1456. }
  1457. if postIndex > l {
  1458. return io.ErrUnexpectedEOF
  1459. }
  1460. if m.Validators == nil {
  1461. m.Validators = &types1.ValidatorSet{}
  1462. }
  1463. if err := m.Validators.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1464. return err
  1465. }
  1466. iNdEx = postIndex
  1467. case 8:
  1468. if wireType != 2 {
  1469. return fmt.Errorf("proto: wrong wireType = %d for field LastValidators", wireType)
  1470. }
  1471. var msglen int
  1472. for shift := uint(0); ; shift += 7 {
  1473. if shift >= 64 {
  1474. return ErrIntOverflowTypes
  1475. }
  1476. if iNdEx >= l {
  1477. return io.ErrUnexpectedEOF
  1478. }
  1479. b := dAtA[iNdEx]
  1480. iNdEx++
  1481. msglen |= int(b&0x7F) << shift
  1482. if b < 0x80 {
  1483. break
  1484. }
  1485. }
  1486. if msglen < 0 {
  1487. return ErrInvalidLengthTypes
  1488. }
  1489. postIndex := iNdEx + msglen
  1490. if postIndex < 0 {
  1491. return ErrInvalidLengthTypes
  1492. }
  1493. if postIndex > l {
  1494. return io.ErrUnexpectedEOF
  1495. }
  1496. if m.LastValidators == nil {
  1497. m.LastValidators = &types1.ValidatorSet{}
  1498. }
  1499. if err := m.LastValidators.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1500. return err
  1501. }
  1502. iNdEx = postIndex
  1503. case 9:
  1504. if wireType != 0 {
  1505. return fmt.Errorf("proto: wrong wireType = %d for field LastHeightValidatorsChanged", wireType)
  1506. }
  1507. m.LastHeightValidatorsChanged = 0
  1508. for shift := uint(0); ; shift += 7 {
  1509. if shift >= 64 {
  1510. return ErrIntOverflowTypes
  1511. }
  1512. if iNdEx >= l {
  1513. return io.ErrUnexpectedEOF
  1514. }
  1515. b := dAtA[iNdEx]
  1516. iNdEx++
  1517. m.LastHeightValidatorsChanged |= int64(b&0x7F) << shift
  1518. if b < 0x80 {
  1519. break
  1520. }
  1521. }
  1522. case 10:
  1523. if wireType != 2 {
  1524. return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParams", wireType)
  1525. }
  1526. var msglen int
  1527. for shift := uint(0); ; shift += 7 {
  1528. if shift >= 64 {
  1529. return ErrIntOverflowTypes
  1530. }
  1531. if iNdEx >= l {
  1532. return io.ErrUnexpectedEOF
  1533. }
  1534. b := dAtA[iNdEx]
  1535. iNdEx++
  1536. msglen |= int(b&0x7F) << shift
  1537. if b < 0x80 {
  1538. break
  1539. }
  1540. }
  1541. if msglen < 0 {
  1542. return ErrInvalidLengthTypes
  1543. }
  1544. postIndex := iNdEx + msglen
  1545. if postIndex < 0 {
  1546. return ErrInvalidLengthTypes
  1547. }
  1548. if postIndex > l {
  1549. return io.ErrUnexpectedEOF
  1550. }
  1551. if err := m.ConsensusParams.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  1552. return err
  1553. }
  1554. iNdEx = postIndex
  1555. case 11:
  1556. if wireType != 0 {
  1557. return fmt.Errorf("proto: wrong wireType = %d for field LastHeightConsensusParamsChanged", wireType)
  1558. }
  1559. m.LastHeightConsensusParamsChanged = 0
  1560. for shift := uint(0); ; shift += 7 {
  1561. if shift >= 64 {
  1562. return ErrIntOverflowTypes
  1563. }
  1564. if iNdEx >= l {
  1565. return io.ErrUnexpectedEOF
  1566. }
  1567. b := dAtA[iNdEx]
  1568. iNdEx++
  1569. m.LastHeightConsensusParamsChanged |= int64(b&0x7F) << shift
  1570. if b < 0x80 {
  1571. break
  1572. }
  1573. }
  1574. case 12:
  1575. if wireType != 2 {
  1576. return fmt.Errorf("proto: wrong wireType = %d for field LastResultsHash", wireType)
  1577. }
  1578. var byteLen int
  1579. for shift := uint(0); ; shift += 7 {
  1580. if shift >= 64 {
  1581. return ErrIntOverflowTypes
  1582. }
  1583. if iNdEx >= l {
  1584. return io.ErrUnexpectedEOF
  1585. }
  1586. b := dAtA[iNdEx]
  1587. iNdEx++
  1588. byteLen |= int(b&0x7F) << shift
  1589. if b < 0x80 {
  1590. break
  1591. }
  1592. }
  1593. if byteLen < 0 {
  1594. return ErrInvalidLengthTypes
  1595. }
  1596. postIndex := iNdEx + byteLen
  1597. if postIndex < 0 {
  1598. return ErrInvalidLengthTypes
  1599. }
  1600. if postIndex > l {
  1601. return io.ErrUnexpectedEOF
  1602. }
  1603. m.LastResultsHash = append(m.LastResultsHash[:0], dAtA[iNdEx:postIndex]...)
  1604. if m.LastResultsHash == nil {
  1605. m.LastResultsHash = []byte{}
  1606. }
  1607. iNdEx = postIndex
  1608. case 13:
  1609. if wireType != 2 {
  1610. return fmt.Errorf("proto: wrong wireType = %d for field AppHash", wireType)
  1611. }
  1612. var byteLen int
  1613. for shift := uint(0); ; shift += 7 {
  1614. if shift >= 64 {
  1615. return ErrIntOverflowTypes
  1616. }
  1617. if iNdEx >= l {
  1618. return io.ErrUnexpectedEOF
  1619. }
  1620. b := dAtA[iNdEx]
  1621. iNdEx++
  1622. byteLen |= int(b&0x7F) << shift
  1623. if b < 0x80 {
  1624. break
  1625. }
  1626. }
  1627. if byteLen < 0 {
  1628. return ErrInvalidLengthTypes
  1629. }
  1630. postIndex := iNdEx + byteLen
  1631. if postIndex < 0 {
  1632. return ErrInvalidLengthTypes
  1633. }
  1634. if postIndex > l {
  1635. return io.ErrUnexpectedEOF
  1636. }
  1637. m.AppHash = append(m.AppHash[:0], dAtA[iNdEx:postIndex]...)
  1638. if m.AppHash == nil {
  1639. m.AppHash = []byte{}
  1640. }
  1641. iNdEx = postIndex
  1642. case 14:
  1643. if wireType != 0 {
  1644. return fmt.Errorf("proto: wrong wireType = %d for field InitialHeight", wireType)
  1645. }
  1646. m.InitialHeight = 0
  1647. for shift := uint(0); ; shift += 7 {
  1648. if shift >= 64 {
  1649. return ErrIntOverflowTypes
  1650. }
  1651. if iNdEx >= l {
  1652. return io.ErrUnexpectedEOF
  1653. }
  1654. b := dAtA[iNdEx]
  1655. iNdEx++
  1656. m.InitialHeight |= int64(b&0x7F) << shift
  1657. if b < 0x80 {
  1658. break
  1659. }
  1660. }
  1661. default:
  1662. iNdEx = preIndex
  1663. skippy, err := skipTypes(dAtA[iNdEx:])
  1664. if err != nil {
  1665. return err
  1666. }
  1667. if (skippy < 0) || (iNdEx+skippy) < 0 {
  1668. return ErrInvalidLengthTypes
  1669. }
  1670. if (iNdEx + skippy) > l {
  1671. return io.ErrUnexpectedEOF
  1672. }
  1673. iNdEx += skippy
  1674. }
  1675. }
  1676. if iNdEx > l {
  1677. return io.ErrUnexpectedEOF
  1678. }
  1679. return nil
  1680. }
  1681. func skipTypes(dAtA []byte) (n int, err error) {
  1682. l := len(dAtA)
  1683. iNdEx := 0
  1684. depth := 0
  1685. for iNdEx < l {
  1686. var wire uint64
  1687. for shift := uint(0); ; shift += 7 {
  1688. if shift >= 64 {
  1689. return 0, ErrIntOverflowTypes
  1690. }
  1691. if iNdEx >= l {
  1692. return 0, io.ErrUnexpectedEOF
  1693. }
  1694. b := dAtA[iNdEx]
  1695. iNdEx++
  1696. wire |= (uint64(b) & 0x7F) << shift
  1697. if b < 0x80 {
  1698. break
  1699. }
  1700. }
  1701. wireType := int(wire & 0x7)
  1702. switch wireType {
  1703. case 0:
  1704. for shift := uint(0); ; shift += 7 {
  1705. if shift >= 64 {
  1706. return 0, ErrIntOverflowTypes
  1707. }
  1708. if iNdEx >= l {
  1709. return 0, io.ErrUnexpectedEOF
  1710. }
  1711. iNdEx++
  1712. if dAtA[iNdEx-1] < 0x80 {
  1713. break
  1714. }
  1715. }
  1716. case 1:
  1717. iNdEx += 8
  1718. case 2:
  1719. var length int
  1720. for shift := uint(0); ; shift += 7 {
  1721. if shift >= 64 {
  1722. return 0, ErrIntOverflowTypes
  1723. }
  1724. if iNdEx >= l {
  1725. return 0, io.ErrUnexpectedEOF
  1726. }
  1727. b := dAtA[iNdEx]
  1728. iNdEx++
  1729. length |= (int(b) & 0x7F) << shift
  1730. if b < 0x80 {
  1731. break
  1732. }
  1733. }
  1734. if length < 0 {
  1735. return 0, ErrInvalidLengthTypes
  1736. }
  1737. iNdEx += length
  1738. case 3:
  1739. depth++
  1740. case 4:
  1741. if depth == 0 {
  1742. return 0, ErrUnexpectedEndOfGroupTypes
  1743. }
  1744. depth--
  1745. case 5:
  1746. iNdEx += 4
  1747. default:
  1748. return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  1749. }
  1750. if iNdEx < 0 {
  1751. return 0, ErrInvalidLengthTypes
  1752. }
  1753. if depth == 0 {
  1754. return iNdEx, nil
  1755. }
  1756. }
  1757. return 0, io.ErrUnexpectedEOF
  1758. }
  1759. var (
  1760. ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling")
  1761. ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow")
  1762. ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group")
  1763. )