Package org.eclipse.emf.compare.ide.ui.internal.logical.resolver

## Class ModelsResolution

- java.lang.Object
- - org.eclipse.emf.compare.ide.ui.internal.logical.resolver.AbstractResolution
  - - org.eclipse.emf.compare.ide.ui.internal.logical.resolver.ModelsResolution

    public class ModelsResolution
    extends AbstractResolution

Computation that resolves 2 or 3 storages (left, right and potentially origin).

### Field Summary

### Fields inherited from class org.eclipse.emf.compare.ide.ui.internal.logical.resolver.AbstractResolution

`context, diagnostic, implicitDependencies, logger, monitor`

### Constructor Summary

Constructors
`ModelsResolution​(IResolutionContext context, org.eclipse.core.runtime.IProgressMonitor monitor, IStorageProviderAccessor storageAccessor, org.eclipse.core.resources.IStorage left, org.eclipse.core.resources.IStorage right, org.eclipse.core.resources.IStorage origin)` At least one of `left`, `right` and `origin` must be non-null.

### Method Summary

All Methods Instance Methods Concrete Methods
`protected Runnable` `getFinalizeResolvingRunnable()` Overridden to set the work remaining to zero on the progress monitor used.
`protected com.google.common.base.Function<URI,​IComputation<URI>>` `resolveRemoteURI​(ThreadSafeProgressMonitor tspm, SynchronizedResourceSet resourceSet)` Provides a `Function` that converts a given URI into a Computation that can be run by a `ResourceComputationScheduler`.
`SynchronizationModel` `run()` Executes the resolution.

### Methods inherited from class org.eclipse.emf.compare.ide.ui.internal.logical.resolver.AbstractResolution

`asURISet, call, getImplicitDependencies, getTicks, resolveTraversal`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### ModelsResolution

    public ModelsResolution​(IResolutionContext context,
                            org.eclipse.core.runtime.IProgressMonitor monitor,
                            IStorageProviderAccessor storageAccessor,
                            org.eclipse.core.resources.IStorage left,
                            org.eclipse.core.resources.IStorage right,
                            org.eclipse.core.resources.IStorage origin)

At least one of `left`, `right` and `origin` must be non-null.

Parameters:
  `dependencyProvider` - The dependency provider
  `scheduler` - The muti-thread support to use
  `eventBus` - The event bus
  `monitor` - The progress monitor to use to report progress
  `storageAccessor` - The storage accessor, must not be `null`
  `left` - The left storage, can be `null`
  `right` - The right storage, can be `null`
  `origin` - The ancestor storage, can be `null`

### Method Detail

#### run

    public SynchronizationModel run()

Executes the resolution.

Returns:
  The logical model to use to compare the given storages

#### getFinalizeResolvingRunnable

    protected Runnable getFinalizeResolvingRunnable()

Overridden to set the work remaining to zero on the progress monitor used.

Overrides:
  `getFinalizeResolvingRunnable` in class `AbstractResolution`
Returns:
  The `Runnable` to run after having resolved resources.

#### resolveRemoteURI

    protected com.google.common.base.Function<URI,​IComputation<URI>> resolveRemoteURI​(ThreadSafeProgressMonitor tspm,
                                                                                            SynchronizedResourceSet resourceSet)

Provides a `Function` that converts a given URI into a Computation that can be run by a `ResourceComputationScheduler`.

Parameters:
  `tspm` - The progress monitor to use
  `resourceSet` - The resource set to use
Returns:
  A `Function`, never `null`, that can be used to remotely resolvea given URI.