FM_DepositVault_v1
Inherits: IFundingManager_v1, IFM_DepositVault_v1, Module_v1
Author: Inverter Network
This contract allows users to deposit tokens to fund the workflow.
Implements {IFundingManager_v1} interface.
State Variables
BPS
Base Points used for percentage calculation. This value represents 100%.
_token
The token that is deposited.
__gap
Storage gap for future upgrades.
Public Functions
supportsInterface
See {IERC165-supportsInterface}.
init
token
Returns the token.
Returns
<none>
IERC20
The token.
deposit
Deposits a specified amount of tokens into the contract from the sender's account.
When using the {TransactionForwarder_v1}, validate transaction success to prevent nonce exploitation and ensure transaction integrity.
Parameters
amount
uint256
The number of tokens to deposit.
transferOrchestratorToken
Transfer a specified amount of Tokens to a designated receiver address.
This function MUST be restricted to be called only by the {Orchestrator_v1}.
Parameters
to
address
The address that will receive the tokens.
amount
uint256
The amount of tokens to be transfered.
Internal Functions
_processProtocolFeeViaTransfer
Transfer protocol fees to the treasury.
Parameters
treasury_
address
The address of the protocol treasury.
token_
IERC20
The token to transfer the fees from.
feeAmount_
uint256
The amount of fees to transfer.
_validateRecipient
Validates the recipient address.
Last updated