public class Governance extends Object
| 构造器和说明 |
|---|
Governance(DnaSdk sdk) |
| 限定符和类型 | 方法和说明 |
|---|---|
String |
addInitPos(Account account,
String peerPubkey,
int pos,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
approveCandidate(Account adminAccount,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
approveCandidate(Address multiAddress,
int M,
Account[] accounts,
byte[][] publicKeys,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
authorizeForPeer(Account account,
String[] peerPubkey,
long[] posList,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
blackNode(String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
long |
calcUnbindOng(long balance,
int startOffset,
int endOffset) |
String |
callSplit(Account payerAcct,
long gaslimit,
long gasprice) |
String |
changeMaxAuthorization(Account account,
String peerPubkey,
int maxAuthorize,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
commitDpos(Account adminAccount,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
commitDpos(Address multiAddress,
int M,
Account[] accounts,
byte[][] publicKeys,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
getAuthorizeInfo(String peerPubkey,
Address addr) |
Configuration |
getConfiguration() |
String |
getContractAddress() |
GlobalParam |
getGlobalParam() |
GlobalParam1 |
getGlobalParam1() |
GlobalParam2 |
getGlobalParam2() |
GovernanceView |
getGovernanceView() |
InputPeerPoolMapParam |
getInputPeerPoolMapParam(String sideChainId) |
String |
getPeerAttributes(String peerPubkey) |
String |
getPeerInfo(String peerPubkey) |
String |
getPeerInfoAll() |
Map |
getPeerPoolMap() |
long |
getPeerUbindOng(String address) |
SplitCurve |
getSplitCurve() |
String |
getSplitFeeAddress(String address) |
String |
quitNode(Account account,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
reduceInitPos(Account account,
String peerPubkey,
int pos,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
registerCandidate(Account account,
String peerPubkey,
long initPos,
String dnaid,
String dnaidpwd,
byte[] salt,
long keyNo,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
rejectCandidate(Account adminAccount,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
rejectCandidate(Address multiAddress,
int M,
Account[] accounts,
byte[][] publicKeys,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
setPeerCost(Account account,
String peerPubkey,
int peerCost,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
unAuthorizeForPeer(Account account,
String[] peerPubkey,
long[] posList,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
unRegisterCandidate(Account account,
String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
updateConfig(Account[] accounts,
byte[][] pks,
int M,
Configuration config,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
updateGlobalParam1(Account[] accounts,
byte[][] pks,
int M,
GlobalParam1 param1,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
updateGlobalParam2(Account[] accounts,
byte[][] pks,
int M,
GlobalParam2 param2,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
updateSplitCurve(Account[] accounts,
byte[][] pks,
int M,
SplitCurve curve,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
whiteNode(String peerPubkey,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
withdraw(Account account,
String[] peerPubkey,
long[] withdrawList,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
withdrawFee(Account account,
Account payerAcct,
long gaslimit,
long gasprice) |
String |
withdrawGas(Account account,
Account payerAcct,
long gaslimit,
long gasprice) |
public Governance(DnaSdk sdk)
public String getContractAddress()
public String registerCandidate(Account account, String peerPubkey, long initPos, String dnaid, String dnaidpwd, byte[] salt, long keyNo, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - initPos - dnaid - dnaidpwd - keyNo - payerAcct - gaslimit - gasprice - Exceptionpublic String unRegisterCandidate(Account account, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String withdrawGas(Account account, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String withdrawFee(Account account, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String getPeerInfo(String peerPubkey) throws ConnectorException, IOException
peerPubkey - ConnectorExceptionIOExceptionpublic String getPeerInfoAll() throws ConnectorException, IOException
ConnectorExceptionIOExceptionpublic Map getPeerPoolMap() throws ConnectorException, IOException
public GovernanceView getGovernanceView() throws ConnectorException, IOException, SDKException
public String getAuthorizeInfo(String peerPubkey, Address addr)
peerPubkey - addr - public String approveCandidate(Account adminAccount, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String approveCandidate(Address multiAddress, int M, Account[] accounts, byte[][] publicKeys, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
multiAddress - M - accounts - publicKeys - peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String rejectCandidate(Account adminAccount, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String rejectCandidate(Address multiAddress, int M, Account[] accounts, byte[][] publicKeys, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
multiAddress - M - accounts - publicKeys - peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String authorizeForPeer(Account account, String[] peerPubkey, long[] posList, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - posList - payerAcct - gaslimit - gasprice - Exceptionpublic String unAuthorizeForPeer(Account account, String[] peerPubkey, long[] posList, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - posList - payerAcct - gaslimit - gasprice - Exceptionpublic String withdraw(Account account, String[] peerPubkey, long[] withdrawList, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - withdrawList - payerAcct - gaslimit - gasprice - Exceptionpublic String commitDpos(Account adminAccount, Account payerAcct, long gaslimit, long gasprice) throws Exception
adminAccount - payerAcct - gaslimit - gasprice - Exceptionpublic String commitDpos(Address multiAddress, int M, Account[] accounts, byte[][] publicKeys, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String blackNode(String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String whiteNode(String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String quitNode(Account account, String peerPubkey, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - payerAcct - gaslimit - gasprice - Exceptionpublic String changeMaxAuthorization(Account account, String peerPubkey, int maxAuthorize, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - maxAuthorize - payerAcct - gaslimit - gasprice - Exceptionpublic String addInitPos(Account account, String peerPubkey, int pos, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - pos - payerAcct - gaslimit - gasprice - Exceptionpublic String reduceInitPos(Account account, String peerPubkey, int pos, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - pos - payerAcct - gaslimit - gasprice - Exceptionpublic String setPeerCost(Account account, String peerPubkey, int peerCost, Account payerAcct, long gaslimit, long gasprice) throws Exception
account - peerPubkey - peerCost - payerAcct - gaslimit - gasprice - Exceptionpublic String getPeerAttributes(String peerPubkey) throws ConnectorException, IOException
peerPubkey - ConnectorExceptionIOExceptionpublic long getPeerUbindOng(String address) throws ConnectorException, IOException, SDKException
public long calcUnbindOng(long balance,
int startOffset,
int endOffset)
public String updateConfig(Account[] accounts, byte[][] pks, int M, Configuration config, Account payerAcct, long gaslimit, long gasprice) throws Exception
config - payerAcct - gaslimit - gasprice - Exceptionpublic String updateSplitCurve(Account[] accounts, byte[][] pks, int M, SplitCurve curve, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String updateGlobalParam1(Account[] accounts, byte[][] pks, int M, GlobalParam1 param1, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String updateGlobalParam2(Account[] accounts, byte[][] pks, int M, GlobalParam2 param2, Account payerAcct, long gaslimit, long gasprice) throws Exception
Exceptionpublic String callSplit(Account payerAcct, long gaslimit, long gasprice) throws Exception
payerAcct - gaslimit - gasprice - Exceptionpublic Configuration getConfiguration() throws ConnectorException, IOException
public GlobalParam1 getGlobalParam1() throws ConnectorException, IOException
public GlobalParam2 getGlobalParam2() throws ConnectorException, IOException
public GlobalParam getGlobalParam() throws ConnectorException, IOException
public SplitCurve getSplitCurve() throws ConnectorException, IOException
public InputPeerPoolMapParam getInputPeerPoolMapParam(String sideChainId) throws ConnectorException, IOException, SDKException
Copyright © 2021. All rights reserved.