Bug 559474: Remove all parts of TM not migrating to CDT
Change-Id: I0fdd9d24c5910b3ba939dc0924ae41669e74ff53 Signed-off-by: Jonah Graham <jonah@kichwacoders.com>
15
.gitignore
vendored
|
@ -1,15 +0,0 @@
|
|||
# ignore various emacs droppings
|
||||
*~
|
||||
\#*\#
|
||||
workspace
|
||||
debug-workspace
|
||||
artifacts/
|
||||
bin/
|
||||
target/
|
||||
rse/plugins/org.eclipse.dstore.core/dstore_core.jar bin
|
||||
rse/plugins/org.eclipse.dstore.extra/dstore_extra_server.jar
|
||||
rse/plugins/org.eclipse.rse.services.dstore/dstore_miners.jar
|
||||
rse/plugins/org.eclipse.rse.services/clientserver.jar
|
||||
.settings/
|
||||
.classpath
|
||||
.project
|
11
.project
|
@ -1,11 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>org.eclipse.tm</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
</natures>
|
||||
</projectDescription>
|
36
README.adoc
|
@ -1,36 +0,0 @@
|
|||
== Building
|
||||
|
||||
`mvn clean install`
|
||||
|
||||
Or, enable jar signing with `-P eclipse-sign`.
|
||||
|
||||
There is only one test plugin, and it currently has one failing test. So you will likely want to add the `-DskipTests` flag to avoid that.
|
||||
|
||||
An update site and zip will be produced in the `site/target/` folder, which contains features and plugins from both Remote System Explorer (RSE) and Terminal.
|
||||
|
||||
== Circular Dependencies
|
||||
|
||||
In theory, the RSE and Terminal are independent projects.
|
||||
|
||||
In practice, they each depend on each other, which is why we've now merged the RSE (org.eclipse.tm) and Terminal (org.eclipse.tm.terminal) repos into a single gerrit repo to resolve this cycle and make building easier.
|
||||
|
||||
=== In RSE
|
||||
|
||||
* rse/plugins/org.eclipse.rse.terminals.ui/META-INF/MANIFEST.MF
|
||||
_depends on_
|
||||
** *org.eclipse.tm.terminal.control*
|
||||
|
||||
* rse/features/org.eclipse.rse.terminals-feature/feature.xml
|
||||
_depends on_
|
||||
** *org.eclipse.tm.terminal.control.feature*
|
||||
|
||||
=== In Terminal:
|
||||
|
||||
* plugins/org.eclipse.tm.terminal.view.ui.rse/META-INF/MANIFEST.MF
|
||||
_depends on_
|
||||
** *org.eclipse.rse.core, org.eclipse.rse.subsystems.files.core, org.eclipse.rse.ui*
|
||||
|
||||
* features/org.eclipse.tm.terminal.view.rse.feature/feature.xml
|
||||
_depends on_
|
||||
** *org.eclipse.rse.core, org.eclipse.rse.subsystems.files.core, org.eclipse.rse.ui*
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?pde version="3.8"?><target name="TM Eclipse 4.6.x (Neon)" sequenceNumber="102">
|
||||
<locations>
|
||||
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="slicer" includeSource="true" type="InstallableUnit">
|
||||
<unit id="org.eclipse.license.feature.group" version="1.0.1.v20140414-1359"/>
|
||||
<repository location="http://download.eclipse.org/cbi/updates/license"/>
|
||||
</location>
|
||||
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="slicer" includeSource="true" type="InstallableUnit">
|
||||
<unit id="org.eclipse.test.feature.group" version="3.7.0.v20150826-1546"/>
|
||||
<unit id="org.eclipse.sdk.ide" version="4.6.0.I20150916-2000"/>
|
||||
<repository location="http://download.eclipse.org/eclipse/updates/4.6milestones"/>
|
||||
</location>
|
||||
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="slicer" includeSource="true" type="InstallableUnit">
|
||||
<unit id="org.apache.commons.net" version="3.2.0.v201305141515"/>
|
||||
<unit id="org.apache.commons.net.source" version="3.2.0.v201305141515"/>
|
||||
<repository location="http://download.eclipse.org/tools/orbit/downloads/drops/R20150821153341/repository"/>
|
||||
</location>
|
||||
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="slicer" includeSource="true" type="InstallableUnit">
|
||||
<unit id="org.eclipse.emf.sdk.feature.group" version="2.12.0.v20150928-0952"/>
|
||||
<repository location="http://download.eclipse.org/releases/neon"/>
|
||||
</location>
|
||||
</locations>
|
||||
</target>
|
|
@ -1,6 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
|
@ -1,7 +0,0 @@
|
|||
bin
|
||||
index
|
||||
build.xml
|
||||
javadoc.link.location
|
||||
temp.bin.log
|
||||
temp.options.txt
|
||||
temp.convert.txt
|
|
@ -1,22 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>org.eclipse.dstore.doc.isv</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.ManifestBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.SchemaBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.pde.PluginNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -1,8 +0,0 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: %pluginName
|
||||
Bundle-SymbolicName: org.eclipse.dstore.doc.isv; singleton:=true
|
||||
Bundle-Version: 4.5.100.qualifier
|
||||
Bundle-Localization: plugin
|
||||
Bundle-Vendor: %providerName
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
|
@ -1,29 +0,0 @@
|
|||
Last revised July 27, 2006
|
||||
(This file is for information only; it is not included in the release.)
|
||||
|
||||
See also
|
||||
http://wiki.eclipse.org/How_to_add_things_to_the_Eclipse_doc
|
||||
with the following exceptions:
|
||||
- platformOptions.txt -> options.txt
|
||||
- overview-platform.html -> /reference/misc/overview-rse.html
|
||||
|
||||
To add new plug-ins you need to make changes in several places in
|
||||
this doc plug-in:
|
||||
|
||||
1) options.txt
|
||||
- the plug-in's source folder(s) must be included on the -sourcepath
|
||||
- code of required plug-ins must be added on the -classpath (the JAR(s)for non-JARed plug-ins and <plugin>/@dot for JARed plug-ins
|
||||
- the API package names must be included in the (alphabetical) package list at the end of the file
|
||||
- note that the @sep@ token is replaced during build by the appropriate separator character for the build platform.
|
||||
|
||||
2) buildDoc.xml
|
||||
- add a line in convertSchemaToHtml target to handle a new plug-ins extension point schemas
|
||||
|
||||
Adding new extension points:
|
||||
|
||||
1) reference/extension-points/index.html
|
||||
- add a line for each extension point
|
||||
|
||||
2) topics_Reference.xml
|
||||
- add a line for each extension point
|
||||
- add a line for each API package
|
|
@ -1,29 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
|
||||
<title>About</title>
|
||||
</head>
|
||||
<body lang="EN-US">
|
||||
<h2>About This Content</h2>
|
||||
|
||||
<p>June 5, 2007</p>
|
||||
<h3>License</h3>
|
||||
|
||||
<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise
|
||||
indicated below, the Content is provided to you under the terms and conditions of the
|
||||
Eclipse Public License 2.0 ("EPL"). A copy of the EPL is available
|
||||
at <a href="https://www.eclipse.org/legal/epl-2.0/">https://www.eclipse.org/legal/epl-2.0/</a>.
|
||||
For purposes of the EPL, "Program" will mean the Content.</p>
|
||||
|
||||
<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
|
||||
being redistributed by another party ("Redistributor") and different terms and conditions may
|
||||
apply to your use of any object code in the Content. Check the Redistributor's license that was
|
||||
provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
|
||||
indicated below, the terms and conditions of the EPL still apply to any source code in the Content
|
||||
and such source code may be obtained at <a href="http://www.eclipse.org">http://www.eclipse.org</a>.</p>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,112 +0,0 @@
|
|||
P.Code {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0.00pt;
|
||||
margin-top: 0.000000pt;
|
||||
margin-bottom: 0.000000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 15pt;
|
||||
font-size: 10.000000pt;
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
color: #4444CC;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
font-family: "Courier New", Courier, monospace;
|
||||
}
|
||||
H6.CaptionFigColumn {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0.000000pt;
|
||||
margin-top: 3.000000pt;
|
||||
margin-bottom: 11.000000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 0.000000pt;
|
||||
font-size: 9.000000pt;
|
||||
font-weight: bold;
|
||||
font-style: Italic;
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
P.Note {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0pt;
|
||||
margin-top: 19.500000pt;
|
||||
margin-bottom: 19.500000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 30pt;
|
||||
font-size: 11.000000pt;
|
||||
font-weight: normal;
|
||||
font-style: Italic;
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
EM.UILabel {
|
||||
font-weight: Bold;
|
||||
font-style: normal;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
EM.CodeName {
|
||||
font-weight: Bold;
|
||||
font-style: normal;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
font-family: "Courier New", Courier, monospace;
|
||||
}
|
||||
|
||||
body, html { border: 0px }
|
||||
|
||||
|
||||
/* following font face declarations need to be removed for DBCS */
|
||||
|
||||
body, h1, h2, h3, h4, h5, h6, p, table, td, caption, th, ul, ol, dl, li, dd, dt {font-family: Arial, Helvetica, sans-serif; color: #000000}
|
||||
pre { font-family: "Courier New", Courier, monospace;}
|
||||
|
||||
/* end font face declarations */
|
||||
|
||||
/* following font size declarations should be OK for DBCS */
|
||||
body, h1, h2, h3, h4, h5, h6, p, table, td, caption, th, ul, ol, dl, li, dd, dt {font-size: 10pt; }
|
||||
pre { font-size: 10pt}
|
||||
|
||||
/* end font size declarations */
|
||||
|
||||
body { background: #FFFFFF; margin-bottom: 1em }
|
||||
h1 { font-size: 18pt; margin-top: 5; margin-bottom: 1 }
|
||||
h2 { font-size: 14pt; margin-top: 25; margin-bottom: 3 }
|
||||
h3 { font-size: 11pt; margin-top: 20; margin-bottom: 3 }
|
||||
h4 { font-size: 10pt; margin-top: 20; margin-bottom: 3; font-style: italic }
|
||||
p { margin-top: 10px; margin-bottom: 10px }
|
||||
pre { margin-left: 6; font-size: 9pt; color: #4444CC }
|
||||
a:link { color: #0000FF }
|
||||
a:hover { color: #000080 }
|
||||
a:visited { text-decoration: underline }
|
||||
ul { margin-top: 10px; margin-bottom: 10px; }
|
||||
li { margin-top: 5px; margin-bottom: 5px; }
|
||||
li p { margin-top: 5px; margin-bottom: 5px; }
|
||||
ol { margin-top: 10px; margin-bottom: 10px; }
|
||||
dl { margin-top: 10px; margin-bottom: 10px; }
|
||||
dt { margin-top: 5px; margin-bottom: 5px; font-weight: bold; }
|
||||
dd { margin-top: 5px; margin-bottom: 5px; }
|
||||
strong { font-weight: bold}
|
||||
em { font-style: italic}
|
||||
var { font-style: italic}
|
||||
div.revision { border-left-style: solid; border-left-width: thin;
|
||||
border-left-color: #7B68EE; padding-left:5 }
|
||||
th { font-weight: bold }
|
||||
|
||||
a.command-link {
|
||||
}
|
||||
a.command-link img {
|
||||
border-width: 0px;
|
||||
border-style: none;
|
||||
vertical-align: middle;
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2000, 2010 IBM Corporation and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License 2.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# https://www.eclipse.org/legal/epl-2.0/
|
||||
#
|
||||
# SPDX-License-Identifier: EPL-2.0
|
||||
#
|
||||
# Contributors:
|
||||
# IBM Corporation - initial API and implementation
|
||||
# Martin Oberhuber (Wind River) - [314012] Remove provisional API declaration
|
||||
###############################################################################
|
||||
bin.includes = META-INF/,\
|
||||
about.html,\
|
||||
book.css,\
|
||||
notices.html,\
|
||||
plugin.properties,\
|
||||
plugin.xml,\
|
||||
toc.html,\
|
||||
toc.xml,\
|
||||
guide/,\
|
||||
index/,\
|
||||
reference/
|
||||
customBuildCallbacks = customBuildCallbacks.xml
|
||||
src.includes = about.html
|
|
@ -1,155 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 2005, 2010 IBM Corporation and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
|
||||
Contributors:
|
||||
IBM Corporation - initial API and implementation
|
||||
-->
|
||||
<project name="RSE DStore ISV Doc Build" default="all" basedir=".">
|
||||
|
||||
<property name="javadoc.link.location" value="${basedir}/javadoc.link.location"/>
|
||||
|
||||
<target name="init">
|
||||
<available file="${basedir}/index" property="index.present" />
|
||||
<path id="path_bootclasspath">
|
||||
<fileset dir="${java.home}/lib">
|
||||
<include name="*.jar"/>
|
||||
</fileset>
|
||||
</path>
|
||||
<property name="bootclasspath" refid="path_bootclasspath"/>
|
||||
<condition property="safeBaseLocation"
|
||||
value="${baseLocation}"
|
||||
else="${eclipse.home}">
|
||||
<isset property="baseLocation"/>
|
||||
</condition>
|
||||
<delete dir="${javadoc.link.location}" />
|
||||
</target>
|
||||
|
||||
<target name="computeClasspath" unless="javadoc.classpath">
|
||||
<!-- Construct the javadoc classpath and store it in a property. -->
|
||||
<echo level="info" message="Computing classpath ..."/>
|
||||
|
||||
<!-- Add platform dependencies required by your plug-in here.
|
||||
Note that this pattern expects Eclipse to have
|
||||
been installed into the platform directory structure, as is
|
||||
the case during the build. -->
|
||||
<patternset id="platform.classpath.pattern">
|
||||
<include name="**/org.eclipse.core*.jar"/>
|
||||
<include name="**/org.eclipse.core*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.ui*.jar"/>
|
||||
<include name="**/org.eclipse.ui*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.osgi*.jar"/>
|
||||
<include name="**/org.eclipse.osgi*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.equinox*.jar"/>
|
||||
<include name="**/org.eclipse.equinox*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.jface*.jar"/>
|
||||
<include name="**/org.eclipse.jface*/**/*.jar"/>
|
||||
<include name="**/org.junit*.jar"/>
|
||||
<include name="**/org.junit*/**/*.jar"/>
|
||||
<include name="**/com.ibm.icu*.jar"/>
|
||||
</patternset>
|
||||
|
||||
<pathconvert property="javadoc.classpath">
|
||||
<path>
|
||||
<fileset dir="${safeBaseLocation}">
|
||||
<patternset refid="platform.classpath.pattern"/>
|
||||
</fileset>
|
||||
</path>
|
||||
</pathconvert>
|
||||
<echo level="info" message="Done computing classpath."/>
|
||||
<echo level="info" message="Bootclasspath is: ${bootclasspath}"/>
|
||||
<echo level="debug" message="Classpath is: ${javadoc.classpath}"/>
|
||||
</target>
|
||||
|
||||
<target name="extractLinks">
|
||||
<mkdir dir="${javadoc.link.location}"/>
|
||||
|
||||
<patternset id="package.list">
|
||||
<include name="**/package-list"/>
|
||||
</patternset>
|
||||
|
||||
<!-- We only need the package-list files out of these -->
|
||||
<unzip dest="${javadoc.link.location}/platform/">
|
||||
<patternset refid="package.list"/>
|
||||
<fileset dir="${safeBaseLocation}/plugins">
|
||||
<include name="org.eclipse.platform.doc.isv*.jar"/>
|
||||
</fileset>
|
||||
</unzip>
|
||||
</target>
|
||||
|
||||
<target name="all" depends="init" unless="index.present">
|
||||
<antcall target="convertSchemaToHtml" />
|
||||
<antcall target="generateJavadoc" />
|
||||
<antcall target="build.index" />
|
||||
</target>
|
||||
|
||||
<target name="build.index" description="Builds search index for the plug-in: org.eclipse.dstore.doc.isv" if="eclipse.running">
|
||||
<help.buildHelpIndex manifest="${basedir}/plugin.xml" destination="${basedir}" />
|
||||
</target>
|
||||
|
||||
<target name="convertSchemaToHtml" if="eclipse.running">
|
||||
<property name="dest" value="reference/extension-points" />
|
||||
<!--
|
||||
<record name="${basedir}/temp.convert.txt" action="start" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.dstore.core/plugin.xml" destination="${dest}" />
|
||||
<record name="${basedir}/temp.convert.txt" action="stop" />
|
||||
-->
|
||||
</target>
|
||||
|
||||
<target name="getJavadocPath">
|
||||
<available file="${java.home}/../bin/javadoc.exe" property="javadoc" value="${java.home}/../bin/javadoc.exe" />
|
||||
<available file="${java.home}/../bin/javadoc" property="javadoc" value="${java.home}/../bin/javadoc" />
|
||||
<available file="/usr/bin/javadoc" property="javadoc" value="/usr/bin/javadoc" />
|
||||
<available file="/shared/tools/tm/ibm-java2-ppc64-50/bin/javadoc" property="javadoc" value="/shared/tools/tm/ibm-java2-ppc64-50/bin/javadoc" />
|
||||
</target>
|
||||
|
||||
<target name="generateJavadoc" depends="getJavadocPath,extractLinks,computeClasspath" if="javadoc">
|
||||
<property name="optionsFile" value="temp.options.txt" />
|
||||
<copy file="options.txt" tofile="${optionsFile}" overwrite="true" />
|
||||
|
||||
<condition property="argsListDelimiter" value=":">
|
||||
<os family="unix" />
|
||||
</condition>
|
||||
<condition property="argsListDelimiter" value=";">
|
||||
<os family="windows" />
|
||||
</condition>
|
||||
|
||||
<replaceregexp file="${basedir}/${optionsFile}" flags="g" match="(\r\n?|\n);" replace="${argsListDelimiter}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@rt@" value="${bootclasspath}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@cp@" value="${javadoc.classpath}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@baseLocation@" value="${safeBaseLocation}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@javadoc.link.location@" value="${javadoc.link.location}" />
|
||||
|
||||
<!--scrub isv plugin directories of any preexisting api doc content-->
|
||||
<delete dir="reference/api" />
|
||||
<mkdir dir="reference/api" />
|
||||
|
||||
<echo message="sep = ${argsListDelimiter}"/>
|
||||
<echo message="javadoc = ${javadoc}"/>
|
||||
<exec dir="." executable="${javadoc}" output="temp.bin.log" resultproperty="javadocResult">
|
||||
<arg line="@${basedir}/${optionsFile} -J-Xmx1000M" />
|
||||
</exec>
|
||||
<echo message="javadoc result = ${javadocResult}"/>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -1,169 +0,0 @@
|
|||
<!--
|
||||
Copyright (c) 2005, 2006 IBM Corporation and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
|
||||
Contributors:
|
||||
IBM Corporation - initial API and implementation
|
||||
-->
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Custom targets called from a project's generated build.xml -->
|
||||
<!-- Set customBuildCallbacks=<path/to/this/file> in your build.properties.-->
|
||||
<!-- ===================================================================== -->
|
||||
<project name="Build specific targets and properties" default="noDefault">
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Default target -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="noDefault">
|
||||
<echo message="This file must be called with explicit targets" />
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target build.jars -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.build.jars">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target build.jars -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.build.jars">
|
||||
<ant antfile="buildDoc.xml" />
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target build.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.build.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target build.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.build.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the compilation target <name> -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- source.foldern : n = 1 ... N, the source folders -->
|
||||
<!-- target.folder : where the results of the compilation go -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="pre.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after compilation but before jaring -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- source.foldern : n = 1 ... N, the source folders -->
|
||||
<!-- target.folder : where the results of the compilation go -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="post.compile.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the compilation target <name> -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- jar.location - the location of the compilation results -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="post.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.bin.parts -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- base.dir - root of the project -->
|
||||
<!-- build.result.folder - folder containing the build results -->
|
||||
<!-- target.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.bin.parts">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.bin.parts -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- base.dir - root of the project -->
|
||||
<!-- build.result.folder - folder containing the build results -->
|
||||
<!-- target.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.bin.parts">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.logs -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.logs">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.logs -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.logs">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target clean -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.clean">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target clean -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- plugin.destination - final destination of the build -->
|
||||
<!-- build.result.folder - results of the compilation -->
|
||||
<!-- temp.folder - temporary folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.clean">
|
||||
</target>
|
||||
</project>
|
|
@ -1,64 +0,0 @@
|
|||
<!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 2000, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>RSE Artifacts</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>DataStore Artifacts</h1>
|
||||
<p>With the DataStore, you interface the following artifacts:</p>
|
||||
<ul>
|
||||
<li><A href="#clientconnection">Client Connection</A></li>
|
||||
<li><A href="#datastore">DataStore</A></li>
|
||||
<li><A href="#dataelement">DataElement</A></li>
|
||||
<li><A href="#miner">Miner</A></li>
|
||||
</ul>
|
||||
<p>All the classes and interfaces mentioned here are defined in the <samp>org.eclipse.dstore.core</samp> plugin.</p>
|
||||
|
||||
<h2><A name="clientconnection">Client Connection</A></h2>
|
||||
<p>
|
||||
The <b>ClientConnection</b> class is used for establishing a DataStore connection. This class provides the
|
||||
means to instantiate a client DataStore and connect to a server DataStore on a specified host running under a
|
||||
specified port. The connection to the server DataStore may either be made directly or a startup
|
||||
negotiation may be made with a remote daemon before connecting to the server. This class also provides the means
|
||||
for disconnecting from the DataStore.
|
||||
</p>
|
||||
|
||||
<h2><A name="datastore">DataStore</A></h2>
|
||||
<p>
|
||||
The <b>DataStore</b> class is the heart of the DataStore communications framework. An instance of a DataStore contains a tree
|
||||
of <a href="#dataelement">DataElements</a>. This tree can be referred to as the <i>DataStore repository</i> because
|
||||
it consists of all the schema information and data content used. Any type of object or relationship defined, command definition or
|
||||
piece of data that needs to be communicated between the client and server are stored in the <i>DataStore repository</i>.
|
||||
The DataStore class can be used for finding, creating and deleting DataElements and for communicating commands
|
||||
to <a href="#miner">miner</a>. The DataStore class encapsulates all remote synchronizations between the client and the
|
||||
server via its <code>command</code> and <code>refresh</code> APIs.
|
||||
</p>
|
||||
|
||||
<h2><A name="dataelement">DataElement</A></h2>
|
||||
<p>
|
||||
The <b>DataElement</b> is the unit of information in a DataStore repository. Each DataElement has a set of attributes that describe
|
||||
the object it represents and is related to other DataElements by containing other DataElements. DataElements represent both the meaning
|
||||
of data as well as the data itself.
|
||||
</p>
|
||||
<p>
|
||||
For more information about DataElements, see the section, <a href="DataElements.html">DataElements and the DataStore model</a>.
|
||||
</p>
|
||||
|
||||
<h2><A name="miner">Miner</A></h2>
|
||||
<p>
|
||||
A <b>Miner</b> is an extension point to the DataStore. Miners are classes, residing on the server-side, that implement a common
|
||||
interface used by the DataStore for communication information between the DataStore and the tools.
|
||||
</p>
|
||||
<p>
|
||||
For more information about Miners, see the section, <a href="Miners.html">Miners</a>.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
|
|
@ -1,171 +0,0 @@
|
|||
<!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 2000, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>Tutorials</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>Communicating with the Server-side</h1>
|
||||
|
||||
<h2>Connecting to a Local DataStore</h2>
|
||||
<p>
|
||||
If you're writing an RSE subsystem to connect to a local standalone DataStore, the following needs
|
||||
to be done during the connect:
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
...
|
||||
ClientConnection clientConnection = new ClientConnection(connectionName);
|
||||
|
||||
// initialize the local datastore
|
||||
clientConnection.localConnect();
|
||||
|
||||
DataStore dataStore = clientConnection.getDataStore();
|
||||
|
||||
// specify miners to load
|
||||
dataStore.addMinersLocation("."); // initializes the default miners
|
||||
|
||||
// initialize miners
|
||||
dataStore.getSchema();
|
||||
dataStore.initMiners();
|
||||
...
|
||||
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<h2>Connecting to a Remote DataStore</h2>
|
||||
<p>
|
||||
If you're writing an RSE subsystem to connect to a remote DataStore, the only difference
|
||||
from the local scenario is that <code>connect</code> is called rather than <code>localConnect</code>.
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
...
|
||||
ClientConnection clientConnection = new ClientConnection(connectionName);
|
||||
|
||||
// prepare connection
|
||||
clientConnection.setHost(hostName);
|
||||
clientConnection.setPort(port);
|
||||
|
||||
// connect
|
||||
clientConnection.connect(ticket);
|
||||
|
||||
DataStore dataStore = clientConnection.getDataStore();
|
||||
|
||||
// specify miners to load
|
||||
dataStore.addMinersLocation("."); // initializes the default miners
|
||||
|
||||
// initialize miners
|
||||
dataStore.getSchema();
|
||||
dataStore.initMiners();
|
||||
...
|
||||
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<h2>Loading an Additional DataStore Miner</h2>
|
||||
<p>
|
||||
If the new miner has been registered via the default minerFile.dat file, then
|
||||
no further steps are required to load it. Otherwise, after the subsystem is
|
||||
connected to the remote DataStore, you need to tell the DataStore to load the
|
||||
miner as follows.
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
...
|
||||
dataStore.addMinersLocation(location);
|
||||
dataStore.getSchema();
|
||||
...
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<p>
|
||||
This tells the host DataStore to instantiate and initialize all miners listed in
|
||||
the specified minerFile.dat file.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>Sending Commands to a Miner</h2>
|
||||
<p>
|
||||
To send a command to a miner, the required <a href="DataElements.html#commanddescriptor">command descriptor</a> must first be obtained
|
||||
using the method <code>DataStore.localDescriptorQuery</code>. The method <code>DataStore.command</code> is then called with command
|
||||
descriptor and the subject of the command. For example, a query might need to be called on the miner as shown in the following code segment.
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
...
|
||||
// the UI model object
|
||||
MyRemoteObject obj = getMyRemoteObject();
|
||||
|
||||
// get the corresponding DataElement for this object
|
||||
DataElement deObj = obj.getDataElement();
|
||||
|
||||
// get the DataStore from the DataElement
|
||||
DataStore ds = deObj.getDataStore();
|
||||
|
||||
// get the query command descriptor for the subject
|
||||
DataElement queryCmd = ds.localDescriptorQuery(deObj.getDescriptor(), "MY_QUERY_COMMAND");
|
||||
|
||||
// send the command
|
||||
DataElement status = ds.command(queryCmd, deObj, true);
|
||||
...
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<h2>Receiving Data from a Miner</h2>
|
||||
<p>
|
||||
After a command is sent to a miner, you might want to receive information that the miner produced in response to the command.
|
||||
DataStore commands and responses are sent asynchronously, much like events. On the server, the
|
||||
<a href="Communications.html#servercommandhandler">Server Command Handler</a> reacts to incoming commands by calling the <code>handleCommand</code>
|
||||
method on the appropriate miner. For the client, the <a href="Communications.html#clientcommandhandler">Client Command Handler</a>
|
||||
reacts to incoming responses by firing domain notifications. In order to receive miner responses, asynchronously,
|
||||
you need to implement a DataStore domain listener.
|
||||
</p>
|
||||
<p>
|
||||
A domain listener implements the IDomainListener interface. An instance of an IDomainListener needs to be added to the DataStore domain listener
|
||||
list. The following is what a simple domain listener looks like:
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
public class MyDomainListener implements IDomainListener
|
||||
{
|
||||
public boolean listeningTo(DomainEvent e)
|
||||
{
|
||||
// check if we care about this event
|
||||
...
|
||||
}
|
||||
|
||||
public void domainChanged(DomainEvent e)
|
||||
{
|
||||
// get the data from this event
|
||||
...
|
||||
}
|
||||
}
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<p>
|
||||
A domain listener may either listen for the duration of a DataStore session or may be transient, to be used for
|
||||
a receiving data from a particular command. For example, after calling <code>DataStore.command</code>, which returns
|
||||
the status of the command instance, a listener can be added as follows:
|
||||
</p>
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
...
|
||||
MyDomainListener listener = new MyDomainListener(shell);
|
||||
`ds.getDomainNotifier().addDomainListener(listener);
|
||||
listener.setStatus(status);
|
||||
...
|
||||
</pre>
|
||||
</font>
|
||||
</body>
|
||||
</html>
|
|
@ -1,158 +0,0 @@
|
|||
<!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 2000, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>RSE Model</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>DataStore Communications</h1>
|
||||
<p>
|
||||
Communication in the DataStore is asynchronous and symmetric. Commands sent and results received are all represented in the same form,
|
||||
<a href="DataElements.html">DataElements</a> and the underlying means of transmitting this information is basically the same for each.
|
||||
When a command is issued, it gets queued and then later routed to the appropriate <b>miner</b> where it gets executed.
|
||||
A miner returns results by updating the DataStore repository with information. Like commands, these
|
||||
results are queued and then later notifications are sent out to any listener that requires the results.
|
||||
</p>
|
||||
<p>
|
||||
The asynchronous routing of data and commands between a client and the tools is made possible by threads, called <i>handlers</i>. There are two
|
||||
types of handlers - a <a href="#commandhandlers">Command Handler</a> and an <a href="#updatehandlers">Update Handler</a>. Each handler thread contains a queue
|
||||
of data that needs to be transmitted and each periodically communicates the data contained in it's queue.
|
||||
</p>
|
||||
|
||||
<h2><a name="commandhandlers">Command Handlers</a></h2>
|
||||
<p>
|
||||
The job of the Command Handler is to route commands to the miners. There are two types of command handlers.
|
||||
</p>
|
||||
|
||||
<h3><a name="clientcommandhandler">Client Command Handler</a></h3>
|
||||
<p>
|
||||
The <b>Client Command Handler</b> is a command handler responsible for transmitting its queue of DataStore commands across a network to
|
||||
the server DataStore. This handler encapsulates the communication of DataStore client data to a DataStore server. The Client Command Handler
|
||||
interfaces the DataStore communication layer, where its queue of commands gets serialized into XML before being sent over a TCP/IP socket
|
||||
to the server.
|
||||
</p>
|
||||
|
||||
<h3><a name="servercommandhandler">Server Command Handler</a></h3>
|
||||
The <b>Server Command Handler</b> is a command handler responsible for directly routing the DataStore commands in its queue to the appropriate
|
||||
miner(s) depending on the command.
|
||||
|
||||
<h2><a name="updatehandlers">Update Handlers</a></h2>
|
||||
<p>
|
||||
The job of the Update Handler is to notify the client that some results have been received or changed. There are two types of
|
||||
update handlers.
|
||||
</p>
|
||||
|
||||
<h3><a name="clientupdatehandler">Client Update Handler</a></h3>
|
||||
<p>
|
||||
The <b>Client Update Handler</b> is an update handler responsible for sending out domain notifications for each unit of data
|
||||
contained in its queue.
|
||||
</p>
|
||||
|
||||
<h3><a name="serverupdatehandler">Server Update Handler</a></h3>
|
||||
<p>
|
||||
The <b>Server Update Handler</b> is an update handler responsible for transmitting its queue of DataStore objects across a network to
|
||||
the client DataStore. This handler encapsulates the communication of DataStore server data to a DataStore client. The Server Update Handler
|
||||
interfaces the DataStore communication layer, where its queue of data gets serialized into XML before being sent over a TCP/IP socket
|
||||
to the client.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Communication between a client and tools may either occur locally and remotely depending on how the
|
||||
user chooses to connect to the DataStore. The client interface and the server tooling are the same regardless of
|
||||
whether the DataStore is standalone or client/server based. The communication differences are encapsulated by
|
||||
the DataStore handlers.
|
||||
</p>
|
||||
|
||||
<h2>Standalone Local DataStore</h2>
|
||||
<p>
|
||||
Locally, the DataStore may be used standalone such that all communication through the DataStore goes directly to between the <b>miners</b>
|
||||
and the client, all running within the same process. In this case, there is only a single DataStore and no communication goes
|
||||
over the network. For its handlers, the local DataStore uses a <b>Client Update Handler</b> and a <b>Server Command Handler</b>.
|
||||
</p>
|
||||
|
||||
<img src="images/local.jpg" alt="Local DataStore Eclipse" border="0">
|
||||
|
||||
<p>
|
||||
In the above dialog, the path of commands to the tools is shown with solid lines, while the path of data to client is shown with dotted lines.
|
||||
</p>
|
||||
|
||||
<ol>
|
||||
<li>
|
||||
In RSE, a subsystem calls a DataStore command API to issue a command.
|
||||
</li>
|
||||
<li>
|
||||
The command is then queued in the <b>Server Command Handler</b>.
|
||||
</li>
|
||||
<li>
|
||||
The Server Command Handler gets the command from the queue, determines which miner should run it, and passes the command into that miner.
|
||||
</li>
|
||||
<li>The miner then executes the command and produces results by calling DataStore object creation methods. When the resulting objects are created,
|
||||
the DataStore queues them in the <b>Client Update Handler</b>.
|
||||
</li>
|
||||
<li>
|
||||
The Client Update Handler gets the data from the queue and sends out a domain notification for each data object in the queue.
|
||||
</li>
|
||||
<li>
|
||||
A domain listener for the RSE subsystem receives the notification and then uses the result data to update the UI.
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h2>Client/Server DataStore</h2>
|
||||
<p>
|
||||
In the remote case, a DataStore client is part of the Eclipse process, while the DataStore server is run
|
||||
in a separate process on a remote host. Information is transferred between the two DataStore repositories over
|
||||
a TCP/IP socket. Any data that is created or changed on either the client or the server is asynchronously
|
||||
propagated over to the other side via serialization/deserialization of the delta.
|
||||
|
||||
Like in the standalone case, the client DataStore uses a <b>Client Update Handler</b>, but instead of using
|
||||
a Server Command Handler it uses a <b>Client Command Handler</b>. The server DataStore uses a <b>Server Update Handler</b>
|
||||
and a <b>Server Command Handler</b>.
|
||||
</p>
|
||||
|
||||
<img src="images/remote.jpg" alt="Remote DataStore Eclipse" border="0">
|
||||
|
||||
<ol>
|
||||
<li>
|
||||
In RSE, a subsystem calls a DataStore command API to issue a command.
|
||||
</li>
|
||||
<li>
|
||||
The command is then queued in the <b>Client Comamnd Handler</b>.
|
||||
</li>
|
||||
<li>
|
||||
The Client Command Handler gets the command from the queue and, via the communication layer, transmits it to the server DataStore.
|
||||
The communication layer on the client serializes the DataStore respository objects that make up the command and sends that
|
||||
serialization over a socket to the server.
|
||||
</li>
|
||||
<li>
|
||||
The communication layer on the server deserializes the socket data and creates DataStore objects in the DataStore repository.
|
||||
Those command objects are added it to the <b>Server Command Handler</b> queue.
|
||||
</li>
|
||||
<li>
|
||||
The Server Command Handler gets the command from the queue, determines which miner should run it, and passes the command into that miner.
|
||||
</li>
|
||||
<li>
|
||||
The miner then executes the command and produces results by calling DataStore object creation methods. When the resulting objects are created,
|
||||
the DataStore queues them in the <b>Server Update Handler</b>.
|
||||
</li>
|
||||
<li>
|
||||
The Server Update Handler gets the results from the queue and transmits them, via the DataStore communicate layer, to the client DataStore.
|
||||
The communication layer on the server serializes the DataStore objects from the queue and sends that serialization over a socket
|
||||
to the client.
|
||||
</li>
|
||||
<li>
|
||||
The communication layer on the client deserializes the socket data and creates DataStore objects in the DataStore respository.
|
||||
Those results are added to the <b>Client Update Handler</b> queue.
|
||||
</li>
|
||||
<li>
|
||||
The Client Update Handler gets the data from the queue and sends out a domain notification for each data object in the queue.
|
||||
</li>
|
||||
<li>
|
||||
A domain listener for the RSE subsystem receives the notification and then uses the result data to update the UI.
|
||||
</li>
|
||||
</ol>
|
||||
</body>
|
||||
</html>
|
|
@ -1,206 +0,0 @@
|
|||
<!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 2000, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>RSE Model</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1><a name="dataelements">DataElements</a></h1>
|
||||
<p>
|
||||
All information in the DataStore repository is stored in the form of <b>DataElements</b>. DataElements are objects
|
||||
that have attributes and may contain other DataElements. The attributes of a DataElement are stored as an array of
|
||||
strings. A particular attribute is retrieved by calling <code>getAttribute(</code><i>attribute index</i><code>)</code>.
|
||||
A particular attribute is set by calling <code>setAttribute(</code><i>attribute index</i><code>, </code><i>attribute value</i><code>)</code>.
|
||||
The attribute indices that can be used are as follows:
|
||||
</p>
|
||||
<table>
|
||||
<tr><td><b>Attribute</b></td><td><b>Description</b></td></tr>
|
||||
<tr><td><code>A_TYPE</code></td><td>Attribute indicating the type of object. The type can be used to indicate the type of an instance of data, a descriptor, a relationship or a commnad.</td></tr>
|
||||
<tr><td><code>A_NAME</code></td><td>Attribute indicating the name of object.</td></tr>
|
||||
<tr><td><code>A_VALUE</code></td><td>Attribute indicating the more information about that object</td></tr>
|
||||
<tr><td><code>A_SOURCE</code></td><td>Attribute indicating source information about an object, if applicable</td></tr>
|
||||
<tr><td><code>A_REF_TYPE</code></td><td>Attribute indicating whether the object is a normal object ("value"), a spirit ("spirit"), or a reference to another DataElement ("reference"). In the DataStore, a reference to another DataElement is represented with a DataElement. For more information on spirit elements, see <a href="MemoryManagement.html">Memory Management in DataStore</a> </td></tr>
|
||||
<tr><td><code>A_ID</code></td><td>The unique ID of a DataElement.</td></tr>
|
||||
</table>
|
||||
<p>
|
||||
Rather than representing different types of objects as different classes, the type attribute of a DataElement
|
||||
indicates its type. There are two general categories of DataElements. There are schema elements, <A href="#descriptors">descriptors</a>, and instances of
|
||||
those schema elements, <a href="#instances">instances</a>.
|
||||
</p>
|
||||
|
||||
<h2><a name="descriptors">Descriptors</a></h2>
|
||||
<p>
|
||||
A descriptor is a DataElement that describes some type of object. The <code>A_TYPE</code> attribute of a descriptor indicates what type of
|
||||
descriptor it is. The <code>A_NAME</code> attribute of a descriptor identifies the type that the descriptor describes.
|
||||
</p>
|
||||
<p>
|
||||
A descriptor may be of one of the following types:
|
||||
</p>
|
||||
<table>
|
||||
<tr><td><code>T_OBJECT_DESCRIPTOR</code></td><td>Describes a type of object</td></tr>
|
||||
<tr><td><code>T_RELATION_DESCRIPTOR</code></td><td>Describes a type of relationship that may exist between two DataElements.</td></tr>
|
||||
<tr><td><code>T_COMMAND_DESCRIPTOR</code></td><td>Describes a type of command</td></tr>
|
||||
</table>
|
||||
|
||||
<h3><a name="objectdescriptors">Object Descriptors</a></h3>
|
||||
<p>
|
||||
<b>Object descriptors</b> describe the different types of data that can be represented in the DataStore repository. Object descriptors
|
||||
can describe types of object instances as well as other types of object descriptors. Each object descriptor is related to other object,
|
||||
relationship and command descriptors.
|
||||
</p>
|
||||
|
||||
<h3><a name="relationdescriptors">Relation Descriptors</a></h3>
|
||||
<p>
|
||||
<b>Relation descriptors</b> describe the different types of relationships that can be represented in the DataStore repository. Relation
|
||||
descriptors describe types of relationships between object instances, object descriptors, command instances and command descriptors.
|
||||
</p>
|
||||
|
||||
<h3><a name="commanddescriptors">Command Descriptors</a></h3>
|
||||
<p>
|
||||
<b>Command descriptors</b> describe the different types of commands that can be executed on an object in the DataStore repository.
|
||||
In the DataStore schema, object descriptors are related to command descriptors to indicate that an object instance of a certain type can
|
||||
have the described command run on it. Command descriptors are always contained by the object descriptors they are associated with. The
|
||||
<code>A_SOURCE</code> attribute of a command descriptor indicates which miner(s) may execute an instance of such a command.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
These three types of objects are used to define the DataStore schema. Instances of relation descriptors are used to define
|
||||
relationships between descriptors in the schema.
|
||||
</p>
|
||||
|
||||
|
||||
<h2><a name="instances">Instances</a></h2>
|
||||
<p>
|
||||
An instance object is a DataElement that is an instance of a descriptor. An instance may either by an object, a
|
||||
relation or a command. An instance uses its descriptor's <code>A_NAME</code> attribute as its <code>A_TYPE</code> attribute.
|
||||
</p>
|
||||
|
||||
<h3><a name="objects">Objects</a></h3>
|
||||
<p>
|
||||
<b>Objects</b> are instances of <b>object descriptors</b>. Objects are used to the represent the external or internal
|
||||
entities that are being interacted with. An instance object can be related in a certain way to another type of
|
||||
instance object if its object descriptor has the same kind of relationship to the other object's object descriptor.
|
||||
An instance object may be associated with a particular command if its object descriptor is associated with the command descriptor
|
||||
for that command.
|
||||
</p>
|
||||
|
||||
<h3><a name="relations">Relations</a></h3>
|
||||
<p>
|
||||
<b>Relations</b> are instances of <b>relation descriptors</b>. A relation is really a typed reference to another object. Relations
|
||||
may exist from one object to another if the schema indicates that the object descriptor for the first object may have a relationship
|
||||
of that type to the other object's descriptor. Relations are used to describe the relationship between two instances, the
|
||||
relationship between two descriptors and the relationship between an instance and a descriptor. A relation is able to reference
|
||||
another element by storing the other element's <code>A_ID</code> attribute in its <code>A_SOURCE</code> attribute. If a relation object
|
||||
needs to be dereferenced, it uses this attribute to query the DataStore for the object being referenced.
|
||||
</p>
|
||||
<p>
|
||||
A relation is typically represented by having an instance object DataElement contain a relation DataElement.
|
||||
There are two types of relationships between elements that are implicit. These are the <i>contains</i> and
|
||||
the <i>parent of</i> relationships. If an element is directly contained within another element, the
|
||||
relationship between those two elements is implied to be <i>contains/parent of</i> relationships.
|
||||
</p>
|
||||
|
||||
<h3><a name="commands">Commands</a></h3>
|
||||
<p>
|
||||
<b>Commands</b> are instances of <b>command descriptors</b>. A command is always associated with an instance object such that
|
||||
the command is to be performed on that object. The object associated with a command is referred to as the <i>subject</i> of
|
||||
the command. Only a command that has a command descriptor that is related to the object descriptor of the subject may be
|
||||
constructed. A command object is constructed when the DataStore method <code>command()</code> is called. The command is
|
||||
created with a reference to the subject, an optional set of arguments, also instance objects, and a status object instance, used
|
||||
to indicate the state of the command. The tree of elements for a command is communicated, via the DataStore comm layer, to
|
||||
the appropriate miner(s), where it is interpreted and executed.
|
||||
</p>
|
||||
<p>
|
||||
The structure of a command looks like the following:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Command
|
||||
<ul>
|
||||
<li>subject - a reference to the instance that this command applies to</li>
|
||||
<li>arg 1 - an optional argument represented as a DataElement</li>
|
||||
<li>...</li>
|
||||
<li>arg n - an optional argument represented as a DataElement</li>
|
||||
<li>status - element that represents the current status of a command</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
As an example, suppose the DataStore is being used for browsing a filesystem. The filesystem entities and how to interact
|
||||
with the filesystem needs to be defined in the schema. The following descriptors could be used to describe this.
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>Object Descriptors
|
||||
<ul>
|
||||
<li>"generic file object" - describes a generic file system object</li>
|
||||
<li>"file" - describes a file object</li>
|
||||
<li>"folder" - describes a folder object</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Relation Descriptors
|
||||
<ul>
|
||||
<li>"contains" - represents the containment relationship between two objects</li>
|
||||
<li>"abstracts" - represents a derives relationship between two object descriptors</li>
|
||||
<li>"abstracted by" - represents an inherits relationship between two object descriptors</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Command Descriptors
|
||||
<ul>
|
||||
<li>"query" - a command to list the contents of a folder</li>
|
||||
<li>"rename" - a command to rename a file or folder</li>
|
||||
<li>"delete" - a command to delete a file or folder</li>
|
||||
<li>"create" - a command to create a new file or folder from an existing folder</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
Now that all the required descriptors are defined, relations between descriptors are needed. Note that the
|
||||
symbol "->" implies a "contains" relationship and "IO()" implies an instance of a specified descriptor.
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>"generic file object"
|
||||
<ul>
|
||||
<li>->"rename"</li>
|
||||
<li>->"delete"</li>
|
||||
<li>->IO("abstracts")->"folder"</li>
|
||||
<li>->IO("abstracts")->"file"</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>"folder"
|
||||
<ul>
|
||||
<li>->"create"</li>
|
||||
<li>->"query"</li>
|
||||
<li>->IO("abstracted by")->"generic file object"</li>
|
||||
<li>->IO("contains")->"generic file object"</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>"file"
|
||||
<ul>
|
||||
<li>->IO("abstracted by")->"generic file object"</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
DataStore schemas are created by the DataStore <b>miners</b>. Each tool contributes it's
|
||||
own schema to the DataStore schema, referencing descriptors of other schemas, such
|
||||
that one tool can contribute to another tool. All the command descriptors that are
|
||||
contributed by a miner are expected to be handled by the contributing miner. Whenever
|
||||
a miner creates a new command descriptor, the <code>A_SOURCE</code> attribute indicates
|
||||
to the DataStore that an instance of that command should be routed to that miner when
|
||||
it's issued.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
See the section, <a href="Miners.html">Miners</a> to find out how miners contribute schemas
|
||||
and execute commands.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,18 +0,0 @@
|
|||
<!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 2000, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>Tutorials</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>Extending and Using the DataStore</h1>
|
||||
<p>
|
||||
This section describes the basic steps required for extending the server DataStore with
|
||||
a DataStore miner and how to interact with the miners from an RSE subsystem.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,68 +0,0 @@
|
|||
<!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 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>RSE DataStore Memory Management</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1><a name="dataelements">Memory Management in DataStore</a></h1>
|
||||
<p>
|
||||
A Memory Management scheme has been implemented for the DataStore that significantly reduces the memory footprint of the
|
||||
DataElements in high-use, long up-time situations. A problem that was identified was that in the DataStore, DataElements were
|
||||
rarely being destroyed - only when the files they represented were themselves deleted. When directories in the file system were explored,
|
||||
DataElements were being created to represent the files in the directories, but these DataElements were cached and never
|
||||
removed from the cache. Therefore, the number of DataElements in the DataStore was always increasing. With no opportunity
|
||||
to clear the cache or remove elements, the memory usage of the server continued to grow boundlessly.
|
||||
</p>
|
||||
<h2><a name="spirit">A solution - Spirit DataElements</a></h2>
|
||||
<p>
|
||||
The solution to the problem of an ever-growing set of DataElements was simple - provide a mechanism of removing "old"
|
||||
DataElements and thus shrinking the set. Since server memory real-estate comes at a much higher premium, the focus here
|
||||
is on server-side memory reduction. The assumption then, is that DataElements in the DataStore will always remain in
|
||||
memory on the client, but that in the mirror-image DataStore that resides on the server, DataElements can be removed.
|
||||
</p>
|
||||
<p>
|
||||
Formerly, the RSE ran under the assumption that the client and server DataStores mirrored each other. The new
|
||||
implementation has a server DataStore tree that is only a subset of all the elements in the client tree (because
|
||||
some elements get removed.) In order to accommodate this, a new boolean member variable was added to the DataElement
|
||||
class called "isSpirit". When this variable is set to true it means different things on the client and server. On the
|
||||
server, a "spirit" DataElement means the element is treated in much the same way as a "deleted" element. At the first
|
||||
opportunity, the element is purged from the DataStore and garbage collected by the JVM - freeing up memory. On the client,
|
||||
a "spirit" element means that that particular DataElement's counterpart has been made a spirit; thus the client "knows"
|
||||
that its twin element on the server side has either been deleted, or is about to be deleted.
|
||||
</p>
|
||||
<h2><a name="disconnecting">Disconnecting "old" DataElements:</a></h2>
|
||||
<p>
|
||||
How is it determined when to mark a given DataElement as a spirit? It was decided that the decision to this would be
|
||||
left to clients of the DataStore (the miners), rather than to the DataStore itself. This was done for the purposes of
|
||||
granularity: some individual miners may not want DataElements to be ever purged, some might want only specific elements,
|
||||
etc. As an example, the UniversalFileSystemMiner employs the FileClassifier to classify files returned from a directory
|
||||
query, and after each file has been classified, the DataStore's disconnectObject() method is called on the DataElement
|
||||
representing that file, setting the stage for its becoming a spirit.
|
||||
</p>
|
||||
<h2><a name="queue">Controlling the queue of DataElements:</a></h2>
|
||||
<p>
|
||||
A new class, the DataElementRemover, running in its own thread, maintains a queue of objects that were passed into
|
||||
DataStore's disconnectObject() method; each object is stored in the queue along with the time it was added. The
|
||||
DataElementRemover is configurable by two command-line options: -DSPIRIT_EXPIRY_TIME=x and -DSPIRIT_INTERVAL_TIME=y;
|
||||
where x and y are integers representing a number of seconds. Every y seconds, the queue checks its elements and "makes
|
||||
spirit" all those that are older than x seconds. The DataElement is then refreshed, and the change propagated to the
|
||||
client. On the server side, the DataElement is deleted at the first opportunity.
|
||||
</p>
|
||||
<h2><a name="feature">Turning on the feature:</a></h2>
|
||||
<p>
|
||||
On the client side, this feature is always "on". It is the server which is configured to do or not to do the spirit
|
||||
DataElement behaviour. This way, backwards compatibility is maintained - if a new client connects to an old server, or a
|
||||
server with spirit turned off, the client detects this and operates as before. If an old client connects to a new server
|
||||
with spirit turned on, the server detects that the client does not have spirit capability and behaves as it did before.
|
||||
</p>
|
||||
<p>
|
||||
To turn on the spirit feature on the server side, one needs to include the command-line option -DDSTORE_SPIRIT_ON=true.
|
||||
The server scripts have been packaged in order to do this by default.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,142 +0,0 @@
|
|||
<!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 2000, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>RSE Model</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Miners</h1>
|
||||
<p>
|
||||
<b>Miners</b> are remote tooling extensions to the DataStore. Each miner describes the model
|
||||
that it works with as well as the commands associated with the model that it implements. Each
|
||||
miner is responsible for extending the DataStore schema and providing implementations for
|
||||
commands that it defines.
|
||||
</p>
|
||||
<p>
|
||||
All miners are derived from the abstract class <code>Miner</code>. To write a miner, the
|
||||
following APIs need to be implemented:
|
||||
</p>
|
||||
<pre>
|
||||
public abstract void extendSchema(DataElement schemaRoot);
|
||||
public abstract DataElement handleCommand(DataElement theCommand);
|
||||
</pre>
|
||||
<p>
|
||||
The first method, <code>extendSchema</code>, is implemented by a miner to contribute the types of objects, relationships and commands that
|
||||
it deals with. The second method, <code>handleCommand</code>, is implemented by a miner so that it can execute the commands it defines.
|
||||
</p>
|
||||
|
||||
<h2>Extending the Schema</h2>
|
||||
<p>
|
||||
A miner extends the DataStore schema by populating the <i>schemaRoot</i> with <a href="DataElements.html#descriptors">descriptors</a>.
|
||||
The DataStore repository tree is structured so that there is a single node where schema descriptors reside. All
|
||||
<a href="DataElements.html#objectdescriptors">object descriptors</a> and <a href="DataElements.html#relationdescriptors">relation descriptors</a>
|
||||
are created under this schema root. <a href="DataElements.html#commanddescriptors">Command descriptors</a> are created under the
|
||||
object descriptors that they apply to. Each miner contributes to this global DataStore schema, so each may also extend or leverage the
|
||||
information from another miner's schema.
|
||||
</p>
|
||||
<p>
|
||||
A miner implements <code>extendSchema(DataElement)</code> to add new descriptors to the DataStore schema. If a miner creates representations
|
||||
of objects that are not already represented by some other miner's schema, then it needs to define descriptors for those new types of objects.
|
||||
Sometimes new relationship types also need to be defined by a miner for its particular model. In order for a miner to be interacted with,
|
||||
via <code>handleCommand</code>, it needs to define command descriptors for object descriptors in the schema. The code below illustrates the
|
||||
typical structure of an <code>extendSchema</code> implementation:
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
public void extendSchema(DataElement schemaRoot)
|
||||
{
|
||||
// create object descriptors
|
||||
DataElement myObjectType1 = createObjectDescriptor(schemaRoot, "my object type 1");
|
||||
DataElmeent myObjectType2 = createObjectDescriptor(schemaRoot, "my object type 2");
|
||||
DataElement myObjectContainerType = createObjectDescriptor(schemaRoot, "my object container");
|
||||
|
||||
// create relation descriptors
|
||||
DataElement myRelationType = createRelationDescriptor(schemaRoot, "my relation type");
|
||||
|
||||
// create command descriptors
|
||||
createCommandDescriptor(myObjectType1, "My Command 1", MY_COMMAND_1);
|
||||
createCommandDescriptor(myObjectType2, "My Command 2", MY_COMMAND_2);
|
||||
createCommandDescriptor(myObjectContainerType, "Query", MY_QUERY);
|
||||
|
||||
// establish relationships between object types
|
||||
createReference(myObjectType1, myObjectType2, myRelationType); // myObjectType1 instances can be associated with myObjectType2 instances by myRelationType
|
||||
createReference(myObjectContainerType, myObjectType1); // myObjectContainerType instances can contain myObjectType1 instances
|
||||
createReference(myObjectContainerType, myObjectType2); // myObjectContainerType instances can contain myObjectType2 instances
|
||||
|
||||
...
|
||||
}
|
||||
</pre>
|
||||
</font>
|
||||
|
||||
<p>
|
||||
The DataStore does not enforce that instance element trees are structured in the manner that the schema describes so the
|
||||
establishing of relationships between object types, as done in this example, is unnecessary as a miner knows its own
|
||||
model, since it defined it. But by convention, it is a good thing to describe a model with those relationships explicitly stated
|
||||
because other miners or client tools may want to leverage or extend the model for their own purposes.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>Handling Commands</h2>
|
||||
<p>
|
||||
The <code>handleCommand</code> method is called by the <a href="Communications.html#servercommandhandler">Server Command Handler</a>
|
||||
if the descriptor for a command instance is associated with a particular miner. When this is called, it is up to the miner implementation
|
||||
to interpret and execute the command.
|
||||
</p>
|
||||
<p>
|
||||
A <a href="DataElements.html#commands">Command instance</a> is a tree of <a href="DataElements.html">DataElements</a> representing the
|
||||
command, the subject of the command, additional arguments to the command and the status of the command. The way this is normally interpretted
|
||||
by a miner to mean <i>perform the specified command on the subject using the specified arguments. Change the status to be "done" when the
|
||||
operation is complete.</i>.
|
||||
</p>
|
||||
<p>
|
||||
The base miner class provides APIs to assist a miner implementation in extracting information from
|
||||
a command tree. The method <code>getCommandName(DataElement)</code> is used to extract the
|
||||
name of the command, <code>getCommandStatus(DataElement)</code> returns the status element of
|
||||
the command, and <code>getCommandArgument(DataElement, int)</code> returns an argument at the
|
||||
specified index. The first argument is always the subject. The code below illustrates
|
||||
the typical structure of a <code>handleCommand</code> implementation.
|
||||
</p>
|
||||
|
||||
<font color='#4444CC'>
|
||||
<pre>
|
||||
public DataElement handleCommand(DataElement theElement)
|
||||
{
|
||||
String name = getCommandName(theElement);
|
||||
DataElement status = getCommandStatus(theElement);
|
||||
DataElement subject = getCommandArgument(theElement, 0);
|
||||
|
||||
if (name.equals(MY_COMMAND_1))
|
||||
{
|
||||
handleMyCommand1(subject, arg1,...,argn, status);
|
||||
}
|
||||
...
|
||||
status.setAttribute(DE.A_NAME, "done");
|
||||
_dataStore.refresh(status);
|
||||
}
|
||||
</pre>
|
||||
</font>
|
||||
<p>
|
||||
The results of a command may be returned in a variety of ways, depending on its
|
||||
purpose. One thing that is always returned is the status object.
|
||||
</p>
|
||||
<p>
|
||||
Think of the status object as the return value of a method. The status object needs to be set to "done"
|
||||
whenever a command is complete but it may also optionally contain results in the form
|
||||
of DataElements. If a command is requesting transient information about something, then
|
||||
the status object could be populated with the results.
|
||||
</p>
|
||||
<p>
|
||||
Each miner has read and write access to the entire DataStore tree. If desired a miner
|
||||
can modify that tree as a result of a command. For example, a miner used for browsing
|
||||
a file system might populate the subject, a folder object, with other folder and file
|
||||
objects, rather than transiently via the status object. In this way, a miner caches
|
||||
data and expands the data available to the DataStore repository in response to user
|
||||
requests.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,36 +0,0 @@
|
|||
<!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 2000, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>Tutorials</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>Extending the Server-side</h1>
|
||||
<p>
|
||||
This section describes the basic steps needed to extend the server side tooling using <b>Miners</b>.
|
||||
</p>
|
||||
<ol>
|
||||
<li>
|
||||
Write a new <a href="Miners.html">DataStore miner</a> by extending the <b>Miner</b> class.
|
||||
</li>
|
||||
<li>
|
||||
Put the compiled miner class on the host, preferably in jar form
|
||||
</li>
|
||||
<li>
|
||||
Register the new miner so that it gets loaded when the server DataStore is connected to. This may be done
|
||||
by adding the miner's qualified classname to the file <i>minerFile.dat</i>. Alternatively, an additional <i>minerFile.dat</i>
|
||||
file can be used to supply the classname.
|
||||
</li>
|
||||
<li>
|
||||
Update the classpaths for the server side so that the new miner class can be loaded by the
|
||||
DataStore. This will vary depending on how the DataStore server is started up. If a startup
|
||||
script is used, then you could update the classpath specified in the script or the system classpath
|
||||
could be updated.
|
||||
</li>
|
||||
</ol>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 32 KiB |
Before Width: | Height: | Size: 73 KiB |
Before Width: | Height: | Size: 56 KiB |
|
@ -1,67 +0,0 @@
|
|||
<!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 2000, 2006. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<title>Remote System Explorer Overview</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>DataStore Overview</h1>
|
||||
<p>
|
||||
The RSE uses the concept of <b>subsystems</b> as a common abstraction for remote tooling. Subsystems provide
|
||||
public interfaces that are called when some remote tool or resource needs to be communicated with. As long as
|
||||
the appropriate public interfaces are implemented, the means of communicating with these remote tools and resources
|
||||
is up to the developer of the subsystem. Whatever that might be, some kind of communication layer is required
|
||||
to access tools on the host. One such means that is used by existing RSE Subsystems and can be reused is the
|
||||
DataStore framework.
|
||||
</p>
|
||||
<p>
|
||||
The <b>DataStore</b> communications framework is used to provide remote access and tooling for the Remote System Explorer.
|
||||
It is a communications layer, in-memory data repository and a pluggable tooling framework. While Eclipse provides
|
||||
the ability for local tools to plug into the Eclipse workbench, DataStore provides the ability to integrate
|
||||
remote tools into the Remote System Explorer. When implementing subsystem APIs, a particular implementation
|
||||
may provide remote function by leveraging DataStore.
|
||||
</p>
|
||||
|
||||
<img src="images/arch.jpg" alt="DataStore and it's relationship to RSE and Eclipse" border="0">
|
||||
|
||||
<p>
|
||||
In an RSE subsystem, the goal of the DataStore is to provide the bridge to tools and resources on the host.
|
||||
To interact with a remote tool, a DataStore client communicates over a network with a DataStore server. Data and
|
||||
commands are transferred between the client and server via the DataStore communication layer. Information
|
||||
that is communicated between each side is kept in memory with the DataStore repository. Both the client and server DataStores
|
||||
have this repository and it is the responsibility of the DataStore communication layer to keep the contents
|
||||
of each of these repositories in sync. All the DataStore data on the server side is replicated to the client and
|
||||
and vice versa.
|
||||
</p>
|
||||
<p>
|
||||
The DataStore framework is generic in the sense that it can be used to facilitate any kind of remote tooling. There are
|
||||
no specialized APIs or artifacts that are geered towards a particular use. How DataStore is used is determined by the
|
||||
tool extensions, <a href="Miners.html">Miners</a>. <a href="Miners.html">Miners</a> are typically either adapters to
|
||||
tools on the host or are tools themselves. These extensions determine the meaning of data used to represent objects,
|
||||
relationships and the commands that can be issued on the represented objects. <a href="Miners.html">Miners</a> shape the
|
||||
DataStore by contributing <a href="Schemas.html">schemas</a> to the pool of information in a DataStore repository.
|
||||
Because the client and server DataStore repositories are synchronized, the DataStore clients
|
||||
have access to the miner <a href="Schemas.html">schemas</a> and, using that information, they are able to communicate with the tools on the host.
|
||||
Because the server has access to those miner <a href="Schemas.html">schemas</a>, each <a href="Miners.html">Miners</a> may also communicate with
|
||||
other <a href="Miners.html">Miners</a> on the host in the same way a client can.
|
||||
</p>
|
||||
<p>
|
||||
A Filesystem miner can shape the DataStore by contributing a <a href="Schemas.html">schema</a> that
|
||||
describes file systems and how they should be interacted with. The <a href="Schemas.html">schema</a> could describe
|
||||
files, folders, properties of files and relationships between them as well as commands for querying folders or renaming files.
|
||||
An RSE subsystem, can then provide browsing capabilities to a remote file system by sending commands
|
||||
via the DataStore client to the Filesystem Miner on the host. Another <a href="Miners.html">miner</a> can
|
||||
contribute its own <a href="Schemas.html">schema</a> or extend the existing Filesystem Miner <a href="Schemas.html">schema</a>
|
||||
to leverage or contribute to the existing file system tool.
|
||||
</p>
|
||||
<p>
|
||||
This guide explains all underlying
|
||||
artifacts and model of the DataStore, its relationship to RSE, and highlights the
|
||||
important APIs available for your use.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,22 +0,0 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2012. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
||||
<LINK REL="STYLESHEET" HREF="book.css" CHARSET="ISO-8859-1" TYPE="text/css">
|
||||
<title>Legal Notices</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h3>
|
||||
<a NAME="Notices"></a>Notices</h3>
|
||||
<p>
|
||||
The material in this guide is Copyright (c) IBM Corporation and others 2000, 2012.
|
||||
</p>
|
||||
<p>
|
||||
<a href="about.html">Terms and conditions regarding the use of this guide.</a>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,27 +0,0 @@
|
|||
-charset "iso-8859-1"
|
||||
-source 1.4
|
||||
-sourcepath "../org.eclipse.dstore.core/src
|
||||
;../org.eclipse.dstore.extra/src"
|
||||
-d reference/api
|
||||
-bootclasspath @rt@
|
||||
-classpath @cp@
|
||||
-breakiterator
|
||||
-use
|
||||
-splitIndex
|
||||
-windowtitle "Remote System Explorer DataStore API Specification"
|
||||
-doctitle "Remote System Explorer DataStore API Specification"
|
||||
-header "<b>Remote System Explorer DataStore</b><br>Release 3.4"
|
||||
-bottom "Copyright (c) IBM Corporation and others 2000, 2012. All Rights Reserved."
|
||||
-link http://docs.oracle.com/javase/1.5.0/docs/api
|
||||
-linkoffline ./../../../org.eclipse.platform.doc.isv/reference/api @javadoc.link.location@/platform/reference/api/
|
||||
-link http://bundles.osgi.org/javadoc/r4
|
||||
|
||||
org.eclipse.dstore.core
|
||||
org.eclipse.dstore.core.client
|
||||
org.eclipse.dstore.core.java
|
||||
org.eclipse.dstore.core.miners
|
||||
org.eclipse.dstore.core.model
|
||||
org.eclipse.dstore.core.server
|
||||
org.eclipse.dstore.core.util
|
||||
org.eclipse.dstore.core.util.ssl
|
||||
org.eclipse.dstore.extra
|
|
@ -1,18 +0,0 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2000, 2011 IBM Corporation and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License 2.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# https://www.eclipse.org/legal/epl-2.0/
|
||||
#
|
||||
# SPDX-License-Identifier: EPL-2.0
|
||||
#
|
||||
# Contributors:
|
||||
# IBM Corporation - initial API and implementation
|
||||
###############################################################################
|
||||
|
||||
# NLS_MESSAGEFORMAT_NONE
|
||||
# NLS_ENCODING=UTF-8
|
||||
|
||||
pluginName=RSE DStore ISV Documentation
|
||||
providerName=Eclipse TM Project
|
|
@ -1 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2005, 2011 IBM Corporation and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License 2.0
which accompanies this distribution, and is available at
https://www.eclipse.org/legal/epl-2.0/
SPDX-License-Identifier: EPL-2.0
Contributors:
IBM Corporation - initial API and implementation
-->
<plugin>
<extension point="org.eclipse.help.toc">
<toc file="toc.xml" primary="true" category="Eclipse.TM"/>
<index path="index/"/>
</extension>
</plugin>
|
|
@ -1,23 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 2018 Red Hat and others.
|
||||
This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
-->
|
||||
|
||||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>org.eclipse.tm.rse.doc</artifactId>
|
||||
<groupId>org.eclipse.tm.rse</groupId>
|
||||
<version>4.5.100-SNAPSHOT</version>
|
||||
</parent>
|
||||
<groupId>org.eclipse.tm</groupId>
|
||||
<artifactId>org.eclipse.dstore.doc.isv</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
</project>
|
|
@ -1 +0,0 @@
|
|||
api
|
|
@ -1 +0,0 @@
|
|||
A nearly empty file used to force the creation of the containing folder.
|
|
@ -1,21 +0,0 @@
|
|||
<!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">
|
||||
<LINK REL="STYLESHEET" HREF="book.css" TYPE="text/css">
|
||||
<title>RSE DataStore developer information</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Using the RSE DataStore for Remote Communications</h1>
|
||||
<div class="p">
|
||||
This section provides information for tool developers who wish to
|
||||
add server-side tooling capabilities. Using the RSE DataStore tooling
|
||||
communication framework, server-side extensions can be written. The Remote System Explorer can be
|
||||
extended to interface the new server-side extensions.
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,42 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?NLS TYPE="org.eclipse.help.toc"?>
|
||||
<!--
|
||||
Copyright (c) 2005, 2010 IBM Corporation and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
|
||||
Contributors:
|
||||
IBM Corporation - initial API and implementation
|
||||
-->
|
||||
|
||||
<toc label="RSE DStore Developer Guide">
|
||||
<topic label="Guide" href="toc.html">
|
||||
<topic label="DataStore Overview" href="guide/overview.html">
|
||||
<topic label="DataStore Artifacts" href="guide/Artifacts.html" />
|
||||
<topic label="DataStore Communications" href="guide/Communications.html" />
|
||||
<topic label="DataElements and the DataStore Model" href="guide/DataElements.html" />
|
||||
<topic label="Memory Management of DataElements" href="guide/MemoryManagement.html" />
|
||||
<topic label="Miners" href="guide/Miners.html" />
|
||||
</topic>
|
||||
<topic label="Extending and Using the DataStore" href="guide/Extending.html">
|
||||
<topic label="Extending the Server-side" href="guide/ServerSide.html" />
|
||||
<topic label="Communicating with the Server-side" href="guide/ClientSide.html" />
|
||||
</topic>
|
||||
<anchor id="guide_additions"/>
|
||||
</topic>
|
||||
<topic label="Reference">
|
||||
<topic label="DataStore API Reference" href="reference/api/overview-summary.html">
|
||||
<topic label="org.eclipse.dstore.core.model" href="reference/api/org/eclipse/dstore/core/model/package-summary.html" />
|
||||
<topic label="org.eclipse.dstore.core.client" href="reference/api/org/eclipse/dstore/core/client/package-summary.html" />
|
||||
<topic label="org.eclipse.dstore.core.server" href="reference/api/org/eclipse/dstore/core/server/package-summary.html" />
|
||||
<topic label="org.eclipse.dstore.core.util" href="reference/api/org/eclipse/dstore/core/util/package-summary.html" />
|
||||
<topic label="org.eclipse.dstore.core.miners" href="reference/api/org/eclipse/dstore/core/miners/package-summary.html" />
|
||||
</topic>
|
||||
<anchor id="reference_additions"/>
|
||||
</topic>
|
||||
<topic label="Legal" href="notices.html"/>
|
||||
</toc>
|
|
@ -1,6 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.rse.launching.JRE_CONTAINER"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
|
@ -1,7 +0,0 @@
|
|||
bin
|
||||
index
|
||||
build.xml
|
||||
javadoc.link.location
|
||||
temp.bin.log
|
||||
temp.convert.txt
|
||||
temp.options.txt
|
|
@ -1,11 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>org.eclipse.rse.doc.isv</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -1,9 +0,0 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: %pluginName
|
||||
Bundle-SymbolicName: org.eclipse.rse.doc.isv; singleton:=true
|
||||
Bundle-Version: 4.5.100.qualifier
|
||||
Bundle-Localization: plugin
|
||||
Eclipse-LazyStart: false
|
||||
Bundle-Vendor: %providerName
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
|
@ -1,29 +0,0 @@
|
|||
Last revised July 27, 2006
|
||||
(This file is for information only; it is not included in the release.)
|
||||
|
||||
See also
|
||||
http://wiki.eclipse.org/How_to_add_things_to_the_Eclipse_doc
|
||||
with the following exceptions:
|
||||
- platformOptions.txt -> options.txt
|
||||
- overview-platform.html -> /reference/misc/overview-rse.html
|
||||
|
||||
To add new plug-ins you need to make changes in several places in
|
||||
this doc plug-in:
|
||||
|
||||
1) options.txt
|
||||
- the plug-in's source folder(s) must be included on the -sourcepath
|
||||
- code of required plug-ins must be added on the -classpath (the JAR(s)for non-JARed plug-ins and <plugin>/@dot for JARed plug-ins
|
||||
- the API package names must be included in the (alphabetical) package list at the end of the file
|
||||
- note that the @sep@ token is replaced during build by the appropriate separator character for the build platform.
|
||||
|
||||
2) buildDoc.xml
|
||||
- add a line in convertSchemaToHtml target to handle a new plug-ins extension point schemas
|
||||
|
||||
Adding new extension points:
|
||||
|
||||
1) reference/extension-points/index.html
|
||||
- add a line for each extension point
|
||||
|
||||
2) topics_Reference.xml
|
||||
- add a line for each extension point
|
||||
- add a line for each API package
|
|
@ -1,29 +0,0 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
|
||||
<title>About</title>
|
||||
</head>
|
||||
<body lang="EN-US">
|
||||
<h2>About This Content</h2>
|
||||
|
||||
<p>June 5, 2007</p>
|
||||
<h3>License</h3>
|
||||
|
||||
<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise
|
||||
indicated below, the Content is provided to you under the terms and conditions of the
|
||||
Eclipse Public License 2.0 ("EPL"). A copy of the EPL is available
|
||||
at <a href="https://www.eclipse.org/legal/epl-2.0/">https://www.eclipse.org/legal/epl-2.0/</a>.
|
||||
For purposes of the EPL, "Program" will mean the Content.</p>
|
||||
|
||||
<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
|
||||
being redistributed by another party ("Redistributor") and different terms and conditions may
|
||||
apply to your use of any object code in the Content. Check the Redistributor's license that was
|
||||
provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
|
||||
indicated below, the terms and conditions of the EPL still apply to any source code in the Content
|
||||
and such source code may be obtained at <a href="http://www.eclipse.org">http://www.eclipse.org</a>.</p>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,112 +0,0 @@
|
|||
P.Code {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0.00pt;
|
||||
margin-top: 0.000000pt;
|
||||
margin-bottom: 0.000000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 15pt;
|
||||
font-size: 10.000000pt;
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
color: #4444CC;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
font-family: "Courier New", Courier, monospace;
|
||||
}
|
||||
H6.CaptionFigColumn {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0.000000pt;
|
||||
margin-top: 3.000000pt;
|
||||
margin-bottom: 11.000000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 0.000000pt;
|
||||
font-size: 9.000000pt;
|
||||
font-weight: bold;
|
||||
font-style: Italic;
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
P.Note {
|
||||
display: block;
|
||||
text-align: left;
|
||||
text-indent: 0pt;
|
||||
margin-top: 19.500000pt;
|
||||
margin-bottom: 19.500000pt;
|
||||
margin-right: 0.000000pt;
|
||||
margin-left: 30pt;
|
||||
font-size: 11.000000pt;
|
||||
font-weight: normal;
|
||||
font-style: Italic;
|
||||
color: #000000;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
EM.UILabel {
|
||||
font-weight: Bold;
|
||||
font-style: normal;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
}
|
||||
EM.CodeName {
|
||||
font-weight: Bold;
|
||||
font-style: normal;
|
||||
text-decoration: none;
|
||||
vertical-align: baseline;
|
||||
text-transform: none;
|
||||
font-family: "Courier New", Courier, monospace;
|
||||
}
|
||||
|
||||
body, html { border: 0px }
|
||||
|
||||
|
||||
/* following font face declarations need to be removed for DBCS */
|
||||
|
||||
body, h1, h2, h3, h4, h5, h6, p, table, td, caption, th, ul, ol, dl, li, dd, dt {font-family: Arial, Helvetica, sans-serif; color: #000000}
|
||||
pre { font-family: "Courier New", Courier, monospace;}
|
||||
|
||||
/* end font face declarations */
|
||||
|
||||
/* following font size declarations should be OK for DBCS */
|
||||
body, h1, h2, h3, h4, h5, h6, p, table, td, caption, th, ul, ol, dl, li, dd, dt {font-size: 10pt; }
|
||||
pre { font-size: 10pt}
|
||||
|
||||
/* end font size declarations */
|
||||
|
||||
body { background: #FFFFFF; margin-bottom: 1em }
|
||||
h1 { font-size: 18pt; margin-top: 5; margin-bottom: 1 }
|
||||
h2 { font-size: 14pt; margin-top: 25; margin-bottom: 3 }
|
||||
h3 { font-size: 11pt; margin-top: 20; margin-bottom: 3 }
|
||||
h4 { font-size: 10pt; margin-top: 20; margin-bottom: 3; font-style: italic }
|
||||
p { margin-top: 10px; margin-bottom: 10px }
|
||||
pre { margin-left: 6; font-size: 9pt; color: #4444CC }
|
||||
a:link { color: #0000FF }
|
||||
a:hover { color: #000080 }
|
||||
a:visited { text-decoration: underline }
|
||||
ul { margin-top: 10px; margin-bottom: 10px; }
|
||||
li { margin-top: 5px; margin-bottom: 5px; }
|
||||
li p { margin-top: 5px; margin-bottom: 5px; }
|
||||
ol { margin-top: 10px; margin-bottom: 10px; }
|
||||
dl { margin-top: 10px; margin-bottom: 10px; }
|
||||
dt { margin-top: 5px; margin-bottom: 5px; font-weight: bold; }
|
||||
dd { margin-top: 5px; margin-bottom: 5px; }
|
||||
strong { font-weight: bold}
|
||||
em { font-style: italic}
|
||||
var { font-style: italic}
|
||||
div.revision { border-left-style: solid; border-left-width: thin;
|
||||
border-left-color: #7B68EE; padding-left:5 }
|
||||
th { font-weight: bold }
|
||||
|
||||
a.command-link {
|
||||
}
|
||||
a.command-link img {
|
||||
border-width: 0px;
|
||||
border-style: none;
|
||||
vertical-align: middle;
|
||||
}
|
|
@ -1,33 +0,0 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2000, 2010 IBM Corporation and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License 2.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# https://www.eclipse.org/legal/epl-2.0/
|
||||
#
|
||||
# SPDX-License-Identifier: EPL-2.0
|
||||
#
|
||||
# Contributors:
|
||||
# IBM Corporation - initial API and implementation
|
||||
# Martin Oberhuber (Wind River) - Declare API provisional
|
||||
# Martin Oberhuber (Wind River) - [314012] Remove provisional API declaration
|
||||
###############################################################################
|
||||
bin.includes = META-INF/,\
|
||||
about.html,\
|
||||
book.css,\
|
||||
notices.html,\
|
||||
plugin.properties,\
|
||||
plugin.xml,\
|
||||
schema.css,\
|
||||
toc.xml,\
|
||||
topics_Guide.xml,\
|
||||
topics_Questions.xml,\
|
||||
topics_Reference.xml,\
|
||||
topics_Samples.xml,\
|
||||
guide/,\
|
||||
icons/,\
|
||||
index/,\
|
||||
questions/,\
|
||||
reference/,\
|
||||
samples/
|
||||
customBuildCallbacks = customBuildCallbacks.xml
|
|
@ -1,172 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 2005, 2011 IBM Corporation and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
|
||||
Contributors:
|
||||
IBM Corporation - initial API and implementation
|
||||
-->
|
||||
<project name="RSE ISV Doc Build" default="all" basedir=".">
|
||||
|
||||
<property name="javadoc.link.location" value="${basedir}/javadoc.link.location"/>
|
||||
|
||||
<target name="init">
|
||||
<available file="${basedir}/index" property="index.present" />
|
||||
<path id="path_bootclasspath">
|
||||
<fileset dir="${java.home}/lib">
|
||||
<include name="*.jar"/>
|
||||
</fileset>
|
||||
</path>
|
||||
<property name="bootclasspath" refid="path_bootclasspath"/>
|
||||
<condition property="safeBaseLocation"
|
||||
value="${baseLocation}"
|
||||
else="${eclipse.home}">
|
||||
<isset property="baseLocation"/>
|
||||
</condition>
|
||||
<delete dir="${javadoc.link.location}" />
|
||||
</target>
|
||||
|
||||
<target name="computeClasspath" unless="javadoc.classpath">
|
||||
<!-- Construct the javadoc classpath and store it in a property. -->
|
||||
<echo level="info" message="Computing classpath ..."/>
|
||||
|
||||
<!-- Add platform dependencies required by your plug-in here.
|
||||
Note that this pattern expects Eclipse to have
|
||||
been installed into the platform directory structure, as is
|
||||
the case during the build. -->
|
||||
<patternset id="platform.classpath.pattern">
|
||||
<include name="**/org.eclipse.core*.jar"/>
|
||||
<include name="**/org.eclipse.core*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.compare*.jar"/>
|
||||
<include name="**/org.eclipse.debug.core*.jar"/>
|
||||
<include name="**/org.eclipse.debug.ui*.jar"/>
|
||||
<include name="**/org.eclipse.help*.jar"/>
|
||||
<include name="**/org.eclipse.search*.jar"/>
|
||||
<include name="**/org.eclipse.swt*.jar"/>
|
||||
<include name="**/org.eclipse.swt*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.ui*.jar"/>
|
||||
<include name="**/org.eclipse.ui*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.update*.jar"/>
|
||||
<include name="**/org.eclipse.update*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.osgi*.jar"/>
|
||||
<include name="**/org.eclipse.osgi*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.equinox*.jar"/>
|
||||
<include name="**/org.eclipse.equinox*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.jface*.jar"/>
|
||||
<include name="**/org.eclipse.jface*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.jsch*.jar"/>
|
||||
<include name="**/org.eclipse.text*.jar"/>
|
||||
<include name="**/org.eclipse.text*/**/*.jar"/>
|
||||
<include name="**/org.eclipse.team*.jar"/>
|
||||
<include name="**/org.eclipse.team*/**/*.jar"/>
|
||||
<include name="**/org.junit*.jar"/>
|
||||
<include name="**/org.junit*/**/*.jar"/>
|
||||
<include name="**/com.ibm.icu*.jar"/>
|
||||
<include name="**/com.jcraft.jsch*.jar"/>
|
||||
</patternset>
|
||||
|
||||
<pathconvert property="javadoc.classpath">
|
||||
<path>
|
||||
<fileset dir="${safeBaseLocation}">
|
||||
<patternset refid="platform.classpath.pattern"/>
|
||||
</fileset>
|
||||
</path>
|
||||
</pathconvert>
|
||||
<echo level="info" message="Done computing classpath."/>
|
||||
<echo level="info" message="Bootclasspath is: ${bootclasspath}"/>
|
||||
<echo level="debug" message="Classpath is: ${javadoc.classpath}"/>
|
||||
</target>
|
||||
|
||||
<target name="extractLinks">
|
||||
<mkdir dir="${javadoc.link.location}"/>
|
||||
|
||||
<patternset id="package.list">
|
||||
<include name="**/package-list"/>
|
||||
</patternset>
|
||||
|
||||
<!-- We only need the package-list files out of these -->
|
||||
<unzip dest="${javadoc.link.location}/platform/">
|
||||
<patternset refid="package.list"/>
|
||||
<fileset dir="${safeBaseLocation}/plugins">
|
||||
<include name="org.eclipse.platform.doc.isv*.jar"/>
|
||||
</fileset>
|
||||
</unzip>
|
||||
</target>
|
||||
|
||||
<target name="all" depends="init" unless="index.present">
|
||||
<antcall target="convertSchemaToHtml" />
|
||||
<antcall target="generateJavadoc" />
|
||||
<antcall target="build.index" />
|
||||
</target>
|
||||
|
||||
<target name="build.index" description="Builds search index for the plug-in: org.eclipse.rse.doc.isv" if="eclipse.running">
|
||||
<help.buildHelpIndex manifest="${basedir}/plugin.xml" destination="${basedir}" />
|
||||
</target>
|
||||
|
||||
<target name="convertSchemaToHtml" if="eclipse.running">
|
||||
<property name="dest" value="reference/extension-points" />
|
||||
<record name="${basedir}/temp.convert.txt" action="start" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.core/plugin.xml" destination="${dest}" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.services/plugin.xml" destination="${dest}" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.subsystems.files.core/plugin.xml" destination="${dest}" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.subsystems.files.ftp/plugin.xml" destination="${dest}" />
|
||||
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.ui/plugin.xml" destination="${dest}" />
|
||||
<record name="${basedir}/temp.convert.txt" action="stop" />
|
||||
</target>
|
||||
|
||||
<target name="getJavadocPath">
|
||||
<available file="${java.home}/../bin/javadoc.exe" property="javadoc" value="${java.home}/../bin/javadoc.exe" />
|
||||
<available file="${java.home}/../bin/javadoc" property="javadoc" value="${java.home}/../bin/javadoc" />
|
||||
<available file="/usr/bin/javadoc" property="javadoc" value="/usr/bin/javadoc" />
|
||||
<available file="/shared/tools/tm/ibm-java2-ppc64-50/bin/javadoc" property="javadoc" value="/shared/tools/tm/ibm-java2-ppc64-50/bin/javadoc" />
|
||||
</target>
|
||||
|
||||
<target name="generateJavadoc" depends="getJavadocPath,extractLinks,computeClasspath" if="javadoc">
|
||||
<property name="optionsFile" value="temp.options.txt" />
|
||||
<copy file="options.txt" tofile="${optionsFile}" overwrite="true" />
|
||||
|
||||
<condition property="argsListDelimiter" value=":">
|
||||
<os family="unix" />
|
||||
</condition>
|
||||
<condition property="argsListDelimiter" value=";">
|
||||
<os family="windows" />
|
||||
</condition>
|
||||
|
||||
<replaceregexp file="${basedir}/${optionsFile}" flags="g" match="(\r\n?|\n);" replace="${argsListDelimiter}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@rt@" value="${bootclasspath}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@cp@" value="${javadoc.classpath}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@baseLocation@" value="${safeBaseLocation}" />
|
||||
<replace file="${basedir}/${optionsFile}" token="@javadoc.link.location@" value="${javadoc.link.location}" />
|
||||
|
||||
<!--scrub isv plugin directories of any preexisting api doc content-->
|
||||
<delete dir="reference/api" />
|
||||
<mkdir dir="reference/api" />
|
||||
|
||||
<echo message="sep = ${argsListDelimiter}"/>
|
||||
<echo message="javadoc = ${javadoc}"/>
|
||||
<exec dir="." executable="${javadoc}" output="temp.bin.log" resultproperty="javadocResult">
|
||||
<arg line="@${basedir}/${optionsFile} -J-Xmx1000M" />
|
||||
</exec>
|
||||
<echo message="javadoc result = ${javadocResult}"/>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -1,170 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!--
|
||||
Copyright (c) 2005, 2007 IBM Corporation and others.
|
||||
All rights reserved. This program and the accompanying materials
|
||||
are made available under the terms of the Eclipse Public License 2.0
|
||||
which accompanies this distribution, and is available at
|
||||
https://www.eclipse.org/legal/epl-2.0/
|
||||
|
||||
SPDX-License-Identifier: EPL-2.0
|
||||
|
||||
Contributors:
|
||||
IBM Corporation - initial API and implementation
|
||||
-->
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Custom targets called from a project's generated build.xml -->
|
||||
<!-- Set customBuildCallbacks=<path/to/this/file> in your build.properties.-->
|
||||
<!-- ===================================================================== -->
|
||||
<project name="Build specific targets and properties" default="noDefault">
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Default target -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="noDefault">
|
||||
<echo message="This file must be called with explicit targets" />
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target build.jars -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.build.jars">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target build.jars -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.build.jars">
|
||||
<ant antfile="buildDoc.xml" />
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target build.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.build.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target build.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- build.result.folder - folder to contain the build results -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.build.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the compilation target <name> -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- source.foldern : n = 1 ... N, the source folders -->
|
||||
<!-- target.folder : where the results of the compilation go -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="pre.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after compilation but before jaring -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- source.foldern : n = 1 ... N, the source folders -->
|
||||
<!-- target.folder : where the results of the compilation go -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="post.compile.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the compilation target <name> -->
|
||||
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- jar.location - the location of the compilation results -->
|
||||
<!-- <name>.classpath : name = name of the compilation target. A -->
|
||||
<!-- reference to the classpath structure. -->
|
||||
<!-- ===================================================================== -->
|
||||
<!--
|
||||
<target name="post.compileTarget.jar">
|
||||
</target>
|
||||
-->
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.bin.parts -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- base.dir - root of the project -->
|
||||
<!-- build.result.folder - folder containing the build results -->
|
||||
<!-- target.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.bin.parts">
|
||||
|
||||
</target>
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.bin.parts -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- base.dir - root of the project -->
|
||||
<!-- build.result.folder - folder containing the build results -->
|
||||
<!-- target.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.bin.parts">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.sources -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.sources">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target gather.logs -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.gather.logs">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target gather.logs -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.gather.logs">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do before the target clean -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- destination.temp.folder - destination folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="pre.clean">
|
||||
</target>
|
||||
|
||||
<!-- ===================================================================== -->
|
||||
<!-- Steps to do after the target clean -->
|
||||
<!-- Available parameters : -->
|
||||
<!-- plugin.destination - final destination of the build -->
|
||||
<!-- build.result.folder - results of the compilation -->
|
||||
<!-- temp.folder - temporary folder -->
|
||||
<!-- ===================================================================== -->
|
||||
<target name="post.clean">
|
||||
</target>
|
||||
</project>
|
|
@ -1,231 +0,0 @@
|
|||
<!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, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
<title>RSE Artifacts</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Remote System Explorer Artifacts</h1>
|
||||
<p>With the RSE, you can create and manipulate the following artifacts, which we introduce here:</p>
|
||||
<ul>
|
||||
<li><A href="#Hosts">Hosts</A></li>
|
||||
<li><A href="#profiles">Profiles</A></li>
|
||||
<li><A href="#subsystems">Subsystems, created from subsystem configurations</A></li>
|
||||
<li><A href="#connectorservices">Connector Services, managed by connector service managers</A></li>
|
||||
<li><A href="#filters">Filters and filter strings</A></li>
|
||||
<li><A href="#filterpools">Filter pools</A></li>
|
||||
<li><A href="#Preferences">Preferences</A></li>
|
||||
<li><A href="#Registry">System Registry</A></li>
|
||||
</ul>
|
||||
<p>All the classes and interfaces mentioned here are defined in the <samp>org.eclipse.rse.core</samp> plugin.
|
||||
|
||||
<h2><A name="Hosts">Hosts</A></h2>
|
||||
<p>
|
||||
The RSE's <A href="view_RS.gif">Remote Systems view</A> shows all existing <b>Hosts</b> to remote systems.
|
||||
Hosts are objects that are persisted, containing the information needed to access a particular remote host.
|
||||
The view contains a prompt to create new Hosts, and pop-up menu actions to rename, copy, delete, and reorder existing Hosts.
|
||||
</p>
|
||||
<p>
|
||||
Hosts contain attributes, or data, that is saved between sessions of the workbench. These attributes are
|
||||
the host name, the remote system's host name and system type, an optional description, and a user Id that is
|
||||
used by default by each subordinate subsystem, at host time.
|
||||
Underneath, all Hosts are stored in profiles by an registered persistence provider.
|
||||
</p>
|
||||
|
||||
<h2><A name="profiles">Profiles</A></h2>
|
||||
<p>
|
||||
To facilitate sharing Hosts are owned by <b>Profiles</b>.
|
||||
In 1.0 these were simply folders in the RemoteSystemsConnections
|
||||
project. With the introduction of persistence providers in 2.0, profiles
|
||||
can now be persisted in multiple forms - including the 1.0 scheme.
|
||||
It is our intention to have RSE allow for the sharing of profiles by exporting to and importing from
|
||||
the file system or from projects in a future release.
|
||||
</p>
|
||||
<p>
|
||||
Internally profiles are realized as
|
||||
SystemProfile objects, managed by the SystemProfileManager.
|
||||
For each profile there is also a SystemHostPool object
|
||||
created to manage the Hosts within that profile. There are menu actions for the
|
||||
user to create and manage profiles. The collective of all Hosts of all <b><I>active</I> profiles</b> are shown in the
|
||||
Remote Systems view,
|
||||
and the user can easily decide which profiles are active using the <A href="preference_activeProfiles.gif">local pulldown menu</A> of the Remote Systems view.
|
||||
The list of profiles currently active is stored locally on each user's workstation, and not shared by teams.
|
||||
By default, there exists a profile named <code>Team</code>, and a profile with a name unique to this user. When the first
|
||||
host is created the user is asked to supply this unique name, which defaults to the hostname of their
|
||||
workstation. Whenever a new host is created, the user is prompted for an active profile to contain the new
|
||||
host. Both default profiles are active initially, so all Hosts from each are shown. There is a preferences
|
||||
setting to show the host names qualified by their profile name.
|
||||
</p>
|
||||
<!-- TODO
|
||||
<p>
|
||||
After synchronizing the RemoteSystemsConnections
|
||||
project with a team repository, using the RSE <A href="plugin/view_Team.gif">team view</A>, all profiles of all members of
|
||||
the team will exist in the user's workspace, and hence
|
||||
all the Hosts created by all the team members. However, only the two default profiles are active, so the Hosts
|
||||
in the other profiles are not seen unless the user explicitly makes another profile active. This design allows
|
||||
for:
|
||||
</p>
|
||||
<ol>
|
||||
<li>Team-shared Hosts (created in the Team profile or any profile all team members make active)
|
||||
<li>User-private Hosts (created in their own profile or any profile not active by default)
|
||||
<li>User-roaming, whereby a user uses a different workstation than usual,
|
||||
and then synchronizes with the team repository and sets their profile to be active.
|
||||
</ol>
|
||||
-->
|
||||
<!-- TODO rework
|
||||
As an aside, user IDs and passwords are not shared with the team repository, but rather stored only locally per
|
||||
workstation.
|
||||
-->
|
||||
|
||||
<h2><A name="subsystems">Subsystems and subsystem configurations</A></h2>
|
||||
<p>
|
||||
When you expand a host, any tools registered with the Remote System Explorer are shown under the host.
|
||||
These tools are referred to as <b>subsystems</b>. The tool provider registers a <b>subsystem configuration</b>
|
||||
class via an RSE <A href="plugin/subsystem.html">extension point</A>, and whenever a new host is created, the configuration
|
||||
is asked to create a new subsystem object for that host. This subsystem is responsible for communicating with the remote host, and
|
||||
exposing artifacts and actions for working with remote resources. The subsystem configuration can elect not to
|
||||
supply a subsystem for a given host if it does not support the system type of that host
|
||||
</p>
|
||||
<p>
|
||||
RSE supplies two subsystem configurations that supply common subsystems for all Hosts:
|
||||
<ol>
|
||||
<li>Files. The subsystems created by this factory access the folders and files of the remote system,
|
||||
and allow users to explore and manipulate those folders and files. Editing support for remote source files is also included. For programmers, the subsystems also supply common APIs and user interface actions, wizards,
|
||||
dialogs, and widgets for easy access to the remote file system for a given host. These APIs are
|
||||
typically used when coding actions that appear in the pop-up menu for selected remote objects, but might
|
||||
also be of value when writing any view, editor, or action that needs access to a remote file system.
|
||||
<li>Commands. The subsystems created by this factory access the command shell of the remote system and
|
||||
allow users to predefine commands, and subsequently run them remotely. The commands subsystems are hidden
|
||||
subsystems, not shown when you expand the host. However, they are used by any code needing to run
|
||||
remote commands. There is also a Remote Shell view supplied that logs all commands and allows users to
|
||||
enter a command to be run remotely. The commands all execute within the same shell, and users
|
||||
can launch additional shells for the same host.
|
||||
</ol>
|
||||
<p>
|
||||
Each subsystem can have a unique user ID, which if not set is inherited from its host,
|
||||
which in turn if not set is inherited from the
|
||||
user ID preferences setting for the appropriate system type.
|
||||
</p>
|
||||
<h2><A name="systems">Connector services and their managers</A></h2>
|
||||
<p>While not seen by the user, subsystem objects are required to return a <b>connectorservice</b> object via the
|
||||
<A href="../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html#getConnectorService()">getConnectorService()</A> method.
|
||||
A connectorService object is an object implementing the <A href="../reference/api/org/eclipse/rse/core/subsystems/IConnectorService.html">IConnectorService</A> interface.
|
||||
A connectorService object manages the live host to the remote system, and supports
|
||||
lifecycle methods for that host such as
|
||||
<A href="../reference/api/org/eclipse/rse/core/subsystems/IConnectorService.html#connect(org.eclipse.core.runtime.IProgressMonitor)">connect</A>,
|
||||
<A href="../reference/api/org/eclipse/rse/core/subsystems/IConnectorService.html#disconnect()">disconnect</A>, and
|
||||
<A href="../reference/api/org/eclipse/rse/core/subsystems/IConnectorService.html#isConnected()">isConnected</A>.
|
||||
The communication layer for that host is entirely the programmer's responsibility, and might use sockets, JDBC, HTTP or
|
||||
SOAP. It is up the provider of the subsystem factory to author their own communication layer; the framework
|
||||
only dictates the handful of methods in IConnectorService, that the RSE UI depends upon. The framework supplies a base
|
||||
system class that is easily extended.
|
||||
</p>
|
||||
<p>It may be the case that multiple subsystems, each from a different subsystem configuration, share the same live
|
||||
host for a given host object. To enable this, the framework supplies a base
|
||||
<b>connector service manager</b> <A href="../reference/api/org/eclipse/rse/core/subsystems/AbstractConnectorServiceManager.html">class</A>
|
||||
that can be used to manage a single shared connector service object across multiple subsystems. It uses a hashtable to store and
|
||||
return the connector service objects, keyed by a subsystem interface that all subsystems sharing the same connector service object
|
||||
are to implement. The subclass of the base connector service manager class supplies that interface. Further, the subclass
|
||||
must also implement the method for instantiating new instances of the connector service class, when no instance is found
|
||||
in the hashtable.
|
||||
</p>
|
||||
<p>
|
||||
It is possible to author a subsystem configuration whose subsystems simply use the same connector service object as that used by
|
||||
the RSE-supplied subsystems. You might do this if the subsystem configuration uses only the RSE-supplied APIs for
|
||||
accessing remote objects, in which case there is no need for a unique communication layer. By sharing the
|
||||
same connector service object, it prevents the user from being prompted to signon multiple times. To do this, simply access
|
||||
any RSE-supplied subsystem for a given host, and ask for its
|
||||
<A href="../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html#getConnectorServiceManager()">connector service manager</A>
|
||||
in your own subsystem's <A href="../reference/api/org/eclipse/rse/core/subsystems/AbstractConnectorService.html#getConnectorServiceManager()">getConnectorServiceManager</A> method.
|
||||
</p>
|
||||
|
||||
<h2><A name="filters">Filters</A></h2>
|
||||
<p>
|
||||
When a subsystem is expanded, users usually see <b>filters</b>. Since subsystems typically list remote artifacts,
|
||||
it is typical that a mechanism is needed to allow users to define which artifacts they wish to see, with some
|
||||
form of filtering criteria. Filters are this mechanism. The filter support is fully supplied by the RSE framework.
|
||||
A filter is simply a <A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilter.html">ISystemFilter</A>
|
||||
object containing a name and a collection of <b>filter strings</b>. Filter strings are just strings, which
|
||||
the subsystem is required to interpret. When a user expands a filter, the owning subsystem is asked to resolve
|
||||
the filter strings within the filter. The subsystem typically interprets each filter string as some form of
|
||||
filtering pattern, and returns a list of remote artifacts matching one or more of the filter string patterns in
|
||||
the filter. For example, file subsystems expect each filter string to represent a folder, and a file name pattern. Then, all files in the folder, matching the name pattern, are returned. The subsystem supplies the user interface the
|
||||
you use to create and change filter strings, so it is responsible for defining what the filter strings
|
||||
look like and for subsequently resolving those filter strings on a filter expansion. A default user interface for
|
||||
the filter string prompt is supplied, but it is a simple entry field.
|
||||
</p>
|
||||
<p>
|
||||
It is possible to author a subsystem that does not support filters, if this is desired.
|
||||
</p>
|
||||
|
||||
<h2><A name="filterpools">Filter Pools</A></h2>
|
||||
<p>
|
||||
Subsystems do not actually "own" filters. Since each host has unique subsystems, if each subsystem owned its
|
||||
own filters then filters could not be shared across Hosts, which is sometimes desirable. Instead, filters are
|
||||
actually contained within <b>filter pools</b>. Filter pools are simply
|
||||
<A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPool.html">ISystemFilterPool</A>
|
||||
objects which have a name and a collection of filters.
|
||||
Filter pools are owned by subsystem configurations, per profile. That is, each subsystem configuration will contain filter pools
|
||||
scoped by profile. Each such configuration plus profile grouping is known internally as a
|
||||
<A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolManager.html">filter pool manager</A>.
|
||||
Subsystems contain <A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolReference.html">references</A>
|
||||
to filter pools. By default, each subsystem configuration automatically creates one filter pool
|
||||
for each profile, named the "xxx Filter Pool", where "xxx" is the name of the profile. Subsystems contain references to
|
||||
filter pools, so that as the filters in the pool are created, changed, deleted or re-ordered, those changes are automatically
|
||||
reflected in every subsystem (and hence host) that references that filter pool. By default, subsystems are given a
|
||||
reference to the default filter pool in their host's profile (for their parent subsystem configuration, so file filters
|
||||
are not used in command subsystems, for example).
|
||||
</p>
|
||||
<p>
|
||||
By default, users do not see filter pools. Instead, filters are created in the default filter pool referenced by this subsystem.
|
||||
As a result, users will see the same list of filters for every host. However, users can use a preference setting to see
|
||||
filter pools. In this case, when a subsystem is expanded, the users see the filter pools referenced by this subsystem.
|
||||
Only then when a filter pool is expanded will the user see the filters within that filter pool. In this mode, users also
|
||||
see new actions to create filter pools and to add and remove references to filter pools within a subsystem. Whenever filters
|
||||
are changed by the user, this change is reflected in all subsystems that reference the parent filter pool. This design
|
||||
of filter pools owned by profiles, and subsystems that reference filter pools, facilitates filter sharing:
|
||||
<ol>
|
||||
<li>Users can share filters across Hosts, by adding references to their parent filter pool in various subsystems.<li>Users can have filters unique to a host, by placing them in a filter pool not referenced by other subsystems.
|
||||
<li>Users can have both shared and host-unique filters in a single host, by having both shared and private references
|
||||
to filter pools.<li>Teams can share filters by asking each user to add a reference to the same filter pool in their Hosts. For example,
|
||||
this is the default case for the default filter pool.
|
||||
<li>Users can create filters that are not shared by the team, by creating their own filter pools and not asking others to
|
||||
reference it.
|
||||
</ol>
|
||||
</p>
|
||||
<h2><A name="preferences">Preferences</A></h2>
|
||||
<p>
|
||||
Many of the default characteristics of the Remote System Explorer view and perspective are configurable by each user
|
||||
by way of the <A href="preferences.gif">Remote Systems node</A> of the <b>Preferences</b> window, accessible from the Window pull-down of the main menu.
|
||||
Furthermore, many of these preferences are directly accessible from the <A
|
||||
href="view_pulldown.gif">pull-down menu of the title bar for the Remote
|
||||
Systems view</A>. These preferences, like all preferences, are unique to each user and not shared by the team, although they can
|
||||
be exported and imported.
|
||||
</p>
|
||||
|
||||
<h2><A name="Registry">System Registry</A></h2>
|
||||
<p>The programmatic front door to all the artifacts in the RSE is the
|
||||
<b>System Registry</b>, which is an object implementing
|
||||
<A href="../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html">ISystemRegistry</A>.
|
||||
This is a singleton object that you
|
||||
can access by calling the static method
|
||||
<A href="../reference/api/org/eclipse/rse/core/model/SystemStartHere.html#getSystemRegistry()">getSystemRegistry()</A> in the
|
||||
<A href="../reference/api/org/eclipse/rse/core/model/SystemStartHere.html">SystemStartHere</A>
|
||||
class in the <samp>org.eclipse.rse.core</samp> plugin.
|
||||
</p>
|
||||
|
||||
<p>A UI-enabled extension of the system registry is available through the
|
||||
<A href="../reference/api/org/eclipse/rse/ui/model/ISystemRegistryUI.html">ISystemRegistryUI</A> interface.
|
||||
This interface is available by calling the static method
|
||||
<A href="../reference/api/org/eclipse/rse/ui/RSEUIPlugin.html#getTheSystemRegistryUI()">getTheSystemRegistryUI()</A> in the
|
||||
<A href="../reference/api/org/eclipse/rse/ui/RSEUIPlugin.html">RSEUIPlugin</A>
|
||||
class in the <samp>org.eclipse.rse.ui</samp> plugin.
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,84 +0,0 @@
|
|||
<!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, 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >
|
||||
<!-- David Dykstal (IBM) - [] remove unintended duplication from the list of extension points -->
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
<title>Remote System Explorer Extension Points</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Remote System Explorer Extension Points</h1>
|
||||
|
||||
<p>
|
||||
This product is built on the Eclipse platform
|
||||
(<A href="http://www.eclipse.org">www.eclipse.org</A>)
|
||||
and so it offers all the
|
||||
capabilities of Eclipse. This includes the ability to create new Eclipse plug-ins to contribute
|
||||
additional functions to Eclipse. You can write plug-ins using Java, using Eclipse itself,
|
||||
with the Plug-in Development Environment (PDE) perspective. Plug-ins contain a file named <code>plugin.xml</code> that
|
||||
registers their functions. All such functions are created by use of <b>extension points</b>.
|
||||
These are either supplied by Eclipse or by other plug-ins. The plugin.xml file describes which extension
|
||||
points are being exploited by each plug-in, and for each identifies the Java class that supplies the
|
||||
additional functions. Each extension point identifies a Java interface (or base class) that
|
||||
classes exploiting the extension point must implement (or extend).
|
||||
</p>
|
||||
<p>
|
||||
There are many Eclipse-supplied extension points described in
|
||||
this documentation. In addition to the Eclipse extension points, there
|
||||
are unique Remote System Explorer extension points that enable you to contribute property pages and
|
||||
pop-up menu actions to remote objects within the Remote Systems view, among other things. The base Eclipse extension
|
||||
points are not sufficient for these, as they do not allow scoping of those property pages and
|
||||
actions such that they only appear for certain remote objects meeting specific filtering criteria.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Listed below are the most common extension points defined by the Remote System Explorer.
|
||||
They are further described in the reference section along with others that are more special-purpose.
|
||||
The ones listed here are specifically designed to make
|
||||
it easy to contribute functions to the pop-up menus of remote objects displayed in the Remote
|
||||
Systems view. These extension points are defined by the
|
||||
<strong>org.eclipse.rse.core</strong> and <strong>org.eclipse.rse.ui</strong> plugins.
|
||||
</p>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Extension Point</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><A href="plugin/systemtype.html">org.eclipse.rse.core.systemTypes</A></TD>
|
||||
<TD>For defining new system types that show up in the New Connection wizard.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><A href="plugin/subsystem.html">org.eclipse.rse.core.subsystemConfigurations</A></TD>
|
||||
<TD>For defining new subsystems that appear when a connection is expanded.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><A href="../reference/extension-points/org_eclipse_rse_services_archivehandlers.html">org.eclipse.rse.services.archivehandlers</A></TD>
|
||||
<TD>For supporting additional archive file types, such as is done today for zip, jar and tar files. This adds support for expanding the archives and supporting all the usual actions on the contents.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><A href="plugin/popup.html">org.eclipse.ui.popupMenus</A></TD>
|
||||
<TD>For defining actions, which appear in the pop-up menu of remote objects
|
||||
listed in the Remote Systems view.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><A href="plugin/propertypage.html">org.eclipse.ui.propertyPages</A></TD>
|
||||
<TD>For defining property pages, which appear in the Properties dialog when
|
||||
users select the Properties action from the pop-up menu of remote
|
||||
objects listed in the Remote Systems view.</TD>
|
||||
</TR>
|
||||
<!-- TODODeferred after RSE 1.0
|
||||
<TR>
|
||||
<TD><A href="../reference/extension-points/org_eclipse_rse_ui_compile.html">org.eclipse.rse.ui.<b>compile</b></A></TD>
|
||||
<TD>For contributing compile commands to the Compile menus and Work With Compile Commands dialog.</TD>
|
||||
</TR>
|
||||
-->
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
</body>
|
||||
</html>
|
|
@ -1,56 +0,0 @@
|
|||
<!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." >
|
||||
<title>RSE Model</title>
|
||||
<link rel="stylesheet" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Remote System Explorer Model</h1>
|
||||
<p>The underlying containment model for the RSE static artifacts is shown here.</p>
|
||||
<p><img ref="ModelRSE.gif" src="ModelRSE.png"></p>
|
||||
<p>At runtime, the model takes a slightly different form:</p>
|
||||
<ul>
|
||||
<li>
|
||||
<A href="../reference/api/org/eclipse/rse/core/model/ISystemProfile.html">Profiles</A> are managed by a
|
||||
<A href="../reference/api/org/eclipse/rse/core/model/ISystemProfileManager.html">profile manager</A>, and contain:
|
||||
</li>
|
||||
<ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/model/ISystemHostPool.html">Host Pools</A>, one per profile, which contain</li>
|
||||
<ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/model/IHost.html">Hosts</A></li>
|
||||
</ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPool.html">Filter pools</A>, keyed by Subsystem Configuration, and managed by a <A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolManager.html">filter pool manager</A>
|
||||
which contain</li>
|
||||
<ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilter.html">Filters</A>, which contain</li>
|
||||
<ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterString.html">Filter strings</A></li>
|
||||
</ul>
|
||||
</ul>
|
||||
<!--
|
||||
<li><A href="../reference/api/org/eclipse/rse/ui/uda/ISystemUDActionElement.html">User actions</A>, keyed by Subsystem Configuration, which contain</li>
|
||||
<ul>
|
||||
<li><i>References</i> to <A href="../reference/api/org/eclipse/rse/ui/uda/ISystemUDTypeElement.html">named types</A></li>
|
||||
</ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/ui/compile/SystemCompileCommand.html">Compile commands</A></li>
|
||||
-->
|
||||
</ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/subsystems/SubSystemConfiguration.html">Subsystem Configurations</A> contain:</li>
|
||||
<ul>
|
||||
<li><A href="../reference/api/org/eclipse/rse/core/subsystems/SubSystem.html">Subsystems</A>, keyed by host, which contain</li>
|
||||
<ul>
|
||||
<li><i><A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolReference.html">References</A></i>
|
||||
to <A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPool.html">filter pools</A>, which are managed by <A href="../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolManager.html">filter pool managers</A></li>
|
||||
</ul>
|
||||
<!--
|
||||
<li><A href="../reference/api/org/eclipse/rse/ui/uda/SystemUDTypeElement.html">Named types</A></li>
|
||||
-->
|
||||
</ul>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 17 KiB |
|
@ -1,89 +0,0 @@
|
|||
<!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>RSE Actions API</title>
|
||||
<STYLE type="text/css">
|
||||
<!--
|
||||
TH {
|
||||
background-color: #e5e5e5
|
||||
}
|
||||
-->
|
||||
</STYLE>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Actions API</h1>
|
||||
<p>In Eclipse, we typically launch our dialogs and wizards and menu items from an action, which is
|
||||
a class that implements the JFace <samp>IAction</samp> interface. The Remote System Explorer offers classes to
|
||||
help simplify the creation of action classes, especially when used together with the RSE classes for
|
||||
<a href="../dialogs/uiDialogsAPI.html">dialogs</a> and <a href="../wizards/uiWizardsAPI.html">wizards</a>.
|
||||
</p>
|
||||
<p>There are two ways the Remote System Explorer API set can help you when it comes to actions:
|
||||
<ol>
|
||||
<li>A set of base action classes from which to base your own action classes.
|
||||
<li>A set of re-usable actions for specific requirements.
|
||||
</ol>
|
||||
</p>
|
||||
|
||||
<h2>RSE-Supplied Base Classes for Actions</h2>
|
||||
<p>Here are the primary base classes the RSE supplies for actions, all of which are found in the
|
||||
package <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/package-summary.html">org.eclipse.rse.ui.actions</A></samp>
|
||||
in the plugin <samp>org.eclipse.rse.ui</samp>:</p>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Class</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html">SystemBaseAction</A></samp></TD>
|
||||
<TD>This is the base action class for the other classes, and is only used directly for actions that do not
|
||||
result in a dialog or wizard being presented to the user. It extends the JFace <samp>Action</samp> class,
|
||||
adding to it support for properties such as the current shell and viewer and selection, as well as
|
||||
overridable methods for easily enabling/disabling the action based on the selection, and a method for
|
||||
setting the context help for the action. There are many other useful methods, such
|
||||
as <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html#allowOnMultipleSelection(boolean)">allowOnMultipleSelection(boolean)</A></samp>
|
||||
and <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html#setContextMenuGroup(java.lang.String)">setContextMenuGroup(String)</A></samp>, to
|
||||
simplify when the action is enabled and where it appears in a popup menu.
|
||||
</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseSubMenuAction.html">SystemBaseSubMenuAction</A></samp></TD>
|
||||
<TD>This base action class extends <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html">SystemBaseAction</A></samp>, and is used as the parent class when
|
||||
for popup menu actions that are to cascade. A cascading menu is itself another menu, really, containing actions just like the primary
|
||||
menu does. So, to create a cascading menu action, you simply subclass this class and override the method
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseSubMenuAction.html#populateSubMenu(org.eclipse.jface.action.IMenuManager)">populateSubMenu</A></samp>, where
|
||||
you add all the actions to show in this cascading menu. And yes, one or more of those can themselves be cascading. The RSE views will
|
||||
automatically call the method <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseSubMenuAction.html#getSubMenu()">getSubMenu</A></samp> when populating the initial popup menu, but your own views will need to do this.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseDialogAction.html">SystemBaseDialogAction</A></samp></TD>
|
||||
<TD>This base action class extends <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html">SystemBaseAction</A></samp>, and is used when the action presents the
|
||||
user with a dialog, preferably a dialog that extends the RSE
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html">SystemPromptDialog</A></samp> class. To use this class, subclass it and override the methods </TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseWizardAction.html">SystemBaseWizardAction</A></samp></TD>
|
||||
<TD>This base action class extends <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseAction.html">SystemBaseAction</A></samp>, and is used when the action presents the
|
||||
user with a wizard, preferably a wizard that extends the RSE <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html">AbstractSystemWizard</A></samp> class.</TD>
|
||||
</TR>
|
||||
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
|
||||
<h2>Actions Pre-Supplied by RSE</h2>
|
||||
<p>You may find some of the actions supplied by the RSE to be immediately re-usable in your own code, saving some
|
||||
development and test effort.
|
||||
All these actions can be found in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/package-summary.html">org.eclipse.rse.ui.actions</A></samp>.
|
||||
Further, you can find many useful actions related to the selection of remote files or folders, in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/files/ui/actions/package-summary.html">org.eclipse.rse.files.ui.actions</A></samp>.
|
||||
</p>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 7.9 KiB |
Before Width: | Height: | Size: 4.5 KiB |
|
@ -1,265 +0,0 @@
|
|||
<!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" CHARSET="UTF-8" TYPE="text/css">
|
||||
<title>RSE Validator Sample One</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Dialog Sample</h1>
|
||||
<p>This is an example of a sample<A href="sampleDlg.gif"> dialog</A> written on top of the RSE base dialog class, and with
|
||||
typical full error checking.
|
||||
<pre>
|
||||
|
||||
package org.eclipse.rse.samples.ui.frameworks.dialogs;
|
||||
|
||||
import org.eclipse.swt.widgets.*;
|
||||
import org.eclipse.swt.events.*;
|
||||
|
||||
import org.eclipse.rse.samples.*;
|
||||
|
||||
import org.eclipse.rse.ui.dialogs.SystemPromptDialog;
|
||||
import org.eclipse.rse.ui.*;
|
||||
import org.eclipse.rse.ui.widgets.*;
|
||||
import org.eclipse.rse.ui.messages.*;
|
||||
import org.eclipse.rse.ui.validators.*;
|
||||
|
||||
/**
|
||||
* <I>A simple example of using the SystemPromptDialog class as the basis for a new dialog</I>.
|
||||
*/
|
||||
public class <B>SampleDialog</B> extends SystemPromptDialog
|
||||
{
|
||||
// <I>gui widgets</I>
|
||||
private SystemHistoryCombo namePrompt;
|
||||
private Text yearPrompt, monthPrompt, dayPrompt;
|
||||
// <I>input</I>
|
||||
private SampleCustomer inpCust;
|
||||
// <I>validators</I>
|
||||
private ISystemValidator nameValidator, yearValidator, monthValidator, dayValidator;
|
||||
// <I>message</I>
|
||||
private SystemMessage errorMessage;
|
||||
|
||||
/**
|
||||
* <I>Constructor for SampleDialog</I>.
|
||||
*/
|
||||
public <B>SampleDialog</B>(Shell shell)
|
||||
{
|
||||
super(shell, SamplesPlugin.getString("org.eclipse.rse.samples.ui.dialogs.dialog1.title"));
|
||||
setHelp(SamplesPlugin.HELPPREFIX + "dlg11000");
|
||||
nameValidator = new <A href="../validators/validatorSample1.html">SampleNameValidator</A>();
|
||||
yearValidator = new <A href="../validators/validatorSample2.html">SampleBirthYearValidator</A>();
|
||||
monthValidator = new <A href="../validators/validatorSample3.html">SampleBirthMonthValidator</A>();
|
||||
dayValidator = new <A href="../validators/validatorSample4.html">SampleBirthDayValidator</A>();
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Required parent override.</I>
|
||||
* <I>This is where we populate the client area</I>
|
||||
*/
|
||||
protected Control <B>createInner</B>(Composite parent)
|
||||
{
|
||||
int nbrColumns = 2;
|
||||
Composite parentComposite = SystemWidgetHelpers.createComposite(parent, nbrColumns);
|
||||
|
||||
// <I>add gui widgets</I>...
|
||||
SystemWidgetHelpers.createLabel(parentComposite, SamplesPlugin.getResourceBundle(), "org.eclipse.rse.samples.ui.dialogs.dialog1.name.");
|
||||
boolean readonly = false;
|
||||
namePrompt = SystemWidgetHelpers.createHistoryCombo(parentComposite, null, "name.history.key", readonly,
|
||||
SamplesPlugin.getResourceBundle(), "org.eclipse.rse.samples.ui.dialogs.dialog1.name.tooltip");
|
||||
|
||||
addSeparatorLine(parentComposite, nbrColumns);
|
||||
boolean wantBorder = false;
|
||||
SystemWidgetHelpers.createLabel(parentComposite, SamplesPlugin.getResourceBundle(),
|
||||
"org.eclipse.rse.samples.ui.dialogs.dialog1.birthday.verbiage.", nbrColumns, wantBorder);
|
||||
|
||||
yearPrompt = SystemWidgetHelpers.createLabeledTextField(parentComposite, null,
|
||||
SamplesPlugin.getResourceBundle(), "org.eclipse.rse.samples.ui.dialogs.dialog1.birthday.year.");
|
||||
monthPrompt = SystemWidgetHelpers.createLabeledTextField(parentComposite, null,
|
||||
SamplesPlugin.getResourceBundle(), "org.eclipse.rse.samples.ui.dialogs.dialog1.birthday.month.");
|
||||
dayPrompt = SystemWidgetHelpers.createLabeledTextField(parentComposite, null,
|
||||
SamplesPlugin.getResourceBundle(), "org.eclipse.rse.samples.ui.dialogs.dialog1.birthday.day.");
|
||||
|
||||
// <I>if given an existing object, prefill it</I>...
|
||||
inpCust = (SampleCustomer)getInputObject();
|
||||
if (inpCust != null)
|
||||
{
|
||||
namePrompt.setText(inpCust.getName());
|
||||
yearPrompt.setText(inpCust.getYear());
|
||||
monthPrompt.setText(inpCust.getMonth());
|
||||
dayPrompt.setText(inpCust.getDay());
|
||||
}
|
||||
|
||||
|
||||
// <I>add modify listeners</I>...
|
||||
namePrompt.addModifyListener( new ModifyListener()
|
||||
{
|
||||
public void modifyText(ModifyEvent event)
|
||||
{
|
||||
if (validateName())
|
||||
validate(namePrompt.getCombo());
|
||||
}
|
||||
} );
|
||||
yearPrompt.addModifyListener( new ModifyListener()
|
||||
{
|
||||
public void modifyText(ModifyEvent event)
|
||||
{
|
||||
if (validateYear())
|
||||
validate(yearPrompt);
|
||||
}
|
||||
} );
|
||||
monthPrompt.addModifyListener( new ModifyListener()
|
||||
{
|
||||
public void modifyText(ModifyEvent event)
|
||||
{
|
||||
if (validateMonth())
|
||||
validate(monthPrompt);
|
||||
}
|
||||
} );
|
||||
dayPrompt.addModifyListener( new ModifyListener()
|
||||
{
|
||||
public void modifyText(ModifyEvent event)
|
||||
{
|
||||
if (validateDay())
|
||||
validate(monthPrompt);
|
||||
}
|
||||
} );
|
||||
|
||||
// <I>initialize enabled state</I>...
|
||||
setPageComplete(isPageComplete());
|
||||
|
||||
return parentComposite;
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Required parent override</I>.
|
||||
* <I>This is where we return the first input control, to give it focus when the dialog appears</I>.
|
||||
*/
|
||||
protected Control <B>getInitialFocusControl</B>()
|
||||
{
|
||||
return namePrompt.getCombo();
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Typical parent override</I>.
|
||||
* <I>This is where we get control when the user presses OK</I>.
|
||||
*/
|
||||
protected boolean <B>processOK</B>()
|
||||
{
|
||||
errorMessage = null;
|
||||
Control controlInError = validate(null);
|
||||
if (controlInError != null)
|
||||
controlInError.setFocus();
|
||||
else
|
||||
{
|
||||
SampleCustomer newCust = inpCust;
|
||||
if (newCust == null)
|
||||
newCust = new SampleCustomer();
|
||||
newCust.setName(namePrompt.getText().trim());
|
||||
newCust.setYear(yearPrompt.getText().trim());
|
||||
newCust.setMonth(monthPrompt.getText().trim());
|
||||
newCust.setDay(dayPrompt.getText().trim());
|
||||
setOutputObject(newCust);
|
||||
|
||||
SystemMessage completionMsg = null;
|
||||
if (inpCust == null)
|
||||
completionMsg = SamplesPlugin.getPluginMessage("SPPD1010");
|
||||
else
|
||||
completionMsg = SamplesPlugin.getPluginMessage("SPPD1011");
|
||||
completionMsg.makeSubstitution(newCust.getName());
|
||||
SystemMessageDialog msgDlg = new SystemMessageDialog(getShell(), completionMsg);
|
||||
msgDlg.open();
|
||||
}
|
||||
return isPageComplete();
|
||||
}
|
||||
|
||||
// ---------------------
|
||||
// <I>Validation methods</I>...
|
||||
// ---------------------
|
||||
/**
|
||||
* <I>Do full validation of all entry fields, optionally skipping a given one</I>.
|
||||
* <I>@return first control that is found to contain errors. Can be used to set focus</I>.
|
||||
*/
|
||||
protected Control <B>validate</B>(Control controlToSkip)
|
||||
{
|
||||
Control controlInError = null;
|
||||
|
||||
if ((controlToSkip != namePrompt.getCombo()) && !validateName())
|
||||
controlInError = namePrompt.getCombo();
|
||||
if ((controlInError==null) && (controlToSkip != yearPrompt) && !validateYear())
|
||||
controlInError = yearPrompt;
|
||||
if ((controlInError==null) && (controlToSkip != monthPrompt) && !validateMonth())
|
||||
controlInError = monthPrompt;
|
||||
if ((controlInError==null) && (controlToSkip != dayPrompt) && !validateDay())
|
||||
controlInError = dayPrompt;
|
||||
|
||||
return controlInError;
|
||||
}
|
||||
/**
|
||||
* <I>Validate the customer name prompt. We only ensure it is not-empty.</I>
|
||||
*/
|
||||
protected boolean <B>validateName</B>()
|
||||
{
|
||||
String input = namePrompt.getText().trim();
|
||||
setErrorMessageAndPageCompletionStatus(nameValidator.validate(input));
|
||||
return (errorMessage==null);
|
||||
}
|
||||
/**
|
||||
* <I>Validate the customer birth year prompt</I>.
|
||||
*/
|
||||
protected boolean <B>validateYear</B>()
|
||||
{
|
||||
String input = yearPrompt.getText().trim();
|
||||
setErrorMessageAndPageCompletionStatus(yearValidator.validate(input));
|
||||
return (errorMessage==null);
|
||||
}
|
||||
/**
|
||||
* <I>Validate the customer birth month prompt</I>.
|
||||
*/
|
||||
protected boolean <B>validateMonth</B>()
|
||||
{
|
||||
String input = monthPrompt.getText().trim();
|
||||
setErrorMessageAndPageCompletionStatus(monthValidator.validate(input));
|
||||
return (errorMessage==null);
|
||||
}
|
||||
/**
|
||||
* <I>Validate the customer birth day prompt</I>.
|
||||
*/
|
||||
protected boolean <B>validateDay</B>()
|
||||
{
|
||||
String input = dayPrompt.getText().trim();
|
||||
setErrorMessageAndPageCompletionStatus(dayValidator.validate(input));
|
||||
return (errorMessage==null);
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>A convenience method that issues or clears the error message on the message line</I>,
|
||||
* <I>and sets the page completion status</I>
|
||||
*/
|
||||
protected void <B>setErrorMessageAndPageCompletionStatus</B>(SystemMessage errorMessage)
|
||||
{
|
||||
this.errorMessage = errorMessage;
|
||||
if (errorMessage == null)
|
||||
clearErrorMessage();
|
||||
else
|
||||
setErrorMessage(errorMessage);
|
||||
setPageComplete(isPageComplete());
|
||||
}
|
||||
/**
|
||||
* <I>Return true if the OK button can be enabled</I>.
|
||||
*/
|
||||
protected boolean <B>isPageComplete</B>()
|
||||
{
|
||||
return ((errorMessage == null) &&
|
||||
(namePrompt.getText().trim().length()>0) &&
|
||||
(yearPrompt.getText().trim().length()>0) &&
|
||||
(monthPrompt.getText().trim().length()>0) &&
|
||||
(dayPrompt.getText().trim().length()>0));
|
||||
}
|
||||
}</pre>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 3.8 KiB |
Before Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 2.7 KiB |
Before Width: | Height: | Size: 7.2 KiB |
Before Width: | Height: | Size: 5.5 KiB |
|
@ -1,180 +0,0 @@
|
|||
<!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>RSE Dialogs API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Dialogs API</h1>
|
||||
<p>There are two ways the Remote System Explorer API set can help you when it comes to dialogs:
|
||||
<ol>
|
||||
<li>A base dialog class from which to base your own dialog classes.
|
||||
<li>A set of re-usable dialogs for specific requirements.
|
||||
</ol>
|
||||
</p>
|
||||
|
||||
<h2>RSE-Supplied Base Class for Dialogs</h2>
|
||||
<p>Dialogs are secondary windows that prompt the user for information or display information to the user. They are typically
|
||||
<i>modal</i>, meaning the rest of the application (in this case eclipse) is disabled while the dialog is showing.
|
||||
Eclipse supplies a raw dialog class in SWT, as well as more robust dialog class in JFace. The RSE supplies its own
|
||||
class,
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html">SystemPromptDialog</A></samp>
|
||||
in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/package-summary.html">org.eclipse.rse.ui.dialogs</A></samp>
|
||||
, that extends
|
||||
the JFace dialog class and adds to it the following capabilities inherited by all classes which extend it:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Support for an optional visual message line at the bottom, on which messages can be displayed to the user. These can be either
|
||||
<samp>SystemMessage</samp> objects, or simple string messages. <samp><A
|
||||
href="../messages/uiMessageAPI.html#SystemMessage">SystemMessage</A></samp> objects are preferred, as using these enables a button
|
||||
beside the message line which users can press to see the details for the message. This is supported via the <samp><A
|
||||
href="../messages/uiMessageAPI.html#ISystemMessageLine">ISystemMessageLine</A></samp>
|
||||
interface, and so offers a consistent programming interface with the RSE property page and wizard page classes.
|
||||
<li>Support of automatic assignment of mnemonics for input-capable widgets such as buttons. This saves tremendous development
|
||||
effort if your user interface is translated as the assignment of unique mnemonics can be difficult after translation.
|
||||
<li>Built-in support for a number of typical push buttons at the bottom of the dialog: OK, Cancel, Browse, Test, Add and
|
||||
Details. You control via setters which buttons to show, and you can affect their label and tooltip text, although the
|
||||
default labels and tips are already translated for you. To program what happens when pressed, override the appropriate
|
||||
<samp>processXXX()</samp> method, such as <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#processOK()">processOK()</A></samp>. By default, you get OK and Cancel buttons.
|
||||
<li>Support for an optional built-in progress monitor at the bottom of the dialog, just like what eclipse offers for wizards.
|
||||
<li>Support of a simple <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#wasCancelled()">wasCancelled()</A></samp> method to easily test if the dialog was cancelled or not.
|
||||
<li>Support for methods to set an input object, and retrieving an output object, making it easy to pass in data and
|
||||
get back data. Your calling code sets the input object, your subclass code sets the output object (typically in
|
||||
its <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#processOK()">processOK()</A></samp> method) and your calling code gets the output object,
|
||||
if <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#wasCancelled()">wasCancelled()</A></samp> returns false.
|
||||
<li>Support of a <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#setPageComplete(boolean)">setPageComplete(boolean)</A></samp> method, consistent with wizard pages, to enable/disable the OK button.
|
||||
This is typically called by your keystroke and button validators. That is, if an error is detected as input is entered, a message
|
||||
is issued to the message line and the OK button is disabled.
|
||||
<li>Support of a simple <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#setHelp(java.lang.String)">setHelp(String helpId)</A></samp> method to set the dialog's popup help.
|
||||
<li>A simple way to toggle the cursor between busy and normal, using
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#setBusyCursor(boolean)">setBusyCursor(boolean)</A></samp>
|
||||
<li>Helper methods for adding <A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#addFillerLine(org.eclipse.swt.widgets.Composite, int)">filler lines</A>
|
||||
and <A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#addSeparatorLine(org.eclipse.swt.widgets.Composite, int)">separator lines</A>.
|
||||
</ul>
|
||||
<p>To create your own dialog:</p>
|
||||
<ol>
|
||||
<li>Subclass <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html">SystemPromptDialog</A></samp>, picking the appropriate constructor, the simplest
|
||||
of which simply requires the shell of the parent window and the title string for this dialog.
|
||||
<li>If buttons beyond OK and Cancel are desired, in your own constructor call the appropriate <samp>setShowXXXButton(true)</samp> methods to enable
|
||||
these buttons, and override the appropriate <samp>processXXX()</samp> methods to process these buttons when pressed by the user.
|
||||
<li>If a progress monitor is desired, in your own constructor call <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#setNeedsProgressMonitor(boolean)">setNeedsProgressMonitor(true)</A></samp>. Later, to run
|
||||
a long-running operation that displays the progress monitor, use <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#getProgressMonitor()">getProgressMonitor()</A></samp>.
|
||||
<li>Override the <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#createInner(org.eclipse.swt.widgets.Composite)">createInner(Composite)</A></samp> method to populate the client area of the dialog with SWT widgets. Typically
|
||||
you create your composite with a GridLayout layout, populate it, and return it. To ease this programming burden, use the many
|
||||
static helper methods in <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemWidgetHelpers.html">SystemWidgetHelpers</A></samp>.
|
||||
<li>Override the <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#getInitialFocusControl()">getInitialFocusControl()</A></samp> method to supply the control to get initial focus when the dialog is displayed.
|
||||
<li>Override the <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#processOK()">processOK()</A></samp> method to supply the processing for when OK is pressed. You typically first validate
|
||||
the user input, and then return true if there are no errors found.
|
||||
<li>To allow the caller to get user-entered information out of the dialog, either supply getter methods,
|
||||
or call <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#setOutputObject(java.lang.Object)">setOuputObject(Object)</A></samp>
|
||||
in your processOK logic so that your caller can code <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html#getOutputObject()">getOutputObject()</A></samp>.
|
||||
</ol>
|
||||
<P>One of the more difficult efforts in building a dialog with multiple entry fields, is the code to do the validation of those entry fields. A common strategy is to add modify listeners to the entry fields, and for each one validate the data as it typed. If the validation fails, a message is issued. If the validation succeeds, then the other fields on the dialog are validated. At the end of the validation, the OK button is enabled or disabled depending on the error message status, and whether the required information has been supplied. The RSE can help with this effort, somewhat, through the use of re-usable <A
|
||||
href="../validators/uiValidatorsAPI.html">validators</A> for various types of input.<BR>
|
||||
<BR>
|
||||
Follow this <A href="dialogSample.html">link</A> for an example of a fully-formed dialog class written on top of this RSE base class, complete with
|
||||
error checking.</P>
|
||||
|
||||
<p>Typically, after creating your dialog, you will create an action to invoke it. The RSE can help with this too, via the
|
||||
supplied <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseDialogAction.html">SystemBaseDialogAction</A></samp> base class.
|
||||
|
||||
<h2>Dialogs Pre-Supplied by RSE</h2>
|
||||
<p>You may find some of the dialogs supplied by the RSE to be immediately re-usable in your own code, saving some
|
||||
development and test effort. All these dialogs are in package <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/package-summary.html">org.eclipse.rse.ui.dialogs</A></samp>:
|
||||
</p>
|
||||
|
||||
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Class</TH>
|
||||
<TH>Description</TH>
|
||||
<TH>Sample</TH>
|
||||
<TH>Action</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemRenameDialog.html">SystemRenameDialog</A></samp></TD>
|
||||
<TD>Rename multiple items. Provides a table listing the old names and new names, which are editable. If your input objects
|
||||
do not adapt to <samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemViewElementAdapter.html">ISystemViewElementAdapter</A></samp>
|
||||
or <samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemRemoteElementAdapter.html">ISystemRemoteElementAdapter</A></samp>,
|
||||
you should call <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemRenameDialog.html#setNameValidator(org.eclipse.rse.ui.validators.ISystemValidator)">setNameValidator</A></samp> to specify a validator that ensures the new name is correct, and your
|
||||
input objects should also either be IResource objects or implement
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/ISystemTypedObject.html">ISystemTypedObject</A></samp>.
|
||||
</TD>
|
||||
<TD align="center"><A href="renameManyDialog.gif">Sample image</A></TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemCommonRenameAction.html">SystemCommonRenameAction</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemRenameSingleDialog.html">SystemRenameSingleDialog</A></samp></TD>
|
||||
<TD>Rename a single item. Provides a simple entry field for the new name. If your input object
|
||||
does not adapt to <samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemViewElementAdapter.html">ISystemViewElementAdapter</A></samp> or
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemRemoteElementAdapter.html">ISystemRemoteElementAdapter</A></samp>,
|
||||
you should call <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemRenameSingleDialog.html#setNameValidator(org.eclipse.rse.ui.validators.ISystemValidator)">setNameValidator</A></samp> to specify a validator that ensures the new name is correct, and your
|
||||
input object should also either be an IResource object or implement <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/ISystemTypedObject.html">ISystemTypedObject</A></samp>.
|
||||
</TD>
|
||||
<TD align="center"><A href="renameOneDialog.gif">Sample image</A></TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemCommonRenameAction.html">SystemCommonRenameAction</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemDeleteDialog.html">SystemDeleteDialog</A></samp></TD>
|
||||
<TD>Confirm delete of one or more items. Provides a table listing the names of input objects. If your input objects
|
||||
do not adapt to <samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemViewElementAdapter.html">ISystemViewElementAdapter</A></samp> or
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/view/ISystemRemoteElementAdapter.html">ISystemRemoteElementAdapter</A></samp>,
|
||||
your input objects should either be IResource objects or implement <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/ISystemTypedObject.html">ISystemTypedObject</A></samp>.
|
||||
</TD>
|
||||
<TD align="center"><A href="deleteDialog.gif">Sample image</A></TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemCommonDeleteAction.html">SystemCommonDeleteAction</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemSelectFileTypesDialog.html">SystemSelectFileTypesDialog</A></samp></TD>
|
||||
<TD>Presents a dialog listing all the file types defined in the eclipse File Associations preferences page, and
|
||||
allows the user to select one or more of these types, or enter additional types not defined in eclipse.</TD>
|
||||
<TD align="center"><A href="selectTypesDialog.gif">Sample image</A></TD>
|
||||
<TD><samp></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemSimpleSelectDialog.html">SystemSimpleSelectDialog</A></samp></TD>
|
||||
<TD>Eclipse has a CheckboxTreeViewer that is designed to allow the user to select multiple items from a hierarchical model.
|
||||
This is a nice viewer, but very difficult to program to, as you have to handle reflecting the state of the selected children
|
||||
for each parent node yourself. This dialog makes that trivial. The trick is to create wrappers of your model objects using
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemSimpleContentElement.html">SystemSimpleContentElement</A></samp>, maintaining the parent/child hierarchy, and pass the root element to the dialog. The rest is
|
||||
done for you, and the result is the selected state set for those elements selected by the user. Note this can also be used
|
||||
as a simple flat list checkbox selection dialog, just by passing a non-visible root with a flat list of children.</TD>
|
||||
<TD align="center"><A href="simpleSelectDialog.gif">Sample image</A></TD>
|
||||
<TD>None</TD>
|
||||
</TR>
|
||||
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<P><BR>While the dialogs can be instantiated directly, it is perhaps best to use them by instantiating their action class, and calling the run method on it.
|
||||
The action classes are all in <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/package-summary.html">org.eclipse.rse.ui.actions</A></samp> package.
|
||||
</P>
|
||||
<p>In addition to these universal dialogs, there are dialogs specific to the predefined Files subsystem. These enable selection of remote files or folders. They can be found in the <a href="../../../reference/api/org/eclipse/rse/files/ui/dialogs/package-summary.html"><samp>org.eclipse.rse.files.ui.dialogs</samp></a> package.</p>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Class</TH>
|
||||
<TH>Description</TH>
|
||||
<TH>Sample</TH>
|
||||
<TH>Action</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/files/ui/dialogs/SystemSelectRemoteFileOrFolderDialog.html">SystemSelectRemoteFileOrFolderDialog</A></samp></TD>
|
||||
<TD>Allows users to select a remote file, or folder (configurable) using a dialog similar to what is used in Eclipse for local file or
|
||||
folder selection. Can be configured to allow user to select from any existing connection, or to be scoped to a particular connection,
|
||||
or even a particular folder in a particular connection.
|
||||
</TD>
|
||||
<TD align="center"><A href="browseFolderDialog.gif">Sample image</A></TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/files/ui/actions/SystemSelectRemoteFileAction.html">SystemSelectRemoteFileAction</A></samp> or
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/files/ui/actions/SystemSelectRemoteFolderAction.html">SystemSelectRemoteFolderAction</A></samp></TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 7.3 KiB |
|
@ -1,23 +0,0 @@
|
|||
<!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, 2007. 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>RSE Logger API</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>RSE Logger API</h1>
|
||||
<p>To log your messages to the workbench log file in <samp>.metadata\.log</samp>,
|
||||
either base your plugin class on the <samp>org.eclipse.rse.ui.SystemBasePlugin</samp> class and use
|
||||
the inherited logging methods, or instead of instantiating your own <samp>Logging</samp> object, re-use the
|
||||
RSE-supplied logging object by calling <samp>getDefault().getLog()</samp> in the <samp>org.eclipse.rse.ui.RSEUIPlugin</samp>
|
||||
class.
|
||||
</p>
|
||||
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,54 +0,0 @@
|
|||
<!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>RSE Massagers API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Massagers API</h1>
|
||||
<p>In addition to <a href="../validators/uiValidatorsAPI.html">validating</a> what a user types, we often need
|
||||
to transform it prior to saving. For example, we may need to fold it to uppercase or lowercase. The RSE abstracts
|
||||
and encapsulates this concept into massagers which can be re-used. A few are pre-supplied by RSE.
|
||||
</p>
|
||||
|
||||
<h2>RSE Massager Interfaces</h2>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/ISystemMassager.html">ISystemMassager</A></samp> interface is in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/package-summary.html">org.eclipse.rse.ui</A></samp>.
|
||||
It is a very simple interface with one method:
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/ISystemMassager.html#massage(java.lang.String)">public String massage(String text)</A></samp>.
|
||||
Given input text, return the massaged text. While simple, by encapsulating this operation into an interface,
|
||||
you will be able to write re-usable dialogs that take a massager as input. Further, tricky massaging can be
|
||||
built as a re-usable object.
|
||||
</p>
|
||||
|
||||
<h2>RSE-Supplied Massagers</h2>
|
||||
<p>The RSE supplies the following massagers in package <samp><A href="../../../reference/api/org/eclipse/rse/ui/package-summary.html">org.eclipse.rse.ui</A></samp>:
|
||||
</p>
|
||||
<BR>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Massager Class</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/MassagerFoldCase.html">MassagerFoldCase</A></samp></TD>
|
||||
<TD>Simply folds the text to uppercase or lowercase</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/MassagerFoldCaseOutsideQuotes.html">MassagerFoldCaseOutsideQuotes</A></samp></TD>
|
||||
<TD>Folds the text to uppercase or lowercase, except parts of the text that are surrounded by quotes or any given delimiter characters</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/MassagerFoldCaseUnlessQuoted.html">MassagerFoldCaseUnlessQuoted</A></samp></TD>
|
||||
<TD>Folds the text to uppercase or lowercase, unless the whole text is surrounded by quotes or any given delimiter character</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 3.4 KiB |
Before Width: | Height: | Size: 2.5 KiB |
Before Width: | Height: | Size: 2.7 KiB |
Before Width: | Height: | Size: 2.9 KiB |
Before Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 3.1 KiB |
|
@ -1,81 +0,0 @@
|
|||
<!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>Sample Message File</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>Sample Message File</h1>
|
||||
<p>This is an example of a simple message file, say in <samp>sampleMessages.xml</samp>, which has defined messages for only a single component.
|
||||
<pre>
|
||||
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE MessageFile SYSTEM "../org.eclipse.rse.ui/messageFile.dtd">
|
||||
<!-- <I>This is an exammple of a message file used by SystemMessage and SystemMessageDialog</I> -->
|
||||
<MessageFile Version="1.0">
|
||||
<Component Name="Samples Plugin" Abbr="<B>SPP</B>">
|
||||
<Subcomponent Name="Dialogs" Abbr="<B>D</B>">
|
||||
<!-- Component 'D' for dialog sample messages -->
|
||||
<MessageList>
|
||||
<A name="SPPD1000"></A> <Message ID="<B>1000</B>" Indicator="E">
|
||||
<LevelOne>You must enter a name</LevelOne>
|
||||
<LevelTwo>You have left the customer name empty. Specify a name.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1001"></A> <Message ID="<B>1001</B>" Indicator="E">
|
||||
<LevelOne>You must enter a birth year</LevelOne>
|
||||
<LevelTwo>You have left the birth year empty. Specify a year.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1002"></A> <Message ID="<B>1002</B>" Indicator="E">
|
||||
<LevelOne>%1 is not a valid year</LevelOne>
|
||||
<LevelTwo>The birth year specified is not within the valid range of %2 to %3.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1003"></A> <Message ID="<B>1003</B>" Indicator="E">
|
||||
<LevelOne>Year %1 is out of range</LevelOne>
|
||||
<LevelTwo>The value you specified for the birth year is not a valid number.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1004"></A> <Message ID="<B>1004</B>" Indicator="E">
|
||||
<LevelOne>You must enter a birth month</LevelOne>
|
||||
<LevelTwo>You have left the birth month empty. Specify a month.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1005"></A> <Message ID="<B>1005</B>" Indicator="E">
|
||||
<LevelOne>%1 is not a valid month</LevelOne>
|
||||
<LevelTwo>The value you specified for the birth month is not a valid number.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1006"></A> <Message ID="<B>1006</B>" Indicator="E">
|
||||
<LevelOne>Month %1 is out of range</LevelOne>
|
||||
<LevelTwo>The birth month specified is not within the valid range of %2 to %3.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1007"></A> <Message ID="<B>1007</B>" Indicator="E">
|
||||
<LevelOne>You must enter a birth day</LevelOne>
|
||||
<LevelTwo>You have left the birth day empty. Specify a day.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1008"></A> <Message ID="<B>1008</B>" Indicator="E">
|
||||
<LevelOne>%1 is not a valid day</LevelOne>
|
||||
<LevelTwo>The value you specified for the birth day is not a valid number.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1009"></A> <Message ID="<B>1009</B>" Indicator="E">
|
||||
<LevelOne>Day %1 is out of range</LevelOne>
|
||||
<LevelTwo>The birth day specified is not within the valid range of %2 to %3.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1010"></A> <Message ID="<B>1010</B>" Indicator="I">
|
||||
<LevelOne>Customer %1 created successfully. Re-run to see update mode.</LevelOne>
|
||||
<LevelTwo>The customer was created. Re-running the same sample action will show the dialog in update mode.</LevelTwo>
|
||||
</Message>
|
||||
<A name="SPPD1011"></A> <Message ID="<B>1011</B>" Indicator="I">
|
||||
<LevelOne>Customer %1 updated successfully.</LevelOne>
|
||||
<LevelTwo>Congratulations!</LevelTwo>
|
||||
</Message>
|
||||
</MessageList>
|
||||
</Subcomponent>
|
||||
</Component>
|
||||
</MessageFile>
|
||||
</pre>
|
||||
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,154 +0,0 @@
|
|||
<!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>RSE Message API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Message API</h1>
|
||||
<p>To work with messages, which are defined in an xml <a href="uiMessageFile.html">message file</a>,
|
||||
you use:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Static methods in the
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html">org.eclipse.rse.ui.SystemBasePlugin</A></samp>
|
||||
class to load the message file and extract messages from it.
|
||||
<li>Classes in the
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/package-summary.html">org.eclipse.rse.ui.messages</A></samp>
|
||||
package to do variable substitution, and display the messages to the user.
|
||||
</ul>
|
||||
|
||||
<h2>Methods for Parsing the Message File</h2>
|
||||
<p>Once you have defined your message file, you must update your plugin class to load it at startup time.
|
||||
To do this, simply call the static method
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadMessageFile(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadMessageFile</a></samp>
|
||||
in the RSE-supplied <samp><a href="../plugin/uiPluginAPI.html">SystemBasePlugin</a></samp> class.
|
||||
<BR>
|
||||
<BR>
|
||||
After the message file is loaded into memory, you can extract messages from it by calling the static method
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getMessage(org.eclipse.rse.ui.messages.SystemMessageFile, java.lang.String)">getMessage</a></samp>
|
||||
from the same <samp><a href="../plugin/uiPluginAPI.html">SystemBasePlugin</a></samp> class.
|
||||
</p>
|
||||
|
||||
<h2>Classes for Displaying Messages</h2>
|
||||
<p>The following classes are all defined in the <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/package-summary.html">org.eclipse.rse.ui.messages</a></samp> package. </p>
|
||||
|
||||
<h3><A name="SystemMessageFile"></A>The <samp>SystemMessageFile</samp> Class</h3>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadMessageFile(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadMessageFile</a></samp> method in <samp>SystemBasePlugin</samp>, returns an instance of
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessageFile.html">SystemMessageFile</a></samp>,
|
||||
representing the parsed message file. It is methods in this which return individual messages.
|
||||
<h3><A name="SystemMessage"></A>The <samp>SystemMessage</samp> Class</h3>
|
||||
The <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getMessage(org.eclipse.rse.ui.messages.SystemMessageFile, java.lang.String)">getMessage</a></samp> method in <samp>SystemBasePlugin</samp> returns an instance of
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessage.html">SystemMessage</a></samp>,
|
||||
representing an individual message from the message file.
|
||||
</p>
|
||||
<p>To do message <i>variable substitution</i>, call the appropriate overload of the <samp>makeSubstitution</samp> method in
|
||||
the <A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessage.html">message</A> object, passing as many parameters as there are unique substitution variables in the message.
|
||||
</p>
|
||||
<p>To get the first level message text, call <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessage.html#getLevelOneText()">getLevelOneText</a></samp> on the message object. To get
|
||||
the second level help, call <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessage.html#getLevelTwoText()">getLevelTwoText</a></samp>.
|
||||
</p>
|
||||
|
||||
<h3><A name="SystemMessageDialog"></A>The <samp>SystemMessageDialog</samp> Class</h3>
|
||||
<p>To display a message in a dialog, instantiate <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/SystemMessageDialog.html">SystemMessageDialog</a></samp>, passing
|
||||
in a parent shell and the message object, and then call the appropriate <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/SystemMessageDialog.html#open()">open</a></samp> method in the dialog object. Here is what the message
|
||||
dialog looks like, for a message of type Error (the type dictates the error icon):
|
||||
</p>
|
||||
<P><IMG border="0" src="msgDialog.gif" width="457" height="190"></P>
|
||||
|
||||
<h3><A name="ISystemMessageLine"></A>The <samp>ISystemMessageLine</samp> Interface</h3>
|
||||
<p>If you are extending the RSE class <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html">SystemPromptDialog</a></samp> for dialogs,
|
||||
or <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html">AbstractSystemWizardPage</a></samp> for wizard pages
|
||||
or <samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemBasePropertyPage.html">SystemBasePropertyPage</a></samp> for property pages, you can display the message to the
|
||||
user by calling the <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/ISystemMessageLine.html#setErrorMessage(org.eclipse.rse.ui.messages.SystemMessage)">setErrorMessage</a></samp> method all these classes support. These classes all implement
|
||||
the interface <b><samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/ISystemMessageLine.html">ISystemMessageLine</a></samp></b>, which also includes the method <samp>clearErrorMessage</samp>. For non-error
|
||||
messages, use <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/ISystemMessageLine.html#setMessage(org.eclipse.rse.ui.messages.SystemMessage)">setMessage</a></samp>
|
||||
and <samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/ISystemMessageLine.html#clearMessage()">clearMessage</a></samp>.</p>
|
||||
<p>
|
||||
Here is what a system message issued in a <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemPromptDialog.html">SystemPromptDialog</a></samp> dialog looks like:</p>
|
||||
<P><IMG border="0" src="msgLine_dialog.gif" width="264" height="125"></P>
|
||||
<p>The user can select the question mark icon on the right to see the full message dialog, and hence access the second level help for the message.
|
||||
<p>Here is what a system message issued in an <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html">AbstractSystemWizardPage</a></samp> looks like:</p>
|
||||
<P><IMG border="0" src="msgLine_wizard.gif" width="439" height="98"></P>
|
||||
<p>If the user clicks the mouse on the message or icon, they will see the full message dialog for the message.</p>
|
||||
|
||||
<p>Here is what a system message issued in a <samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemBasePropertyPage.html">SystemBasePropertyPage</a></samp> looks like:</p>
|
||||
<P><IMG border="0" src="msgLine_properties.gif" width="491" height="75"></P>
|
||||
<p>Again, if the user clicks the mouse on the message or icon, they will see the full message dialog for the message.</p>
|
||||
|
||||
<h2>Classes for Displaying Message Exceptions</h2>
|
||||
<p>The following class is defined in the <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/package-summary.html">org.eclipse.rse.services.clientserver.messages</a></samp> package.
|
||||
|
||||
<h3>The <samp>SystemMessageDialog</samp> Class</h3>
|
||||
<p>Many of the RSE APIs throw <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessageException.html">org.eclipse.rse.services.clientserver.messages.SystemMessageException</a></samp>, which
|
||||
encapsulates a system message object. To get the encapsulated message, call <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessageException.html#getSystemMessage()">getSystemMessage()</a></samp>.
|
||||
To display the message in an RSE message dialog box, simply call <samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessageException.html#displayMessage()">displayMessage()</a></samp> on the exception object.
|
||||
To get the first-level text, call <samp>getMessage()</samp>, or <samp>getSystemMessage().getLevelOneText()</samp>
|
||||
</p>
|
||||
|
||||
<h1>Message Example</h1>
|
||||
<h2>Declaring the Messages</h2>
|
||||
<p>Declare the messages via the <samp>Message</samp> tag in a <a href="uiMessageFile.html">message file</a>, such as <samp>sampleMessages.xml</samp>
|
||||
<pre><?xml version="1.0" encoding='UTF-8'?>
|
||||
<!DOCTYPE MessageFile SYSTEM "../org.eclipse.rse.ui/messageFile.dtd">
|
||||
<!-- This is an exammple of a message file used by SystemMessage and SystemMessageDialog -->
|
||||
<MessageFile Version="1.0">
|
||||
<Component Name="Samples Plugin" Abbr="<B>SPP</B>">
|
||||
<Subcomponent Name="Dialogs" Abbr="<B>D</B>">
|
||||
<!-- Component 'D' for dialog sample messages -->
|
||||
<MessageList>
|
||||
<Message ID="<B>1003</B>" Indicator="E">
|
||||
<LevelOne>%1 is not a valid year</LevelOne>
|
||||
<LevelTwo>The birth year specified is not within the valid range of %2 to %3.</LevelTwo>
|
||||
</Message>
|
||||
<!-- <I>repeat Message elements as needed</I> -->
|
||||
</MessageList>
|
||||
</Subcomponent>
|
||||
</Component>
|
||||
</MessageFile>
|
||||
</pre>
|
||||
|
||||
<h2>Processing the Message File</h2>
|
||||
In your plugin class, declare a message file static variable, load the message file in the constructor, and
|
||||
supply a static method for retrieving a message from the file.
|
||||
<pre>import org.eclipse.rse.ui.messages.*; // <I>for message file classes</I>
|
||||
import org.eclipse.rse.ui.*; // <I>for SystemBasePlugin</I>
|
||||
<B>...</B>
|
||||
private static SystemMessageFile messageFile = null;
|
||||
<B>...</B>
|
||||
messageFile = SystemBasePlugin.loadMessageFile(descriptor, "sampleMessages.xml"); // <I>in constructor</I>
|
||||
<B>...</B>
|
||||
|
||||
/**
|
||||
* <I>Retrieve a message from this plugin's message file</I>
|
||||
* <I>@param msgId - the ID of the message to retrieve. This is the concatenation of the</I>
|
||||
* <I>message's component abbreviation, subcomponent abbreviation, and message ID as declared</I>
|
||||
* <I>in the message xml file.</I>
|
||||
*/
|
||||
<A name="getPluginMessage"></A>public static SystemMessage <B>getPluginMessage</B>(String msgId)
|
||||
{
|
||||
return SystemBasePlugin.getMessage(messageFile, msgId);
|
||||
}</pre>
|
||||
|
||||
<h2>Retrieving the Message</h2>
|
||||
<pre>SystemMessage errorMessage = SamplesPlugin.getPluginMessage("SPPD1003");
|
||||
errorMessage.makeSubstitution(input, "1900", "2003");</pre>
|
||||
|
||||
<h2>Displaying the Message</h2>
|
||||
<h3>On a Message Line</h3>
|
||||
<pre>setErrorMessage(errorMessage);</pre>
|
||||
|
||||
<P><IMG border="0" src="msgSample_msgline.gif" width="227" height="208"></P>
|
||||
<h3>In a Message Dialog</h3>
|
||||
<pre>SystemMessageDialog msgDlg = new SystemMessageDialog(shell, errorMessage);</br>msgDlg.open(); // <I>to open with details not showing</I>
|
||||
//msgDlg.openWithDetails(); // <I>to open with details already showing</I> </pre>
|
||||
|
||||
<P><IMG border="0" src="msgSample_msgDlg.gif" width="457" height="190"></P>
|
||||
<P><BR>
|
||||
</P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,79 +0,0 @@
|
|||
<!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>RSE Message File</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Message File</h1>
|
||||
<p>To exploit the message framework in RSE, you start by create an message file, named
|
||||
say <samp>mymessages.xml</samp>, which looks something like this:
|
||||
<pre>
|
||||
<?xml version="1.0" encoding='UTF-8'?>
|
||||
<!-- This is a sample message file -->
|
||||
<MessageFile Version="1.0">
|
||||
<Component Name="ACME Tools" Abbr="ACME">
|
||||
<Subcomponent Name="General" Abbr="G">
|
||||
<MessageList>
|
||||
<Message ID="1001" Indicator="E">
|
||||
<LevelOne>You made a mistake</LevelOne>
|
||||
<LevelTwo>Fix your mistake, then re-attempt the operation.</LevelTwo>
|
||||
</Message>
|
||||
</MessageList>
|
||||
</Subcomponent>
|
||||
</Component>
|
||||
</MessageFile>
|
||||
</pre>
|
||||
|
||||
<h2>RSE Message File Elements</h2>
|
||||
<p>Typically, this file is created in plugin project's root folder.</p>
|
||||
<p>The important elements in this file are:
|
||||
</p><TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Element</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>MessageFile</TD>
|
||||
<TD>The overall element for the file. There is only one of these tags.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Component</TD>
|
||||
<TD>Identifies a course-grained component within your plugin. You can specify multiple component tags. It is up to you to decide<BR>how many components to divide your plugin into. The abbreviation (Abbr) of the component constitutes the first part of the message ID for messages defined in this component, aiding in servicing when an error message is reported.
|
||||
</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Subcomponent</TD>
|
||||
<TD>Identifies a fine-grained subcomponent within a component. The abbreviation (Abbr) of the subcomponent is appended to the component's abbreviation when the message ID is created for messages in this subcomponent. It is up to you to decide how many subcomponents to divide your component into, and what to name them.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>MessageList</TD>
|
||||
<TD>Simply encapsulates the list of Message elements for this subcomponent.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Message</TD>
|
||||
<TD>Defines a message. <BR>
|
||||
The <b>ID</b> attribute can be anything you like, but following a naming or numbering convention is a good idea. The ID is appended to the component and subcomponent abbreviations to form the message ID the user will see.
|
||||
<BR>The <b>Indicator</b> attribute identifies the severity of the message: <b>I</b> for Information, <b>E</b> for Error, <b>W</b> for Warning, <b>U</b> for Unexpected, and <b>Q</b> for Question. This affects the icon that will be used for this message, and the buttons allowed on the message dialog.
|
||||
</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>LevelOne</TD>
|
||||
<TD>The first-level message the user will initially see. Use %n for substitution variables, where n is a positive integer incrementing up from 1.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>LevelTwo</TD>
|
||||
<TD>The second-level help for the message, the user will only see if they ask to see it. Use %n for substitution variables. Any variable used here and in the LevelOne text will be consistently substituted with the same value.</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
|
||||
<h2>RSE Message File Sample</h2>
|
||||
<p>This is a bigger <A href="sampleMessageFile.html">sample</A>.</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,23 +0,0 @@
|
|||
<!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>RSE Model API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Model API</h1>
|
||||
<p>The front door to accessing the elements of the RSE model is the <A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html">ISystemRegistry</A>, which is a
|
||||
singleton object accessible via <A href="../../reference/api/org/eclipse/rse/core/model/SystemStartHere.html#getSystemRegistry()">SystemStartHere.getSystemRegistry()</A>.
|
||||
</p>
|
||||
<p>The system registry will get you access to profiles, connections and subsystem factories.
|
||||
From a <A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystemConfiguration.html">subsystem configuration</A> you can access subsystems, filter pools,
|
||||
user actions and compile commands.
|
||||
From <A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">ISubSystem</A> you can access remote resources, as well
|
||||
as filter pools referenced by the subsystem.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,80 +0,0 @@
|
|||
<!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>RSE Base Plugin Class</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Base Plugin Class</h1>
|
||||
<p>You may find it of value to base your own plugin class on the RSE-supplied base plugin class.
|
||||
If so, there are some methods you are encouraged to create or override in your class. The benefits
|
||||
of using this as your base class is the inherited methods you can access.
|
||||
</p>
|
||||
<h2>Methods required in your plugin subclass</h2>
|
||||
<p>To use the RSE base plugin class
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html">org.eclipse.rse.ui.SystemBasePlugin</A></samp>,
|
||||
you subclass it for your own plugin class, and supply some key static methods of your own:
|
||||
</p>
|
||||
<ul>
|
||||
<li><samp>getDefault()</samp>. Return a singleton instance of your plugin.
|
||||
<li><samp>getResourceBundle()</samp>. Return the resource bundle for your plugin. This is stored in
|
||||
a static field, initialized in your constructor by calling the <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadResourceBundle(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadResourceBundle(...)</A></samp> inherited method.
|
||||
<li><samp>getString(String key)</samp>. Return a translated string by calling the inherited method
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getString(java.util.ResourceBundle, java.lang.String)">getString(ResourceBundle rb, String key)</A></samp>, passing in the static resource bundle field.
|
||||
<li><samp>getPluginMessageFile()</samp>. Return your RSE message file instance, initialized in your
|
||||
constructor by calling <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadMessageFile(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadMessageFile(...)</A></samp>.
|
||||
<li><samp>getPluginMessage(String msgID)</samp>. Return the
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/services/clientserver/messages/SystemMessage.html">SystemMessage</A></samp> for the given ID, by
|
||||
calling the inherited method
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getMessage(org.eclipse.rse.services.clientserver.messages.SystemMessageFile, java.lang.String)">getMessage(getPluginMessageFile(), msgId)</a></samp>. You will call this method often to get message objects.
|
||||
</ul>
|
||||
<p>You may also override some RSE-supplied instance methods:
|
||||
<ul>
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#initializeImageRegistry()">initializeImageRegistry()</A></samp>. Call
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#putImageInRegistry(java.lang.String, java.lang.String)">putImageInRegistry(String id, String imageFileName)</A></samp>
|
||||
to load each of your images.
|
||||
</ul>
|
||||
</p>
|
||||
<p>Of course, there are the usual eclipse-supplied instance methods to override too:
|
||||
<ul>
|
||||
<li><samp>initializeDefaultPreferences()</samp>. Good place to call the <samp>initDefaults()</samp> method of your preference pages. Be sure to call <samp>super.initializeDefaultPreferences()</samp>.
|
||||
<li><samp>startup()</samp>. Good place to register adapters and so forth. Be sure to call <samp>super.startup()</samp> at the beginning.
|
||||
<li><samp>shutdown()</samp>. Good place to close any open communication layers. Be sure to call <samp>super.shutdown()</samp> at the end.
|
||||
</ul>
|
||||
</p>
|
||||
|
||||
<h2>Methods inherited from the RSE base class</h2>
|
||||
<p>The methods you get access to by using the RSE-supplied base plugin class include:</p>
|
||||
<ul>
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getPluginId()">getPluginId()</A></samp>. Return this plugin's ID.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getActiveWorkbenchShell()">getActiveWorkbenchShell()</A></samp>. Return the shell of the active workbench window.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getActiveWorkbenchWindow()">getActiveWorkbenchWindow()</A></samp>. Return the active workbench window.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getWorkspaceRoot()">getWorkspaceRoot()</A></samp>. Return the root of the workspace.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getWorkspace()">getWorkspace()</A></samp>. Return the workspace root.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getInstallLocation()">getInstallLocation()</A></samp>. Return the install directory for this plugin.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getIconPath()">getIconPath()</A></samp>. Return the typical path for icons, relative to the plugin's folder: "icons/"
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#putImageInRegistry(java.lang.String, java.lang.String)">putImageInRegistry(String id, String fileName)</A></samp>. Load an image in the image registry, given the ID to retrieve it with, and its filename and path relative to this plugin's folder
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getImage(java.lang.String)">getImage(String id)</A></samp>. Return an Image given the ID with which it was registered in putImageInRegistry.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getImageDescriptor(java.lang.String)">getImageDescriptor(String id)</A></samp>. Return an ImageDescriptor given the ID with which it was registered in putImageInRegistry.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadResourceBundle(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadResourceBundle(IPluginDescriptor descriptor, String fileName)</A></samp>. Load a resource bundle, given its file name, relative to the given plugin's installation folder.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadResourceBundle(java.lang.String)">loadResourceBundle(String fileName)</A></samp>. Load a resource bundle, given its file name, relative to this plugin's installation folder.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getString(java.util.ResourceBundle, java.lang.String)">getString(ResourceBundle rb, String id)</A></samp>. Return a translated string from a resource bundle, given its key ID.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getString(java.util.ResourceBundle, java.lang.String, java.lang.String)">getString(ResourceBundle rb, String id, String default)</A></samp>. Return a translated string from a resource bundle, given its key ID. If key not found in the resource bundle, returns the given default string.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#loadMessageFile(org.eclipse.core.runtime.IPluginDescriptor, java.lang.String)">loadMessageFile(IPluginDescriptor descriptor,String fileName)</A></samp>. Parse an RSE-style message file into memory, given the plugin and message file name.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getMessage(org.eclipse.rse.services.clientserver.messages.SystemMessageFile, java.lang.String)">getMessage(SystemMessageFile msgFile, String msgId)</A></samp>. Retrieve a SystemMessage object, given the message file that contains it, and its message ID including component and subcomponent abbreviations.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#scanForDuplicateMessages(org.eclipse.rse.services.clientserver.messages.SystemMessageFile)">scanForDuplicateMessages(SystemMessageFile msgFile)</A></samp>. Scan given message file for duplicate IDs. Typically only called during the development cycle.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#printMessages(org.eclipse.rse.services.clientserver.messages.SystemMessageFile, java.lang.String)">printMessages(SystemMessageFile msgFile, String fullyQualifiedTargetFile)</A></samp>. Generate an HTML file documenting the messages in the given message file, given the fully qualified name of the target HTML file.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#showProgrammerErrorMessage(java.lang.String)">showProgrammerErrorMessage(String msg)</A></samp>. Show a message to the user, when the message file support is not available.
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#logInfo(java.lang.String)">logInfo(String message)</A></samp>. Log an informational message to the RSE's core log file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#logWarning(java.lang.String)">logWarning(String message)</A></samp>. Log a warning message to the RSE's core log file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#logError(java.lang.String)">logError(String message)</A></samp>. Log an error message to the RSE's core log file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#logError(java.lang.String, java.lang.Throwable)">logError(String message, Throwable exception)</A></samp>. Log an error message resulting from an exception to the RSE's core log file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#logDebugMessage(java.lang.String, java.lang.String)">logDebugMessage(String prefix, String message)</A></samp>. Log a debug (trace) message to the RSE's core log file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
<li><samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemBasePlugin.html#getLogger()">getLogger()</A></samp>.Return the Logger instance for the RSE default logging file (<samp>.....\.metadata\.plugins\org.eclipse.rse.core\.log</samp>).
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 540 B |
Before Width: | Height: | Size: 14 KiB |
|
@ -1,53 +0,0 @@
|
|||
<!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>RSE Preferences API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Preferences API</h1>
|
||||
|
||||
<h2>RSE Preference Pages Category</h2>
|
||||
<p>All Remote System Explorer preference pages are rooted within the
|
||||
preferences category <samp>org.eclipse.rse.ui.preferences.RemoteSystemsPreferencePage</samp>,
|
||||
as shown here:</p>
|
||||
<P><IMG border="0" src="rsePreferences.gif"></P>
|
||||
|
||||
<h2>RSE Preference Pages Classes</h2>
|
||||
<p>There is no RSE-supplied base class for preference pages, but we recommend
|
||||
you extend <samp>FieldEditorPreferencePage</samp> in package <samp>org.eclipse.jface.preference</samp>.
|
||||
This JFace class allows you to create a preferences page as a sequence of "field
|
||||
editors" which know how to initialize, load and store their values from their preferences store.
|
||||
</p>
|
||||
<p>We also suggest the following when designing your preference pages:
|
||||
<ol>
|
||||
<li>A interface for your preferences constants. It should store two constants per preference: the preference store key, and its default value.
|
||||
<li>Static getter and setter methods in your preference page classes, one per preference, to query or update the preference value in the preferences store.
|
||||
<li>An <samp>initDefaults(IPreferenceStore store)</samp> method per preferences class, that initializes the preference store value of each preference on that page.
|
||||
<li>In your plugin class, an override of the <samp>initializeDefaultPreferences(IPreferenceStore store)</samp> method, so it calls your
|
||||
<samp>initDefaults(store)</samp> method for each preference page class.
|
||||
</ol>
|
||||
<p>Should you need to query, or update, any RSE preferences you can do so via
|
||||
the getters and setters in <samp>org.eclipse.rse.core.SystemPreferencesManager</samp>.
|
||||
</p>
|
||||
<p>The RSE supplies a few field editors, complementing what JFace supplies
|
||||
in <samp>org.eclipse.jface.preference</samp>. The RSE-supplied field editors, and the
|
||||
RSE-supplied preferences pages, are all found in package <samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/package-summary.html">org.eclipse.rse.ui.propertypages</A></samp>:
|
||||
</p>
|
||||
<ul>
|
||||
<li><b><samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemBooleanFieldEditor.html">SystemBooleanFieldEditor</A></samp></b>. Extends <samp>BooleanFieldEditor</samp> to add support for tooltip text.
|
||||
<p><IMG border="0" src="fldEditor_checkBox.gif"></p>
|
||||
<li><b><samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemComboBoxFieldEditor.html">SystemComboBoxFieldEditor</A></samp></b>. Shows a combo box allowing the user to choose from a finite list of discrete possibilities.
|
||||
<p><IMG border="0" src="fldEditor_comboBox.gif"></p>
|
||||
<li><b><samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemKeyValueFieldEditor.html">SystemKeyValueFieldEditor</A></samp></b>. Shows a list of hard-coded keys, each of which supports a user-specifiable value.
|
||||
<p><IMG border="0" src="fldEditor_keyValue.gif"></p>
|
||||
<li><b><samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemStringFieldEditor.html">SystemStringFieldEditor</A></samp></b>. For simple string preferences. Unlike the JFace string editor, this supports tooltip text and RSE validators and massagers on the typed text.
|
||||
<p><IMG border="0" src="fldEditor_string.gif"></p>
|
||||
</ul>
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,74 +0,0 @@
|
|||
<!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, 2007. 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>RSE Properties API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Properties API</h1>
|
||||
<p>You can supply your own property pages to any node in the Remote Systems tree or table views.
|
||||
As you author your property page classes, you may find the RSE-supplied base class for property pages
|
||||
of value.
|
||||
|
||||
<h2>RSE-Supplied Base Class for Property Pages</h2>
|
||||
<p>The RSE supplies a base class for property pages,
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/propertypages/SystemBasePropertyPage.html">org.eclipse.rse.ui.propertypages.SystemBasePropertyPage</A></samp>,
|
||||
that extends the base eclipse property page <samp>org.eclipse.ui.dialogs.PropertyPage</samp>. The advantages
|
||||
of using this RSE-supplied class are:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Supports <samp><a href="../messages/uiMessageAPI.html">SystemMessage</A></samp> error messages, allowing the user to click on a message to see its details.
|
||||
<li>Supports automatic assignment of mnemonics for input-capable fields.
|
||||
<li>Supports automatic management of the "isValid" property based on current error message status in the message line. This
|
||||
property is important to set correct, so eclipse knows when to prevent the user from switching focus to other property pages.
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Property Pages for RSE Non-Remote Resources</h2>
|
||||
<p>You can simply use the eclipse-supplied extension point <samp>org.eclipse.ui.propertyPages</samp> to
|
||||
contribute property pages to any of the non-remote artifacts from the RSE model. To use this extension
|
||||
point, you need to know the class or, preferably, interface that the objects implement, which we describe here:
|
||||
</p>
|
||||
|
||||
<TABLE border="1" width="100%">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>RSE Resource</TH>
|
||||
<TH>Implements Interface</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Profile</TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/core/model/ISystemProfile.html">org.eclipse.rse.core.model.ISystemProfile</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Host</TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/core/model/IHost.html">org.eclipse.rse.core.model.IHost</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Subsystem</TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">org.eclipse.rse.core.subsystems.ISubSystem</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Filter pool reference</TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolReference.html">org.eclipse.rse.core.filters.ISystemFilterPoolReference</A></samp></TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD>Filter reference</TD>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/core/filters/ISystemFilterReference.html">org.eclipse.rse.core.filters.ISystemFilterReference</A></samp></TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<h2>Property Pages for RSE Remote Resources</h2>
|
||||
<p>See <a href="../../../guide/plugin/propertypage.html">Plugging In Property Pages</a>
|
||||
for information on how to contribute property pages for remote resources.
|
||||
Because remote resources have no underlying eclipse resource, and typically all are instances of the same class,
|
||||
Eclipse Filtering capabilities are used to allow very explicit scoping of the property page to very specific types of remote resources.
|
||||
</p>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,33 +0,0 @@
|
|||
<!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>RSE Remote Resource API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Remote Resource API</h1>
|
||||
<p>RSE supplies subsystems for accessing the file system and for executing commands, for
|
||||
all system types ("universally").
|
||||
</p>
|
||||
<p>
|
||||
To programmatically access the files in a remote system
|
||||
identified by a particular system connection, use the
|
||||
<A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html">system registry</A> to get to the
|
||||
<A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html#getSubSystemsBySubSystemConfigurationCategory(String, org.eclipse.rse.core.model.IHost)">file subsystem</A>
|
||||
for that connection, by passing in the file category as a String. This <A href="../../reference/api/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFileSubSystem.html">file subsystem</A> offers methods for accessing the remote files.
|
||||
</p>
|
||||
<p>
|
||||
Similarly, to programmatically run commands in a remote system
|
||||
identified by a particular system connection, use the
|
||||
<A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html">system registry</A> to get to the
|
||||
<A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html#getSubSystemsBySubSystemConfigurationCategory(String, org.eclipse.rse.core.model.IHost)">command subsystem</A>
|
||||
for that connection, by passing in the command category as a String. This <A href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteCmdSubSystem.html">command subsystem</A> offers methods for running remote commands,
|
||||
either in a new command shell or an existing command shell. You can also set environment variables
|
||||
using this subsytem object.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -1,129 +0,0 @@
|
|||
<!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, 2007. 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>RSE User Interface API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE User Interface API</h1>
|
||||
<p>The RSE provides a number of classes that can help with programming productivity when authoring
|
||||
user interface artifacts, such as actions, dialogs, wizards, property pages and preferences pages.
|
||||
Further, a common requirement in all of these artifacts is the need to display translated messages
|
||||
to the user. The RSE supplies a framework for defining and displaying rich messages that have second
|
||||
level help, severity and ID attributes.
|
||||
</p>
|
||||
<p>
|
||||
In the following sections we introduce the support offered by the RSE for these UI constructs.
|
||||
<h2>Plugin Class</h2>
|
||||
<p>The RSE supplies a base plugin class <samp><a href="plugin/uiPluginAPI.html">SystemBasePlugin</a></samp> that offers
|
||||
some advantages over the base eclipse <samp>AbstractUIPlugin</samp> class:
|
||||
<ol>
|
||||
<li>Simplified methods for registering images, and support for retrieving them either as an image
|
||||
or an image descriptor.
|
||||
<li>Support for <a href="logger/uiLoggerAPI.html">logging</a> error, warning and information messages, using the RSE logging framework.
|
||||
<li>Support for loading a resource bundle, and easily retrieving translated strings from it.
|
||||
<li>Support for loading an RSE <a href="messages/uiMessageFile.html">message file</a>, and easily retrieving translated messages from it.
|
||||
<li>Helper methods for getting the active workbench window and shell.
|
||||
</ol>
|
||||
</p>
|
||||
<p>To use the base plugin class effectively, you must subclass it and supply some critical
|
||||
methods of your own.
|
||||
</p>
|
||||
|
||||
<h2>Messages</h2>
|
||||
<p>The Java property file for messages is not very rich, as it offers only the ability to define a
|
||||
single message string. Throughout the RSE perspective you will notice that the messages are richer
|
||||
than this. They contain second level help, severity, and ID and more. Further, there is a unique
|
||||
error message dialog for displaying messages, with their second level help, and specialized support
|
||||
in the RSE dialog, wizard and property page classes for displaying messages on a message line. These
|
||||
messages can be selected by the user, to bring up the specialized message dialog displaying the
|
||||
additional properties of the message. Further, there is support for logging severe errors to a log
|
||||
file, enabling better service support.
|
||||
</p>
|
||||
<p>
|
||||
Your own plugins can enjoy this rich message support too, even independently of using the rest of
|
||||
the RSE for remote resource access. This support involves defining an xml
|
||||
<a href="messages/uiMessageFile.html">message file</a>, which defines
|
||||
the messages, and using a set of
|
||||
<a href="messages/uiMessageAPI.html">supplied classes</a> to work with the messages.
|
||||
</p>
|
||||
<p>Before defining your own messages, you may wish to peruse the list of <a href="messages/uiMessagesCore.html">RSE-supplied messages</a> that are
|
||||
already defined. The key benefit to using an existing message is translation, as these are already
|
||||
translated into many languages.
|
||||
</p>
|
||||
|
||||
<h2>Preference Pages</h2>
|
||||
<p>When defining your own <a href="preferences/uiPreferencesAPI.html">preferences pages</a>,
|
||||
you may want to place your preference pages within the Remote Systems preference page category.
|
||||
As you author your preference page classes, you may find some of the RSE-supplied classes for
|
||||
preference pages to be useful.
|
||||
</p>
|
||||
|
||||
<h2>Property Pages</h2>
|
||||
<p>Property pages can appear in the Properties dialog of any object in eclipse. This dialog is available by selecting
|
||||
"Properties" from the pop-up menu for the object. The RSE supports defining your own
|
||||
<a href="properties/uiPropertiesAPI.html">property pages</a> for the resources in its model, although there is a
|
||||
distinction between local and remote resources.
|
||||
</p>
|
||||
|
||||
<h2>Validators</h2>
|
||||
<p>Validating user-entered text is a common and tedious task in any GUI programming. Using validators to encapsulate
|
||||
the error checking for a particular type of data is a highly recommended practice. The
|
||||
<a href="validators/uiValidatorsAPI.html">RSE validator</a> support is very
|
||||
helpful for this, offering both a common interface for all manner of validators and a large list of pre-supplied
|
||||
validators.
|
||||
</p>
|
||||
|
||||
<h2>Massagers</h2>
|
||||
<p>While validating user-entered text is common, so is affecting user-entered text prior to saving it. For example, folding it
|
||||
to upper or lower case. The <a href="massagers/uiMassagersAPI.html">RSE massager</a> support encapsulates this concept, and
|
||||
supplies a few re-usable massagers for you.
|
||||
</p>
|
||||
|
||||
<h2>Widgets</h2>
|
||||
<p>Populating preference pages, property pages, dialogs and wizards requires use of SWT widget programming. The RSE
|
||||
<a href="widgets/uiWidgetsAPI.html">widget support</a> can help, with helper methods and classes, and re-usable widgets you may
|
||||
find useful.
|
||||
</p>
|
||||
|
||||
<h2>Dialogs</h2>
|
||||
<p>The RSE supplies rich support for <a href="dialogs/uiDialogsAPI.html">dialogs</a>, including a powerful base class
|
||||
and, re-usable pre-built dialogs.
|
||||
</p>
|
||||
|
||||
<h2>Wizards</h2>
|
||||
<p>Wizards are a common building block of an eclipse GUI. Typically, a wizard is used to prompt for information to create
|
||||
something new, while a dialog is used to prompt for information for other purposes.
|
||||
The RSE <a href="wizards/uiWizardsAPI.html">wizard support</a> includes base classes that can simplify the task of creating wizards.
|
||||
</p>
|
||||
|
||||
<h2>Actions</h2>
|
||||
<p>Populating popup and pulldown menu items requires the creation of actions. These actions typically popup dialogs or wizards,
|
||||
and need to be able to pass selections and inputs from the action to the dialog or wizard, and get outputs back. The RSE
|
||||
<a href="actions/uiActionsAPI.html">action support</a> can significantly help with this programming task, especially when used
|
||||
together with the RSE dialog and wizard support.
|
||||
</p>
|
||||
|
||||
<p>Often we want to refresh the contents of the Remote Systems view or Table view from within our actions, to visualize
|
||||
changes to the selected resources. To do this, use the
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html#fireRemoteResourceChangeEvent(int, java.lang.Object, java.lang.Object, org.eclipse.rse.core.subsystems.ISubSystem, java.lang.String)">method</a></samp>.
|
||||
To get the system registry, use the
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/core/model/SystemStartHere.html#getSystemRegistry()">method</a></samp>.
|
||||
</p>
|
||||
|
||||
<p>At times, you may want to post events in a dispatch thread rather than using the
|
||||
original client's thread; or you may need access to the System Clipboard.
|
||||
Such operations are only possible when the UI
|
||||
is loaded, and therefore you need to use
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/core/model/ISystemRegistry.html#fireRemoteResourceChangeEvent(int, java.lang.Object, java.lang.Object, org.eclipse.rse.core.subsystems.ISubSystem, java.lang.String, java.lang.Object)">ISystemRegistry.fireEvent()</a></samp>
|
||||
method in that case. To get the system registry UI interface, use the
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/ui/RSEUIPlugin.html#getTheSystemRegistryUI()">RSEUIPlugin.getTheSystemRegistryUI()</a></samp>
|
||||
method.
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,226 +0,0 @@
|
|||
<!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>RSE Validators API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Validators API</h1>
|
||||
<p>Throughout an eclipse UI there are times when we need to validate what the user has typed in. Validators
|
||||
offer a way to encapsulate the error checking for a particular domain, so it can be re-used wherever the user
|
||||
is prompted for this. This includes dialogs, property pages, preference pages, wizard pages and viewer
|
||||
cells. Eclipse's JFace offers two interfaces for this, one for viewer cells and one for the rest. In RSE,
|
||||
there is a single interface combining the requirements of both, so you can author a single validator that is
|
||||
re-usable anywhere. Further, the RSE validator interface and sub-interfaces force additional information to be
|
||||
supplied to enhance re-use, such as the maximum length, which can be used to set the text limit for a text field.
|
||||
</p>
|
||||
|
||||
<h2>RSE Validator Interfaces</h2>
|
||||
<p>All RSE validator interfaces and classes are in package <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/package-summary.html">org.eclipse.rse.ui.validators</A></samp>.
|
||||
|
||||
<h3>ISystemValidator Interface</h3>
|
||||
<p>The primary validator interface is <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html">ISystemValidator</A></samp>, which is extends <samp>org.eclipse.jface.dialogs.IInputValidator</samp>
|
||||
and <samp>org.eclipse.jface.viewers.ICellEditorValidator</samp>. Both parent interfaces define an <samp>isValid</samp> method,
|
||||
but the former takes a String while the latter takes an Object. They both return a String which is the error message if an
|
||||
error was detected, or null if no error detected. The <samp>ISystemValidator</samp> interface adds the following additional methods:
|
||||
</p>
|
||||
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Method</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public int <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#getMaximumNameLength()">getMaximumNameLength()</A></samp></TD>
|
||||
<TD>Returns the maximum length allowed for this text. Can be used to set text limit of text widgets.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public SystemMessage <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#getSystemMessage()">getSystemMessage()</A></samp></TD>
|
||||
<TD>If <samp>isValid</samp> returns false, this returns a <samp>SystemMessage</samp> object that offers richer message support than just a string.
|
||||
Return null if you don't support <samp><A href="../messages/uiMessageAPI.html">SystemMessages</A></samp>.
|
||||
Callers don't need to use this if they use <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#validate(java.lang.String)">validate(String)</A></samp> instead of <samp>isValid(String)</samp>.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public SystemMessage <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#validate(java.lang.String)">validate(String text)</A></samp></TD>
|
||||
<TD>An alternative to <samp>isValid</samp> if your validator does support <samp>SystemMessage</samp> objects versus simple strings for error messages.</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
|
||||
<h3>ISystemValidatorUniqueString Interface</h3>
|
||||
<p>Often our validation requires checking that the given text is unique, in some given list of existing things, like names say. To facilitate
|
||||
this, there is an interface <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidatorUniqueString.html">ISystemValidatorUniqueString</A></samp>, which extends <samp>ISystemValidator</samp> and adds some additional
|
||||
methods required for uniqueness validation:
|
||||
</p>
|
||||
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Method</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public void <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidatorUniqueString.html#setCaseSensitive(boolean)">setCaseSensitive(boolean caseSensitive)</A></samp></TD>
|
||||
<TD>Specifies whether the test for an existing string should consider case or not.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public void <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidatorUniqueString.html#setExistingNamesList(java.lang.String[])">setExistingNamesList(String[] existingList)</A></samp></TD>
|
||||
<TD>Sets the existing list to test against, as an array.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public void <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidatorUniqueString.html#setExistingNamesList(java.util.Vector)">setExistingNamesList(Vector existingList)</A></samp></TD>
|
||||
<TD>Sets the existing list to test against, as a vector of Strings.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp>public String[] <A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidatorUniqueString.html#getExistingNamesList()">getExistingNamesList()</A></samp></TD>
|
||||
<TD>Returns the existing list that is used to test against.</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<p>If you desire to create a unique string validator, you probably will start by subclassing <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUniqueString.html">ValidatorUniqueString</A></samp>.
|
||||
</p>
|
||||
|
||||
<h3>IValidatorRemoteSelection Interface</h3>
|
||||
<p>The third validator interface is <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/IValidatorRemoteSelection.html">IValidatorRemoteSelection</A></samp>, which is specifically intended to be used
|
||||
in the remote resource selection dialogs supplied by the RSE. It allows you to decide when to enable the OK button, based on what
|
||||
is selected. It contains only the following method:</p>
|
||||
<samp>public SystemMessage <A href="../../../reference/api/org/eclipse/rse/ui/validators/IValidatorRemoteSelection.html#isValid(org.eclipse.rse.core.model.IHost, java.lang.Object[], org.eclipse.rse.ui.view.ISystemRemoteElementAdapter[])">isValid(SystemConnection selectedConnection, Object[] selectedObjects, ISystemRemoteElementAdapter[] remoteAdaptersForSelectedObject)</A>;</samp>
|
||||
<p>You typically won't implement this interface directly, but rather sublcass <samp>ValidatorRemoteSelection</samp>.</p>
|
||||
|
||||
<h3>Validator Samples</h3>
|
||||
<ul>
|
||||
<li><A href="validatorSample1.html">Sample 1</A></li>
|
||||
<li><A href="validatorSample2.html">Sample 2</A></li>
|
||||
<li><A href="validatorSample3.html">Sample 3</A></li>
|
||||
<li><A href="validatorSample4.html">Sample 4</A></li>
|
||||
</ul>
|
||||
|
||||
<h2>RSE-Supplied Validators</h2>
|
||||
<p>You may be able to avoid creating a new validator if you find that RSE has already supplied one you need. Or, you may find it
|
||||
appropriate to simply subclass one of these RSE-supplied validators. All of them are designed to be either used as-is, or configured
|
||||
via setter calls, or subclassed, whichever is most convenient.</p>
|
||||
<p>All of these validators support rich <samp><A href="../messages/uiMessageAPI.html">SystemMessage</A></samp> objects, versus just simple strings for the error message. When used with the
|
||||
RSE dialog, property page or wizard page classes, you should call
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#validate(java.lang.String)">validate(String)</A></samp> and call
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/messages/ISystemMessageLine.html#setErrorMessage(org.eclipse.rse.ui.messages.SystemMessage)">setErrorMessage</A></samp> with the result. When used
|
||||
in other places you should use <samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ISystemValidator.html#isValid(java.lang.String)">isValid(String)</A></samp> as it returns just the first-level text of the system message.</p>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Validator Class</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorCompileCommandLabel.html">ValidatorCompileCommandLabel</A></samp></TD>
|
||||
<TD>Validates the label for a compile command in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorConnectionName.html">ValidatorConnectionName</A></samp></TD>
|
||||
<TD>Validates the name of a connection in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorFileName.html">ValidatorFileName</A></samp></TD>
|
||||
<TD>Validates the name of a file in eclipse.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorFilterName.html">ValidatorFilterName</A></samp></TD>
|
||||
<TD>Validates the name of a filter in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorFilterPoolName.html">ValidatorFilterPoolName</A></samp></TD>
|
||||
<TD>Validates the name of a filter pool in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorFilterString.html">ValidatorFilterString</A></samp></TD>
|
||||
<TD>Validates the contents of a filter string in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorFolderName.html">ValidatorFolderName</A></samp></TD>
|
||||
<TD>Validates the name of a folder in eclipse.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorIntegerInput.html">ValidatorIntegerInput</A></samp></TD>
|
||||
<TD>Validates the given string is a valid integer.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorIntegerRangeInput.html">ValidatorIntegerRangeInput</A></samp></TD>
|
||||
<TD>Validates the given string is a valid integer within a given range.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorLongInput.html">ValidatorLongInput</A></samp></TD>
|
||||
<TD>Validates the given string is a valid long integer.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorLongRangeInput.html">ValidatorLongRangeInput</A></samp></TD>
|
||||
<TD>Validates the given string is a valid long integer within a given range.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorPathName.html">ValidatorPathName</A></samp></TD>
|
||||
<TD>Validates the given string is a valid folder path in eclipse.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorPortInput.html">ValidatorPortInput</A></samp></TD>
|
||||
<TD>Validates the given string is a valid TCP/IP port number.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorProfileName.html">ValidatorProfileName</A></samp></TD>
|
||||
<TD>Validates the name of a system profile in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorRemoteSelection.html">ValidatorRemoteSelection</A></samp></TD>
|
||||
<TD>This is a very special case abstract base class, for validators that decide the enablement of the OK button
|
||||
in the RSE-supplied remote resource selection dialogs.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorSourceType.html">ValidatorSourceType</A></samp></TD>
|
||||
<TD>A validator for source types, such as a file type or "*.java". It is intended to be subclassed.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorSpecialChar.html">ValidatorSpecialChar</A></samp></TD>
|
||||
<TD>A base class for validators that need to ensure the given string doesn't contain certain characters.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorSystemName.html">ValidatorSystemName</A></samp></TD>
|
||||
<TD>A name validator, to be used when the name being prompted for must follow Java identifier rules.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUniqueString.html">ValidatorUniqueString</A></samp></TD>
|
||||
<TD>A base class, or configurable class, to be used for any validation that requires the string to be unique within a given list.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserActionCommand.html">ValidatorUserActionCommand</A></samp></TD>
|
||||
<TD>Validates the command of a user defined action in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserActionComment.html">ValidatorUserActionComment</A></samp></TD>
|
||||
<TD>Validates the comment of a user defined action in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserActionName.html">ValidatorUserActionName</A></samp></TD>
|
||||
<TD>Validates the name of a user defined action in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserId.html">ValidatorUserId</A></samp></TD>
|
||||
<TD>Validates a user ID. Does only basic checking, intended to be subclassed.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserTypeName.html">ValidatorUserTypeName</A></samp></TD>
|
||||
<TD>Validates the name of a named type in the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/validators/ValidatorUserTypeTypes.html">ValidatorUserTypeTypes</A></samp></TD>
|
||||
<TD>Validates the type list of a named type in the RSE.</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
|
||||
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,97 +0,0 @@
|
|||
<!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>RSE Validator Sample One</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Validator Sample One</h1>
|
||||
<p>This is an example of a validator written from scratch, that just validates a customer name field is not empty.
|
||||
Note that while that is all is does today, the power of encapsulation is that we can easily add additional error
|
||||
checking in the future, and all dialogs or wizards that use the validator will pick up that change.
|
||||
<pre>
|
||||
|
||||
package org.eclipse.rse.samples.ui.frameworks.dialogs;
|
||||
import org.eclipse.rse.samples.*;
|
||||
import org.eclipse.rse.ui.messages.SystemMessage;
|
||||
import org.eclipse.rse.ui.validators.ISystemValidator;
|
||||
|
||||
/**
|
||||
* <I>A validator for a customer name. We simply ensure it is not empty, but this could easily be expanded.</I>
|
||||
*/
|
||||
public class <B>SampleNameValidator</B> implements ISystemValidator
|
||||
{
|
||||
private SystemMessage currentMsg;
|
||||
private SystemMessage emptyMsg;
|
||||
|
||||
/**
|
||||
* <I>Constructor for SampleNameValidator.</I>
|
||||
*/
|
||||
public <B>SampleNameValidator</B>()
|
||||
{
|
||||
super();
|
||||
emptyMsg = SamplesPlugin.<A
|
||||
href="../messages/uiMessageAPI.html#getPluginMessage">getPluginMessage</A>(<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1000">"SPPD1000"</A>);
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Required ISystemValidator interface method.</I>
|
||||
* <I>Return the maximum length for customer names. We return 100.</I>
|
||||
*/
|
||||
public int <B>getMaximumNameLength</B>()
|
||||
{
|
||||
return 100;
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Required ISystemValidator interface method.</I>
|
||||
* <I>@see org.eclipse.rse.ui.validators.ISystemValidator#getSystemMessage()</I>
|
||||
*/
|
||||
public SystemMessage <B>getSystemMessage</B>()
|
||||
{
|
||||
return currentMsg;
|
||||
}
|
||||
|
||||
/**
|
||||
* <I>Required ISystemValidator interface method.</I>
|
||||
* <I>@see org.eclipse.rse.ui.validators.ISystemValidator#validate(String)</I>
|
||||
*/
|
||||
public SystemMessage <B>validate</B>(String text)
|
||||
{
|
||||
isValid(text);
|
||||
return currentMsg;
|
||||
}
|
||||
/**
|
||||
* <I>@see org.eclipse.jface.dialogs.IInputValidator#isValid(String)</I>
|
||||
*/
|
||||
public String <B>isValid</B>(String newText)
|
||||
{
|
||||
if ((newText==null) || (newText.length()==0))
|
||||
currentMsg = emptyMsg;
|
||||
// todo: more error checking
|
||||
|
||||
if (currentMsg != null)
|
||||
return currentMsg.getLevelOneText();
|
||||
else
|
||||
return null;
|
||||
}
|
||||
/**
|
||||
* <I>@see org.eclipse.jface.viewers.ICellEditorValidator#isValid(Object)</I>
|
||||
*/
|
||||
public String <B>isValid</B>(Object value)
|
||||
{
|
||||
if (value instanceof String)
|
||||
return isValid((String)value);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
</pre>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,45 +0,0 @@
|
|||
<!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>RSE Validator Sample Two</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Validator Sample Two</h1>
|
||||
<p>This is an example of a validator written by extending an existing RSE-supplied validator, and
|
||||
simply supplying unique messages.
|
||||
<pre>
|
||||
|
||||
package org.eclipse.rse.samples.ui.frameworks.dialogs;
|
||||
import org.eclipse.rse.ui.validators.ValidatorIntegerRangeInput;
|
||||
import org.eclipse.rse.samples.*;
|
||||
|
||||
/**
|
||||
* <I>An example of a customized validator, that prompts for a birth year.</I>
|
||||
*/
|
||||
public class <B>SampleBirthYearValidator</B> extends ValidatorIntegerRangeInput
|
||||
{
|
||||
/**
|
||||
* <I>Constructor. Specifies the valid range, and unique error messages.</I>
|
||||
*/
|
||||
public SampleBirthYearValidator()
|
||||
{
|
||||
super(1900, 2003);
|
||||
super.setErrorMessages(SamplesPlugin.<A
|
||||
href="../messages/uiMessageAPI.html#getPluginMessage">getPluginMessage</A>("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1001">SPPD1001</A>"), // <I>empty</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1002">SPPD1002</A>"), // <I>non-numeric</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1003">SPPD1003</A>")); // <I>out of range</I>
|
||||
}
|
||||
|
||||
}</pre>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,43 +0,0 @@
|
|||
<!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>RSE Validator Sample Three</title></head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Validator Sample Three</h1>
|
||||
<p>This is an example of a validator written by extending an existing RSE-supplied validator, and
|
||||
simply supplying unique messages.
|
||||
<pre>
|
||||
package org.eclipse.rse.samples.ui.frameworks.dialogs;
|
||||
import org.eclipse.rse.ui.validators.ValidatorIntegerRangeInput;
|
||||
import org.eclipse.rse.samples.*;
|
||||
|
||||
/**
|
||||
* <I>An example of a customized validator, that prompts for a birth month.</I>
|
||||
*/
|
||||
public class <B>SampleBirthMonthValidator</B> extends ValidatorIntegerRangeInput
|
||||
{
|
||||
/**
|
||||
* <I>Constructor. Specifies the valid range, and unique error messages.</I>
|
||||
*/
|
||||
public SampleBirthMonthValidator()
|
||||
{
|
||||
super(1, 12);
|
||||
super.setErrorMessages(SamplesPlugin.<A
|
||||
href="../messages/uiMessageAPI.html#getPluginMessage">getPluginMessage</A>("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1004">SPPD1004</A>"), // <I>empty</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1005">SPPD1005</A>"), // <I>non-numeric</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1006">SPPD1006</A>")); // <I>out of range</I>
|
||||
}
|
||||
|
||||
}</pre>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,44 +0,0 @@
|
|||
<!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>RSE Validator Sample Four</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Validator Sample Four</h1>
|
||||
<p>This is an example of a validator written by extending an existing RSE-supplied validator, and
|
||||
simply supplying unique messages.
|
||||
<pre>
|
||||
package org.eclipse.rse.samples.ui.frameworks.dialogs;
|
||||
import org.eclipse.rse.core.ui.validators.ValidatorIntegerRangeInput;
|
||||
import org.eclipse.rse.samples.*;
|
||||
|
||||
/**
|
||||
* <I>An example of a customized validator, that prompts for a birth day.</I>
|
||||
*/
|
||||
public class <B>SampleBirthDayValidator</B> extends ValidatorIntegerRangeInput
|
||||
{
|
||||
/**
|
||||
* <I>Constructor. Specifies the valid range, and unique error messages</I>.
|
||||
*/
|
||||
public SampleBirthDayValidator()
|
||||
{
|
||||
super(1, 31);
|
||||
super.setErrorMessages(SamplesPlugin.<A
|
||||
href="../messages/uiMessageAPI.html#getPluginMessage">getPluginMessage</A>("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1007">SPPD1007</A>"), // <I>empty</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1008">SPPD1008</A>"), // <I>non-numeric</I>
|
||||
SamplesPlugin.getPluginMessage("<A
|
||||
href="../messages/sampleMessageFile.html#SPPD1009">SPPD1009</A>")); // <I>out of range</I>
|
||||
}
|
||||
|
||||
}</pre>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,73 +0,0 @@
|
|||
<!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>RSE Widgets API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
|
||||
<h1>RSE Widgets API</h1>
|
||||
<p>Whether coding dialogs, property pages, preference pages or wizard pages we need to write the code to display
|
||||
and process the widgets in the client area. The RSE offers some help in this area in two ways:
|
||||
</p>
|
||||
<ol>
|
||||
<li>A <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemWidgetHelpers.html">SystemWidgetHelpers</A></samp>
|
||||
class full of static methods to make it easier to create SWT widgets.
|
||||
<li>A few re-usable widgets that extend SWT.
|
||||
</ol>
|
||||
|
||||
<h2>SystemWidgetHelpers Class</h2>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/SystemWidgetHelpers.html">SystemWidgetHelpers</A></samp>
|
||||
class in <samp><A href="../../../reference/api/org/eclipse/rse/ui/package-summary.html">org.eclipse.rse.ui</A></samp>
|
||||
is chock full of static methods to simplify the work in populating a GridLayout composite with widgets. The GridLayout composite is the most
|
||||
flexible and useful of the layouts, yet the most work to code to. These methods will help with that. The methods include:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Methods for creating a GridLayout composite. You typically call this at the start of your code that populates the client area.
|
||||
<li>Methods for creating all the common SWT controls, with the GridData values specified for you.
|
||||
<li>Methods for creating readonly flavours of input controls, such as a Text field or Combo box.
|
||||
<li>Methods for creating labeled entry fields that have a prompting label in front of an input widget.
|
||||
<li>Methods for automatically assigning unique mnemonics to all input widgets on a given composite or page.
|
||||
<li>Methods for setting composite, widget, action and menu item contextual help.
|
||||
<li>Methods for creating RSE-supplied widgets.
|
||||
<li>Methods for creating populated combo boxes for connections, remote folders, system types and host names.
|
||||
</ul>
|
||||
|
||||
<h2>RSE-Supplied Widgets</h2>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/widgets/package-summary.html">org.eclipse.rse.ui.widgets</A></samp>
|
||||
package contains some specialized widgets you may find a use for:
|
||||
</p>
|
||||
<TABLE border="1">
|
||||
<TBODY>
|
||||
<TR>
|
||||
<TH>Widget Class</TH>
|
||||
<TH>Description</TH>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/widgets/SystemHistoryCombo.html">SystemHistoryCombo</A></samp></TD>
|
||||
<TD>A entry field that remembers its previous values and shows them in a dropdown so the user can easily re-select a previously typed value. The history is maintained for you, and is indexed by a key. This allows the combos to share history across numerous dialogs, property pages or wizard pages. The history can be bounded and pre-filled, and the user can clear the history at any time. This handy widget is used extensively within the RSE.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/widgets/InheritableEntryField.html">InheritableEntryField</A></samp></TD>
|
||||
<TD>An entry field with an left-right arrow beside it. When toggled left, the entry field is not editable and displays a supplied value. When toggled right, the entry field is editable. Useful in cases where the user can choose between an inherited or default value, or enter their own value.</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/widgets/SystemPortPrompt.html">SystemPortPrompt</A></samp></TD>
|
||||
<TD>Uses the InheritableEntryField to prompt for a TCP/IP port, where toggling to the left means port 0, or let the "first available port".</TD>
|
||||
</TR>
|
||||
<TR>
|
||||
<TD><samp><A href="../../../reference/api/org/eclipse/rse/ui/widgets/SystemHostCombo.html">SystemHostCombo</A></samp></TD>
|
||||
<TD>This is a combo box that displays the currently defined RSE system connections. The list can be subset by system type or types. Further, you can optionally display a New button beside the combo that allows the user to create a new connection.</TD>
|
||||
</TR>
|
||||
</TBODY>
|
||||
</TABLE>
|
||||
<p>There are also many useful widgets related to the selection of remote files or folders, in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/files/ui/widgets/package-summary.html">org.eclipse.rse.files.ui.widgets</A></samp>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
|
@ -1,74 +0,0 @@
|
|||
<!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>RSE Wizards API</title>
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
<h1>RSE Wizards API</h1>
|
||||
<p>Typically in eclipse GUI design we use a wizard to create new things, and a dialog
|
||||
to prompt for secondary information, or update existing things. The Remote System Explorer
|
||||
can offer help in creating wizards, just as it does in creating dialogs.
|
||||
</p>
|
||||
|
||||
<h2>RSE-Supplied Base Classes for Wizards</h2>
|
||||
<p>The RSE offers the following classes, in package
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/package-summary.html">org.eclipse.rse.ui.wizards</A></samp> to simplify the creation of wizards.</p>
|
||||
|
||||
<h3>The <samp>AbstractSystemWizardPage</samp> class</h3>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html">AbstractSystemWizardPage</A></samp> abstract base class extends the
|
||||
JFace <samp>WizardPage</samp> class to offer the following benefits to subclasses:</p>
|
||||
<ol>
|
||||
<li>Designed to work in conjunction with <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html">AbstractSystemWizard</A></samp>,
|
||||
propogating settings from the wizard to the individual wizard pages.
|
||||
<li>Supports using the overall wizard page title as set
|
||||
by <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#setWizardPageTitle(java.lang.String)">setWizardPageTitle(String)</A></samp>
|
||||
in <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html">AbstractSystemWizard</A></samp>,
|
||||
if no title specified in the constructor.
|
||||
<li>Supports a <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html#setHelp(java.lang.String)">setHelp(String)</A></samp> method to set the wizard page's overall contextual help
|
||||
<li>Implements <samp><A
|
||||
href="../messages/uiMessageAPI.html#ISystemMessageLine">ISystemMessageLine</A></samp> so supports setting error messages as
|
||||
either strings or, preferably, <samp><A
|
||||
href="../messages/uiMessageAPI.html#SystemMessage">SystemMessage</A></samp> objects.
|
||||
<li>Supports automatic assignment of unique mnemonics for all input-capable controls on the page, to aid in accessibility.
|
||||
<li>Supports setting a default-focus control, which gets initial focus when the page is shown.
|
||||
<li>Supports helper methods to aid in population of the client area:
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html#addSeparatorLine(org.eclipse.swt.widgets.Composite, int)">addSeparatorLine(Composite,int)</A></samp>,
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html#addFillerLine(org.eclipse.swt.widgets.Composite, int)">addFillerLine(Composite,int)</A></samp> and
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html#addGrowableFillerLine(org.eclipse.swt.widgets.Composite, int)">addGrowableFillerLine(Composite,int)</A></samp>.
|
||||
</ol>
|
||||
|
||||
|
||||
<h3><A name="AbstractSystemWizard"></A>The <samp>AbstractSystemWizard</samp> class</h3>
|
||||
<p>The <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html">AbstractSystemWizard</A></samp> abstract base class extends the JFace <samp>Wizard</samp>
|
||||
class to offer the following benefits to subclasses:</p>
|
||||
<ol>
|
||||
<li>Designed to work in conjunction with the <samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseWizardAction.html">SystemBaseWizardAction</A></samp>,
|
||||
and <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemWizardDialog.html">SystemWizardDialog</A></samp> classes, propogating settings
|
||||
from these to the wizard, and further propogating those to the individual wizard pages.
|
||||
<li>The overall wizard title and image can be set via the constructor or setter methods.
|
||||
<li>Supports setting an input object, and getting an output object. This is exploited by the
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/actions/SystemBaseWizardAction.html">SystemBaseWizardAction</A></samp> class, when this wizard is launched from a subclass of that action class.
|
||||
<li>Supports setting a wizard page title via <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#setWizardPageTitle(java.lang.String)">setWizardPageTitle(String)</A></samp>, that all
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html">AbstractSystemWizardPage</A></samp> pages will use by default for
|
||||
their title, if the non-title constructor is used for that page.
|
||||
<li>If being hosted by a <samp><A href="../../../reference/api/org/eclipse/rse/ui/dialogs/SystemWizardDialog.html">SystemWizardDialog</A></samp>, supports dynamically
|
||||
updating the wizard size via <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#updateSize()">updateSize()</A></samp>,
|
||||
if dynamic content is added to a wizard page, causing the page to grow beyond its initial size.
|
||||
<li>Supports a <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#setHelp(java.lang.String)">setHelp(String)</A></samp> method to set the overall wizard's contextual help. This is propogated to each
|
||||
<samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizardPage.html">AbstractSystemWizardPage</A></samp> as it is added.
|
||||
<li>Supports setting the viewer that launched this wizard, as wizards often need to know this so they can update the UI upon Finish.
|
||||
<li>Supports a <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#wasCancelled()">wasCancelled()</A></samp> method so callers can easily test if the wizard was cancelled by the user.
|
||||
<li>Supports a <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#setMinimumPageSize(int, int)">setMinimumPageSize(int,int)</A></samp> method to set the minimum width and height of the wizard.
|
||||
<li>Supports a <samp><A href="../../../reference/api/org/eclipse/rse/ui/wizards/AbstractSystemWizard.html#setPageError(org.eclipse.jface.wizard.IWizardPage)">setPageError(IWizardPage)</A></samp> method that can be called in performFinish when an error is detected on a
|
||||
non-current page. This issues a message telling the user there is an error on another page.
|
||||
</ol>
|
||||
|
||||
<P><BR></P>
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 5.9 KiB |
Before Width: | Height: | Size: 24 KiB |
Before Width: | Height: | Size: 3.2 KiB |
|
@ -1,14 +0,0 @@
|
|||
<!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">
|
||||
<title>Remote System Explorer Overview</title>
|
||||
<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" type="text/css" HREF="../book.css">
|
||||
</head>
|
||||
|
||||
<body bgcolor="#ffffff">
|
||||
</body>
|
||||
</html>
|
Before Width: | Height: | Size: 8.7 KiB |
Before Width: | Height: | Size: 8.8 KiB |
Before Width: | Height: | Size: 6.8 KiB |
Before Width: | Height: | Size: 7.4 KiB |
|
@ -1,196 +0,0 @@
|
|||
<!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, 2007. 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><a name="viewActions"></a>
|
||||
<samp><a href="../../../org.eclipse.platform.doc.isv/guide/workbench_basicext_viewActions.htm">org.eclipse.ui.viewActions</a></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><a name="property"></a>
|
||||
<samp>
|
||||
<!-- a href="../../../org.eclipse.platform.doc.isv/guide/preferences_prop_contribute.htm" -->
|
||||
<a href="propertypage.html">
|
||||
org.eclipse.ui.propertyPages</a></samp></TD>
|
||||
<TD>For adding property pages for 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/core/model/IHost.html">org.eclipse.rse.core.model.IHost</A></samp></li>
|
||||
<li>SubSystems: <samp><A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">org.eclipse.rse.core.subsystems.ISubSystem</A></samp></li>
|
||||
<li>Filter Pools: <samp><A href="../../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolReference.html">org.eclipse.rse.core.filters.ISystemFilterPoolReference</A></samp></li>
|
||||
<li>Filters: <samp><A href="../../reference/api/org/eclipse/rse/core/filters/ISystemFilterReference.html">org.eclipse.rse.core.filters.ISystemFilterReference</A></samp></li>
|
||||
<li>Remote Elements: your model objects, which are adaptable to <samp>ISystemViewElementAdapter</samp>.
|
||||
For the RSE-provided reusable file, process and shell subsystems, these are
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFile.html">IRemoteFile</a></samp>,
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/processes/core/subsystem/IRemoteProcess.html">IRemoteProcess</a></samp> and
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteCommandShell.html">IRemoteCommandShell</a></samp>, respectively.
|
||||
In the Remote Command View, you'll also find
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteError.html">IRemoteError</a></samp> and
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteOutput.html">IRemoteOutput</a></samp>.
|
||||
</li>
|
||||
</ul>
|
||||
Because all RSE elements adapt to
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/ui/view/ISystemViewElementAdapter.html">ISystemViewElementAdapter</A></samp>,
|
||||
which in turn implements
|
||||
<samp><A href="../../../org.eclipse.platform.doc.isv/reference/api/org/eclipse/ui/IActionFilter.html">org.eclipse.ui.IActionFilter</A></samp>,
|
||||
it is possible to scope your property pages to only appear for certain system types or subsystems, using
|
||||
the extension point's <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.core.filters.ISystemFilterReference" >
|
||||
<b><filter name="subsystemConfigurationId" 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><a name="popup"></a>
|
||||
<samp>
|
||||
<!-- a href="../../../org.eclipse.platform.doc.isv/guide/workbench_basicext_popupMenus.htm" -->
|
||||
<a href="popup.html">
|
||||
org.eclipse.ui.popupMenus</a></samp>
|
||||
</TD>
|
||||
<TD>For adding pop-up menu actions for 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/core/model/IHost.html">org.eclipse.rse.core.model.IHost</A></samp></li>
|
||||
<li>SubSystems: <samp><A href="../../reference/api/org/eclipse/rse/core/subsystems/ISubSystem.html">org.eclipse.rse.core.subsystems.ISubSystem</A></samp></li>
|
||||
<li>Filter Pools: <samp><A href="../../reference/api/org/eclipse/rse/core/filters/ISystemFilterPoolReference.html">org.eclipse.rse.core.filters.ISystemFilterPoolReference</A></samp></li>
|
||||
<li>Filters: <samp><A href="../../reference/api/org/eclipse/rse/core/filters/ISystemFilterReference.html">org.eclipse.rse.core.filters.ISystemFilterReference</A></samp></li>
|
||||
<li>Remote Elements: your model objects, which are adaptable to <samp>ISystemViewElementAdapter</samp>.
|
||||
For the RSE-provided reusable file, process and shell subsystems, these are
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/files/core/subsystems/IRemoteFile.html">IRemoteFile</a></samp>,
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/processes/core/subsystem/IRemoteProcess.html">IRemoteProcess</a></samp> and
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteCommandShell.html">IRemoteCommandShell</a></samp>, respectively.
|
||||
In the Remote Command View, you'll also find
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteError.html">IRemoteError</a></samp> and
|
||||
<samp><a href="../../reference/api/org/eclipse/rse/subsystems/shells/core/subsystems/IRemoteOutput.html">IRemoteOutput</a></samp>.
|
||||
</li>
|
||||
</ul>
|
||||
Because all RSE elements adapt to
|
||||
<samp><A href="../../reference/api/org/eclipse/rse/ui/view/ISystemViewElementAdapter.html">ISystemViewElementAdapter</A></samp>,
|
||||
which in turn extends
|
||||
<samp><A href="../../../org.eclipse.platform.doc.isv/reference/api/org/eclipse/ui/IActionFilter.html">org.eclipse.ui.IActionFilter</A></samp>,
|
||||
it is possible to scope your actions to only appear for certain system types or subsystems, using
|
||||
the extension point's <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.core.filters.ISystemFilterReference">
|
||||
<b><filter name="subsystemConfigurationId" 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>"subsystemConfigurationId"</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>"subsystemConfigurationCategory"</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.core.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>
|