/**
* Initialize the Index persistable listener.
*/
protected void initIndexPersistableListener() {
_index.setPersistableListener(new PersistableListener() {
@Override
public void beforePersist() {
try {
PersistableListener l = _listener;
if(l != null) l.beforePersist();
} catch (Exception e) {
_logger.error("failed on calling beforePersist", e);
}
try {
_bytesDB.persist();
} catch (Exception e) {
_logger.error("failed on calling beforePersist", e);
}
}
@Override
public void afterPersist() {
try {
PersistableListener l = _listener;
if(l != null) l.afterPersist();
} catch(Exception e) {
_logger.error("failed on calling afterPersist", e);
}
}
});