@gitmyabi/nweth 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,956 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.NormalizerMethanewETH_json = exports.NormalizerMethanewETH_jsonAbi = void 0;
4
+ const viem_1 = require("viem");
5
+ /**
6
+ * NormalizerMethanewETH_json ABI
7
+ *
8
+ * This ABI is typed using viem's type system for full type safety.
9
+ */
10
+ exports.NormalizerMethanewETH_jsonAbi = [
11
+ {
12
+ "inputs": [],
13
+ "stateMutability": "nonpayable",
14
+ "type": "constructor"
15
+ },
16
+ {
17
+ "anonymous": false,
18
+ "inputs": [
19
+ {
20
+ "indexed": true,
21
+ "internalType": "address",
22
+ "name": "owner",
23
+ "type": "address"
24
+ },
25
+ {
26
+ "indexed": true,
27
+ "internalType": "address",
28
+ "name": "spender",
29
+ "type": "address"
30
+ },
31
+ {
32
+ "indexed": false,
33
+ "internalType": "uint256",
34
+ "name": "value",
35
+ "type": "uint256"
36
+ }
37
+ ],
38
+ "name": "Approval",
39
+ "type": "event"
40
+ },
41
+ {
42
+ "anonymous": false,
43
+ "inputs": [
44
+ {
45
+ "indexed": true,
46
+ "internalType": "address",
47
+ "name": "from",
48
+ "type": "address"
49
+ },
50
+ {
51
+ "indexed": true,
52
+ "internalType": "address",
53
+ "name": "to",
54
+ "type": "address"
55
+ },
56
+ {
57
+ "indexed": false,
58
+ "internalType": "uint256",
59
+ "name": "value",
60
+ "type": "uint256"
61
+ }
62
+ ],
63
+ "name": "Transfer",
64
+ "type": "event"
65
+ },
66
+ {
67
+ "inputs": [
68
+ {
69
+ "internalType": "uint256",
70
+ "name": "_amount",
71
+ "type": "uint256"
72
+ }
73
+ ],
74
+ "name": "BurnNToken",
75
+ "outputs": [],
76
+ "stateMutability": "nonpayable",
77
+ "type": "function"
78
+ },
79
+ {
80
+ "inputs": [
81
+ {
82
+ "internalType": "uint256",
83
+ "name": "_amount",
84
+ "type": "uint256"
85
+ }
86
+ ],
87
+ "name": "DepositFToken",
88
+ "outputs": [],
89
+ "stateMutability": "nonpayable",
90
+ "type": "function"
91
+ },
92
+ {
93
+ "inputs": [
94
+ {
95
+ "internalType": "address",
96
+ "name": "_addr",
97
+ "type": "address"
98
+ }
99
+ ],
100
+ "name": "GetMaximumNToken",
101
+ "outputs": [
102
+ {
103
+ "internalType": "uint256",
104
+ "name": "",
105
+ "type": "uint256"
106
+ }
107
+ ],
108
+ "stateMutability": "view",
109
+ "type": "function"
110
+ },
111
+ {
112
+ "inputs": [
113
+ {
114
+ "internalType": "uint256",
115
+ "name": "_amount",
116
+ "type": "uint256"
117
+ }
118
+ ],
119
+ "name": "MintNToken",
120
+ "outputs": [],
121
+ "stateMutability": "nonpayable",
122
+ "type": "function"
123
+ },
124
+ {
125
+ "inputs": [
126
+ {
127
+ "internalType": "uint256",
128
+ "name": "_d",
129
+ "type": "uint256"
130
+ },
131
+ {
132
+ "internalType": "uint256",
133
+ "name": "_m",
134
+ "type": "uint256"
135
+ }
136
+ ],
137
+ "name": "RealizeFToken",
138
+ "outputs": [],
139
+ "stateMutability": "nonpayable",
140
+ "type": "function"
141
+ },
142
+ {
143
+ "inputs": [
144
+ {
145
+ "internalType": "address",
146
+ "name": "_governance",
147
+ "type": "address"
148
+ }
149
+ ],
150
+ "name": "SetGovernance",
151
+ "outputs": [],
152
+ "stateMutability": "nonpayable",
153
+ "type": "function"
154
+ },
155
+ {
156
+ "inputs": [
157
+ {
158
+ "internalType": "uint256",
159
+ "name": "_overfillE18",
160
+ "type": "uint256"
161
+ }
162
+ ],
163
+ "name": "SetOverfillE18",
164
+ "outputs": [],
165
+ "stateMutability": "nonpayable",
166
+ "type": "function"
167
+ },
168
+ {
169
+ "inputs": [
170
+ {
171
+ "internalType": "uint256",
172
+ "name": "_w",
173
+ "type": "uint256"
174
+ },
175
+ {
176
+ "internalType": "uint256",
177
+ "name": "_b",
178
+ "type": "uint256"
179
+ }
180
+ ],
181
+ "name": "UnrealizeFToken",
182
+ "outputs": [],
183
+ "stateMutability": "nonpayable",
184
+ "type": "function"
185
+ },
186
+ {
187
+ "inputs": [
188
+ {
189
+ "internalType": "uint256",
190
+ "name": "_amount",
191
+ "type": "uint256"
192
+ }
193
+ ],
194
+ "name": "WithdrawFToken",
195
+ "outputs": [],
196
+ "stateMutability": "nonpayable",
197
+ "type": "function"
198
+ },
199
+ {
200
+ "inputs": [
201
+ {
202
+ "internalType": "address",
203
+ "name": "owner",
204
+ "type": "address"
205
+ },
206
+ {
207
+ "internalType": "address",
208
+ "name": "spender",
209
+ "type": "address"
210
+ }
211
+ ],
212
+ "name": "allowance",
213
+ "outputs": [
214
+ {
215
+ "internalType": "uint256",
216
+ "name": "",
217
+ "type": "uint256"
218
+ }
219
+ ],
220
+ "stateMutability": "view",
221
+ "type": "function"
222
+ },
223
+ {
224
+ "inputs": [
225
+ {
226
+ "internalType": "address",
227
+ "name": "spender",
228
+ "type": "address"
229
+ },
230
+ {
231
+ "internalType": "uint256",
232
+ "name": "amount",
233
+ "type": "uint256"
234
+ }
235
+ ],
236
+ "name": "approve",
237
+ "outputs": [
238
+ {
239
+ "internalType": "bool",
240
+ "name": "",
241
+ "type": "bool"
242
+ }
243
+ ],
244
+ "stateMutability": "nonpayable",
245
+ "type": "function"
246
+ },
247
+ {
248
+ "inputs": [
249
+ {
250
+ "internalType": "address",
251
+ "name": "account",
252
+ "type": "address"
253
+ }
254
+ ],
255
+ "name": "balanceOf",
256
+ "outputs": [
257
+ {
258
+ "internalType": "uint256",
259
+ "name": "",
260
+ "type": "uint256"
261
+ }
262
+ ],
263
+ "stateMutability": "view",
264
+ "type": "function"
265
+ },
266
+ {
267
+ "inputs": [],
268
+ "name": "decimals",
269
+ "outputs": [
270
+ {
271
+ "internalType": "uint8",
272
+ "name": "",
273
+ "type": "uint8"
274
+ }
275
+ ],
276
+ "stateMutability": "view",
277
+ "type": "function"
278
+ },
279
+ {
280
+ "inputs": [
281
+ {
282
+ "internalType": "address",
283
+ "name": "spender",
284
+ "type": "address"
285
+ },
286
+ {
287
+ "internalType": "uint256",
288
+ "name": "subtractedValue",
289
+ "type": "uint256"
290
+ }
291
+ ],
292
+ "name": "decreaseAllowance",
293
+ "outputs": [
294
+ {
295
+ "internalType": "bool",
296
+ "name": "",
297
+ "type": "bool"
298
+ }
299
+ ],
300
+ "stateMutability": "nonpayable",
301
+ "type": "function"
302
+ },
303
+ {
304
+ "inputs": [
305
+ {
306
+ "internalType": "address",
307
+ "name": "",
308
+ "type": "address"
309
+ }
310
+ ],
311
+ "name": "f",
312
+ "outputs": [
313
+ {
314
+ "internalType": "uint256",
315
+ "name": "",
316
+ "type": "uint256"
317
+ }
318
+ ],
319
+ "stateMutability": "view",
320
+ "type": "function"
321
+ },
322
+ {
323
+ "inputs": [],
324
+ "name": "governance",
325
+ "outputs": [
326
+ {
327
+ "internalType": "address",
328
+ "name": "",
329
+ "type": "address"
330
+ }
331
+ ],
332
+ "stateMutability": "view",
333
+ "type": "function"
334
+ },
335
+ {
336
+ "inputs": [
337
+ {
338
+ "internalType": "address",
339
+ "name": "spender",
340
+ "type": "address"
341
+ },
342
+ {
343
+ "internalType": "uint256",
344
+ "name": "addedValue",
345
+ "type": "uint256"
346
+ }
347
+ ],
348
+ "name": "increaseAllowance",
349
+ "outputs": [
350
+ {
351
+ "internalType": "bool",
352
+ "name": "",
353
+ "type": "bool"
354
+ }
355
+ ],
356
+ "stateMutability": "nonpayable",
357
+ "type": "function"
358
+ },
359
+ {
360
+ "inputs": [
361
+ {
362
+ "internalType": "address",
363
+ "name": "",
364
+ "type": "address"
365
+ }
366
+ ],
367
+ "name": "n",
368
+ "outputs": [
369
+ {
370
+ "internalType": "uint256",
371
+ "name": "",
372
+ "type": "uint256"
373
+ }
374
+ ],
375
+ "stateMutability": "view",
376
+ "type": "function"
377
+ },
378
+ {
379
+ "inputs": [],
380
+ "name": "name",
381
+ "outputs": [
382
+ {
383
+ "internalType": "string",
384
+ "name": "",
385
+ "type": "string"
386
+ }
387
+ ],
388
+ "stateMutability": "view",
389
+ "type": "function"
390
+ },
391
+ {
392
+ "inputs": [],
393
+ "name": "overfillE18",
394
+ "outputs": [
395
+ {
396
+ "internalType": "uint256",
397
+ "name": "",
398
+ "type": "uint256"
399
+ }
400
+ ],
401
+ "stateMutability": "view",
402
+ "type": "function"
403
+ },
404
+ {
405
+ "inputs": [],
406
+ "name": "symbol",
407
+ "outputs": [
408
+ {
409
+ "internalType": "string",
410
+ "name": "",
411
+ "type": "string"
412
+ }
413
+ ],
414
+ "stateMutability": "view",
415
+ "type": "function"
416
+ },
417
+ {
418
+ "inputs": [],
419
+ "name": "totalSupply",
420
+ "outputs": [
421
+ {
422
+ "internalType": "uint256",
423
+ "name": "",
424
+ "type": "uint256"
425
+ }
426
+ ],
427
+ "stateMutability": "view",
428
+ "type": "function"
429
+ },
430
+ {
431
+ "inputs": [
432
+ {
433
+ "internalType": "address",
434
+ "name": "recipient",
435
+ "type": "address"
436
+ },
437
+ {
438
+ "internalType": "uint256",
439
+ "name": "amount",
440
+ "type": "uint256"
441
+ }
442
+ ],
443
+ "name": "transfer",
444
+ "outputs": [
445
+ {
446
+ "internalType": "bool",
447
+ "name": "",
448
+ "type": "bool"
449
+ }
450
+ ],
451
+ "stateMutability": "nonpayable",
452
+ "type": "function"
453
+ },
454
+ {
455
+ "inputs": [
456
+ {
457
+ "internalType": "address",
458
+ "name": "sender",
459
+ "type": "address"
460
+ },
461
+ {
462
+ "internalType": "address",
463
+ "name": "recipient",
464
+ "type": "address"
465
+ },
466
+ {
467
+ "internalType": "uint256",
468
+ "name": "amount",
469
+ "type": "uint256"
470
+ }
471
+ ],
472
+ "name": "transferFrom",
473
+ "outputs": [
474
+ {
475
+ "internalType": "bool",
476
+ "name": "",
477
+ "type": "bool"
478
+ }
479
+ ],
480
+ "stateMutability": "nonpayable",
481
+ "type": "function"
482
+ },
483
+ {
484
+ "inputs": [],
485
+ "name": "underlying",
486
+ "outputs": [
487
+ {
488
+ "internalType": "contract IERC20",
489
+ "name": "",
490
+ "type": "address"
491
+ }
492
+ ],
493
+ "stateMutability": "view",
494
+ "type": "function"
495
+ }
496
+ ];
497
+ /**
498
+ * NormalizerMethanewETH_json Contract Class
499
+ *
500
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
501
+ *
502
+ * @example
503
+ * ```typescript
504
+ * import { createPublicClient, createWalletClient, http } from 'viem';
505
+ * import { mainnet } from 'viem/chains';
506
+ * import { NormalizerMethanewETH_json } from 'NormalizerMethanewETH_json';
507
+ *
508
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
509
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
510
+ *
511
+ * const contract = new NormalizerMethanewETH_json('0x...', { publicClient, walletClient });
512
+ *
513
+ * // Read functions
514
+ * const result = await contract.balanceOf('0x...');
515
+ *
516
+ * // Write functions
517
+ * const hash = await contract.transfer('0x...', 1000n);
518
+ *
519
+ * // Simulate transactions (dry-run)
520
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
521
+ * console.log('Gas estimate:', simulation.request.gas);
522
+ *
523
+ * // Watch events
524
+ * const unwatch = contract.watch.Transfer((event) => {
525
+ * console.log('Transfer event:', event);
526
+ * });
527
+ * ```
528
+ */
529
+ class NormalizerMethanewETH_json {
530
+ constructor(address, clients) {
531
+ this.contractAddress = address;
532
+ this.publicClient = clients.publicClient;
533
+ this.contract = (0, viem_1.getContract)({
534
+ address,
535
+ abi: exports.NormalizerMethanewETH_jsonAbi,
536
+ client: {
537
+ public: clients.publicClient,
538
+ wallet: clients.walletClient,
539
+ },
540
+ });
541
+ }
542
+ /**
543
+ * Get the contract address
544
+ */
545
+ get address() {
546
+ return this.contractAddress;
547
+ }
548
+ /**
549
+ * Get the underlying viem contract instance
550
+ */
551
+ getContract() {
552
+ return this.contract;
553
+ }
554
+ /**
555
+ * GetMaximumNToken
556
+ * view
557
+ */
558
+ async GetMaximumNToken(_addr) {
559
+ return this.contract.read.GetMaximumNToken([_addr]);
560
+ }
561
+ /**
562
+ * allowance
563
+ * view
564
+ */
565
+ async allowance(owner, spender) {
566
+ return this.contract.read.allowance([owner, spender]);
567
+ }
568
+ /**
569
+ * balanceOf
570
+ * view
571
+ */
572
+ async balanceOf(account) {
573
+ return this.contract.read.balanceOf([account]);
574
+ }
575
+ /**
576
+ * decimals
577
+ * view
578
+ */
579
+ async decimals() {
580
+ return this.contract.read.decimals();
581
+ }
582
+ /**
583
+ * f
584
+ * view
585
+ */
586
+ async f(arg0) {
587
+ return this.contract.read.f([arg0]);
588
+ }
589
+ /**
590
+ * governance
591
+ * view
592
+ */
593
+ async governance() {
594
+ return this.contract.read.governance();
595
+ }
596
+ /**
597
+ * n
598
+ * view
599
+ */
600
+ async n(arg0) {
601
+ return this.contract.read.n([arg0]);
602
+ }
603
+ /**
604
+ * name
605
+ * view
606
+ */
607
+ async name() {
608
+ return this.contract.read.name();
609
+ }
610
+ /**
611
+ * overfillE18
612
+ * view
613
+ */
614
+ async overfillE18() {
615
+ return this.contract.read.overfillE18();
616
+ }
617
+ /**
618
+ * symbol
619
+ * view
620
+ */
621
+ async symbol() {
622
+ return this.contract.read.symbol();
623
+ }
624
+ /**
625
+ * totalSupply
626
+ * view
627
+ */
628
+ async totalSupply() {
629
+ return this.contract.read.totalSupply();
630
+ }
631
+ /**
632
+ * underlying
633
+ * view
634
+ */
635
+ async underlying() {
636
+ return this.contract.read.underlying();
637
+ }
638
+ /**
639
+ * BurnNToken
640
+ * nonpayable
641
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
642
+ */
643
+ async BurnNToken(_amount, options) {
644
+ if (!this.contract.write) {
645
+ throw new Error('Wallet client is required for write operations');
646
+ }
647
+ return this.contract.write.BurnNToken([_amount], options);
648
+ }
649
+ /**
650
+ * DepositFToken
651
+ * nonpayable
652
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
653
+ */
654
+ async DepositFToken(_amount, options) {
655
+ if (!this.contract.write) {
656
+ throw new Error('Wallet client is required for write operations');
657
+ }
658
+ return this.contract.write.DepositFToken([_amount], options);
659
+ }
660
+ /**
661
+ * MintNToken
662
+ * nonpayable
663
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
664
+ */
665
+ async MintNToken(_amount, options) {
666
+ if (!this.contract.write) {
667
+ throw new Error('Wallet client is required for write operations');
668
+ }
669
+ return this.contract.write.MintNToken([_amount], options);
670
+ }
671
+ /**
672
+ * RealizeFToken
673
+ * nonpayable
674
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
675
+ */
676
+ async RealizeFToken(_d, _m, options) {
677
+ if (!this.contract.write) {
678
+ throw new Error('Wallet client is required for write operations');
679
+ }
680
+ return this.contract.write.RealizeFToken([_d, _m], options);
681
+ }
682
+ /**
683
+ * SetGovernance
684
+ * nonpayable
685
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
686
+ */
687
+ async SetGovernance(_governance, options) {
688
+ if (!this.contract.write) {
689
+ throw new Error('Wallet client is required for write operations');
690
+ }
691
+ return this.contract.write.SetGovernance([_governance], options);
692
+ }
693
+ /**
694
+ * SetOverfillE18
695
+ * nonpayable
696
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
697
+ */
698
+ async SetOverfillE18(_overfillE18, options) {
699
+ if (!this.contract.write) {
700
+ throw new Error('Wallet client is required for write operations');
701
+ }
702
+ return this.contract.write.SetOverfillE18([_overfillE18], options);
703
+ }
704
+ /**
705
+ * UnrealizeFToken
706
+ * nonpayable
707
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
708
+ */
709
+ async UnrealizeFToken(_w, _b, options) {
710
+ if (!this.contract.write) {
711
+ throw new Error('Wallet client is required for write operations');
712
+ }
713
+ return this.contract.write.UnrealizeFToken([_w, _b], options);
714
+ }
715
+ /**
716
+ * WithdrawFToken
717
+ * nonpayable
718
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
719
+ */
720
+ async WithdrawFToken(_amount, options) {
721
+ if (!this.contract.write) {
722
+ throw new Error('Wallet client is required for write operations');
723
+ }
724
+ return this.contract.write.WithdrawFToken([_amount], options);
725
+ }
726
+ /**
727
+ * approve
728
+ * nonpayable
729
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
730
+ */
731
+ async approve(spender, amount, options) {
732
+ if (!this.contract.write) {
733
+ throw new Error('Wallet client is required for write operations');
734
+ }
735
+ return this.contract.write.approve([spender, amount], options);
736
+ }
737
+ /**
738
+ * decreaseAllowance
739
+ * nonpayable
740
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
741
+ */
742
+ async decreaseAllowance(spender, subtractedValue, options) {
743
+ if (!this.contract.write) {
744
+ throw new Error('Wallet client is required for write operations');
745
+ }
746
+ return this.contract.write.decreaseAllowance([spender, subtractedValue], options);
747
+ }
748
+ /**
749
+ * increaseAllowance
750
+ * nonpayable
751
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
752
+ */
753
+ async increaseAllowance(spender, addedValue, options) {
754
+ if (!this.contract.write) {
755
+ throw new Error('Wallet client is required for write operations');
756
+ }
757
+ return this.contract.write.increaseAllowance([spender, addedValue], options);
758
+ }
759
+ /**
760
+ * transfer
761
+ * nonpayable
762
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
763
+ */
764
+ async transfer(recipient, amount, options) {
765
+ if (!this.contract.write) {
766
+ throw new Error('Wallet client is required for write operations');
767
+ }
768
+ return this.contract.write.transfer([recipient, amount], options);
769
+ }
770
+ /**
771
+ * transferFrom
772
+ * nonpayable
773
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
774
+ */
775
+ async transferFrom(sender, recipient, amount, options) {
776
+ if (!this.contract.write) {
777
+ throw new Error('Wallet client is required for write operations');
778
+ }
779
+ return this.contract.write.transferFrom([sender, recipient, amount], options);
780
+ }
781
+ /**
782
+ * Simulate contract write operations (dry-run without sending transaction)
783
+ *
784
+ * @example
785
+ * const result = await contract.simulate.transfer('0x...', 1000n);
786
+ * console.log('Gas estimate:', result.request.gas);
787
+ * console.log('Would succeed:', result.result);
788
+ */
789
+ get simulate() {
790
+ const contract = this.contract;
791
+ if (!contract.simulate) {
792
+ throw new Error('Public client is required for simulation');
793
+ }
794
+ return {
795
+ /**
796
+ * Simulate BurnNToken
797
+ * Returns gas estimate and result without sending transaction
798
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
799
+ */
800
+ async BurnNToken(_amount, options) {
801
+ return contract.simulate.BurnNToken([_amount], options);
802
+ },
803
+ /**
804
+ * Simulate DepositFToken
805
+ * Returns gas estimate and result without sending transaction
806
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
807
+ */
808
+ async DepositFToken(_amount, options) {
809
+ return contract.simulate.DepositFToken([_amount], options);
810
+ },
811
+ /**
812
+ * Simulate MintNToken
813
+ * Returns gas estimate and result without sending transaction
814
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
815
+ */
816
+ async MintNToken(_amount, options) {
817
+ return contract.simulate.MintNToken([_amount], options);
818
+ },
819
+ /**
820
+ * Simulate RealizeFToken
821
+ * Returns gas estimate and result without sending transaction
822
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
823
+ */
824
+ async RealizeFToken(_d, _m, options) {
825
+ return contract.simulate.RealizeFToken([_d, _m], options);
826
+ },
827
+ /**
828
+ * Simulate SetGovernance
829
+ * Returns gas estimate and result without sending transaction
830
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
831
+ */
832
+ async SetGovernance(_governance, options) {
833
+ return contract.simulate.SetGovernance([_governance], options);
834
+ },
835
+ /**
836
+ * Simulate SetOverfillE18
837
+ * Returns gas estimate and result without sending transaction
838
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
839
+ */
840
+ async SetOverfillE18(_overfillE18, options) {
841
+ return contract.simulate.SetOverfillE18([_overfillE18], options);
842
+ },
843
+ /**
844
+ * Simulate UnrealizeFToken
845
+ * Returns gas estimate and result without sending transaction
846
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
847
+ */
848
+ async UnrealizeFToken(_w, _b, options) {
849
+ return contract.simulate.UnrealizeFToken([_w, _b], options);
850
+ },
851
+ /**
852
+ * Simulate WithdrawFToken
853
+ * Returns gas estimate and result without sending transaction
854
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
855
+ */
856
+ async WithdrawFToken(_amount, options) {
857
+ return contract.simulate.WithdrawFToken([_amount], options);
858
+ },
859
+ /**
860
+ * Simulate approve
861
+ * Returns gas estimate and result without sending transaction
862
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
863
+ */
864
+ async approve(spender, amount, options) {
865
+ return contract.simulate.approve([spender, amount], options);
866
+ },
867
+ /**
868
+ * Simulate decreaseAllowance
869
+ * Returns gas estimate and result without sending transaction
870
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
871
+ */
872
+ async decreaseAllowance(spender, subtractedValue, options) {
873
+ return contract.simulate.decreaseAllowance([spender, subtractedValue], options);
874
+ },
875
+ /**
876
+ * Simulate increaseAllowance
877
+ * Returns gas estimate and result without sending transaction
878
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
879
+ */
880
+ async increaseAllowance(spender, addedValue, options) {
881
+ return contract.simulate.increaseAllowance([spender, addedValue], options);
882
+ },
883
+ /**
884
+ * Simulate transfer
885
+ * Returns gas estimate and result without sending transaction
886
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
887
+ */
888
+ async transfer(recipient, amount, options) {
889
+ return contract.simulate.transfer([recipient, amount], options);
890
+ },
891
+ /**
892
+ * Simulate transferFrom
893
+ * Returns gas estimate and result without sending transaction
894
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
895
+ */
896
+ async transferFrom(sender, recipient, amount, options) {
897
+ return contract.simulate.transferFrom([sender, recipient, amount], options);
898
+ }
899
+ };
900
+ }
901
+ /**
902
+ * Watch contract events
903
+ *
904
+ * @example
905
+ * // Watch all Transfer events
906
+ * const unwatch = contract.watch.Transfer((event) => {
907
+ * console.log('Transfer:', event);
908
+ * });
909
+ *
910
+ * // Stop watching
911
+ * unwatch();
912
+ */
913
+ get watch() {
914
+ return {
915
+ /**
916
+ * Watch Approval events
917
+ * @param callback Function to call when event is emitted
918
+ * @param filter Optional filter for indexed parameters
919
+ * @returns Unwatch function to stop listening
920
+ */
921
+ Approval: (callback, filter) => {
922
+ return this.publicClient.watchContractEvent({
923
+ address: this.contractAddress,
924
+ abi: exports.NormalizerMethanewETH_jsonAbi,
925
+ eventName: 'Approval',
926
+ args: filter,
927
+ onLogs: (logs) => {
928
+ logs.forEach((log) => {
929
+ callback(log.args);
930
+ });
931
+ },
932
+ });
933
+ },
934
+ /**
935
+ * Watch Transfer events
936
+ * @param callback Function to call when event is emitted
937
+ * @param filter Optional filter for indexed parameters
938
+ * @returns Unwatch function to stop listening
939
+ */
940
+ Transfer: (callback, filter) => {
941
+ return this.publicClient.watchContractEvent({
942
+ address: this.contractAddress,
943
+ abi: exports.NormalizerMethanewETH_jsonAbi,
944
+ eventName: 'Transfer',
945
+ args: filter,
946
+ onLogs: (logs) => {
947
+ logs.forEach((log) => {
948
+ callback(log.args);
949
+ });
950
+ },
951
+ });
952
+ }
953
+ };
954
+ }
955
+ }
956
+ exports.NormalizerMethanewETH_json = NormalizerMethanewETH_json;