-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathFtsResult.java
37 lines (31 loc) · 890 Bytes
/
FtsResult.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import java.util.List;
/**
* A class containing the result produced by follow-the-satoshi.
*/
public class FtsResult {
private final List<ProofEntry> merkleProof;
private final Stakeholder stakeholder;
public FtsResult(List<ProofEntry> merkleProof, Stakeholder stakeholder) {
this.merkleProof = merkleProof;
this.stakeholder = stakeholder;
}
public Stakeholder getStakeholder() {
return stakeholder;
}
public List<ProofEntry> getMerkleProof() {
return merkleProof;
}
@Override
public String toString() {
final StringBuilder sb = new StringBuilder();
sb.append("merkleProof {\n");
for (ProofEntry proofEntry : merkleProof) {
sb.append(String.format(" %s\n", proofEntry.toString()));
}
sb.append("}\n");
sb.append("stakeholder {\n");
sb.append(String.format(" %s\n", stakeholder.toString()));
sb.append("}");
return sb.toString();
}
}