use of org.fisco.bcos.web3j.abi.datatypes.Function in project web3sdk by FISCO-BCOS.
the class ChainGovernance method getUpdateCommitteeMemberWeightOutput.
public Tuple1<BigInteger> getUpdateCommitteeMemberWeightOutput(TransactionReceipt transactionReceipt) {
String data = transactionReceipt.getOutput();
final Function function = new Function(FUNC_UPDATECOMMITTEEMEMBERWEIGHT, Arrays.<Type>asList(), Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {
}));
List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
;
return new Tuple1<BigInteger>((BigInteger) results.get(0).getValue());
}
use of org.fisco.bcos.web3j.abi.datatypes.Function in project web3sdk by FISCO-BCOS.
the class ChainGovernance method updateCommitteeMemberWeight.
public void updateCommitteeMemberWeight(String user, BigInteger weight, TransactionSucCallback callback) {
final Function function = new Function(FUNC_UPDATECOMMITTEEMEMBERWEIGHT, Arrays.<Type>asList(new org.fisco.bcos.web3j.abi.datatypes.Address(user), new org.fisco.bcos.web3j.abi.datatypes.generated.Int256(weight)), Collections.<TypeReference<?>>emptyList());
asyncExecuteTransaction(function, callback);
}
use of org.fisco.bcos.web3j.abi.datatypes.Function in project web3sdk by FISCO-BCOS.
the class ChainGovernance method getRevokeOperatorInput.
public Tuple1<String> getRevokeOperatorInput(TransactionReceipt transactionReceipt) {
String data = transactionReceipt.getInput().substring(10);
final Function function = new Function(FUNC_REVOKEOPERATOR, Arrays.<Type>asList(), Arrays.<TypeReference<?>>asList(new TypeReference<Address>() {
}));
List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
;
return new Tuple1<String>((String) results.get(0).getValue());
}
use of org.fisco.bcos.web3j.abi.datatypes.Function in project web3sdk by FISCO-BCOS.
the class ChainGovernance method getGrantCommitteeMemberOutput.
public Tuple1<BigInteger> getGrantCommitteeMemberOutput(TransactionReceipt transactionReceipt) {
String data = transactionReceipt.getOutput();
final Function function = new Function(FUNC_GRANTCOMMITTEEMEMBER, Arrays.<Type>asList(), Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {
}));
List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
;
return new Tuple1<BigInteger>((BigInteger) results.get(0).getValue());
}
use of org.fisco.bcos.web3j.abi.datatypes.Function in project web3sdk by FISCO-BCOS.
the class ChainGovernance method getRevokeCommitteeMemberOutput.
public Tuple1<BigInteger> getRevokeCommitteeMemberOutput(TransactionReceipt transactionReceipt) {
String data = transactionReceipt.getOutput();
final Function function = new Function(FUNC_REVOKECOMMITTEEMEMBER, Arrays.<Type>asList(), Arrays.<TypeReference<?>>asList(new TypeReference<Int256>() {
}));
List<Type> results = FunctionReturnDecoder.decode(data, function.getOutputParameters());
;
return new Tuple1<BigInteger>((BigInteger) results.get(0).getValue());
}
Aggregations