Skip to main content

EthConnectAdapter

@bosonprotocol/eth-connect-sdk / Exports / EthConnectAdapter

Class: EthConnectAdapter

Web3LibAdapter implementation targeting eth-connect in a Decentraland environment.

Implements

  • Web3LibAdapter

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new EthConnectAdapter(requestManager, externalFeatures)

Parameters

NameType
requestManagerRequestManager
externalFeaturesExternalFeatures

Defined in

src/eth-connect-adapter.ts:26

Properties

_externalFeatures

Private _externalFeatures: ExternalFeatures

Defined in

src/eth-connect-adapter.ts:22


_requestManager

Private _requestManager: RequestManager

Defined in

src/eth-connect-adapter.ts:21


receiptData

Static Private receiptData: Map<string, { from: string ; to: string }>

Defined in

src/eth-connect-adapter.ts:24

Methods

_wait

Private _wait(txHash, receiptData, confirmations?): Promise<TransactionReceipt>

Parameters

NameType
txHashstring
receiptDataObject
receiptData.fromstring
receiptData.tostring
confirmations?number

Returns

Promise<TransactionReceipt>

Defined in

src/eth-connect-adapter.ts:100


call

call(transactionRequest): Promise<string>

Parameters

NameType
transactionRequestPartial<{ data: string ; from: string ; gasLimit: BigNumberish ; gasPrice: BigNumberish ; nonce: number ; to: string ; value: BigNumberish }>

Returns

Promise<string>

Implementation of

Web3LibAdapter.call

Defined in

src/eth-connect-adapter.ts:82


getBalance

getBalance(addressOrName, blockNumber?): Promise<string>

Parameters

NameType
addressOrNamestring
blockNumber?string | number

Returns

Promise<string>

Implementation of

Web3LibAdapter.getBalance

Defined in

src/eth-connect-adapter.ts:49


getChainId

getChainId(): Promise<number>

Returns

Promise<number>

Implementation of

Web3LibAdapter.getChainId

Defined in

src/eth-connect-adapter.ts:44


getSignerAddress

getSignerAddress(): Promise<string>

Returns

Promise<string>

Implementation of

Web3LibAdapter.getSignerAddress

Defined in

src/eth-connect-adapter.ts:34


getTransactionReceipt

getTransactionReceipt(txHash, receiptData?): Promise<TransactionReceipt>

Parameters

NameType
txHashany
receiptData?Object
receiptData.fromstring
receiptData.tostring

Returns

Promise<TransactionReceipt>

Implementation of

Web3LibAdapter.getTransactionReceipt

Defined in

src/eth-connect-adapter.ts:138


send

send(rpcMethod, payload): Promise<string>

Parameters

NameType
rpcMethodstring
payloadunknown[]

Returns

Promise<string>

Implementation of

Web3LibAdapter.send

Defined in

src/eth-connect-adapter.ts:93


sendTransaction

sendTransaction(transactionRequest): Promise<TransactionResponse>

Parameters

NameType
transactionRequestPartial<{ data: string ; from: string ; gasLimit: BigNumberish ; gasPrice: BigNumberish ; nonce: number ; to: string ; value: BigNumberish }>

Returns

Promise<TransactionResponse>

Implementation of

Web3LibAdapter.sendTransaction

Defined in

src/eth-connect-adapter.ts:60