|
Bouncy Castle Cryptography Library 1.81 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.OutputStream
org.bouncycastle.bcpg.BCPGOutputStream
Basic output stream.
Field Summary |
Fields inherited from interface org.bouncycastle.bcpg.PacketTags |
AEAD_ENC_DATA, COMPRESSED_DATA, EXPERIMENTAL_1, EXPERIMENTAL_2, EXPERIMENTAL_3, EXPERIMENTAL_4, LITERAL_DATA, MARKER, MOD_DETECTION_CODE, ONE_PASS_SIGNATURE, PADDING, PUBLIC_KEY, PUBLIC_KEY_ENC_SESSION, PUBLIC_SUBKEY, RESERVED, SECRET_KEY, SECRET_SUBKEY, SIGNATURE, SYM_ENC_INTEGRITY_PRO, SYMMETRIC_KEY_ENC, SYMMETRIC_KEY_ENC_SESSION, TRUST, USER_ATTRIBUTE, USER_ID |
Fields inherited from interface org.bouncycastle.bcpg.CompressionAlgorithmTags |
BZIP2, UNCOMPRESSED, ZIP, ZLIB |
Constructor Summary | |
BCPGOutputStream(java.io.OutputStream out)
Base constructor - generate a PGP protocol encoding with old-style packets whenever there is an alternative for backwards compatibility. |
|
BCPGOutputStream(java.io.OutputStream out,
boolean newFormatOnly)
Base constructor specifying whether to use packets in the new format wherever possible. |
|
BCPGOutputStream(java.io.OutputStream out,
int tag)
Create a stream representing an old style partial object. |
|
BCPGOutputStream(java.io.OutputStream out,
int tag,
byte[] buffer)
Create a new style partial input stream buffered into chunks. |
|
BCPGOutputStream(java.io.OutputStream out,
int tag,
long length)
|
|
BCPGOutputStream(java.io.OutputStream out,
int tag,
long length,
boolean oldFormat)
Create a stream representing a general packet. |
|
BCPGOutputStream(java.io.OutputStream out,
PacketFormat packetFormat)
|
Method Summary | |
void |
close()
|
void |
finish()
Finish writing out the current packet without closing the underlying stream. |
void |
flush()
Flush the underlying stream. |
static BCPGOutputStream |
wrap(java.io.OutputStream out)
If the argument is a BCPGOutputStream , return it.
|
void |
write(byte[] bytes,
int off,
int len)
|
void |
write(int b)
|
void |
writeObject(BCPGObject o)
|
void |
writePacket(ContainedPacket p)
Write a packet to the stream. |
Methods inherited from class java.io.OutputStream |
write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public BCPGOutputStream(java.io.OutputStream out)
out
- output stream to write encoded data to.public BCPGOutputStream(java.io.OutputStream out, boolean newFormatOnly)
out
- output stream to write encoded data to.newFormatOnly
- true if use new format packets, false if backwards compatible preferred.public BCPGOutputStream(java.io.OutputStream out, PacketFormat packetFormat)
public BCPGOutputStream(java.io.OutputStream out, int tag) throws java.io.IOException
tag
- the packet tag for the object.public BCPGOutputStream(java.io.OutputStream out, int tag, long length, boolean oldFormat) throws java.io.IOException
out
- tag
- length
- oldFormat
-
java.io.IOException
public BCPGOutputStream(java.io.OutputStream out, int tag, long length) throws java.io.IOException
tag
- length
-
java.io.IOException
public BCPGOutputStream(java.io.OutputStream out, int tag, byte[] buffer) throws java.io.IOException
out
- output stream to write to.tag
- packet tag.buffer
- size of chunks making up the packet.
java.io.IOException
Method Detail |
public static BCPGOutputStream wrap(java.io.OutputStream out)
BCPGOutputStream
, return it.
Otherwise wrap it in a BCPGOutputStream
and then return the result.
out
- output stream
public void write(int b) throws java.io.IOException
java.io.IOException
public void write(byte[] bytes, int off, int len) throws java.io.IOException
java.io.IOException
public void writePacket(ContainedPacket p) throws java.io.IOException
p
- packet
java.io.IOException
public void writeObject(BCPGObject o) throws java.io.IOException
java.io.IOException
public void flush() throws java.io.IOException
java.io.IOException
public void finish() throws java.io.IOException
java.io.IOException
public void close() throws java.io.IOException
java.io.IOException
|
Bouncy Castle Cryptography Library 1.81 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |