@sentio/sdk 2.40.0-rc.4 → 2.40.0-rc.41

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 (224) hide show
  1. package/lib/aptos/aptos-processor.d.ts +1 -1
  2. package/lib/aptos/aptos-processor.d.ts.map +1 -1
  3. package/lib/aptos/aptos-processor.js +1 -1
  4. package/lib/aptos/aptos-processor.js.map +1 -1
  5. package/lib/aptos/context.d.ts +2 -2
  6. package/lib/aptos/context.d.ts.map +1 -1
  7. package/lib/aptos/context.js +1 -1
  8. package/lib/aptos/ext/aptos-dex.d.ts +1 -1
  9. package/lib/aptos/ext/aptos-dex.d.ts.map +1 -1
  10. package/lib/aptos/ext/aptos-dex.js +1 -1
  11. package/lib/aptos/ext/aptos-dex.js.map +1 -1
  12. package/lib/aptos/ext/coin-event.d.ts +1 -1
  13. package/lib/aptos/ext/coin-event.d.ts.map +1 -1
  14. package/lib/aptos/ext/coin.js +2 -2
  15. package/lib/aptos/ext/coin.js.map +1 -1
  16. package/lib/aptos/move-coder.d.ts.map +1 -1
  17. package/lib/aptos/move-coder.js +6 -5
  18. package/lib/aptos/move-coder.js.map +1 -1
  19. package/lib/aptos/network.d.ts +2 -0
  20. package/lib/aptos/network.d.ts.map +1 -1
  21. package/lib/aptos/network.js +7 -1
  22. package/lib/aptos/network.js.map +1 -1
  23. package/lib/eth/account-processor.d.ts +21 -7
  24. package/lib/eth/account-processor.d.ts.map +1 -1
  25. package/lib/eth/account-processor.js +2 -2
  26. package/lib/eth/account-processor.js.map +1 -1
  27. package/lib/eth/base-processor-template.d.ts +24 -8
  28. package/lib/eth/base-processor-template.d.ts.map +1 -1
  29. package/lib/eth/base-processor-template.js.map +1 -1
  30. package/lib/eth/base-processor.d.ts +30 -10
  31. package/lib/eth/base-processor.d.ts.map +1 -1
  32. package/lib/eth/base-processor.js +6 -6
  33. package/lib/eth/base-processor.js.map +1 -1
  34. package/lib/eth/builtin/internal/eacaggregatorproxy-processor.d.ts +100 -31
  35. package/lib/eth/builtin/internal/eacaggregatorproxy-processor.d.ts.map +1 -1
  36. package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js +1226 -46
  37. package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js.map +1 -1
  38. package/lib/eth/builtin/internal/erc1155-processor.d.ts +55 -16
  39. package/lib/eth/builtin/internal/erc1155-processor.d.ts.map +1 -1
  40. package/lib/eth/builtin/internal/erc1155-processor.js +486 -16
  41. package/lib/eth/builtin/internal/erc1155-processor.js.map +1 -1
  42. package/lib/eth/builtin/internal/erc20-processor.d.ts +79 -24
  43. package/lib/eth/builtin/internal/erc20-processor.d.ts.map +1 -1
  44. package/lib/eth/builtin/internal/erc20-processor.js +985 -36
  45. package/lib/eth/builtin/internal/erc20-processor.js.map +1 -1
  46. package/lib/eth/builtin/internal/erc20bytes-processor.d.ts +46 -13
  47. package/lib/eth/builtin/internal/erc20bytes-processor.d.ts.map +1 -1
  48. package/lib/eth/builtin/internal/erc20bytes-processor.js +485 -18
  49. package/lib/eth/builtin/internal/erc20bytes-processor.js.map +1 -1
  50. package/lib/eth/builtin/internal/erc721-processor.d.ts +67 -20
  51. package/lib/eth/builtin/internal/erc721-processor.d.ts.map +1 -1
  52. package/lib/eth/builtin/internal/erc721-processor.js +784 -28
  53. package/lib/eth/builtin/internal/erc721-processor.js.map +1 -1
  54. package/lib/eth/builtin/internal/weth9-processor.d.ts +64 -19
  55. package/lib/eth/builtin/internal/weth9-processor.d.ts.map +1 -1
  56. package/lib/eth/builtin/internal/weth9-processor.js +574 -22
  57. package/lib/eth/builtin/internal/weth9-processor.js.map +1 -1
  58. package/lib/eth/codegen/event-handler.js +1 -1
  59. package/lib/eth/codegen/file.d.ts.map +1 -1
  60. package/lib/eth/codegen/file.js +21 -3
  61. package/lib/eth/codegen/file.js.map +1 -1
  62. package/lib/eth/codegen/function-calls.d.ts +4 -0
  63. package/lib/eth/codegen/function-calls.d.ts.map +1 -1
  64. package/lib/eth/codegen/function-calls.js +80 -5
  65. package/lib/eth/codegen/function-calls.js.map +1 -1
  66. package/lib/eth/codegen/types.d.ts +1 -0
  67. package/lib/eth/codegen/types.d.ts.map +1 -1
  68. package/lib/eth/codegen/types.js +13 -0
  69. package/lib/eth/codegen/types.js.map +1 -1
  70. package/lib/eth/context.d.ts +4 -0
  71. package/lib/eth/context.d.ts.map +1 -1
  72. package/lib/eth/context.js +4 -0
  73. package/lib/eth/context.js.map +1 -1
  74. package/lib/eth/eth-plugin.d.ts +27 -9
  75. package/lib/eth/eth-plugin.d.ts.map +1 -1
  76. package/lib/eth/eth-plugin.js +20 -17
  77. package/lib/eth/eth-plugin.js.map +1 -1
  78. package/lib/eth/eth.d.ts.map +1 -1
  79. package/lib/eth/eth.js +1 -1
  80. package/lib/eth/eth.js.map +1 -1
  81. package/lib/eth/generic-processor.js +1 -1
  82. package/lib/eth/generic-processor.js.map +1 -1
  83. package/lib/eth/generic-processor.test.js.map +1 -1
  84. package/lib/eth/index.d.ts +2 -1
  85. package/lib/eth/index.d.ts.map +1 -1
  86. package/lib/eth/index.js +2 -1
  87. package/lib/eth/index.js.map +1 -1
  88. package/lib/solana/builtin/spl-token-processor.d.ts +1 -1
  89. package/lib/solana/builtin/spl-token-processor.d.ts.map +1 -1
  90. package/lib/solana/builtin/spl-token-processor.js +1 -1
  91. package/lib/solana/builtin/spl-token-processor.js.map +1 -1
  92. package/lib/solana/solana-context.d.ts +1 -1
  93. package/lib/solana/solana-context.js +2 -2
  94. package/lib/stark/codegen/codegen.d.ts +2 -0
  95. package/lib/stark/codegen/codegen.d.ts.map +1 -0
  96. package/lib/stark/codegen/codegen.js +109 -0
  97. package/lib/stark/codegen/codegen.js.map +1 -0
  98. package/lib/stark/codegen/index.d.ts +2 -0
  99. package/lib/stark/codegen/index.d.ts.map +1 -0
  100. package/lib/stark/codegen/index.js +2 -0
  101. package/lib/stark/codegen/index.js.map +1 -0
  102. package/lib/stark/codegen/run.d.ts +2 -0
  103. package/lib/stark/codegen/run.d.ts.map +1 -0
  104. package/lib/stark/codegen/run.js +11 -0
  105. package/lib/stark/codegen/run.js.map +1 -0
  106. package/lib/stark/codegen/utils.d.ts +2 -0
  107. package/lib/stark/codegen/utils.d.ts.map +1 -0
  108. package/lib/stark/codegen/utils.js +4 -0
  109. package/lib/stark/codegen/utils.js.map +1 -0
  110. package/lib/stark/context.d.ts +28 -0
  111. package/lib/stark/context.d.ts.map +1 -0
  112. package/lib/stark/context.js +59 -0
  113. package/lib/stark/context.js.map +1 -0
  114. package/lib/stark/contract.d.ts +12 -0
  115. package/lib/stark/contract.d.ts.map +1 -0
  116. package/lib/stark/contract.js +43 -0
  117. package/lib/stark/contract.js.map +1 -0
  118. package/lib/stark/event.d.ts +7 -0
  119. package/lib/stark/event.d.ts.map +1 -0
  120. package/lib/stark/event.js +11 -0
  121. package/lib/stark/event.js.map +1 -0
  122. package/lib/stark/index.d.ts +7 -0
  123. package/lib/stark/index.d.ts.map +1 -0
  124. package/lib/stark/index.js +7 -0
  125. package/lib/stark/index.js.map +1 -0
  126. package/lib/stark/starknet-plugin.d.ts +17 -0
  127. package/lib/stark/starknet-plugin.d.ts.map +1 -0
  128. package/lib/stark/starknet-plugin.js +78 -0
  129. package/lib/stark/starknet-plugin.js.map +1 -0
  130. package/lib/stark/starknet-processor.d.ts +32 -0
  131. package/lib/stark/starknet-processor.d.ts.map +1 -0
  132. package/lib/stark/starknet-processor.js +111 -0
  133. package/lib/stark/starknet-processor.js.map +1 -0
  134. package/lib/stark/types.d.ts +11 -0
  135. package/lib/stark/types.d.ts.map +1 -0
  136. package/lib/stark/types.js +2 -0
  137. package/lib/stark/types.js.map +1 -0
  138. package/lib/store/cache.d.ts +14 -0
  139. package/lib/store/cache.d.ts.map +1 -0
  140. package/lib/store/cache.js +35 -0
  141. package/lib/store/cache.js.map +1 -0
  142. package/lib/store/store.d.ts +2 -3
  143. package/lib/store/store.d.ts.map +1 -1
  144. package/lib/store/store.js +34 -9
  145. package/lib/store/store.js.map +1 -1
  146. package/lib/sui/context.d.ts +1 -1
  147. package/lib/sui/context.d.ts.map +1 -1
  148. package/lib/sui/sui-processor.d.ts +1 -1
  149. package/lib/sui/sui-processor.d.ts.map +1 -1
  150. package/lib/sui/sui-processor.js +1 -1
  151. package/lib/sui/sui-processor.js.map +1 -1
  152. package/lib/testing/aptos-facet.d.ts +1 -1
  153. package/lib/testing/aptos-facet.js +2 -2
  154. package/lib/testing/starknet-facet.d.ts +9 -0
  155. package/lib/testing/starknet-facet.d.ts.map +1 -0
  156. package/lib/testing/starknet-facet.js +52 -0
  157. package/lib/testing/starknet-facet.js.map +1 -0
  158. package/lib/testing/sui-facet.js +1 -1
  159. package/lib/testing/test-processor-server.d.ts +2 -0
  160. package/lib/testing/test-processor-server.d.ts.map +1 -1
  161. package/lib/testing/test-processor-server.js +3 -0
  162. package/lib/testing/test-processor-server.js.map +1 -1
  163. package/lib/tsup.config.ts +3 -15
  164. package/lib/utils/dex-price.d.ts +1 -0
  165. package/lib/utils/dex-price.d.ts.map +1 -1
  166. package/lib/utils/dex-price.js +13 -2
  167. package/lib/utils/dex-price.js.map +1 -1
  168. package/package.json +21 -10
  169. package/src/aptos/aptos-processor.ts +1 -1
  170. package/src/aptos/context.ts +2 -2
  171. package/src/aptos/ext/aptos-dex.ts +1 -1
  172. package/src/aptos/ext/coin-event.ts +1 -1
  173. package/src/aptos/ext/coin.ts +2 -2
  174. package/src/aptos/move-coder.ts +7 -5
  175. package/src/aptos/network.ts +7 -1
  176. package/src/bundle.config.ts +23 -0
  177. package/src/eth/account-processor.ts +28 -12
  178. package/src/eth/base-processor-template.ts +16 -8
  179. package/src/eth/base-processor.ts +25 -16
  180. package/src/eth/builtin/internal/eacaggregatorproxy-processor.ts +1554 -123
  181. package/src/eth/builtin/internal/erc1155-processor.ts +659 -42
  182. package/src/eth/builtin/internal/erc20-processor.ts +1266 -90
  183. package/src/eth/builtin/internal/erc20bytes-processor.ts +639 -49
  184. package/src/eth/builtin/internal/erc721-processor.ts +1035 -70
  185. package/src/eth/builtin/internal/weth9-processor.ts +758 -63
  186. package/src/eth/codegen/event-handler.ts +1 -1
  187. package/src/eth/codegen/file.ts +26 -3
  188. package/src/eth/codegen/function-calls.ts +96 -8
  189. package/src/eth/codegen/types.ts +22 -1
  190. package/src/eth/context.ts +7 -0
  191. package/src/eth/eth-plugin.ts +34 -26
  192. package/src/eth/eth.ts +1 -2
  193. package/src/eth/generic-processor.ts +1 -1
  194. package/src/eth/index.ts +5 -1
  195. package/src/solana/builtin/spl-token-processor.ts +1 -1
  196. package/src/solana/solana-context.ts +2 -2
  197. package/src/stark/codegen/codegen.ts +124 -0
  198. package/src/stark/codegen/index.ts +1 -0
  199. package/src/stark/codegen/run.ts +10 -0
  200. package/src/stark/codegen/utils.ts +3 -0
  201. package/src/stark/context.ts +78 -0
  202. package/src/stark/contract.ts +55 -0
  203. package/src/stark/event.ts +7 -0
  204. package/src/stark/index.ts +9 -0
  205. package/src/stark/starknet-plugin.ts +108 -0
  206. package/src/stark/starknet-processor.ts +140 -0
  207. package/src/stark/types.ts +11 -0
  208. package/src/store/cache.ts +46 -0
  209. package/src/store/store.ts +40 -22
  210. package/src/sui/context.ts +1 -1
  211. package/src/sui/sui-processor.ts +1 -1
  212. package/src/testing/aptos-facet.ts +2 -2
  213. package/src/testing/starknet-facet.ts +61 -0
  214. package/src/testing/sui-facet.ts +1 -1
  215. package/src/testing/test-processor-server.ts +3 -0
  216. package/src/tsup.config.ts +3 -15
  217. package/src/utils/dex-price.ts +15 -2
  218. package/lib/eth/provider.d.ts +0 -5
  219. package/lib/eth/provider.d.ts.map +0 -1
  220. package/lib/eth/provider.js +0 -134
  221. package/lib/eth/provider.js.map +0 -1
  222. package/lib/utils/chainlink-oracles-sepolia.csv +0 -19
  223. package/lib/utils/chainlink-oracles.csv +0 -217
  224. package/src/eth/provider.ts +0 -163
@@ -1,4 +1,8 @@
1
- import { addContractByABI, getContractByABI, addProcessor, getProcessor, getProvider, transformEtherError, BaseProcessor, BaseProcessorTemplate, BoundContractView, ContractView, DummyProvider, } from "@sentio/sdk/eth";
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import { Interface } from "ethers";
5
+ import { addContractByABI, getContractByABI, addProcessor, getProcessor, getProvider, transformEtherError, BaseProcessor, BaseProcessorTemplate, BoundContractView, ContractView, DummyProvider, makeEthCallKey, } from "@sentio/sdk/eth";
2
6
  import { EACAggregatorProxy__factory } from "./index.js";
3
7
  const templateContract = EACAggregatorProxy__factory.connect("0x0", DummyProvider);
4
8
  export class EACAggregatorProxyContractView extends ContractView {
@@ -6,8 +10,25 @@ export class EACAggregatorProxyContractView extends ContractView {
6
10
  super(contract);
7
11
  this.callStatic.contract = contract;
8
12
  }
9
- async accessController(overrides) {
13
+ async accessController(overrides, preparedData, ethCallContext) {
10
14
  try {
15
+ if (preparedData?.ethCallResults && ethCallContext) {
16
+ const iface = new Interface([
17
+ "function accessController() view returns (address)",
18
+ ]);
19
+ const calldata = iface.encodeFunctionData("accessController", []);
20
+ const key = makeEthCallKey({
21
+ context: ethCallContext,
22
+ calldata,
23
+ });
24
+ const ret = preparedData.ethCallResults[key];
25
+ if (ret) {
26
+ const result = iface
27
+ .decodeFunctionResult("accessController", ret)
28
+ .toArray();
29
+ return result.length == 1 ? result[0] : result;
30
+ }
31
+ }
11
32
  return await this.contract.getFunction("accessController()")(overrides || {});
12
33
  }
13
34
  catch (e) {
@@ -15,8 +36,25 @@ export class EACAggregatorProxyContractView extends ContractView {
15
36
  throw transformEtherError(e, undefined, stack);
16
37
  }
17
38
  }
18
- async aggregator(overrides) {
39
+ async aggregator(overrides, preparedData, ethCallContext) {
19
40
  try {
41
+ if (preparedData?.ethCallResults && ethCallContext) {
42
+ const iface = new Interface([
43
+ "function aggregator() view returns (address)",
44
+ ]);
45
+ const calldata = iface.encodeFunctionData("aggregator", []);
46
+ const key = makeEthCallKey({
47
+ context: ethCallContext,
48
+ calldata,
49
+ });
50
+ const ret = preparedData.ethCallResults[key];
51
+ if (ret) {
52
+ const result = iface
53
+ .decodeFunctionResult("aggregator", ret)
54
+ .toArray();
55
+ return result.length == 1 ? result[0] : result;
56
+ }
57
+ }
20
58
  return await this.contract.getFunction("aggregator()")(overrides || {});
21
59
  }
22
60
  catch (e) {
@@ -24,8 +62,23 @@ export class EACAggregatorProxyContractView extends ContractView {
24
62
  throw transformEtherError(e, undefined, stack);
25
63
  }
26
64
  }
27
- async decimals(overrides) {
65
+ async decimals(overrides, preparedData, ethCallContext) {
28
66
  try {
67
+ if (preparedData?.ethCallResults && ethCallContext) {
68
+ const iface = new Interface([
69
+ "function decimals() view returns (uint8)",
70
+ ]);
71
+ const calldata = iface.encodeFunctionData("decimals", []);
72
+ const key = makeEthCallKey({
73
+ context: ethCallContext,
74
+ calldata,
75
+ });
76
+ const ret = preparedData.ethCallResults[key];
77
+ if (ret) {
78
+ const result = iface.decodeFunctionResult("decimals", ret).toArray();
79
+ return result.length == 1 ? result[0] : result;
80
+ }
81
+ }
29
82
  return await this.contract.getFunction("decimals()")(overrides || {});
30
83
  }
31
84
  catch (e) {
@@ -33,8 +86,25 @@ export class EACAggregatorProxyContractView extends ContractView {
33
86
  throw transformEtherError(e, undefined, stack);
34
87
  }
35
88
  }
36
- async description(overrides) {
89
+ async description(overrides, preparedData, ethCallContext) {
37
90
  try {
91
+ if (preparedData?.ethCallResults && ethCallContext) {
92
+ const iface = new Interface([
93
+ "function description() view returns (string)",
94
+ ]);
95
+ const calldata = iface.encodeFunctionData("description", []);
96
+ const key = makeEthCallKey({
97
+ context: ethCallContext,
98
+ calldata,
99
+ });
100
+ const ret = preparedData.ethCallResults[key];
101
+ if (ret) {
102
+ const result = iface
103
+ .decodeFunctionResult("description", ret)
104
+ .toArray();
105
+ return result.length == 1 ? result[0] : result;
106
+ }
107
+ }
38
108
  return await this.contract.getFunction("description()")(overrides || {});
39
109
  }
40
110
  catch (e) {
@@ -42,8 +112,23 @@ export class EACAggregatorProxyContractView extends ContractView {
42
112
  throw transformEtherError(e, undefined, stack);
43
113
  }
44
114
  }
45
- async getAnswer(_roundId, overrides) {
115
+ async getAnswer(_roundId, overrides, preparedData, ethCallContext) {
46
116
  try {
117
+ if (preparedData?.ethCallResults && ethCallContext) {
118
+ const iface = new Interface([
119
+ "function getAnswer(uint256) view returns (int256)",
120
+ ]);
121
+ const calldata = iface.encodeFunctionData("getAnswer", [_roundId]);
122
+ const key = makeEthCallKey({
123
+ context: ethCallContext,
124
+ calldata,
125
+ });
126
+ const ret = preparedData.ethCallResults[key];
127
+ if (ret) {
128
+ const result = iface.decodeFunctionResult("getAnswer", ret).toArray();
129
+ return result.length == 1 ? result[0] : result;
130
+ }
131
+ }
47
132
  return await this.contract.getFunction("getAnswer(uint256)")(_roundId, overrides || {});
48
133
  }
49
134
  catch (e) {
@@ -51,8 +136,25 @@ export class EACAggregatorProxyContractView extends ContractView {
51
136
  throw transformEtherError(e, undefined, stack);
52
137
  }
53
138
  }
54
- async getRoundData(_roundId, overrides) {
139
+ async getRoundData(_roundId, overrides, preparedData, ethCallContext) {
55
140
  try {
141
+ if (preparedData?.ethCallResults && ethCallContext) {
142
+ const iface = new Interface([
143
+ "function getRoundData(uint80) view returns (uint80,int256,uint256,uint256,uint80)",
144
+ ]);
145
+ const calldata = iface.encodeFunctionData("getRoundData", [_roundId]);
146
+ const key = makeEthCallKey({
147
+ context: ethCallContext,
148
+ calldata,
149
+ });
150
+ const ret = preparedData.ethCallResults[key];
151
+ if (ret) {
152
+ const result = iface
153
+ .decodeFunctionResult("getRoundData", ret)
154
+ .toArray();
155
+ return result.length == 1 ? result[0] : result;
156
+ }
157
+ }
56
158
  return await this.contract.getFunction("getRoundData(uint80)")(_roundId, overrides || {});
57
159
  }
58
160
  catch (e) {
@@ -60,8 +162,25 @@ export class EACAggregatorProxyContractView extends ContractView {
60
162
  throw transformEtherError(e, undefined, stack);
61
163
  }
62
164
  }
63
- async getTimestamp(_roundId, overrides) {
165
+ async getTimestamp(_roundId, overrides, preparedData, ethCallContext) {
64
166
  try {
167
+ if (preparedData?.ethCallResults && ethCallContext) {
168
+ const iface = new Interface([
169
+ "function getTimestamp(uint256) view returns (uint256)",
170
+ ]);
171
+ const calldata = iface.encodeFunctionData("getTimestamp", [_roundId]);
172
+ const key = makeEthCallKey({
173
+ context: ethCallContext,
174
+ calldata,
175
+ });
176
+ const ret = preparedData.ethCallResults[key];
177
+ if (ret) {
178
+ const result = iface
179
+ .decodeFunctionResult("getTimestamp", ret)
180
+ .toArray();
181
+ return result.length == 1 ? result[0] : result;
182
+ }
183
+ }
65
184
  return await this.contract.getFunction("getTimestamp(uint256)")(_roundId, overrides || {});
66
185
  }
67
186
  catch (e) {
@@ -69,8 +188,25 @@ export class EACAggregatorProxyContractView extends ContractView {
69
188
  throw transformEtherError(e, undefined, stack);
70
189
  }
71
190
  }
72
- async latestAnswer(overrides) {
191
+ async latestAnswer(overrides, preparedData, ethCallContext) {
73
192
  try {
193
+ if (preparedData?.ethCallResults && ethCallContext) {
194
+ const iface = new Interface([
195
+ "function latestAnswer() view returns (int256)",
196
+ ]);
197
+ const calldata = iface.encodeFunctionData("latestAnswer", []);
198
+ const key = makeEthCallKey({
199
+ context: ethCallContext,
200
+ calldata,
201
+ });
202
+ const ret = preparedData.ethCallResults[key];
203
+ if (ret) {
204
+ const result = iface
205
+ .decodeFunctionResult("latestAnswer", ret)
206
+ .toArray();
207
+ return result.length == 1 ? result[0] : result;
208
+ }
209
+ }
74
210
  return await this.contract.getFunction("latestAnswer()")(overrides || {});
75
211
  }
76
212
  catch (e) {
@@ -78,8 +214,25 @@ export class EACAggregatorProxyContractView extends ContractView {
78
214
  throw transformEtherError(e, undefined, stack);
79
215
  }
80
216
  }
81
- async latestRound(overrides) {
217
+ async latestRound(overrides, preparedData, ethCallContext) {
82
218
  try {
219
+ if (preparedData?.ethCallResults && ethCallContext) {
220
+ const iface = new Interface([
221
+ "function latestRound() view returns (uint256)",
222
+ ]);
223
+ const calldata = iface.encodeFunctionData("latestRound", []);
224
+ const key = makeEthCallKey({
225
+ context: ethCallContext,
226
+ calldata,
227
+ });
228
+ const ret = preparedData.ethCallResults[key];
229
+ if (ret) {
230
+ const result = iface
231
+ .decodeFunctionResult("latestRound", ret)
232
+ .toArray();
233
+ return result.length == 1 ? result[0] : result;
234
+ }
235
+ }
83
236
  return await this.contract.getFunction("latestRound()")(overrides || {});
84
237
  }
85
238
  catch (e) {
@@ -87,8 +240,25 @@ export class EACAggregatorProxyContractView extends ContractView {
87
240
  throw transformEtherError(e, undefined, stack);
88
241
  }
89
242
  }
90
- async latestRoundData(overrides) {
243
+ async latestRoundData(overrides, preparedData, ethCallContext) {
91
244
  try {
245
+ if (preparedData?.ethCallResults && ethCallContext) {
246
+ const iface = new Interface([
247
+ "function latestRoundData() view returns (uint80,int256,uint256,uint256,uint80)",
248
+ ]);
249
+ const calldata = iface.encodeFunctionData("latestRoundData", []);
250
+ const key = makeEthCallKey({
251
+ context: ethCallContext,
252
+ calldata,
253
+ });
254
+ const ret = preparedData.ethCallResults[key];
255
+ if (ret) {
256
+ const result = iface
257
+ .decodeFunctionResult("latestRoundData", ret)
258
+ .toArray();
259
+ return result.length == 1 ? result[0] : result;
260
+ }
261
+ }
92
262
  return await this.contract.getFunction("latestRoundData()")(overrides || {});
93
263
  }
94
264
  catch (e) {
@@ -96,8 +266,25 @@ export class EACAggregatorProxyContractView extends ContractView {
96
266
  throw transformEtherError(e, undefined, stack);
97
267
  }
98
268
  }
99
- async latestTimestamp(overrides) {
269
+ async latestTimestamp(overrides, preparedData, ethCallContext) {
100
270
  try {
271
+ if (preparedData?.ethCallResults && ethCallContext) {
272
+ const iface = new Interface([
273
+ "function latestTimestamp() view returns (uint256)",
274
+ ]);
275
+ const calldata = iface.encodeFunctionData("latestTimestamp", []);
276
+ const key = makeEthCallKey({
277
+ context: ethCallContext,
278
+ calldata,
279
+ });
280
+ const ret = preparedData.ethCallResults[key];
281
+ if (ret) {
282
+ const result = iface
283
+ .decodeFunctionResult("latestTimestamp", ret)
284
+ .toArray();
285
+ return result.length == 1 ? result[0] : result;
286
+ }
287
+ }
101
288
  return await this.contract.getFunction("latestTimestamp()")(overrides || {});
102
289
  }
103
290
  catch (e) {
@@ -105,8 +292,23 @@ export class EACAggregatorProxyContractView extends ContractView {
105
292
  throw transformEtherError(e, undefined, stack);
106
293
  }
107
294
  }
108
- async owner(overrides) {
295
+ async owner(overrides, preparedData, ethCallContext) {
109
296
  try {
297
+ if (preparedData?.ethCallResults && ethCallContext) {
298
+ const iface = new Interface([
299
+ "function owner() view returns (address)",
300
+ ]);
301
+ const calldata = iface.encodeFunctionData("owner", []);
302
+ const key = makeEthCallKey({
303
+ context: ethCallContext,
304
+ calldata,
305
+ });
306
+ const ret = preparedData.ethCallResults[key];
307
+ if (ret) {
308
+ const result = iface.decodeFunctionResult("owner", ret).toArray();
309
+ return result.length == 1 ? result[0] : result;
310
+ }
311
+ }
110
312
  return await this.contract.getFunction("owner()")(overrides || {});
111
313
  }
112
314
  catch (e) {
@@ -114,8 +316,25 @@ export class EACAggregatorProxyContractView extends ContractView {
114
316
  throw transformEtherError(e, undefined, stack);
115
317
  }
116
318
  }
117
- async phaseAggregators(arg0, overrides) {
319
+ async phaseAggregators(arg0, overrides, preparedData, ethCallContext) {
118
320
  try {
321
+ if (preparedData?.ethCallResults && ethCallContext) {
322
+ const iface = new Interface([
323
+ "function phaseAggregators(uint16) view returns (address)",
324
+ ]);
325
+ const calldata = iface.encodeFunctionData("phaseAggregators", [arg0]);
326
+ const key = makeEthCallKey({
327
+ context: ethCallContext,
328
+ calldata,
329
+ });
330
+ const ret = preparedData.ethCallResults[key];
331
+ if (ret) {
332
+ const result = iface
333
+ .decodeFunctionResult("phaseAggregators", ret)
334
+ .toArray();
335
+ return result.length == 1 ? result[0] : result;
336
+ }
337
+ }
119
338
  return await this.contract.getFunction("phaseAggregators(uint16)")(arg0, overrides || {});
120
339
  }
121
340
  catch (e) {
@@ -123,8 +342,23 @@ export class EACAggregatorProxyContractView extends ContractView {
123
342
  throw transformEtherError(e, undefined, stack);
124
343
  }
125
344
  }
126
- async phaseId(overrides) {
345
+ async phaseId(overrides, preparedData, ethCallContext) {
127
346
  try {
347
+ if (preparedData?.ethCallResults && ethCallContext) {
348
+ const iface = new Interface([
349
+ "function phaseId() view returns (uint16)",
350
+ ]);
351
+ const calldata = iface.encodeFunctionData("phaseId", []);
352
+ const key = makeEthCallKey({
353
+ context: ethCallContext,
354
+ calldata,
355
+ });
356
+ const ret = preparedData.ethCallResults[key];
357
+ if (ret) {
358
+ const result = iface.decodeFunctionResult("phaseId", ret).toArray();
359
+ return result.length == 1 ? result[0] : result;
360
+ }
361
+ }
128
362
  return await this.contract.getFunction("phaseId()")(overrides || {});
129
363
  }
130
364
  catch (e) {
@@ -132,8 +366,25 @@ export class EACAggregatorProxyContractView extends ContractView {
132
366
  throw transformEtherError(e, undefined, stack);
133
367
  }
134
368
  }
135
- async proposedAggregator(overrides) {
369
+ async proposedAggregator(overrides, preparedData, ethCallContext) {
136
370
  try {
371
+ if (preparedData?.ethCallResults && ethCallContext) {
372
+ const iface = new Interface([
373
+ "function proposedAggregator() view returns (address)",
374
+ ]);
375
+ const calldata = iface.encodeFunctionData("proposedAggregator", []);
376
+ const key = makeEthCallKey({
377
+ context: ethCallContext,
378
+ calldata,
379
+ });
380
+ const ret = preparedData.ethCallResults[key];
381
+ if (ret) {
382
+ const result = iface
383
+ .decodeFunctionResult("proposedAggregator", ret)
384
+ .toArray();
385
+ return result.length == 1 ? result[0] : result;
386
+ }
387
+ }
137
388
  return await this.contract.getFunction("proposedAggregator()")(overrides || {});
138
389
  }
139
390
  catch (e) {
@@ -141,8 +392,27 @@ export class EACAggregatorProxyContractView extends ContractView {
141
392
  throw transformEtherError(e, undefined, stack);
142
393
  }
143
394
  }
144
- async proposedGetRoundData(_roundId, overrides) {
395
+ async proposedGetRoundData(_roundId, overrides, preparedData, ethCallContext) {
145
396
  try {
397
+ if (preparedData?.ethCallResults && ethCallContext) {
398
+ const iface = new Interface([
399
+ "function proposedGetRoundData(uint80) view returns (uint80,int256,uint256,uint256,uint80)",
400
+ ]);
401
+ const calldata = iface.encodeFunctionData("proposedGetRoundData", [
402
+ _roundId,
403
+ ]);
404
+ const key = makeEthCallKey({
405
+ context: ethCallContext,
406
+ calldata,
407
+ });
408
+ const ret = preparedData.ethCallResults[key];
409
+ if (ret) {
410
+ const result = iface
411
+ .decodeFunctionResult("proposedGetRoundData", ret)
412
+ .toArray();
413
+ return result.length == 1 ? result[0] : result;
414
+ }
415
+ }
146
416
  return await this.contract.getFunction("proposedGetRoundData(uint80)")(_roundId, overrides || {});
147
417
  }
148
418
  catch (e) {
@@ -150,8 +420,25 @@ export class EACAggregatorProxyContractView extends ContractView {
150
420
  throw transformEtherError(e, undefined, stack);
151
421
  }
152
422
  }
153
- async proposedLatestRoundData(overrides) {
423
+ async proposedLatestRoundData(overrides, preparedData, ethCallContext) {
154
424
  try {
425
+ if (preparedData?.ethCallResults && ethCallContext) {
426
+ const iface = new Interface([
427
+ "function proposedLatestRoundData() view returns (uint80,int256,uint256,uint256,uint80)",
428
+ ]);
429
+ const calldata = iface.encodeFunctionData("proposedLatestRoundData", []);
430
+ const key = makeEthCallKey({
431
+ context: ethCallContext,
432
+ calldata,
433
+ });
434
+ const ret = preparedData.ethCallResults[key];
435
+ if (ret) {
436
+ const result = iface
437
+ .decodeFunctionResult("proposedLatestRoundData", ret)
438
+ .toArray();
439
+ return result.length == 1 ? result[0] : result;
440
+ }
441
+ }
155
442
  return await this.contract.getFunction("proposedLatestRoundData()")(overrides || {});
156
443
  }
157
444
  catch (e) {
@@ -159,8 +446,23 @@ export class EACAggregatorProxyContractView extends ContractView {
159
446
  throw transformEtherError(e, undefined, stack);
160
447
  }
161
448
  }
162
- async version(overrides) {
449
+ async version(overrides, preparedData, ethCallContext) {
163
450
  try {
451
+ if (preparedData?.ethCallResults && ethCallContext) {
452
+ const iface = new Interface([
453
+ "function version() view returns (uint256)",
454
+ ]);
455
+ const calldata = iface.encodeFunctionData("version", []);
456
+ const key = makeEthCallKey({
457
+ context: ethCallContext,
458
+ calldata,
459
+ });
460
+ const ret = preparedData.ethCallResults[key];
461
+ if (ret) {
462
+ const result = iface.decodeFunctionResult("version", ret).toArray();
463
+ return result.length == 1 ? result[0] : result;
464
+ }
465
+ }
164
466
  return await this.contract.getFunction("version()")(overrides || {});
165
467
  }
166
468
  catch (e) {
@@ -170,8 +472,25 @@ export class EACAggregatorProxyContractView extends ContractView {
170
472
  }
171
473
  callStatic = {
172
474
  contract: this.contract,
173
- async acceptOwnership(overrides) {
475
+ async acceptOwnership(overrides, preparedData, ethCallContext) {
174
476
  try {
477
+ if (preparedData?.ethCallResults && ethCallContext) {
478
+ const iface = new Interface([
479
+ "function acceptOwnership() nonpayable returns ()",
480
+ ]);
481
+ const calldata = iface.encodeFunctionData("acceptOwnership", []);
482
+ const key = makeEthCallKey({
483
+ context: ethCallContext,
484
+ calldata,
485
+ });
486
+ const ret = preparedData.ethCallResults[key];
487
+ if (ret) {
488
+ const result = iface
489
+ .decodeFunctionResult("acceptOwnership", ret)
490
+ .toArray();
491
+ return result.length == 1 ? result[0] : result;
492
+ }
493
+ }
175
494
  return await this.contract
176
495
  .getFunction("acceptOwnership()")
177
496
  .staticCall(overrides || {});
@@ -181,8 +500,27 @@ export class EACAggregatorProxyContractView extends ContractView {
181
500
  throw transformEtherError(e, undefined, stack);
182
501
  }
183
502
  },
184
- async confirmAggregator(_aggregator, overrides) {
503
+ async confirmAggregator(_aggregator, overrides, preparedData, ethCallContext) {
185
504
  try {
505
+ if (preparedData?.ethCallResults && ethCallContext) {
506
+ const iface = new Interface([
507
+ "function confirmAggregator(address) nonpayable returns ()",
508
+ ]);
509
+ const calldata = iface.encodeFunctionData("confirmAggregator", [
510
+ _aggregator,
511
+ ]);
512
+ const key = makeEthCallKey({
513
+ context: ethCallContext,
514
+ calldata,
515
+ });
516
+ const ret = preparedData.ethCallResults[key];
517
+ if (ret) {
518
+ const result = iface
519
+ .decodeFunctionResult("confirmAggregator", ret)
520
+ .toArray();
521
+ return result.length == 1 ? result[0] : result;
522
+ }
523
+ }
186
524
  return await this.contract
187
525
  .getFunction("confirmAggregator(address)")
188
526
  .staticCall(_aggregator, overrides || {});
@@ -192,8 +530,27 @@ export class EACAggregatorProxyContractView extends ContractView {
192
530
  throw transformEtherError(e, undefined, stack);
193
531
  }
194
532
  },
195
- async proposeAggregator(_aggregator, overrides) {
533
+ async proposeAggregator(_aggregator, overrides, preparedData, ethCallContext) {
196
534
  try {
535
+ if (preparedData?.ethCallResults && ethCallContext) {
536
+ const iface = new Interface([
537
+ "function proposeAggregator(address) nonpayable returns ()",
538
+ ]);
539
+ const calldata = iface.encodeFunctionData("proposeAggregator", [
540
+ _aggregator,
541
+ ]);
542
+ const key = makeEthCallKey({
543
+ context: ethCallContext,
544
+ calldata,
545
+ });
546
+ const ret = preparedData.ethCallResults[key];
547
+ if (ret) {
548
+ const result = iface
549
+ .decodeFunctionResult("proposeAggregator", ret)
550
+ .toArray();
551
+ return result.length == 1 ? result[0] : result;
552
+ }
553
+ }
197
554
  return await this.contract
198
555
  .getFunction("proposeAggregator(address)")
199
556
  .staticCall(_aggregator, overrides || {});
@@ -203,8 +560,27 @@ export class EACAggregatorProxyContractView extends ContractView {
203
560
  throw transformEtherError(e, undefined, stack);
204
561
  }
205
562
  },
206
- async setController(_accessController, overrides) {
563
+ async setController(_accessController, overrides, preparedData, ethCallContext) {
207
564
  try {
565
+ if (preparedData?.ethCallResults && ethCallContext) {
566
+ const iface = new Interface([
567
+ "function setController(address) nonpayable returns ()",
568
+ ]);
569
+ const calldata = iface.encodeFunctionData("setController", [
570
+ _accessController,
571
+ ]);
572
+ const key = makeEthCallKey({
573
+ context: ethCallContext,
574
+ calldata,
575
+ });
576
+ const ret = preparedData.ethCallResults[key];
577
+ if (ret) {
578
+ const result = iface
579
+ .decodeFunctionResult("setController", ret)
580
+ .toArray();
581
+ return result.length == 1 ? result[0] : result;
582
+ }
583
+ }
208
584
  return await this.contract
209
585
  .getFunction("setController(address)")
210
586
  .staticCall(_accessController, overrides || {});
@@ -214,8 +590,25 @@ export class EACAggregatorProxyContractView extends ContractView {
214
590
  throw transformEtherError(e, undefined, stack);
215
591
  }
216
592
  },
217
- async transferOwnership(_to, overrides) {
593
+ async transferOwnership(_to, overrides, preparedData, ethCallContext) {
218
594
  try {
595
+ if (preparedData?.ethCallResults && ethCallContext) {
596
+ const iface = new Interface([
597
+ "function transferOwnership(address) nonpayable returns ()",
598
+ ]);
599
+ const calldata = iface.encodeFunctionData("transferOwnership", [_to]);
600
+ const key = makeEthCallKey({
601
+ context: ethCallContext,
602
+ calldata,
603
+ });
604
+ const ret = preparedData.ethCallResults[key];
605
+ if (ret) {
606
+ const result = iface
607
+ .decodeFunctionResult("transferOwnership", ret)
608
+ .toArray();
609
+ return result.length == 1 ? result[0] : result;
610
+ }
611
+ }
219
612
  return await this.contract
220
613
  .getFunction("transferOwnership(address)")
221
614
  .staticCall(_to, overrides || {});
@@ -226,149 +619,936 @@ export class EACAggregatorProxyContractView extends ContractView {
226
619
  }
227
620
  },
228
621
  };
622
+ encodeCall = {
623
+ acceptOwnership(ethCallContext) {
624
+ try {
625
+ const iface = new Interface(["function acceptOwnership()"]);
626
+ const calldata = iface.encodeFunctionData("acceptOwnership", []);
627
+ return {
628
+ context: ethCallContext,
629
+ calldata,
630
+ };
631
+ }
632
+ catch (e) {
633
+ const stack = new Error().stack;
634
+ throw transformEtherError(e, undefined, stack);
635
+ }
636
+ },
637
+ accessController(ethCallContext) {
638
+ try {
639
+ const iface = new Interface(["function accessController()"]);
640
+ const calldata = iface.encodeFunctionData("accessController", []);
641
+ return {
642
+ context: ethCallContext,
643
+ calldata,
644
+ };
645
+ }
646
+ catch (e) {
647
+ const stack = new Error().stack;
648
+ throw transformEtherError(e, undefined, stack);
649
+ }
650
+ },
651
+ aggregator(ethCallContext) {
652
+ try {
653
+ const iface = new Interface(["function aggregator()"]);
654
+ const calldata = iface.encodeFunctionData("aggregator", []);
655
+ return {
656
+ context: ethCallContext,
657
+ calldata,
658
+ };
659
+ }
660
+ catch (e) {
661
+ const stack = new Error().stack;
662
+ throw transformEtherError(e, undefined, stack);
663
+ }
664
+ },
665
+ confirmAggregator(_aggregator, ethCallContext) {
666
+ try {
667
+ const iface = new Interface(["function confirmAggregator(address)"]);
668
+ const calldata = iface.encodeFunctionData("confirmAggregator", [
669
+ _aggregator,
670
+ ]);
671
+ return {
672
+ context: ethCallContext,
673
+ calldata,
674
+ };
675
+ }
676
+ catch (e) {
677
+ const stack = new Error().stack;
678
+ throw transformEtherError(e, undefined, stack);
679
+ }
680
+ },
681
+ decimals(ethCallContext) {
682
+ try {
683
+ const iface = new Interface(["function decimals()"]);
684
+ const calldata = iface.encodeFunctionData("decimals", []);
685
+ return {
686
+ context: ethCallContext,
687
+ calldata,
688
+ };
689
+ }
690
+ catch (e) {
691
+ const stack = new Error().stack;
692
+ throw transformEtherError(e, undefined, stack);
693
+ }
694
+ },
695
+ description(ethCallContext) {
696
+ try {
697
+ const iface = new Interface(["function description()"]);
698
+ const calldata = iface.encodeFunctionData("description", []);
699
+ return {
700
+ context: ethCallContext,
701
+ calldata,
702
+ };
703
+ }
704
+ catch (e) {
705
+ const stack = new Error().stack;
706
+ throw transformEtherError(e, undefined, stack);
707
+ }
708
+ },
709
+ getAnswer(_roundId, ethCallContext) {
710
+ try {
711
+ const iface = new Interface(["function getAnswer(uint256)"]);
712
+ const calldata = iface.encodeFunctionData("getAnswer", [_roundId]);
713
+ return {
714
+ context: ethCallContext,
715
+ calldata,
716
+ };
717
+ }
718
+ catch (e) {
719
+ const stack = new Error().stack;
720
+ throw transformEtherError(e, undefined, stack);
721
+ }
722
+ },
723
+ getRoundData(_roundId, ethCallContext) {
724
+ try {
725
+ const iface = new Interface(["function getRoundData(uint80)"]);
726
+ const calldata = iface.encodeFunctionData("getRoundData", [_roundId]);
727
+ return {
728
+ context: ethCallContext,
729
+ calldata,
730
+ };
731
+ }
732
+ catch (e) {
733
+ const stack = new Error().stack;
734
+ throw transformEtherError(e, undefined, stack);
735
+ }
736
+ },
737
+ getTimestamp(_roundId, ethCallContext) {
738
+ try {
739
+ const iface = new Interface(["function getTimestamp(uint256)"]);
740
+ const calldata = iface.encodeFunctionData("getTimestamp", [_roundId]);
741
+ return {
742
+ context: ethCallContext,
743
+ calldata,
744
+ };
745
+ }
746
+ catch (e) {
747
+ const stack = new Error().stack;
748
+ throw transformEtherError(e, undefined, stack);
749
+ }
750
+ },
751
+ latestAnswer(ethCallContext) {
752
+ try {
753
+ const iface = new Interface(["function latestAnswer()"]);
754
+ const calldata = iface.encodeFunctionData("latestAnswer", []);
755
+ return {
756
+ context: ethCallContext,
757
+ calldata,
758
+ };
759
+ }
760
+ catch (e) {
761
+ const stack = new Error().stack;
762
+ throw transformEtherError(e, undefined, stack);
763
+ }
764
+ },
765
+ latestRound(ethCallContext) {
766
+ try {
767
+ const iface = new Interface(["function latestRound()"]);
768
+ const calldata = iface.encodeFunctionData("latestRound", []);
769
+ return {
770
+ context: ethCallContext,
771
+ calldata,
772
+ };
773
+ }
774
+ catch (e) {
775
+ const stack = new Error().stack;
776
+ throw transformEtherError(e, undefined, stack);
777
+ }
778
+ },
779
+ latestRoundData(ethCallContext) {
780
+ try {
781
+ const iface = new Interface(["function latestRoundData()"]);
782
+ const calldata = iface.encodeFunctionData("latestRoundData", []);
783
+ return {
784
+ context: ethCallContext,
785
+ calldata,
786
+ };
787
+ }
788
+ catch (e) {
789
+ const stack = new Error().stack;
790
+ throw transformEtherError(e, undefined, stack);
791
+ }
792
+ },
793
+ latestTimestamp(ethCallContext) {
794
+ try {
795
+ const iface = new Interface(["function latestTimestamp()"]);
796
+ const calldata = iface.encodeFunctionData("latestTimestamp", []);
797
+ return {
798
+ context: ethCallContext,
799
+ calldata,
800
+ };
801
+ }
802
+ catch (e) {
803
+ const stack = new Error().stack;
804
+ throw transformEtherError(e, undefined, stack);
805
+ }
806
+ },
807
+ owner(ethCallContext) {
808
+ try {
809
+ const iface = new Interface(["function owner()"]);
810
+ const calldata = iface.encodeFunctionData("owner", []);
811
+ return {
812
+ context: ethCallContext,
813
+ calldata,
814
+ };
815
+ }
816
+ catch (e) {
817
+ const stack = new Error().stack;
818
+ throw transformEtherError(e, undefined, stack);
819
+ }
820
+ },
821
+ phaseAggregators(arg0, ethCallContext) {
822
+ try {
823
+ const iface = new Interface(["function phaseAggregators(uint16)"]);
824
+ const calldata = iface.encodeFunctionData("phaseAggregators", [arg0]);
825
+ return {
826
+ context: ethCallContext,
827
+ calldata,
828
+ };
829
+ }
830
+ catch (e) {
831
+ const stack = new Error().stack;
832
+ throw transformEtherError(e, undefined, stack);
833
+ }
834
+ },
835
+ phaseId(ethCallContext) {
836
+ try {
837
+ const iface = new Interface(["function phaseId()"]);
838
+ const calldata = iface.encodeFunctionData("phaseId", []);
839
+ return {
840
+ context: ethCallContext,
841
+ calldata,
842
+ };
843
+ }
844
+ catch (e) {
845
+ const stack = new Error().stack;
846
+ throw transformEtherError(e, undefined, stack);
847
+ }
848
+ },
849
+ proposeAggregator(_aggregator, ethCallContext) {
850
+ try {
851
+ const iface = new Interface(["function proposeAggregator(address)"]);
852
+ const calldata = iface.encodeFunctionData("proposeAggregator", [
853
+ _aggregator,
854
+ ]);
855
+ return {
856
+ context: ethCallContext,
857
+ calldata,
858
+ };
859
+ }
860
+ catch (e) {
861
+ const stack = new Error().stack;
862
+ throw transformEtherError(e, undefined, stack);
863
+ }
864
+ },
865
+ proposedAggregator(ethCallContext) {
866
+ try {
867
+ const iface = new Interface(["function proposedAggregator()"]);
868
+ const calldata = iface.encodeFunctionData("proposedAggregator", []);
869
+ return {
870
+ context: ethCallContext,
871
+ calldata,
872
+ };
873
+ }
874
+ catch (e) {
875
+ const stack = new Error().stack;
876
+ throw transformEtherError(e, undefined, stack);
877
+ }
878
+ },
879
+ proposedGetRoundData(_roundId, ethCallContext) {
880
+ try {
881
+ const iface = new Interface(["function proposedGetRoundData(uint80)"]);
882
+ const calldata = iface.encodeFunctionData("proposedGetRoundData", [
883
+ _roundId,
884
+ ]);
885
+ return {
886
+ context: ethCallContext,
887
+ calldata,
888
+ };
889
+ }
890
+ catch (e) {
891
+ const stack = new Error().stack;
892
+ throw transformEtherError(e, undefined, stack);
893
+ }
894
+ },
895
+ proposedLatestRoundData(ethCallContext) {
896
+ try {
897
+ const iface = new Interface(["function proposedLatestRoundData()"]);
898
+ const calldata = iface.encodeFunctionData("proposedLatestRoundData", []);
899
+ return {
900
+ context: ethCallContext,
901
+ calldata,
902
+ };
903
+ }
904
+ catch (e) {
905
+ const stack = new Error().stack;
906
+ throw transformEtherError(e, undefined, stack);
907
+ }
908
+ },
909
+ setController(_accessController, ethCallContext) {
910
+ try {
911
+ const iface = new Interface(["function setController(address)"]);
912
+ const calldata = iface.encodeFunctionData("setController", [
913
+ _accessController,
914
+ ]);
915
+ return {
916
+ context: ethCallContext,
917
+ calldata,
918
+ };
919
+ }
920
+ catch (e) {
921
+ const stack = new Error().stack;
922
+ throw transformEtherError(e, undefined, stack);
923
+ }
924
+ },
925
+ transferOwnership(_to, ethCallContext) {
926
+ try {
927
+ const iface = new Interface(["function transferOwnership(address)"]);
928
+ const calldata = iface.encodeFunctionData("transferOwnership", [_to]);
929
+ return {
930
+ context: ethCallContext,
931
+ calldata,
932
+ };
933
+ }
934
+ catch (e) {
935
+ const stack = new Error().stack;
936
+ throw transformEtherError(e, undefined, stack);
937
+ }
938
+ },
939
+ version(ethCallContext) {
940
+ try {
941
+ const iface = new Interface(["function version()"]);
942
+ const calldata = iface.encodeFunctionData("version", []);
943
+ return {
944
+ context: ethCallContext,
945
+ calldata,
946
+ };
947
+ }
948
+ catch (e) {
949
+ const stack = new Error().stack;
950
+ throw transformEtherError(e, undefined, stack);
951
+ }
952
+ },
953
+ };
229
954
  }
230
955
  export class EACAggregatorProxyBoundContractView extends BoundContractView {
231
956
  async accessController(overrides) {
957
+ const ethCallContext = {
958
+ chainId: this.context.chainId,
959
+ blockTag: "0x" + this.context.blockNumber.toString(16),
960
+ address: this.context.address,
961
+ };
232
962
  return await this.view.accessController({
233
963
  blockTag: this.context.blockNumber,
234
964
  ...overrides,
235
- });
965
+ }, this.context.preparedData, ethCallContext);
236
966
  }
237
967
  async aggregator(overrides) {
968
+ const ethCallContext = {
969
+ chainId: this.context.chainId,
970
+ blockTag: "0x" + this.context.blockNumber.toString(16),
971
+ address: this.context.address,
972
+ };
238
973
  return await this.view.aggregator({
239
974
  blockTag: this.context.blockNumber,
240
975
  ...overrides,
241
- });
976
+ }, this.context.preparedData, ethCallContext);
242
977
  }
243
978
  async decimals(overrides) {
979
+ const ethCallContext = {
980
+ chainId: this.context.chainId,
981
+ blockTag: "0x" + this.context.blockNumber.toString(16),
982
+ address: this.context.address,
983
+ };
244
984
  return await this.view.decimals({
245
985
  blockTag: this.context.blockNumber,
246
986
  ...overrides,
247
- });
987
+ }, this.context.preparedData, ethCallContext);
248
988
  }
249
989
  async description(overrides) {
990
+ const ethCallContext = {
991
+ chainId: this.context.chainId,
992
+ blockTag: "0x" + this.context.blockNumber.toString(16),
993
+ address: this.context.address,
994
+ };
250
995
  return await this.view.description({
251
996
  blockTag: this.context.blockNumber,
252
997
  ...overrides,
253
- });
998
+ }, this.context.preparedData, ethCallContext);
254
999
  }
255
1000
  async getAnswer(_roundId, overrides) {
1001
+ const ethCallContext = {
1002
+ chainId: this.context.chainId,
1003
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1004
+ address: this.context.address,
1005
+ };
256
1006
  return await this.view.getAnswer(_roundId, {
257
1007
  blockTag: this.context.blockNumber,
258
1008
  ...overrides,
259
- });
1009
+ }, this.context.preparedData, ethCallContext);
260
1010
  }
261
1011
  async getRoundData(_roundId, overrides) {
1012
+ const ethCallContext = {
1013
+ chainId: this.context.chainId,
1014
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1015
+ address: this.context.address,
1016
+ };
262
1017
  return await this.view.getRoundData(_roundId, {
263
1018
  blockTag: this.context.blockNumber,
264
1019
  ...overrides,
265
- });
1020
+ }, this.context.preparedData, ethCallContext);
266
1021
  }
267
1022
  async getTimestamp(_roundId, overrides) {
1023
+ const ethCallContext = {
1024
+ chainId: this.context.chainId,
1025
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1026
+ address: this.context.address,
1027
+ };
268
1028
  return await this.view.getTimestamp(_roundId, {
269
1029
  blockTag: this.context.blockNumber,
270
1030
  ...overrides,
271
- });
1031
+ }, this.context.preparedData, ethCallContext);
272
1032
  }
273
1033
  async latestAnswer(overrides) {
1034
+ const ethCallContext = {
1035
+ chainId: this.context.chainId,
1036
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1037
+ address: this.context.address,
1038
+ };
274
1039
  return await this.view.latestAnswer({
275
1040
  blockTag: this.context.blockNumber,
276
1041
  ...overrides,
277
- });
1042
+ }, this.context.preparedData, ethCallContext);
278
1043
  }
279
1044
  async latestRound(overrides) {
1045
+ const ethCallContext = {
1046
+ chainId: this.context.chainId,
1047
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1048
+ address: this.context.address,
1049
+ };
280
1050
  return await this.view.latestRound({
281
1051
  blockTag: this.context.blockNumber,
282
1052
  ...overrides,
283
- });
1053
+ }, this.context.preparedData, ethCallContext);
284
1054
  }
285
1055
  async latestRoundData(overrides) {
1056
+ const ethCallContext = {
1057
+ chainId: this.context.chainId,
1058
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1059
+ address: this.context.address,
1060
+ };
286
1061
  return await this.view.latestRoundData({
287
1062
  blockTag: this.context.blockNumber,
288
1063
  ...overrides,
289
- });
1064
+ }, this.context.preparedData, ethCallContext);
290
1065
  }
291
1066
  async latestTimestamp(overrides) {
1067
+ const ethCallContext = {
1068
+ chainId: this.context.chainId,
1069
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1070
+ address: this.context.address,
1071
+ };
292
1072
  return await this.view.latestTimestamp({
293
1073
  blockTag: this.context.blockNumber,
294
1074
  ...overrides,
295
- });
1075
+ }, this.context.preparedData, ethCallContext);
296
1076
  }
297
1077
  async owner(overrides) {
1078
+ const ethCallContext = {
1079
+ chainId: this.context.chainId,
1080
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1081
+ address: this.context.address,
1082
+ };
298
1083
  return await this.view.owner({
299
1084
  blockTag: this.context.blockNumber,
300
1085
  ...overrides,
301
- });
1086
+ }, this.context.preparedData, ethCallContext);
302
1087
  }
303
1088
  async phaseAggregators(arg0, overrides) {
1089
+ const ethCallContext = {
1090
+ chainId: this.context.chainId,
1091
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1092
+ address: this.context.address,
1093
+ };
304
1094
  return await this.view.phaseAggregators(arg0, {
305
1095
  blockTag: this.context.blockNumber,
306
1096
  ...overrides,
307
- });
1097
+ }, this.context.preparedData, ethCallContext);
308
1098
  }
309
1099
  async phaseId(overrides) {
1100
+ const ethCallContext = {
1101
+ chainId: this.context.chainId,
1102
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1103
+ address: this.context.address,
1104
+ };
310
1105
  return await this.view.phaseId({
311
1106
  blockTag: this.context.blockNumber,
312
1107
  ...overrides,
313
- });
1108
+ }, this.context.preparedData, ethCallContext);
314
1109
  }
315
1110
  async proposedAggregator(overrides) {
1111
+ const ethCallContext = {
1112
+ chainId: this.context.chainId,
1113
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1114
+ address: this.context.address,
1115
+ };
316
1116
  return await this.view.proposedAggregator({
317
1117
  blockTag: this.context.blockNumber,
318
1118
  ...overrides,
319
- });
1119
+ }, this.context.preparedData, ethCallContext);
320
1120
  }
321
1121
  async proposedGetRoundData(_roundId, overrides) {
1122
+ const ethCallContext = {
1123
+ chainId: this.context.chainId,
1124
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1125
+ address: this.context.address,
1126
+ };
322
1127
  return await this.view.proposedGetRoundData(_roundId, {
323
1128
  blockTag: this.context.blockNumber,
324
1129
  ...overrides,
325
- });
1130
+ }, this.context.preparedData, ethCallContext);
326
1131
  }
327
1132
  async proposedLatestRoundData(overrides) {
1133
+ const ethCallContext = {
1134
+ chainId: this.context.chainId,
1135
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1136
+ address: this.context.address,
1137
+ };
328
1138
  return await this.view.proposedLatestRoundData({
329
1139
  blockTag: this.context.blockNumber,
330
1140
  ...overrides,
331
- });
1141
+ }, this.context.preparedData, ethCallContext);
332
1142
  }
333
1143
  async version(overrides) {
1144
+ const ethCallContext = {
1145
+ chainId: this.context.chainId,
1146
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1147
+ address: this.context.address,
1148
+ };
334
1149
  return await this.view.version({
335
1150
  blockTag: this.context.blockNumber,
336
1151
  ...overrides,
337
- });
1152
+ }, this.context.preparedData, ethCallContext);
338
1153
  }
339
1154
  callStatic = {
340
1155
  view: this.view,
341
1156
  context: this.context,
342
1157
  async acceptOwnership(overrides) {
1158
+ const ethCallContext = {
1159
+ chainId: this.context.chainId,
1160
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1161
+ address: this.context.address,
1162
+ };
343
1163
  return await this.view.callStatic.acceptOwnership({
344
1164
  blockTag: this.context.blockNumber,
345
1165
  ...overrides,
346
- });
1166
+ }, this.context.preparedData, ethCallContext);
347
1167
  },
348
1168
  async confirmAggregator(_aggregator, overrides) {
1169
+ const ethCallContext = {
1170
+ chainId: this.context.chainId,
1171
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1172
+ address: this.context.address,
1173
+ };
349
1174
  return await this.view.callStatic.confirmAggregator(_aggregator, {
350
1175
  blockTag: this.context.blockNumber,
351
1176
  ...overrides,
352
- });
1177
+ }, this.context.preparedData, ethCallContext);
353
1178
  },
354
1179
  async proposeAggregator(_aggregator, overrides) {
1180
+ const ethCallContext = {
1181
+ chainId: this.context.chainId,
1182
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1183
+ address: this.context.address,
1184
+ };
355
1185
  return await this.view.callStatic.proposeAggregator(_aggregator, {
356
1186
  blockTag: this.context.blockNumber,
357
1187
  ...overrides,
358
- });
1188
+ }, this.context.preparedData, ethCallContext);
359
1189
  },
360
1190
  async setController(_accessController, overrides) {
1191
+ const ethCallContext = {
1192
+ chainId: this.context.chainId,
1193
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1194
+ address: this.context.address,
1195
+ };
361
1196
  return await this.view.callStatic.setController(_accessController, {
362
1197
  blockTag: this.context.blockNumber,
363
1198
  ...overrides,
364
- });
1199
+ }, this.context.preparedData, ethCallContext);
365
1200
  },
366
1201
  async transferOwnership(_to, overrides) {
1202
+ const ethCallContext = {
1203
+ chainId: this.context.chainId,
1204
+ blockTag: "0x" + this.context.blockNumber.toString(16),
1205
+ address: this.context.address,
1206
+ };
367
1207
  return await this.view.callStatic.transferOwnership(_to, {
368
1208
  blockTag: this.context.blockNumber,
369
1209
  ...overrides,
1210
+ }, this.context.preparedData, ethCallContext);
1211
+ },
1212
+ };
1213
+ encodeCall = {
1214
+ view: this.view,
1215
+ context: this.context,
1216
+ acceptOwnership(overrides) {
1217
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1218
+ const address = this.context.address;
1219
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1220
+ if (overrides?.blockTag) {
1221
+ blockTag =
1222
+ typeof overrides.blockTag == "string"
1223
+ ? overrides.blockTag
1224
+ : "0x" + overrides.blockTag.toString(16);
1225
+ }
1226
+ return this.view.encodeCall.acceptOwnership({
1227
+ chainId,
1228
+ address,
1229
+ blockTag,
1230
+ });
1231
+ },
1232
+ accessController(overrides) {
1233
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1234
+ const address = this.context.address;
1235
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1236
+ if (overrides?.blockTag) {
1237
+ blockTag =
1238
+ typeof overrides.blockTag == "string"
1239
+ ? overrides.blockTag
1240
+ : "0x" + overrides.blockTag.toString(16);
1241
+ }
1242
+ return this.view.encodeCall.accessController({
1243
+ chainId,
1244
+ address,
1245
+ blockTag,
1246
+ });
1247
+ },
1248
+ aggregator(overrides) {
1249
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1250
+ const address = this.context.address;
1251
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1252
+ if (overrides?.blockTag) {
1253
+ blockTag =
1254
+ typeof overrides.blockTag == "string"
1255
+ ? overrides.blockTag
1256
+ : "0x" + overrides.blockTag.toString(16);
1257
+ }
1258
+ return this.view.encodeCall.aggregator({ chainId, address, blockTag });
1259
+ },
1260
+ confirmAggregator(_aggregator, overrides) {
1261
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1262
+ const address = this.context.address;
1263
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1264
+ if (overrides?.blockTag) {
1265
+ blockTag =
1266
+ typeof overrides.blockTag == "string"
1267
+ ? overrides.blockTag
1268
+ : "0x" + overrides.blockTag.toString(16);
1269
+ }
1270
+ return this.view.encodeCall.confirmAggregator(_aggregator, {
1271
+ chainId,
1272
+ address,
1273
+ blockTag,
370
1274
  });
371
1275
  },
1276
+ decimals(overrides) {
1277
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1278
+ const address = this.context.address;
1279
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1280
+ if (overrides?.blockTag) {
1281
+ blockTag =
1282
+ typeof overrides.blockTag == "string"
1283
+ ? overrides.blockTag
1284
+ : "0x" + overrides.blockTag.toString(16);
1285
+ }
1286
+ return this.view.encodeCall.decimals({ chainId, address, blockTag });
1287
+ },
1288
+ description(overrides) {
1289
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1290
+ const address = this.context.address;
1291
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1292
+ if (overrides?.blockTag) {
1293
+ blockTag =
1294
+ typeof overrides.blockTag == "string"
1295
+ ? overrides.blockTag
1296
+ : "0x" + overrides.blockTag.toString(16);
1297
+ }
1298
+ return this.view.encodeCall.description({ chainId, address, blockTag });
1299
+ },
1300
+ getAnswer(_roundId, overrides) {
1301
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1302
+ const address = this.context.address;
1303
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1304
+ if (overrides?.blockTag) {
1305
+ blockTag =
1306
+ typeof overrides.blockTag == "string"
1307
+ ? overrides.blockTag
1308
+ : "0x" + overrides.blockTag.toString(16);
1309
+ }
1310
+ return this.view.encodeCall.getAnswer(_roundId, {
1311
+ chainId,
1312
+ address,
1313
+ blockTag,
1314
+ });
1315
+ },
1316
+ getRoundData(_roundId, overrides) {
1317
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1318
+ const address = this.context.address;
1319
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1320
+ if (overrides?.blockTag) {
1321
+ blockTag =
1322
+ typeof overrides.blockTag == "string"
1323
+ ? overrides.blockTag
1324
+ : "0x" + overrides.blockTag.toString(16);
1325
+ }
1326
+ return this.view.encodeCall.getRoundData(_roundId, {
1327
+ chainId,
1328
+ address,
1329
+ blockTag,
1330
+ });
1331
+ },
1332
+ getTimestamp(_roundId, overrides) {
1333
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1334
+ const address = this.context.address;
1335
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1336
+ if (overrides?.blockTag) {
1337
+ blockTag =
1338
+ typeof overrides.blockTag == "string"
1339
+ ? overrides.blockTag
1340
+ : "0x" + overrides.blockTag.toString(16);
1341
+ }
1342
+ return this.view.encodeCall.getTimestamp(_roundId, {
1343
+ chainId,
1344
+ address,
1345
+ blockTag,
1346
+ });
1347
+ },
1348
+ latestAnswer(overrides) {
1349
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1350
+ const address = this.context.address;
1351
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1352
+ if (overrides?.blockTag) {
1353
+ blockTag =
1354
+ typeof overrides.blockTag == "string"
1355
+ ? overrides.blockTag
1356
+ : "0x" + overrides.blockTag.toString(16);
1357
+ }
1358
+ return this.view.encodeCall.latestAnswer({ chainId, address, blockTag });
1359
+ },
1360
+ latestRound(overrides) {
1361
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1362
+ const address = this.context.address;
1363
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1364
+ if (overrides?.blockTag) {
1365
+ blockTag =
1366
+ typeof overrides.blockTag == "string"
1367
+ ? overrides.blockTag
1368
+ : "0x" + overrides.blockTag.toString(16);
1369
+ }
1370
+ return this.view.encodeCall.latestRound({ chainId, address, blockTag });
1371
+ },
1372
+ latestRoundData(overrides) {
1373
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1374
+ const address = this.context.address;
1375
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1376
+ if (overrides?.blockTag) {
1377
+ blockTag =
1378
+ typeof overrides.blockTag == "string"
1379
+ ? overrides.blockTag
1380
+ : "0x" + overrides.blockTag.toString(16);
1381
+ }
1382
+ return this.view.encodeCall.latestRoundData({
1383
+ chainId,
1384
+ address,
1385
+ blockTag,
1386
+ });
1387
+ },
1388
+ latestTimestamp(overrides) {
1389
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1390
+ const address = this.context.address;
1391
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1392
+ if (overrides?.blockTag) {
1393
+ blockTag =
1394
+ typeof overrides.blockTag == "string"
1395
+ ? overrides.blockTag
1396
+ : "0x" + overrides.blockTag.toString(16);
1397
+ }
1398
+ return this.view.encodeCall.latestTimestamp({
1399
+ chainId,
1400
+ address,
1401
+ blockTag,
1402
+ });
1403
+ },
1404
+ owner(overrides) {
1405
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1406
+ const address = this.context.address;
1407
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1408
+ if (overrides?.blockTag) {
1409
+ blockTag =
1410
+ typeof overrides.blockTag == "string"
1411
+ ? overrides.blockTag
1412
+ : "0x" + overrides.blockTag.toString(16);
1413
+ }
1414
+ return this.view.encodeCall.owner({ chainId, address, blockTag });
1415
+ },
1416
+ phaseAggregators(arg0, overrides) {
1417
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1418
+ const address = this.context.address;
1419
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1420
+ if (overrides?.blockTag) {
1421
+ blockTag =
1422
+ typeof overrides.blockTag == "string"
1423
+ ? overrides.blockTag
1424
+ : "0x" + overrides.blockTag.toString(16);
1425
+ }
1426
+ return this.view.encodeCall.phaseAggregators(arg0, {
1427
+ chainId,
1428
+ address,
1429
+ blockTag,
1430
+ });
1431
+ },
1432
+ phaseId(overrides) {
1433
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1434
+ const address = this.context.address;
1435
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1436
+ if (overrides?.blockTag) {
1437
+ blockTag =
1438
+ typeof overrides.blockTag == "string"
1439
+ ? overrides.blockTag
1440
+ : "0x" + overrides.blockTag.toString(16);
1441
+ }
1442
+ return this.view.encodeCall.phaseId({ chainId, address, blockTag });
1443
+ },
1444
+ proposeAggregator(_aggregator, overrides) {
1445
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1446
+ const address = this.context.address;
1447
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1448
+ if (overrides?.blockTag) {
1449
+ blockTag =
1450
+ typeof overrides.blockTag == "string"
1451
+ ? overrides.blockTag
1452
+ : "0x" + overrides.blockTag.toString(16);
1453
+ }
1454
+ return this.view.encodeCall.proposeAggregator(_aggregator, {
1455
+ chainId,
1456
+ address,
1457
+ blockTag,
1458
+ });
1459
+ },
1460
+ proposedAggregator(overrides) {
1461
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1462
+ const address = this.context.address;
1463
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1464
+ if (overrides?.blockTag) {
1465
+ blockTag =
1466
+ typeof overrides.blockTag == "string"
1467
+ ? overrides.blockTag
1468
+ : "0x" + overrides.blockTag.toString(16);
1469
+ }
1470
+ return this.view.encodeCall.proposedAggregator({
1471
+ chainId,
1472
+ address,
1473
+ blockTag,
1474
+ });
1475
+ },
1476
+ proposedGetRoundData(_roundId, overrides) {
1477
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1478
+ const address = this.context.address;
1479
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1480
+ if (overrides?.blockTag) {
1481
+ blockTag =
1482
+ typeof overrides.blockTag == "string"
1483
+ ? overrides.blockTag
1484
+ : "0x" + overrides.blockTag.toString(16);
1485
+ }
1486
+ return this.view.encodeCall.proposedGetRoundData(_roundId, {
1487
+ chainId,
1488
+ address,
1489
+ blockTag,
1490
+ });
1491
+ },
1492
+ proposedLatestRoundData(overrides) {
1493
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1494
+ const address = this.context.address;
1495
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1496
+ if (overrides?.blockTag) {
1497
+ blockTag =
1498
+ typeof overrides.blockTag == "string"
1499
+ ? overrides.blockTag
1500
+ : "0x" + overrides.blockTag.toString(16);
1501
+ }
1502
+ return this.view.encodeCall.proposedLatestRoundData({
1503
+ chainId,
1504
+ address,
1505
+ blockTag,
1506
+ });
1507
+ },
1508
+ setController(_accessController, overrides) {
1509
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1510
+ const address = this.context.address;
1511
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1512
+ if (overrides?.blockTag) {
1513
+ blockTag =
1514
+ typeof overrides.blockTag == "string"
1515
+ ? overrides.blockTag
1516
+ : "0x" + overrides.blockTag.toString(16);
1517
+ }
1518
+ return this.view.encodeCall.setController(_accessController, {
1519
+ chainId,
1520
+ address,
1521
+ blockTag,
1522
+ });
1523
+ },
1524
+ transferOwnership(_to, overrides) {
1525
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1526
+ const address = this.context.address;
1527
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1528
+ if (overrides?.blockTag) {
1529
+ blockTag =
1530
+ typeof overrides.blockTag == "string"
1531
+ ? overrides.blockTag
1532
+ : "0x" + overrides.blockTag.toString(16);
1533
+ }
1534
+ return this.view.encodeCall.transferOwnership(_to, {
1535
+ chainId,
1536
+ address,
1537
+ blockTag,
1538
+ });
1539
+ },
1540
+ version(overrides) {
1541
+ const chainId = overrides?.chainId?.toString() ?? this.context.chainId.toString();
1542
+ const address = this.context.address;
1543
+ let blockTag = "0x" + this.context.blockNumber.toString(16);
1544
+ if (overrides?.blockTag) {
1545
+ blockTag =
1546
+ typeof overrides.blockTag == "string"
1547
+ ? overrides.blockTag
1548
+ : "0x" + overrides.blockTag.toString(16);
1549
+ }
1550
+ return this.view.encodeCall.version({ chainId, address, blockTag });
1551
+ },
372
1552
  };
373
1553
  }
374
1554
  export class EACAggregatorProxyProcessor extends BaseProcessor {