coreum-js 2.16.2 → 2.17.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 (203) hide show
  1. package/dist/main/client/index.js +16 -17
  2. package/dist/main/coreum/asset/ft/v1/authz.d.ts +38 -0
  3. package/dist/main/coreum/asset/ft/v1/authz.js +122 -0
  4. package/dist/main/coreum/asset/ft/v1/event.d.ts +52 -120
  5. package/dist/main/coreum/asset/ft/v1/event.js +744 -138
  6. package/dist/main/coreum/asset/ft/v1/genesis.d.ts +31 -517
  7. package/dist/main/coreum/asset/ft/v1/genesis.js +273 -62
  8. package/dist/main/coreum/asset/ft/v1/params.d.ts +12 -63
  9. package/dist/main/coreum/asset/ft/v1/params.js +37 -33
  10. package/dist/main/coreum/asset/ft/v1/query.d.ts +86 -1950
  11. package/dist/main/coreum/asset/ft/v1/query.js +697 -217
  12. package/dist/main/coreum/asset/ft/v1/token.d.ts +17 -249
  13. package/dist/main/coreum/asset/ft/v1/token.js +273 -197
  14. package/dist/main/coreum/asset/ft/v1/tx.d.ts +30 -755
  15. package/dist/main/coreum/asset/ft/v1/tx.js +502 -386
  16. package/dist/main/coreum/asset/index.d.ts +2 -3
  17. package/dist/main/coreum/asset/nft/v1/authz.d.ts +33 -0
  18. package/dist/main/coreum/asset/nft/v1/authz.js +137 -0
  19. package/dist/main/coreum/asset/nft/v1/event.d.ts +35 -147
  20. package/dist/main/coreum/asset/nft/v1/event.js +475 -147
  21. package/dist/main/coreum/asset/nft/v1/genesis.d.ts +27 -286
  22. package/dist/main/coreum/asset/nft/v1/genesis.js +311 -119
  23. package/dist/main/coreum/asset/nft/v1/nft.d.ts +20 -108
  24. package/dist/main/coreum/asset/nft/v1/nft.js +136 -101
  25. package/dist/main/coreum/asset/nft/v1/params.d.ts +12 -38
  26. package/dist/main/coreum/asset/nft/v1/params.js +17 -20
  27. package/dist/main/coreum/asset/nft/v1/query.d.ts +110 -706
  28. package/dist/main/coreum/asset/nft/v1/query.js +1079 -185
  29. package/dist/main/coreum/asset/nft/v1/tx.d.ts +96 -266
  30. package/dist/main/coreum/asset/nft/v1/tx.js +865 -234
  31. package/dist/main/coreum/asset/nft/v1/types.d.ts +38 -19
  32. package/dist/main/coreum/asset/nft/v1/types.js +273 -45
  33. package/dist/main/coreum/customparams/v1/genesis.d.ts +12 -32
  34. package/dist/main/coreum/customparams/v1/genesis.js +26 -22
  35. package/dist/main/coreum/customparams/v1/params.d.ts +11 -19
  36. package/dist/main/coreum/customparams/v1/params.js +23 -20
  37. package/dist/main/coreum/customparams/v1/query.d.ts +14 -40
  38. package/dist/main/coreum/customparams/v1/query.js +35 -29
  39. package/dist/main/coreum/dex/index.d.ts +1 -0
  40. package/dist/main/coreum/dex/index.js +12 -0
  41. package/dist/main/coreum/dex/v1/event.d.ts +73 -0
  42. package/dist/main/coreum/dex/v1/event.js +470 -0
  43. package/dist/main/coreum/dex/v1/genesis.d.ts +49 -0
  44. package/dist/main/coreum/dex/v1/genesis.js +318 -0
  45. package/dist/main/coreum/dex/v1/order.d.ts +172 -0
  46. package/dist/main/coreum/dex/v1/order.js +1137 -0
  47. package/dist/main/coreum/dex/v1/params.d.ts +34 -0
  48. package/dist/main/coreum/dex/v1/params.js +139 -0
  49. package/dist/main/coreum/dex/v1/query.d.ts +133 -0
  50. package/dist/main/coreum/dex/v1/query.js +873 -0
  51. package/dist/main/coreum/dex/v1/tx.d.ts +102 -0
  52. package/dist/main/coreum/dex/v1/tx.js +521 -0
  53. package/dist/main/coreum/extensions/dex.d.ts +12 -0
  54. package/dist/main/coreum/extensions/dex.js +32 -0
  55. package/dist/main/coreum/feemodel/v1/genesis.d.ts +13 -233
  56. package/dist/main/coreum/feemodel/v1/genesis.js +23 -24
  57. package/dist/main/coreum/feemodel/v1/params.d.ts +14 -337
  58. package/dist/main/coreum/feemodel/v1/params.js +113 -66
  59. package/dist/main/coreum/feemodel/v1/query.d.ts +30 -261
  60. package/dist/main/coreum/feemodel/v1/query.js +196 -43
  61. package/dist/main/coreum/index.d.ts +46 -0
  62. package/dist/main/coreum/index.js +58 -1
  63. package/dist/main/coreum/nft/index.d.ts +1 -2
  64. package/dist/main/coreum/nft/v1beta1/event.d.ts +23 -79
  65. package/dist/main/coreum/nft/v1beta1/event.js +103 -77
  66. package/dist/main/coreum/nft/v1beta1/genesis.d.ts +13 -435
  67. package/dist/main/coreum/nft/v1beta1/genesis.js +50 -52
  68. package/dist/main/coreum/nft/v1beta1/nft.d.ts +15 -114
  69. package/dist/main/coreum/nft/v1beta1/nft.js +111 -81
  70. package/dist/main/coreum/nft/v1beta1/query.d.ts +54 -1628
  71. package/dist/main/coreum/nft/v1beta1/query.js +259 -223
  72. package/dist/main/coreum/nft/v1beta1/tx.d.ts +13 -39
  73. package/dist/main/coreum/nft/v1beta1/tx.js +54 -43
  74. package/dist/main/cosmos/extensions/distribution.d.ts +4 -4
  75. package/dist/main/cosmos/extensions/distribution.js +9 -9
  76. package/dist/main/cosmos/extensions/gov.d.ts +13 -13
  77. package/dist/main/cosmos/extensions/gov.js +14 -8
  78. package/dist/main/cosmos/index.d.ts +8 -8
  79. package/dist/main/google/api/http.js +18 -21
  80. package/dist/main/google/protobuf/any.js +3 -4
  81. package/dist/main/google/protobuf/duration.js +3 -4
  82. package/dist/main/google/protobuf/timestamp.js +3 -4
  83. package/dist/main/services/cosmostation.js +1 -1
  84. package/dist/main/tendermint/abci/types.js +183 -223
  85. package/dist/main/tendermint/crypto/keys.js +3 -4
  86. package/dist/main/tendermint/crypto/proof.js +19 -24
  87. package/dist/main/tendermint/types/params.js +15 -20
  88. package/dist/main/tendermint/types/types.js +57 -68
  89. package/dist/main/tendermint/types/validator.js +10 -13
  90. package/dist/main/tendermint/version/types.js +6 -8
  91. package/dist/main/types/core.d.ts +2 -1
  92. package/dist/main/types/core.js +2 -0
  93. package/dist/main/wasm/v1/authz.d.ts +20 -471
  94. package/dist/main/wasm/v1/authz.js +129 -148
  95. package/dist/main/wasm/v1/genesis.d.ts +14 -1020
  96. package/dist/main/wasm/v1/genesis.js +169 -140
  97. package/dist/main/wasm/v1/ibc.d.ts +13 -62
  98. package/dist/main/wasm/v1/ibc.js +91 -76
  99. package/dist/main/wasm/v1/index.d.ts +1 -2
  100. package/dist/main/wasm/v1/pagination.js +9 -11
  101. package/dist/main/wasm/v1/proposal.d.ts +23 -720
  102. package/dist/main/wasm/v1/proposal.js +634 -465
  103. package/dist/main/wasm/v1/query.d.ts +35 -1201
  104. package/dist/main/wasm/v1/query.js +370 -363
  105. package/dist/main/wasm/v1/tx.d.ts +37 -788
  106. package/dist/main/wasm/v1/tx.js +621 -497
  107. package/dist/main/wasm/v1/types.d.ts +19 -297
  108. package/dist/main/wasm/v1/types.js +219 -190
  109. package/dist/module/client/index.js +4 -3
  110. package/dist/module/coreum/asset/ft/v1/authz.d.ts +38 -0
  111. package/dist/module/coreum/asset/ft/v1/authz.js +119 -0
  112. package/dist/module/coreum/asset/ft/v1/event.d.ts +52 -120
  113. package/dist/module/coreum/asset/ft/v1/event.js +721 -109
  114. package/dist/module/coreum/asset/ft/v1/genesis.d.ts +31 -517
  115. package/dist/module/coreum/asset/ft/v1/genesis.js +266 -50
  116. package/dist/module/coreum/asset/ft/v1/params.d.ts +12 -63
  117. package/dist/module/coreum/asset/ft/v1/params.js +35 -27
  118. package/dist/module/coreum/asset/ft/v1/query.d.ts +86 -1950
  119. package/dist/module/coreum/asset/ft/v1/query.js +672 -180
  120. package/dist/module/coreum/asset/ft/v1/token.d.ts +17 -249
  121. package/dist/module/coreum/asset/ft/v1/token.js +236 -152
  122. package/dist/module/coreum/asset/ft/v1/tx.d.ts +30 -755
  123. package/dist/module/coreum/asset/ft/v1/tx.js +437 -301
  124. package/dist/module/coreum/asset/index.d.ts +2 -3
  125. package/dist/module/coreum/asset/nft/v1/authz.d.ts +33 -0
  126. package/dist/module/coreum/asset/nft/v1/authz.js +134 -0
  127. package/dist/module/coreum/asset/nft/v1/event.d.ts +35 -147
  128. package/dist/module/coreum/asset/nft/v1/event.js +448 -112
  129. package/dist/module/coreum/asset/nft/v1/genesis.d.ts +27 -286
  130. package/dist/module/coreum/asset/nft/v1/genesis.js +299 -100
  131. package/dist/module/coreum/asset/nft/v1/nft.d.ts +20 -108
  132. package/dist/module/coreum/asset/nft/v1/nft.js +121 -81
  133. package/dist/module/coreum/asset/nft/v1/params.d.ts +12 -38
  134. package/dist/module/coreum/asset/nft/v1/params.js +16 -16
  135. package/dist/module/coreum/asset/nft/v1/query.d.ts +110 -706
  136. package/dist/module/coreum/asset/nft/v1/query.js +1057 -153
  137. package/dist/module/coreum/asset/nft/v1/tx.d.ts +96 -266
  138. package/dist/module/coreum/asset/nft/v1/tx.js +825 -184
  139. package/dist/module/coreum/asset/nft/v1/types.d.ts +38 -19
  140. package/dist/module/coreum/asset/nft/v1/types.js +269 -39
  141. package/dist/module/coreum/customparams/v1/genesis.d.ts +12 -32
  142. package/dist/module/coreum/customparams/v1/genesis.js +25 -18
  143. package/dist/module/coreum/customparams/v1/params.d.ts +11 -19
  144. package/dist/module/coreum/customparams/v1/params.js +21 -14
  145. package/dist/module/coreum/customparams/v1/query.d.ts +14 -40
  146. package/dist/module/coreum/customparams/v1/query.js +32 -23
  147. package/dist/module/coreum/dex/index.d.ts +1 -0
  148. package/dist/module/coreum/dex/index.js +9 -0
  149. package/dist/module/coreum/dex/v1/event.d.ts +73 -0
  150. package/dist/module/coreum/dex/v1/event.js +467 -0
  151. package/dist/module/coreum/dex/v1/genesis.d.ts +49 -0
  152. package/dist/module/coreum/dex/v1/genesis.js +315 -0
  153. package/dist/module/coreum/dex/v1/order.d.ts +172 -0
  154. package/dist/module/coreum/dex/v1/order.js +1128 -0
  155. package/dist/module/coreum/dex/v1/params.d.ts +34 -0
  156. package/dist/module/coreum/dex/v1/params.js +136 -0
  157. package/dist/module/coreum/dex/v1/query.d.ts +133 -0
  158. package/dist/module/coreum/dex/v1/query.js +871 -0
  159. package/dist/module/coreum/dex/v1/tx.d.ts +102 -0
  160. package/dist/module/coreum/dex/v1/tx.js +519 -0
  161. package/dist/module/coreum/extensions/dex.d.ts +12 -0
  162. package/dist/module/coreum/extensions/dex.js +28 -0
  163. package/dist/module/coreum/feemodel/v1/genesis.d.ts +13 -233
  164. package/dist/module/coreum/feemodel/v1/genesis.js +22 -20
  165. package/dist/module/coreum/feemodel/v1/params.d.ts +14 -337
  166. package/dist/module/coreum/feemodel/v1/params.js +105 -54
  167. package/dist/module/coreum/feemodel/v1/query.d.ts +30 -261
  168. package/dist/module/coreum/feemodel/v1/query.js +191 -35
  169. package/dist/module/coreum/index.d.ts +46 -0
  170. package/dist/module/coreum/index.js +57 -0
  171. package/dist/module/coreum/nft/index.d.ts +1 -2
  172. package/dist/module/coreum/nft/v1beta1/event.d.ts +23 -79
  173. package/dist/module/coreum/nft/v1beta1/event.js +90 -58
  174. package/dist/module/coreum/nft/v1beta1/genesis.d.ts +13 -435
  175. package/dist/module/coreum/nft/v1beta1/genesis.js +44 -41
  176. package/dist/module/coreum/nft/v1beta1/nft.d.ts +15 -114
  177. package/dist/module/coreum/nft/v1beta1/nft.js +99 -64
  178. package/dist/module/coreum/nft/v1beta1/query.d.ts +54 -1628
  179. package/dist/module/coreum/nft/v1beta1/query.js +231 -183
  180. package/dist/module/coreum/nft/v1beta1/tx.d.ts +13 -39
  181. package/dist/module/coreum/nft/v1beta1/tx.js +47 -32
  182. package/dist/module/cosmos/extensions/distribution.d.ts +4 -4
  183. package/dist/module/cosmos/extensions/gov.d.ts +13 -13
  184. package/dist/module/cosmos/index.d.ts +8 -8
  185. package/dist/module/services/cosmostation.js +1 -1
  186. package/dist/module/types/core.d.ts +2 -1
  187. package/dist/module/types/core.js +2 -0
  188. package/dist/module/wasm/v1/authz.d.ts +20 -471
  189. package/dist/module/wasm/v1/authz.js +111 -119
  190. package/dist/module/wasm/v1/genesis.d.ts +14 -1020
  191. package/dist/module/wasm/v1/genesis.js +161 -125
  192. package/dist/module/wasm/v1/ibc.d.ts +13 -62
  193. package/dist/module/wasm/v1/ibc.js +83 -62
  194. package/dist/module/wasm/v1/index.d.ts +1 -2
  195. package/dist/module/wasm/v1/proposal.d.ts +23 -720
  196. package/dist/module/wasm/v1/proposal.js +562 -377
  197. package/dist/module/wasm/v1/query.d.ts +35 -1201
  198. package/dist/module/wasm/v1/query.js +330 -301
  199. package/dist/module/wasm/v1/tx.d.ts +37 -788
  200. package/dist/module/wasm/v1/tx.js +551 -404
  201. package/dist/module/wasm/v1/types.d.ts +19 -297
  202. package/dist/module/wasm/v1/types.js +196 -156
  203. package/package.json +11 -10
@@ -1,14 +1,26 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v2.7.0
4
+ // protoc v3.21.12
5
+ // source: coreum-protos/nft/genesis.proto
1
6
  /* eslint-disable */
2
- import Long from "long";
3
- import _m0 from "protobufjs/minimal";
7
+ import { BinaryReader, BinaryWriter } from "cosmjs-types/binary";
4
8
  import { ClassDefinition } from "./nft";
5
9
  import { Params } from "./params";
6
10
  export const protobufPackage = "coreum.asset.nft.v1";
7
11
  function createBaseGenesisState() {
8
- return { params: undefined, classDefinitions: [], frozenNfts: [], whitelistedNftAccounts: [], burntNfts: [] };
12
+ return {
13
+ params: undefined,
14
+ classDefinitions: [],
15
+ frozenNfts: [],
16
+ whitelistedNftAccounts: [],
17
+ burntNfts: [],
18
+ classWhitelistedAccounts: [],
19
+ classFrozenAccounts: [],
20
+ };
9
21
  }
10
22
  export const GenesisState = {
11
- encode(message, writer = _m0.Writer.create()) {
23
+ encode(message, writer = new BinaryWriter()) {
12
24
  if (message.params !== undefined) {
13
25
  Params.encode(message.params, writer.uint32(10).fork()).ldelim();
14
26
  }
@@ -24,92 +36,123 @@ export const GenesisState = {
24
36
  for (const v of message.burntNfts) {
25
37
  BurntNFT.encode(v, writer.uint32(42).fork()).ldelim();
26
38
  }
39
+ for (const v of message.classWhitelistedAccounts) {
40
+ ClassWhitelistedAccounts.encode(v, writer.uint32(50).fork()).ldelim();
41
+ }
42
+ for (const v of message.classFrozenAccounts) {
43
+ ClassFrozenAccounts.encode(v, writer.uint32(58).fork()).ldelim();
44
+ }
27
45
  return writer;
28
46
  },
29
47
  decode(input, length) {
30
- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
48
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
31
49
  let end = length === undefined ? reader.len : reader.pos + length;
32
50
  const message = createBaseGenesisState();
33
51
  while (reader.pos < end) {
34
52
  const tag = reader.uint32();
35
53
  switch (tag >>> 3) {
36
- case 1:
37
- if (tag != 10) {
54
+ case 1: {
55
+ if (tag !== 10) {
38
56
  break;
39
57
  }
40
58
  message.params = Params.decode(reader, reader.uint32());
41
59
  continue;
42
- case 2:
43
- if (tag != 18) {
60
+ }
61
+ case 2: {
62
+ if (tag !== 18) {
44
63
  break;
45
64
  }
46
65
  message.classDefinitions.push(ClassDefinition.decode(reader, reader.uint32()));
47
66
  continue;
48
- case 3:
49
- if (tag != 26) {
67
+ }
68
+ case 3: {
69
+ if (tag !== 26) {
50
70
  break;
51
71
  }
52
72
  message.frozenNfts.push(FrozenNFT.decode(reader, reader.uint32()));
53
73
  continue;
54
- case 4:
55
- if (tag != 34) {
74
+ }
75
+ case 4: {
76
+ if (tag !== 34) {
56
77
  break;
57
78
  }
58
79
  message.whitelistedNftAccounts.push(WhitelistedNFTAccounts.decode(reader, reader.uint32()));
59
80
  continue;
60
- case 5:
61
- if (tag != 42) {
81
+ }
82
+ case 5: {
83
+ if (tag !== 42) {
62
84
  break;
63
85
  }
64
86
  message.burntNfts.push(BurntNFT.decode(reader, reader.uint32()));
65
87
  continue;
88
+ }
89
+ case 6: {
90
+ if (tag !== 50) {
91
+ break;
92
+ }
93
+ message.classWhitelistedAccounts.push(ClassWhitelistedAccounts.decode(reader, reader.uint32()));
94
+ continue;
95
+ }
96
+ case 7: {
97
+ if (tag !== 58) {
98
+ break;
99
+ }
100
+ message.classFrozenAccounts.push(ClassFrozenAccounts.decode(reader, reader.uint32()));
101
+ continue;
102
+ }
66
103
  }
67
- if ((tag & 7) == 4 || tag == 0) {
104
+ if ((tag & 7) === 4 || tag === 0) {
68
105
  break;
69
106
  }
70
- reader.skipType(tag & 7);
107
+ reader.skip(tag & 7);
71
108
  }
72
109
  return message;
73
110
  },
74
111
  fromJSON(object) {
75
112
  return {
76
113
  params: isSet(object.params) ? Params.fromJSON(object.params) : undefined,
77
- classDefinitions: Array.isArray(object?.classDefinitions)
114
+ classDefinitions: globalThis.Array.isArray(object?.classDefinitions)
78
115
  ? object.classDefinitions.map((e) => ClassDefinition.fromJSON(e))
79
116
  : [],
80
- frozenNfts: Array.isArray(object?.frozenNfts) ? object.frozenNfts.map((e) => FrozenNFT.fromJSON(e)) : [],
81
- whitelistedNftAccounts: Array.isArray(object?.whitelistedNftAccounts)
117
+ frozenNfts: globalThis.Array.isArray(object?.frozenNfts)
118
+ ? object.frozenNfts.map((e) => FrozenNFT.fromJSON(e))
119
+ : [],
120
+ whitelistedNftAccounts: globalThis.Array.isArray(object?.whitelistedNftAccounts)
82
121
  ? object.whitelistedNftAccounts.map((e) => WhitelistedNFTAccounts.fromJSON(e))
83
122
  : [],
84
- burntNfts: Array.isArray(object?.burntNfts) ? object.burntNfts.map((e) => BurntNFT.fromJSON(e)) : [],
123
+ burntNfts: globalThis.Array.isArray(object?.burntNfts)
124
+ ? object.burntNfts.map((e) => BurntNFT.fromJSON(e))
125
+ : [],
126
+ classWhitelistedAccounts: globalThis.Array.isArray(object?.classWhitelistedAccounts)
127
+ ? object.classWhitelistedAccounts.map((e) => ClassWhitelistedAccounts.fromJSON(e))
128
+ : [],
129
+ classFrozenAccounts: globalThis.Array.isArray(object?.classFrozenAccounts)
130
+ ? object.classFrozenAccounts.map((e) => ClassFrozenAccounts.fromJSON(e))
131
+ : [],
85
132
  };
86
133
  },
87
134
  toJSON(message) {
88
135
  const obj = {};
89
- message.params !== undefined && (obj.params = message.params ? Params.toJSON(message.params) : undefined);
90
- if (message.classDefinitions) {
91
- obj.classDefinitions = message.classDefinitions.map((e) => e ? ClassDefinition.toJSON(e) : undefined);
92
- }
93
- else {
94
- obj.classDefinitions = [];
136
+ if (message.params !== undefined) {
137
+ obj.params = Params.toJSON(message.params);
95
138
  }
96
- if (message.frozenNfts) {
97
- obj.frozenNfts = message.frozenNfts.map((e) => e ? FrozenNFT.toJSON(e) : undefined);
139
+ if (message.classDefinitions?.length) {
140
+ obj.classDefinitions = message.classDefinitions.map((e) => ClassDefinition.toJSON(e));
98
141
  }
99
- else {
100
- obj.frozenNfts = [];
142
+ if (message.frozenNfts?.length) {
143
+ obj.frozenNfts = message.frozenNfts.map((e) => FrozenNFT.toJSON(e));
101
144
  }
102
- if (message.whitelistedNftAccounts) {
103
- obj.whitelistedNftAccounts = message.whitelistedNftAccounts.map((e) => e ? WhitelistedNFTAccounts.toJSON(e) : undefined);
145
+ if (message.whitelistedNftAccounts?.length) {
146
+ obj.whitelistedNftAccounts = message.whitelistedNftAccounts.map((e) => WhitelistedNFTAccounts.toJSON(e));
104
147
  }
105
- else {
106
- obj.whitelistedNftAccounts = [];
148
+ if (message.burntNfts?.length) {
149
+ obj.burntNfts = message.burntNfts.map((e) => BurntNFT.toJSON(e));
107
150
  }
108
- if (message.burntNfts) {
109
- obj.burntNfts = message.burntNfts.map((e) => e ? BurntNFT.toJSON(e) : undefined);
151
+ if (message.classWhitelistedAccounts?.length) {
152
+ obj.classWhitelistedAccounts = message.classWhitelistedAccounts.map((e) => ClassWhitelistedAccounts.toJSON(e));
110
153
  }
111
- else {
112
- obj.burntNfts = [];
154
+ if (message.classFrozenAccounts?.length) {
155
+ obj.classFrozenAccounts = message.classFrozenAccounts.map((e) => ClassFrozenAccounts.toJSON(e));
113
156
  }
114
157
  return obj;
115
158
  },
@@ -118,14 +161,22 @@ export const GenesisState = {
118
161
  },
119
162
  fromPartial(object) {
120
163
  const message = createBaseGenesisState();
121
- message.params = (object.params !== undefined && object.params !== null)
122
- ? Params.fromPartial(object.params)
123
- : undefined;
124
- message.classDefinitions = object.classDefinitions?.map((e) => ClassDefinition.fromPartial(e)) || [];
125
- message.frozenNfts = object.frozenNfts?.map((e) => FrozenNFT.fromPartial(e)) || [];
126
- message.whitelistedNftAccounts = object.whitelistedNftAccounts?.map((e) => WhitelistedNFTAccounts.fromPartial(e)) ||
127
- [];
128
- message.burntNfts = object.burntNfts?.map((e) => BurntNFT.fromPartial(e)) || [];
164
+ message.params =
165
+ object.params !== undefined && object.params !== null
166
+ ? Params.fromPartial(object.params)
167
+ : undefined;
168
+ message.classDefinitions =
169
+ object.classDefinitions?.map((e) => ClassDefinition.fromPartial(e)) || [];
170
+ message.frozenNfts =
171
+ object.frozenNfts?.map((e) => FrozenNFT.fromPartial(e)) || [];
172
+ message.whitelistedNftAccounts =
173
+ object.whitelistedNftAccounts?.map((e) => WhitelistedNFTAccounts.fromPartial(e)) || [];
174
+ message.burntNfts =
175
+ object.burntNfts?.map((e) => BurntNFT.fromPartial(e)) || [];
176
+ message.classWhitelistedAccounts =
177
+ object.classWhitelistedAccounts?.map((e) => ClassWhitelistedAccounts.fromPartial(e)) || [];
178
+ message.classFrozenAccounts =
179
+ object.classFrozenAccounts?.map((e) => ClassFrozenAccounts.fromPartial(e)) || [];
129
180
  return message;
130
181
  },
131
182
  };
@@ -133,7 +184,7 @@ function createBaseFrozenNFT() {
133
184
  return { classID: "", nftIDs: [] };
134
185
  }
135
186
  export const FrozenNFT = {
136
- encode(message, writer = _m0.Writer.create()) {
187
+ encode(message, writer = new BinaryWriter()) {
137
188
  if (message.classID !== "") {
138
189
  writer.uint32(10).string(message.classID);
139
190
  }
@@ -143,46 +194,49 @@ export const FrozenNFT = {
143
194
  return writer;
144
195
  },
145
196
  decode(input, length) {
146
- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
197
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
147
198
  let end = length === undefined ? reader.len : reader.pos + length;
148
199
  const message = createBaseFrozenNFT();
149
200
  while (reader.pos < end) {
150
201
  const tag = reader.uint32();
151
202
  switch (tag >>> 3) {
152
- case 1:
153
- if (tag != 10) {
203
+ case 1: {
204
+ if (tag !== 10) {
154
205
  break;
155
206
  }
156
207
  message.classID = reader.string();
157
208
  continue;
158
- case 2:
159
- if (tag != 18) {
209
+ }
210
+ case 2: {
211
+ if (tag !== 18) {
160
212
  break;
161
213
  }
162
214
  message.nftIDs.push(reader.string());
163
215
  continue;
216
+ }
164
217
  }
165
- if ((tag & 7) == 4 || tag == 0) {
218
+ if ((tag & 7) === 4 || tag === 0) {
166
219
  break;
167
220
  }
168
- reader.skipType(tag & 7);
221
+ reader.skip(tag & 7);
169
222
  }
170
223
  return message;
171
224
  },
172
225
  fromJSON(object) {
173
226
  return {
174
- classID: isSet(object.classID) ? String(object.classID) : "",
175
- nftIDs: Array.isArray(object?.nftIDs) ? object.nftIDs.map((e) => String(e)) : [],
227
+ classID: isSet(object.classID) ? globalThis.String(object.classID) : "",
228
+ nftIDs: globalThis.Array.isArray(object?.nftIDs)
229
+ ? object.nftIDs.map((e) => globalThis.String(e))
230
+ : [],
176
231
  };
177
232
  },
178
233
  toJSON(message) {
179
234
  const obj = {};
180
- message.classID !== undefined && (obj.classID = message.classID);
181
- if (message.nftIDs) {
182
- obj.nftIDs = message.nftIDs.map((e) => e);
235
+ if (message.classID !== "") {
236
+ obj.classID = message.classID;
183
237
  }
184
- else {
185
- obj.nftIDs = [];
238
+ if (message.nftIDs?.length) {
239
+ obj.nftIDs = message.nftIDs;
186
240
  }
187
241
  return obj;
188
242
  },
@@ -200,7 +254,7 @@ function createBaseWhitelistedNFTAccounts() {
200
254
  return { classID: "", nftID: "", accounts: [] };
201
255
  }
202
256
  export const WhitelistedNFTAccounts = {
203
- encode(message, writer = _m0.Writer.create()) {
257
+ encode(message, writer = new BinaryWriter()) {
204
258
  if (message.classID !== "") {
205
259
  writer.uint32(10).string(message.classID);
206
260
  }
@@ -213,54 +267,60 @@ export const WhitelistedNFTAccounts = {
213
267
  return writer;
214
268
  },
215
269
  decode(input, length) {
216
- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
270
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
217
271
  let end = length === undefined ? reader.len : reader.pos + length;
218
272
  const message = createBaseWhitelistedNFTAccounts();
219
273
  while (reader.pos < end) {
220
274
  const tag = reader.uint32();
221
275
  switch (tag >>> 3) {
222
- case 1:
223
- if (tag != 10) {
276
+ case 1: {
277
+ if (tag !== 10) {
224
278
  break;
225
279
  }
226
280
  message.classID = reader.string();
227
281
  continue;
228
- case 2:
229
- if (tag != 18) {
282
+ }
283
+ case 2: {
284
+ if (tag !== 18) {
230
285
  break;
231
286
  }
232
287
  message.nftID = reader.string();
233
288
  continue;
234
- case 4:
235
- if (tag != 34) {
289
+ }
290
+ case 4: {
291
+ if (tag !== 34) {
236
292
  break;
237
293
  }
238
294
  message.accounts.push(reader.string());
239
295
  continue;
296
+ }
240
297
  }
241
- if ((tag & 7) == 4 || tag == 0) {
298
+ if ((tag & 7) === 4 || tag === 0) {
242
299
  break;
243
300
  }
244
- reader.skipType(tag & 7);
301
+ reader.skip(tag & 7);
245
302
  }
246
303
  return message;
247
304
  },
248
305
  fromJSON(object) {
249
306
  return {
250
- classID: isSet(object.classID) ? String(object.classID) : "",
251
- nftID: isSet(object.nftID) ? String(object.nftID) : "",
252
- accounts: Array.isArray(object?.accounts) ? object.accounts.map((e) => String(e)) : [],
307
+ classID: isSet(object.classID) ? globalThis.String(object.classID) : "",
308
+ nftID: isSet(object.nftID) ? globalThis.String(object.nftID) : "",
309
+ accounts: globalThis.Array.isArray(object?.accounts)
310
+ ? object.accounts.map((e) => globalThis.String(e))
311
+ : [],
253
312
  };
254
313
  },
255
314
  toJSON(message) {
256
315
  const obj = {};
257
- message.classID !== undefined && (obj.classID = message.classID);
258
- message.nftID !== undefined && (obj.nftID = message.nftID);
259
- if (message.accounts) {
260
- obj.accounts = message.accounts.map((e) => e);
316
+ if (message.classID !== "") {
317
+ obj.classID = message.classID;
318
+ }
319
+ if (message.nftID !== "") {
320
+ obj.nftID = message.nftID;
261
321
  }
262
- else {
263
- obj.accounts = [];
322
+ if (message.accounts?.length) {
323
+ obj.accounts = message.accounts;
264
324
  }
265
325
  return obj;
266
326
  },
@@ -275,11 +335,151 @@ export const WhitelistedNFTAccounts = {
275
335
  return message;
276
336
  },
277
337
  };
338
+ function createBaseClassWhitelistedAccounts() {
339
+ return { classID: "", accounts: [] };
340
+ }
341
+ export const ClassWhitelistedAccounts = {
342
+ encode(message, writer = new BinaryWriter()) {
343
+ if (message.classID !== "") {
344
+ writer.uint32(10).string(message.classID);
345
+ }
346
+ for (const v of message.accounts) {
347
+ writer.uint32(18).string(v);
348
+ }
349
+ return writer;
350
+ },
351
+ decode(input, length) {
352
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
353
+ let end = length === undefined ? reader.len : reader.pos + length;
354
+ const message = createBaseClassWhitelistedAccounts();
355
+ while (reader.pos < end) {
356
+ const tag = reader.uint32();
357
+ switch (tag >>> 3) {
358
+ case 1: {
359
+ if (tag !== 10) {
360
+ break;
361
+ }
362
+ message.classID = reader.string();
363
+ continue;
364
+ }
365
+ case 2: {
366
+ if (tag !== 18) {
367
+ break;
368
+ }
369
+ message.accounts.push(reader.string());
370
+ continue;
371
+ }
372
+ }
373
+ if ((tag & 7) === 4 || tag === 0) {
374
+ break;
375
+ }
376
+ reader.skip(tag & 7);
377
+ }
378
+ return message;
379
+ },
380
+ fromJSON(object) {
381
+ return {
382
+ classID: isSet(object.classID) ? globalThis.String(object.classID) : "",
383
+ accounts: globalThis.Array.isArray(object?.accounts)
384
+ ? object.accounts.map((e) => globalThis.String(e))
385
+ : [],
386
+ };
387
+ },
388
+ toJSON(message) {
389
+ const obj = {};
390
+ if (message.classID !== "") {
391
+ obj.classID = message.classID;
392
+ }
393
+ if (message.accounts?.length) {
394
+ obj.accounts = message.accounts;
395
+ }
396
+ return obj;
397
+ },
398
+ create(base) {
399
+ return ClassWhitelistedAccounts.fromPartial(base ?? {});
400
+ },
401
+ fromPartial(object) {
402
+ const message = createBaseClassWhitelistedAccounts();
403
+ message.classID = object.classID ?? "";
404
+ message.accounts = object.accounts?.map((e) => e) || [];
405
+ return message;
406
+ },
407
+ };
408
+ function createBaseClassFrozenAccounts() {
409
+ return { classID: "", accounts: [] };
410
+ }
411
+ export const ClassFrozenAccounts = {
412
+ encode(message, writer = new BinaryWriter()) {
413
+ if (message.classID !== "") {
414
+ writer.uint32(10).string(message.classID);
415
+ }
416
+ for (const v of message.accounts) {
417
+ writer.uint32(18).string(v);
418
+ }
419
+ return writer;
420
+ },
421
+ decode(input, length) {
422
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
423
+ let end = length === undefined ? reader.len : reader.pos + length;
424
+ const message = createBaseClassFrozenAccounts();
425
+ while (reader.pos < end) {
426
+ const tag = reader.uint32();
427
+ switch (tag >>> 3) {
428
+ case 1: {
429
+ if (tag !== 10) {
430
+ break;
431
+ }
432
+ message.classID = reader.string();
433
+ continue;
434
+ }
435
+ case 2: {
436
+ if (tag !== 18) {
437
+ break;
438
+ }
439
+ message.accounts.push(reader.string());
440
+ continue;
441
+ }
442
+ }
443
+ if ((tag & 7) === 4 || tag === 0) {
444
+ break;
445
+ }
446
+ reader.skip(tag & 7);
447
+ }
448
+ return message;
449
+ },
450
+ fromJSON(object) {
451
+ return {
452
+ classID: isSet(object.classID) ? globalThis.String(object.classID) : "",
453
+ accounts: globalThis.Array.isArray(object?.accounts)
454
+ ? object.accounts.map((e) => globalThis.String(e))
455
+ : [],
456
+ };
457
+ },
458
+ toJSON(message) {
459
+ const obj = {};
460
+ if (message.classID !== "") {
461
+ obj.classID = message.classID;
462
+ }
463
+ if (message.accounts?.length) {
464
+ obj.accounts = message.accounts;
465
+ }
466
+ return obj;
467
+ },
468
+ create(base) {
469
+ return ClassFrozenAccounts.fromPartial(base ?? {});
470
+ },
471
+ fromPartial(object) {
472
+ const message = createBaseClassFrozenAccounts();
473
+ message.classID = object.classID ?? "";
474
+ message.accounts = object.accounts?.map((e) => e) || [];
475
+ return message;
476
+ },
477
+ };
278
478
  function createBaseBurntNFT() {
279
479
  return { classID: "", nftIDs: [] };
280
480
  }
281
481
  export const BurntNFT = {
282
- encode(message, writer = _m0.Writer.create()) {
482
+ encode(message, writer = new BinaryWriter()) {
283
483
  if (message.classID !== "") {
284
484
  writer.uint32(10).string(message.classID);
285
485
  }
@@ -289,46 +489,49 @@ export const BurntNFT = {
289
489
  return writer;
290
490
  },
291
491
  decode(input, length) {
292
- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
492
+ const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
293
493
  let end = length === undefined ? reader.len : reader.pos + length;
294
494
  const message = createBaseBurntNFT();
295
495
  while (reader.pos < end) {
296
496
  const tag = reader.uint32();
297
497
  switch (tag >>> 3) {
298
- case 1:
299
- if (tag != 10) {
498
+ case 1: {
499
+ if (tag !== 10) {
300
500
  break;
301
501
  }
302
502
  message.classID = reader.string();
303
503
  continue;
304
- case 2:
305
- if (tag != 18) {
504
+ }
505
+ case 2: {
506
+ if (tag !== 18) {
306
507
  break;
307
508
  }
308
509
  message.nftIDs.push(reader.string());
309
510
  continue;
511
+ }
310
512
  }
311
- if ((tag & 7) == 4 || tag == 0) {
513
+ if ((tag & 7) === 4 || tag === 0) {
312
514
  break;
313
515
  }
314
- reader.skipType(tag & 7);
516
+ reader.skip(tag & 7);
315
517
  }
316
518
  return message;
317
519
  },
318
520
  fromJSON(object) {
319
521
  return {
320
- classID: isSet(object.classID) ? String(object.classID) : "",
321
- nftIDs: Array.isArray(object?.nftIDs) ? object.nftIDs.map((e) => String(e)) : [],
522
+ classID: isSet(object.classID) ? globalThis.String(object.classID) : "",
523
+ nftIDs: globalThis.Array.isArray(object?.nftIDs)
524
+ ? object.nftIDs.map((e) => globalThis.String(e))
525
+ : [],
322
526
  };
323
527
  },
324
528
  toJSON(message) {
325
529
  const obj = {};
326
- message.classID !== undefined && (obj.classID = message.classID);
327
- if (message.nftIDs) {
328
- obj.nftIDs = message.nftIDs.map((e) => e);
530
+ if (message.classID !== "") {
531
+ obj.classID = message.classID;
329
532
  }
330
- else {
331
- obj.nftIDs = [];
533
+ if (message.nftIDs?.length) {
534
+ obj.nftIDs = message.nftIDs;
332
535
  }
333
536
  return obj;
334
537
  },
@@ -342,10 +545,6 @@ export const BurntNFT = {
342
545
  return message;
343
546
  },
344
547
  };
345
- if (_m0.util.Long !== Long) {
346
- _m0.util.Long = Long;
347
- _m0.configure();
348
- }
349
548
  function isSet(value) {
350
549
  return value !== null && value !== undefined;
351
550
  }