Skip to main content

PegExchanger

Functions

constructor

function constructor(
address tribeRariDAO
) public

Parameters

NameTypeDescription
tribeRariDAOaddress

exchange

function exchange(
uint256 amount
) public

call to exchange held RGT with TRIBE

Parameters

NameTypeDescription
amountuint256the amount to exchange

isExpired

function isExpired() public returns (bool)

tells whether or not the contract is expired.

Return Values

NameTypeDescription
[0]boolboolean true if we have passed the expiration block, else false

setExpirationTimestamp

function setExpirationTimestamp(
uint256 timestamp
) public

the expiry must be set to at least MIN_EXPIRY_WINDOW in the future.

Parameters

NameTypeDescription
timestampuint256the block timestamp for expiration

Events

Exchange

event Exchange(
address from,
uint256 amountIn,
uint256 amountOut
)

Parameters

NameTypeDescription
fromaddress
amountInuint256
amountOutuint256

SetExpiry

event SetExpiry(
address caller,
uint256 expiry
)

Parameters

NameTypeDescription
calleraddress
expiryuint256