Inputs inherit their value from the connected output. If there not yet
an output connected, then you cannot tell their value. See
TransactionInput.getValue().

Transaction.getFee() calculates the fee but once again, it needs all
inputs connected to their outputs. Otherwise it will return null.


On 2018-07-27 11:32, Oleksii Stepanenko wrote:
> 
> 
> Hello, I have faced with the next problem: I can't extract
> TransactionInputs values and TxFee from transaction object with
> bitcoinj. I tried to use the method
> 
> |
>  peerGroup.downloadBlockChain();
> |
> 
> But it doesn't help me. 
> 
> <https://lh3.googleusercontent.com/-z6f1FikdjhA/W1rmRbjolrI/AAAAAAAAAAc/5C8_OCvgLoYjZ0nkXP05rriItIkxsAcDACLcBGAs/s1600/%25D0%2591%25D0%25B5%25D0%25B7%2B%25D0%25BD%25D0%25B0%25D0%25B7%25D0%25B2%25D0%25B0%25D0%25BD%25D0%25B8%25D1%258F.png>
> 
> How may I receive the value of TransactionInput or at least fee of the
> transaction? 
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "bitcoinj" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to [email protected]
> <mailto:[email protected]>.
> For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google Groups 
"bitcoinj" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to