tronwb 6.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 (318) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +201 -0
  3. package/dist/TronWeb.js +3 -0
  4. package/dist/TronWeb.js.LICENSE.txt +12 -0
  5. package/dist/TronWeb.js.map +1 -0
  6. package/dist/TronWeb.node.js +2 -0
  7. package/dist/TronWeb.node.js.map +1 -0
  8. package/kj9btptx.cjs +1 -0
  9. package/lib/commonjs/index.d.ts +64 -0
  10. package/lib/commonjs/index.js +37 -0
  11. package/lib/commonjs/index.js.map +1 -0
  12. package/lib/commonjs/lib/TransactionBuilder/TransactionBuilder.d.ts +127 -0
  13. package/lib/commonjs/lib/TransactionBuilder/TransactionBuilder.js +1771 -0
  14. package/lib/commonjs/lib/TransactionBuilder/TransactionBuilder.js.map +1 -0
  15. package/lib/commonjs/lib/TransactionBuilder/helper.d.ts +28 -0
  16. package/lib/commonjs/lib/TransactionBuilder/helper.js +122 -0
  17. package/lib/commonjs/lib/TransactionBuilder/helper.js.map +1 -0
  18. package/lib/commonjs/lib/contract/index.d.ts +29 -0
  19. package/lib/commonjs/lib/contract/index.js +124 -0
  20. package/lib/commonjs/lib/contract/index.js.map +1 -0
  21. package/lib/commonjs/lib/contract/method.d.ts +50 -0
  22. package/lib/commonjs/lib/contract/method.js +238 -0
  23. package/lib/commonjs/lib/contract/method.js.map +1 -0
  24. package/lib/commonjs/lib/event.d.ts +85 -0
  25. package/lib/commonjs/lib/event.js +137 -0
  26. package/lib/commonjs/lib/event.js.map +1 -0
  27. package/lib/commonjs/lib/plugin.d.ts +28 -0
  28. package/lib/commonjs/lib/plugin.js +84 -0
  29. package/lib/commonjs/lib/plugin.js.map +1 -0
  30. package/lib/commonjs/lib/providers/HttpProvider.d.ts +15 -0
  31. package/lib/commonjs/lib/providers/HttpProvider.js +63 -0
  32. package/lib/commonjs/lib/providers/HttpProvider.js.map +1 -0
  33. package/lib/commonjs/lib/providers/index.d.ts +6 -0
  34. package/lib/commonjs/lib/providers/index.js +8 -0
  35. package/lib/commonjs/lib/providers/index.js.map +1 -0
  36. package/lib/commonjs/lib/trx.d.ts +315 -0
  37. package/lib/commonjs/lib/trx.js +965 -0
  38. package/lib/commonjs/lib/trx.js.map +1 -0
  39. package/lib/commonjs/package.json +1 -0
  40. package/lib/commonjs/paramValidator/index.d.ts +19 -0
  41. package/lib/commonjs/paramValidator/index.js +110 -0
  42. package/lib/commonjs/paramValidator/index.js.map +1 -0
  43. package/lib/commonjs/protocol/core/Tron_pb.cjs +7524 -0
  44. package/lib/commonjs/protocol/core/contract/account_contract_pb.cjs +961 -0
  45. package/lib/commonjs/protocol/core/contract/asset_issue_contract_pb.cjs +2196 -0
  46. package/lib/commonjs/protocol/core/contract/balance_contract_pb.cjs +3826 -0
  47. package/lib/commonjs/protocol/core/contract/common_pb.cjs +34 -0
  48. package/lib/commonjs/protocol/core/contract/exchange_contract_pb.cjs +1268 -0
  49. package/lib/commonjs/protocol/core/contract/proposal_contract_pb.cjs +675 -0
  50. package/lib/commonjs/protocol/core/contract/smart_contract_pb.cjs +2960 -0
  51. package/lib/commonjs/protocol/core/contract/storage_contract_pb.cjs +848 -0
  52. package/lib/commonjs/protocol/core/contract/vote_asset_contract_pb.cjs +340 -0
  53. package/lib/commonjs/protocol/core/contract/witness_contract_pb.cjs +956 -0
  54. package/lib/commonjs/tronweb.d.ts +111 -0
  55. package/lib/commonjs/tronweb.js +365 -0
  56. package/lib/commonjs/tronweb.js.map +1 -0
  57. package/lib/commonjs/types/ABI.d.ts +59 -0
  58. package/lib/commonjs/types/ABI.js +3 -0
  59. package/lib/commonjs/types/ABI.js.map +1 -0
  60. package/lib/commonjs/types/APIResponse.d.ts +31 -0
  61. package/lib/commonjs/types/APIResponse.js +3 -0
  62. package/lib/commonjs/types/APIResponse.js.map +1 -0
  63. package/lib/commonjs/types/Contract.d.ts +287 -0
  64. package/lib/commonjs/types/Contract.js +63 -0
  65. package/lib/commonjs/types/Contract.js.map +1 -0
  66. package/lib/commonjs/types/Providers.d.ts +8 -0
  67. package/lib/commonjs/types/Providers.js +3 -0
  68. package/lib/commonjs/types/Providers.js.map +1 -0
  69. package/lib/commonjs/types/Transaction.d.ts +65 -0
  70. package/lib/commonjs/types/Transaction.js +3 -0
  71. package/lib/commonjs/types/Transaction.js.map +1 -0
  72. package/lib/commonjs/types/TransactionBuilder.d.ts +270 -0
  73. package/lib/commonjs/types/TransactionBuilder.js +3 -0
  74. package/lib/commonjs/types/TransactionBuilder.js.map +1 -0
  75. package/lib/commonjs/types/TronWeb.d.ts +20 -0
  76. package/lib/commonjs/types/TronWeb.js +3 -0
  77. package/lib/commonjs/types/TronWeb.js.map +1 -0
  78. package/lib/commonjs/types/Trx.d.ts +263 -0
  79. package/lib/commonjs/types/Trx.js +42 -0
  80. package/lib/commonjs/types/Trx.js.map +1 -0
  81. package/lib/commonjs/types/UtilsTypes.d.ts +23 -0
  82. package/lib/commonjs/types/UtilsTypes.js +3 -0
  83. package/lib/commonjs/types/UtilsTypes.js.map +1 -0
  84. package/lib/commonjs/types/index.d.ts +9 -0
  85. package/lib/commonjs/types/index.js +13 -0
  86. package/lib/commonjs/types/index.js.map +1 -0
  87. package/lib/commonjs/utils/abi.d.ts +5 -0
  88. package/lib/commonjs/utils/abi.js +251 -0
  89. package/lib/commonjs/utils/abi.js.map +1 -0
  90. package/lib/commonjs/utils/accounts.d.ts +22 -0
  91. package/lib/commonjs/utils/accounts.js +51 -0
  92. package/lib/commonjs/utils/accounts.js.map +1 -0
  93. package/lib/commonjs/utils/address.d.ts +12 -0
  94. package/lib/commonjs/utils/address.js +91 -0
  95. package/lib/commonjs/utils/address.js.map +1 -0
  96. package/lib/commonjs/utils/base58.d.ts +3 -0
  97. package/lib/commonjs/utils/base58.js +68 -0
  98. package/lib/commonjs/utils/base58.js.map +1 -0
  99. package/lib/commonjs/utils/base64.d.ts +10 -0
  100. package/lib/commonjs/utils/base64.js +173 -0
  101. package/lib/commonjs/utils/base64.js.map +1 -0
  102. package/lib/commonjs/utils/bytes.d.ts +7 -0
  103. package/lib/commonjs/utils/bytes.js +61 -0
  104. package/lib/commonjs/utils/bytes.js.map +1 -0
  105. package/lib/commonjs/utils/code.d.ts +12 -0
  106. package/lib/commonjs/utils/code.js +166 -0
  107. package/lib/commonjs/utils/code.js.map +1 -0
  108. package/lib/commonjs/utils/crypto.d.ts +25 -0
  109. package/lib/commonjs/utils/crypto.js +222 -0
  110. package/lib/commonjs/utils/crypto.js.map +1 -0
  111. package/lib/commonjs/utils/ethersUtils.d.ts +14 -0
  112. package/lib/commonjs/utils/ethersUtils.js +39 -0
  113. package/lib/commonjs/utils/ethersUtils.js.map +1 -0
  114. package/lib/commonjs/utils/fragments.d.ts +465 -0
  115. package/lib/commonjs/utils/fragments.js +1342 -0
  116. package/lib/commonjs/utils/fragments.js.map +1 -0
  117. package/lib/commonjs/utils/help.d.ts +8 -0
  118. package/lib/commonjs/utils/help.js +61 -0
  119. package/lib/commonjs/utils/help.js.map +1 -0
  120. package/lib/commonjs/utils/index.d.ts +56 -0
  121. package/lib/commonjs/utils/index.js +43 -0
  122. package/lib/commonjs/utils/index.js.map +1 -0
  123. package/lib/commonjs/utils/interface.d.ts +381 -0
  124. package/lib/commonjs/utils/interface.js +1121 -0
  125. package/lib/commonjs/utils/interface.js.map +1 -0
  126. package/lib/commonjs/utils/message.d.ts +4 -0
  127. package/lib/commonjs/utils/message.js +38 -0
  128. package/lib/commonjs/utils/message.js.map +1 -0
  129. package/lib/commonjs/utils/transaction.d.ts +17 -0
  130. package/lib/commonjs/utils/transaction.js +678 -0
  131. package/lib/commonjs/utils/transaction.js.map +1 -0
  132. package/lib/commonjs/utils/typedData.d.ts +148 -0
  133. package/lib/commonjs/utils/typedData.js +498 -0
  134. package/lib/commonjs/utils/typedData.js.map +1 -0
  135. package/lib/commonjs/utils/validations.d.ts +22 -0
  136. package/lib/commonjs/utils/validations.js +128 -0
  137. package/lib/commonjs/utils/validations.js.map +1 -0
  138. package/lib/esm/index.d.ts +64 -0
  139. package/lib/esm/index.js +33 -0
  140. package/lib/esm/index.js.map +1 -0
  141. package/lib/esm/lib/TransactionBuilder/TransactionBuilder.d.ts +127 -0
  142. package/lib/esm/lib/TransactionBuilder/TransactionBuilder.js +1767 -0
  143. package/lib/esm/lib/TransactionBuilder/TransactionBuilder.js.map +1 -0
  144. package/lib/esm/lib/TransactionBuilder/helper.d.ts +28 -0
  145. package/lib/esm/lib/TransactionBuilder/helper.js +112 -0
  146. package/lib/esm/lib/TransactionBuilder/helper.js.map +1 -0
  147. package/lib/esm/lib/contract/index.d.ts +29 -0
  148. package/lib/esm/lib/contract/index.js +118 -0
  149. package/lib/esm/lib/contract/index.js.map +1 -0
  150. package/lib/esm/lib/contract/method.d.ts +50 -0
  151. package/lib/esm/lib/contract/method.js +233 -0
  152. package/lib/esm/lib/contract/method.js.map +1 -0
  153. package/lib/esm/lib/event.d.ts +85 -0
  154. package/lib/esm/lib/event.js +132 -0
  155. package/lib/esm/lib/event.js.map +1 -0
  156. package/lib/esm/lib/plugin.d.ts +28 -0
  157. package/lib/esm/lib/plugin.js +79 -0
  158. package/lib/esm/lib/plugin.js.map +1 -0
  159. package/lib/esm/lib/providers/HttpProvider.d.ts +15 -0
  160. package/lib/esm/lib/providers/HttpProvider.js +59 -0
  161. package/lib/esm/lib/providers/HttpProvider.js.map +1 -0
  162. package/lib/esm/lib/providers/index.d.ts +6 -0
  163. package/lib/esm/lib/providers/index.js +4 -0
  164. package/lib/esm/lib/providers/index.js.map +1 -0
  165. package/lib/esm/lib/trx.d.ts +315 -0
  166. package/lib/esm/lib/trx.js +960 -0
  167. package/lib/esm/lib/trx.js.map +1 -0
  168. package/lib/esm/package.json +1 -0
  169. package/lib/esm/paramValidator/index.d.ts +19 -0
  170. package/lib/esm/paramValidator/index.js +106 -0
  171. package/lib/esm/paramValidator/index.js.map +1 -0
  172. package/lib/esm/protocol/core/Tron_pb.cjs +7524 -0
  173. package/lib/esm/protocol/core/contract/account_contract_pb.cjs +961 -0
  174. package/lib/esm/protocol/core/contract/asset_issue_contract_pb.cjs +2196 -0
  175. package/lib/esm/protocol/core/contract/balance_contract_pb.cjs +3826 -0
  176. package/lib/esm/protocol/core/contract/common_pb.cjs +34 -0
  177. package/lib/esm/protocol/core/contract/exchange_contract_pb.cjs +1268 -0
  178. package/lib/esm/protocol/core/contract/proposal_contract_pb.cjs +675 -0
  179. package/lib/esm/protocol/core/contract/smart_contract_pb.cjs +2960 -0
  180. package/lib/esm/protocol/core/contract/storage_contract_pb.cjs +848 -0
  181. package/lib/esm/protocol/core/contract/vote_asset_contract_pb.cjs +340 -0
  182. package/lib/esm/protocol/core/contract/witness_contract_pb.cjs +956 -0
  183. package/lib/esm/tronweb.d.ts +111 -0
  184. package/lib/esm/tronweb.js +360 -0
  185. package/lib/esm/tronweb.js.map +1 -0
  186. package/lib/esm/types/ABI.d.ts +59 -0
  187. package/lib/esm/types/ABI.js +2 -0
  188. package/lib/esm/types/ABI.js.map +1 -0
  189. package/lib/esm/types/APIResponse.d.ts +31 -0
  190. package/lib/esm/types/APIResponse.js +2 -0
  191. package/lib/esm/types/APIResponse.js.map +1 -0
  192. package/lib/esm/types/Contract.d.ts +287 -0
  193. package/lib/esm/types/Contract.js +60 -0
  194. package/lib/esm/types/Contract.js.map +1 -0
  195. package/lib/esm/types/Providers.d.ts +8 -0
  196. package/lib/esm/types/Providers.js +2 -0
  197. package/lib/esm/types/Providers.js.map +1 -0
  198. package/lib/esm/types/Transaction.d.ts +65 -0
  199. package/lib/esm/types/Transaction.js +2 -0
  200. package/lib/esm/types/Transaction.js.map +1 -0
  201. package/lib/esm/types/TransactionBuilder.d.ts +270 -0
  202. package/lib/esm/types/TransactionBuilder.js +2 -0
  203. package/lib/esm/types/TransactionBuilder.js.map +1 -0
  204. package/lib/esm/types/TronWeb.d.ts +20 -0
  205. package/lib/esm/types/TronWeb.js +2 -0
  206. package/lib/esm/types/TronWeb.js.map +1 -0
  207. package/lib/esm/types/Trx.d.ts +263 -0
  208. package/lib/esm/types/Trx.js +39 -0
  209. package/lib/esm/types/Trx.js.map +1 -0
  210. package/lib/esm/types/UtilsTypes.d.ts +23 -0
  211. package/lib/esm/types/UtilsTypes.js +2 -0
  212. package/lib/esm/types/UtilsTypes.js.map +1 -0
  213. package/lib/esm/types/index.d.ts +9 -0
  214. package/lib/esm/types/index.js +10 -0
  215. package/lib/esm/types/index.js.map +1 -0
  216. package/lib/esm/utils/abi.d.ts +5 -0
  217. package/lib/esm/utils/abi.js +245 -0
  218. package/lib/esm/utils/abi.js.map +1 -0
  219. package/lib/esm/utils/accounts.d.ts +22 -0
  220. package/lib/esm/utils/accounts.js +46 -0
  221. package/lib/esm/utils/accounts.js.map +1 -0
  222. package/lib/esm/utils/address.d.ts +12 -0
  223. package/lib/esm/utils/address.js +82 -0
  224. package/lib/esm/utils/address.js.map +1 -0
  225. package/lib/esm/utils/base58.d.ts +3 -0
  226. package/lib/esm/utils/base58.js +64 -0
  227. package/lib/esm/utils/base58.js.map +1 -0
  228. package/lib/esm/utils/base64.d.ts +10 -0
  229. package/lib/esm/utils/base64.js +169 -0
  230. package/lib/esm/utils/base64.js.map +1 -0
  231. package/lib/esm/utils/bytes.d.ts +7 -0
  232. package/lib/esm/utils/bytes.js +53 -0
  233. package/lib/esm/utils/bytes.js.map +1 -0
  234. package/lib/esm/utils/code.d.ts +12 -0
  235. package/lib/esm/utils/code.js +149 -0
  236. package/lib/esm/utils/code.js.map +1 -0
  237. package/lib/esm/utils/crypto.d.ts +25 -0
  238. package/lib/esm/utils/crypto.js +198 -0
  239. package/lib/esm/utils/crypto.js.map +1 -0
  240. package/lib/esm/utils/ethersUtils.d.ts +14 -0
  241. package/lib/esm/utils/ethersUtils.js +17 -0
  242. package/lib/esm/utils/ethersUtils.js.map +1 -0
  243. package/lib/esm/utils/fragments.d.ts +465 -0
  244. package/lib/esm/utils/fragments.js +1330 -0
  245. package/lib/esm/utils/fragments.js.map +1 -0
  246. package/lib/esm/utils/help.d.ts +8 -0
  247. package/lib/esm/utils/help.js +51 -0
  248. package/lib/esm/utils/help.js.map +1 -0
  249. package/lib/esm/utils/index.d.ts +56 -0
  250. package/lib/esm/utils/index.js +40 -0
  251. package/lib/esm/utils/index.js.map +1 -0
  252. package/lib/esm/utils/interface.d.ts +381 -0
  253. package/lib/esm/utils/interface.js +1112 -0
  254. package/lib/esm/utils/interface.js.map +1 -0
  255. package/lib/esm/utils/message.d.ts +4 -0
  256. package/lib/esm/utils/message.js +32 -0
  257. package/lib/esm/utils/message.js.map +1 -0
  258. package/lib/esm/utils/transaction.d.ts +17 -0
  259. package/lib/esm/utils/transaction.js +669 -0
  260. package/lib/esm/utils/transaction.js.map +1 -0
  261. package/lib/esm/utils/typedData.d.ts +148 -0
  262. package/lib/esm/utils/typedData.js +493 -0
  263. package/lib/esm/utils/typedData.js.map +1 -0
  264. package/lib/esm/utils/validations.d.ts +22 -0
  265. package/lib/esm/utils/validations.js +108 -0
  266. package/lib/esm/utils/validations.js.map +1 -0
  267. package/package.json +110 -0
  268. package/src/index.ts +42 -0
  269. package/src/lib/TransactionBuilder/TransactionBuilder.ts +2272 -0
  270. package/src/lib/TransactionBuilder/helper.ts +139 -0
  271. package/src/lib/contract/index.ts +151 -0
  272. package/src/lib/contract/method.ts +336 -0
  273. package/src/lib/event.ts +248 -0
  274. package/src/lib/plugin.ts +102 -0
  275. package/src/lib/providers/HttpProvider.ts +66 -0
  276. package/src/lib/providers/index.ts +6 -0
  277. package/src/lib/trx.ts +1463 -0
  278. package/src/paramValidator/index.ts +136 -0
  279. package/src/protocol/core/Tron_pb.cjs +7524 -0
  280. package/src/protocol/core/contract/account_contract_pb.cjs +961 -0
  281. package/src/protocol/core/contract/asset_issue_contract_pb.cjs +2196 -0
  282. package/src/protocol/core/contract/balance_contract_pb.cjs +3826 -0
  283. package/src/protocol/core/contract/common_pb.cjs +34 -0
  284. package/src/protocol/core/contract/exchange_contract_pb.cjs +1268 -0
  285. package/src/protocol/core/contract/proposal_contract_pb.cjs +675 -0
  286. package/src/protocol/core/contract/smart_contract_pb.cjs +2960 -0
  287. package/src/protocol/core/contract/storage_contract_pb.cjs +848 -0
  288. package/src/protocol/core/contract/vote_asset_contract_pb.cjs +340 -0
  289. package/src/protocol/core/contract/witness_contract_pb.cjs +956 -0
  290. package/src/tronweb.ts +437 -0
  291. package/src/types/ABI.ts +82 -0
  292. package/src/types/APIResponse.ts +34 -0
  293. package/src/types/Contract.ts +352 -0
  294. package/src/types/Providers.ts +7 -0
  295. package/src/types/Transaction.ts +70 -0
  296. package/src/types/TransactionBuilder.ts +281 -0
  297. package/src/types/TronWeb.ts +23 -0
  298. package/src/types/Trx.ts +285 -0
  299. package/src/types/UtilsTypes.ts +25 -0
  300. package/src/types/index.ts +9 -0
  301. package/src/types/interface.d.ts +1 -0
  302. package/src/utils/abi.ts +257 -0
  303. package/src/utils/accounts.ts +60 -0
  304. package/src/utils/address.ts +89 -0
  305. package/src/utils/base58.ts +78 -0
  306. package/src/utils/base64.ts +200 -0
  307. package/src/utils/bytes.ts +68 -0
  308. package/src/utils/code.ts +172 -0
  309. package/src/utils/crypto.ts +264 -0
  310. package/src/utils/ethersUtils.ts +60 -0
  311. package/src/utils/fragments.ts +1738 -0
  312. package/src/utils/help.ts +59 -0
  313. package/src/utils/index.ts +42 -0
  314. package/src/utils/interface.ts +1362 -0
  315. package/src/utils/message.ts +38 -0
  316. package/src/utils/transaction.ts +991 -0
  317. package/src/utils/typedData.ts +688 -0
  318. package/src/utils/validations.ts +130 -0
@@ -0,0 +1,961 @@
1
+ // source: core/contract/account_contract.proto
2
+ /**
3
+ * @fileoverview
4
+ * @enhanceable
5
+ * @suppress {missingRequire} reports error on implicit type usages.
6
+ * @suppress {messageConventions} JS Compiler reports an error if a variable or
7
+ * field starts with 'MSG_' and isn't a translatable message.
8
+ * @public
9
+ */
10
+ // GENERATED CODE -- DO NOT EDIT!
11
+ /* eslint-disable */
12
+ // @ts-nocheck
13
+
14
+ var jspb = require('@tronweb3/google-protobuf');
15
+ var goog = jspb;
16
+ var global =
17
+ (typeof globalThis !== 'undefined' && globalThis) ||
18
+ (typeof window !== 'undefined' && window) ||
19
+ (typeof global !== 'undefined' && global) ||
20
+ (typeof self !== 'undefined' && self) ||
21
+ function () {
22
+ return this;
23
+ }.call(null) ||
24
+ Function('return this')();
25
+
26
+ var core_Tron_pb = require('../../core/Tron_pb.cjs');
27
+ goog.object.extend(proto, core_Tron_pb);
28
+ goog.exportSymbol('TronWebProto.AccountCreateContract', null, global);
29
+ goog.exportSymbol('TronWebProto.AccountPermissionUpdateContract', null, global);
30
+ goog.exportSymbol('TronWebProto.AccountUpdateContract', null, global);
31
+ goog.exportSymbol('TronWebProto.SetAccountIdContract', null, global);
32
+ /**
33
+ * Generated by JsPbCodeGenerator.
34
+ * @param {Array=} opt_data Optional initial data array, typically from a
35
+ * server response, or constructed directly in Javascript. The array is used
36
+ * in place and becomes part of the constructed object. It is not cloned.
37
+ * If no data is provided, the constructed object will be empty, but still
38
+ * valid.
39
+ * @extends {jspb.Message}
40
+ * @constructor
41
+ */
42
+ TronWebProto.AccountCreateContract = function (opt_data) {
43
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
44
+ };
45
+ goog.inherits(TronWebProto.AccountCreateContract, jspb.Message);
46
+ if (goog.DEBUG && !COMPILED) {
47
+ /**
48
+ * @public
49
+ * @override
50
+ */
51
+ TronWebProto.AccountCreateContract.displayName = 'TronWebProto.AccountCreateContract';
52
+ }
53
+ /**
54
+ * Generated by JsPbCodeGenerator.
55
+ * @param {Array=} opt_data Optional initial data array, typically from a
56
+ * server response, or constructed directly in Javascript. The array is used
57
+ * in place and becomes part of the constructed object. It is not cloned.
58
+ * If no data is provided, the constructed object will be empty, but still
59
+ * valid.
60
+ * @extends {jspb.Message}
61
+ * @constructor
62
+ */
63
+ TronWebProto.AccountUpdateContract = function (opt_data) {
64
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
65
+ };
66
+ goog.inherits(TronWebProto.AccountUpdateContract, jspb.Message);
67
+ if (goog.DEBUG && !COMPILED) {
68
+ /**
69
+ * @public
70
+ * @override
71
+ */
72
+ TronWebProto.AccountUpdateContract.displayName = 'TronWebProto.AccountUpdateContract';
73
+ }
74
+ /**
75
+ * Generated by JsPbCodeGenerator.
76
+ * @param {Array=} opt_data Optional initial data array, typically from a
77
+ * server response, or constructed directly in Javascript. The array is used
78
+ * in place and becomes part of the constructed object. It is not cloned.
79
+ * If no data is provided, the constructed object will be empty, but still
80
+ * valid.
81
+ * @extends {jspb.Message}
82
+ * @constructor
83
+ */
84
+ TronWebProto.SetAccountIdContract = function (opt_data) {
85
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
86
+ };
87
+ goog.inherits(TronWebProto.SetAccountIdContract, jspb.Message);
88
+ if (goog.DEBUG && !COMPILED) {
89
+ /**
90
+ * @public
91
+ * @override
92
+ */
93
+ TronWebProto.SetAccountIdContract.displayName = 'TronWebProto.SetAccountIdContract';
94
+ }
95
+ /**
96
+ * Generated by JsPbCodeGenerator.
97
+ * @param {Array=} opt_data Optional initial data array, typically from a
98
+ * server response, or constructed directly in Javascript. The array is used
99
+ * in place and becomes part of the constructed object. It is not cloned.
100
+ * If no data is provided, the constructed object will be empty, but still
101
+ * valid.
102
+ * @extends {jspb.Message}
103
+ * @constructor
104
+ */
105
+ TronWebProto.AccountPermissionUpdateContract = function (opt_data) {
106
+ jspb.Message.initialize(this, opt_data, 0, -1, TronWebProto.AccountPermissionUpdateContract.repeatedFields_, null);
107
+ };
108
+ goog.inherits(TronWebProto.AccountPermissionUpdateContract, jspb.Message);
109
+ if (goog.DEBUG && !COMPILED) {
110
+ /**
111
+ * @public
112
+ * @override
113
+ */
114
+ TronWebProto.AccountPermissionUpdateContract.displayName = 'TronWebProto.AccountPermissionUpdateContract';
115
+ }
116
+
117
+ if (jspb.Message.GENERATE_TO_OBJECT) {
118
+ /**
119
+ * Creates an object representation of this proto.
120
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
121
+ * Optional fields that are not set will be set to undefined.
122
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
123
+ * For the list of reserved names please see:
124
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
125
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
126
+ * JSPB instance for transitional soy proto support:
127
+ * http://goto/soy-param-migration
128
+ * @return {!Object}
129
+ */
130
+ TronWebProto.AccountCreateContract.prototype.toObject = function (opt_includeInstance) {
131
+ return TronWebProto.AccountCreateContract.toObject(opt_includeInstance, this);
132
+ };
133
+
134
+ /**
135
+ * Static version of the {@see toObject} method.
136
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
137
+ * the JSPB instance for transitional soy proto support:
138
+ * http://goto/soy-param-migration
139
+ * @param {!TronWebProto.AccountCreateContract} msg The msg instance to transform.
140
+ * @return {!Object}
141
+ * @suppress {unusedLocalVariables} f is only used for nested messages
142
+ */
143
+ TronWebProto.AccountCreateContract.toObject = function (includeInstance, msg) {
144
+ var f,
145
+ obj = {
146
+ ownerAddress: msg.getOwnerAddress_asB64(),
147
+ accountAddress: msg.getAccountAddress_asB64(),
148
+ type: jspb.Message.getFieldWithDefault(msg, 3, 0),
149
+ };
150
+
151
+ if (includeInstance) {
152
+ obj.$jspbMessageInstance = msg;
153
+ }
154
+ return obj;
155
+ };
156
+ }
157
+
158
+ /**
159
+ * Deserializes binary data (in protobuf wire format).
160
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
161
+ * @return {!TronWebProto.AccountCreateContract}
162
+ */
163
+ TronWebProto.AccountCreateContract.deserializeBinary = function (bytes) {
164
+ var reader = new jspb.BinaryReader(bytes);
165
+ var msg = new TronWebProto.AccountCreateContract();
166
+ return TronWebProto.AccountCreateContract.deserializeBinaryFromReader(msg, reader);
167
+ };
168
+
169
+ /**
170
+ * Deserializes binary data (in protobuf wire format) from the
171
+ * given reader into the given message object.
172
+ * @param {!TronWebProto.AccountCreateContract} msg The message object to deserialize into.
173
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
174
+ * @return {!TronWebProto.AccountCreateContract}
175
+ */
176
+ TronWebProto.AccountCreateContract.deserializeBinaryFromReader = function (msg, reader) {
177
+ while (reader.nextField()) {
178
+ if (reader.isEndGroup()) {
179
+ break;
180
+ }
181
+ var field = reader.getFieldNumber();
182
+ switch (field) {
183
+ case 1:
184
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
185
+ msg.setOwnerAddress(value);
186
+ break;
187
+ case 2:
188
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
189
+ msg.setAccountAddress(value);
190
+ break;
191
+ case 3:
192
+ var value = /** @type {!TronWebProto.AccountType} */ (reader.readEnum());
193
+ msg.setType(value);
194
+ break;
195
+ default:
196
+ reader.skipField();
197
+ break;
198
+ }
199
+ }
200
+ return msg;
201
+ };
202
+
203
+ /**
204
+ * Serializes the message to binary data (in protobuf wire format).
205
+ * @return {!Uint8Array}
206
+ */
207
+ TronWebProto.AccountCreateContract.prototype.serializeBinary = function () {
208
+ var writer = new jspb.BinaryWriter();
209
+ TronWebProto.AccountCreateContract.serializeBinaryToWriter(this, writer);
210
+ return writer.getResultBuffer();
211
+ };
212
+
213
+ /**
214
+ * Serializes the given message to binary data (in protobuf wire
215
+ * format), writing to the given BinaryWriter.
216
+ * @param {!TronWebProto.AccountCreateContract} message
217
+ * @param {!jspb.BinaryWriter} writer
218
+ * @suppress {unusedLocalVariables} f is only used for nested messages
219
+ */
220
+ TronWebProto.AccountCreateContract.serializeBinaryToWriter = function (message, writer) {
221
+ var f = undefined;
222
+ f = message.getOwnerAddress_asU8();
223
+ if (f.length > 0) {
224
+ writer.writeBytes(1, f);
225
+ }
226
+ f = message.getAccountAddress_asU8();
227
+ if (f.length > 0) {
228
+ writer.writeBytes(2, f);
229
+ }
230
+ f = message.getType();
231
+ if (f !== 0.0) {
232
+ writer.writeEnum(3, f);
233
+ }
234
+ };
235
+
236
+ /**
237
+ * optional bytes owner_address = 1;
238
+ * @return {!(string|Uint8Array)}
239
+ */
240
+ TronWebProto.AccountCreateContract.prototype.getOwnerAddress = function () {
241
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ''));
242
+ };
243
+
244
+ /**
245
+ * optional bytes owner_address = 1;
246
+ * This is a type-conversion wrapper around `getOwnerAddress()`
247
+ * @return {string}
248
+ */
249
+ TronWebProto.AccountCreateContract.prototype.getOwnerAddress_asB64 = function () {
250
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getOwnerAddress()));
251
+ };
252
+
253
+ /**
254
+ * optional bytes owner_address = 1;
255
+ * Note that Uint8Array is not supported on all browsers.
256
+ * @see http://caniuse.com/Uint8Array
257
+ * This is a type-conversion wrapper around `getOwnerAddress()`
258
+ * @return {!Uint8Array}
259
+ */
260
+ TronWebProto.AccountCreateContract.prototype.getOwnerAddress_asU8 = function () {
261
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getOwnerAddress()));
262
+ };
263
+
264
+ /**
265
+ * @param {!(string|Uint8Array)} value
266
+ * @return {!TronWebProto.AccountCreateContract} returns this
267
+ */
268
+ TronWebProto.AccountCreateContract.prototype.setOwnerAddress = function (value) {
269
+ return jspb.Message.setProto3BytesField(this, 1, value);
270
+ };
271
+
272
+ /**
273
+ * optional bytes account_address = 2;
274
+ * @return {!(string|Uint8Array)}
275
+ */
276
+ TronWebProto.AccountCreateContract.prototype.getAccountAddress = function () {
277
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ''));
278
+ };
279
+
280
+ /**
281
+ * optional bytes account_address = 2;
282
+ * This is a type-conversion wrapper around `getAccountAddress()`
283
+ * @return {string}
284
+ */
285
+ TronWebProto.AccountCreateContract.prototype.getAccountAddress_asB64 = function () {
286
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getAccountAddress()));
287
+ };
288
+
289
+ /**
290
+ * optional bytes account_address = 2;
291
+ * Note that Uint8Array is not supported on all browsers.
292
+ * @see http://caniuse.com/Uint8Array
293
+ * This is a type-conversion wrapper around `getAccountAddress()`
294
+ * @return {!Uint8Array}
295
+ */
296
+ TronWebProto.AccountCreateContract.prototype.getAccountAddress_asU8 = function () {
297
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getAccountAddress()));
298
+ };
299
+
300
+ /**
301
+ * @param {!(string|Uint8Array)} value
302
+ * @return {!TronWebProto.AccountCreateContract} returns this
303
+ */
304
+ TronWebProto.AccountCreateContract.prototype.setAccountAddress = function (value) {
305
+ return jspb.Message.setProto3BytesField(this, 2, value);
306
+ };
307
+
308
+ /**
309
+ * optional AccountType type = 3;
310
+ * @return {!TronWebProto.AccountType}
311
+ */
312
+ TronWebProto.AccountCreateContract.prototype.getType = function () {
313
+ return /** @type {!TronWebProto.AccountType} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
314
+ };
315
+
316
+ /**
317
+ * @param {!TronWebProto.AccountType} value
318
+ * @return {!TronWebProto.AccountCreateContract} returns this
319
+ */
320
+ TronWebProto.AccountCreateContract.prototype.setType = function (value) {
321
+ return jspb.Message.setProto3EnumField(this, 3, value);
322
+ };
323
+
324
+ if (jspb.Message.GENERATE_TO_OBJECT) {
325
+ /**
326
+ * Creates an object representation of this proto.
327
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
328
+ * Optional fields that are not set will be set to undefined.
329
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
330
+ * For the list of reserved names please see:
331
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
332
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
333
+ * JSPB instance for transitional soy proto support:
334
+ * http://goto/soy-param-migration
335
+ * @return {!Object}
336
+ */
337
+ TronWebProto.AccountUpdateContract.prototype.toObject = function (opt_includeInstance) {
338
+ return TronWebProto.AccountUpdateContract.toObject(opt_includeInstance, this);
339
+ };
340
+
341
+ /**
342
+ * Static version of the {@see toObject} method.
343
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
344
+ * the JSPB instance for transitional soy proto support:
345
+ * http://goto/soy-param-migration
346
+ * @param {!TronWebProto.AccountUpdateContract} msg The msg instance to transform.
347
+ * @return {!Object}
348
+ * @suppress {unusedLocalVariables} f is only used for nested messages
349
+ */
350
+ TronWebProto.AccountUpdateContract.toObject = function (includeInstance, msg) {
351
+ var f,
352
+ obj = {
353
+ accountName: msg.getAccountName_asB64(),
354
+ ownerAddress: msg.getOwnerAddress_asB64(),
355
+ };
356
+
357
+ if (includeInstance) {
358
+ obj.$jspbMessageInstance = msg;
359
+ }
360
+ return obj;
361
+ };
362
+ }
363
+
364
+ /**
365
+ * Deserializes binary data (in protobuf wire format).
366
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
367
+ * @return {!TronWebProto.AccountUpdateContract}
368
+ */
369
+ TronWebProto.AccountUpdateContract.deserializeBinary = function (bytes) {
370
+ var reader = new jspb.BinaryReader(bytes);
371
+ var msg = new TronWebProto.AccountUpdateContract();
372
+ return TronWebProto.AccountUpdateContract.deserializeBinaryFromReader(msg, reader);
373
+ };
374
+
375
+ /**
376
+ * Deserializes binary data (in protobuf wire format) from the
377
+ * given reader into the given message object.
378
+ * @param {!TronWebProto.AccountUpdateContract} msg The message object to deserialize into.
379
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
380
+ * @return {!TronWebProto.AccountUpdateContract}
381
+ */
382
+ TronWebProto.AccountUpdateContract.deserializeBinaryFromReader = function (msg, reader) {
383
+ while (reader.nextField()) {
384
+ if (reader.isEndGroup()) {
385
+ break;
386
+ }
387
+ var field = reader.getFieldNumber();
388
+ switch (field) {
389
+ case 1:
390
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
391
+ msg.setAccountName(value);
392
+ break;
393
+ case 2:
394
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
395
+ msg.setOwnerAddress(value);
396
+ break;
397
+ default:
398
+ reader.skipField();
399
+ break;
400
+ }
401
+ }
402
+ return msg;
403
+ };
404
+
405
+ /**
406
+ * Serializes the message to binary data (in protobuf wire format).
407
+ * @return {!Uint8Array}
408
+ */
409
+ TronWebProto.AccountUpdateContract.prototype.serializeBinary = function () {
410
+ var writer = new jspb.BinaryWriter();
411
+ TronWebProto.AccountUpdateContract.serializeBinaryToWriter(this, writer);
412
+ return writer.getResultBuffer();
413
+ };
414
+
415
+ /**
416
+ * Serializes the given message to binary data (in protobuf wire
417
+ * format), writing to the given BinaryWriter.
418
+ * @param {!TronWebProto.AccountUpdateContract} message
419
+ * @param {!jspb.BinaryWriter} writer
420
+ * @suppress {unusedLocalVariables} f is only used for nested messages
421
+ */
422
+ TronWebProto.AccountUpdateContract.serializeBinaryToWriter = function (message, writer) {
423
+ var f = undefined;
424
+ f = message.getAccountName_asU8();
425
+ if (f.length > 0) {
426
+ writer.writeBytes(1, f);
427
+ }
428
+ f = message.getOwnerAddress_asU8();
429
+ if (f.length > 0) {
430
+ writer.writeBytes(2, f);
431
+ }
432
+ };
433
+
434
+ /**
435
+ * optional bytes account_name = 1;
436
+ * @return {!(string|Uint8Array)}
437
+ */
438
+ TronWebProto.AccountUpdateContract.prototype.getAccountName = function () {
439
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ''));
440
+ };
441
+
442
+ /**
443
+ * optional bytes account_name = 1;
444
+ * This is a type-conversion wrapper around `getAccountName()`
445
+ * @return {string}
446
+ */
447
+ TronWebProto.AccountUpdateContract.prototype.getAccountName_asB64 = function () {
448
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getAccountName()));
449
+ };
450
+
451
+ /**
452
+ * optional bytes account_name = 1;
453
+ * Note that Uint8Array is not supported on all browsers.
454
+ * @see http://caniuse.com/Uint8Array
455
+ * This is a type-conversion wrapper around `getAccountName()`
456
+ * @return {!Uint8Array}
457
+ */
458
+ TronWebProto.AccountUpdateContract.prototype.getAccountName_asU8 = function () {
459
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getAccountName()));
460
+ };
461
+
462
+ /**
463
+ * @param {!(string|Uint8Array)} value
464
+ * @return {!TronWebProto.AccountUpdateContract} returns this
465
+ */
466
+ TronWebProto.AccountUpdateContract.prototype.setAccountName = function (value) {
467
+ return jspb.Message.setProto3BytesField(this, 1, value);
468
+ };
469
+
470
+ /**
471
+ * optional bytes owner_address = 2;
472
+ * @return {!(string|Uint8Array)}
473
+ */
474
+ TronWebProto.AccountUpdateContract.prototype.getOwnerAddress = function () {
475
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ''));
476
+ };
477
+
478
+ /**
479
+ * optional bytes owner_address = 2;
480
+ * This is a type-conversion wrapper around `getOwnerAddress()`
481
+ * @return {string}
482
+ */
483
+ TronWebProto.AccountUpdateContract.prototype.getOwnerAddress_asB64 = function () {
484
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getOwnerAddress()));
485
+ };
486
+
487
+ /**
488
+ * optional bytes owner_address = 2;
489
+ * Note that Uint8Array is not supported on all browsers.
490
+ * @see http://caniuse.com/Uint8Array
491
+ * This is a type-conversion wrapper around `getOwnerAddress()`
492
+ * @return {!Uint8Array}
493
+ */
494
+ TronWebProto.AccountUpdateContract.prototype.getOwnerAddress_asU8 = function () {
495
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getOwnerAddress()));
496
+ };
497
+
498
+ /**
499
+ * @param {!(string|Uint8Array)} value
500
+ * @return {!TronWebProto.AccountUpdateContract} returns this
501
+ */
502
+ TronWebProto.AccountUpdateContract.prototype.setOwnerAddress = function (value) {
503
+ return jspb.Message.setProto3BytesField(this, 2, value);
504
+ };
505
+
506
+ if (jspb.Message.GENERATE_TO_OBJECT) {
507
+ /**
508
+ * Creates an object representation of this proto.
509
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
510
+ * Optional fields that are not set will be set to undefined.
511
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
512
+ * For the list of reserved names please see:
513
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
514
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
515
+ * JSPB instance for transitional soy proto support:
516
+ * http://goto/soy-param-migration
517
+ * @return {!Object}
518
+ */
519
+ TronWebProto.SetAccountIdContract.prototype.toObject = function (opt_includeInstance) {
520
+ return TronWebProto.SetAccountIdContract.toObject(opt_includeInstance, this);
521
+ };
522
+
523
+ /**
524
+ * Static version of the {@see toObject} method.
525
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
526
+ * the JSPB instance for transitional soy proto support:
527
+ * http://goto/soy-param-migration
528
+ * @param {!TronWebProto.SetAccountIdContract} msg The msg instance to transform.
529
+ * @return {!Object}
530
+ * @suppress {unusedLocalVariables} f is only used for nested messages
531
+ */
532
+ TronWebProto.SetAccountIdContract.toObject = function (includeInstance, msg) {
533
+ var f,
534
+ obj = {
535
+ accountId: msg.getAccountId_asB64(),
536
+ ownerAddress: msg.getOwnerAddress_asB64(),
537
+ };
538
+
539
+ if (includeInstance) {
540
+ obj.$jspbMessageInstance = msg;
541
+ }
542
+ return obj;
543
+ };
544
+ }
545
+
546
+ /**
547
+ * Deserializes binary data (in protobuf wire format).
548
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
549
+ * @return {!TronWebProto.SetAccountIdContract}
550
+ */
551
+ TronWebProto.SetAccountIdContract.deserializeBinary = function (bytes) {
552
+ var reader = new jspb.BinaryReader(bytes);
553
+ var msg = new TronWebProto.SetAccountIdContract();
554
+ return TronWebProto.SetAccountIdContract.deserializeBinaryFromReader(msg, reader);
555
+ };
556
+
557
+ /**
558
+ * Deserializes binary data (in protobuf wire format) from the
559
+ * given reader into the given message object.
560
+ * @param {!TronWebProto.SetAccountIdContract} msg The message object to deserialize into.
561
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
562
+ * @return {!TronWebProto.SetAccountIdContract}
563
+ */
564
+ TronWebProto.SetAccountIdContract.deserializeBinaryFromReader = function (msg, reader) {
565
+ while (reader.nextField()) {
566
+ if (reader.isEndGroup()) {
567
+ break;
568
+ }
569
+ var field = reader.getFieldNumber();
570
+ switch (field) {
571
+ case 1:
572
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
573
+ msg.setAccountId(value);
574
+ break;
575
+ case 2:
576
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
577
+ msg.setOwnerAddress(value);
578
+ break;
579
+ default:
580
+ reader.skipField();
581
+ break;
582
+ }
583
+ }
584
+ return msg;
585
+ };
586
+
587
+ /**
588
+ * Serializes the message to binary data (in protobuf wire format).
589
+ * @return {!Uint8Array}
590
+ */
591
+ TronWebProto.SetAccountIdContract.prototype.serializeBinary = function () {
592
+ var writer = new jspb.BinaryWriter();
593
+ TronWebProto.SetAccountIdContract.serializeBinaryToWriter(this, writer);
594
+ return writer.getResultBuffer();
595
+ };
596
+
597
+ /**
598
+ * Serializes the given message to binary data (in protobuf wire
599
+ * format), writing to the given BinaryWriter.
600
+ * @param {!TronWebProto.SetAccountIdContract} message
601
+ * @param {!jspb.BinaryWriter} writer
602
+ * @suppress {unusedLocalVariables} f is only used for nested messages
603
+ */
604
+ TronWebProto.SetAccountIdContract.serializeBinaryToWriter = function (message, writer) {
605
+ var f = undefined;
606
+ f = message.getAccountId_asU8();
607
+ if (f.length > 0) {
608
+ writer.writeBytes(1, f);
609
+ }
610
+ f = message.getOwnerAddress_asU8();
611
+ if (f.length > 0) {
612
+ writer.writeBytes(2, f);
613
+ }
614
+ };
615
+
616
+ /**
617
+ * optional bytes account_id = 1;
618
+ * @return {!(string|Uint8Array)}
619
+ */
620
+ TronWebProto.SetAccountIdContract.prototype.getAccountId = function () {
621
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ''));
622
+ };
623
+
624
+ /**
625
+ * optional bytes account_id = 1;
626
+ * This is a type-conversion wrapper around `getAccountId()`
627
+ * @return {string}
628
+ */
629
+ TronWebProto.SetAccountIdContract.prototype.getAccountId_asB64 = function () {
630
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getAccountId()));
631
+ };
632
+
633
+ /**
634
+ * optional bytes account_id = 1;
635
+ * Note that Uint8Array is not supported on all browsers.
636
+ * @see http://caniuse.com/Uint8Array
637
+ * This is a type-conversion wrapper around `getAccountId()`
638
+ * @return {!Uint8Array}
639
+ */
640
+ TronWebProto.SetAccountIdContract.prototype.getAccountId_asU8 = function () {
641
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getAccountId()));
642
+ };
643
+
644
+ /**
645
+ * @param {!(string|Uint8Array)} value
646
+ * @return {!TronWebProto.SetAccountIdContract} returns this
647
+ */
648
+ TronWebProto.SetAccountIdContract.prototype.setAccountId = function (value) {
649
+ return jspb.Message.setProto3BytesField(this, 1, value);
650
+ };
651
+
652
+ /**
653
+ * optional bytes owner_address = 2;
654
+ * @return {!(string|Uint8Array)}
655
+ */
656
+ TronWebProto.SetAccountIdContract.prototype.getOwnerAddress = function () {
657
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ''));
658
+ };
659
+
660
+ /**
661
+ * optional bytes owner_address = 2;
662
+ * This is a type-conversion wrapper around `getOwnerAddress()`
663
+ * @return {string}
664
+ */
665
+ TronWebProto.SetAccountIdContract.prototype.getOwnerAddress_asB64 = function () {
666
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getOwnerAddress()));
667
+ };
668
+
669
+ /**
670
+ * optional bytes owner_address = 2;
671
+ * Note that Uint8Array is not supported on all browsers.
672
+ * @see http://caniuse.com/Uint8Array
673
+ * This is a type-conversion wrapper around `getOwnerAddress()`
674
+ * @return {!Uint8Array}
675
+ */
676
+ TronWebProto.SetAccountIdContract.prototype.getOwnerAddress_asU8 = function () {
677
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getOwnerAddress()));
678
+ };
679
+
680
+ /**
681
+ * @param {!(string|Uint8Array)} value
682
+ * @return {!TronWebProto.SetAccountIdContract} returns this
683
+ */
684
+ TronWebProto.SetAccountIdContract.prototype.setOwnerAddress = function (value) {
685
+ return jspb.Message.setProto3BytesField(this, 2, value);
686
+ };
687
+
688
+ /**
689
+ * List of repeated fields within this message type.
690
+ * @private {!Array<number>}
691
+ * @const
692
+ */
693
+ TronWebProto.AccountPermissionUpdateContract.repeatedFields_ = [4];
694
+
695
+ if (jspb.Message.GENERATE_TO_OBJECT) {
696
+ /**
697
+ * Creates an object representation of this proto.
698
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
699
+ * Optional fields that are not set will be set to undefined.
700
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
701
+ * For the list of reserved names please see:
702
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
703
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
704
+ * JSPB instance for transitional soy proto support:
705
+ * http://goto/soy-param-migration
706
+ * @return {!Object}
707
+ */
708
+ TronWebProto.AccountPermissionUpdateContract.prototype.toObject = function (opt_includeInstance) {
709
+ return TronWebProto.AccountPermissionUpdateContract.toObject(opt_includeInstance, this);
710
+ };
711
+
712
+ /**
713
+ * Static version of the {@see toObject} method.
714
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
715
+ * the JSPB instance for transitional soy proto support:
716
+ * http://goto/soy-param-migration
717
+ * @param {!TronWebProto.AccountPermissionUpdateContract} msg The msg instance to transform.
718
+ * @return {!Object}
719
+ * @suppress {unusedLocalVariables} f is only used for nested messages
720
+ */
721
+ TronWebProto.AccountPermissionUpdateContract.toObject = function (includeInstance, msg) {
722
+ var f,
723
+ obj = {
724
+ ownerAddress: msg.getOwnerAddress_asB64(),
725
+ owner: (f = msg.getOwner()) && core_Tron_pb.Permission.toObject(includeInstance, f),
726
+ witness: (f = msg.getWitness()) && core_Tron_pb.Permission.toObject(includeInstance, f),
727
+ activesList: jspb.Message.toObjectList(msg.getActivesList(), core_Tron_pb.Permission.toObject, includeInstance),
728
+ };
729
+
730
+ if (includeInstance) {
731
+ obj.$jspbMessageInstance = msg;
732
+ }
733
+ return obj;
734
+ };
735
+ }
736
+
737
+ /**
738
+ * Deserializes binary data (in protobuf wire format).
739
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
740
+ * @return {!TronWebProto.AccountPermissionUpdateContract}
741
+ */
742
+ TronWebProto.AccountPermissionUpdateContract.deserializeBinary = function (bytes) {
743
+ var reader = new jspb.BinaryReader(bytes);
744
+ var msg = new TronWebProto.AccountPermissionUpdateContract();
745
+ return TronWebProto.AccountPermissionUpdateContract.deserializeBinaryFromReader(msg, reader);
746
+ };
747
+
748
+ /**
749
+ * Deserializes binary data (in protobuf wire format) from the
750
+ * given reader into the given message object.
751
+ * @param {!TronWebProto.AccountPermissionUpdateContract} msg The message object to deserialize into.
752
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
753
+ * @return {!TronWebProto.AccountPermissionUpdateContract}
754
+ */
755
+ TronWebProto.AccountPermissionUpdateContract.deserializeBinaryFromReader = function (msg, reader) {
756
+ while (reader.nextField()) {
757
+ if (reader.isEndGroup()) {
758
+ break;
759
+ }
760
+ var field = reader.getFieldNumber();
761
+ switch (field) {
762
+ case 1:
763
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
764
+ msg.setOwnerAddress(value);
765
+ break;
766
+ case 2:
767
+ var value = new core_Tron_pb.Permission();
768
+ reader.readMessage(value, core_Tron_pb.Permission.deserializeBinaryFromReader);
769
+ msg.setOwner(value);
770
+ break;
771
+ case 3:
772
+ var value = new core_Tron_pb.Permission();
773
+ reader.readMessage(value, core_Tron_pb.Permission.deserializeBinaryFromReader);
774
+ msg.setWitness(value);
775
+ break;
776
+ case 4:
777
+ var value = new core_Tron_pb.Permission();
778
+ reader.readMessage(value, core_Tron_pb.Permission.deserializeBinaryFromReader);
779
+ msg.addActives(value);
780
+ break;
781
+ default:
782
+ reader.skipField();
783
+ break;
784
+ }
785
+ }
786
+ return msg;
787
+ };
788
+
789
+ /**
790
+ * Serializes the message to binary data (in protobuf wire format).
791
+ * @return {!Uint8Array}
792
+ */
793
+ TronWebProto.AccountPermissionUpdateContract.prototype.serializeBinary = function () {
794
+ var writer = new jspb.BinaryWriter();
795
+ TronWebProto.AccountPermissionUpdateContract.serializeBinaryToWriter(this, writer);
796
+ return writer.getResultBuffer();
797
+ };
798
+
799
+ /**
800
+ * Serializes the given message to binary data (in protobuf wire
801
+ * format), writing to the given BinaryWriter.
802
+ * @param {!TronWebProto.AccountPermissionUpdateContract} message
803
+ * @param {!jspb.BinaryWriter} writer
804
+ * @suppress {unusedLocalVariables} f is only used for nested messages
805
+ */
806
+ TronWebProto.AccountPermissionUpdateContract.serializeBinaryToWriter = function (message, writer) {
807
+ var f = undefined;
808
+ f = message.getOwnerAddress_asU8();
809
+ if (f.length > 0) {
810
+ writer.writeBytes(1, f);
811
+ }
812
+ f = message.getOwner();
813
+ if (f != null) {
814
+ writer.writeMessage(2, f, core_Tron_pb.Permission.serializeBinaryToWriter);
815
+ }
816
+ f = message.getWitness();
817
+ if (f != null) {
818
+ writer.writeMessage(3, f, core_Tron_pb.Permission.serializeBinaryToWriter);
819
+ }
820
+ f = message.getActivesList();
821
+ if (f.length > 0) {
822
+ writer.writeRepeatedMessage(4, f, core_Tron_pb.Permission.serializeBinaryToWriter);
823
+ }
824
+ };
825
+
826
+ /**
827
+ * optional bytes owner_address = 1;
828
+ * @return {!(string|Uint8Array)}
829
+ */
830
+ TronWebProto.AccountPermissionUpdateContract.prototype.getOwnerAddress = function () {
831
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ''));
832
+ };
833
+
834
+ /**
835
+ * optional bytes owner_address = 1;
836
+ * This is a type-conversion wrapper around `getOwnerAddress()`
837
+ * @return {string}
838
+ */
839
+ TronWebProto.AccountPermissionUpdateContract.prototype.getOwnerAddress_asB64 = function () {
840
+ return /** @type {string} */ (jspb.Message.bytesAsB64(this.getOwnerAddress()));
841
+ };
842
+
843
+ /**
844
+ * optional bytes owner_address = 1;
845
+ * Note that Uint8Array is not supported on all browsers.
846
+ * @see http://caniuse.com/Uint8Array
847
+ * This is a type-conversion wrapper around `getOwnerAddress()`
848
+ * @return {!Uint8Array}
849
+ */
850
+ TronWebProto.AccountPermissionUpdateContract.prototype.getOwnerAddress_asU8 = function () {
851
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(this.getOwnerAddress()));
852
+ };
853
+
854
+ /**
855
+ * @param {!(string|Uint8Array)} value
856
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
857
+ */
858
+ TronWebProto.AccountPermissionUpdateContract.prototype.setOwnerAddress = function (value) {
859
+ return jspb.Message.setProto3BytesField(this, 1, value);
860
+ };
861
+
862
+ /**
863
+ * optional Permission owner = 2;
864
+ * @return {?TronWebProto.Permission}
865
+ */
866
+ TronWebProto.AccountPermissionUpdateContract.prototype.getOwner = function () {
867
+ return /** @type{?TronWebProto.Permission} */ (jspb.Message.getWrapperField(this, core_Tron_pb.Permission, 2));
868
+ };
869
+
870
+ /**
871
+ * @param {?TronWebProto.Permission|undefined} value
872
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
873
+ */
874
+ TronWebProto.AccountPermissionUpdateContract.prototype.setOwner = function (value) {
875
+ return jspb.Message.setWrapperField(this, 2, value);
876
+ };
877
+
878
+ /**
879
+ * Clears the message field making it undefined.
880
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
881
+ */
882
+ TronWebProto.AccountPermissionUpdateContract.prototype.clearOwner = function () {
883
+ return this.setOwner(undefined);
884
+ };
885
+
886
+ /**
887
+ * Returns whether this field is set.
888
+ * @return {boolean}
889
+ */
890
+ TronWebProto.AccountPermissionUpdateContract.prototype.hasOwner = function () {
891
+ return jspb.Message.getField(this, 2) != null;
892
+ };
893
+
894
+ /**
895
+ * optional Permission witness = 3;
896
+ * @return {?TronWebProto.Permission}
897
+ */
898
+ TronWebProto.AccountPermissionUpdateContract.prototype.getWitness = function () {
899
+ return /** @type{?TronWebProto.Permission} */ (jspb.Message.getWrapperField(this, core_Tron_pb.Permission, 3));
900
+ };
901
+
902
+ /**
903
+ * @param {?TronWebProto.Permission|undefined} value
904
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
905
+ */
906
+ TronWebProto.AccountPermissionUpdateContract.prototype.setWitness = function (value) {
907
+ return jspb.Message.setWrapperField(this, 3, value);
908
+ };
909
+
910
+ /**
911
+ * Clears the message field making it undefined.
912
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
913
+ */
914
+ TronWebProto.AccountPermissionUpdateContract.prototype.clearWitness = function () {
915
+ return this.setWitness(undefined);
916
+ };
917
+
918
+ /**
919
+ * Returns whether this field is set.
920
+ * @return {boolean}
921
+ */
922
+ TronWebProto.AccountPermissionUpdateContract.prototype.hasWitness = function () {
923
+ return jspb.Message.getField(this, 3) != null;
924
+ };
925
+
926
+ /**
927
+ * repeated Permission actives = 4;
928
+ * @return {!Array<!TronWebProto.Permission>}
929
+ */
930
+ TronWebProto.AccountPermissionUpdateContract.prototype.getActivesList = function () {
931
+ return /** @type{!Array<!TronWebProto.Permission>} */ (
932
+ jspb.Message.getRepeatedWrapperField(this, core_Tron_pb.Permission, 4)
933
+ );
934
+ };
935
+
936
+ /**
937
+ * @param {!Array<!TronWebProto.Permission>} value
938
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
939
+ */
940
+ TronWebProto.AccountPermissionUpdateContract.prototype.setActivesList = function (value) {
941
+ return jspb.Message.setRepeatedWrapperField(this, 4, value);
942
+ };
943
+
944
+ /**
945
+ * @param {!TronWebProto.Permission=} opt_value
946
+ * @param {number=} opt_index
947
+ * @return {!TronWebProto.Permission}
948
+ */
949
+ TronWebProto.AccountPermissionUpdateContract.prototype.addActives = function (opt_value, opt_index) {
950
+ return jspb.Message.addToRepeatedWrapperField(this, 4, opt_value, TronWebProto.Permission, opt_index);
951
+ };
952
+
953
+ /**
954
+ * Clears the list making it empty but non-null.
955
+ * @return {!TronWebProto.AccountPermissionUpdateContract} returns this
956
+ */
957
+ TronWebProto.AccountPermissionUpdateContract.prototype.clearActivesList = function () {
958
+ return this.setActivesList([]);
959
+ };
960
+
961
+ goog.object.extend(exports, TronWebProto);