↗ Extends: CustomPausable ↘ Derived Contracts: VestingSchedule.
VestingScheduleBase
Vesting Schedule indicates when, how much, and how frequently founders, employees, and advisor can exercise their token allocations. Vesting is determined for each individual.
struct Allocation {
string memberName,
uint256 startedOn,
uint256 releaseOn,
uint256 allocation,
uint256 closingBalance,
bool deleted,
uint256 withdrawn,
uint256 lastWithdrawnOn
}Constants & Variables
//public members
uint256 public withdrawalCap;
uint256 public withdrawalFrequency;
uint256 public vestingStartedOn;
uint256 public minimumVestingPeriod;
uint256 public earliestWithdrawalDate;
uint256 public totalVested;
uint256 public totalWithdrawn;
contract ERC20 public vestingCoin;
//internal members
mapping(address => struct VestingScheduleBase.Allocation) internal allocations;Events
event Funded(address indexed _funder, uint256 _amount, uint256 _previousCap, uint256 _newCap);
event FundRemoved(address indexed _address, uint256 _amount, uint256 _remainingInPool);
event Withdrawn(address indexed _address, string _memberName, uint256 _amount);
event AllocationCreated(address indexed _address, string _memberName, uint256 _amount, uint256 _releaseOn);
event AllocationIncreased(address indexed _address, string _memberName, uint256 _amount, uint256 _additionalAmount);
event AllocationDecreased(address indexed _address, string _memberName, uint256 _amount, uint256 _lessAmount);
event AllocationDeleted(address indexed _address, string _memberName, uint256 _amount);
event ScheduleExtended(address indexed _address, string _memberName, uint256 _releaseOn, uint256 _newReleaseDate);Signifies that the action is only possible after the earliest withdrawal date of the vesting contract.
modifier afterEarliestWithdrawalDate() internalArguments
| Name | Type | Description |
|---|
- createAllocation
- deleteAllocation
- increaseAllocation
- decreaseAllocation
- extendAllocation
- withdraw
- getAvailableFunds
- getAmountInVesting
- getAllocation
- fund
- removeFunds
⤿ Overridden Implementation(s): VestingSchedule.createAllocation
function createAllocation(address _address, string _memberName, uint256 _amount, uint256 _releaseOn) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _address | address | |
| _memberName | string | |
| _amount | uint256 | |
| _releaseOn | uint256 |
⤿ Overridden Implementation(s): VestingSchedule.deleteAllocation
function deleteAllocation(address _address) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _address | address |
⤿ Overridden Implementation(s): VestingSchedule.increaseAllocation
function increaseAllocation(address _address, uint256 _additionalAmount) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _address | address | |
| _additionalAmount | uint256 |
⤿ Overridden Implementation(s): VestingSchedule.decreaseAllocation
function decreaseAllocation(address _address, uint256 _lessAmount) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _address | address | |
| _lessAmount | uint256 |
⤿ Overridden Implementation(s): VestingSchedule.extendAllocation
function extendAllocation(address _address, uint256 _newReleaseDate) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _address | address | |
| _newReleaseDate | uint256 |
⤿ Overridden Implementation(s): VestingSchedule.withdraw
function withdraw(uint256 _amount) external
returns(bool)Arguments
| Name | Type | Description |
|---|---|---|
| _amount | uint256 |
The balance of this smart contract.
function getAvailableFunds() public view
returns(uint256)Returns
Returns the closing balance of vesting coin held by this contract.
The sum total amount in vesting allocations.
function getAmountInVesting() public view
returns(uint256)Returns
Returns the amount in vesting coin that must be held by this contract.
The vesting schedule allocation of the specified address.
function getAllocation(address _address) external view
returns(_startedOn uint256, _memberName string, _releaseOn uint256, _allocation uint256, _closingBalance uint256, _withdrawn uint256, _lastWithdrawnOn uint256, _deleted bool)Returns
Returns the requested vesting schedule allocation.
Arguments
| Name | Type | Description |
|---|---|---|
| _address | address | The address to get the vesting schedule allocation of. |
⤿ Overridden Implementation(s): VestingSchedule.fund
Override this function to receive the vesting coin in this contract.
function fund() external
returns(bool)Returns
Returns true if the action was successful.
⤿ Overridden Implementation(s): VestingSchedule.removeFunds
Override this function to remove the vesting coin from this contract.
function removeFunds(uint256 _amount) external
returns(bool)Returns
Returns true if the action was successful.
Arguments
| Name | Type | Description |
|---|---|---|
| _amount | uint256 |