public class SplitFileSegmentKeys
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable
Modifier and Type | Field and Description |
---|---|
int |
checkBlocks |
byte[] |
commonDecryptKey
Modern splitfiles have a common decrypt key
|
byte[] |
commonExtraBytes
Modern splitfiles have common extra bytes
|
int |
dataBlocks |
byte[] |
decryptKeys
Individual per-block decryption keys.
|
byte[] |
extraBytesForKeys
Individual per-block extra bytes.
|
byte[] |
routingKeys
Routing keys.
|
Modifier | Constructor and Description |
---|---|
protected |
SplitFileSegmentKeys() |
|
SplitFileSegmentKeys(int blocksPerSegment,
int checkBlocksPerSegment,
byte[] splitfileSingleCryptoKey,
byte splitfileSingleCryptoAlgorithm) |
Modifier and Type | Method and Description |
---|---|
SplitFileSegmentKeys |
clone() |
boolean |
equals(java.lang.Object obj) |
int |
getBlockNumber(ClientCHK key,
boolean[] ignoreSlots) |
int |
getBlockNumber(NodeCHK key,
boolean[] ignoreSlots) |
int[] |
getBlockNumbers(NodeCHK key,
boolean[] ignoreSlots) |
int |
getCheckBlocks() |
int |
getDataBlocks() |
ClientCHK |
getKey(int x,
boolean[] ignoreSlots,
boolean copy) |
NodeCHK |
getNodeKey(int x,
boolean[] ignoreSlots,
boolean copy) |
int |
hashCode() |
NodeCHK[] |
listNodeKeys(boolean[] foundKeys,
boolean copy) |
void |
readKeys(java.io.DataInputStream dis,
boolean check) |
void |
setKey(int i,
ClientCHK key) |
static int |
storedKeysLength(int dataBlocks,
int checkBlocks,
boolean commonDecryptKey) |
int |
totalKeys() |
void |
writeKeys(java.io.DataOutputStream dos,
boolean check) |
public final int dataBlocks
public final int checkBlocks
public final byte[] commonDecryptKey
public final byte[] commonExtraBytes
public final byte[] routingKeys
public final byte[] decryptKeys
public final byte[] extraBytesForKeys
public SplitFileSegmentKeys(int blocksPerSegment, int checkBlocksPerSegment, byte[] splitfileSingleCryptoKey, byte splitfileSingleCryptoAlgorithm)
protected SplitFileSegmentKeys()
public int getBlockNumber(ClientCHK key, boolean[] ignoreSlots)
public int getBlockNumber(NodeCHK key, boolean[] ignoreSlots)
public int[] getBlockNumbers(NodeCHK key, boolean[] ignoreSlots)
public NodeCHK getNodeKey(int x, boolean[] ignoreSlots, boolean copy)
public ClientCHK getKey(int x, boolean[] ignoreSlots, boolean copy)
public void readKeys(java.io.DataInputStream dis, boolean check) throws java.io.IOException
java.io.IOException
public void writeKeys(java.io.DataOutputStream dos, boolean check) throws java.io.IOException
java.io.IOException
public static int storedKeysLength(int dataBlocks, int checkBlocks, boolean commonDecryptKey)
public int getDataBlocks()
public int getCheckBlocks()
public void setKey(int i, ClientCHK key)
public NodeCHK[] listNodeKeys(boolean[] foundKeys, boolean copy)
public SplitFileSegmentKeys clone()
clone
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int totalKeys()