Package ca.odell.glazedlists.io
Interface ByteCoder
-
public interface ByteCoder
An utility interface for converting Objects to bytes for storage or network transport. For some common, general-purposeByteCoder
s, see theGlazedLists
factory class.- Author:
- Jesse Wilson
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Object
decode(java.io.InputStream source)
Decode the Object from the specifiedInputStream
.void
encode(java.lang.Object source, java.io.OutputStream target)
Encode the specified Object over the specifiedOutputStream
.
-
-
-
Method Detail
-
encode
void encode(java.lang.Object source, java.io.OutputStream target) throws java.io.IOException
Encode the specified Object over the specifiedOutputStream
.- Throws:
java.io.IOException
-
decode
java.lang.Object decode(java.io.InputStream source) throws java.io.IOException
Decode the Object from the specifiedInputStream
. The stream should contain exactly one Object and no further bytes before the end of the stream.- Throws:
java.io.IOException
-
-