A simple example of usage.
CMSCompressedDataStreamGenerator gen = new CMSCompressedDataStreamGenerator();
OutputStream cOut = gen.open(outputStream, new ZlibCompressor());
cOut.write(data);
cOut.close();
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private int | |
| public static final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public OutputStream | Returns: an output stream to write the data be compressed to.the stream to encode to. out, OutputCompressor the type of compressor to use. compressor)Open a compressing output stream with the PKCS#7 content type OID of "data". |
| public OutputStream | Returns: an output stream to write the data be compressed to.the content type OID. contentOID, OutputStream the stream to encode to. out, OutputCompressor the type of compressor to use. compressor)Open a compressing output stream. |
| public void | setBufferSize(int
length of octet strings to buffer the data. bufferSize)Set the underlying string size for encapsulated data |
| _bufferSize | back to summary |
|---|---|
| private int _bufferSize | |
| ZLIB | back to summary |
|---|---|
| public static final String ZLIB | |
| CMSCompressedDataStreamGenerator | back to summary |
|---|---|
| public CMSCompressedDataStreamGenerator() base constructor | |
| open | back to summary |
|---|---|
| public OutputStream open(OutputStream out, OutputCompressor compressor) throws IOException Open a compressing output stream with the PKCS#7 content type OID of "data".
| |
| open | back to summary |
|---|---|
| public OutputStream open(ASN1ObjectIdentifier contentOID, OutputStream out, OutputCompressor compressor) throws IOException Open a compressing output stream.
| |
| setBufferSize | back to summary |
|---|---|
| public void setBufferSize(int bufferSize) Set the underlying string size for encapsulated data
| |
| Modifier and Type | Field and Description |
|---|---|
| private BERSequenceGenerator | |
| private BERSequenceGenerator | |
| private OutputStream | |
| private BERSequenceGenerator |
| Access | Constructor and Description |
|---|---|
| pack-priv | CmsCompressedOutputStream(OutputStream out, BERSequenceGenerator sGen, BERSequenceGenerator cGen, BERSequenceGenerator eiGen)
|
| Modifier and Type | Method and Description |
|---|---|
| public void | close()
Overrides java. Implements java. Closes this output stream and releases any system resources associated with this stream. |
| public void | write(int
the b)byte.Implements abstract java. Writes the specified byte to this output stream. |
| public void | write(byte[]
the data. bytes, int the start offset in the data. off, int the number of bytes to write. len)Overrides java. Writes |
| public void | write(byte[]
the data. bytes)Overrides java. Writes |
| _cGen | back to summary |
|---|---|
| private BERSequenceGenerator _cGen | |
| _eiGen | back to summary |
|---|---|
| private BERSequenceGenerator _eiGen | |
| _out | back to summary |
|---|---|
| private OutputStream _out | |
| _sGen | back to summary |
|---|---|
| private BERSequenceGenerator _sGen | |
| CmsCompressedOutputStream | back to summary |
|---|---|
| pack-priv CmsCompressedOutputStream(OutputStream out, BERSequenceGenerator sGen, BERSequenceGenerator cGen, BERSequenceGenerator eiGen) | |
| close | back to summary |
|---|---|
| public void close() throws IOException Overrides java. Implements java. Doc from java. Closes this output stream and releases any system resources
associated with this stream. The general contract of
| |
| write | back to summary |
|---|---|
| public void write(int b) throws IOException Implements abstract java. Doc from java. Writes the specified byte to this output stream. The general
contract for
| |
| write | back to summary |
|---|---|
| public void write(byte[] bytes, int off, int len) throws IOException Overrides java. Doc from java. Writes
If
If
| |
| write | back to summary |
|---|---|
| public void write(byte[] bytes) throws IOException Overrides java. Doc from java. Writes
| |