Interface for communication with the L2BitcoinDepositor on-chain contract deployed on the given L2 chain.
▸ extraDataEncoder(): CrossChainExtraDataEncoder
Extra data encoder for this contract. The encoder is used to encode and decode the extra data included in the cross-chain deposit script.
src/lib/contracts/cross-chain.ts:92
▸ getChainIdentifier(): ChainIdentifier
Gets the chain-specific identifier of this contract.
src/lib/contracts/cross-chain.ts:72
▸ getDepositOwner(): undefined
| ChainIdentifier
Gets the identifier that should be used as the owner of the deposits issued by this contract.
undefined
| ChainIdentifier
The identifier of the deposit owner or undefined if not set.
src/lib/contracts/cross-chain.ts:79
▸ initializeDeposit(depositTx
, depositOutputIndex
, deposit
, vault?
): Promise
<Hex
>
Initializes the cross-chain deposit indirectly through the given L2 chain.
Name | Type | Description |
---|---|---|
depositTx |
BitcoinRawTxVectors |
Deposit transaction data |
depositOutputIndex |
number |
Index of the deposit transaction output that funds the revealed deposit |
deposit |
DepositReceipt |
Data of the revealed deposit |
vault? |
ChainIdentifier |
Optional parameter denoting the vault the given deposit should be routed to |
Promise
<Hex
>
Transaction hash of the reveal deposit transaction.
src/lib/contracts/cross-chain.ts:104
▸ setDepositOwner(depositOwner
): void
Sets the identifier that should be used as the owner of the deposits issued by this contract.
Name | Type | Description |
---|---|---|
depositOwner |
ChainIdentifier |
Identifier of the deposit owner or undefined to clear. |
void