// SPDX-License-Identifier: MIT pragma solidity ^0.8.20; // @dev Import the 'MessagingFee' and 'MessagingReceipt' so it's exposed to OApp implementers // solhint-disable-next-line no-unused-import import { MessagingParams, MessagingFee, MessagingReceipt } from "@layerzerolabs/lz-evm-protocol-v2/contracts/interfaces/ILayerZeroEndpointV2.sol"; // @dev Import the 'Origin' so it's exposed to OApp implementers // solhint-disable-next-line no-unused-import import { OAppReceiver, Origin } from "@layerzerolabs/oapp-evm/contracts/oapp/OAppReceiver.sol"; import { OAppCore } from "@layerzerolabs/oapp-evm/contracts/oapp/OAppCore.sol"; import { OAppSenderAlt, OAppSender } from "./OAppSenderAlt.sol"; /** * @title OAppAlt * @dev Abstract contract serving as the base for OAppAlt implementation, combining OAppSenderAlt and OAppReceiver functionality. * @dev This is used to interact with LayerZero's EndpointV2Alt */ abstract contract OAppAlt is OAppSenderAlt, OAppReceiver { /** * @dev Constructor to initialize the OAppAlt with the provided alt-endpoint and owner. * @param _endpoint The address of the LOCAL LayerZero endpoint. * @param _delegate The delegate capable of making OApp configurations inside of the endpoint. */ constructor(address _endpoint, address _delegate) OAppCore(_endpoint, _delegate) {} /** * @notice Retrieves the OAppAlt version information. * @return senderVersion The version of the OAppSenderAlt.sol implementation. * @return receiverVersion The version of the OAppReceiver.sol implementation. */ function oAppVersion() public pure virtual override(OAppSender, OAppReceiver) returns (uint64 senderVersion, uint64 receiverVersion) { return (SENDER_VERSION, RECEIVER_VERSION); } }