我堅固的合同是以下幾點:如何使用Java
contract SimpleStorage {
uint storedData;
function set(uint x) {
storedData = x;
}
function get() constant returns (uint retVal) {
return storedData;
}}
,並生成ABI是以下幾點:
[ { "constant": false, "inputs": [ { "name": "x", "type": "uint256" } ], "name": "set", "outputs": [], "type": "function" }, { "constant": true, "inputs": [], "name": "get", "outputs": [ { "name": "retVal", "type": "uint256", "value": "0" } ], "type": "function" } ]
和https://github.com/ethereum/wiki/wiki/JSON-RPC參考,
如何調用得到函數和通過使用java(不是js)得到值?
#Conor我有以下的答案,這是非常好理解,但我面臨一些問題,你可以請看看這個,並幫助我https://stackoverflow.com/questions/44719819/web3j-not-working-with -contract功能 –