LogoLogo
User DocsDeveloper DocsHow-To Guides
  • ➡️Start Here
  • 🚧Disclaimer
  • User Docs
    • Introduction
    • Fund Overview
    • zVLT
    • Tranches
    • ZVE Token
  • How-To Guides
    • Complete KYC/KYB
    • Mint Tranche Tokens
    • Stake Tranche Tokens
  • Developer Docs
    • Contract Addresses
    • Core Contracts
      • ZivoeDAO.sol
      • ZivoeGlobals.sol
      • ZivoeGovernorV2.sol
      • ZivoeITO.sol
      • ZivoeLocker.sol
      • ZivoeMath.sol
      • ZivoeRewards.sol
      • ZivoeRewardsVesting.sol
      • ZivoeToken.sol
      • ZivoeTranches.sol
      • ZivoeTrancheToken.sol
      • ZivoeYDL.sol
    • Lockers
      • OCC_Modular.sol
      • OCE_ZVE.sol
      • OCL_ZVE.sol
      • OCR_Modular.sol
      • OCT_DAO.sol
      • OCT_YDL.sol
      • OCT_ZVL.sol
      • OCY_Convex_A.sol
      • OCY_Convex_B.sol
      • OCY_Convex_C.sol
      • OCY_OUSD.sol
      • ZivoeSwapper.sol
  • Official Links
    • Audits
    • Website
    • Twitter
    • Telegram
    • Blog
    • Discord
  • Terms
    • Terms Of Use / Privacy Policy
    • Reg S Compliance
Powered by GitBook

Zivoe Finance - Official Documentation

On this page
  • Introduction
  • Sections
  • Read Functions
  • Write Functions
  • Events
  1. Developer Docs
  2. Lockers

OCT_DAO.sol

OCT -> On-Chain Treasury

PreviousOCR_Modular.solNextOCT_YDL.sol

Last updated 10 months ago

Introduction

This contract converts assets and forwards them to the DAO.

State Variables

Type
Name
Description

address

GBL

The ZivoeGlobals contract.

Sections

Read Functions

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

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

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

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

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

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

Write Functions

  • convertAndForward() - Converts an asset and forwards it to the DAO.

Events

  • AssetConvertedForwarded()

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 and forwards it to the DAO.

function convertAndForward(
    address asset, 
    address toAsset, 
    bytes calldata data
) external nonReentrant;
Type
Name
Description

address

asset

The asset to convert.

uint256

toAsset

The ERC20 that we are converting "asset" to.

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 toAsset, 
    uint256 amountFrom, 
    uint256 amountTo
);
Type
Indexed
Name
Description

address

True

asset

The "asset" being converted.

address

True

toAsset

The ERC20 that we are converting "asset" to.

uint256

False

amountFrom

The amount being converted.

uint256

False

amountTo

The amount received from conversion.