mirror of
https://github.com/bitcoinj/bitcoinj.git
synced 2025-02-24 14:50:57 +01:00
Transaction: In toString(), if an output is unconnected still print the outpoint.
This commit is contained in:
parent
4055e77ce9
commit
0f811846c9
1 changed files with 4 additions and 2 deletions
|
@ -803,16 +803,18 @@ public class Transaction extends ChildMessage {
|
||||||
}
|
}
|
||||||
final TransactionOutPoint outpoint = in.getOutpoint();
|
final TransactionOutPoint outpoint = in.getOutpoint();
|
||||||
final TransactionOutput connectedOutput = outpoint.getConnectedOutput();
|
final TransactionOutput connectedOutput = outpoint.getConnectedOutput();
|
||||||
|
s.append(indent).append(" ");
|
||||||
if (connectedOutput != null) {
|
if (connectedOutput != null) {
|
||||||
Script scriptPubKey = connectedOutput.getScriptPubKey();
|
Script scriptPubKey = connectedOutput.getScriptPubKey();
|
||||||
ScriptType scriptType = scriptPubKey.getScriptType();
|
ScriptType scriptType = scriptPubKey.getScriptType();
|
||||||
s.append(indent).append(" ");
|
|
||||||
if (scriptType != null)
|
if (scriptType != null)
|
||||||
s.append(scriptType).append(" addr:").append(scriptPubKey.getToAddress(params));
|
s.append(scriptType).append(" addr:").append(scriptPubKey.getToAddress(params));
|
||||||
else
|
else
|
||||||
s.append("unknown script type");
|
s.append("unknown script type");
|
||||||
s.append(" outpoint:").append(outpoint).append('\n');
|
} else {
|
||||||
|
s.append("unconnected");
|
||||||
}
|
}
|
||||||
|
s.append(" outpoint:").append(outpoint).append('\n');
|
||||||
if (in.hasSequence()) {
|
if (in.hasSequence()) {
|
||||||
s.append(indent).append(" sequence:").append(Long.toHexString(in.getSequenceNumber()));
|
s.append(indent).append(" sequence:").append(Long.toHexString(in.getSequenceNumber()));
|
||||||
if (in.isOptInFullRBF())
|
if (in.isOptInFullRBF())
|
||||||
|
|
Loading…
Add table
Reference in a new issue