{
    "Function": "_sendAndCall",
    "File": "contracts/OFT/OFTCoreV2.sol",
    "Parent Contracts": [
        "contracts/OFT/lzApp/NonblockingLzApp.sol",
        "contracts/OFT/lzApp/LzApp.sol",
        "contracts/OFT/interfaces/ILayerZeroUserApplicationConfig.sol",
        "contracts/OFT/interfaces/ILayerZeroReceiver.sol",
        "node_modules/@openzeppelin/contracts/access/Ownable.sol",
        "node_modules/@openzeppelin/contracts/utils/Context.sol"
    ],
    "High-Level Calls": [],
    "Internal Calls": [
        "require(bool,string)",
        "_encodeSendAndCallPayload",
        "_removeDust",
        "_ld2sd",
        "_checkAdapterParams",
        "_lzSend",
        "_debitFrom"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function _sendAndCall(address _from, uint16 _dstChainId, bytes32 _toAddress, uint _amount, bytes memory _payload, uint64 _dstGasForCall, address payable _refundAddress, address _zroPaymentAddress, bytes memory _adapterParams) internal virtual returns (uint amount) {\n        _checkAdapterParams(_dstChainId, PT_SEND_AND_CALL, _adapterParams, _dstGasForCall);\n\n        (amount,) = _removeDust(_amount);\n        amount = _debitFrom(_from, _dstChainId, _toAddress, amount);\n        require(amount > 0, \"OFTCore: amount too small\");\n\n        // encode the msg.sender into the payload instead of _from\n        bytes memory lzPayload = _encodeSendAndCallPayload(msg.sender, _toAddress, _ld2sd(amount), _payload, _dstGasForCall);\n        _lzSend(_dstChainId, lzPayload, _refundAddress, _zroPaymentAddress, _adapterParams, msg.value);\n\n        emit SendToChain(_dstChainId, _from, _toAddress, amount);\n    }"
}