org.web3j.tx.TransactionManager Java Examples
The following examples show how to use
org.web3j.tx.TransactionManager.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: SolidityFunctionWrapper.java From etherscan-explorer with GNU General Public License v3.0 | 6 votes |
void generateJavaFiles( String contractName, String bin, List<AbiDefinition> abi, String destinationDir, String basePackageName, Map<String, String> addresses) throws IOException, ClassNotFoundException { String className = Strings.capitaliseFirstLetter(contractName); TypeSpec.Builder classBuilder = createClassBuilder(className, bin); classBuilder.addMethod(buildConstructor(Credentials.class, CREDENTIALS)); classBuilder.addMethod(buildConstructor(TransactionManager.class, TRANSACTION_MANAGER)); classBuilder.addMethods( buildFunctionDefinitions(className, classBuilder, abi)); classBuilder.addMethod(buildLoad(className, Credentials.class, CREDENTIALS)); classBuilder.addMethod(buildLoad(className, TransactionManager.class, TRANSACTION_MANAGER)); addAddressesSupport(classBuilder, addresses); write(basePackageName, classBuilder.build(), destinationDir); }
Example #2
Source File: OnChainPrivacyGroupManagementProxy.java From besu with Apache License 2.0 | 6 votes |
public static RemoteCall<OnChainPrivacyGroupManagementProxy> deploy( Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider, String _implementation) { String encodedConstructor = FunctionEncoder.encodeConstructor( Arrays.<Type>asList(new org.web3j.abi.datatypes.Address(160, _implementation))); return deployRemoteCall( OnChainPrivacyGroupManagementProxy.class, web3j, transactionManager, contractGasProvider, BINARY, encodedConstructor); }
Example #3
Source File: OnChainPrivacyGroupManagementProxy.java From besu with Apache License 2.0 | 6 votes |
@Deprecated public static RemoteCall<OnChainPrivacyGroupManagementProxy> deploy( Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit, String _implementation) { String encodedConstructor = FunctionEncoder.encodeConstructor( Arrays.<Type>asList(new org.web3j.abi.datatypes.Address(160, _implementation))); return deployRemoteCall( OnChainPrivacyGroupManagementProxy.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, encodedConstructor); }
Example #4
Source File: EventEmitter.java From besu with Apache License 2.0 | 5 votes |
public static EventEmitter load( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { return new EventEmitter(contractAddress, web3j, transactionManager, contractGasProvider); }
Example #5
Source File: SimpleStorage.java From ethsigner with Apache License 2.0 | 5 votes |
@Deprecated protected SimpleStorage( String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #6
Source File: SimpleStorage.java From ethsigner with Apache License 2.0 | 5 votes |
@Deprecated public static RemoteCall<SimpleStorage> deploy( Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return deployRemoteCall( SimpleStorage.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); }
Example #7
Source File: OnChainPrivacyGroupManagementProxy.java From besu with Apache License 2.0 | 5 votes |
public static OnChainPrivacyGroupManagementProxy load( String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { return new OnChainPrivacyGroupManagementProxy( contractAddress, web3j, transactionManager, contractGasProvider); }
Example #8
Source File: SimpleStorage.java From ethsigner with Apache License 2.0 | 5 votes |
@Deprecated public static SimpleStorage load( String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return new SimpleStorage(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #9
Source File: OnChainPrivacyGroupManagementInterface.java From besu with Apache License 2.0 | 5 votes |
protected OnChainPrivacyGroupManagementInterface( String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #10
Source File: OnChainPrivacyGroupManagementInterface.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static OnChainPrivacyGroupManagementInterface load( String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return new OnChainPrivacyGroupManagementInterface( contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #11
Source File: OnChainPrivacyGroupManagementInterface.java From besu with Apache License 2.0 | 5 votes |
@Deprecated protected OnChainPrivacyGroupManagementInterface( String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { super(BINARY, contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #12
Source File: DeployPrivateSmartContractWithPrivacyGroupIdTransaction.java From besu with Apache License 2.0 | 5 votes |
@Override public T execute(final NodeRequests node) { final PrivateTransactionManager privateTransactionManager = new BesuPrivateTransactionManager( node.privacy().getBesuClient(), GAS_PROVIDER, senderCredentials, chainId, privateFrom, privacyGroupId); try { final Method method = clazz.getMethod( "deploy", Web3j.class, TransactionManager.class, ContractGasProvider.class); final Object invoked = method.invoke( METHOD_IS_STATIC, node.privacy().getBesuClient(), privateTransactionManager, GAS_PROVIDER); return cast(invoked).send(); } catch (final Exception e) { throw new RuntimeException(e); } }
Example #13
Source File: LoadPrivateSmartContractTransaction.java From besu with Apache License 2.0 | 5 votes |
@SuppressWarnings("unchecked") @Override public T execute(final NodeRequests node) { final PrivateTransactionManager privateTransactionManager = new LegacyPrivateTransactionManager( node.privacy().getBesuClient(), GAS_PROVIDER, senderCredentials, chainId, privateFrom, privateFor); try { final Method method = clazz.getMethod( "load", String.class, Web3j.class, TransactionManager.class, ContractGasProvider.class); return (T) method.invoke( METHOD_IS_STATIC, contractAddress, node.privacy().getBesuClient(), privateTransactionManager, GAS_PROVIDER); } catch (final Exception e) { throw new RuntimeException(e); } }
Example #14
Source File: DepositContract.java From teku with Apache License 2.0 | 5 votes |
@Deprecated public static RemoteCall<DepositContract> deploy( Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return deployRemoteCall( DepositContract.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); }
Example #15
Source File: EventEmitter.java From besu with Apache License 2.0 | 5 votes |
protected EventEmitter( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #16
Source File: EventEmitter.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static EventEmitter load( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final BigInteger gasPrice, final BigInteger gasLimit) { return new EventEmitter(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #17
Source File: SimpleStorage.java From ethsigner with Apache License 2.0 | 5 votes |
protected SimpleStorage( String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #18
Source File: EventEmitter.java From besu with Apache License 2.0 | 5 votes |
public static RemoteCall<EventEmitter> deploy( final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { return deployRemoteCall( EventEmitter.class, web3j, transactionManager, contractGasProvider, BINARY, ""); }
Example #19
Source File: EventEmitter.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static RemoteCall<EventEmitter> deploy( final Web3j web3j, final TransactionManager transactionManager, final BigInteger gasPrice, final BigInteger gasLimit) { return deployRemoteCall( EventEmitter.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); }
Example #20
Source File: RevertReason.java From besu with Apache License 2.0 | 5 votes |
protected RevertReason( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #21
Source File: RevertReason.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static RevertReason load( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final BigInteger gasPrice, final BigInteger gasLimit) { return new RevertReason(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #22
Source File: DepositContract.java From teku with Apache License 2.0 | 5 votes |
protected DepositContract( String contractAddress, Web3j web3j, TransactionManager transactionManager, ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #23
Source File: SimpleStorage.java From besu with Apache License 2.0 | 5 votes |
protected SimpleStorage( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #24
Source File: CrossContractReader.java From besu with Apache License 2.0 | 5 votes |
protected CrossContractReader( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { super(BINARY, contractAddress, web3j, transactionManager, contractGasProvider); }
Example #25
Source File: CrossContractReader.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static CrossContractReader load( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final BigInteger gasPrice, final BigInteger gasLimit) { return new CrossContractReader(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }
Example #26
Source File: CrossContractReader.java From besu with Apache License 2.0 | 5 votes |
public static CrossContractReader load( final String contractAddress, final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { return new CrossContractReader(contractAddress, web3j, transactionManager, contractGasProvider); }
Example #27
Source File: CrossContractReader.java From besu with Apache License 2.0 | 5 votes |
public static RemoteCall<CrossContractReader> deploy( final Web3j web3j, final TransactionManager transactionManager, final ContractGasProvider contractGasProvider) { return deployRemoteCall( CrossContractReader.class, web3j, transactionManager, contractGasProvider, BINARY, ""); }
Example #28
Source File: CrossContractReader.java From besu with Apache License 2.0 | 5 votes |
@Deprecated public static RemoteCall<CrossContractReader> deploy( final Web3j web3j, final TransactionManager transactionManager, final BigInteger gasPrice, final BigInteger gasLimit) { return deployRemoteCall( CrossContractReader.class, web3j, transactionManager, gasPrice, gasLimit, BINARY, ""); }
Example #29
Source File: HumanStandardToken.java From client-sdk-java with Apache License 2.0 | 5 votes |
public static RemoteCall<HumanStandardToken> deploy(Web3j web3j, TransactionManager transactionManager, GasProvider contractGasProvider, BigInteger _initialAmount, String _tokenName, BigInteger _decimalUnits, String _tokenSymbol) { String encodedConstructor = FunctionEncoder.encodeConstructor( Arrays.<Type>asList(new org.web3j.abi.datatypes.generated.Uint256(_initialAmount), new org.web3j.abi.datatypes.Utf8String(_tokenName), new org.web3j.abi.datatypes.generated.Uint8(_decimalUnits), new org.web3j.abi.datatypes.Utf8String(_tokenSymbol))); return deployRemoteCall(HumanStandardToken.class, web3j, transactionManager, contractGasProvider, BINARY, encodedConstructor); }
Example #30
Source File: DepositContract.java From teku with Apache License 2.0 | 5 votes |
@Deprecated public static DepositContract load( String contractAddress, Web3j web3j, TransactionManager transactionManager, BigInteger gasPrice, BigInteger gasLimit) { return new DepositContract(contractAddress, web3j, transactionManager, gasPrice, gasLimit); }