1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85
| public class Hello extends Contract { private static final String BINARY = "608060405234801561001057600080fd5b50610346806100206000396000f3fe608060405234801561001057600080fd5b5060043610610053576000357c0100000000000000000000000000000000000000000000000000000000900480635a9b0b89146100585780638262963b146100e2575b600080fd5b6100606101a7565b6040518080602001838152602001828103825284818151815260200191508051906020019080838360005b838110156100a657808201518184015260208101905061008b565b50505050905090810190601f1680156100d35780820380516001836020036101000a031916815260200191505b50935050505060405180910390f35b6101a5600480360360408110156100f857600080fd5b810190808035906020019064010000000081111561011557600080fd5b82018360208201111561012757600080fd5b8035906020019184600183028401116401000000008311171561014957600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f82011690508083019250505050505050919291929080359060200190929190505050610253565b005b6060600080600154818054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156102445780601f1061021957610100808354040283529160200191610244565b820191906000526020600020905b81548152906001019060200180831161022757829003601f168201915b50505050509150915091509091565b8160009080519060200190610269929190610275565b50806001819055505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106102b657805160ff19168380011785556102e4565b828001600101855582156102e4579182015b828111156102e35782518255916020019190600101906102c8565b5b5090506102f191906102f5565b5090565b61031791905b808211156103135760008160009055506001016102fb565b5090565b9056fea165627a7a7230582007c004e4d5d896b794dd7a63a8b6bdd16e95744ed1d0aa3c5b0eb8c4c7590e250029";
public static final String FUNC_GETINFO = "getInfo";
public static final String FUNC_SETINFO = "setInfo";
@Deprecated protected Hello(String contractAddress, Web3j web3j, Credentials credentials, BigInteger gasPrice, BigInteger gasLimit) { super(BINARY, contractAddress, web3j, credentials, gasPrice, gasLimit); }
protected Hello(String contractAddress, Web3j web3j, Credentials credentials, ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, credentials, contractGasProvider); }
@Deprecated protected Hello(String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
protected Hello(String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
public RemoteCall<Tuple2<Utf8String, Uint256>> getInfo() { final Function function = new Function(FUNC_GETINFO, Arrays.<Type>asList(), Arrays.<TypeReference<?>>asList(new TypeReference<Utf8String>() {}, new TypeReference<Uint256>() {})); return new RemoteCall<Tuple2<Utf8String, Uint256>>( new Callable<Tuple2<Utf8String, Uint256>>() { @Override public Tuple2<Utf8String, Uint256> call() throws Exception { List<Type> results = executeCallMultipleValueReturn(function); return new Tuple2<Utf8String, Uint256>( (Utf8String) results.get(0), (Uint256) results.get(1)); } }); }
public RemoteCall<TransactionReceipt> setInfo(Utf8String _fName, Uint256 _age) { final Function function = new Function( FUNC_SETINFO, Arrays.<Type>asList(_fName, _age), Collections.<TypeReference<?>>emptyList()); return executeRemoteCallTransaction(function); }
@Deprecated public static Hello load(String contractAddress, Web3j web3j, Credentials credentials, BigInteger gasPrice, BigInteger gasLimit) { return new Hello(contractAddress, web3j, credentials, gasPrice, gasLimit); }
@Deprecated public static Hello load(String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return new Hello(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
public static Hello load(String contractAddress, Web3j web3j, Credentials credentials, ContractGasProvider contractGasProvider) { return new Hello(contractAddress, web3j, credentials, contractGasProvider); }
public static Hello load(String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { return new Hello(contractAddress, web3j, transactionManager, contractGasProvider); }
public static RemoteCall<Hello> deploy(Web3j web3j, Credentials credentials, ContractGasProvider contractGasProvider) { return deployRemoteCall(Hello.class, web3j, credentials, contractGasProvider, BINARY, ""); }
@Deprecated public static RemoteCall<Hello> deploy(Web3j web3j, Credentials credentials, BigInteger gasPrice, BigInteger gasLimit) { return deployRemoteCall(Hello.class, web3j, credentials, gasPrice, gasLimit, BINARY, ""); }
public static RemoteCall<Hello> deploy(Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { return deployRemoteCall(Hello.class, web3j, transactionManager, contractGasProvider, BINARY, ""); }
@Deprecated public static RemoteCall<Hello> deploy(Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return deployRemoteCall(Hello.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); } }
|