<!doctype html public "-//w3c//dtd html 4.0 transitional//en"> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> | |
<meta name="GENERATOR" content="Mozilla/4.75 [en] (WinNT; U) [Netscape]"> | |
<title>Compare Extension Points: contentMergeViewers</title> | |
</head> | |
<body link="#0000FF" vlink="#800080"> | |
<center> | |
<h1> | |
ContentMergeViewers</h1></center> | |
<b><i>Identifier: </i></b>org.eclipse.compare.contentMergeViewers | |
<p><b><i>Description: </i></b>This extension point allows to plug in a | |
compare/merge viewer for specific content types. The viewer must extend | |
<tt>org.eclipse.jface.viewers.Viewer</tt>. | |
<br>However since viewers don't have a default constructor the extension | |
point must implement a factory object for viewers: the interface <tt>org.eclipse.compare.IViewerCreator</tt>. | |
<p><b><i>Configuration Markup:</i></b> | |
<p><tt> <!ELEMENT viewer EMPTY></tt> | |
<br><tt> <!ATTLIST viewer</tt> | |
<br><tt> id | |
CDATA #REQUIRED</tt> | |
<br><tt> class | |
CDATA #REQUIRED</tt> | |
<br><tt> extensions CDATA #REQUIRED</tt> | |
<br><tt> ></tt> | |
<ul> | |
<li> | |
<b>id</b> - a unique identifier that can be used to reference the viewer</li> | |
<li> | |
<b>class</b> - name of a class that implements a factory for the content | |
merge viewer and implements <tt>org.eclipse.compare.IViewerCreator</tt></li> | |
<li> | |
<b>extensions </b>- a comma separated list of file extensions e.g . "java, | |
gif"</li> | |
</ul> | |
<b><i>Examples:</i></b> | |
<br>The following is an example of compare/merge viewer for text files | |
(extension "txt"): | |
<p><extension point = "org.eclipse.compare.contentMergeViewers"> | |
<br> <viewer | |
<br> id="org.eclipse.compare.contentmergeviewer.TextMergeViewer" | |
<br> class="org.eclipse.compare.internal.TextMergeViewerCreator" | |
<br> extensions="txt" | |
<br> /> | |
<br></extension> | |
<p><b><i>Supplied Implementation:</i></b> | |
<br>The Compare UI plugin defines content viewers for text, binary contents, | |
and images. | |
<p><a href="hglegal.htm"><img SRC="ngibmcpy.gif" ALT="Copyright IBM Corp. 2000, 2001. All Rights Reserved." BORDER=0 height=12 width=195></a> | |
</body> | |
</html> |