-// $Id$
/**
* Copyright (C) 2015 EDIT
* European Distributed Institute of Taxonomy
private final Object source;
private final Action action;
private final boolean async;
+ protected Class entityType;
public RemotingCdmOperation(String label, Action action, Object source, boolean async) {
super(label);
protected abstract IStatus onComplete(boolean success);
- protected void fireDataChangeEvent(Set<? extends CdmBase> changedObjects) {
+ protected void fireDataChangeEvent(Set<CdmBase> changedObjects) {
if(changedObjects != null && !changedObjects.isEmpty()) {
CdmApplicationState.getCurrentDataChangeService().fireChangeEvent(new CdmChangeEvent(action, changedObjects, source.getClass()), async);
}
protected void fireDataChangeEvent(UpdateResult updateResult) {
Set<CdmBase> updatedObjects = updateResult.getUpdatedObjects();
- if(updatedObjects != null && !updatedObjects.isEmpty()) {
- CdmApplicationState.getCurrentDataChangeService().fireChangeEvent(new CdmChangeEvent(action, updatedObjects, source.getClass()), async);
+ CdmApplicationState.getCurrentDataChangeService()
+ .fireChangeEvent(new CdmChangeEvent(action, updatedObjects, source.getClass(), entityType), async);
+ }
+
+ protected void fireDataChangeEvent(CdmBase cdmBase) {
+ if(cdmBase != null) {
+ CdmApplicationState.getCurrentDataChangeService().fireChangeEvent(new CdmChangeEvent(action, cdmBase, source.getClass()), async);
}
}