Package com.mongodb
Interface DBDecoder
-
- All Superinterfaces:
org.bson.BSONDecoder
- All Known Implementing Classes:
DefaultDBDecoder,LazyDBDecoder
public interface DBDecoder extends org.bson.BSONDecoderAn interface for decoders of BSON into instances of DBObject that belong to a DBCollection.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description com.mongodb.DBObjectdecode(byte[] bytes, DBCollection collection)Decode a single DBObject belonging to the given collection from the given array of bytes.com.mongodb.DBObjectdecode(InputStream input, DBCollection collection)Decode a single DBObject belonging to the given collection from the given input stream.DBCallbackgetDBCallback(DBCollection collection)Get a callback for the given collection.
-
-
-
Method Detail
-
getDBCallback
DBCallback getDBCallback(DBCollection collection)
Get a callback for the given collection.- Parameters:
collection- the collection- Returns:
- the callback
-
decode
com.mongodb.DBObject decode(InputStream input, DBCollection collection) throws IOException
Decode a single DBObject belonging to the given collection from the given input stream.- Parameters:
input- the input streamcollection- the collection- Returns:
- the DBObject
- Throws:
IOException- may throw an exception while decoding from theInputStream
-
decode
com.mongodb.DBObject decode(byte[] bytes, DBCollection collection)Decode a single DBObject belonging to the given collection from the given array of bytes.- Parameters:
bytes- the byte arraycollection- the collection- Returns:
- the DBObject
-
-