public class StreamOptions extends Object
Constructor and Description |
---|
StreamOptions(int bufferSize)
An option object with the given buffer size set.
|
StreamOptions(StreamOptions other) |
Modifier and Type | Method and Description |
---|---|
StreamOptions |
bufferSize(int bufferSize) |
EncryptionAlgorithm |
getAlgorithm() |
int |
getBufferSize() |
CompressionCodec |
getCodec() |
CompressionCodec.Options |
getCodecOptions() |
byte[] |
getIv() |
Key |
getKey() |
boolean |
isEncrypted() |
StreamOptions |
modifyIv(Consumer<byte[]> modifier)
Modify the IV.
|
String |
toString() |
StreamOptions |
withCodec(CompressionCodec codec,
CompressionCodec.Options options)
Compress using the given codec.
|
StreamOptions |
withEncryption(EncryptionAlgorithm algorithm,
Key key) |
public StreamOptions(StreamOptions other)
public StreamOptions(int bufferSize)
bufferSize
- the size of the buffers.public StreamOptions bufferSize(int bufferSize)
public StreamOptions withCodec(CompressionCodec codec, CompressionCodec.Options options)
codec
- the codec to compress withpublic StreamOptions withEncryption(EncryptionAlgorithm algorithm, Key key)
public StreamOptions modifyIv(Consumer<byte[]> modifier)
modifier
- the function to modify the IVpublic CompressionCodec getCodec()
public CompressionCodec.Options getCodecOptions()
public byte[] getIv()
public int getBufferSize()
public boolean isEncrypted()
public Key getKey()
public EncryptionAlgorithm getAlgorithm()
Copyright © 2013–2021 The Apache Software Foundation. All rights reserved.