@sentio/sdk 2.25.0-rc.2 → 2.25.0-rc.4
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.
- package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js +23 -23
- package/lib/eth/builtin/internal/eacaggregatorproxy-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc1155-processor.js +8 -8
- package/lib/eth/builtin/internal/erc1155-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc20-processor.js +18 -18
- package/lib/eth/builtin/internal/erc20-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc20bytes-processor.js +9 -9
- package/lib/eth/builtin/internal/erc20bytes-processor.js.map +1 -1
- package/lib/eth/builtin/internal/erc721-processor.js +14 -14
- package/lib/eth/builtin/internal/erc721-processor.js.map +1 -1
- package/lib/eth/builtin/internal/weth9-processor.js +11 -11
- package/lib/eth/builtin/internal/weth9-processor.js.map +1 -1
- package/lib/eth/codegen/function-calls.js +5 -5
- package/lib/eth/codegen/function-calls.js.map +1 -1
- package/package.json +12 -12
- package/src/eth/builtin/internal/eacaggregatorproxy-processor.ts +23 -23
- package/src/eth/builtin/internal/erc1155-processor.ts +8 -8
- package/src/eth/builtin/internal/erc20-processor.ts +18 -18
- package/src/eth/builtin/internal/erc20bytes-processor.ts +9 -9
- package/src/eth/builtin/internal/erc721-processor.ts +14 -14
- package/src/eth/builtin/internal/weth9-processor.ts +11 -11
- package/src/eth/codegen/function-calls.ts +9 -9
@@ -129,7 +129,6 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
129
129
|
id: BigNumberish,
|
130
130
|
overrides?: Overrides
|
131
131
|
): Promise<bigint> {
|
132
|
-
const stack = new Error().stack;
|
133
132
|
try {
|
134
133
|
return await this.contract.getFunction("balanceOf(address,uint256)")(
|
135
134
|
account,
|
@@ -137,6 +136,7 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
137
136
|
overrides || {}
|
138
137
|
);
|
139
138
|
} catch (e) {
|
139
|
+
const stack = new Error().stack;
|
140
140
|
throw transformEtherError(e, undefined, stack);
|
141
141
|
}
|
142
142
|
}
|
@@ -146,12 +146,12 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
146
146
|
ids: BigNumberish[],
|
147
147
|
overrides?: Overrides
|
148
148
|
): Promise<bigint[]> {
|
149
|
-
const stack = new Error().stack;
|
150
149
|
try {
|
151
150
|
return await this.contract.getFunction(
|
152
151
|
"balanceOfBatch(address[],uint256[])"
|
153
152
|
)(accounts, ids, overrides || {});
|
154
153
|
} catch (e) {
|
154
|
+
const stack = new Error().stack;
|
155
155
|
throw transformEtherError(e, undefined, stack);
|
156
156
|
}
|
157
157
|
}
|
@@ -161,12 +161,12 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
161
161
|
operator: string,
|
162
162
|
overrides?: Overrides
|
163
163
|
): Promise<boolean> {
|
164
|
-
const stack = new Error().stack;
|
165
164
|
try {
|
166
165
|
return await this.contract.getFunction(
|
167
166
|
"isApprovedForAll(address,address)"
|
168
167
|
)(account, operator, overrides || {});
|
169
168
|
} catch (e) {
|
169
|
+
const stack = new Error().stack;
|
170
170
|
throw transformEtherError(e, undefined, stack);
|
171
171
|
}
|
172
172
|
}
|
@@ -175,25 +175,25 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
175
175
|
interfaceId: BytesLike,
|
176
176
|
overrides?: Overrides
|
177
177
|
): Promise<boolean> {
|
178
|
-
const stack = new Error().stack;
|
179
178
|
try {
|
180
179
|
return await this.contract.getFunction("supportsInterface(bytes4)")(
|
181
180
|
interfaceId,
|
182
181
|
overrides || {}
|
183
182
|
);
|
184
183
|
} catch (e) {
|
184
|
+
const stack = new Error().stack;
|
185
185
|
throw transformEtherError(e, undefined, stack);
|
186
186
|
}
|
187
187
|
}
|
188
188
|
|
189
189
|
async uri(id: BigNumberish, overrides?: Overrides): Promise<string> {
|
190
|
-
const stack = new Error().stack;
|
191
190
|
try {
|
192
191
|
return await this.contract.getFunction("uri(uint256)")(
|
193
192
|
id,
|
194
193
|
overrides || {}
|
195
194
|
);
|
196
195
|
} catch (e) {
|
196
|
+
const stack = new Error().stack;
|
197
197
|
throw transformEtherError(e, undefined, stack);
|
198
198
|
}
|
199
199
|
}
|
@@ -209,7 +209,6 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
209
209
|
data: BytesLike,
|
210
210
|
overrides?: Overrides
|
211
211
|
): Promise<void> {
|
212
|
-
const stack = new Error().stack;
|
213
212
|
try {
|
214
213
|
return await this.contract
|
215
214
|
.getFunction(
|
@@ -217,6 +216,7 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
217
216
|
)
|
218
217
|
.staticCall(from, to, ids, amounts, data, overrides || {});
|
219
218
|
} catch (e) {
|
219
|
+
const stack = new Error().stack;
|
220
220
|
throw transformEtherError(e, undefined, stack);
|
221
221
|
}
|
222
222
|
},
|
@@ -228,7 +228,6 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
228
228
|
data: BytesLike,
|
229
229
|
overrides?: Overrides
|
230
230
|
): Promise<void> {
|
231
|
-
const stack = new Error().stack;
|
232
231
|
try {
|
233
232
|
return await this.contract
|
234
233
|
.getFunction(
|
@@ -236,6 +235,7 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
236
235
|
)
|
237
236
|
.staticCall(from, to, id, amount, data, overrides || {});
|
238
237
|
} catch (e) {
|
238
|
+
const stack = new Error().stack;
|
239
239
|
throw transformEtherError(e, undefined, stack);
|
240
240
|
}
|
241
241
|
},
|
@@ -244,12 +244,12 @@ export class ERC1155ContractView extends ContractView<ERC1155> {
|
|
244
244
|
approved: boolean,
|
245
245
|
overrides?: Overrides
|
246
246
|
): Promise<void> {
|
247
|
-
const stack = new Error().stack;
|
248
247
|
try {
|
249
248
|
return await this.contract
|
250
249
|
.getFunction("setApprovalForAll(address,bool)")
|
251
250
|
.staticCall(operator, approved, overrides || {});
|
252
251
|
} catch (e) {
|
252
|
+
const stack = new Error().stack;
|
253
253
|
throw transformEtherError(e, undefined, stack);
|
254
254
|
}
|
255
255
|
},
|
@@ -175,7 +175,6 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
175
175
|
spender: string,
|
176
176
|
overrides?: Overrides
|
177
177
|
): Promise<bigint> {
|
178
|
-
const stack = new Error().stack;
|
179
178
|
try {
|
180
179
|
return await this.contract.getFunction("allowance(address,address)")(
|
181
180
|
owner,
|
@@ -183,72 +182,73 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
183
182
|
overrides || {}
|
184
183
|
);
|
185
184
|
} catch (e) {
|
185
|
+
const stack = new Error().stack;
|
186
186
|
throw transformEtherError(e, undefined, stack);
|
187
187
|
}
|
188
188
|
}
|
189
189
|
|
190
190
|
async balanceOf(account: string, overrides?: Overrides): Promise<bigint> {
|
191
|
-
const stack = new Error().stack;
|
192
191
|
try {
|
193
192
|
return await this.contract.getFunction("balanceOf(address)")(
|
194
193
|
account,
|
195
194
|
overrides || {}
|
196
195
|
);
|
197
196
|
} catch (e) {
|
197
|
+
const stack = new Error().stack;
|
198
198
|
throw transformEtherError(e, undefined, stack);
|
199
199
|
}
|
200
200
|
}
|
201
201
|
|
202
202
|
async decimals(overrides?: Overrides): Promise<bigint> {
|
203
|
-
const stack = new Error().stack;
|
204
203
|
try {
|
205
204
|
return await this.contract.getFunction("decimals()")(overrides || {});
|
206
205
|
} catch (e) {
|
206
|
+
const stack = new Error().stack;
|
207
207
|
throw transformEtherError(e, undefined, stack);
|
208
208
|
}
|
209
209
|
}
|
210
210
|
|
211
211
|
async locker(overrides?: Overrides): Promise<string> {
|
212
|
-
const stack = new Error().stack;
|
213
212
|
try {
|
214
213
|
return await this.contract.getFunction("locker()")(overrides || {});
|
215
214
|
} catch (e) {
|
215
|
+
const stack = new Error().stack;
|
216
216
|
throw transformEtherError(e, undefined, stack);
|
217
217
|
}
|
218
218
|
}
|
219
219
|
|
220
220
|
async name(overrides?: Overrides): Promise<string> {
|
221
|
-
const stack = new Error().stack;
|
222
221
|
try {
|
223
222
|
return await this.contract.getFunction("name()")(overrides || {});
|
224
223
|
} catch (e) {
|
224
|
+
const stack = new Error().stack;
|
225
225
|
throw transformEtherError(e, undefined, stack);
|
226
226
|
}
|
227
227
|
}
|
228
228
|
|
229
229
|
async owner(overrides?: Overrides): Promise<string> {
|
230
|
-
const stack = new Error().stack;
|
231
230
|
try {
|
232
231
|
return await this.contract.getFunction("owner()")(overrides || {});
|
233
232
|
} catch (e) {
|
233
|
+
const stack = new Error().stack;
|
234
234
|
throw transformEtherError(e, undefined, stack);
|
235
235
|
}
|
236
236
|
}
|
237
237
|
|
238
238
|
async symbol(overrides?: Overrides): Promise<string> {
|
239
|
-
const stack = new Error().stack;
|
240
239
|
try {
|
241
240
|
return await this.contract.getFunction("symbol()")(overrides || {});
|
242
241
|
} catch (e) {
|
242
|
+
const stack = new Error().stack;
|
243
243
|
throw transformEtherError(e, undefined, stack);
|
244
244
|
}
|
245
245
|
}
|
246
246
|
|
247
247
|
async totalSupply(overrides?: Overrides): Promise<bigint> {
|
248
|
-
const stack = new Error().stack;
|
249
248
|
try {
|
250
249
|
return await this.contract.getFunction("totalSupply()")(overrides || {});
|
251
250
|
} catch (e) {
|
251
|
+
const stack = new Error().stack;
|
252
252
|
throw transformEtherError(e, undefined, stack);
|
253
253
|
}
|
254
254
|
}
|
@@ -261,22 +261,22 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
261
261
|
amount: BigNumberish,
|
262
262
|
overrides?: Overrides
|
263
263
|
): Promise<boolean> {
|
264
|
-
const stack = new Error().stack;
|
265
264
|
try {
|
266
265
|
return await this.contract
|
267
266
|
.getFunction("approve(address,uint256)")
|
268
267
|
.staticCall(spender, amount, overrides || {});
|
269
268
|
} catch (e) {
|
269
|
+
const stack = new Error().stack;
|
270
270
|
throw transformEtherError(e, undefined, stack);
|
271
271
|
}
|
272
272
|
},
|
273
273
|
async burn(amount: BigNumberish, overrides?: Overrides): Promise<void> {
|
274
|
-
const stack = new Error().stack;
|
275
274
|
try {
|
276
275
|
return await this.contract
|
277
276
|
.getFunction("burn(uint256)")
|
278
277
|
.staticCall(amount, overrides || {});
|
279
278
|
} catch (e) {
|
279
|
+
const stack = new Error().stack;
|
280
280
|
throw transformEtherError(e, undefined, stack);
|
281
281
|
}
|
282
282
|
},
|
@@ -285,12 +285,12 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
285
285
|
amount: BigNumberish,
|
286
286
|
overrides?: Overrides
|
287
287
|
): Promise<void> {
|
288
|
-
const stack = new Error().stack;
|
289
288
|
try {
|
290
289
|
return await this.contract
|
291
290
|
.getFunction("burnFrom(address,uint256)")
|
292
291
|
.staticCall(account, amount, overrides || {});
|
293
292
|
} catch (e) {
|
293
|
+
const stack = new Error().stack;
|
294
294
|
throw transformEtherError(e, undefined, stack);
|
295
295
|
}
|
296
296
|
},
|
@@ -299,12 +299,12 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
299
299
|
subtractedValue: BigNumberish,
|
300
300
|
overrides?: Overrides
|
301
301
|
): Promise<boolean> {
|
302
|
-
const stack = new Error().stack;
|
303
302
|
try {
|
304
303
|
return await this.contract
|
305
304
|
.getFunction("decreaseAllowance(address,uint256)")
|
306
305
|
.staticCall(spender, subtractedValue, overrides || {});
|
307
306
|
} catch (e) {
|
307
|
+
const stack = new Error().stack;
|
308
308
|
throw transformEtherError(e, undefined, stack);
|
309
309
|
}
|
310
310
|
},
|
@@ -313,32 +313,32 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
313
313
|
addedValue: BigNumberish,
|
314
314
|
overrides?: Overrides
|
315
315
|
): Promise<boolean> {
|
316
|
-
const stack = new Error().stack;
|
317
316
|
try {
|
318
317
|
return await this.contract
|
319
318
|
.getFunction("increaseAllowance(address,uint256)")
|
320
319
|
.staticCall(spender, addedValue, overrides || {});
|
321
320
|
} catch (e) {
|
321
|
+
const stack = new Error().stack;
|
322
322
|
throw transformEtherError(e, undefined, stack);
|
323
323
|
}
|
324
324
|
},
|
325
325
|
async renounceOwnership(overrides?: Overrides): Promise<void> {
|
326
|
-
const stack = new Error().stack;
|
327
326
|
try {
|
328
327
|
return await this.contract
|
329
328
|
.getFunction("renounceOwnership()")
|
330
329
|
.staticCall(overrides || {});
|
331
330
|
} catch (e) {
|
331
|
+
const stack = new Error().stack;
|
332
332
|
throw transformEtherError(e, undefined, stack);
|
333
333
|
}
|
334
334
|
},
|
335
335
|
async setLocker(_locker: string, overrides?: Overrides): Promise<void> {
|
336
|
-
const stack = new Error().stack;
|
337
336
|
try {
|
338
337
|
return await this.contract
|
339
338
|
.getFunction("setLocker(address)")
|
340
339
|
.staticCall(_locker, overrides || {});
|
341
340
|
} catch (e) {
|
341
|
+
const stack = new Error().stack;
|
342
342
|
throw transformEtherError(e, undefined, stack);
|
343
343
|
}
|
344
344
|
},
|
@@ -347,12 +347,12 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
347
347
|
amount: BigNumberish,
|
348
348
|
overrides?: Overrides
|
349
349
|
): Promise<boolean> {
|
350
|
-
const stack = new Error().stack;
|
351
350
|
try {
|
352
351
|
return await this.contract
|
353
352
|
.getFunction("transfer(address,uint256)")
|
354
353
|
.staticCall(recipient, amount, overrides || {});
|
355
354
|
} catch (e) {
|
355
|
+
const stack = new Error().stack;
|
356
356
|
throw transformEtherError(e, undefined, stack);
|
357
357
|
}
|
358
358
|
},
|
@@ -362,12 +362,12 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
362
362
|
amount: BigNumberish,
|
363
363
|
overrides?: Overrides
|
364
364
|
): Promise<boolean> {
|
365
|
-
const stack = new Error().stack;
|
366
365
|
try {
|
367
366
|
return await this.contract
|
368
367
|
.getFunction("transferFrom(address,address,uint256)")
|
369
368
|
.staticCall(sender, recipient, amount, overrides || {});
|
370
369
|
} catch (e) {
|
370
|
+
const stack = new Error().stack;
|
371
371
|
throw transformEtherError(e, undefined, stack);
|
372
372
|
}
|
373
373
|
},
|
@@ -375,12 +375,12 @@ export class ERC20ContractView extends ContractView<ERC20> {
|
|
375
375
|
newOwner: string,
|
376
376
|
overrides?: Overrides
|
377
377
|
): Promise<void> {
|
378
|
-
const stack = new Error().stack;
|
379
378
|
try {
|
380
379
|
return await this.contract
|
381
380
|
.getFunction("transferOwnership(address)")
|
382
381
|
.staticCall(newOwner, overrides || {});
|
383
382
|
} catch (e) {
|
383
|
+
const stack = new Error().stack;
|
384
384
|
throw transformEtherError(e, undefined, stack);
|
385
385
|
}
|
386
386
|
},
|
@@ -103,49 +103,49 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
103
103
|
}
|
104
104
|
|
105
105
|
async name(overrides?: Overrides): Promise<string> {
|
106
|
-
const stack = new Error().stack;
|
107
106
|
try {
|
108
107
|
return await this.contract.getFunction("name()")(overrides || {});
|
109
108
|
} catch (e) {
|
109
|
+
const stack = new Error().stack;
|
110
110
|
throw transformEtherError(e, undefined, stack);
|
111
111
|
}
|
112
112
|
}
|
113
113
|
|
114
114
|
async totalSupply(overrides?: Overrides): Promise<bigint> {
|
115
|
-
const stack = new Error().stack;
|
116
115
|
try {
|
117
116
|
return await this.contract.getFunction("totalSupply()")(overrides || {});
|
118
117
|
} catch (e) {
|
118
|
+
const stack = new Error().stack;
|
119
119
|
throw transformEtherError(e, undefined, stack);
|
120
120
|
}
|
121
121
|
}
|
122
122
|
|
123
123
|
async decimals(overrides?: Overrides): Promise<bigint> {
|
124
|
-
const stack = new Error().stack;
|
125
124
|
try {
|
126
125
|
return await this.contract.getFunction("decimals()")(overrides || {});
|
127
126
|
} catch (e) {
|
127
|
+
const stack = new Error().stack;
|
128
128
|
throw transformEtherError(e, undefined, stack);
|
129
129
|
}
|
130
130
|
}
|
131
131
|
|
132
132
|
async balanceOf(who: string, overrides?: Overrides): Promise<bigint> {
|
133
|
-
const stack = new Error().stack;
|
134
133
|
try {
|
135
134
|
return await this.contract.getFunction("balanceOf(address)")(
|
136
135
|
who,
|
137
136
|
overrides || {}
|
138
137
|
);
|
139
138
|
} catch (e) {
|
139
|
+
const stack = new Error().stack;
|
140
140
|
throw transformEtherError(e, undefined, stack);
|
141
141
|
}
|
142
142
|
}
|
143
143
|
|
144
144
|
async symbol(overrides?: Overrides): Promise<string> {
|
145
|
-
const stack = new Error().stack;
|
146
145
|
try {
|
147
146
|
return await this.contract.getFunction("symbol()")(overrides || {});
|
148
147
|
} catch (e) {
|
148
|
+
const stack = new Error().stack;
|
149
149
|
throw transformEtherError(e, undefined, stack);
|
150
150
|
}
|
151
151
|
}
|
@@ -155,7 +155,6 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
155
155
|
spender: string,
|
156
156
|
overrides?: Overrides
|
157
157
|
): Promise<bigint> {
|
158
|
-
const stack = new Error().stack;
|
159
158
|
try {
|
160
159
|
return await this.contract.getFunction("allowance(address,address)")(
|
161
160
|
owner,
|
@@ -163,6 +162,7 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
163
162
|
overrides || {}
|
164
163
|
);
|
165
164
|
} catch (e) {
|
165
|
+
const stack = new Error().stack;
|
166
166
|
throw transformEtherError(e, undefined, stack);
|
167
167
|
}
|
168
168
|
}
|
@@ -175,12 +175,12 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
175
175
|
value: BigNumberish,
|
176
176
|
overrides?: Overrides
|
177
177
|
): Promise<boolean> {
|
178
|
-
const stack = new Error().stack;
|
179
178
|
try {
|
180
179
|
return await this.contract
|
181
180
|
.getFunction("approve(address,uint256)")
|
182
181
|
.staticCall(spender, value, overrides || {});
|
183
182
|
} catch (e) {
|
183
|
+
const stack = new Error().stack;
|
184
184
|
throw transformEtherError(e, undefined, stack);
|
185
185
|
}
|
186
186
|
},
|
@@ -190,12 +190,12 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
190
190
|
value: BigNumberish,
|
191
191
|
overrides?: Overrides
|
192
192
|
): Promise<boolean> {
|
193
|
-
const stack = new Error().stack;
|
194
193
|
try {
|
195
194
|
return await this.contract
|
196
195
|
.getFunction("transferFrom(address,address,uint256)")
|
197
196
|
.staticCall(from, to, value, overrides || {});
|
198
197
|
} catch (e) {
|
198
|
+
const stack = new Error().stack;
|
199
199
|
throw transformEtherError(e, undefined, stack);
|
200
200
|
}
|
201
201
|
},
|
@@ -204,12 +204,12 @@ export class ERC20BytesContractView extends ContractView<ERC20Bytes> {
|
|
204
204
|
value: BigNumberish,
|
205
205
|
overrides?: Overrides
|
206
206
|
): Promise<boolean> {
|
207
|
-
const stack = new Error().stack;
|
208
207
|
try {
|
209
208
|
return await this.contract
|
210
209
|
.getFunction("transfer(address,uint256)")
|
211
210
|
.staticCall(to, value, overrides || {});
|
212
211
|
} catch (e) {
|
212
|
+
const stack = new Error().stack;
|
213
213
|
throw transformEtherError(e, undefined, stack);
|
214
214
|
}
|
215
215
|
},
|
@@ -155,22 +155,22 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
155
155
|
}
|
156
156
|
|
157
157
|
async totalSupply(overrides?: Overrides): Promise<bigint> {
|
158
|
-
const stack = new Error().stack;
|
159
158
|
try {
|
160
159
|
return await this.contract.getFunction("totalSupply()")(overrides || {});
|
161
160
|
} catch (e) {
|
161
|
+
const stack = new Error().stack;
|
162
162
|
throw transformEtherError(e, undefined, stack);
|
163
163
|
}
|
164
164
|
}
|
165
165
|
|
166
166
|
async balanceOf(owner: string, overrides?: Overrides): Promise<bigint> {
|
167
|
-
const stack = new Error().stack;
|
168
167
|
try {
|
169
168
|
return await this.contract.getFunction("balanceOf(address)")(
|
170
169
|
owner,
|
171
170
|
overrides || {}
|
172
171
|
);
|
173
172
|
} catch (e) {
|
173
|
+
const stack = new Error().stack;
|
174
174
|
throw transformEtherError(e, undefined, stack);
|
175
175
|
}
|
176
176
|
}
|
@@ -179,13 +179,13 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
179
179
|
tokenId: BigNumberish,
|
180
180
|
overrides?: Overrides
|
181
181
|
): Promise<string> {
|
182
|
-
const stack = new Error().stack;
|
183
182
|
try {
|
184
183
|
return await this.contract.getFunction("getApproved(uint256)")(
|
185
184
|
tokenId,
|
186
185
|
overrides || {}
|
187
186
|
);
|
188
187
|
} catch (e) {
|
188
|
+
const stack = new Error().stack;
|
189
189
|
throw transformEtherError(e, undefined, stack);
|
190
190
|
}
|
191
191
|
}
|
@@ -195,33 +195,33 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
195
195
|
operator: string,
|
196
196
|
overrides?: Overrides
|
197
197
|
): Promise<boolean> {
|
198
|
-
const stack = new Error().stack;
|
199
198
|
try {
|
200
199
|
return await this.contract.getFunction(
|
201
200
|
"isApprovedForAll(address,address)"
|
202
201
|
)(owner, operator, overrides || {});
|
203
202
|
} catch (e) {
|
203
|
+
const stack = new Error().stack;
|
204
204
|
throw transformEtherError(e, undefined, stack);
|
205
205
|
}
|
206
206
|
}
|
207
207
|
|
208
208
|
async name(overrides?: Overrides): Promise<string> {
|
209
|
-
const stack = new Error().stack;
|
210
209
|
try {
|
211
210
|
return await this.contract.getFunction("name()")(overrides || {});
|
212
211
|
} catch (e) {
|
212
|
+
const stack = new Error().stack;
|
213
213
|
throw transformEtherError(e, undefined, stack);
|
214
214
|
}
|
215
215
|
}
|
216
216
|
|
217
217
|
async ownerOf(tokenId: BigNumberish, overrides?: Overrides): Promise<string> {
|
218
|
-
const stack = new Error().stack;
|
219
218
|
try {
|
220
219
|
return await this.contract.getFunction("ownerOf(uint256)")(
|
221
220
|
tokenId,
|
222
221
|
overrides || {}
|
223
222
|
);
|
224
223
|
} catch (e) {
|
224
|
+
const stack = new Error().stack;
|
225
225
|
throw transformEtherError(e, undefined, stack);
|
226
226
|
}
|
227
227
|
}
|
@@ -230,22 +230,22 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
230
230
|
interfaceId: BytesLike,
|
231
231
|
overrides?: Overrides
|
232
232
|
): Promise<boolean> {
|
233
|
-
const stack = new Error().stack;
|
234
233
|
try {
|
235
234
|
return await this.contract.getFunction("supportsInterface(bytes4)")(
|
236
235
|
interfaceId,
|
237
236
|
overrides || {}
|
238
237
|
);
|
239
238
|
} catch (e) {
|
239
|
+
const stack = new Error().stack;
|
240
240
|
throw transformEtherError(e, undefined, stack);
|
241
241
|
}
|
242
242
|
}
|
243
243
|
|
244
244
|
async symbol(overrides?: Overrides): Promise<string> {
|
245
|
-
const stack = new Error().stack;
|
246
245
|
try {
|
247
246
|
return await this.contract.getFunction("symbol()")(overrides || {});
|
248
247
|
} catch (e) {
|
248
|
+
const stack = new Error().stack;
|
249
249
|
throw transformEtherError(e, undefined, stack);
|
250
250
|
}
|
251
251
|
}
|
@@ -254,13 +254,13 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
254
254
|
tokenId: BigNumberish,
|
255
255
|
overrides?: Overrides
|
256
256
|
): Promise<string> {
|
257
|
-
const stack = new Error().stack;
|
258
257
|
try {
|
259
258
|
return await this.contract.getFunction("tokenURI(uint256)")(
|
260
259
|
tokenId,
|
261
260
|
overrides || {}
|
262
261
|
);
|
263
262
|
} catch (e) {
|
263
|
+
const stack = new Error().stack;
|
264
264
|
throw transformEtherError(e, undefined, stack);
|
265
265
|
}
|
266
266
|
}
|
@@ -273,12 +273,12 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
273
273
|
tokenId: BigNumberish,
|
274
274
|
overrides?: Overrides
|
275
275
|
): Promise<void> {
|
276
|
-
const stack = new Error().stack;
|
277
276
|
try {
|
278
277
|
return await this.contract
|
279
278
|
.getFunction("approve(address,uint256)")
|
280
279
|
.staticCall(to, tokenId, overrides || {});
|
281
280
|
} catch (e) {
|
281
|
+
const stack = new Error().stack;
|
282
282
|
throw transformEtherError(e, undefined, stack);
|
283
283
|
}
|
284
284
|
},
|
@@ -288,12 +288,12 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
288
288
|
tokenId: BigNumberish,
|
289
289
|
overrides?: Overrides
|
290
290
|
): Promise<void> {
|
291
|
-
const stack = new Error().stack;
|
292
291
|
try {
|
293
292
|
return await this.contract
|
294
293
|
.getFunction("safeTransferFrom(address,address,uint256)")
|
295
294
|
.staticCall(from, to, tokenId, overrides || {});
|
296
295
|
} catch (e) {
|
296
|
+
const stack = new Error().stack;
|
297
297
|
throw transformEtherError(e, undefined, stack);
|
298
298
|
}
|
299
299
|
},
|
@@ -304,12 +304,12 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
304
304
|
data: BytesLike,
|
305
305
|
overrides?: Overrides
|
306
306
|
): Promise<void> {
|
307
|
-
const stack = new Error().stack;
|
308
307
|
try {
|
309
308
|
return await this.contract
|
310
309
|
.getFunction("safeTransferFrom(address,address,uint256,bytes)")
|
311
310
|
.staticCall(from, to, tokenId, data, overrides || {});
|
312
311
|
} catch (e) {
|
312
|
+
const stack = new Error().stack;
|
313
313
|
throw transformEtherError(e, undefined, stack);
|
314
314
|
}
|
315
315
|
},
|
@@ -318,12 +318,12 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
318
318
|
_approved: boolean,
|
319
319
|
overrides?: Overrides
|
320
320
|
): Promise<void> {
|
321
|
-
const stack = new Error().stack;
|
322
321
|
try {
|
323
322
|
return await this.contract
|
324
323
|
.getFunction("setApprovalForAll(address,bool)")
|
325
324
|
.staticCall(operator, _approved, overrides || {});
|
326
325
|
} catch (e) {
|
326
|
+
const stack = new Error().stack;
|
327
327
|
throw transformEtherError(e, undefined, stack);
|
328
328
|
}
|
329
329
|
},
|
@@ -333,12 +333,12 @@ export class ERC721ContractView extends ContractView<ERC721> {
|
|
333
333
|
tokenId: BigNumberish,
|
334
334
|
overrides?: Overrides
|
335
335
|
): Promise<void> {
|
336
|
-
const stack = new Error().stack;
|
337
336
|
try {
|
338
337
|
return await this.contract
|
339
338
|
.getFunction("transferFrom(address,address,uint256)")
|
340
339
|
.staticCall(from, to, tokenId, overrides || {});
|
341
340
|
} catch (e) {
|
341
|
+
const stack = new Error().stack;
|
342
342
|
throw transformEtherError(e, undefined, stack);
|
343
343
|
}
|
344
344
|
},
|