Skip to content

IFluidPauseAuthDex ​

Git Source

Title: Fluid Pause Auth DEX Interface

Interface for the DEX-layer pause auth helper used by FluidPauseAuth. DEX user pause is side-level: a whole side toggles the pool's pause bit, borrow without payback freezes the user's borrow limits (restored by the matching unpause), and the other half-side shapes revert PauseAuthDex__PartialSideNotSupported.

Functions ​

pauseVault ​

Pauses selected vault operations at the DEX layer.

solidity
function pauseVault(uint256 vaultId_, bool pauseSupply_, bool pauseWithdraw_, bool pauseBorrow_, bool pausePayback_)
    external
    returns (address vault_, bool actedSupply_, bool actedWithdraw_, bool actedBorrow_, bool actedPayback_);

Parameters

NameTypeDescription
vaultId_uint256Vault ID to pause.
pauseSupply_boolWhether to pause supply/deposit operations.
pauseWithdraw_boolWhether to pause withdraw operations.
pauseBorrow_boolWhether to pause borrow operations.
pausePayback_boolWhether to pause payback operations.

Returns

NameTypeDescription
vault_addressResolved vault address.
actedSupply_boolWhether supply/deposit pause state changed.
actedWithdraw_boolWhether withdraw pause state changed.
actedBorrow_boolWhether borrow state changed (pause bit, or limits freeze for borrow-only).
actedPayback_boolWhether payback pause state changed.

unpauseVault ​

Unpauses selected vault operations at the DEX layer.

solidity
function unpauseVault(
    uint256 vaultId_,
    bool unpauseSupply_,
    bool unpauseWithdraw_,
    bool unpauseBorrow_,
    bool unpausePayback_
) external returns (address vault_, bool actedSupply_, bool actedWithdraw_, bool actedBorrow_, bool actedPayback_);

Parameters

NameTypeDescription
vaultId_uint256Vault ID to unpause.
unpauseSupply_boolWhether to unpause supply/deposit operations.
unpauseWithdraw_boolWhether to unpause withdraw operations.
unpauseBorrow_boolWhether to unpause borrow operations.
unpausePayback_boolWhether to unpause payback operations.

Returns

NameTypeDescription
vault_addressResolved vault address.
actedSupply_boolWhether supply/deposit unpause state changed.
actedWithdraw_boolWhether withdraw unpause state changed.
actedBorrow_boolWhether borrow state changed (pause bit, or frozen limits restored).
actedPayback_boolWhether payback unpause state changed.

pauseSwapAndArbitrage ​

Pauses swap and arbitrage on a DEX pool.

solidity
function pauseSwapAndArbitrage(uint256 dexId_) external returns (address dex_, bool acted_);

Parameters

NameTypeDescription
dexId_uint256DEX ID to pause.

Returns

NameTypeDescription
dex_addressResolved DEX address.
acted_boolWhether swap and arbitrage pause state changed.

unpauseSwapAndArbitrage ​

Unpauses swap and arbitrage on a DEX pool.

solidity
function unpauseSwapAndArbitrage(uint256 dexId_) external returns (address dex_, bool acted_);

Parameters

NameTypeDescription
dexId_uint256DEX ID to unpause.

Returns

NameTypeDescription
dex_addressResolved DEX address.
acted_boolWhether swap and arbitrage unpause state changed.

pauseSmartLending ​

Pauses the smart lending contract on a DEX pool; both flags must be set, else 100143.

solidity
function pauseSmartLending(uint256 dexId_, bool pauseSupply_, bool pauseWithdraw_)
    external
    returns (address dex_, address smartLending_, bool actedSupply_, bool actedWithdraw_);

Parameters

NameTypeDescription
dexId_uint256DEX ID whose smart lending contract should be paused.
pauseSupply_boolWhether to pause smart lending supply/deposit operations.
pauseWithdraw_boolWhether to pause smart lending withdraw operations.

Returns

NameTypeDescription
dex_addressResolved DEX address.
smartLending_addressResolved smart lending address.
actedSupply_boolWhether smart lending supply/deposit pause state changed.
actedWithdraw_boolWhether smart lending withdraw pause state changed.

unpauseSmartLending ​

Unpauses the smart lending contract on a DEX pool; both flags must be set, else 100143.

solidity
function unpauseSmartLending(uint256 dexId_, bool unpauseSupply_, bool unpauseWithdraw_)
    external
    returns (address dex_, address smartLending_, bool actedSupply_, bool actedWithdraw_);

Parameters

NameTypeDescription
dexId_uint256DEX ID whose smart lending contract should be unpaused.
unpauseSupply_boolWhether to unpause smart lending supply/deposit operations.
unpauseWithdraw_boolWhether to unpause smart lending withdraw operations.

Returns

NameTypeDescription
dex_addressResolved DEX address.
smartLending_addressResolved smart lending address.
actedSupply_boolWhether smart lending supply/deposit unpause state changed.
actedWithdraw_boolWhether smart lending withdraw unpause state changed.

pauseUser ​

Pauses a user's selected operations on a DEX pool. Reverts PauseAuthDex__InvalidParams if a requested side has no row on the pool.

solidity
function pauseUser(
    uint256 dexId_,
    address user_,
    bool pauseSupply_,
    bool pauseWithdraw_,
    bool pauseBorrow_,
    bool pausePayback_
) external returns (address dex_, bool actedSupply_, bool actedWithdraw_, bool actedBorrow_, bool actedPayback_);

Parameters

NameTypeDescription
dexId_uint256DEX ID where the user should be paused.
user_addressUser address to pause on the DEX.
pauseSupply_boolWhether to pause supply/deposit operations.
pauseWithdraw_boolWhether to pause withdraw operations.
pauseBorrow_boolWhether to pause borrow operations.
pausePayback_boolWhether to pause payback operations.

Returns

NameTypeDescription
dex_addressResolved DEX address.
actedSupply_boolWhether supply/deposit pause state changed.
actedWithdraw_boolWhether withdraw pause state changed.
actedBorrow_boolWhether borrow state changed (pause bit, or limits freeze for borrow-only).
actedPayback_boolWhether payback pause state changed.

unpauseUser ​

Unpauses a user's selected operations on a DEX pool. Reverts PauseAuthDex__InvalidParams if a requested side has no row on the pool.

solidity
function unpauseUser(
    uint256 dexId_,
    address user_,
    bool unpauseSupply_,
    bool unpauseWithdraw_,
    bool unpauseBorrow_,
    bool unpausePayback_
) external returns (address dex_, bool actedSupply_, bool actedWithdraw_, bool actedBorrow_, bool actedPayback_);

Parameters

NameTypeDescription
dexId_uint256DEX ID where the user should be unpaused.
user_addressUser address to unpause on the DEX.
unpauseSupply_boolWhether to unpause supply/deposit operations.
unpauseWithdraw_boolWhether to unpause withdraw operations.
unpauseBorrow_boolWhether to unpause borrow operations.
unpausePayback_boolWhether to unpause payback operations.

Returns

NameTypeDescription
dex_addressResolved DEX address.
actedSupply_boolWhether supply/deposit unpause state changed.
actedWithdraw_boolWhether withdraw unpause state changed.
actedBorrow_boolWhether borrow state changed (pause bit, or frozen limits restored).
actedPayback_boolWhether payback unpause state changed.