Package | Description |
---|---|
com.guardtime.ksi.tree |
Classes and interfaces to build a hash tree
|
com.guardtime.ksi.unisignature |
Interfaces to decode and encode KSI signatures
|
Modifier and Type | Method and Description |
---|---|
void |
HashTreeBuilder.add(ImprintNode... nodes)
Adds a new array of child nodes to the hash tree.
|
void |
HashTreeBuilder.add(ImprintNode node)
Adds a new single child node to the hash tree.
|
void |
HashTreeBuilder.add(ImprintNode node,
IdentityMetadata metadata)
Adds a new leaf with its metadata to the hash tree.
|
void |
TreeBuilder.add(N node,
IdentityMetadata metadata)
Adds a new leaf with its metadata to the binary tree.
|
protected ImprintNode |
HashTreeBuilder.aggregate(ImprintNode left,
ImprintNode right) |
ImprintNode |
HashTreeBuilder.build()
Builds the hash tree and returns the root hash of the tree.
|
long |
HashTreeBuilder.calculateHeight(ImprintNode node)
Calculates the height of the hash tree in case a new node would be added.
|
long |
HashTreeBuilder.calculateHeight(ImprintNode node,
IdentityMetadata metadata)
Calculates the height of the hash tree in case a new node with metadata would be added.
|
long |
TreeBuilder.calculateHeight(N node,
IdentityMetadata metadata)
Calculates the binary tree height if new leaf with metadata would be added.
|
static DataHash |
Util.hash(HashAlgorithm hashAlgorithm,
byte[] left,
byte[] right,
long level)
Calculates a data hash using the following formula: H(left||right||Util.encodeUnsignedLong(level)) where
H is a cryptographic hash function defined by
hashAlgorithm . |
Modifier and Type | Method and Description |
---|---|
DataHash |
RFC3161Record.getOutputHash(HashAlgorithm hashAlgorithm)
Returns the RFC3161 record output data hash
|
Copyright © 2024 Guardtime. All rights reserved.