|
Eclipse Platform Release 3.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.jface.viewers.Viewer org.eclipse.jface.viewers.ContentViewer org.eclipse.jface.viewers.StructuredViewer org.eclipse.jface.viewers.AbstractTreeViewer org.eclipse.jface.viewers.TreeViewer org.eclipse.compare.structuremergeviewer.DiffTreeViewer org.eclipse.compare.structuremergeviewer.StructureDiffViewer
A diff tree viewer that can be configured with a IStructureCreator to retrieve a hierarchical structure from the input object (an ICompareInput) and perform a two-way or three-way compare on it.
This class may be instantiated; it is not intended to be subclassed outside this package.
Field Summary |
Fields inherited from class org.eclipse.jface.viewers.AbstractTreeViewer |
ALL_LEVELS |
Fields inherited from class org.eclipse.jface.viewers.Viewer |
WIDGET_DATA_KEY |
Constructor Summary | |
StructureDiffViewer(Composite parent,
CompareConfiguration configuration)
Creates a new viewer under the given SWT parent with the specified configuration. | |
StructureDiffViewer(Tree tree,
CompareConfiguration configuration)
Creates a new viewer for the given SWT tree control with the specified configuration. |
Method Summary | |
protected void | compareInputChanged(ICompareInput input)
Recreates the comparable structures for the input sides. |
protected void | contentChanged(IContentChangeNotifier changed)
Calls diff whenever the byte contents changes. |
protected void | copySelected(boolean leftToRight)
Overridden to call the save method on the structure creator after nodes have been copied from one side to the other side of an input object. |
protected void | diff()
Runs the difference engine and refreshes the tree. |
protected Object | getRoot()
Overridden because the input of this viewer is not identical to the root of the tree. |
IStructureCreator | getStructureCreator()
Returns the structure creator or null if no structure creator has been set with setStructureCreator. |
String | getTitle()
Reimplemented to get the descriptive title for this viewer from the IStructureCreator. |
protected void | handleDispose(DisposeEvent event)
Called on the viewer disposal. |
protected void | initialSelection()
This hook method is called from within inputChanged after a new input has been set but before any controls are updated. |
protected void | inputChanged(Object input,
Object oldInput)
Overridden to create the comparable structures from the input object and to feed them through the differencing engine. |
protected void | postDiffHook(Differencer differencer,
IDiffContainer root)
This method is called from within diff() after the difference tree has been built. |
protected void | preDiffHook(IStructureComparator ancestor,
IStructureComparator left,
IStructureComparator right)
This method is called from within diff() before the difference tree is being built. |
protected void | propertyChange(PropertyChangeEvent event)
Tracks property changes of the configuration object. |
void | setStructureCreator(IStructureCreator structureCreator)
Configures the StructureDiffViewer with a structure creator. |
Methods inherited from class org.eclipse.compare.structuremergeviewer.DiffTreeViewer |
copyOne, createToolItems, dontExpand, expandSelection, fillContextMenu, getBundle, getCompareConfiguration, internalExpandToLevel, navigate |
Methods inherited from class org.eclipse.jface.viewers.TreeViewer |
addTreeListener, doUpdateItem, getChildren, getControl, getExpanded, getItem, getItemCount, getItemCount, getItems, getLabelProvider, getParentItem, getSelection, getTree, newItem, removeAll, setExpanded, setLabelProvider, setSelection, showItem |
Methods inherited from class org.eclipse.jface.viewers.ContentViewer |
getContentProvider, getInput |
Methods inherited from class org.eclipse.jface.viewers.Viewer |
addHelpListener, addSelectionChangedListener, fireHelpRequested, fireSelectionChanged, getData, handleHelpRequest, removeHelpListener, removeSelectionChangedListener, setData, setSelection |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.jface.viewers.ISelectionProvider |
addSelectionChangedListener, removeSelectionChangedListener, setSelection |
Constructor Detail |
public StructureDiffViewer(Tree tree, CompareConfiguration configuration)
public StructureDiffViewer(Composite parent, CompareConfiguration configuration)
Method Detail |
public void setStructureCreator(IStructureCreator structureCreator)
public IStructureCreator getStructureCreator()
public String getTitle()
protected Object getRoot()
protected void inputChanged(Object input, Object oldInput)
protected void initialSelection()
protected void handleDispose(DisposeEvent event)
protected void compareInputChanged(ICompareInput input)
protected void contentChanged(IContentChangeNotifier changed)
protected void preDiffHook(IStructureComparator ancestor, IStructureComparator left, IStructureComparator right)
protected void diff()
protected void postDiffHook(Differencer differencer, IDiffContainer root)
protected void propertyChange(PropertyChangeEvent event)
protected void copySelected(boolean leftToRight)
|
Eclipse Platform Release 3.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2004. All rights reserved.