如下例所示: 现在还数据库了(postgreSQL),我该把这些方法转换成相对应的什么方法? 求解答
protected DBObject createWaveletDBQuery() {
DBObject query = new BasicDBObject();
query.put(MongoDbDeltaStoreUtil.FIELD_WAVE_ID, waveletName.waveId.serialise());
query.put(MongoDbDeltaStoreUtil.FIELD_WAVELET_ID, waveletName.waveletId.serialise());
return query;
}
public WaveletDeltaRecord getDelta(long version) throws IOException {
DBObject query = createWaveletDBQuery();
query.put(MongoDbDeltaStoreUtil.FIELD_TRANSFORMED_APPLIEDATVERSION, version);
DBObject result = deltaDbCollection.findOne(query);
WaveletDeltaRecord waveletDelta = null;
if (result != null) try {
waveletDelta = MongoDbDeltaStoreUtil.deserializeWaveletDeltaRecord(result);
} catch (PersistenceException e) {
throw new IOException(e);
}
return waveletDelta;
}