org.eclipse.emf.emfstore.client.callbacks
Interface ESUpdateCallback

All Known Implementing Classes:
UIUpdateProjectController

public interface ESUpdateCallback

Callback interface for updating a ESLocalProject.

Author:
ovonwesen, emueller

Field Summary
static ESUpdateCallback NOCALLBACK
          A default implementation of an update callback that does nothing and defaults this#conflictOccurred(ESConflictSet, IProgressMonitor) to false and checksumCheckFailed to true.
 
Method Summary
 boolean conflictOccurred(ESConflictSet changeConflict, org.eclipse.core.runtime.IProgressMonitor monitor)
          Called when local and remote changes overlap.
 boolean inspectChanges(ESLocalProject project, List<ESChangePackage> changes, ESModelElementIdToEObjectMapping idToEObjectMapping)
          Called right before the changes get applied upon the project space.
 void noChangesOnServer()
          Called when no remote changes are available.
 

Field Detail

NOCALLBACK

static final ESUpdateCallback NOCALLBACK
A default implementation of an update callback that does nothing and defaults this#conflictOccurred(ESConflictSet, IProgressMonitor) to false and checksumCheckFailed to true.

Method Detail

inspectChanges

boolean inspectChanges(ESLocalProject project,
                       List<ESChangePackage> changes,
                       ESModelElementIdToEObjectMapping idToEObjectMapping)
Called right before the changes get applied upon the project space.

Parameters:
project - the ESLocalProject being updated
changes - a list of ESChangePackages that will get applied upon the project
idToEObjectMapping - a mapping from IDs to EObjects and vice versa. Contains all IDs of model elements involved in the ESChangePackages as well as those contained by the project in the ESLocalProject
Returns:
true, if the changes should get applied upon the project space, false otherwise

noChangesOnServer

void noChangesOnServer()
Called when no remote changes are available.


conflictOccurred

boolean conflictOccurred(ESConflictSet changeConflict,
                         org.eclipse.core.runtime.IProgressMonitor monitor)
Called when local and remote changes overlap.

Parameters:
changeConflict - the ESConflictSetImpl containing the changes that led to the conflict
monitor - an IProgressMonitor to report on progress
Returns:
true, if the conflict has been resolved, false otherwise


Copyright © 2015. All Rights Reserved.