public class VirgilChunkCipher extends VirgilCipherBase implements AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
static long |
kPreferredChunkSize |
swigCMemOwn| Modifier | Constructor and Description |
|---|---|
|
VirgilChunkCipher()
Create a new instance of
VirgilChunkCipher |
protected |
VirgilChunkCipher(long cPtr,
boolean cMemoryOwn) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
decryptWithKey(VirgilDataSource source,
VirgilDataSink sink,
byte[] recipientId,
byte[] privateKey)
Decrypt data read from given source for recipient defined by id and
private key, and write it to the sink.
|
void |
decryptWithKey(VirgilDataSource source,
VirgilDataSink sink,
byte[] recipientId,
byte[] privateKey,
byte[] privateKeyPassword)
Decrypt data read from given source for recipient defined by id and
private key, and write it to the sink.
|
void |
decryptWithPassword(VirgilDataSource source,
VirgilDataSink sink,
byte[] pwd)
Decrypt data read from given source for recipient defined by id and
private key, and write it to the sink.
|
void |
delete() |
void |
encrypt(VirgilDataSource source,
VirgilDataSink sink)
Encrypt data read from given source and write it the sink.
|
void |
encrypt(VirgilDataSource source,
VirgilDataSink sink,
boolean embedContentInfo)
Encrypt data read from given source and write it the sink.
|
void |
encrypt(VirgilDataSource source,
VirgilDataSink sink,
boolean embedContentInfo,
long preferredChunkSize)
Encrypt data read from given source and write it the sink.
|
protected void |
finalize() |
protected static long |
getCPtr(VirgilChunkCipher obj) |
addKeyRecipient, addPasswordRecipient, computeShared, computeShared, customParams, defineContentInfoSize, getContentInfo, getCPtr, keyRecipientExists, passwordRecipientExists, removeAllRecipients, removeKeyRecipient, removePasswordRecipient, setContentInfoprotected VirgilChunkCipher(long cPtr,
boolean cMemoryOwn)
public VirgilChunkCipher()
VirgilChunkCipherprotected static long getCPtr(VirgilChunkCipher obj)
protected void finalize()
finalize in class VirgilCipherBasepublic void delete()
delete in class VirgilCipherBasepublic void close()
close in interface AutoCloseableclose in class VirgilCipherBasepublic void encrypt(VirgilDataSource source, VirgilDataSink sink, boolean embedContentInfo, long preferredChunkSize)
source - The source of the data to be encrypted.sink - The target sink for encrypted data.embedContentInfo - Determines whether to embed content info the the encrypted
data, or not.preferredChunkSize - Chunk size that will appropriate.public void encrypt(VirgilDataSource source, VirgilDataSink sink, boolean embedContentInfo)
source - The source of the data to be encrypted.sink - The target sink for encrypted data.embedContentInfo - Determines whether to embed content info the the encrypted
data, or not.public void encrypt(VirgilDataSource source, VirgilDataSink sink)
source - The source of the data to be encrypted.sink - The target sink for encrypted data.public void decryptWithKey(VirgilDataSource source, VirgilDataSink sink, byte[] recipientId, byte[] privateKey, byte[] privateKeyPassword)
source - The source of the data to be decrypted.sink - The target sink for decrypted data.recipientId - The recipient identifier.privateKey - Recipient's private key protected with password.privateKeyPassword - The private key password.public void decryptWithKey(VirgilDataSource source, VirgilDataSink sink, byte[] recipientId, byte[] privateKey)
source - The source of the data to be decrypted.sink - The target sink for decrypted data.recipientId - The recipient identifier.privateKey - Recipient's private key.public void decryptWithPassword(VirgilDataSource source, VirgilDataSink sink, byte[] pwd)
source - The source of the data to be decrypted.sink - The target sink for decrypted data.pwd - The password.Copyright © 2016. All rights reserved.