Class MatchAccessor
java.lang.Object
org.eclipse.emf.compare.rcp.ui.contentmergeviewer.accessor.legacy.impl.AbstractTypedElementAdapter
org.eclipse.emf.compare.rcp.ui.internal.contentmergeviewer.accessor.impl.MatchAccessor
- All Implemented Interfaces:
ICompareAccessor
,ITypedElement
A specific
ICompareAccessor
for Match
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
ConstructorDescriptionMatchAccessor
(AdapterFactory adapterFactory, Match match, Diff diff, IMergeViewer.MergeViewerSide side) Creates a new object wrapping the giveneObject
.MatchAccessor
(AdapterFactory adapterFactory, Match match, IMergeViewer.MergeViewerSide side) Creates a new object wrapping the giveneObject
. -
Method Summary
Modifier and TypeMethodDescriptionReturns the comparison object used by this accessor.org.eclipse.swt.graphics.Image
getImage()
Returns an image for this object.Returns the initial item of this accessor.com.google.common.collect.ImmutableList<? extends IMergeViewerItem>
getItems()
Returns the list of items known by this accessor.getName()
Returns the name of this object.protected final IMergeViewer.MergeViewerSide
getSide()
Returns the side of this accessor.getType()
Returns the type of this object.Methods inherited from class org.eclipse.emf.compare.rcp.ui.contentmergeviewer.accessor.legacy.impl.AbstractTypedElementAdapter
getAdapterFactory, getItemDelegator, getRootAdapterFactory
-
Constructor Details
-
MatchAccessor
Creates a new object wrapping the giveneObject
.- Parameters:
adapterFactory
- the adapter factory used to create the accessor.match
- the match to associate with this accessor.side
- the side of this accessor.
-
MatchAccessor
public MatchAccessor(AdapterFactory adapterFactory, Match match, Diff diff, IMergeViewer.MergeViewerSide side) Creates a new object wrapping the giveneObject
.- Parameters:
adapterFactory
- the adapter factory used to create the accessor.match
- the match to associate with this accessor.diff
- the diff associated with this accessor.side
- the side of this accessor.
-
-
Method Details
-
getSide
Returns the side of this accessor.- Returns:
- the side of this accessor.
-
getName
Returns the name of this object. The name is used when displaying this object in the UI.- Specified by:
getName
in interfaceITypedElement
- Returns:
- the name of this object
- See Also:
-
getImage
public org.eclipse.swt.graphics.Image getImage()Returns an image for this object. This image is used when displaying this object in the UI.- Specified by:
getImage
in interfaceITypedElement
- Returns:
- the image of this object or
null
if this type of input has no image - See Also:
-
getType
Returns the type of this object. For objects with a file name this is typically the file extension. For folders its the constantFOLDER_TYPE
. The type is used for determining a suitable viewer for this object.- Specified by:
getType
in interfaceITypedElement
- Returns:
- the type of this object
- See Also:
-
getComparison
Returns the comparison object used by this accessor.- Specified by:
getComparison
in interfaceICompareAccessor
- Returns:
- the comparison object used by this accessor.
- See Also:
-
getInitialItem
Returns the initial item of this accessor.- Specified by:
getInitialItem
in interfaceICompareAccessor
- Returns:
- the initial item of this accessor.
- See Also:
-
getItems
Returns the list of items known by this accessor.- Specified by:
getItems
in interfaceICompareAccessor
- Returns:
- the list of items known by this accessor.
- See Also:
-