mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-05 16:15:25 +02:00
160 lines
9.4 KiB
HTML
Executable file
160 lines
9.4 KiB
HTML
Executable file
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html>
|
|
|
|
<head>
|
|
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
|
|
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
|
|
<meta name="copyright" content="Copyright (c) IBM Corporation and others 2002, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
|
<LINK REL="STYLESHEET" HREF="../../book.css" TYPE="text/css">
|
|
<title>Other Relevant Extension Points</title>
|
|
</head>
|
|
|
|
<body bgcolor="#ffffff">
|
|
<h1>Other Relevant Extension Points</h1>
|
|
<p>There are some Eclipse extension points that are relevant as-is to the Remote System Explorer,
|
|
which we list here. We do not describe how to use these extension points here, except to document
|
|
the information needed to enable them to in Remote System Explorer.
|
|
</p>
|
|
|
|
<TABLE border="1">
|
|
<TBODY>
|
|
<TR>
|
|
<TH>Extension Point</TH>
|
|
<TH>Description</TH>
|
|
</TR>
|
|
<TR>
|
|
<TD><samp>org.eclipse.ui.viewActions</samp></TD>
|
|
<TD>For adding actions to the pulldown menu in any view's local toolbar, or to the toolbar itself.
|
|
To use this you need to know the ID of the RSE views, for the <samp>targetID</samp> attribute: There are:
|
|
<ul>
|
|
<li><samp>org.eclipse.rse.ui.view.systemView</samp> for the primary
|
|
<A href="view_RS.gif">Remote Systems</A> view.
|
|
<li><samp>org.eclipse.rse.ui.view.teamView</samp> for the
|
|
<A href="view_Team.gif">Team</A> view in the RSE perspective.
|
|
<li><samp>org.eclipse.rse.ui.view.systemTableView</samp> for the
|
|
<A href="view_Table.gif">Remote System Details</A> view in the RSE perspective.
|
|
</ul>
|
|
</TD>
|
|
</TR>
|
|
<TR>
|
|
<TD><samp>org.eclipse.ui.propertyPages</samp></TD>
|
|
<TD>For adding property pages for non-remote objects within the
|
|
Remote System Explorer. To use this you need to know the class type
|
|
of these objects for the <samp>objectClass</samp> attribute of the <samp><page></samp> element:
|
|
<ul>
|
|
<li>Connections: <samp><A href="../../reference/api/org/eclipse/rse/model/IHost.html">org.eclipse.rse.model.IHost</A></samp>
|
|
<li>SubSystems: <samp><A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">org.eclipse.rse.core.subsystems.ISubSystem</A></samp>
|
|
<li>Filter Pools: <samp><A href="../../reference/api/org/eclipse/rse/filters/ISystemFilterPoolReference.html">org.eclipse.rse.filters.ISystemFilterPoolReference</A></samp>
|
|
<li>Filters: <samp><A href="../../reference/api/org/eclipse/rse/filters/ISystemFilterReference.html">org.eclipse.rse.filters.ISystemFilterReference</A></samp>
|
|
</ul>
|
|
It is possible to scope your property pages to only appear for certain system types or subsystems, using
|
|
the <samp><filter></samp> element. For example:<br>
|
|
<pre><code>
|
|
<extension point="org.eclipse.ui.propertyPages">
|
|
<page name="Team Info"
|
|
class="samples.ui.propertypages.TeamFilterPropertyPage"
|
|
id="samples.ui.pp.filter.team"
|
|
objectClass="org.eclipse.rse.filters.ISystemFilterReference" >
|
|
<b><filter name="subsystemFactoryId" value="samples.subsystems.factory"/></b>
|
|
</page>
|
|
</extension>
|
|
</code></pre>
|
|
See <a href="#scoping">Scoping</a> for all the filter <samp>names</samp> supported by RSE objects.
|
|
</TD>
|
|
</TR>
|
|
<TR>
|
|
<TD><samp>org.eclipse.ui.popupMenus</samp></TD>
|
|
<TD>For adding pop-up menu actions for non-remote objects within the Remote System Explorer.
|
|
To use this you need to know the class type of these objects for the <samp>objectClass</samp> attribute
|
|
of the <objectContribution> element:
|
|
<ul>
|
|
<li>Connections: <samp><A href="../../reference/api/org/eclipse/rse/model/IHost.html">org.eclipse.rse.model.IHost</A></samp>
|
|
<li>SubSystems: <samp><A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">org.eclipse.rse.core.subsystems.ISubSystem</A></samp>
|
|
<li>Filter Pools: <samp><A href="../../reference/api/org/eclipse/rse/filters/ISystemFilterPoolReference.html">org.eclipse.rse.filters.ISystemFilterPoolReference</A></samp>
|
|
<li>Filters: <samp><A href="../../reference/api/org/eclipse/rse/filters/ISystemFilterReference.html">org.eclipse.rse.filters.ISystemFilterReference</A></samp>
|
|
</ul>
|
|
It is possible to scope your actions to only appear for certain system types or subsystems, using
|
|
the <samp><filter></samp> element. For example:<br>
|
|
<pre><code>
|
|
<extension point="org.eclipse.ui.popupMenus">
|
|
<objectContribution
|
|
id ="samples.ui.actions.TeamFilterActions"
|
|
objectClass="org.eclipse.rse.filters.ISystemFilterReference">
|
|
<b><filter name="subsystemFactoryId" value="samples.subsystems.factory"/></b>
|
|
<action id="samples.ui.actions.TeamFilterAction1"
|
|
label="Sample Team Filter Action"
|
|
class="samples.ui.actions.ShowJarContents">
|
|
</action>
|
|
</objectContribution>
|
|
</extension>
|
|
</code></pre>
|
|
See <a href="#scoping">Scoping</a> for all the filter <samp>names</samp> supported by RSE objects.
|
|
</TD>
|
|
</TR>
|
|
</TBODY>
|
|
</TABLE>
|
|
|
|
<a name="scoping"></a><h2>Scoping</h2>
|
|
<p>For the <samp>org.eclipse.ui.propertyPages</samp> and <samp>org.eclipse.ui.popupMenus</samp> extension points, it is
|
|
possible to scope your property pages and actions to only filters in a particular subsystem, or connections of a
|
|
particular system type, say. These extension points support the <samp><filter></samp> element, which
|
|
allows you to specify a property name, and a property value, such that the page or action will only show if
|
|
that property's value is the one given:<br>
|
|
<pre><code>
|
|
<filter name="<i>name</i>" value="<i>value</i>"/>
|
|
</code></pre>
|
|
It is up to the selected object's adapter to perform this test, in its
|
|
<code>testAttribute(Object target,String <i>name</i>,String <i>value</i>)</code> method. This method is implemented for the adapters for every object shown in the
|
|
Remote Systems view, and what follows is a list of the tests it will do on the given <samp><i>value</i></samp>,
|
|
for the given <samp><i>name</i></samp>:</p>
|
|
<ul>
|
|
<li><b><samp>"name"</samp></b>. Will test the <i>value</i> for an exact match on an object's name,
|
|
or beginning-of-name match if ends with an asterisk.
|
|
<li><b><samp>"type"</samp></b>. Will test the <i>value</i> for an exact match on an object's type.
|
|
<li><b><samp>"offline"</samp></b>.Will test the <i>value</i> against "true" if the user is working
|
|
in "offline" mode or "false" if not. Currently only supported for iSeries connections.
|
|
<li><b><samp>"connected"</samp></b>. Will test the <i>value</i> against "true" if the connection
|
|
containing the selected object is active or "false" if not.
|
|
<li><b><samp>"hasChildren"</samp></b>. Will test the <i>value</i> against "true" if this object's
|
|
adapter reports that it has children or "false" if it doesn't have children.
|
|
<li><b><samp>"systemType"</samp></b>. Will test the <i>value</i> for an exact match on the system type of
|
|
this object's parent SystemConnection object.
|
|
You can specify multiple values if you comma-separate them.
|
|
<li><b><samp>"subsystemFactoryId"</samp></b>. Will test the <i>value</i> for an exact match on the
|
|
<samp>ID</samp> of the subsystem factory that created this object's subsystem. Returns false for SystemConnection objects.
|
|
You can specify multiple values if you comma-separate them.
|
|
<li><b><samp>"subsystemFactoryCategory"</samp></b>. Will test the <i>value</i> for an exact match
|
|
on the <samp>category</samp> of the subsystem factory that created this object's subsystem.
|
|
You can specify multiple values if you comma-separate them.
|
|
</ul>
|
|
|
|
<p>For system filter objects of type <samp>org.eclipse.rse.filters.ISystemFilterReference</samp>,
|
|
the following names are also supported:
|
|
<ul>
|
|
<li><b><samp>"filterType"</samp></b>. Will test the <i>value</i> for an exact match on the selected filter's
|
|
untranslated type, as set internally. The only RSE-supplied subsystem to support multiple filter types is
|
|
the iSeries Objects subsystem for iSeries connections. It contains these types:
|
|
<ul>
|
|
<li><samp>"Library"</samp>.
|
|
<li><samp>"LibraryList"</samp>.
|
|
<li><samp>"Object"</samp>.
|
|
<li><samp>"Member"</samp>.
|
|
</ul>
|
|
</ul>
|
|
|
|
<p>For the <samp>org.eclipse.ui.popupMenus</samp> extension point, you can also use the above names
|
|
in the <visibility> and <enablement> elements, for extreme flexibility in when
|
|
the action is shown, and when it is enabled or disabled. These map to the <samp>objectState</samp>
|
|
attribute. For example:
|
|
<pre><code>
|
|
<enablement>
|
|
<objectState name="hasChildren" value="true"/>
|
|
</enablement>
|
|
</code></pre>
|
|
|
|
|
|
<p>Be aware the <samp><visibility></samp> element is available at the
|
|
<samp><objectContribution></samp> level, while the <samp><enablement></samp>
|
|
element is available at the <samp><Action></samp> level.
|
|
</body>
|
|
</html>
|