|
Rice Pastry API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjava.io.OutputStream
rice.p2p.util.EncryptedOutputStream
| Field Summary | |
protected byte[] |
buffer
DESCRIBE THE FIELD |
int |
BUFFER_SIZE
DESCRIBE THE FIELD |
protected int |
bufferLength
DESCRIBE THE FIELD |
protected byte[] |
key
DESCRIBE THE FIELD |
protected java.security.PublicKey |
publicKey
DESCRIBE THE FIELD |
protected java.io.DataOutputStream |
stream
DESCRIBE THE FIELD |
| Constructor Summary | |
EncryptedOutputStream(java.security.PublicKey publicKey,
java.io.OutputStream stream,
int bufferSize)
Builds an encrypted outputstream given a public key to encrypt thing under |
|
| Method Summary | |
void |
close()
Closes this output stream and releases any system resources associated with this stream. |
void |
flush()
Flushes this output stream and forces any buffered output bytes to be written out. |
void |
write(byte[] b,
int off,
int len)
Writes the given bytes to the output |
void |
write(int b)
Writes the specified byte to this output stream. |
protected void |
writeBuffer()
Internal method which writes out the buffered data |
| 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 |
| Field Detail |
public final int BUFFER_SIZE
protected java.security.PublicKey publicKey
protected byte[] key
protected java.io.DataOutputStream stream
protected byte[] buffer
protected int bufferLength
| Constructor Detail |
public EncryptedOutputStream(java.security.PublicKey publicKey,
java.io.OutputStream stream,
int bufferSize)
throws java.io.IOException
stream - The underlying streampublicKey - DESCRIBE THE PARAMETERbufferSize - DESCRIBE THE PARAMETER
java.io.IOException - DESCRIBE THE EXCEPTION| Method Detail |
public void write(int b)
throws java.io.IOException
b - the byte
java.io.IOException - DESCRIBE THE EXCEPTION
public void write(byte[] b,
int off,
int len)
throws java.io.IOException
b - the data.off - the start offset in the data.len - the number of bytes to write.
java.io.IOException - DESCRIBE THE EXCEPTION
protected void writeBuffer()
throws java.io.IOException
java.io.IOException - DESCRIBE THE EXCEPTION
public void flush()
throws java.io.IOException
java.io.IOException - DESCRIBE THE EXCEPTION
public void close()
throws java.io.IOException
java.io.IOException - DESCRIBE THE EXCEPTION
|
Rice Pastry API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||