1
1
package client
2
2
3
3
import (
4
- bytes "bytes"
5
- context "context"
4
+ "bytes"
5
+ "context"
6
6
contract "erc20/contract"
7
- fmt "fmt"
7
+ "fmt"
8
8
9
9
address "github.com/filecoin-project/go-address"
10
10
abi "github.com/filecoin-project/go-state-types/abi"
@@ -13,7 +13,7 @@ import (
13
13
init8 "github.com/filecoin-project/specs-actors/v8/actors/builtin/init"
14
14
actors "github.com/filecoin-project/venus/venus-shared/actors"
15
15
types "github.com/filecoin-project/venus/venus-shared/types"
16
- types2 "github.com/ipfs-force-community/go-fvm-sdk/sdk/types"
16
+ sdkTypes "github.com/ipfs-force-community/go-fvm-sdk/sdk/types"
17
17
cid "github.com/ipfs/go-cid"
18
18
typegen "github.com/whyrusleeping/cbor-gen"
19
19
@@ -31,9 +31,9 @@ type IErc20TokenClient interface {
31
31
32
32
Constructor (context.Context , * contract.ConstructorReq ) error
33
33
34
- GetName (context.Context ) (types2 .CborString , error )
34
+ GetName (context.Context ) (sdkTypes .CborString , error )
35
35
36
- GetSymbol (context.Context ) (types2 .CborString , error )
36
+ GetSymbol (context.Context ) (sdkTypes .CborString , error )
37
37
38
38
GetDecimal (context.Context ) (typegen.CborInt , error )
39
39
@@ -208,7 +208,7 @@ func (c *Erc20TokenClient) Constructor(ctx context.Context, p0 *contract.Constru
208
208
return nil
209
209
}
210
210
211
- func (c * Erc20TokenClient ) GetName (ctx context.Context ) (types2 .CborString , error ) {
211
+ func (c * Erc20TokenClient ) GetName (ctx context.Context ) (sdkTypes .CborString , error ) {
212
212
if c .actor == address .Undef {
213
213
return "" , fmt .Errorf ("unset actor address for call" )
214
214
}
@@ -239,14 +239,14 @@ func (c *Erc20TokenClient) GetName(ctx context.Context) (types2.CborString, erro
239
239
return "" , fmt .Errorf ("expect get result for call" )
240
240
}
241
241
242
- result := new (types2 .CborString )
242
+ result := new (sdkTypes .CborString )
243
243
result .UnmarshalCBOR (bytes .NewReader (wait .Receipt .Return ))
244
244
245
245
return * result , nil
246
246
247
247
}
248
248
249
- func (c * Erc20TokenClient ) GetSymbol (ctx context.Context ) (types2 .CborString , error ) {
249
+ func (c * Erc20TokenClient ) GetSymbol (ctx context.Context ) (sdkTypes .CborString , error ) {
250
250
if c .actor == address .Undef {
251
251
return "" , fmt .Errorf ("unset actor address for call" )
252
252
}
@@ -277,7 +277,7 @@ func (c *Erc20TokenClient) GetSymbol(ctx context.Context) (types2.CborString, er
277
277
return "" , fmt .Errorf ("expect get result for call" )
278
278
}
279
279
280
- result := new (types2 .CborString )
280
+ result := new (sdkTypes .CborString )
281
281
result .UnmarshalCBOR (bytes .NewReader (wait .Receipt .Return ))
282
282
283
283
return * result , nil
0 commit comments