Class ContractMethod


  • public class ContractMethod
    extends java.lang.Object
    Representing a Contract's method information.
    • Constructor Detail

      • ContractMethod

        public ContractMethod()
        Creates a ContractMethod instance.
      • ContractMethod

        public ContractMethod​(Caver caver,
                              java.lang.String type,
                              java.lang.String name,
                              java.util.List<ContractIOType> inputs,
                              java.util.List<ContractIOType> outputs,
                              java.lang.String signature,
                              java.lang.String contractAddress)
        Creates a ContractMethod instance.
        Parameters:
        caver - A Caver instance.
        type - The input type. It always set "function"
        name - The function name
        inputs - The list of ContractIOType contains to function parameter information.
        outputs - The list of ContractIOType
        signature - The function signature string.
        contractAddress - The contract address
    • Method Detail

      • call

        public java.util.List<Type> call​(java.util.List<java.lang.Object> arguments)
                                  throws java.io.IOException,
                                         java.lang.ClassNotFoundException,
                                         java.lang.NoSuchMethodException,
                                         java.lang.InstantiationException,
                                         java.lang.IllegalAccessException,
                                         java.lang.reflect.InvocationTargetException
        Execute smart contract method in the EVM without sending any transaction.
        Parameters:
        arguments - A List of parameter to call smart contract method.
        Returns:
        List
        Throws:
        java.io.IOException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • call

        public java.util.List<Type> call​(java.util.List<java.lang.Object> arguments,
                                         CallObject callObject)
                                  throws java.io.IOException,
                                         java.lang.ClassNotFoundException,
                                         java.lang.NoSuchMethodException,
                                         java.lang.InstantiationException,
                                         java.lang.IllegalAccessException,
                                         java.lang.reflect.InvocationTargetException
        Execute smart contract method in the EVM without sending any transaction.

        When creating CallObject, it need not to fill 'data', 'to' fields.

        The 'data', 'to' fields automatically filled in call() method.

        Parameters:
        arguments - A List of parameter to call smart contract method.
        callObject - A CallObject instance to 'call' smart contract method.
        Returns:
        List
        Throws:
        java.io.IOException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • send

        public TransactionReceipt.TransactionReceiptData send​(java.util.List<java.lang.Object> arguments)
                                                       throws java.io.IOException,
                                                              org.web3j.protocol.exceptions.TransactionException,
                                                              java.lang.ClassNotFoundException,
                                                              java.lang.NoSuchMethodException,
                                                              java.lang.InstantiationException,
                                                              java.lang.IllegalAccessException,
                                                              java.lang.reflect.InvocationTargetException
        Send a transaction to deploy smart contract or execute smart contract's method.
         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
             String abi = "abi";
             String bytecode = "Contract bytecode";
        
             String sender = "0x{sender address}";
             Contract contract = caver.contract.create(abi);
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
             contract.setDefaultSendOptions(sendOptions);
        
             TransactionReceipt.TransactionReceiptData deployed = contract.getMethod("constructor").send(Arrays.asList(bytecode, constructor_param1, constructor_param2...));
         
         It is used defaultSendOption field to sendOptions.
         It sets TransactionReceiptProcessor to PollingTransactionReceiptProcessor.
         
        Parameters:
        arguments - A List of parameter to call smart contract method.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • send

        public TransactionReceipt.TransactionReceiptData send​(java.util.List<java.lang.Object> arguments,
                                                              SendOptions options)
                                                       throws java.io.IOException,
                                                              org.web3j.protocol.exceptions.TransactionException,
                                                              java.lang.ClassNotFoundException,
                                                              java.lang.NoSuchMethodException,
                                                              java.lang.InstantiationException,
                                                              java.lang.IllegalAccessException,
                                                              java.lang.reflect.InvocationTargetException
        Send a transaction to deploy smart contract or execute smart contract's method.
         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
             String abi = "abi";
             String bytecode = "Contract bytecode";
        
             String sender = "0x{sender address}";
             Contract contract = caver.contract.create(abi);
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
        
             TransactionReceipt.TransactionReceiptData deployed = contract.getMethod("constructor").send(Arrays.asList(bytecode, constructor_param1, constructor_param2...), sendOptions);
         
         It sets TransactionReceiptProcessor to PollingTransactionReceiptProcessor.
         
        Parameters:
        arguments - A List of parameter to call smart contract method.
        options - An option to deploy or execute smart contract method.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • send

        public TransactionReceipt.TransactionReceiptData send​(java.util.List<java.lang.Object> arguments,
                                                              SendOptions options,
                                                              TransactionReceiptProcessor processor)
                                                       throws java.io.IOException,
                                                              org.web3j.protocol.exceptions.TransactionException,
                                                              java.lang.ClassNotFoundException,
                                                              java.lang.NoSuchMethodException,
                                                              java.lang.InstantiationException,
                                                              java.lang.IllegalAccessException,
                                                              java.lang.reflect.InvocationTargetException
        Send a transaction to deploy smart contract or execute smart contract's method.
         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
             String abi = "abi";
             String bytecode = "Contract bytecode";
        
             String sender = "0x{sender address}";
             Contract contract = caver.contract.create(abi);
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
        
             TransactionReceiptProcessor receiptProcessor = new PollingTransactionReceiptProcessor(caver, 1000, 15);
             TransactionReceipt.TransactionReceiptData deployed = contract.getMethod("constructor").send(Arrays.asList(bytecode, constructor_param1, constructor_param2...), sendOptions, receiptProcessor);
         
         
        Parameters:
        arguments - A List of parameter to call smart contract method.
        options - An option to deploy or execute smart contract method.
        processor - A TransactionReceiptProcessor to get receipt.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • sign

        public AbstractTransaction sign​(java.util.List<java.lang.Object> arguments)
                                 throws java.lang.ClassNotFoundException,
                                        java.lang.reflect.InvocationTargetException,
                                        java.lang.NoSuchMethodException,
                                        java.lang.InstantiationException,
                                        java.lang.IllegalAccessException,
                                        java.io.IOException
        Create and sign a transaction with the input data generated by the passed argument.

         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
        
             String abi = "abi";
             String bytecode = "Contract bytecode";
             String sender = "0x{sender address}";
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
        
             Contract contract = caver.contract.create(abi);
             contract.setDefaultSendOptions(sendOptions);
        
             TransactionReceipt.TransactionReceiptData deployed = contract.getMethod("constructor").sign(Arrays.asList(bytecode, constructor_param1, constructor_param2...));
         
         It is used defaultSendOption field to sendOptions.
         
        Parameters:
        arguments - The list of arguments to deploy or execute a smart contract.
        Returns:
        AbstractTransaction
        Throws:
        java.lang.ClassNotFoundException
        java.lang.reflect.InvocationTargetException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.io.IOException
      • sign

        public AbstractTransaction sign​(java.util.List<java.lang.Object> arguments,
                                        SendOptions sendOptions)
                                 throws java.lang.ClassNotFoundException,
                                        java.lang.reflect.InvocationTargetException,
                                        java.lang.NoSuchMethodException,
                                        java.lang.InstantiationException,
                                        java.lang.IllegalAccessException,
                                        java.io.IOException
        Create and sign a transaction with the input data generated by the passed argument.

         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
        
             String abi = "abi";
             String bytecode = "Contract bytecode";
             String sender = "0x{sender address}";
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
        
             Contract contract = caver.contract.create(abi);
             TransactionReceipt.TransactionReceiptData deployed = contract.getMethod("constructor").sign(Arrays.asList(bytecode, constructor_param1, constructor_param2...), sendOptions);
         
         
        Parameters:
        arguments - The list of arguments to deploy or execute a smart contract.
        sendOptions - An option to deploy or execute smart contract method.
        Returns:
        AbstractTransaction
        Throws:
        java.lang.ClassNotFoundException
        java.lang.reflect.InvocationTargetException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.io.IOException
      • signAsFeePayer

        public AbstractFeeDelegatedTransaction signAsFeePayer​(java.util.List<java.lang.Object> arguments)
                                                       throws java.lang.ClassNotFoundException,
                                                              java.lang.reflect.InvocationTargetException,
                                                              java.lang.NoSuchMethodException,
                                                              java.lang.InstantiationException,
                                                              java.lang.IllegalAccessException,
                                                              java.io.IOException
        Create and sign a transaction as a fee payer with the input data generated by the passed argument.

         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
        
             String abi = "abi";
             String bytecode = "Contract bytecode";
             String sender = "0x{sender address}";
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
             sendOptions.setFeeDelegation(true);
             sendOptions.setFeePayer("0x{feePayer}");
        
             Contract contract = caver.contract.create(abi);
             contract.setDefaultSendOptions(sendOptions);
             AbstractTransaction transaction = contract.getMethod("constructor").signAsFeePayer(Arrays.asList(bytecode, constructor_param1, constructor_param2....));
         
         It is used defaultSendOption field to sendOptions.
         
        Parameters:
        arguments - The list of arguments to deploy or execute a smart contract.
        Returns:
        AbstractTransaction
        Throws:
        java.lang.ClassNotFoundException
        java.lang.reflect.InvocationTargetException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.io.IOException
      • signAsFeePayer

        public AbstractFeeDelegatedTransaction signAsFeePayer​(java.util.List<java.lang.Object> arguments,
                                                              SendOptions sendOptions)
                                                       throws java.lang.ClassNotFoundException,
                                                              java.lang.reflect.InvocationTargetException,
                                                              java.lang.NoSuchMethodException,
                                                              java.lang.InstantiationException,
                                                              java.lang.IllegalAccessException,
                                                              java.io.IOException
        Create and sign a transaction as a fee payer with the input data generated by the passed argument.

         If the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
             Caver caver = new Caver(Caver.DEFAULT_URL);
        
             String abi = "abi";
             String bytecode = "Contract bytecode";
             String sender = "0x{sender address}";
        
             SendOptions sendOptions = new SendOptions();
             sendOptions.setFrom("0x{from}");
             sendOptions.setGas(BigInteger.valueOf(100000000));
             sendOptions.setFeeDelegation(true);
             sendOptions.setFeePayer("0x{feePayer}");
        
             Contract contract = caver.contract.create(abi);
             AbstractTransaction transaction = contract.getMethod("constructor").signAsFeePayer(Arrays.asList(bytecode, constructor_param1, constructor_param2....), sendOptions);
         
         
        Parameters:
        arguments - The list of arguments to deploy or execute a smart contract.
        sendOptions - An option to deploy or execute smart contract method.
        Returns:
        AbstractTransaction
        Throws:
        java.lang.ClassNotFoundException
        java.lang.reflect.InvocationTargetException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.io.IOException
      • encodeABI

        public java.lang.String encodeABI​(java.util.List<java.lang.Object> arguments)
                                   throws java.lang.ClassNotFoundException,
                                          java.lang.NoSuchMethodException,
                                          java.lang.InstantiationException,
                                          java.lang.IllegalAccessException,
                                          java.lang.reflect.InvocationTargetException
        Encodes the ABI for this method. It returns 32-bit function signature hash plus the encoded passed parameters.

        If the 'type' field is a "constructor", it encodes a constructor params to deploy.

         When the 'type' field is a "constructor", the arguments parsed as follow.
           - arguments[0] : Smart contract's bytecode.
           - others : The constructor arguments to deploy smart contract.
         
        Parameters:
        arguments - A List of parameter to encode function signature and parameters
        Returns:
        The encoded ABI byte code to send via a transaction or call.
        Throws:
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • estimateGas

        public java.lang.String estimateGas​(java.util.List<java.lang.Object> arguments,
                                            CallObject callObject)
                                     throws java.io.IOException,
                                            java.lang.ClassNotFoundException,
                                            java.lang.NoSuchMethodException,
                                            java.lang.InstantiationException,
                                            java.lang.IllegalAccessException,
                                            java.lang.reflect.InvocationTargetException
        Estimate the gas to execute the contract's method.
        Parameters:
        arguments - A List of parameter that solidity wrapper type
        callObject - An option to execute smart contract method.
        Returns:
        String
        Throws:
        java.io.IOException
        java.lang.ClassNotFoundException
        java.lang.NoSuchMethodException
        java.lang.InstantiationException
        java.lang.IllegalAccessException
        java.lang.reflect.InvocationTargetException
      • callWithSolidityWrapper

        public java.util.List<Type> callWithSolidityWrapper​(java.util.List<Type> arguments)
                                                     throws java.io.IOException,
                                                            java.lang.ClassNotFoundException
        Execute smart contract method in the EVM without sending any transaction.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        arguments - A List of parameter that solidity wrapper type to call smart contract method.
        Returns:
        List
        Throws:
        java.io.IOException
        java.lang.ClassNotFoundException
      • callWithSolidityWrapper

        public java.util.List<Type> callWithSolidityWrapper​(java.util.List<Type> arguments,
                                                            CallObject callObject)
                                                     throws java.io.IOException,
                                                            java.lang.ClassNotFoundException
        Execute smart contract method in the EVM without sending any transaction.

        When creating CallObject, it need not to fill 'data', 'to' fields.

        The 'data', 'to' fields automatically filled in call() method.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        arguments - A List of parameter that solidity wrapper type to call smart contract method.
        callObject - A CallObject instance to 'call' smart contract method.
        Returns:
        List
        Throws:
        java.io.IOException
        java.lang.ClassNotFoundException
      • sendWithSolidityWrapper

        public TransactionReceipt.TransactionReceiptData sendWithSolidityWrapper​(java.util.List<Type> wrapperArguments)
                                                                          throws java.io.IOException,
                                                                                 org.web3j.protocol.exceptions.TransactionException
        Send a transaction to smart contract and execute its method using solidity type wrapper class.

        It is used defaultSendOption field to sendOptions.

        It sets TransactionReceiptProcessor to PollingTransactionReceiptProcessor.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped solidity wrapper class.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
      • sendWithSolidityWrapper

        public TransactionReceipt.TransactionReceiptData sendWithSolidityWrapper​(java.util.List<Type> wrapperArguments,
                                                                                 SendOptions options)
                                                                          throws java.io.IOException,
                                                                                 org.web3j.protocol.exceptions.TransactionException
        Send a transaction to smart contract and execute its method using solidity type wrapper class.

        It sets TransactionReceiptProcessor to PollingTransactionReceiptProcessor.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped solidity wrapper class.
        options - An option to execute smart contract method.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
      • sendWithSolidityWrapper

        public TransactionReceipt.TransactionReceiptData sendWithSolidityWrapper​(java.util.List<Type> wrapperArguments,
                                                                                 SendOptions options,
                                                                                 TransactionReceiptProcessor processor)
                                                                          throws java.io.IOException,
                                                                                 org.web3j.protocol.exceptions.TransactionException
        Send a transaction to smart contract and execute its method using solidity type wrapper class.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped solidity wrapper class.
        options - An option to execute smart contract method.
        processor - A TransactionReceiptProcessor to get receipt.
        Returns:
        TransactionReceiptData
        Throws:
        java.io.IOException
        org.web3j.protocol.exceptions.TransactionException
      • signWithSolidityWrapper

        public AbstractTransaction signWithSolidityWrapper​(java.util.List<Type> wrapperArguments)
                                                    throws java.io.IOException
        Create and sign a transaction with the input data generated by the passed argument that wrapped by solidity type class.

        It creates a transaction related to SmartContractExecution to execute smart contract method.

        It is used defaultSendOption field to sendOptions.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped by solidity type wrapper class.
        Returns:
        AbstractTransaction
        Throws:
        java.io.IOException
      • signWithSolidityWrapper

        public AbstractTransaction signWithSolidityWrapper​(java.util.List<Type> wrapperArguments,
                                                           SendOptions sendOptions)
                                                    throws java.io.IOException
        Create and sign a transaction with the input data generated by the passed argument that wrapped by solidity type class.

        It creates a transaction related to SmartContractExecution to execute smart contract method.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped by solidity type wrapper class.
        sendOptions - An option to execute smart contract method.
        Returns:
        AbstractTransaction
        Throws:
        java.io.IOException
      • signAsFeePayerWithSolidityWrapper

        public AbstractFeeDelegatedTransaction signAsFeePayerWithSolidityWrapper​(java.util.List<Type> wrapperArguments)
                                                                          throws java.io.IOException
        Create and sign a transaction as a fee payer with the input data generated by the passed argument that wrapped by solidity type class.

        It creates a transaction related to FeeDelegatedSmartContractExecution to execute smart contract method.

        It is used defaultSendOption field to sendOptions.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped by solidity type wrapper class.
        Returns:
        AbstractTransaction
        Throws:
        java.io.IOException
      • signAsFeePayerWithSolidityWrapper

        public AbstractFeeDelegatedTransaction signAsFeePayerWithSolidityWrapper​(java.util.List<Type> wrapperArguments,
                                                                                 SendOptions sendOptions)
                                                                          throws java.io.IOException
        Create and sign a transaction with the input data generated by the passed argument that wrapped by solidity type class.

        It creates a transaction related to FeeDelegatedSmartContractExecution to execute smart contract method.

        It is recommended to use this function when you want to execute one of the functions with the same number of parameters.

        Parameters:
        wrapperArguments - A List of parameter that wrapped by solidity type wrapper class.
        sendOptions - An option to execute smart contract method.
        Returns:
        AbstractTransaction
        Throws:
        java.io.IOException
      • encodeABIWithSolidityWrapper

        public java.lang.String encodeABIWithSolidityWrapper​(java.util.List<Type> wrapperArguments)
        Encodes the ABI for this method. It returns 32-bit function signature hash plus the encoded passed parameters. It is recommended to use this function when you want to execute one of the functions with the same number of parameters.
        Parameters:
        wrapperArguments - A List of parameter that solidity wrapper class
        Returns:
        The encoded ABI byte code to send via a transaction or call.
      • estimateGasWithSolidityWrapper

        public java.lang.String estimateGasWithSolidityWrapper​(java.util.List<Type> arguments,
                                                               CallObject callObject)
                                                        throws java.io.IOException
        Estimate the gas to execute the Contract's method using Solidity type wrapper class. It is recommended to use this function when you want to execute one of the functions with the same number of parameters.
        Parameters:
        arguments - The arguments that need to execute smart contract method.
        callObject - An option to execute smart contract method.
        Returns:
        String
        Throws:
        java.io.IOException
      • checkTypeValid

        public void checkTypeValid​(java.util.List<java.lang.Object> types)
        Check that passed parameter is valid to execute smart contract method. - check parameter count. - check defined parameter solidity type and parameter solidity wrapper type.
        Parameters:
        types - A List of parameter that solidity wrapper type
      • getCaver

        public Caver getCaver()
        Getter function for Caver.
        Returns:
        Caver
      • getType

        public java.lang.String getType()
        Getter function for type.
        Returns:
        String
      • getName

        public java.lang.String getName()
        Getter function for name.
        Returns:
        String
      • getInputs

        public java.util.List<ContractIOType> getInputs()
        Getter function for input.
        Returns:
        List
      • getOutputs

        public java.util.List<ContractIOType> getOutputs()
        Getter function for output.
        Returns:
        List
      • getSignature

        public java.lang.String getSignature()
        Getter function for signature.
        Returns:
        String
      • getContractAddress

        public java.lang.String getContractAddress()
        Getter function for contract address
        Returns:
        String
      • getDefaultSendOptions

        public SendOptions getDefaultSendOptions()
        Getter function for DefaultSendOptions
        Returns:
        SendOptions
      • getNextContractMethods

        public java.util.List<ContractMethod> getNextContractMethods()
      • setSignature

        public void setSignature​(java.lang.String signature)
        Setter function for function signature.
        Parameters:
        signature - A function signature
      • setWallet

        public void setWallet​(IWallet wallet)
        Setter function for wallet
        Parameters:
        wallet - The class instance implemented IWallet interface to sign transaction.
      • makeSendOption

        public SendOptions makeSendOption​(SendOptions sendOption)
        Make SendOptions instance by comparing with defaultSendOption and passed parameter "options" Passed parameter "options" has higher priority than "defaultSendOption" field.
        Parameters:
        sendOption - SendOptions instance
        Returns:
        SendOption
      • findMethodBySignature

        public ContractMethod findMethodBySignature​(java.lang.String functionSignature)
        Find a ContractMethod instance that has the function signature same as passed as a parameter.
        Parameters:
        functionSignature - The function signature to find a ContractMethod instance.
        Returns:
        ContractMethod