---
# System prepended metadata

title: vDF Governance Kovan

---

# vDF Governance Kovan



| Contract Name        | Contract Address                           | Link                                                                                  |
|:-------------------- | ------------------------------------------ |:------------------------------------------------------------------------------------- |
| DF                   | 0x79E40d67DA6eAE5eB4A93Fc6a56A7961625E15F3 | [link](https://kovan.etherscan.io/address/0x79E40d67DA6eAE5eB4A93Fc6a56A7961625E15F3) |
| vault address        | 0x2294B1cE7B9d73D905d08da7411f1e9f8fec76D2 | [link](https://kovan.etherscan.io/address/0x2294B1cE7B9d73D905d08da7411f1e9f8fec76D2) |
| vDF proxy admin      | 0xEe5107eAe1339F02Ab27E580862d8c89293AA187 | [link](https://kovan.etherscan.io/address/0xEe5107eAe1339F02Ab27E580862d8c89293AA187) |
| vDF implementation   | 0x7a1cC6c77d0463cC80CAD15cbacbF7355CAa0234 | [link](https://kovan.etherscan.io/address/0x7a1cC6c77d0463cC80CAD15cbacbF7355CAa0234) |
| vDF proxy            | 0xDc6630379E7D04f37A262e88A19cFb0f294Ea2b6 | [link](https://kovan.etherscan.io/address/0xDc6630379E7D04f37A262e88A19cFb0f294Ea2b6) |
| timelock             | 0x6964981096d0370bD3B43e9E1237418009a55611 | [link](https://kovan.etherscan.io/address/0x6964981096d0370bD3B43e9E1237418009a55611) |
| governance delegate  | 0x2284bF22fEb8ca58Fe9B84586Dcb6031E3438E02 | [link](https://kovan.etherscan.io/address/0x2284bF22fEb8ca58Fe9B84586Dcb6031E3438E02) |
| governance delegator | 0x668CA4DFE21de6264261874198E3E6157BdfA4a6 | [link](https://kovan.etherscan.io/address/0x668CA4DFE21de6264261874198E3E6157BdfA4a6) |
|                      |                                            |                                                                                       |
| 01-14:               |                                            |                                                                                       |
| vDF                  | 0xE1D6D7d16BddC232B73120Df435B512FAA7F1a45 |                                                                                       |
| time lock            | 0xf956256794F35d1EE3F9CF090B5a676BD5aF5B30 |                                                                                       |
| governance delegate  | 0xe264616085e35Ad0eC7cD069a068b8Dbc8229Bd2 |                                                                                       |
| governance delegator | 0x3d9a888B4F2B2B2c98ddEe4ef542Fb13eB9bAf23 |                                                                                       |


方法：

1. vDF.balanceOf（address）: 查询输入地址的vDF数量
2. vDF.totalSupply(): 查询vDF 的总量
3. vDF.getCurrentExchangeRate(): 查询当前DF与vDF的兑换比率
4. vDF.getUnderlyingTotalAmount(): 查询当前DF的总量

5. vDF.delegate(address): 委托投票权给输入的地址账户
6. vDF.getCurrentVotes(address): 获得查询账户的可投票数量
7. vDF.getPriorVotes(address,blockNumber): 查询在某个时刻的可投票数量(blockNumber 需小于当前block number，即blockNumber最大为 current block - 1)

6. vDF.proposalThreshold(): 最少投票数量

7. governorDelegator.propose(targets, values, signatures, calldatas, description)：发起proposal
前提：发起投票用户需有一定数量的投票权。查询governorDelegator.proposalThreshold（）获得最低投票权数量。只有当发起投票用户的投票权大于等于该数值才可以发起proposal。

8. 方法一： governorDelegator.castVote(prososalId, voteState) 用户针对proposalId进行投票，voteState只能为0:反对，1:赞成，2:弃权
前提：
0: let proposal = 即governorDelegator.proposals[proposalId]
1.该proposal的状态只能是激活状态，即governorDelegator.state(prososalId) == 1（active）
2.投票状态只能是0，1，2
3.用户未对该proposal投过票，即proposal.receipts.hasVoted == false

投票结束后，通过proposal.receipts查询结果，
proposal.receipt.hasVoted: true(已投票)/false(未投票)
proposal.receipt.support: 投票结果(0:反对，1:赞成，2:弃权)
proposal.receipt.votes: 投票数量

8. 方法二：governorDelegator.castVoteWithReason(proposalId,voteState,reason), 这个方法比上面的方法只多了一个reason。其他判断条件不变

9. governorDelegator.state(proposalId): 这个proposalId的状态查询
```
ProposalState {
    Pending,
    Active,
    Canceled,
    Defeated,
    Succeeded,
    Queued,
    Expired,
    Executed
}
```

10. governorDelegator.proposalCount(): 查询当前proposal 数量

11. governorDelegator.proposals(id): 查询某个proposal具体内容，
返回内容如下：
```
struct Proposal {
    uint id;
    address proposer;
    uint eta;
    address[] targets;
    uint[] values;
    string[] signatures;
    bytes[] calldatas;
    uint startBlock;
    uint endBlock;
    uint forVotes;
    uint againstVotes;
    uint abstainVotes;
    bool canceled;
    bool executed;
    mapping (address => Receipt) receipts;
}
```

12. governorDelegator.getReceipt(proposalId, voter): 查询某个用户对某个proposal的投票状态：
```
{
    bool hasVoted;
    uint8 support;
    uint96 votes;
}
```
13. governorDelegator.latestProposalIds(account_address): 查询某个用户上一次的proposal ID