注意: このページはまだ日本語に翻訳されていません。以下は英語の原文です。A contract method on a Contract.
Extends
BaseContractMethod<A,R,D>
Extended by
Type parameters
| Type parameter | Value |
|---|---|
A extends any[] | any[] |
R | any |
D extends R | ContractTransactionResponse | R | ContractTransactionResponse |
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to call the method with. |
Returns
Promise<D>
A promise resolving to the result of the call.
Source
contract/types.ts:206Properties
| Property | Type | Description | Inherited from |
|---|---|---|---|
fragment | FunctionFragment | The fragment of the Contract method. This will throw on ambiguous method names. | BaseContractMethod.fragment |
name | string | The name of the Contract method. | BaseContractMethod.name |
Methods
estimateGas()
args.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to call the method with. |
Returns
Promise<bigint>
A promise resolving to the estimated gas.
Inherited from
BaseContractMethod.estimateGas
Source
contract/types.ts:190getFragment()
args. This can be used to resolve ambiguous method names.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to constrain the fragment by. |
Returns
FunctionFragment
The constrained fragment.
Inherited from
BaseContractMethod.getFragment
Source
contract/types.ts:155populateTransaction()
args.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to populate the transaction with. |
Returns
Promise<ContractTransaction>
A promise resolving to the populated transaction.
Inherited from
BaseContractMethod.populateTransaction
Source
contract/types.ts:163send()
args.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to call the method with. |
Returns
Promise<ContractTransactionResponse>
A promise resolving to the transaction response.
Inherited from
BaseContractMethod.send
Source
contract/types.ts:182staticCall()
args and return the value.
If the return value is a single type, it will be dereferenced and returned directly, otherwise the full Result
will be returned.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to call the method with. |
Returns
Promise<R>
A promise resolving to the result of the static call.
Inherited from
BaseContractMethod.staticCall
Source
contract/types.ts:174staticCallResult()
args and return the Result without any dereferencing.
Parameters
| Parameter | Type | Description |
|---|---|---|
…args | ContractMethodArgs<A> | The arguments to call the method with. |
Returns
Promise<Result>
A promise resolving to the Result of the static call.
Inherited from
BaseContractMethod.staticCallResult
