@burnt-labs/xion-types 16.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/README.md +111 -0
  2. package/package.json +26 -0
  3. package/types/.gitkeep +0 -0
  4. package/types/generated/amino/amino.ts +9 -0
  5. package/types/generated/cosmos/app/v1alpha1/config.ts +336 -0
  6. package/types/generated/cosmos/app/v1alpha1/query.ts +265 -0
  7. package/types/generated/cosmos/auth/v1beta1/auth.ts +520 -0
  8. package/types/generated/cosmos/auth/v1beta1/query.ts +1852 -0
  9. package/types/generated/cosmos/authz/v1beta1/authz.ts +404 -0
  10. package/types/generated/cosmos/authz/v1beta1/query.ts +774 -0
  11. package/types/generated/cosmos/autocli/v1/options.ts +1016 -0
  12. package/types/generated/cosmos/autocli/v1/query.ts +379 -0
  13. package/types/generated/cosmos/bank/v1beta1/bank.ts +752 -0
  14. package/types/generated/cosmos/bank/v1beta1/query.ts +2789 -0
  15. package/types/generated/cosmos/base/abci/v1beta1/abci.ts +1447 -0
  16. package/types/generated/cosmos/base/node/v1beta1/query.ts +587 -0
  17. package/types/generated/cosmos/base/query/v1beta1/pagination.ts +317 -0
  18. package/types/generated/cosmos/base/tendermint/v1beta1/query.ts +2228 -0
  19. package/types/generated/cosmos/base/tendermint/v1beta1/types.ts +522 -0
  20. package/types/generated/cosmos/base/v1beta1/coin.ts +326 -0
  21. package/types/generated/cosmos/circuit/v1/query.ts +606 -0
  22. package/types/generated/cosmos/circuit/v1/types.ts +353 -0
  23. package/types/generated/cosmos/consensus/v1/query.ts +271 -0
  24. package/types/generated/cosmos/crypto/multisig/v1beta1/multisig.ts +212 -0
  25. package/types/generated/cosmos/distribution/v1beta1/distribution.ts +1143 -0
  26. package/types/generated/cosmos/distribution/v1beta1/query.ts +2005 -0
  27. package/types/generated/cosmos/evidence/v1beta1/query.ts +526 -0
  28. package/types/generated/cosmos/feegrant/v1beta1/feegrant.ts +502 -0
  29. package/types/generated/cosmos/feegrant/v1beta1/query.ts +725 -0
  30. package/types/generated/cosmos/gov/v1/gov.ts +1656 -0
  31. package/types/generated/cosmos/gov/v1/query.ts +1847 -0
  32. package/types/generated/cosmos/gov/v1beta1/gov.ts +1239 -0
  33. package/types/generated/cosmos/gov/v1beta1/query.ts +1658 -0
  34. package/types/generated/cosmos/group/v1/query.ts +2840 -0
  35. package/types/generated/cosmos/group/v1/types.ts +1803 -0
  36. package/types/generated/cosmos/ics23/v1/proofs.ts +1685 -0
  37. package/types/generated/cosmos/mint/v1beta1/mint.ts +273 -0
  38. package/types/generated/cosmos/mint/v1beta1/query.ts +589 -0
  39. package/types/generated/cosmos/msg/v1/msg.ts +9 -0
  40. package/types/generated/cosmos/nft/v1beta1/nft.ts +333 -0
  41. package/types/generated/cosmos/nft/v1beta1/query.ts +1362 -0
  42. package/types/generated/cosmos/orm/query/v1alpha1/query.ts +1016 -0
  43. package/types/generated/cosmos/params/v1beta1/params.ts +227 -0
  44. package/types/generated/cosmos/params/v1beta1/query.ts +545 -0
  45. package/types/generated/cosmos/query/v1/query.ts +9 -0
  46. package/types/generated/cosmos/slashing/v1beta1/query.ts +626 -0
  47. package/types/generated/cosmos/slashing/v1beta1/slashing.ts +409 -0
  48. package/types/generated/cosmos/staking/v1beta1/query.ts +2912 -0
  49. package/types/generated/cosmos/staking/v1beta1/staking.ts +2515 -0
  50. package/types/generated/cosmos/tx/signing/v1beta1/signing.ts +608 -0
  51. package/types/generated/cosmos/tx/v1beta1/service.ts +2111 -0
  52. package/types/generated/cosmos/tx/v1beta1/tx.ts +1613 -0
  53. package/types/generated/cosmos/upgrade/v1beta1/query.ts +1007 -0
  54. package/types/generated/cosmos/upgrade/v1beta1/upgrade.ts +507 -0
  55. package/types/generated/cosmos_proto/cosmos.ts +299 -0
  56. package/types/generated/cosmwasm/wasm/v1/query.ts +2984 -0
  57. package/types/generated/cosmwasm/wasm/v1/types.ts +962 -0
  58. package/types/generated/gogoproto/gogo.ts +9 -0
  59. package/types/generated/google/api/annotations.ts +9 -0
  60. package/types/generated/google/api/http.ts +757 -0
  61. package/types/generated/google/protobuf/any.ts +253 -0
  62. package/types/generated/google/protobuf/descriptor.ts +4958 -0
  63. package/types/generated/google/protobuf/duration.ts +186 -0
  64. package/types/generated/google/protobuf/timestamp.ts +215 -0
  65. package/types/generated/ibc/applications/fee/v1/fee.ts +391 -0
  66. package/types/generated/ibc/applications/fee/v1/genesis.ts +553 -0
  67. package/types/generated/ibc/applications/fee/v1/query.ts +2056 -0
  68. package/types/generated/ibc/applications/interchain_accounts/controller/v1/controller.ts +100 -0
  69. package/types/generated/ibc/applications/interchain_accounts/controller/v1/query.ts +447 -0
  70. package/types/generated/ibc/applications/interchain_accounts/host/v1/host.ts +235 -0
  71. package/types/generated/ibc/applications/interchain_accounts/host/v1/query.ts +265 -0
  72. package/types/generated/ibc/applications/transfer/v1/query.ts +1135 -0
  73. package/types/generated/ibc/applications/transfer/v1/transfer.ts +213 -0
  74. package/types/generated/ibc/core/channel/v1/channel.ts +1329 -0
  75. package/types/generated/ibc/core/channel/v1/query.ts +4214 -0
  76. package/types/generated/ibc/core/channel/v1/upgrade.ts +330 -0
  77. package/types/generated/ibc/core/client/v1/client.ts +726 -0
  78. package/types/generated/ibc/core/client/v1/query.ts +2208 -0
  79. package/types/generated/ibc/core/commitment/v1/commitment.ts +329 -0
  80. package/types/generated/ibc/core/connection/v1/connection.ts +813 -0
  81. package/types/generated/ibc/core/connection/v1/query.ts +1442 -0
  82. package/types/generated/ibc/lightclients/wasm/v1/query.ts +484 -0
  83. package/types/generated/tendermint/abci/types.ts +6429 -0
  84. package/types/generated/tendermint/crypto/keys.ts +137 -0
  85. package/types/generated/tendermint/crypto/proof.ts +506 -0
  86. package/types/generated/tendermint/p2p/types.ts +514 -0
  87. package/types/generated/tendermint/types/block.ts +151 -0
  88. package/types/generated/tendermint/types/evidence.ts +493 -0
  89. package/types/generated/tendermint/types/params.ts +687 -0
  90. package/types/generated/tendermint/types/types.ts +2069 -0
  91. package/types/generated/tendermint/types/validator.ts +409 -0
  92. package/types/generated/tendermint/version/types.ts +202 -0
  93. package/types/generated/xion/globalfee/v1/genesis.ts +219 -0
  94. package/types/generated/xion/globalfee/v1/query.ts +269 -0
  95. package/types/generated/xion/jwk/v1/audience.ts +188 -0
  96. package/types/generated/xion/jwk/v1/params.ts +118 -0
  97. package/types/generated/xion/jwk/v1/query.ts +1061 -0
  98. package/types/generated/xion/mint/v1/mint.ts +273 -0
  99. package/types/generated/xion/mint/v1/query.ts +589 -0
  100. package/types/generated/xion/v1/query.ts +878 -0
@@ -0,0 +1,687 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v1.181.2
4
+ // protoc unknown
5
+ // source: tendermint/types/params.proto
6
+
7
+ /* eslint-disable */
8
+ import Long from "long";
9
+ import _m0 from "protobufjs/minimal";
10
+ import { Duration } from "../../google/protobuf/duration";
11
+
12
+ export const protobufPackage = "tendermint.types";
13
+
14
+ /**
15
+ * ConsensusParams contains consensus critical parameters that determine the
16
+ * validity of blocks.
17
+ */
18
+ export interface ConsensusParams {
19
+ block?: BlockParams | undefined;
20
+ evidence?: EvidenceParams | undefined;
21
+ validator?: ValidatorParams | undefined;
22
+ version?: VersionParams | undefined;
23
+ abci?: ABCIParams | undefined;
24
+ }
25
+
26
+ /** BlockParams contains limits on the block size. */
27
+ export interface BlockParams {
28
+ /**
29
+ * Max block size, in bytes.
30
+ * Note: must be greater than 0
31
+ */
32
+ maxBytes: Long;
33
+ /**
34
+ * Max gas per block.
35
+ * Note: must be greater or equal to -1
36
+ */
37
+ maxGas: Long;
38
+ }
39
+
40
+ /** EvidenceParams determine how we handle evidence of malfeasance. */
41
+ export interface EvidenceParams {
42
+ /**
43
+ * Max age of evidence, in blocks.
44
+ *
45
+ * The basic formula for calculating this is: MaxAgeDuration / {average block
46
+ * time}.
47
+ */
48
+ maxAgeNumBlocks: Long;
49
+ /**
50
+ * Max age of evidence, in time.
51
+ *
52
+ * It should correspond with an app's "unbonding period" or other similar
53
+ * mechanism for handling [Nothing-At-Stake
54
+ * attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed).
55
+ */
56
+ maxAgeDuration?:
57
+ | Duration
58
+ | undefined;
59
+ /**
60
+ * This sets the maximum size of total evidence in bytes that can be committed in a single block.
61
+ * and should fall comfortably under the max block bytes.
62
+ * Default is 1048576 or 1MB
63
+ */
64
+ maxBytes: Long;
65
+ }
66
+
67
+ /**
68
+ * ValidatorParams restrict the public key types validators can use.
69
+ * NOTE: uses ABCI pubkey naming, not Amino names.
70
+ */
71
+ export interface ValidatorParams {
72
+ pubKeyTypes: string[];
73
+ }
74
+
75
+ /** VersionParams contains the ABCI application version. */
76
+ export interface VersionParams {
77
+ app: Long;
78
+ }
79
+
80
+ /**
81
+ * HashedParams is a subset of ConsensusParams.
82
+ *
83
+ * It is hashed into the Header.ConsensusHash.
84
+ */
85
+ export interface HashedParams {
86
+ blockMaxBytes: Long;
87
+ blockMaxGas: Long;
88
+ }
89
+
90
+ /** ABCIParams configure functionality specific to the Application Blockchain Interface. */
91
+ export interface ABCIParams {
92
+ /**
93
+ * vote_extensions_enable_height configures the first height during which
94
+ * vote extensions will be enabled. During this specified height, and for all
95
+ * subsequent heights, precommit messages that do not contain valid extension data
96
+ * will be considered invalid. Prior to this height, vote extensions will not
97
+ * be used or accepted by validators on the network.
98
+ *
99
+ * Once enabled, vote extensions will be created by the application in ExtendVote,
100
+ * passed to the application for validation in VerifyVoteExtension and given
101
+ * to the application to use when proposing a block during PrepareProposal.
102
+ */
103
+ voteExtensionsEnableHeight: Long;
104
+ }
105
+
106
+ function createBaseConsensusParams(): ConsensusParams {
107
+ return { block: undefined, evidence: undefined, validator: undefined, version: undefined, abci: undefined };
108
+ }
109
+
110
+ export const ConsensusParams = {
111
+ encode(message: ConsensusParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
112
+ if (message.block !== undefined) {
113
+ BlockParams.encode(message.block, writer.uint32(10).fork()).ldelim();
114
+ }
115
+ if (message.evidence !== undefined) {
116
+ EvidenceParams.encode(message.evidence, writer.uint32(18).fork()).ldelim();
117
+ }
118
+ if (message.validator !== undefined) {
119
+ ValidatorParams.encode(message.validator, writer.uint32(26).fork()).ldelim();
120
+ }
121
+ if (message.version !== undefined) {
122
+ VersionParams.encode(message.version, writer.uint32(34).fork()).ldelim();
123
+ }
124
+ if (message.abci !== undefined) {
125
+ ABCIParams.encode(message.abci, writer.uint32(42).fork()).ldelim();
126
+ }
127
+ return writer;
128
+ },
129
+
130
+ decode(input: _m0.Reader | Uint8Array, length?: number): ConsensusParams {
131
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
132
+ let end = length === undefined ? reader.len : reader.pos + length;
133
+ const message = createBaseConsensusParams();
134
+ while (reader.pos < end) {
135
+ const tag = reader.uint32();
136
+ switch (tag >>> 3) {
137
+ case 1:
138
+ if (tag !== 10) {
139
+ break;
140
+ }
141
+
142
+ message.block = BlockParams.decode(reader, reader.uint32());
143
+ continue;
144
+ case 2:
145
+ if (tag !== 18) {
146
+ break;
147
+ }
148
+
149
+ message.evidence = EvidenceParams.decode(reader, reader.uint32());
150
+ continue;
151
+ case 3:
152
+ if (tag !== 26) {
153
+ break;
154
+ }
155
+
156
+ message.validator = ValidatorParams.decode(reader, reader.uint32());
157
+ continue;
158
+ case 4:
159
+ if (tag !== 34) {
160
+ break;
161
+ }
162
+
163
+ message.version = VersionParams.decode(reader, reader.uint32());
164
+ continue;
165
+ case 5:
166
+ if (tag !== 42) {
167
+ break;
168
+ }
169
+
170
+ message.abci = ABCIParams.decode(reader, reader.uint32());
171
+ continue;
172
+ }
173
+ if ((tag & 7) === 4 || tag === 0) {
174
+ break;
175
+ }
176
+ reader.skipType(tag & 7);
177
+ }
178
+ return message;
179
+ },
180
+
181
+ fromJSON(object: any): ConsensusParams {
182
+ return {
183
+ block: isSet(object.block) ? BlockParams.fromJSON(object.block) : undefined,
184
+ evidence: isSet(object.evidence) ? EvidenceParams.fromJSON(object.evidence) : undefined,
185
+ validator: isSet(object.validator) ? ValidatorParams.fromJSON(object.validator) : undefined,
186
+ version: isSet(object.version) ? VersionParams.fromJSON(object.version) : undefined,
187
+ abci: isSet(object.abci) ? ABCIParams.fromJSON(object.abci) : undefined,
188
+ };
189
+ },
190
+
191
+ toJSON(message: ConsensusParams): unknown {
192
+ const obj: any = {};
193
+ if (message.block !== undefined) {
194
+ obj.block = BlockParams.toJSON(message.block);
195
+ }
196
+ if (message.evidence !== undefined) {
197
+ obj.evidence = EvidenceParams.toJSON(message.evidence);
198
+ }
199
+ if (message.validator !== undefined) {
200
+ obj.validator = ValidatorParams.toJSON(message.validator);
201
+ }
202
+ if (message.version !== undefined) {
203
+ obj.version = VersionParams.toJSON(message.version);
204
+ }
205
+ if (message.abci !== undefined) {
206
+ obj.abci = ABCIParams.toJSON(message.abci);
207
+ }
208
+ return obj;
209
+ },
210
+
211
+ create<I extends Exact<DeepPartial<ConsensusParams>, I>>(base?: I): ConsensusParams {
212
+ return ConsensusParams.fromPartial(base ?? ({} as any));
213
+ },
214
+ fromPartial<I extends Exact<DeepPartial<ConsensusParams>, I>>(object: I): ConsensusParams {
215
+ const message = createBaseConsensusParams();
216
+ message.block = (object.block !== undefined && object.block !== null)
217
+ ? BlockParams.fromPartial(object.block)
218
+ : undefined;
219
+ message.evidence = (object.evidence !== undefined && object.evidence !== null)
220
+ ? EvidenceParams.fromPartial(object.evidence)
221
+ : undefined;
222
+ message.validator = (object.validator !== undefined && object.validator !== null)
223
+ ? ValidatorParams.fromPartial(object.validator)
224
+ : undefined;
225
+ message.version = (object.version !== undefined && object.version !== null)
226
+ ? VersionParams.fromPartial(object.version)
227
+ : undefined;
228
+ message.abci = (object.abci !== undefined && object.abci !== null)
229
+ ? ABCIParams.fromPartial(object.abci)
230
+ : undefined;
231
+ return message;
232
+ },
233
+ };
234
+
235
+ function createBaseBlockParams(): BlockParams {
236
+ return { maxBytes: Long.ZERO, maxGas: Long.ZERO };
237
+ }
238
+
239
+ export const BlockParams = {
240
+ encode(message: BlockParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
241
+ if (!message.maxBytes.equals(Long.ZERO)) {
242
+ writer.uint32(8).int64(message.maxBytes);
243
+ }
244
+ if (!message.maxGas.equals(Long.ZERO)) {
245
+ writer.uint32(16).int64(message.maxGas);
246
+ }
247
+ return writer;
248
+ },
249
+
250
+ decode(input: _m0.Reader | Uint8Array, length?: number): BlockParams {
251
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
252
+ let end = length === undefined ? reader.len : reader.pos + length;
253
+ const message = createBaseBlockParams();
254
+ while (reader.pos < end) {
255
+ const tag = reader.uint32();
256
+ switch (tag >>> 3) {
257
+ case 1:
258
+ if (tag !== 8) {
259
+ break;
260
+ }
261
+
262
+ message.maxBytes = reader.int64() as Long;
263
+ continue;
264
+ case 2:
265
+ if (tag !== 16) {
266
+ break;
267
+ }
268
+
269
+ message.maxGas = reader.int64() as Long;
270
+ continue;
271
+ }
272
+ if ((tag & 7) === 4 || tag === 0) {
273
+ break;
274
+ }
275
+ reader.skipType(tag & 7);
276
+ }
277
+ return message;
278
+ },
279
+
280
+ fromJSON(object: any): BlockParams {
281
+ return {
282
+ maxBytes: isSet(object.maxBytes) ? Long.fromValue(object.maxBytes) : Long.ZERO,
283
+ maxGas: isSet(object.maxGas) ? Long.fromValue(object.maxGas) : Long.ZERO,
284
+ };
285
+ },
286
+
287
+ toJSON(message: BlockParams): unknown {
288
+ const obj: any = {};
289
+ if (!message.maxBytes.equals(Long.ZERO)) {
290
+ obj.maxBytes = (message.maxBytes || Long.ZERO).toString();
291
+ }
292
+ if (!message.maxGas.equals(Long.ZERO)) {
293
+ obj.maxGas = (message.maxGas || Long.ZERO).toString();
294
+ }
295
+ return obj;
296
+ },
297
+
298
+ create<I extends Exact<DeepPartial<BlockParams>, I>>(base?: I): BlockParams {
299
+ return BlockParams.fromPartial(base ?? ({} as any));
300
+ },
301
+ fromPartial<I extends Exact<DeepPartial<BlockParams>, I>>(object: I): BlockParams {
302
+ const message = createBaseBlockParams();
303
+ message.maxBytes = (object.maxBytes !== undefined && object.maxBytes !== null)
304
+ ? Long.fromValue(object.maxBytes)
305
+ : Long.ZERO;
306
+ message.maxGas = (object.maxGas !== undefined && object.maxGas !== null)
307
+ ? Long.fromValue(object.maxGas)
308
+ : Long.ZERO;
309
+ return message;
310
+ },
311
+ };
312
+
313
+ function createBaseEvidenceParams(): EvidenceParams {
314
+ return { maxAgeNumBlocks: Long.ZERO, maxAgeDuration: undefined, maxBytes: Long.ZERO };
315
+ }
316
+
317
+ export const EvidenceParams = {
318
+ encode(message: EvidenceParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
319
+ if (!message.maxAgeNumBlocks.equals(Long.ZERO)) {
320
+ writer.uint32(8).int64(message.maxAgeNumBlocks);
321
+ }
322
+ if (message.maxAgeDuration !== undefined) {
323
+ Duration.encode(message.maxAgeDuration, writer.uint32(18).fork()).ldelim();
324
+ }
325
+ if (!message.maxBytes.equals(Long.ZERO)) {
326
+ writer.uint32(24).int64(message.maxBytes);
327
+ }
328
+ return writer;
329
+ },
330
+
331
+ decode(input: _m0.Reader | Uint8Array, length?: number): EvidenceParams {
332
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
333
+ let end = length === undefined ? reader.len : reader.pos + length;
334
+ const message = createBaseEvidenceParams();
335
+ while (reader.pos < end) {
336
+ const tag = reader.uint32();
337
+ switch (tag >>> 3) {
338
+ case 1:
339
+ if (tag !== 8) {
340
+ break;
341
+ }
342
+
343
+ message.maxAgeNumBlocks = reader.int64() as Long;
344
+ continue;
345
+ case 2:
346
+ if (tag !== 18) {
347
+ break;
348
+ }
349
+
350
+ message.maxAgeDuration = Duration.decode(reader, reader.uint32());
351
+ continue;
352
+ case 3:
353
+ if (tag !== 24) {
354
+ break;
355
+ }
356
+
357
+ message.maxBytes = reader.int64() as Long;
358
+ continue;
359
+ }
360
+ if ((tag & 7) === 4 || tag === 0) {
361
+ break;
362
+ }
363
+ reader.skipType(tag & 7);
364
+ }
365
+ return message;
366
+ },
367
+
368
+ fromJSON(object: any): EvidenceParams {
369
+ return {
370
+ maxAgeNumBlocks: isSet(object.maxAgeNumBlocks) ? Long.fromValue(object.maxAgeNumBlocks) : Long.ZERO,
371
+ maxAgeDuration: isSet(object.maxAgeDuration) ? Duration.fromJSON(object.maxAgeDuration) : undefined,
372
+ maxBytes: isSet(object.maxBytes) ? Long.fromValue(object.maxBytes) : Long.ZERO,
373
+ };
374
+ },
375
+
376
+ toJSON(message: EvidenceParams): unknown {
377
+ const obj: any = {};
378
+ if (!message.maxAgeNumBlocks.equals(Long.ZERO)) {
379
+ obj.maxAgeNumBlocks = (message.maxAgeNumBlocks || Long.ZERO).toString();
380
+ }
381
+ if (message.maxAgeDuration !== undefined) {
382
+ obj.maxAgeDuration = Duration.toJSON(message.maxAgeDuration);
383
+ }
384
+ if (!message.maxBytes.equals(Long.ZERO)) {
385
+ obj.maxBytes = (message.maxBytes || Long.ZERO).toString();
386
+ }
387
+ return obj;
388
+ },
389
+
390
+ create<I extends Exact<DeepPartial<EvidenceParams>, I>>(base?: I): EvidenceParams {
391
+ return EvidenceParams.fromPartial(base ?? ({} as any));
392
+ },
393
+ fromPartial<I extends Exact<DeepPartial<EvidenceParams>, I>>(object: I): EvidenceParams {
394
+ const message = createBaseEvidenceParams();
395
+ message.maxAgeNumBlocks = (object.maxAgeNumBlocks !== undefined && object.maxAgeNumBlocks !== null)
396
+ ? Long.fromValue(object.maxAgeNumBlocks)
397
+ : Long.ZERO;
398
+ message.maxAgeDuration = (object.maxAgeDuration !== undefined && object.maxAgeDuration !== null)
399
+ ? Duration.fromPartial(object.maxAgeDuration)
400
+ : undefined;
401
+ message.maxBytes = (object.maxBytes !== undefined && object.maxBytes !== null)
402
+ ? Long.fromValue(object.maxBytes)
403
+ : Long.ZERO;
404
+ return message;
405
+ },
406
+ };
407
+
408
+ function createBaseValidatorParams(): ValidatorParams {
409
+ return { pubKeyTypes: [] };
410
+ }
411
+
412
+ export const ValidatorParams = {
413
+ encode(message: ValidatorParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
414
+ for (const v of message.pubKeyTypes) {
415
+ writer.uint32(10).string(v!);
416
+ }
417
+ return writer;
418
+ },
419
+
420
+ decode(input: _m0.Reader | Uint8Array, length?: number): ValidatorParams {
421
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
422
+ let end = length === undefined ? reader.len : reader.pos + length;
423
+ const message = createBaseValidatorParams();
424
+ while (reader.pos < end) {
425
+ const tag = reader.uint32();
426
+ switch (tag >>> 3) {
427
+ case 1:
428
+ if (tag !== 10) {
429
+ break;
430
+ }
431
+
432
+ message.pubKeyTypes.push(reader.string());
433
+ continue;
434
+ }
435
+ if ((tag & 7) === 4 || tag === 0) {
436
+ break;
437
+ }
438
+ reader.skipType(tag & 7);
439
+ }
440
+ return message;
441
+ },
442
+
443
+ fromJSON(object: any): ValidatorParams {
444
+ return {
445
+ pubKeyTypes: globalThis.Array.isArray(object?.pubKeyTypes)
446
+ ? object.pubKeyTypes.map((e: any) => globalThis.String(e))
447
+ : [],
448
+ };
449
+ },
450
+
451
+ toJSON(message: ValidatorParams): unknown {
452
+ const obj: any = {};
453
+ if (message.pubKeyTypes?.length) {
454
+ obj.pubKeyTypes = message.pubKeyTypes;
455
+ }
456
+ return obj;
457
+ },
458
+
459
+ create<I extends Exact<DeepPartial<ValidatorParams>, I>>(base?: I): ValidatorParams {
460
+ return ValidatorParams.fromPartial(base ?? ({} as any));
461
+ },
462
+ fromPartial<I extends Exact<DeepPartial<ValidatorParams>, I>>(object: I): ValidatorParams {
463
+ const message = createBaseValidatorParams();
464
+ message.pubKeyTypes = object.pubKeyTypes?.map((e) => e) || [];
465
+ return message;
466
+ },
467
+ };
468
+
469
+ function createBaseVersionParams(): VersionParams {
470
+ return { app: Long.UZERO };
471
+ }
472
+
473
+ export const VersionParams = {
474
+ encode(message: VersionParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
475
+ if (!message.app.equals(Long.UZERO)) {
476
+ writer.uint32(8).uint64(message.app);
477
+ }
478
+ return writer;
479
+ },
480
+
481
+ decode(input: _m0.Reader | Uint8Array, length?: number): VersionParams {
482
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
483
+ let end = length === undefined ? reader.len : reader.pos + length;
484
+ const message = createBaseVersionParams();
485
+ while (reader.pos < end) {
486
+ const tag = reader.uint32();
487
+ switch (tag >>> 3) {
488
+ case 1:
489
+ if (tag !== 8) {
490
+ break;
491
+ }
492
+
493
+ message.app = reader.uint64() as Long;
494
+ continue;
495
+ }
496
+ if ((tag & 7) === 4 || tag === 0) {
497
+ break;
498
+ }
499
+ reader.skipType(tag & 7);
500
+ }
501
+ return message;
502
+ },
503
+
504
+ fromJSON(object: any): VersionParams {
505
+ return { app: isSet(object.app) ? Long.fromValue(object.app) : Long.UZERO };
506
+ },
507
+
508
+ toJSON(message: VersionParams): unknown {
509
+ const obj: any = {};
510
+ if (!message.app.equals(Long.UZERO)) {
511
+ obj.app = (message.app || Long.UZERO).toString();
512
+ }
513
+ return obj;
514
+ },
515
+
516
+ create<I extends Exact<DeepPartial<VersionParams>, I>>(base?: I): VersionParams {
517
+ return VersionParams.fromPartial(base ?? ({} as any));
518
+ },
519
+ fromPartial<I extends Exact<DeepPartial<VersionParams>, I>>(object: I): VersionParams {
520
+ const message = createBaseVersionParams();
521
+ message.app = (object.app !== undefined && object.app !== null) ? Long.fromValue(object.app) : Long.UZERO;
522
+ return message;
523
+ },
524
+ };
525
+
526
+ function createBaseHashedParams(): HashedParams {
527
+ return { blockMaxBytes: Long.ZERO, blockMaxGas: Long.ZERO };
528
+ }
529
+
530
+ export const HashedParams = {
531
+ encode(message: HashedParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
532
+ if (!message.blockMaxBytes.equals(Long.ZERO)) {
533
+ writer.uint32(8).int64(message.blockMaxBytes);
534
+ }
535
+ if (!message.blockMaxGas.equals(Long.ZERO)) {
536
+ writer.uint32(16).int64(message.blockMaxGas);
537
+ }
538
+ return writer;
539
+ },
540
+
541
+ decode(input: _m0.Reader | Uint8Array, length?: number): HashedParams {
542
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
543
+ let end = length === undefined ? reader.len : reader.pos + length;
544
+ const message = createBaseHashedParams();
545
+ while (reader.pos < end) {
546
+ const tag = reader.uint32();
547
+ switch (tag >>> 3) {
548
+ case 1:
549
+ if (tag !== 8) {
550
+ break;
551
+ }
552
+
553
+ message.blockMaxBytes = reader.int64() as Long;
554
+ continue;
555
+ case 2:
556
+ if (tag !== 16) {
557
+ break;
558
+ }
559
+
560
+ message.blockMaxGas = reader.int64() as Long;
561
+ continue;
562
+ }
563
+ if ((tag & 7) === 4 || tag === 0) {
564
+ break;
565
+ }
566
+ reader.skipType(tag & 7);
567
+ }
568
+ return message;
569
+ },
570
+
571
+ fromJSON(object: any): HashedParams {
572
+ return {
573
+ blockMaxBytes: isSet(object.blockMaxBytes) ? Long.fromValue(object.blockMaxBytes) : Long.ZERO,
574
+ blockMaxGas: isSet(object.blockMaxGas) ? Long.fromValue(object.blockMaxGas) : Long.ZERO,
575
+ };
576
+ },
577
+
578
+ toJSON(message: HashedParams): unknown {
579
+ const obj: any = {};
580
+ if (!message.blockMaxBytes.equals(Long.ZERO)) {
581
+ obj.blockMaxBytes = (message.blockMaxBytes || Long.ZERO).toString();
582
+ }
583
+ if (!message.blockMaxGas.equals(Long.ZERO)) {
584
+ obj.blockMaxGas = (message.blockMaxGas || Long.ZERO).toString();
585
+ }
586
+ return obj;
587
+ },
588
+
589
+ create<I extends Exact<DeepPartial<HashedParams>, I>>(base?: I): HashedParams {
590
+ return HashedParams.fromPartial(base ?? ({} as any));
591
+ },
592
+ fromPartial<I extends Exact<DeepPartial<HashedParams>, I>>(object: I): HashedParams {
593
+ const message = createBaseHashedParams();
594
+ message.blockMaxBytes = (object.blockMaxBytes !== undefined && object.blockMaxBytes !== null)
595
+ ? Long.fromValue(object.blockMaxBytes)
596
+ : Long.ZERO;
597
+ message.blockMaxGas = (object.blockMaxGas !== undefined && object.blockMaxGas !== null)
598
+ ? Long.fromValue(object.blockMaxGas)
599
+ : Long.ZERO;
600
+ return message;
601
+ },
602
+ };
603
+
604
+ function createBaseABCIParams(): ABCIParams {
605
+ return { voteExtensionsEnableHeight: Long.ZERO };
606
+ }
607
+
608
+ export const ABCIParams = {
609
+ encode(message: ABCIParams, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
610
+ if (!message.voteExtensionsEnableHeight.equals(Long.ZERO)) {
611
+ writer.uint32(8).int64(message.voteExtensionsEnableHeight);
612
+ }
613
+ return writer;
614
+ },
615
+
616
+ decode(input: _m0.Reader | Uint8Array, length?: number): ABCIParams {
617
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
618
+ let end = length === undefined ? reader.len : reader.pos + length;
619
+ const message = createBaseABCIParams();
620
+ while (reader.pos < end) {
621
+ const tag = reader.uint32();
622
+ switch (tag >>> 3) {
623
+ case 1:
624
+ if (tag !== 8) {
625
+ break;
626
+ }
627
+
628
+ message.voteExtensionsEnableHeight = reader.int64() as Long;
629
+ continue;
630
+ }
631
+ if ((tag & 7) === 4 || tag === 0) {
632
+ break;
633
+ }
634
+ reader.skipType(tag & 7);
635
+ }
636
+ return message;
637
+ },
638
+
639
+ fromJSON(object: any): ABCIParams {
640
+ return {
641
+ voteExtensionsEnableHeight: isSet(object.voteExtensionsEnableHeight)
642
+ ? Long.fromValue(object.voteExtensionsEnableHeight)
643
+ : Long.ZERO,
644
+ };
645
+ },
646
+
647
+ toJSON(message: ABCIParams): unknown {
648
+ const obj: any = {};
649
+ if (!message.voteExtensionsEnableHeight.equals(Long.ZERO)) {
650
+ obj.voteExtensionsEnableHeight = (message.voteExtensionsEnableHeight || Long.ZERO).toString();
651
+ }
652
+ return obj;
653
+ },
654
+
655
+ create<I extends Exact<DeepPartial<ABCIParams>, I>>(base?: I): ABCIParams {
656
+ return ABCIParams.fromPartial(base ?? ({} as any));
657
+ },
658
+ fromPartial<I extends Exact<DeepPartial<ABCIParams>, I>>(object: I): ABCIParams {
659
+ const message = createBaseABCIParams();
660
+ message.voteExtensionsEnableHeight =
661
+ (object.voteExtensionsEnableHeight !== undefined && object.voteExtensionsEnableHeight !== null)
662
+ ? Long.fromValue(object.voteExtensionsEnableHeight)
663
+ : Long.ZERO;
664
+ return message;
665
+ },
666
+ };
667
+
668
+ type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
669
+
670
+ export type DeepPartial<T> = T extends Builtin ? T
671
+ : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>
672
+ : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
673
+ : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
674
+ : Partial<T>;
675
+
676
+ type KeysOfUnion<T> = T extends T ? keyof T : never;
677
+ export type Exact<P, I extends P> = P extends Builtin ? P
678
+ : P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
679
+
680
+ if (_m0.util.Long !== Long) {
681
+ _m0.util.Long = Long as any;
682
+ _m0.configure();
683
+ }
684
+
685
+ function isSet(value: any): boolean {
686
+ return value !== null && value !== undefined;
687
+ }