return new BasicBSONObject("ok", 1).append("n", 0);
if (data.length > 1)
return new BasicBSONObject("ok", 0).append("n", data.length);
BSONObject result = (BSONObject) ((BasicBSONObject) data[0]).clone();
new DefaultUpdateHandler(mongo).handleUpdate(database, collection,
false, false, query, update);
return new BasicBSONObject("ok", 1).append("n", 1).append("value",
result);
}