RevenuePathV2
Path
contracts/core/ReveelMainV2.sol
Contract Interface
receive payable ()
Events
DepositETH (address,uint256)
Emits on receive; mimics ERC20 Transfer
Parameters
address from: Address that deposited the eth
uint256 value: Amount of ETH deposited
ERC20PaymentReleased (address,address,uint256)
Emits when ERC20 payment is withdrawn/claimed by a member
Parameters
address token: The token address for which withdrawal is made
address account: The wallet address to which withdrawal is made
uint256 payment: The amount of the given token the wallet has claimed
FeeDistributed (address,uint256)
Emits when fee is distributed
Parameters
address token: The token address. Address 0 for native gas token like ETH
uint256 amount: The amount of fee deducted
FeeReleased (address,uint256)
Emits when fee is released
Parameters
address token: The token address. Address 0 for native gas token like ETH
uint256 amount: The amount of fee released
Initialized (uint8)
Parameters
uint8 version
OwnershipTransferred (address,address)
Parameters
address previousOwner
address newOwner
PaymentReleased (address,address,uint256)
Emits when token payment is withdrawn/claimed by a member
Parameters
address account: The wallet for which ETH has been claimed for
address token
uint256 payment: The amount of ETH that has been paid out to the wallet
RevenueTierAdded (address[][],uint256[][])
emits when one or more revenue tiers are added
Parameters
address[][] wallets: Array of arrays of wallet lists (each array is a tier)
uint256[][] distributions: Array of arrays of distr %s (each array is a tier)
RevenueTierUpdated (uint256[],address[][],uint256[][])
emits when one or more revenue tiers wallets/distributions are updated
Parameters
uint256[] tierNumbers: Array tier numbers being updated
address[][] wallets: Array of arrays of wallet lists (each array is a tier)
uint256[][] distributions: Array of arrays of distr %s (each array is a tier)
TierLimitUpdated (uint256,address[],uint256[])
emits when one revenue tier's limit is updated
Parameters
uint256 tier: tier number being updated
address[] tokenList: Array of tokens in that tier
uint256[] newLimits: Array of limits for those tokens
TokenDistributed (address,uint256,uint256)
Emits when tokens are distributed during withdraw or external distribution call
Parameters
address token: Address of token for distribution. Zero address for native token like ETH
uint256 amount: The amount of token distributed in wei
uint256 tier: The tier for which the distribution occured
Methods
BASE view ()
Return Values
uint32 _0
VERSION view ()
Return Values
uint8 _0
addRevenueTiers nonpayable (address[][],uint256[][])
Adding new revenue tiers
Parameters
address[][] _walletList: a nested list of new wallets
uint256[][] _distribution: a nested list of corresponding distribution
distributePendingTokens nonpayable (address)
Called for a given token to distribute, unallocated tokens to the respective tiers and wallet members
Parameters
address token: The address of the token
getCurrentTier view (address)
Get the current ongoing tier of revenue path For eth: token address(0) is reserved
Parameters
address token
Return Values
uint256 tierNumber
getFeeRequirementStatus view ()
Get the current ongoing tier of revenue path
Return Values
bool required
getImmutabilityStatus view ()
Get the revenue path Immutability status
Return Values
bool _0
getMainFactory view ()
Returns the ReveelMainV2 contract address
Return Values
address _0
getPendingDistributionAmount view (address)
Get the token amount that has not been allocated for in the revenue path
Parameters
address token: The token address
Return Values
uint256 _0
getPlatformFee view ()
Get the platform fee percentage
Return Values
uint256 _0
getRevenueProportion view (uint256,address)
Get the token revenue proportion for a given account at a given tier
Parameters
uint256 tier: The tier to fetch revenue proportions for
address account: The wallet address for which revenue proportion is requested
Return Values
uint256 proportion
getRevenueTier view (uint256)
Get the wallet list for a given revenue tier
Parameters
uint256 tierNumber: the index of the tier for which list needs to be provided.
Return Values
address[] _walletList
getTierDistributedAmount view (address,uint256)
Get the amount of token distrbuted for a given tier
Parameters
address token: The token address for which distributed amount is fetched
uint256 tier: The tier for which distributed amount is fetched
Return Values
uint256 amount
getTierWalletCount view (uint256)
Total wallets available in a tier
Parameters
uint256 tier: The tier for which wallet counts will be fetched
Return Values
uint256 _0
getTokenReleased view (address,address)
Get the amount of token released for a given account
Parameters
address token: the token address for which token released is fetched
address account: the wallet address for whih the token released is fetched
Return Values
uint256 amount
getTokenTierLimits view (address,uint256)
Parameters
address token
uint256 tier
Return Values
uint256 _0
getTokenWithdrawn view (address,address)
Get the amount of total eth withdrawn by the account
Parameters
address token
address account
Return Values
uint256 _0
getTotalFeeAccumulated view (address)
Get the amount of ETH accumulated for fee collection
Parameters
address token
Return Values
uint256 amount
getTotalRevenueTiers view ()
Get the totalNumber of revenue tiers in the revenue path
Return Values
uint256 total
getTotalTokenAccounted view (address)
Returns total token accounted for a given token address
Parameters
address token: The token for which total accountd amount is fetched
Return Values
uint256 _0
getTotalTokenReleased view (address)
Returns total token released
Parameters
address token: The token for which total released amount is fetched
Return Values
uint256 _0
getTrustedForwarder view ()
:warning: **Warning** :warning: The Forwarder can have a full control over your Recipient. Only trust verified Forwarder.Method is not a required method to allow Recipients to trust multiple Forwarders. Not recommended yet.
Return Values
address forwarder: The address of the Forwarder contract that is being used.
getWithdrawableToken view (address,address)
Returns withdrawable or claimable token amount for a given wallet in the revenue path
Parameters
address token
address wallet
Return Values
uint256 _0
initialize nonpayable (address[][],uint256[][],address[],uint256[][],tuple,address)
Initializes revenue path
Parameters
address[][] _walletList: Nested array for wallet list across different tiers
uint256[][] _distribution: Nested array for distribution percentage across different tiers
address[] _tokenList: A list of tokens for which limits will be set
uint256[][] _limitSequence: A nested array of limits for each token
tuple pathInfo: A property object for the path details
address _owner: Address of path owner
isTrustedForwarder view (address)
:warning: **Warning** :warning: The Forwarder can have a full control over your Recipient. Only trust verified Forwarder.
Parameters
address forwarder: The address of the Forwarder contract that is being used.
Return Values
bool _0: isTrustedForwarder `true` if the Forwarder is trusted to forward relayed transactions by this Recipient.
owner view ()
Returns the address of the current owner.
Return Values
address _0
release nonpayable (address,address)
Releases distribute token
Parameters
address token: The token address
address account: The address of the receiver
renounceOwnership nonpayable ()
Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.
setTrustedForwarder nonpayable (address)
Update the trusted forwarder address
Parameters
address forwarder: The address of the new forwarder
transferOwnership nonpayable (address)
Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.
Parameters
address newOwner
updateLimits nonpayable (address[],uint256[],uint256)
Update tier limits for given tokens for an existing tier
Parameters
address[] tokenList: A list of tokens for which limits will be updated
uint256[] newLimits: A list of corresponding limits for the tokens
uint256 tier: The tier for which limits are being updated
updateRevenueTiers nonpayable (address[][],uint256[][],uint256[])
Updating distribution for existing revenue tiers
Parameters
address[][] _walletList: A nested list of wallet address
uint256[][] _distribution: A nested list of distribution percentage
uint256[] _tierNumbers: A list of tier numbers to be updated
Last updated