use of org.activityinfo.client.local.sync.Synchronizer in project activityinfo by bedatadriven.
the class LocalController method loadSynchronizerImpl.
private void loadSynchronizerImpl(final AsyncCallback<Synchronizer> callback) {
Log.trace("loadSynchronizerImpl() starting...");
GWT.runAsync(new RunAsyncCallback() {
@Override
public void onFailure(Throwable throwable) {
Log.trace("loadSynchronizerImpl() failed");
callback.onFailure(throwable);
}
@Override
public void onSuccess() {
Log.trace("loadSynchronizerImpl() succeeded");
Synchronizer impl = null;
try {
impl = synchronizerProvider.get();
} catch (Exception caught) {
Log.error("SynchronizationImpl constructor threw exception", caught);
callback.onFailure(caught);
return;
}
callback.onSuccess(impl);
}
});
}
Aggregations