DirectDepositor
Inherits: MachinePeriphery, SanctionsList, Whitelist, IDirectDepositor
Functions
constructor
constructor(address _registry, address _sanctionsOracle)
MachinePeriphery(_registry)
SanctionsList(_sanctionsOracle);Parameters
| Name | Type | Description |
|---|---|---|
| _registry | address | |
| _sanctionsOracle | address |
initialize
function initialize(bytes calldata data) external virtual override initializer;Parameters
| Name | Type | Description |
|---|---|---|
| data | bytes |
deposit
Deposits accounting tokens into the machine and mints shares to the receiver.
function deposit(uint256 assets, address receiver, uint256 minShares, bytes32 referralKey)
public
virtual
override
sanctionsCheck
whitelistCheck
returns (uint256);Parameters
| Name | Type | Description |
|---|---|---|
| assets | uint256 | The amount of accounting tokens to deposit. |
| receiver | address | The receiver of minted shares. |
| minShares | uint256 | The minimum amount of shares to be minted. |
| referralKey | bytes32 | The optional identifier used to track a referral source. |
Returns
| Name | Type | Description |
|---|---|---|
| <none> | uint256 | shares The amount of shares minted. |
setWhitelistStatus
Enables or disables the whitelist.
function setWhitelistStatus(bool enabled) external override onlyRiskManager;Parameters
| Name | Type | Description |
|---|---|---|
| enabled | bool | True to enable the whitelist, false to disable. |
setWhitelistedUsers
Whitelists or unwhitelists a list of users.
function setWhitelistedUsers(address[] calldata users, bool whitelisted) external override onlyRiskManager;Parameters
| Name | Type | Description |
|---|---|---|
| users | address[] | The addresses of the users to update. |
| whitelisted | bool | True to whitelist the users, false to unwhitelist. |
setSanctionsCheckStatus
Enables or disables sanctions screening.
function setSanctionsCheckStatus(bool enabled) external override onlyRiskManager;Parameters
| Name | Type | Description |
|---|---|---|
| enabled | bool | True to enable screening, false to disable. |