@SuppressWarnings("unchecked")
protected void fillMap(HashMap<String, ByteIterator> resultMap, DBObject obj) {
Map<String, Object> objMap = obj.toMap();
for (Map.Entry<String, Object> entry : objMap.entrySet()) {
if (entry.getValue() instanceof byte[]) {
resultMap.put(entry.getKey(), new ByteArrayByteIterator(
(byte[]) entry.getValue()));
}
}
}