3
0
mirror of https://github.com/Qortal/altcoinj.git synced 2025-02-12 10:15:52 +00:00

Hide some fields in PartialMerkleTree

This commit is contained in:
Mike Hearn 2014-08-11 19:21:25 +02:00
parent 19b73600c8
commit 5220fb5141
2 changed files with 8 additions and 4 deletions

View File

@ -115,6 +115,6 @@ public class FilteredBlock extends Message {
/** Number of transactions in this block, before it was filtered */
public int getTransactionCount() {
return merkleTree.transactionCount;
return merkleTree.getTransactionCount();
}
}

View File

@ -50,13 +50,13 @@ import java.util.List;
*/
public class PartialMerkleTree extends Message {
// the total number of transactions in the block
int transactionCount;
private int transactionCount;
// node-is-parent-of-matched-txid bits
byte[] matchedChildBits;
private byte[] matchedChildBits;
// txids and internal hashes
List<Sha256Hash> hashes;
private List<Sha256Hash> hashes;
public PartialMerkleTree(NetworkParameters params, byte[] payloadBytes, int offset) throws ProtocolException {
super(params, payloadBytes, offset);
@ -176,4 +176,8 @@ public class PartialMerkleTree extends Message {
return merkleRoot;
}
public int getTransactionCount() {
return transactionCount;
}
}