Package org.eclipse.emf.compare.rcp.ui.internal.contentmergeviewer.accessor.impl

# Class ContainmentReferenceChangeAccessorImpl

java.lang.Object
org.eclipse.emf.compare.rcp.ui.contentmergeviewer.accessor.legacy.impl.AbstractTypedElementAdapter
org.eclipse.emf.compare.rcp.ui.internal.contentmergeviewer.accessor.impl.AbstractStructuralFeatureAccessor
org.eclipse.emf.compare.rcp.ui.internal.contentmergeviewer.accessor.impl.ContainmentReferenceChangeAccessorImpl

All Implemented Interfaces:
  `ICompareAccessor`, `IStructuralFeatureAccessor`, `ITypedElement`

public class ContainmentReferenceChangeAccessorImpl extends AbstractStructuralFeatureAccessor
A specific `AbstractStructuralFeatureAccessor` for containment `ReferenceChange` objects.

Since:
  4.0

## Field Summary

### Fields inherited from interface org.eclipse.emf.compare.rcp.ui.contentmergeviewer.accessor.legacy.ITypedElement

`FOLDER_TYPE, TEXT_TYPE, UNKNOWN_TYPE`

## Constructor Summary

Constructors
Constructor
Description
`ContainmentReferenceChangeAccessorImpl(AdapterFactory adapterFactory, Diff diff, IMergeViewer.MergeViewerSide side)`
.

## Method Summary

Modifier and Type
Method
Description
`protected com.google.common.collect.ImmutableList<Diff>`
`computeDifferences()`
Compute the differences that apply on the structural feature.
`IMergeViewerItem`
`getInitialItem()`
Returns the initial item of this accessor.
`com.google.common.collect.ImmutableList<? extends IMergeViewerItem>`
`getItems()`
Returns the list of items known by this accessor.
`String`
`getType()`
Returns the type of this object.

### Methods inherited from class org.eclipse.emf.compare.rcp.ui.internal.contentmergeviewer.accessor.impl.AbstractStructuralFeatureAccessor

`getAffectedFeature, getComparison, getDifferences, getEObject, getImage, getInitialDiff, getName, getSide, getStructuralFeature`

### Methods inherited from class org.eclipse.emf.compare.rcp.ui.contentmergeviewer.accessor.legacy.impl.AbstractTypedElementAdapter

`getAdapterFactory, getItemDelegator, getRootAdapterFactory`

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

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

## Constructor Details

### ContainmentReferenceChangeAccessorImpl

public ContainmentReferenceChangeAccessorImpl(AdapterFactory adapterFactory, Diff diff, IMergeViewer.MergeViewerSide side)
.

See Also:
  - `AbstractStructuralFeatureAccessor(org.eclipse.emf.common.notify.AdapterFactory, org.eclipse.emf.compare.Diff, org.eclipse.emf.compare.rcp.ui.mergeviewer.IMergeViewer.MergeViewerSide)`

## Method Details

### computeDifferences

protected com.google.common.collect.ImmutableList<Diff> computeDifferences()
Compute the differences that apply on the structural feature.

Overrides:
  `computeDifferences` in class `AbstractStructuralFeatureAccessor`
Returns:
  the list of diff that apply on the structural feature.

### getInitialItem

public IMergeViewerItem getInitialItem()
Returns the initial item of this accessor.

Specified by:
  `getInitialItem` in interface `ICompareAccessor`
Overrides:
  `getInitialItem` in class `AbstractStructuralFeatureAccessor`
Returns:
  the initial item of this accessor.
See Also:
  - `ICompareAccessor.getInitialItem()`

### getItems

public com.google.common.collect.ImmutableList<? extends IMergeViewerItem> getItems()
Returns the list of items known by this accessor.

Returns:
  the list of items known by this accessor.
See Also:
  - `ICompareAccessor.getItems()`

### getType

public String getType()
Returns the type of this object. For objects with a file name this is typically the file extension. For folders its the constant `FOLDER_TYPE`. The type is used for determining a suitable viewer for this object.

Specified by:
  `getType` in interface `ITypedElement`
Overrides:
  `getType` in class `AbstractStructuralFeatureAccessor`
Returns:
  the type of this object
See Also:
  - `ITypedElement.getType()`