Skip to content

Latest commit

 

History

History
133 lines (86 loc) · 1.65 KB

affiliate.md

File metadata and controls

133 lines (86 loc) · 1.65 KB
description
description

Affiliate

Read methods

Get Id

description

function getId(address affiliate) external view returns (bytes32);

Get Affliate

description

function getAffiliate(bytes32 id) external view returns (address);

Get Referrer

description

function getReferrer(address account) external view returns (address);

Balance Of

description

function balanceOf(address account) external view returns (uint256);

Has Been Assigned

description

function hasBeenAssigned(address account) external view returns (bool);

Ratio

description

function ratio(uint256 index) external view returns (uint256);

Total Ratio

description

function totalRatio() external view returns (uint256);

Ratios

description

function ratios() external view returns (uint256[] memory);

Write Methods

Set Id

description

function setID(bytes32 id) external;

Assign To

description

function assignTo(bytes32 id) external;

Withdraw

description

function withdraw(address to, uint256 amount) external;

Reward

description

function reward(uint256 totalTokens, address sender) external returns (uint256 remainder);

Events

Withdrawal

Description

event Withdrawal(
    address indexed to, 
    uint256 amount, 
    address indexed sender
);

ID Updated

Description

event IDUpdated(
    bytes32 indexed prevId, 
    bytes32 indexed newId,
    address indexed sender
);