OCT_YDL.sol

OCT -> On-Chain Treasury

Introduction

This contract converts assets and forwards them to the YDL.

State Variables

TypeNameDescription

address

GBL

The ZivoeGlobals contract.

Sections

Read Functions

Write Functions

Events

Read Functions

canPush()

Permission for owner to call pushToLocker(). See ZivoeLocker.sol

 function canPush() public override pure returns (bool) { return true; }

canPushMulti()

Permission for owner to call pushToLockerMulti(). See ZivoeLocker.sol

 function canPushMulti() public override pure returns (bool) { return true; }

canPull()

Permission for owner to call pullFromLocker(). See ZivoeLocker.sol

function canPull() public override pure returns (bool) { return true; }

canPullMulti()

Permission for owner to call pullFromLockerMulti(). See ZivoeLocker.sol

 function canPullMulti() public override pure returns (bool) { return true; }

canPullPartial()

Permission for owner to call pullFromLockerPartial(). See ZivoeLocker.sol

function canPullPartial() public override pure returns (bool) { return true; }

canPullPartialMulti()

Permission for owner to call pullFromLockerMultiPartial(). See ZivoeLocker.sol

 function canPullPartialMulti() public override pure returns (bool) { return true; }

Write Functions

convertAndForward()

Converts an asset to YDL.distributedAsset() and forwards it.

function convertAndForward(address asset, bytes calldata data) external; 
TypeNameDescription

address

asset

The asset to convert.

bytes

data

The payload containing conversion data, consumed by 1INCH_V5.

Emits the AssetConvertedForwarded() event

Events

AssetConvertedForwarded()

Emitted during convertAndForward()

event AssetConvertedForwarded(
    address indexed asset, 
    address indexed distributedAsset, 
    uint256 amountFrom, 
    uint256 amountTo
);
TypeIndexedNameDescription

address

True

asset

The "asset" being converted.

address

True

distributedAsset

The ERC20 that we are converting "asset" to, based on YDL.distributedAsset().

uint256

False

amountFrom

The amount being converted.

uint256

False

amountTo

The amount of distibutedAsset received.

Last updated

Zivoe Finance - Official Documentation