@mainsail/contracts 0.0.1-evm.5 → 0.0.1-evm.50

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 (532) hide show
  1. package/distribution/contracts/api/api.d.ts +7 -14
  2. package/distribution/contracts/api/api.d.ts.map +1 -1
  3. package/distribution/contracts/api/rpc.d.ts +9 -13
  4. package/distribution/contracts/api/rpc.d.ts.map +1 -1
  5. package/distribution/contracts/api-sync.d.ts +7 -3
  6. package/distribution/contracts/api-sync.d.ts.map +1 -1
  7. package/distribution/contracts/blockchain-utilities.d.ts +19 -0
  8. package/distribution/contracts/blockchain-utilities.d.ts.map +1 -0
  9. package/distribution/contracts/cli/application.d.ts +15 -0
  10. package/distribution/contracts/cli/application.d.ts.map +1 -0
  11. package/distribution/contracts/cli/cli.d.ts +22 -0
  12. package/distribution/contracts/cli/cli.d.ts.map +1 -0
  13. package/distribution/contracts/cli/commands.d.ts +26 -0
  14. package/distribution/contracts/cli/commands.d.ts.map +1 -0
  15. package/distribution/contracts/cli/index.d.ts +6 -0
  16. package/distribution/contracts/cli/index.d.ts.map +1 -0
  17. package/distribution/contracts/cli/paths.d.ts +2 -0
  18. package/distribution/contracts/cli/paths.d.ts.map +1 -0
  19. package/distribution/contracts/cli/services.d.ts +106 -0
  20. package/distribution/contracts/cli/services.d.ts.map +1 -0
  21. package/distribution/contracts/consensus/consensus.d.ts +25 -22
  22. package/distribution/contracts/consensus/consensus.d.ts.map +1 -1
  23. package/distribution/contracts/consensus/enums.d.ts +3 -10
  24. package/distribution/contracts/consensus/enums.d.ts.map +1 -1
  25. package/distribution/contracts/consensus/processor.d.ts +4 -7
  26. package/distribution/contracts/consensus/processor.d.ts.map +1 -1
  27. package/distribution/contracts/consensus-storage.d.ts +8 -9
  28. package/distribution/contracts/consensus-storage.d.ts.map +1 -1
  29. package/distribution/contracts/crypto/block.d.ts +54 -53
  30. package/distribution/contracts/crypto/block.d.ts.map +1 -1
  31. package/distribution/contracts/crypto/commit-handler.d.ts +5 -0
  32. package/distribution/contracts/crypto/commit-handler.d.ts.map +1 -0
  33. package/distribution/contracts/crypto/commit.d.ts +11 -9
  34. package/distribution/contracts/crypto/commit.d.ts.map +1 -1
  35. package/distribution/contracts/crypto/config.d.ts +10 -7
  36. package/distribution/contracts/crypto/config.d.ts.map +1 -1
  37. package/distribution/contracts/crypto/crypto.d.ts +0 -1
  38. package/distribution/contracts/crypto/crypto.d.ts.map +1 -1
  39. package/distribution/contracts/crypto/hash.d.ts +4 -4
  40. package/distribution/contracts/crypto/hash.d.ts.map +1 -1
  41. package/distribution/contracts/crypto/identities.d.ts +15 -8
  42. package/distribution/contracts/crypto/identities.d.ts.map +1 -1
  43. package/distribution/contracts/crypto/index.d.ts +2 -1
  44. package/distribution/contracts/crypto/index.d.ts.map +1 -1
  45. package/distribution/contracts/crypto/messages.d.ts +17 -106
  46. package/distribution/contracts/crypto/messages.d.ts.map +1 -1
  47. package/distribution/contracts/crypto/networks.d.ts +17 -12
  48. package/distribution/contracts/crypto/networks.d.ts.map +1 -1
  49. package/distribution/contracts/crypto/proposal.d.ts +48 -0
  50. package/distribution/contracts/crypto/proposal.d.ts.map +1 -0
  51. package/distribution/contracts/crypto/transactions.d.ts +72 -113
  52. package/distribution/contracts/crypto/transactions.d.ts.map +1 -1
  53. package/distribution/contracts/crypto/validator.d.ts +5 -5
  54. package/distribution/contracts/crypto/validator.d.ts.map +1 -1
  55. package/distribution/contracts/crypto/worker.d.ts +23 -14
  56. package/distribution/contracts/crypto/worker.d.ts.map +1 -1
  57. package/distribution/contracts/database.d.ts +20 -9
  58. package/distribution/contracts/database.d.ts.map +1 -1
  59. package/distribution/contracts/evm/contract-service.d.ts +32 -0
  60. package/distribution/contracts/evm/contract-service.d.ts.map +1 -0
  61. package/distribution/contracts/evm/evm.d.ts +102 -37
  62. package/distribution/contracts/evm/evm.d.ts.map +1 -1
  63. package/distribution/contracts/evm/index.d.ts +3 -1
  64. package/distribution/contracts/evm/index.d.ts.map +1 -1
  65. package/distribution/contracts/evm/instance.d.ts +30 -0
  66. package/distribution/contracts/evm/instance.d.ts.map +1 -0
  67. package/distribution/contracts/evm/storage.d.ts +58 -0
  68. package/distribution/contracts/evm/storage.d.ts.map +1 -0
  69. package/distribution/contracts/evm/worker.d.ts +7 -10
  70. package/distribution/contracts/evm/worker.d.ts.map +1 -1
  71. package/distribution/contracts/forger.d.ts +15 -0
  72. package/distribution/contracts/forger.d.ts.map +1 -0
  73. package/distribution/contracts/index.d.ts +8 -5
  74. package/distribution/contracts/index.d.ts.map +1 -1
  75. package/distribution/contracts/kernel/application.d.ts +13 -17
  76. package/distribution/contracts/kernel/application.d.ts.map +1 -1
  77. package/distribution/contracts/kernel/cache.d.ts +1 -0
  78. package/distribution/contracts/kernel/cache.d.ts.map +1 -1
  79. package/distribution/contracts/kernel/container.d.ts +1 -1
  80. package/distribution/contracts/kernel/container.d.ts.map +1 -1
  81. package/distribution/contracts/kernel/events.d.ts +14 -19
  82. package/distribution/contracts/kernel/events.d.ts.map +1 -1
  83. package/distribution/contracts/kernel/filesystem.d.ts +7 -6
  84. package/distribution/contracts/kernel/filesystem.d.ts.map +1 -1
  85. package/distribution/contracts/kernel/index.d.ts +3 -2
  86. package/distribution/contracts/kernel/index.d.ts.map +1 -1
  87. package/distribution/contracts/kernel/ipc.d.ts +19 -19
  88. package/distribution/contracts/kernel/ipc.d.ts.map +1 -1
  89. package/distribution/contracts/kernel/log.d.ts +7 -8
  90. package/distribution/contracts/kernel/log.d.ts.map +1 -1
  91. package/distribution/contracts/kernel/pipeline.d.ts +7 -6
  92. package/distribution/contracts/kernel/pipeline.d.ts.map +1 -1
  93. package/distribution/contracts/kernel/providers.d.ts +13 -0
  94. package/distribution/contracts/kernel/providers.d.ts.map +1 -0
  95. package/distribution/contracts/kernel/queue.d.ts +3 -2
  96. package/distribution/contracts/kernel/queue.d.ts.map +1 -1
  97. package/distribution/contracts/kernel/repository.d.ts +2 -2
  98. package/distribution/contracts/kernel/repository.d.ts.map +1 -1
  99. package/distribution/contracts/kernel/trigger.d.ts +2 -0
  100. package/distribution/contracts/kernel/trigger.d.ts.map +1 -0
  101. package/distribution/contracts/network-generator.d.ts +22 -2
  102. package/distribution/contracts/network-generator.d.ts.map +1 -1
  103. package/distribution/contracts/p2p/api-node-discoverer.d.ts +2 -2
  104. package/distribution/contracts/p2p/api-node-discoverer.d.ts.map +1 -1
  105. package/distribution/contracts/p2p/api-node-processor.d.ts +1 -1
  106. package/distribution/contracts/p2p/api-node-processor.d.ts.map +1 -1
  107. package/distribution/contracts/p2p/api-node-repository.d.ts +1 -1
  108. package/distribution/contracts/p2p/api-node-repository.d.ts.map +1 -1
  109. package/distribution/contracts/p2p/api-node-verifier.d.ts +1 -1
  110. package/distribution/contracts/p2p/api-node-verifier.d.ts.map +1 -1
  111. package/distribution/contracts/p2p/api-node.d.ts +1 -1
  112. package/distribution/contracts/p2p/api-node.d.ts.map +1 -1
  113. package/distribution/contracts/p2p/broadcaster.d.ts +2 -3
  114. package/distribution/contracts/p2p/broadcaster.d.ts.map +1 -1
  115. package/distribution/contracts/p2p/downloader.d.ts +1 -1
  116. package/distribution/contracts/p2p/downloader.d.ts.map +1 -1
  117. package/distribution/contracts/p2p/endpoints.d.ts +15 -22
  118. package/distribution/contracts/p2p/endpoints.d.ts.map +1 -1
  119. package/distribution/contracts/p2p/enums.d.ts +2 -4
  120. package/distribution/contracts/p2p/enums.d.ts.map +1 -1
  121. package/distribution/contracts/p2p/header-service.d.ts +2 -2
  122. package/distribution/contracts/p2p/header-service.d.ts.map +1 -1
  123. package/distribution/contracts/p2p/header.d.ts +4 -4
  124. package/distribution/contracts/p2p/header.d.ts.map +1 -1
  125. package/distribution/contracts/p2p/index.d.ts +4 -3
  126. package/distribution/contracts/p2p/index.d.ts.map +1 -1
  127. package/distribution/contracts/p2p/log.d.ts +4 -11
  128. package/distribution/contracts/p2p/log.d.ts.map +1 -1
  129. package/distribution/contracts/p2p/nes.d.ts +3 -3
  130. package/distribution/contracts/p2p/nes.d.ts.map +1 -1
  131. package/distribution/contracts/p2p/peer-communicator.d.ts +5 -7
  132. package/distribution/contracts/p2p/peer-communicator.d.ts.map +1 -1
  133. package/distribution/contracts/p2p/peer-connector.d.ts +5 -3
  134. package/distribution/contracts/p2p/peer-connector.d.ts.map +1 -1
  135. package/distribution/contracts/p2p/peer-discoverer.d.ts +1 -1
  136. package/distribution/contracts/p2p/peer-discoverer.d.ts.map +1 -1
  137. package/distribution/contracts/p2p/peer-disposer.d.ts +1 -1
  138. package/distribution/contracts/p2p/peer-disposer.d.ts.map +1 -1
  139. package/distribution/contracts/p2p/peer-processor.d.ts +4 -3
  140. package/distribution/contracts/p2p/peer-processor.d.ts.map +1 -1
  141. package/distribution/contracts/p2p/peer-repository.d.ts +1 -1
  142. package/distribution/contracts/p2p/peer-repository.d.ts.map +1 -1
  143. package/distribution/contracts/p2p/peer-verifier.d.ts +1 -1
  144. package/distribution/contracts/p2p/peer-verifier.d.ts.map +1 -1
  145. package/distribution/contracts/p2p/peer.d.ts +12 -13
  146. package/distribution/contracts/p2p/peer.d.ts.map +1 -1
  147. package/distribution/contracts/p2p/server.d.ts +27 -3
  148. package/distribution/contracts/p2p/server.d.ts.map +1 -1
  149. package/distribution/contracts/p2p/service.d.ts +1 -1
  150. package/distribution/contracts/p2p/service.d.ts.map +1 -1
  151. package/distribution/contracts/p2p/state.d.ts +1 -1
  152. package/distribution/contracts/p2p/state.d.ts.map +1 -1
  153. package/distribution/contracts/p2p/statistic.d.ts +85 -0
  154. package/distribution/contracts/p2p/statistic.d.ts.map +1 -0
  155. package/distribution/contracts/processor/block-processor-result.d.ts +8 -0
  156. package/distribution/contracts/processor/block-processor-result.d.ts.map +1 -0
  157. package/distribution/contracts/processor/block-processor.d.ts +7 -0
  158. package/distribution/contracts/processor/block-processor.d.ts.map +1 -0
  159. package/distribution/contracts/processor/handler.d.ts +5 -0
  160. package/distribution/contracts/processor/handler.d.ts.map +1 -0
  161. package/distribution/contracts/processor/index.d.ts +7 -0
  162. package/distribution/contracts/processor/index.d.ts.map +1 -0
  163. package/distribution/contracts/processor/processable-unit.d.ts +16 -0
  164. package/distribution/contracts/processor/processable-unit.d.ts.map +1 -0
  165. package/distribution/contracts/processor/transaction-processor.d.ts +7 -0
  166. package/distribution/contracts/processor/transaction-processor.d.ts.map +1 -0
  167. package/distribution/contracts/processor/verifier.d.ts +5 -0
  168. package/distribution/contracts/processor/verifier.d.ts.map +1 -0
  169. package/distribution/contracts/serializer.d.ts +4 -5
  170. package/distribution/contracts/serializer.d.ts.map +1 -1
  171. package/distribution/contracts/shared/dynamic-fee.d.ts +1 -1
  172. package/distribution/contracts/shared/dynamic-fee.d.ts.map +1 -1
  173. package/distribution/contracts/snapshot.d.ts +59 -0
  174. package/distribution/contracts/snapshot.d.ts.map +1 -0
  175. package/distribution/contracts/state/store.d.ts +4 -4
  176. package/distribution/contracts/state/store.d.ts.map +1 -1
  177. package/distribution/contracts/state/wallets.d.ts +11 -8
  178. package/distribution/contracts/state/wallets.d.ts.map +1 -1
  179. package/distribution/contracts/transaction-pool/broadcaster.d.ts +4 -15
  180. package/distribution/contracts/transaction-pool/broadcaster.d.ts.map +1 -1
  181. package/distribution/contracts/transaction-pool/client.d.ts +1 -2
  182. package/distribution/contracts/transaction-pool/client.d.ts.map +1 -1
  183. package/distribution/contracts/transaction-pool/index.d.ts +1 -2
  184. package/distribution/contracts/transaction-pool/index.d.ts.map +1 -1
  185. package/distribution/contracts/transaction-pool/mempool.d.ts +2 -2
  186. package/distribution/contracts/transaction-pool/mempool.d.ts.map +1 -1
  187. package/distribution/contracts/transaction-pool/processor.d.ts +1 -2
  188. package/distribution/contracts/transaction-pool/processor.d.ts.map +1 -1
  189. package/distribution/contracts/transaction-pool/query.d.ts +2 -6
  190. package/distribution/contracts/transaction-pool/query.d.ts.map +1 -1
  191. package/distribution/contracts/transaction-pool/selector.d.ts +15 -0
  192. package/distribution/contracts/transaction-pool/selector.d.ts.map +1 -0
  193. package/distribution/contracts/transaction-pool/sender-mempool.d.ts +5 -3
  194. package/distribution/contracts/transaction-pool/sender-mempool.d.ts.map +1 -1
  195. package/distribution/contracts/transaction-pool/sender-state.d.ts +4 -2
  196. package/distribution/contracts/transaction-pool/sender-state.d.ts.map +1 -1
  197. package/distribution/contracts/transaction-pool/service.d.ts +2 -2
  198. package/distribution/contracts/transaction-pool/service.d.ts.map +1 -1
  199. package/distribution/contracts/transaction-pool/storage.d.ts +5 -6
  200. package/distribution/contracts/transaction-pool/storage.d.ts.map +1 -1
  201. package/distribution/contracts/transaction-pool/worker.d.ts +12 -14
  202. package/distribution/contracts/transaction-pool/worker.d.ts.map +1 -1
  203. package/distribution/contracts/transactions.d.ts +6 -31
  204. package/distribution/contracts/transactions.d.ts.map +1 -1
  205. package/distribution/contracts/types/index.d.ts +3 -7
  206. package/distribution/contracts/types/index.d.ts.map +1 -1
  207. package/distribution/contracts/validator-set.d.ts +3 -3
  208. package/distribution/contracts/validator-set.d.ts.map +1 -1
  209. package/distribution/contracts/validator.d.ts +3 -4
  210. package/distribution/contracts/validator.d.ts.map +1 -1
  211. package/distribution/contracts/webhooks.d.ts +8 -1
  212. package/distribution/contracts/webhooks.d.ts.map +1 -1
  213. package/distribution/index.d.ts +1 -6
  214. package/distribution/index.d.ts.map +1 -1
  215. package/distribution/{utils.d.ts → utilities.d.ts} +1 -1
  216. package/distribution/utilities.d.ts.map +1 -0
  217. package/package.json +16 -13
  218. package/distribution/constants/channels.d.ts +0 -2
  219. package/distribution/constants/channels.d.ts.map +0 -1
  220. package/distribution/constants/channels.js +0 -2
  221. package/distribution/constants/channels.js.map +0 -1
  222. package/distribution/constants/environment-variables.d.ts +0 -3
  223. package/distribution/constants/environment-variables.d.ts.map +0 -1
  224. package/distribution/constants/environment-variables.js +0 -136
  225. package/distribution/constants/environment-variables.js.map +0 -1
  226. package/distribution/constants/index.d.ts +0 -4
  227. package/distribution/constants/index.d.ts.map +0 -1
  228. package/distribution/constants/index.js +0 -4
  229. package/distribution/constants/index.js.map +0 -1
  230. package/distribution/constants/units.d.ts +0 -8
  231. package/distribution/constants/units.d.ts.map +0 -1
  232. package/distribution/constants/units.js +0 -9
  233. package/distribution/constants/units.js.map +0 -1
  234. package/distribution/contracts/api/api.js +0 -6
  235. package/distribution/contracts/api/api.js.map +0 -1
  236. package/distribution/contracts/api/index.js +0 -3
  237. package/distribution/contracts/api/index.js.map +0 -1
  238. package/distribution/contracts/api/rpc.js +0 -9
  239. package/distribution/contracts/api/rpc.js.map +0 -1
  240. package/distribution/contracts/api-sync.js +0 -2
  241. package/distribution/contracts/api-sync.js.map +0 -1
  242. package/distribution/contracts/consensus/consensus.js +0 -2
  243. package/distribution/contracts/consensus/consensus.js.map +0 -1
  244. package/distribution/contracts/consensus/enums.js +0 -13
  245. package/distribution/contracts/consensus/enums.js.map +0 -1
  246. package/distribution/contracts/consensus/index.js +0 -4
  247. package/distribution/contracts/consensus/index.js.map +0 -1
  248. package/distribution/contracts/consensus/processor.js +0 -2
  249. package/distribution/contracts/consensus/processor.js.map +0 -1
  250. package/distribution/contracts/consensus-storage.js +0 -2
  251. package/distribution/contracts/consensus-storage.js.map +0 -1
  252. package/distribution/contracts/crypto/block.js +0 -2
  253. package/distribution/contracts/crypto/block.js.map +0 -1
  254. package/distribution/contracts/crypto/commit.js +0 -2
  255. package/distribution/contracts/crypto/commit.js.map +0 -1
  256. package/distribution/contracts/crypto/config.js +0 -2
  257. package/distribution/contracts/crypto/config.js.map +0 -1
  258. package/distribution/contracts/crypto/crypto.js +0 -2
  259. package/distribution/contracts/crypto/crypto.js.map +0 -1
  260. package/distribution/contracts/crypto/enums.d.ts +0 -17
  261. package/distribution/contracts/crypto/enums.d.ts.map +0 -1
  262. package/distribution/contracts/crypto/enums.js +0 -20
  263. package/distribution/contracts/crypto/enums.js.map +0 -1
  264. package/distribution/contracts/crypto/hash.js +0 -2
  265. package/distribution/contracts/crypto/hash.js.map +0 -1
  266. package/distribution/contracts/crypto/identities.js +0 -2
  267. package/distribution/contracts/crypto/identities.js.map +0 -1
  268. package/distribution/contracts/crypto/index.js +0 -14
  269. package/distribution/contracts/crypto/index.js.map +0 -1
  270. package/distribution/contracts/crypto/messages.js +0 -6
  271. package/distribution/contracts/crypto/messages.js.map +0 -1
  272. package/distribution/contracts/crypto/networks.js +0 -2
  273. package/distribution/contracts/crypto/networks.js.map +0 -1
  274. package/distribution/contracts/crypto/signatures.js +0 -2
  275. package/distribution/contracts/crypto/signatures.js.map +0 -1
  276. package/distribution/contracts/crypto/transactions.js +0 -2
  277. package/distribution/contracts/crypto/transactions.js.map +0 -1
  278. package/distribution/contracts/crypto/validator.js +0 -2
  279. package/distribution/contracts/crypto/validator.js.map +0 -1
  280. package/distribution/contracts/crypto/worker.js +0 -2
  281. package/distribution/contracts/crypto/worker.js.map +0 -1
  282. package/distribution/contracts/database.js +0 -2
  283. package/distribution/contracts/database.js.map +0 -1
  284. package/distribution/contracts/evm/evm.js +0 -13
  285. package/distribution/contracts/evm/evm.js.map +0 -1
  286. package/distribution/contracts/evm/gas-fee.d.ts +0 -10
  287. package/distribution/contracts/evm/gas-fee.d.ts.map +0 -1
  288. package/distribution/contracts/evm/gas-fee.js +0 -2
  289. package/distribution/contracts/evm/gas-fee.js.map +0 -1
  290. package/distribution/contracts/evm/index.js +0 -5
  291. package/distribution/contracts/evm/index.js.map +0 -1
  292. package/distribution/contracts/evm/state.js +0 -2
  293. package/distribution/contracts/evm/state.js.map +0 -1
  294. package/distribution/contracts/evm/worker.js +0 -2
  295. package/distribution/contracts/evm/worker.js.map +0 -1
  296. package/distribution/contracts/index.js +0 -22
  297. package/distribution/contracts/index.js.map +0 -1
  298. package/distribution/contracts/kernel/application.js +0 -2
  299. package/distribution/contracts/kernel/application.js.map +0 -1
  300. package/distribution/contracts/kernel/cache.js +0 -2
  301. package/distribution/contracts/kernel/cache.js.map +0 -1
  302. package/distribution/contracts/kernel/config.js +0 -2
  303. package/distribution/contracts/kernel/config.js.map +0 -1
  304. package/distribution/contracts/kernel/container.js +0 -2
  305. package/distribution/contracts/kernel/container.js.map +0 -1
  306. package/distribution/contracts/kernel/environment-variables.d.ts +0 -3
  307. package/distribution/contracts/kernel/environment-variables.d.ts.map +0 -1
  308. package/distribution/contracts/kernel/environment-variables.js +0 -2
  309. package/distribution/contracts/kernel/environment-variables.js.map +0 -1
  310. package/distribution/contracts/kernel/events.js +0 -2
  311. package/distribution/contracts/kernel/events.js.map +0 -1
  312. package/distribution/contracts/kernel/filesystem.js +0 -2
  313. package/distribution/contracts/kernel/filesystem.js.map +0 -1
  314. package/distribution/contracts/kernel/index.js +0 -15
  315. package/distribution/contracts/kernel/index.js.map +0 -1
  316. package/distribution/contracts/kernel/ipc.js +0 -2
  317. package/distribution/contracts/kernel/ipc.js.map +0 -1
  318. package/distribution/contracts/kernel/lock.js +0 -2
  319. package/distribution/contracts/kernel/lock.js.map +0 -1
  320. package/distribution/contracts/kernel/log.js +0 -2
  321. package/distribution/contracts/kernel/log.js.map +0 -1
  322. package/distribution/contracts/kernel/pipeline.js +0 -2
  323. package/distribution/contracts/kernel/pipeline.js.map +0 -1
  324. package/distribution/contracts/kernel/queue.js +0 -2
  325. package/distribution/contracts/kernel/queue.js.map +0 -1
  326. package/distribution/contracts/kernel/repository.js +0 -2
  327. package/distribution/contracts/kernel/repository.js.map +0 -1
  328. package/distribution/contracts/kernel/validation.js +0 -2
  329. package/distribution/contracts/kernel/validation.js.map +0 -1
  330. package/distribution/contracts/network-generator.js +0 -2
  331. package/distribution/contracts/network-generator.js.map +0 -1
  332. package/distribution/contracts/p2p/api-node-discoverer.js +0 -2
  333. package/distribution/contracts/p2p/api-node-discoverer.js.map +0 -1
  334. package/distribution/contracts/p2p/api-node-processor.js +0 -2
  335. package/distribution/contracts/p2p/api-node-processor.js.map +0 -1
  336. package/distribution/contracts/p2p/api-node-repository.js +0 -2
  337. package/distribution/contracts/p2p/api-node-repository.js.map +0 -1
  338. package/distribution/contracts/p2p/api-node-verifier.js +0 -2
  339. package/distribution/contracts/p2p/api-node-verifier.js.map +0 -1
  340. package/distribution/contracts/p2p/api-node.js +0 -2
  341. package/distribution/contracts/p2p/api-node.js.map +0 -1
  342. package/distribution/contracts/p2p/broadcaster.js +0 -2
  343. package/distribution/contracts/p2p/broadcaster.js.map +0 -1
  344. package/distribution/contracts/p2p/downloader.js +0 -2
  345. package/distribution/contracts/p2p/downloader.js.map +0 -1
  346. package/distribution/contracts/p2p/endpoints.js +0 -2
  347. package/distribution/contracts/p2p/endpoints.js.map +0 -1
  348. package/distribution/contracts/p2p/enums.js +0 -6
  349. package/distribution/contracts/p2p/enums.js.map +0 -1
  350. package/distribution/contracts/p2p/header-service.js +0 -2
  351. package/distribution/contracts/p2p/header-service.js.map +0 -1
  352. package/distribution/contracts/p2p/header.js +0 -2
  353. package/distribution/contracts/p2p/header.js.map +0 -1
  354. package/distribution/contracts/p2p/index.js +0 -26
  355. package/distribution/contracts/p2p/index.js.map +0 -1
  356. package/distribution/contracts/p2p/log.js +0 -2
  357. package/distribution/contracts/p2p/log.js.map +0 -1
  358. package/distribution/contracts/p2p/nes.js +0 -2
  359. package/distribution/contracts/p2p/nes.js.map +0 -1
  360. package/distribution/contracts/p2p/peer-communicator.js +0 -2
  361. package/distribution/contracts/p2p/peer-communicator.js.map +0 -1
  362. package/distribution/contracts/p2p/peer-connector.js +0 -2
  363. package/distribution/contracts/p2p/peer-connector.js.map +0 -1
  364. package/distribution/contracts/p2p/peer-discoverer.js +0 -2
  365. package/distribution/contracts/p2p/peer-discoverer.js.map +0 -1
  366. package/distribution/contracts/p2p/peer-disposer.js +0 -2
  367. package/distribution/contracts/p2p/peer-disposer.js.map +0 -1
  368. package/distribution/contracts/p2p/peer-processor.js +0 -2
  369. package/distribution/contracts/p2p/peer-processor.js.map +0 -1
  370. package/distribution/contracts/p2p/peer-repository.js +0 -2
  371. package/distribution/contracts/p2p/peer-repository.js.map +0 -1
  372. package/distribution/contracts/p2p/peer-verifier.js +0 -2
  373. package/distribution/contracts/p2p/peer-verifier.js.map +0 -1
  374. package/distribution/contracts/p2p/peer.js +0 -2
  375. package/distribution/contracts/p2p/peer.js.map +0 -1
  376. package/distribution/contracts/p2p/server.js +0 -2
  377. package/distribution/contracts/p2p/server.js.map +0 -1
  378. package/distribution/contracts/p2p/service.js +0 -2
  379. package/distribution/contracts/p2p/service.js.map +0 -1
  380. package/distribution/contracts/p2p/state.js +0 -2
  381. package/distribution/contracts/p2p/state.js.map +0 -1
  382. package/distribution/contracts/p2p/tx-pool-node.js +0 -2
  383. package/distribution/contracts/p2p/tx-pool-node.js.map +0 -1
  384. package/distribution/contracts/processor.d.ts +0 -33
  385. package/distribution/contracts/processor.d.ts.map +0 -1
  386. package/distribution/contracts/processor.js +0 -2
  387. package/distribution/contracts/processor.js.map +0 -1
  388. package/distribution/contracts/proposer.d.ts +0 -5
  389. package/distribution/contracts/proposer.d.ts.map +0 -1
  390. package/distribution/contracts/proposer.js +0 -2
  391. package/distribution/contracts/proposer.js.map +0 -1
  392. package/distribution/contracts/serializer.js +0 -2
  393. package/distribution/contracts/serializer.js.map +0 -1
  394. package/distribution/contracts/shared/dynamic-fee.js +0 -2
  395. package/distribution/contracts/shared/dynamic-fee.js.map +0 -1
  396. package/distribution/contracts/shared/index.js +0 -3
  397. package/distribution/contracts/shared/index.js.map +0 -1
  398. package/distribution/contracts/shared/rounds.js +0 -2
  399. package/distribution/contracts/shared/rounds.js.map +0 -1
  400. package/distribution/contracts/state/index.js +0 -4
  401. package/distribution/contracts/state/index.js.map +0 -1
  402. package/distribution/contracts/state/state.js +0 -2
  403. package/distribution/contracts/state/state.js.map +0 -1
  404. package/distribution/contracts/state/store.js +0 -2
  405. package/distribution/contracts/state/store.js.map +0 -1
  406. package/distribution/contracts/state/wallets.js +0 -2
  407. package/distribution/contracts/state/wallets.js.map +0 -1
  408. package/distribution/contracts/transaction-pool/broadcaster.js +0 -6
  409. package/distribution/contracts/transaction-pool/broadcaster.js.map +0 -1
  410. package/distribution/contracts/transaction-pool/client.js +0 -2
  411. package/distribution/contracts/transaction-pool/client.js.map +0 -1
  412. package/distribution/contracts/transaction-pool/dynamic-fee-matcher.d.ts +0 -6
  413. package/distribution/contracts/transaction-pool/dynamic-fee-matcher.d.ts.map +0 -1
  414. package/distribution/contracts/transaction-pool/dynamic-fee-matcher.js +0 -2
  415. package/distribution/contracts/transaction-pool/dynamic-fee-matcher.js.map +0 -1
  416. package/distribution/contracts/transaction-pool/expiration-service.d.ts +0 -7
  417. package/distribution/contracts/transaction-pool/expiration-service.d.ts.map +0 -1
  418. package/distribution/contracts/transaction-pool/expiration-service.js +0 -2
  419. package/distribution/contracts/transaction-pool/expiration-service.js.map +0 -1
  420. package/distribution/contracts/transaction-pool/index.js +0 -13
  421. package/distribution/contracts/transaction-pool/index.js.map +0 -1
  422. package/distribution/contracts/transaction-pool/mempool.js +0 -2
  423. package/distribution/contracts/transaction-pool/mempool.js.map +0 -1
  424. package/distribution/contracts/transaction-pool/processor.js +0 -2
  425. package/distribution/contracts/transaction-pool/processor.js.map +0 -1
  426. package/distribution/contracts/transaction-pool/query.js +0 -2
  427. package/distribution/contracts/transaction-pool/query.js.map +0 -1
  428. package/distribution/contracts/transaction-pool/sender-mempool.js +0 -2
  429. package/distribution/contracts/transaction-pool/sender-mempool.js.map +0 -1
  430. package/distribution/contracts/transaction-pool/sender-state.js +0 -2
  431. package/distribution/contracts/transaction-pool/sender-state.js.map +0 -1
  432. package/distribution/contracts/transaction-pool/service.js +0 -2
  433. package/distribution/contracts/transaction-pool/service.js.map +0 -1
  434. package/distribution/contracts/transaction-pool/storage.js +0 -2
  435. package/distribution/contracts/transaction-pool/storage.js.map +0 -1
  436. package/distribution/contracts/transaction-pool/worker.js +0 -2
  437. package/distribution/contracts/transaction-pool/worker.js.map +0 -1
  438. package/distribution/contracts/transactions.js +0 -2
  439. package/distribution/contracts/transactions.js.map +0 -1
  440. package/distribution/contracts/types/container.d.ts +0 -4
  441. package/distribution/contracts/types/container.d.ts.map +0 -1
  442. package/distribution/contracts/types/container.js +0 -2
  443. package/distribution/contracts/types/container.js.map +0 -1
  444. package/distribution/contracts/types/index.js +0 -2
  445. package/distribution/contracts/types/index.js.map +0 -1
  446. package/distribution/contracts/validator-set.js +0 -2
  447. package/distribution/contracts/validator-set.js.map +0 -1
  448. package/distribution/contracts/validator.js +0 -2
  449. package/distribution/contracts/validator.js.map +0 -1
  450. package/distribution/contracts/webhooks.js +0 -2
  451. package/distribution/contracts/webhooks.js.map +0 -1
  452. package/distribution/events.d.ts +0 -85
  453. package/distribution/events.d.ts.map +0 -1
  454. package/distribution/events.js +0 -100
  455. package/distribution/events.js.map +0 -1
  456. package/distribution/exceptions/base.d.ts +0 -4
  457. package/distribution/exceptions/base.d.ts.map +0 -1
  458. package/distribution/exceptions/base.js +0 -15
  459. package/distribution/exceptions/base.js.map +0 -1
  460. package/distribution/exceptions/cli.d.ts +0 -8
  461. package/distribution/exceptions/cli.d.ts.map +0 -1
  462. package/distribution/exceptions/cli.js +0 -12
  463. package/distribution/exceptions/cli.js.map +0 -1
  464. package/distribution/exceptions/config.d.ts +0 -19
  465. package/distribution/exceptions/config.d.ts.map +0 -1
  466. package/distribution/exceptions/config.js +0 -25
  467. package/distribution/exceptions/config.js.map +0 -1
  468. package/distribution/exceptions/consensus.d.ts +0 -5
  469. package/distribution/exceptions/consensus.d.ts.map +0 -1
  470. package/distribution/exceptions/consensus.js +0 -7
  471. package/distribution/exceptions/consensus.js.map +0 -1
  472. package/distribution/exceptions/container.d.ts +0 -18
  473. package/distribution/exceptions/container.d.ts.map +0 -1
  474. package/distribution/exceptions/container.js +0 -22
  475. package/distribution/exceptions/container.js.map +0 -1
  476. package/distribution/exceptions/crypto.d.ts +0 -202
  477. package/distribution/exceptions/crypto.d.ts.map +0 -1
  478. package/distribution/exceptions/crypto.js +0 -335
  479. package/distribution/exceptions/crypto.js.map +0 -1
  480. package/distribution/exceptions/filesystem.d.ts +0 -12
  481. package/distribution/exceptions/filesystem.d.ts.map +0 -1
  482. package/distribution/exceptions/filesystem.js +0 -16
  483. package/distribution/exceptions/filesystem.js.map +0 -1
  484. package/distribution/exceptions/index.d.ts +0 -17
  485. package/distribution/exceptions/index.d.ts.map +0 -1
  486. package/distribution/exceptions/index.js +0 -17
  487. package/distribution/exceptions/index.js.map +0 -1
  488. package/distribution/exceptions/logic.d.ts +0 -28
  489. package/distribution/exceptions/logic.d.ts.map +0 -1
  490. package/distribution/exceptions/logic.js +0 -36
  491. package/distribution/exceptions/logic.js.map +0 -1
  492. package/distribution/exceptions/p2p.d.ts +0 -24
  493. package/distribution/exceptions/p2p.d.ts.map +0 -1
  494. package/distribution/exceptions/p2p.js +0 -37
  495. package/distribution/exceptions/p2p.js.map +0 -1
  496. package/distribution/exceptions/plugins.d.ts +0 -27
  497. package/distribution/exceptions/plugins.d.ts.map +0 -1
  498. package/distribution/exceptions/plugins.js +0 -43
  499. package/distribution/exceptions/plugins.js.map +0 -1
  500. package/distribution/exceptions/pool.d.ts +0 -50
  501. package/distribution/exceptions/pool.d.ts.map +0 -1
  502. package/distribution/exceptions/pool.js +0 -74
  503. package/distribution/exceptions/pool.js.map +0 -1
  504. package/distribution/exceptions/processor.d.ts +0 -26
  505. package/distribution/exceptions/processor.d.ts.map +0 -1
  506. package/distribution/exceptions/processor.js +0 -39
  507. package/distribution/exceptions/processor.js.map +0 -1
  508. package/distribution/exceptions/rpc.d.ts +0 -6
  509. package/distribution/exceptions/rpc.d.ts.map +0 -1
  510. package/distribution/exceptions/rpc.js +0 -8
  511. package/distribution/exceptions/rpc.js.map +0 -1
  512. package/distribution/exceptions/runtime.d.ts +0 -9
  513. package/distribution/exceptions/runtime.d.ts.map +0 -1
  514. package/distribution/exceptions/runtime.js +0 -11
  515. package/distribution/exceptions/runtime.js.map +0 -1
  516. package/distribution/exceptions/state.d.ts +0 -8
  517. package/distribution/exceptions/state.d.ts.map +0 -1
  518. package/distribution/exceptions/state.js +0 -12
  519. package/distribution/exceptions/state.js.map +0 -1
  520. package/distribution/exceptions/validation.d.ts +0 -5
  521. package/distribution/exceptions/validation.d.ts.map +0 -1
  522. package/distribution/exceptions/validation.js +0 -7
  523. package/distribution/exceptions/validation.js.map +0 -1
  524. package/distribution/identifiers.d.ts +0 -298
  525. package/distribution/identifiers.d.ts.map +0 -1
  526. package/distribution/identifiers.js +0 -298
  527. package/distribution/identifiers.js.map +0 -1
  528. package/distribution/index.js +0 -8
  529. package/distribution/index.js.map +0 -1
  530. package/distribution/utils.d.ts.map +0 -1
  531. package/distribution/utils.js +0 -2
  532. package/distribution/utils.js.map +0 -1
@@ -1,13 +1,6 @@
1
- export interface Logger {
2
- emergency(message: any): void;
3
- alert(message: any): void;
4
- critical(message: any): void;
5
- error(message: any): void;
6
- warning(message: any): void;
7
- warningExtra(message: any): void;
8
- notice(message: any): void;
9
- info(message: any): void;
10
- debug(message: any): void;
11
- debugExtra(message: any): void;
1
+ import type { Logger as MainLogger, LoggerContext } from "../kernel/index.js";
2
+ export interface Logger extends Omit<MainLogger, "dispose" | "suppressConsoleOutput"> {
3
+ warnExtra(message: string, context?: LoggerContext): void;
4
+ debugExtra(message: string, context?: LoggerContext): void;
12
5
  }
13
6
  //# sourceMappingURL=log.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"log.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/log.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACtB,SAAS,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE9B,KAAK,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE1B,QAAQ,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE7B,KAAK,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE1B,OAAO,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE5B,YAAY,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAEjC,MAAM,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE3B,IAAI,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAEzB,KAAK,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;IAE1B,UAAU,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,CAAC;CAC/B"}
1
+ {"version":3,"file":"log.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/log.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,IAAI,UAAU,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAE9E,MAAM,WAAW,MAAO,SAAQ,IAAI,CAAC,UAAU,EAAE,SAAS,GAAG,uBAAuB,CAAC;IACpF,SAAS,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;IAC1D,UAAU,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,aAAa,GAAG,IAAI,CAAC;CAC3D"}
@@ -1,7 +1,7 @@
1
1
  export interface Client {
2
- connect(options: any): Promise<any>;
3
- disconnect(): Promise<any>;
4
- request(options: any): Promise<any>;
2
+ connect(options: Record<string, unknown>): Promise<void>;
3
+ disconnect(): Promise<void>;
4
+ request(options: Record<string, unknown>): Promise<void>;
5
5
  }
6
6
  export interface Socket {
7
7
  info: {
@@ -1 +1 @@
1
- {"version":3,"file":"nes.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/nes.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACtB,OAAO,CAAC,OAAO,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;IACpC,UAAU,IAAI,OAAO,CAAC,GAAG,CAAC,CAAC;IAC3B,OAAO,CAAC,OAAO,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;CACpC;AAED,MAAM,WAAW,MAAM;IACtB,IAAI,EAAE;QACL,iBAAiB,CAAC,EAAE,MAAM,CAAC;QAC3B,aAAa,EAAE,MAAM,CAAC;KACtB,CAAC;CACF;AAED,MAAM,MAAM,QAAQ,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG,KAAK,CAAC"}
1
+ {"version":3,"file":"nes.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/nes.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACtB,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACzD,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAC5B,OAAO,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACzD;AAED,MAAM,WAAW,MAAM;IACtB,IAAI,EAAE;QACL,iBAAiB,CAAC,EAAE,MAAM,CAAC;QAC3B,aAAa,EAAE,MAAM,CAAC;KACtB,CAAC;CACF;AAED,MAAM,MAAM,QAAQ,GAAG;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG,KAAK,CAAC"}
@@ -1,20 +1,18 @@
1
- /// <reference types="node" resolution-mode="require"/>
2
- import { GetApiNodesResponse, GetBlocksResponse, GetMessagesResponse, GetPeersResponse, GetProposalResponse, GetStatusResponse } from "./endpoints.js";
3
- import { Peer } from "./peer.js";
1
+ import type { GetApiNodesResponse, GetBlocksResponse, GetMessagesResponse, GetPeersResponse, GetProposalResponse, GetStatusResponse } from "./endpoints.js";
2
+ import type { Peer } from "./peer.js";
4
3
  export type EmitOptions = {
5
4
  timeout: number;
6
5
  };
7
6
  export interface PeerCommunicator {
8
7
  postProposal(peer: Peer, proposal: Buffer): Promise<void>;
9
- postPrevote(peer: Peer, prevote: Buffer): Promise<void>;
10
- postPrecommit(peer: Peer, prevote: Buffer): Promise<void>;
8
+ postMessage(peer: Peer, message: Buffer): Promise<void>;
11
9
  pingPorts(peer: Peer): Promise<void>;
12
10
  getPeers(peer: Peer): Promise<GetPeersResponse>;
13
11
  getApiNodes(peer: Peer): Promise<GetApiNodesResponse>;
14
12
  getMessages(peer: Peer): Promise<GetMessagesResponse>;
15
13
  getProposal(peer: Peer): Promise<GetProposalResponse>;
16
- getBlocks(peer: Peer, { fromHeight, limit }: {
17
- fromHeight: number;
14
+ getBlocks(peer: Peer, { fromBlockNumber, limit }: {
15
+ fromBlockNumber: number;
18
16
  limit?: number;
19
17
  }, options?: Partial<EmitOptions>): Promise<GetBlocksResponse>;
20
18
  getStatus(peer: Peer, options?: Partial<EmitOptions>): Promise<GetStatusResponse>;
@@ -1 +1 @@
1
- {"version":3,"file":"peer-communicator.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-communicator.ts"],"names":[],"mappings":";AAAA,OAAO,EACN,mBAAmB,EACnB,iBAAiB,EACjB,mBAAmB,EACnB,gBAAgB,EAChB,mBAAmB,EACnB,iBAAiB,EACjB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,MAAM,MAAM,WAAW,GAAG;IACzB,OAAO,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,MAAM,WAAW,gBAAgB;IAChC,YAAY,CAAC,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,WAAW,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACxD,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE1D,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErC,QAAQ,CAAC,IAAI,EAAE,IAA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IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAErC,QAAQ,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAChD,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;IACtD,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;IACtD,WAAW,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;IACtD,SAAS,CACR,IAAI,EAAE,IAAI,EACV,EAAE,eAAe,EAAE,KAAK,EAAE,EAAE;QAAE,eAAe,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,EACvE,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAC5B,OAAO,CAAC,iBAAiB,CAAC,CAAC;IAC9B,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;CAClF"}
@@ -1,8 +1,10 @@
1
- import { Client } from "./nes.js";
2
- import { Peer } from "./peer.js";
1
+ import type { Client } from "./nes.js";
2
+ import type { Peer } from "./peer.js";
3
3
  export interface PeerConnector {
4
4
  connect(peer: Peer): Promise<Client>;
5
5
  disconnect(ip: string): Promise<void>;
6
- emit(peer: Peer, event: string, payload: any, timeout?: number): Promise<any>;
6
+ emit(peer: Peer, event: string, payload: Buffer, timeout?: number): Promise<{
7
+ payload: Buffer;
8
+ }>;
7
9
  }
8
10
  //# sourceMappingURL=peer-connector.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"peer-connector.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-connector.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,MAAM,WAAW,aAAa;IAC7B,OAAO,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IACrC,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEtC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;CAC9E"}
1
+ {"version":3,"file":"peer-connector.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-connector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,WAAW,aAAa;IAC7B,OAAO,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IACrC,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEtC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACjG"}
@@ -1,4 +1,4 @@
1
- import { Peer } from "./peer.js";
1
+ import type { Peer } from "./peer.js";
2
2
  export interface PeerDiscoverer {
3
3
  discoverPeers(peer: Peer): Promise<void>;
4
4
  populateSeedPeers(): Promise<void>;
@@ -1 +1 @@
1
- {"version":3,"file":"peer-discoverer.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-discoverer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,MAAM,WAAW,cAAc;IAC9B,aAAa,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACzC,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACnC"}
1
+ {"version":3,"file":"peer-discoverer.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-discoverer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,WAAW,cAAc;IAC9B,aAAa,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACzC,iBAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACnC"}
@@ -1,4 +1,4 @@
1
- import { NesError } from "./nes.js";
1
+ import type { NesError } from "./nes.js";
2
2
  export interface PeerDisposer {
3
3
  banPeer(ip: string, error: Error | NesError): void;
4
4
  disposePeer(ip: string): void;
@@ -1 +1 @@
1
- {"version":3,"file":"peer-disposer.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-disposer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEpC,MAAM,WAAW,YAAY;IAC5B,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnD,WAAW,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9B,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAC9B,WAAW,IAAI;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CACjD"}
1
+ {"version":3,"file":"peer-disposer.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-disposer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,WAAW,YAAY;IAC5B,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnD,WAAW,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9B,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAC9B,WAAW,IAAI;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CACjD"}
@@ -1,10 +1,11 @@
1
+ import type { Peer } from "./peer.js";
1
2
  export interface AcceptNewPeerOptions {
2
3
  seed?: boolean;
3
4
  }
4
5
  export interface PeerProcessor {
5
- initialize(): any;
6
+ initialize(): void;
6
7
  validateAndAcceptPeer(ip: string, options?: AcceptNewPeerOptions): Promise<void>;
7
- validatePeerIp(peer: any, options?: AcceptNewPeerOptions): boolean;
8
- isWhitelisted(peer: any): boolean;
8
+ validatePeerIp(ip: string, options?: AcceptNewPeerOptions): boolean;
9
+ isWhitelisted(peer: Peer): boolean;
9
10
  }
10
11
  //# sourceMappingURL=peer-processor.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"peer-processor.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-processor.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,oBAAoB;IACpC,IAAI,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,aAAa;IAC7B,UAAU,QAAG;IAEb,qBAAqB,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,oBAAoB,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjF,cAAc,CAAC,IAAI,KAAA,EAAE,OAAO,CAAC,EAAE,oBAAoB,GAAG,OAAO,CAAC;IAE9D,aAAa,CAAC,IAAI,KAAA,GAAG,OAAO,CAAC;CAC7B"}
1
+ {"version":3,"file":"peer-processor.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-processor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,WAAW,oBAAoB;IACpC,IAAI,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,aAAa;IAC7B,UAAU,IAAI,IAAI,CAAC;IAEnB,qBAAqB,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,oBAAoB,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjF,cAAc,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,oBAAoB,GAAG,OAAO,CAAC;IAEpE,aAAa,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC;CACnC"}
@@ -1,4 +1,4 @@
1
- import { Peer } from "./peer.js";
1
+ import type { Peer } from "./peer.js";
2
2
  export interface PeerRepository {
3
3
  getPeers(): Peer[];
4
4
  hasPeers(): boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"peer-repository.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-repository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,MAAM,WAAW,cAAc;IAC9B,QAAQ,IAAI,IAAI,EAAE,CAAC;IACnB,QAAQ,IAAI,OAAO,CAAC;IAEpB,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,UAAU,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAC7B,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAE7B,eAAe,IAAI,IAAI,EAAE,CAAC;IAC1B,eAAe,IAAI,OAAO,CAAC;IAE3B,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,cAAc,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IACjC,iBAAiB,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IACpC,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAEpC,eAAe,IAAI,OAAO,CAAC;IAE3B,kBAAkB,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,EAAE,CAAC;CACvC"}
1
+ {"version":3,"file":"peer-repository.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-repository.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,WAAW,cAAc;IAC9B,QAAQ,IAAI,IAAI,EAAE,CAAC;IACnB,QAAQ,IAAI,OAAO,CAAC;IAEpB,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,OAAO,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAC1B,UAAU,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IAC7B,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAE7B,eAAe,IAAI,IAAI,EAAE,CAAC;IAC1B,eAAe,IAAI,OAAO,CAAC;IAE3B,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,cAAc,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IACjC,iBAAiB,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;IACpC,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;IAEpC,eAAe,IAAI,OAAO,CAAC;IAE3B,kBAAkB,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI,EAAE,CAAC;CACvC"}
@@ -1,4 +1,4 @@
1
- import { Peer } from "./peer.js";
1
+ import type { Peer } from "./peer.js";
2
2
  export interface PeerVerifier {
3
3
  verify(peer: Peer): Promise<boolean>;
4
4
  }
@@ -1 +1 @@
1
- {"version":3,"file":"peer-verifier.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-verifier.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,MAAM,WAAW,YAAY;IAC5B,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CACrC"}
1
+ {"version":3,"file":"peer-verifier.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer-verifier.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,WAAW,YAAY;IAC5B,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CACrC"}
@@ -1,8 +1,7 @@
1
- import { Dayjs } from "dayjs";
2
- import { Queue } from "../kernel/queue.js";
3
- import { ApiNode } from "./api-node.js";
4
- import { PeerProtocol } from "./enums.js";
5
- import { HeaderData } from "./header.js";
1
+ import type { Queue } from "../kernel/queue.js";
2
+ import type { ApiNode } from "./api-node.js";
3
+ import type { PeerProtocol } from "./enums.js";
4
+ import type { HeaderData } from "./header.js";
6
5
  export interface PeerPorts {
7
6
  [name: string]: number;
8
7
  }
@@ -19,14 +18,14 @@ export interface Peer {
19
18
  readonly protocol: PeerProtocol;
20
19
  readonly ip: string;
21
20
  readonly ports: PeerPorts;
21
+ readonly lastPinged: number | undefined;
22
22
  version: string | undefined;
23
- latency: number | undefined;
23
+ readonly latency: number | undefined;
24
24
  header: HeaderData;
25
25
  plugins: PeerPlugins;
26
- lastPinged: Dayjs | undefined;
27
26
  sequentialErrorCounter: number;
28
27
  apiNodes: ApiNode[];
29
- recentlyPinged(): boolean;
28
+ setPinged(latency: number): void;
30
29
  toBroadcast(): PeerBroadcast;
31
30
  getTransactionsQueue(): Promise<Queue>;
32
31
  dispose(): void;
@@ -37,8 +36,8 @@ export interface PeerBroadcast {
37
36
  protocol: PeerProtocol;
38
37
  }
39
38
  export interface PeerState {
40
- height: number;
41
- id: string;
39
+ blockNumber: number;
40
+ blockHash: string;
42
41
  }
43
42
  export interface PeerData {
44
43
  ip: string;
@@ -63,9 +62,9 @@ export interface PeerPingResponse {
63
62
  config: PeerConfig;
64
63
  }
65
64
  export interface PeerVerificationResult {
66
- readonly myHeight: number;
67
- readonly hisHeight: number;
68
- readonly highestCommonHeight: number;
65
+ readonly myBlockNumber: number;
66
+ readonly hisBlockNumber: number;
67
+ readonly highestCommonBlockNumber: number;
69
68
  }
70
69
  export type PeerFactory = (ip: string) => Peer;
71
70
  //# sourceMappingURL=peer.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"peer.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/peer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAE9B,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,MAAM,WAAW,SAAS;IACzB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,WAAW;IAC3B,CAAC,IAAI,EAAE,MAAM,GAAG;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,kBAAkB,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;CACjF;AAED,MAAM,WAAW,IAAI;IACpB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,YAAY,CAAC;IAEhC,QAAQ,CAAC,EAAE,E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ServerRoute } from "@hapi/hapi";
1
+ import type { Plugin, Request, ResponseToolkit, Server as HapiServer, ServerInjectOptions, ServerInjectResponse, ServerRoute } from "@hapi/hapi";
2
+ import type { Schema } from "joi";
3
+ import type { Response } from "./endpoints.js";
2
4
  export interface Controller {
3
- handle(request: Request, h: ResponseToolkit): Promise<any>;
5
+ handle(request: Request, h: ResponseToolkit): Promise<Response>;
4
6
  }
5
7
  export interface Server {
6
8
  initialize(name: string, optionsServer: {
@@ -9,8 +11,30 @@ export interface Server {
9
11
  }): Promise<void>;
10
12
  boot(): Promise<void>;
11
13
  dispose(): Promise<void>;
12
- register(plugins: any): Promise<void>;
14
+ register(plugins: Plugin<unknown, unknown>): Promise<void>;
13
15
  route(routes: ServerRoute | ServerRoute[]): Promise<void>;
14
16
  inject(options: string | ServerInjectOptions): Promise<ServerInjectResponse>;
15
17
  }
18
+ export type Codec = {
19
+ request: {
20
+ serialize: (object: object) => Buffer;
21
+ deserialize: (payload: Buffer) => object;
22
+ };
23
+ response: {
24
+ serialize: (object: object) => Buffer;
25
+ deserialize: (payload: Buffer) => object;
26
+ };
27
+ };
28
+ export type RouteConfig = {
29
+ id: string;
30
+ validation?: Schema;
31
+ codec: Codec;
32
+ maxBytes?: number;
33
+ };
34
+ export interface Route {
35
+ register(server: HapiServer): void;
36
+ getRoutesConfigByPath(): {
37
+ [path: string]: RouteConfig;
38
+ };
39
+ }
16
40
  //# sourceMappingURL=server.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9G,MAAM,WAAW,UAAU;IAC1B,MAAM,CAAC,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;CAC3D;AAED,MAAM,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I,OAAO,CAAC,IAAI,CAAC,CAAC;IACzB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC3D,KAAK,CAAC,MAAM,EAAE,WAAW,GAAG,WAAW,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,MAAM,CAAC,OAAO,EAAE,MAAM,GAAG,mBAAmB,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;CAC7E;AAED,MAAM,MAAM,KAAK,GAAG;IACnB,OAAO,EAAE;QACR,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,CAAC;QACtC,WAAW,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,CAAC;KACzC,CAAC;IACF,QAAQ,EAAE;QACT,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,MAAM,CAAC;QACtC,WAAW,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,MAAM,CAAC;KACzC,CAAC;CACF,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,WAAW,KAAK;IACrB,QAAQ,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI,CAAC;IACnC,qBAAqB,IAAI;QAAE,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,CAAA;KAAE,CAAC;CACzD"}
@@ -1,6 +1,6 @@
1
1
  export interface Service {
2
2
  boot(): Promise<void>;
3
3
  dispose(): Promise<void>;
4
- getNetworkHeight(): number;
4
+ getNetworkBlockNumberPercentile(p: number): number;
5
5
  }
6
6
  //# sourceMappingURL=service.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/service.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACvB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACtB,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACzB,gBAAgB,IAAI,MAAM,CAAC;CAC3B"}
1
+ {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/service.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACvB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACtB,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACzB,+BAA+B,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;CACnD"}
@@ -1,4 +1,4 @@
1
- import { Dayjs } from "dayjs";
1
+ import type { Dayjs } from "dayjs";
2
2
  export interface State {
3
3
  resetLastMessageTime(): void;
4
4
  getLastMessageTime(): Dayjs;
@@ -1 +1 @@
1
- {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAE9B,MAAM,WAAW,KAAK;IACrB,oBAAoB,IAAI,IAAI,CAAC;IAC7B,kBAAkB,IAAI,KAAK,CAAC;CAC5B"}
1
+ {"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../source/contracts/p2p/state.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAEnC,MAAM,WAAW,KAAK;IACrB,oBAAoB,IAAI,IAAI,CAAC;IAC7B,kBAAkB,IAAI,KAAK,CAAC;CAC5B"}
@@ -0,0 +1,85 @@
1
+ export interface StatisticService {
2
+ boot(): void;
3
+ newRound(height: number, round: number): void;
4
+ getCurrentRoundStatistic(): RoundStatistic;
5
+ getRoundStatisticList(): string[];
6
+ getRoundStatistic(id: string): RoundStatistic | undefined;
7
+ }
8
+ export interface RoundStatistic {
9
+ height: number;
10
+ round: number;
11
+ start(): void;
12
+ stop(): void;
13
+ addEmit(ip: string, endpoint: string, emitStatistic: EmitStatistic): void;
14
+ addPing(ip: string, endpoint: string, pingStatistic: PingStatistic): void;
15
+ peerAdded(ip: string): void;
16
+ peerRemoved(ip: string): void;
17
+ peerBanned(ip: string): void;
18
+ getGeneralStatistic(): GeneralStatistic;
19
+ getEmitStatistics(): EndpointStatistic[];
20
+ getPingStatistics(): EndpointStatistic[];
21
+ getPeerStatistics(): PeerStatistic[];
22
+ }
23
+ export interface StatisticLogger {
24
+ log(roundStatistic: RoundStatistic): void;
25
+ }
26
+ export interface EmitStatistic {
27
+ deserializeTime: number;
28
+ responseTime: number;
29
+ throttleTime: number;
30
+ success: boolean;
31
+ }
32
+ export interface PingStatistic {
33
+ responseTime: number;
34
+ success: boolean;
35
+ }
36
+ export type GeneralStatistic = {
37
+ duration: number;
38
+ count: {
39
+ peersTotal: number;
40
+ peersBanned: number;
41
+ peersRound: number;
42
+ emitsSuccess: number;
43
+ emitsFailed: number;
44
+ pingsSuccess: number;
45
+ pingsFailed: number;
46
+ };
47
+ response: {
48
+ average: number;
49
+ };
50
+ peers: {
51
+ added: string[];
52
+ removed: string[];
53
+ banned: string[];
54
+ };
55
+ };
56
+ export type EndpointStatistic = {
57
+ endpoint: string;
58
+ count: {
59
+ success: number;
60
+ emits: number;
61
+ peers: number;
62
+ };
63
+ response: {
64
+ average: number;
65
+ max: number[];
66
+ min: number[];
67
+ };
68
+ };
69
+ export type PeerSectionStatistic = {
70
+ count: number;
71
+ success: number;
72
+ average: number;
73
+ max: number[];
74
+ min: number[];
75
+ endpoints: {
76
+ name: string;
77
+ responseTimes: number[];
78
+ }[];
79
+ };
80
+ export type PeerStatistic = {
81
+ ip: string;
82
+ emits: PeerSectionStatistic;
83
+ pings: PeerSectionStatistic;
84
+ };
85
+ //# sourceMappingURL=statistic.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"statistic.d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AC;CACJ,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,oBAAoB,CAAC;IAC5B,KAAK,EAAE,oBAAoB,CAAC;CAC5B,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { TransactionReceipt } from "../evm/evm.js";
2
+ export interface BlockProcessorResult {
3
+ success: boolean;
4
+ receipts: Map<string, TransactionReceipt>;
5
+ gasUsed: number;
6
+ feeUsed: bigint;
7
+ }
8
+ //# sourceMappingURL=block-processor-result.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block-processor-result.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/block-processor-result.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAExD,MAAM,WAAW,oBAAoB;IACpC,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAAC;IAC1C,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CAChB"}
@@ -0,0 +1,7 @@
1
+ import type { BlockProcessorResult } from "./block-processor-result.js";
2
+ import type { ProcessableUnit } from "./processable-unit.js";
3
+ export interface BlockProcessor {
4
+ process(unit: ProcessableUnit): Promise<BlockProcessorResult>;
5
+ commit(unit: ProcessableUnit): Promise<void>;
6
+ }
7
+ //# sourceMappingURL=block-processor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block-processor.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/block-processor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,cAAc;IAC9B,OAAO,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;IAC9D,MAAM,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7C"}
@@ -0,0 +1,5 @@
1
+ import type { ProcessableUnit } from "./processable-unit.js";
2
+ export interface Handler {
3
+ execute(unit: ProcessableUnit): Promise<void>;
4
+ }
5
+ //# sourceMappingURL=handler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,OAAO;IACvB,OAAO,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC9C"}
@@ -0,0 +1,7 @@
1
+ export * from "./block-processor-result.js";
2
+ export * from "./block-processor.js";
3
+ export * from "./handler.js";
4
+ export * from "./processable-unit.js";
5
+ export * from "./transaction-processor.js";
6
+ export * from "./verifier.js";
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC;AAC5C,cAAc,sBAAsB,CAAC;AACrC,cAAc,cAAc,CAAC;AAC7B,cAAc,uBAAuB,CAAC;AACtC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,eAAe,CAAC"}
@@ -0,0 +1,16 @@
1
+ import type { Block } from "../crypto/block.js";
2
+ import type { Commit } from "../crypto/commit.js";
3
+ import type { AccountUpdate } from "../evm/evm.js";
4
+ import type { BlockProcessorResult } from "./block-processor-result.js";
5
+ export interface ProcessableUnit {
6
+ readonly blockNumber: number;
7
+ readonly round: number;
8
+ hasProcessorResult(): boolean;
9
+ getProcessorResult(): BlockProcessorResult;
10
+ setProcessorResult(processorResult: BlockProcessorResult): void;
11
+ setAccountUpdates(accounts: Array<AccountUpdate>): void;
12
+ getAccountUpdates(): Array<AccountUpdate>;
13
+ getBlock(): Block;
14
+ getCommit(): Promise<Commit>;
15
+ }
16
+ //# sourceMappingURL=processable-unit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"processable-unit.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/processable-unit.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAExE,MAAM,WAAW,eAAe;IAC/B,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,kBAAkB,IAAI,OAAO,CAAC;IAC9B,kBAAkB,IAAI,oBAAoB,CAAC;IAC3C,kBAAkB,CAAC,eAAe,EAAE,oBAAoB,GAAG,IAAI,CAAC;IAChE,iBAAiB,CAAC,QAAQ,EAAE,KAAK,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC;IACxD,iBAAiB,IAAI,KAAK,CAAC,aAAa,CAAC,CAAC;IAC1C,QAAQ,IAAI,KAAK,CAAC;IAClB,SAAS,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;CAC7B"}
@@ -0,0 +1,7 @@
1
+ import type { Transaction } from "../crypto/index.js";
2
+ import type { TransactionReceipt } from "../evm/index.js";
3
+ import type { ProcessableUnit } from "./processable-unit.js";
4
+ export interface TransactionProcessor {
5
+ process(unit: ProcessableUnit, transaction: Transaction): Promise<TransactionReceipt>;
6
+ }
7
+ //# sourceMappingURL=transaction-processor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transaction-processor.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/transaction-processor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAC1D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,oBAAoB;IACpC,OAAO,CAAC,IAAI,EAAE,eAAe,EAAE,WAAW,EAAE,WAAW,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAC;CACtF"}
@@ -0,0 +1,5 @@
1
+ import type { ProcessableUnit } from "./processable-unit.js";
2
+ export interface Verifier {
3
+ verify(unit: ProcessableUnit): Promise<void>;
4
+ }
5
+ //# sourceMappingURL=verifier.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verifier.d.ts","sourceRoot":"","sources":["../../../source/contracts/processor/verifier.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE7D,MAAM,WAAW,QAAQ;IACxB,MAAM,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7C"}
@@ -1,7 +1,6 @@
1
- /// <reference types="node" resolution-mode="require"/>
2
- import { ByteBuffer } from "@mainsail/utils";
3
- export type MandatoryPropertyType = "hash" | "publicKey" | "hex" | "signature" | "transactions" | "consensusSignature" | "validatorSet";
4
- export type OptionalPropertyType = "uint8" | "uint16" | "uint32" | "uint48" | "uint64" | "uint256" | "address" | "bigint" | "blockId";
1
+ import type { ByteBuffer } from "@mainsail/utils";
2
+ export type MandatoryPropertyType = "hash" | "publicKey" | "hex" | "transactions" | "consensusSignature" | "validatorSet";
3
+ export type OptionalPropertyType = "uint8" | "uint16" | "uint32" | "uint48" | "uint64" | "uint256" | "address" | "bigint" | "blockHash";
5
4
  export type SerializationSchema = {
6
5
  type: MandatoryPropertyType;
7
6
  } | {
@@ -27,6 +26,6 @@ export interface DeserializationConfiguration {
27
26
  }
28
27
  export interface Serializer {
29
28
  serialize<T>(data: T, configuration: SerializationConfiguration): Promise<Buffer>;
30
- deserialize<T>(source: ByteBuffer, target: T, configuration: DeserializationConfiguration): Promise<T>;
29
+ deserialize<T>(source: ByteBuffer, target: Partial<T>, configuration: DeserializationConfiguration): Promise<T>;
31
30
  }
32
31
  //# sourceMappingURL=serializer.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"serializer.d.ts","sourceRoot":"","sources":["../../source/contracts/serializer.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,MAAM,MAAM,qBAAqB,GAC9B,MAAM,GACN,WAAW,GACX,KAAK,GACL,WAAW,GACX,cAAc,GACd,oBAAoB,GACpB,cAAc,CAAC;AAElB,MAAM,MAAM,oBAAoB,GAC7B,OAAO,GACP,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,SAAS,GACT,SAAS,GACT,QAAQ,GACR,SAAS,CAAC;AAEb,MAAM,MAAM,mBAAmB,GAAG;IAAE,IAAI,EAAE,qBAAqB,CAAA;CAAE,GAAG;IAAE,IAAI,EAAE,oBAAoB,CAAC;IAAC,QAAQ,CAAC,EAAE,IAAI,CAAA;CAAE,CAAC;AAEpH,MAAM,WAAW,0BAA0B;IAC1C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,mBAAmB,CAAC,CAAC;IAC5C,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CACb;AAED,MAAM,MAAM,qBAAqB,GAC9B;IAAE,IAAI,EAAE,qBAAqB,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,GAC9C;IAAE,IAAI,EAAE,oBAAoB,CAAC;IAAC,QAAQ,CAAC,EAAE,IAAI,CAAA;CAAE,CAAC;AAEnD,MAAM,WAAW,4BAA4B;IAC5C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;IAC9C,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C;AAEnD,MAAM,WAAW,4BAA4B;IAC5C,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC;IAC9C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,UAAU;IAC1B,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,aAAa,EAAE,0BAA0B,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAElF,WAAW,CAAC,CAAC,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,aAAa,EAAE,4BAA4B,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC;CAChH"}
@@ -1,4 +1,4 @@
1
- import { Transaction } from "../crypto/transactions.js";
1
+ import type { Transaction } from "../crypto/transactions.js";
2
2
  export interface DynamicFeeContext {
3
3
  transaction: Transaction;
4
4
  addonBytes: number;
@@ -1 +1 @@
1
- {"version":3,"file":"dynamic-fee.d.ts","sourceRoot":"","sources":["../../../source/contracts/shared/dynamic-fee.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAExD,MAAM,WAAW,iBAAiB;IACjC,WAAW,EAAE,WAAW,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;CACf"}
1
+ {"version":3,"file":"dynamic-fee.d.ts","sourceRoot":"","sources":["../../../source/contracts/shared/dynamic-fee.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAE7D,MAAM,WAAW,iBAAiB;IACjC,WAAW,EAAE,WAAW,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;CACf"}