Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/.project17
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/build.properties6
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/epl-v10.html304
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/feature.properties142
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/feature.xml40
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/license.html79
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/rootfiles/epl-v10.html304
-rwxr-xr-xplugins/org.eclipse.jet.all-feature/rootfiles/notice.html86
-rw-r--r--plugins/org.eclipse.jet.editor-feature/.project17
-rw-r--r--plugins/org.eclipse.jet.editor-feature/build.properties4
-rw-r--r--plugins/org.eclipse.jet.editor-feature/epl-v10.html304
-rw-r--r--plugins/org.eclipse.jet.editor-feature/feature.properties141
-rw-r--r--plugins/org.eclipse.jet.editor-feature/feature.xml45
-rw-r--r--plugins/org.eclipse.jet.editor-feature/license.html79
-rw-r--r--plugins/org.eclipse.jet.editor-feature/rootfiles/epl-v10.html304
-rw-r--r--plugins/org.eclipse.jet.editor-feature/rootfiles/notice.html86
-rw-r--r--plugins/org.eclipse.jet.editor/.classpath7
-rw-r--r--plugins/org.eclipse.jet.editor/.cvsignore1
-rw-r--r--plugins/org.eclipse.jet.editor/.jetproperties4
-rw-r--r--plugins/org.eclipse.jet.editor/.project34
-rw-r--r--plugins/org.eclipse.jet.editor/.settings/org.eclipse.jdt.core.prefs12
-rw-r--r--plugins/org.eclipse.jet.editor/META-INF/MANIFEST.MF33
-rw-r--r--plugins/org.eclipse.jet.editor/ModelingFeature.pngbin2414 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/about.html29
-rw-r--r--plugins/org.eclipse.jet.editor/about.ini28
-rw-r--r--plugins/org.eclipse.jet.editor/about.mappings6
-rw-r--r--plugins/org.eclipse.jet.editor/about.properties23
-rw-r--r--plugins/org.eclipse.jet.editor/build.properties12
-rw-r--r--plugins/org.eclipse.jet.editor/icons/full/ctool16/JETFileWizard.gifbin1006 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/icons/full/ctool16/JETProjectWizard.gifbin597 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/icons/full/obj16/JETTemplateFile.gifbin968 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/icons/full/wizban/JETProjectWizard.gifbin597 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/icons/sample.gifbin983 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.editor/plugin.properties4
-rw-r--r--plugins/org.eclipse.jet.editor/plugin.xml60
-rw-r--r--plugins/org.eclipse.jet.editor/schema/defaultContentColorerDelegates.exsd105
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/Activator.java82
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETDocumentReader.java79
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditor.java140
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditorHelper.java455
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETSourceViewer.java106
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextEditor.java449
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextPreviewViewer.java203
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/actions/SetContentColorerAction.java75
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationHover.java140
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationModel.java64
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETProblemAnnotation.java33
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/autoedit/JETTemplateAutoEditStrategy.java276
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/DoubleClickStrategy.java122
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/IJETColorConstants.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETDocumentProvider.java60
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETEditorPreferenceConstants.java105
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETReconcilingStrategy.java111
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETSourceViewerConfiguration.java122
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETTokenStyleManager.java160
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETWhitespaceDetector.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/NonRuleBasedDamagerRepairer.java148
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/IJETDefaultTextColorerDelegate.java21
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/java/JavaContentPartitionConfigurationDelegate.java123
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/xml/XMLContentPartitionConfigurationDelegate.java166
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractJETAssistProcessor.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractXMLTagsBasedAssistProcessor.java165
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETCustomTagAssistProcessor.java110
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETDirectiveAssistProcessor.java55
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaDeclarationAssistProcessor.java86
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaExpressionAssistProcessor.java93
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaScriptletAssistProcessor.java87
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETTagAssistProcessor.java57
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETCustomTagFormattingStrategy.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETDirectiveFormattingStrategy.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaDeclarationFormattingStrategy.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaExpressionFormattingStrategy.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaScriptletFormattingStrategy.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/i18n/TextEditorMessages.properties1
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineContentProvider.java187
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineLabelProvider.java155
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlinePage.java47
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/ITokenScannerProvider.java18
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/JETDocumentPartitionScanner.java375
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/PartitionScannerBasedDamagerRepairer.java151
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTElementScannerRule.java52
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCommentRule.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCustomTagRule.java28
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETDirectiveRule.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaDeclarationRule.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaExpressionRule.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaScriptletRule.java27
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETBracketRule.java76
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCommentRule.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCustomTagRule.java88
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETDirectiveRule.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaDeclarationRule.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaExpressionRule.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaScriptletRule.java20
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/WordListDetectorRule.java55
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCommentScanner.java29
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCustomTagScanner.java79
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDefaultContentScanner.java22
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDirectiveScanner.java71
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaCodeScanner.java251
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaDeclarationScanner.java44
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaExpressionScanner.java51
-rw-r--r--plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaScriptletScanner.java45
-rw-r--r--plugins/org.eclipse.jet.ui/.classpath7
-rw-r--r--plugins/org.eclipse.jet.ui/.cvsignore3
-rw-r--r--plugins/org.eclipse.jet.ui/.project28
-rw-r--r--plugins/org.eclipse.jet.ui/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--plugins/org.eclipse.jet.ui/.settings/org.eclipse.jdt.core.prefs70
-rw-r--r--plugins/org.eclipse.jet.ui/META-INF/MANIFEST.MF27
-rw-r--r--plugins/org.eclipse.jet.ui/NewJETProject.p1.wzPage.xml42
-rw-r--r--plugins/org.eclipse.jet.ui/NewJETProject.p2.wzPage.xml72
-rw-r--r--plugins/org.eclipse.jet.ui/about.html29
-rw-r--r--plugins/org.eclipse.jet.ui/build.properties19
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JET2File.gifbin920 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JET2LaunchIcon.gifbin920 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JET2Project.gifbin971 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JET2ProjectWizard.gifbin597 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JET2ProjectWizardBanner.gifbin3180 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/JETRuntimeError.gifbin949 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/icons/sample.gifbin983 -> 0 bytes
-rw-r--r--plugins/org.eclipse.jet.ui/plugin.properties40
-rw-r--r--plugins/org.eclipse.jet.ui/plugin.xml137
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/filters/JavaFilter.java77
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/Messages.java129
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/messages.properties66
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JET2TransformationTabGroup.java48
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETConsoleColorProvider.java125
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETLaunchHelper.java311
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETTransformMainTab.java402
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/LaunchShortcut.java70
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/popup/actions/UnloadAction.java91
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/CompilePreferencePage.java313
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/ExtensionListEditor.java70
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/JETPreferencePage.java84
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/Activator.java82
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/Messages.java42
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1.java139
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1Controls.java183
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2.java169
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2Controls.java265
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectInfo.java109
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectWizard.java171
-rw-r--r--plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/messages.properties19
143 files changed, 0 insertions, 12005 deletions
diff --git a/plugins/org.eclipse.jet.all-feature/.project b/plugins/org.eclipse.jet.all-feature/.project
deleted file mode 100755
index 940e181..0000000
--- a/plugins/org.eclipse.jet.all-feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jet.all-feature</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.pde.FeatureBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.FeatureNature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/org.eclipse.jet.all-feature/build.properties b/plugins/org.eclipse.jet.all-feature/build.properties
deleted file mode 100755
index 5049b52..0000000
--- a/plugins/org.eclipse.jet.all-feature/build.properties
+++ /dev/null
@@ -1,6 +0,0 @@
-# NLS_MESSAGEFORMAT_VAR
-bin.includes = feature.xml,\
- license.html,\
- feature.properties,\
- epl-v10.html
-root=rootfiles
diff --git a/plugins/org.eclipse.jet.all-feature/epl-v10.html b/plugins/org.eclipse.jet.all-feature/epl-v10.html
deleted file mode 100755
index cb1073a..0000000
--- a/plugins/org.eclipse.jet.all-feature/epl-v10.html
+++ /dev/null
@@ -1,304 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html xmlns:o="urn:schemas-microsoft-com:office:office"
-xmlns:w="urn:schemas-microsoft-com:office:word"
-xmlns="http://www.w3.org/TR/REC-html40">
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-font-pitch:variable;
- mso-font-signature:553679495 -2147483648 8 0 66047 0;}
- /* Style Definitions */
-p.MsoNormal, li.MsoNormal, div.MsoNormal
- {mso-style-parent:"";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p
- {margin-right:0in;
- mso-margin-top-alt:auto;
- mso-margin-bottom-alt:auto;
- margin-left:0in;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
-
- }
-@page Section1
- {size:8.5in 11.0in;
- margin:1.0in 1.25in 1.0in 1.25in;
- mso-header-margin:.5in;
- mso-footer-margin:.5in;
- mso-paper-source:0;}
-div.Section1
- {page:Section1;}
--->
-</style>
-</head>
-
-<body lang="EN-US" style='tab-interval:.5in'>
-
-<div class=Section1>
-
-<p align=center style='text-align:center'><b>Eclipse Public License - v 1.0</b>
-</p>
-
-<p><span style='font-size:10.0pt'>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER
-THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE,
-REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>1. DEFINITIONS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Contribution&quot; means:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-in the case of the initial Contributor, the initial code and documentation
-distributed under this Agreement, and<br clear=left>
-b) in the case of each subsequent Contributor:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-changes to the Program, and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-additions to the Program;</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>where
-such changes and/or additions to the Program originate from and are distributed
-by that particular Contributor. A Contribution 'originates' from a Contributor
-if it was added to the Program by such Contributor itself or anyone acting on
-such Contributor's behalf. Contributions do not include additions to the
-Program which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii) are not derivative
-works of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Contributor&quot; means any person or
-entity that distributes the Program.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Licensed Patents &quot; mean patent
-claims licensable by a Contributor which are necessarily infringed by the use
-or sale of its Contribution alone or when combined with the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Program&quot; means the Contributions
-distributed in accordance with this Agreement.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Recipient&quot; means anyone who
-receives the Program under this Agreement, including all Contributors.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>2. GRANT OF RIGHTS</span></b> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-Subject to the terms of this Agreement, each Contributor hereby grants Recipient
-a non-exclusive, worldwide, royalty-free copyright license to<span
-style='color:red'> </span>reproduce, prepare derivative works of, publicly
-display, publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and object code
-form.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-Subject to the terms of this Agreement, each Contributor hereby grants
-Recipient a non-exclusive, worldwide,<span style='color:green'> </span>royalty-free
-patent license under Licensed Patents to make, use, sell, offer to sell, import
-and otherwise transfer the Contribution of such Contributor, if any, in source
-code and object code form. This patent license shall apply to the combination
-of the Contribution and the Program if, at the time the Contribution is added
-by the Contributor, such addition of the Contribution causes such combination
-to be covered by the Licensed Patents. The patent license shall not apply to
-any other combinations which include the Contribution. No hardware per se is
-licensed hereunder. </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>c)
-Recipient understands that although each Contributor grants the licenses to its
-Contributions set forth herein, no assurances are provided by any Contributor
-that the Program does not infringe the patent or other intellectual property
-rights of any other entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement of intellectual
-property rights or otherwise. As a condition to exercising the rights and
-licenses granted hereunder, each Recipient hereby assumes sole responsibility
-to secure any other intellectual property rights needed, if any. For example,
-if a third party patent license is required to allow Recipient to distribute
-the Program, it is Recipient's responsibility to acquire that license before
-distributing the Program.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>d)
-Each Contributor represents that to its knowledge it has sufficient copyright
-rights in its Contribution, if any, to grant the copyright license set forth in
-this Agreement. </span></p>
-
-<p><b><span style='font-size:10.0pt'>3. REQUIREMENTS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>A Contributor may choose to distribute the
-Program in object code form under its own license agreement, provided that:</span>
-</p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it complies with the terms and conditions of this Agreement; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-its license agreement:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-effectively disclaims on behalf of all Contributors all warranties and
-conditions, express and implied, including warranties or conditions of title
-and non-infringement, and implied warranties or conditions of merchantability
-and fitness for a particular purpose; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-effectively excludes on behalf of all Contributors all liability for damages,
-including direct, indirect, special, incidental and consequential damages, such
-as lost profits; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iii)
-states that any provisions which differ from this Agreement are offered by that
-Contributor alone and not by any other party; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iv)
-states that source code for the Program is available from such Contributor, and
-informs licensees how to obtain it in a reasonable manner on or through a
-medium customarily used for software exchange.<span style='color:blue'> </span></span></p>
-
-<p><span style='font-size:10.0pt'>When the Program is made available in source
-code form:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it must be made available under this Agreement; and </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b) a
-copy of this Agreement must be included with each copy of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Contributors may not remove or alter any
-copyright notices contained within the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Each Contributor must identify itself as the
-originator of its Contribution, if any, in a manner that reasonably allows
-subsequent Recipients to identify the originator of the Contribution. </span></p>
-
-<p><b><span style='font-size:10.0pt'>4. COMMERCIAL DISTRIBUTION</span></b> </p>
-
-<p><span style='font-size:10.0pt'>Commercial distributors of software may
-accept certain responsibilities with respect to end users, business partners
-and the like. While this license is intended to facilitate the commercial use
-of the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create potential
-liability for other Contributors. Therefore, if a Contributor includes the
-Program in a commercial product offering, such Contributor (&quot;Commercial
-Contributor&quot;) hereby agrees to defend and indemnify every other
-Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and
-costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified Contributor to
-the extent caused by the acts or omissions of such Commercial Contributor in
-connection with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any claims or Losses
-relating to any actual or alleged intellectual property infringement. In order
-to qualify, an Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial Contributor
-to control, and cooperate with the Commercial Contributor in, the defense and
-any related settlement negotiations. The Indemnified Contributor may participate
-in any such claim at its own expense.</span> </p>
-
-<p><span style='font-size:10.0pt'>For example, a Contributor might include the
-Program in a commercial product offering, Product X. That Contributor is then a
-Commercial Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance claims and
-warranties are such Commercial Contributor's responsibility alone. Under this
-section, the Commercial Contributor would have to defend claims against the
-other Contributors related to those performance claims and warranties, and if a
-court requires any other Contributor to pay any damages as a result, the
-Commercial Contributor must pay those damages.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>5. NO WARRANTY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING,
-WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and distributing the
-Program and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program errors,
-compliance with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations. </span></p>
-
-<p><b><span style='font-size:10.0pt'>6. DISCLAIMER OF LIABILITY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF
-THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF
-THE POSSIBILITY OF SUCH DAMAGES.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>7. GENERAL</span></b> </p>
-
-<p><span style='font-size:10.0pt'>If any provision of this Agreement is invalid
-or unenforceable under applicable law, it shall not affect the validity or
-enforceability of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be reformed to the
-minimum extent necessary to make such provision valid and enforceable.</span> </p>
-
-<p><span style='font-size:10.0pt'>If Recipient institutes patent litigation
-against any entity (including a cross-claim or counterclaim in a lawsuit)
-alleging that the Program itself (excluding combinations of the Program with
-other software or hardware) infringes such Recipient's patent(s), then such
-Recipient's rights granted under Section 2(b) shall terminate as of the date
-such litigation is filed. </span></p>
-
-<p><span style='font-size:10.0pt'>All Recipient's rights under this Agreement
-shall terminate if it fails to comply with any of the material terms or
-conditions of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If all Recipient's
-rights under this Agreement terminate, Recipient agrees to cease use and
-distribution of the Program as soon as reasonably practicable. However,
-Recipient's obligations under this Agreement and any licenses granted by
-Recipient relating to the Program shall continue and survive. </span></p>
-
-<p><span style='font-size:10.0pt'>Everyone is permitted to copy and distribute
-copies of this Agreement, but in order to avoid inconsistency the Agreement is
-copyrighted and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including revisions) of
-this Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the initial
-Agreement Steward. The Eclipse Foundation may assign the responsibility to
-serve as the Agreement Steward to a suitable separate entity. Each new version
-of the Agreement will be given a distinguishing version number. The Program
-(including Contributions) may always be distributed subject to the version of
-the Agreement under which it was received. In addition, after a new version of
-the Agreement is published, Contributor may elect to distribute the Program
-(including its Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to
-the intellectual property of any Contributor under this Agreement, whether
-expressly, by implication, estoppel or otherwise. All rights in the Program not
-expressly granted under this Agreement are reserved.</span> </p>
-
-<p><span style='font-size:10.0pt'>This Agreement is governed by the laws of the
-State of New York and the intellectual property laws of the United States of
-America. No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose. Each party waives
-its rights to a jury trial in any resulting litigation.</span> </p>
-
-<p class=MsoNormal></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.all-feature/feature.properties b/plugins/org.eclipse.jet.all-feature/feature.properties
deleted file mode 100755
index b33890c..0000000
--- a/plugins/org.eclipse.jet.all-feature/feature.properties
+++ /dev/null
@@ -1,142 +0,0 @@
-# /**
-# * <copyright>
-# *
-# * Copyright (c) 2004, 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 v1.0
-# * which accompanies this distribution, and is available at
-# * http://www.eclipse.org/legal/epl-v10.html
-# *
-# * Contributors:
-# * IBM - Initial API and implementation
-# *
-# * </copyright>
-# *
-# * $Id: feature.properties,v 1.1 2008/02/05 21:38:30 nickb Exp $
-# */
-
-# NLS_MESSAGEFORMAT_VAR
-
-featureName=Java Emitter Templates (JET) All-In-One Feature (Incubation)
-providerName=Eclipse.org
-description=JET SDK includes JET, JET UI, JET Editor, source code, test code and code examples. (Incubation)
-
-# "copyright" property - text of the "Feature Update Copyright"
-copyright=\
-Copyright (c) 2000, 2007 IBM Corporation and others.\n\
-All rights reserved. This program and the accompanying materials\n\
-are made available under the terms of the Eclipse Public License v1.0\n\
-which accompanies this distribution, and is available at\n\
-http://www.eclipse.org/legal/epl-v10.html\n\
-\n\
-Contributors:\n\
- IBM Corporation - initial API and implementation\n
-################ end of copyright property ####################################
-
-# "licenseURL" property - URL of the "Feature License"
-# do not translate value - just change to point to a locale-specific HTML page
-licenseURL=license.html
-
-# "license" property - text of the "Feature Update License"
-# should be plain text version of license agreement pointed to be "licenseURL"
-license=\
-ECLIPSE FOUNDATION SOFTWARE USER AGREEMENT\n\
-March 17, 2005\n\
-\n\
-Usage Of Content\n\
-\n\
-THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\
-OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\
-USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\
-AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\
-NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\
-AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\
-AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\
-OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\
-TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\
-OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\
-BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\
-\n\
-Applicable Licenses\n\
-\n\
-Unless otherwise indicated, all Content made available by the Eclipse Foundation\n\
-is provided to you under the terms and conditions of the Eclipse Public\n\
-License Version 1.0 ("EPL"). A copy of the EPL is provided with this\n\
-Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\
-For purposes of the EPL, "Program" will mean the Content.\n\
-\n\
-Content includes, but is not limited to, source code, object code,\n\
-documentation and other files maintained in the Eclipse.org CVS\n\
-repository ("Repository") in CVS modules ("Modules") and made available\n\
-as downloadable archives ("Downloads").\n\
-\n\
- - Content may be structured and packaged into modules to facilitate delivering,\n\
- extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\
- plug-in fragments ("Fragments"), and features ("Features").\n\
- - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java? ARchive)\n\
- in a directory named "plugins".\n\
- - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\
- Each Feature may be packaged as a sub-directory in a directory named "features".\n\
- Within a Feature, files named "feature.xml" may contain a list of the names and version\n\
- numbers of the Plug-ins and/or Fragments associated with that Feature.\n\
- - Features may also include other Features ("Included Features"). Within a Feature, files\n\
- named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\
-\n\
-Features may also include other Features ("Included Features"). Files named\n\
-"feature.xml" may contain a list of the names and version numbers of\n\
-Included Features.\n\
-\n\
-The terms and conditions governing Plug-ins and Fragments should be\n\
-contained in files named "about.html" ("Abouts"). The terms and\n\
-conditions governing Features and Included Features should be contained\n\
-in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\
-Licenses may be located in any directory of a Download or Module\n\
-including, but not limited to the following locations:\n\
-\n\
- - The top-level (root) directory\n\
- - Plug-in and Fragment directories\n\
- - Inside Plug-ins and Fragments packaged as JARs\n\
- - Sub-directories of the directory named "src" of certain Plug-ins\n\
- - Feature directories\n\
-\n\
-Note: if a Feature made available by the Eclipse Foundation is installed using the\n\
-Eclipse Update Manager, you must agree to a license ("Feature Update\n\
-License") during the installation process. If the Feature contains\n\
-Included Features, the Feature Update License should either provide you\n\
-with the terms and conditions governing the Included Features or inform\n\
-you where you can locate them. Feature Update Licenses may be found in\n\
-the "license" property of files named "feature.properties". Such Abouts,\n\
-Feature Licenses and Feature Update Licenses contain the terms and\n\
-conditions (or references to such terms and conditions) that govern your\n\
-use of the associated Content in that directory.\n\
-\n\
-THE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER\n\
-TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\
-SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\
-\n\
- - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\
- - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\
- - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\
- - IBM Public License 1.0 (available at http://oss.software.ibm.com/developerworks/opensource/license10.html)\n\
- - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\
- - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\
-\n\
-IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\
-TO USE OF THE CONTENT. If no About, Feature License or Feature Update License\n\
-is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\
-govern that particular Content.\n\
-\n\
-Cryptography\n\
-\n\
-Content may contain encryption software. The country in which you are\n\
-currently may have restrictions on the import, possession, and use,\n\
-and/or re-export to another country, of encryption software. BEFORE\n\
-using any encryption software, please check the country's laws,\n\
-regulations and policies concerning the import, possession, or use,\n\
-and re-export of encryption software, to see if this is permitted.\n\
-\n\
-Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.\n
-########### end of license property ##########################################
-
-# "updateSiteName" property - label for the M2T update site
-updateSiteName=Eclipse Model to Text (M2T) Updates
diff --git a/plugins/org.eclipse.jet.all-feature/feature.xml b/plugins/org.eclipse.jet.all-feature/feature.xml
deleted file mode 100755
index fd1c41c..0000000
--- a/plugins/org.eclipse.jet.all-feature/feature.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.jet.all"
- label="%featureName"
- version="0.9.2.qualifier"
- provider-name="%providerName">
-
- <description>
- %description
- </description>
-
- <copyright>
- %copyright
- </copyright>
-
- <license url="%licenseURL">
- %license
- </license>
-
- <url>
- <update label="%updateSiteName" url="http://download.eclipse.org/modeling/m2t/updates/"/>
- </url>
-
- <includes
- id="org.eclipse.jet.sdk"
- version="0.0.0"/>
-
- <includes
- id="org.eclipse.jet.editor"
- version="0.0.0"/>
-
- <requires>
- <import plugin="org.eclipse.emf.edit"/>
- <import plugin="org.eclipse.core.runtime"/>
- <import plugin="org.eclipse.core.resources"/>
- <import plugin="org.eclipse.ui.ide"/>
- <import plugin="org.eclipse.emf.edit.ui"/>
- </requires>
-
-</feature>
diff --git a/plugins/org.eclipse.jet.all-feature/license.html b/plugins/org.eclipse.jet.all-feature/license.html
deleted file mode 100755
index 74122b2..0000000
--- a/plugins/org.eclipse.jet.all-feature/license.html
+++ /dev/null
@@ -1,79 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<title>Eclipse.org Software User Agreement</title>
-</head>
-
-<body lang="EN-US" link=blue vlink=purple>
-<h2>Eclipse Foundation Software User Agreement</h2>
-<p>March 17, 2005</p>
-
-<h3>Usage Of Content</h3>
-
-<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
- (COLLECTIVELY &quot;CONTENT&quot;). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
- CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
- OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
- NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
- CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
-
-<h3>Applicable Licenses</h3>
-
-<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
- (&quot;EPL&quot;). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository (&quot;Repository&quot;) in CVS
- modules (&quot;Modules&quot;) and made available as downloadable archives (&quot;Downloads&quot;).</p>
-
-<ul>
- <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins (&quot;Plug-ins&quot;), plug-in fragments (&quot;Fragments&quot;), and features (&quot;Features&quot;).</li>
- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java<sup>TM</sup> ARchive) in a directory named &quot;plugins&quot;.</li>
- <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named &quot;features&quot;. Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of the Plug-ins
- and/or Fragments associated with that Feature.</li>
- <li>Features may also include other Features (&quot;Included Features&quot;). Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of Included Features.</li>
-</ul>
-
-<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named &quot;about.html&quot; (&quot;Abouts&quot;). The terms and conditions governing Features and
-Included Features should be contained in files named &quot;license.html&quot; (&quot;Feature Licenses&quot;). Abouts and Feature Licenses may be located in any directory of a Download or Module
-including, but not limited to the following locations:</p>
-
-<ul>
- <li>The top-level (root) directory</li>
- <li>Plug-in and Fragment directories</li>
- <li>Inside Plug-ins and Fragments packaged as JARs</li>
- <li>Sub-directories of the directory named &quot;src&quot; of certain Plug-ins</li>
- <li>Feature directories</li>
-</ul>
-
-<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license (&quot;Feature Update License&quot;) during the
-installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
-inform you where you can locate them. Feature Update Licenses may be found in the &quot;license&quot; property of files named &quot;feature.properties&quot; found within a Feature.
-Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
-that directory.</p>
-
-<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
-OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
-
-<ul>
- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
-</ul>
-
-<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
-contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
-
-<h3>Cryptography</h3>
-
-<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
- another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
- possession, or use, and re-export of encryption software, to see if this is permitted.</p>
-
-<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.all-feature/rootfiles/epl-v10.html b/plugins/org.eclipse.jet.all-feature/rootfiles/epl-v10.html
deleted file mode 100755
index cb1073a..0000000
--- a/plugins/org.eclipse.jet.all-feature/rootfiles/epl-v10.html
+++ /dev/null
@@ -1,304 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html xmlns:o="urn:schemas-microsoft-com:office:office"
-xmlns:w="urn:schemas-microsoft-com:office:word"
-xmlns="http://www.w3.org/TR/REC-html40">
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-font-pitch:variable;
- mso-font-signature:553679495 -2147483648 8 0 66047 0;}
- /* Style Definitions */
-p.MsoNormal, li.MsoNormal, div.MsoNormal
- {mso-style-parent:"";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p
- {margin-right:0in;
- mso-margin-top-alt:auto;
- mso-margin-bottom-alt:auto;
- margin-left:0in;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
-
- }
-@page Section1
- {size:8.5in 11.0in;
- margin:1.0in 1.25in 1.0in 1.25in;
- mso-header-margin:.5in;
- mso-footer-margin:.5in;
- mso-paper-source:0;}
-div.Section1
- {page:Section1;}
--->
-</style>
-</head>
-
-<body lang="EN-US" style='tab-interval:.5in'>
-
-<div class=Section1>
-
-<p align=center style='text-align:center'><b>Eclipse Public License - v 1.0</b>
-</p>
-
-<p><span style='font-size:10.0pt'>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER
-THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE,
-REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>1. DEFINITIONS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Contribution&quot; means:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-in the case of the initial Contributor, the initial code and documentation
-distributed under this Agreement, and<br clear=left>
-b) in the case of each subsequent Contributor:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-changes to the Program, and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-additions to the Program;</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>where
-such changes and/or additions to the Program originate from and are distributed
-by that particular Contributor. A Contribution 'originates' from a Contributor
-if it was added to the Program by such Contributor itself or anyone acting on
-such Contributor's behalf. Contributions do not include additions to the
-Program which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii) are not derivative
-works of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Contributor&quot; means any person or
-entity that distributes the Program.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Licensed Patents &quot; mean patent
-claims licensable by a Contributor which are necessarily infringed by the use
-or sale of its Contribution alone or when combined with the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Program&quot; means the Contributions
-distributed in accordance with this Agreement.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Recipient&quot; means anyone who
-receives the Program under this Agreement, including all Contributors.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>2. GRANT OF RIGHTS</span></b> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-Subject to the terms of this Agreement, each Contributor hereby grants Recipient
-a non-exclusive, worldwide, royalty-free copyright license to<span
-style='color:red'> </span>reproduce, prepare derivative works of, publicly
-display, publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and object code
-form.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-Subject to the terms of this Agreement, each Contributor hereby grants
-Recipient a non-exclusive, worldwide,<span style='color:green'> </span>royalty-free
-patent license under Licensed Patents to make, use, sell, offer to sell, import
-and otherwise transfer the Contribution of such Contributor, if any, in source
-code and object code form. This patent license shall apply to the combination
-of the Contribution and the Program if, at the time the Contribution is added
-by the Contributor, such addition of the Contribution causes such combination
-to be covered by the Licensed Patents. The patent license shall not apply to
-any other combinations which include the Contribution. No hardware per se is
-licensed hereunder. </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>c)
-Recipient understands that although each Contributor grants the licenses to its
-Contributions set forth herein, no assurances are provided by any Contributor
-that the Program does not infringe the patent or other intellectual property
-rights of any other entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement of intellectual
-property rights or otherwise. As a condition to exercising the rights and
-licenses granted hereunder, each Recipient hereby assumes sole responsibility
-to secure any other intellectual property rights needed, if any. For example,
-if a third party patent license is required to allow Recipient to distribute
-the Program, it is Recipient's responsibility to acquire that license before
-distributing the Program.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>d)
-Each Contributor represents that to its knowledge it has sufficient copyright
-rights in its Contribution, if any, to grant the copyright license set forth in
-this Agreement. </span></p>
-
-<p><b><span style='font-size:10.0pt'>3. REQUIREMENTS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>A Contributor may choose to distribute the
-Program in object code form under its own license agreement, provided that:</span>
-</p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it complies with the terms and conditions of this Agreement; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-its license agreement:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-effectively disclaims on behalf of all Contributors all warranties and
-conditions, express and implied, including warranties or conditions of title
-and non-infringement, and implied warranties or conditions of merchantability
-and fitness for a particular purpose; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-effectively excludes on behalf of all Contributors all liability for damages,
-including direct, indirect, special, incidental and consequential damages, such
-as lost profits; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iii)
-states that any provisions which differ from this Agreement are offered by that
-Contributor alone and not by any other party; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iv)
-states that source code for the Program is available from such Contributor, and
-informs licensees how to obtain it in a reasonable manner on or through a
-medium customarily used for software exchange.<span style='color:blue'> </span></span></p>
-
-<p><span style='font-size:10.0pt'>When the Program is made available in source
-code form:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it must be made available under this Agreement; and </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b) a
-copy of this Agreement must be included with each copy of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Contributors may not remove or alter any
-copyright notices contained within the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Each Contributor must identify itself as the
-originator of its Contribution, if any, in a manner that reasonably allows
-subsequent Recipients to identify the originator of the Contribution. </span></p>
-
-<p><b><span style='font-size:10.0pt'>4. COMMERCIAL DISTRIBUTION</span></b> </p>
-
-<p><span style='font-size:10.0pt'>Commercial distributors of software may
-accept certain responsibilities with respect to end users, business partners
-and the like. While this license is intended to facilitate the commercial use
-of the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create potential
-liability for other Contributors. Therefore, if a Contributor includes the
-Program in a commercial product offering, such Contributor (&quot;Commercial
-Contributor&quot;) hereby agrees to defend and indemnify every other
-Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and
-costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified Contributor to
-the extent caused by the acts or omissions of such Commercial Contributor in
-connection with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any claims or Losses
-relating to any actual or alleged intellectual property infringement. In order
-to qualify, an Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial Contributor
-to control, and cooperate with the Commercial Contributor in, the defense and
-any related settlement negotiations. The Indemnified Contributor may participate
-in any such claim at its own expense.</span> </p>
-
-<p><span style='font-size:10.0pt'>For example, a Contributor might include the
-Program in a commercial product offering, Product X. That Contributor is then a
-Commercial Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance claims and
-warranties are such Commercial Contributor's responsibility alone. Under this
-section, the Commercial Contributor would have to defend claims against the
-other Contributors related to those performance claims and warranties, and if a
-court requires any other Contributor to pay any damages as a result, the
-Commercial Contributor must pay those damages.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>5. NO WARRANTY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING,
-WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and distributing the
-Program and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program errors,
-compliance with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations. </span></p>
-
-<p><b><span style='font-size:10.0pt'>6. DISCLAIMER OF LIABILITY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF
-THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF
-THE POSSIBILITY OF SUCH DAMAGES.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>7. GENERAL</span></b> </p>
-
-<p><span style='font-size:10.0pt'>If any provision of this Agreement is invalid
-or unenforceable under applicable law, it shall not affect the validity or
-enforceability of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be reformed to the
-minimum extent necessary to make such provision valid and enforceable.</span> </p>
-
-<p><span style='font-size:10.0pt'>If Recipient institutes patent litigation
-against any entity (including a cross-claim or counterclaim in a lawsuit)
-alleging that the Program itself (excluding combinations of the Program with
-other software or hardware) infringes such Recipient's patent(s), then such
-Recipient's rights granted under Section 2(b) shall terminate as of the date
-such litigation is filed. </span></p>
-
-<p><span style='font-size:10.0pt'>All Recipient's rights under this Agreement
-shall terminate if it fails to comply with any of the material terms or
-conditions of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If all Recipient's
-rights under this Agreement terminate, Recipient agrees to cease use and
-distribution of the Program as soon as reasonably practicable. However,
-Recipient's obligations under this Agreement and any licenses granted by
-Recipient relating to the Program shall continue and survive. </span></p>
-
-<p><span style='font-size:10.0pt'>Everyone is permitted to copy and distribute
-copies of this Agreement, but in order to avoid inconsistency the Agreement is
-copyrighted and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including revisions) of
-this Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the initial
-Agreement Steward. The Eclipse Foundation may assign the responsibility to
-serve as the Agreement Steward to a suitable separate entity. Each new version
-of the Agreement will be given a distinguishing version number. The Program
-(including Contributions) may always be distributed subject to the version of
-the Agreement under which it was received. In addition, after a new version of
-the Agreement is published, Contributor may elect to distribute the Program
-(including its Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to
-the intellectual property of any Contributor under this Agreement, whether
-expressly, by implication, estoppel or otherwise. All rights in the Program not
-expressly granted under this Agreement are reserved.</span> </p>
-
-<p><span style='font-size:10.0pt'>This Agreement is governed by the laws of the
-State of New York and the intellectual property laws of the United States of
-America. No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose. Each party waives
-its rights to a jury trial in any resulting litigation.</span> </p>
-
-<p class=MsoNormal></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.all-feature/rootfiles/notice.html b/plugins/org.eclipse.jet.all-feature/rootfiles/notice.html
deleted file mode 100755
index da529cb..0000000
--- a/plugins/org.eclipse.jet.all-feature/rootfiles/notice.html
+++ /dev/null
@@ -1,86 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<title>Eclipse.org Software User Agreement</title>
-</head>
-
-<body lang="EN-US" link=blue vlink=purple>
-<h2>Eclipse Foundation Software User Agreement</h2>
-<p>March 17, 2005</p>
-
-<h3>Usage Of Content</h3>
-
-<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
- (COLLECTIVELY &quot;CONTENT&quot;). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
- CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
- OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
- NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
- CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
-
-<h3>Applicable Licenses</h3>
-
-<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
- (&quot;EPL&quot;). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository (&quot;Repository&quot;) in CVS
- modules (&quot;Modules&quot;) and made available as downloadable archives (&quot;Downloads&quot;).</p>
-
-<ul>
- <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins (&quot;Plug-ins&quot;), plug-in fragments (&quot;Fragments&quot;), and features (&quot;Features&quot;).</li>
-
- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java<sup>TM</sup> ARchive) in a directory named &quot;plugins&quot;.</li>
- <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named &quot;features&quot;. Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of the Plug-ins
- and/or Fragments associated with that Feature.</li>
- <li>Features may also include other Features (&quot;Included Features&quot;). Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of Included Features.</li>
-
-</ul>
-
-<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named &quot;about.html&quot; (&quot;Abouts&quot;). The terms and conditions governing Features and
-Included Features should be contained in files named &quot;license.html&quot; (&quot;Feature Licenses&quot;). Abouts and Feature Licenses may be located in any directory of a Download or Module
-including, but not limited to the following locations:</p>
-
-<ul>
- <li>The top-level (root) directory</li>
-
- <li>Plug-in and Fragment directories</li>
- <li>Inside Plug-ins and Fragments packaged as JARs</li>
- <li>Sub-directories of the directory named &quot;src&quot; of certain Plug-ins</li>
- <li>Feature directories</li>
-</ul>
-
-
-<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license (&quot;Feature Update License&quot;) during the
-installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
-inform you where you can locate them. Feature Update Licenses may be found in the &quot;license&quot; property of files named &quot;feature.properties&quot; found within a Feature.
-Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
-that directory.</p>
-
-<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
-OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
-
-<ul>
- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
-
- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
-
- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
-</ul>
-
-<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
-contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
-
-<h3>Cryptography</h3>
-
-<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
- another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
- possession, or use, and re-export of encryption software, to see if this is permitted.</p>
-
-<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
-
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.editor-feature/.project b/plugins/org.eclipse.jet.editor-feature/.project
deleted file mode 100644
index a620260..0000000
--- a/plugins/org.eclipse.jet.editor-feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jet.editor-feature</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.pde.FeatureBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.FeatureNature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/org.eclipse.jet.editor-feature/build.properties b/plugins/org.eclipse.jet.editor-feature/build.properties
deleted file mode 100644
index 39b0777..0000000
--- a/plugins/org.eclipse.jet.editor-feature/build.properties
+++ /dev/null
@@ -1,4 +0,0 @@
-bin.includes = feature.xml,\
- epl-v10.html,\
- feature.properties,\
- license.html
diff --git a/plugins/org.eclipse.jet.editor-feature/epl-v10.html b/plugins/org.eclipse.jet.editor-feature/epl-v10.html
deleted file mode 100644
index cb1073a..0000000
--- a/plugins/org.eclipse.jet.editor-feature/epl-v10.html
+++ /dev/null
@@ -1,304 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html xmlns:o="urn:schemas-microsoft-com:office:office"
-xmlns:w="urn:schemas-microsoft-com:office:word"
-xmlns="http://www.w3.org/TR/REC-html40">
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-font-pitch:variable;
- mso-font-signature:553679495 -2147483648 8 0 66047 0;}
- /* Style Definitions */
-p.MsoNormal, li.MsoNormal, div.MsoNormal
- {mso-style-parent:"";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p
- {margin-right:0in;
- mso-margin-top-alt:auto;
- mso-margin-bottom-alt:auto;
- margin-left:0in;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
-
- }
-@page Section1
- {size:8.5in 11.0in;
- margin:1.0in 1.25in 1.0in 1.25in;
- mso-header-margin:.5in;
- mso-footer-margin:.5in;
- mso-paper-source:0;}
-div.Section1
- {page:Section1;}
--->
-</style>
-</head>
-
-<body lang="EN-US" style='tab-interval:.5in'>
-
-<div class=Section1>
-
-<p align=center style='text-align:center'><b>Eclipse Public License - v 1.0</b>
-</p>
-
-<p><span style='font-size:10.0pt'>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER
-THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE,
-REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>1. DEFINITIONS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Contribution&quot; means:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-in the case of the initial Contributor, the initial code and documentation
-distributed under this Agreement, and<br clear=left>
-b) in the case of each subsequent Contributor:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-changes to the Program, and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-additions to the Program;</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>where
-such changes and/or additions to the Program originate from and are distributed
-by that particular Contributor. A Contribution 'originates' from a Contributor
-if it was added to the Program by such Contributor itself or anyone acting on
-such Contributor's behalf. Contributions do not include additions to the
-Program which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii) are not derivative
-works of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Contributor&quot; means any person or
-entity that distributes the Program.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Licensed Patents &quot; mean patent
-claims licensable by a Contributor which are necessarily infringed by the use
-or sale of its Contribution alone or when combined with the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Program&quot; means the Contributions
-distributed in accordance with this Agreement.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Recipient&quot; means anyone who
-receives the Program under this Agreement, including all Contributors.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>2. GRANT OF RIGHTS</span></b> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-Subject to the terms of this Agreement, each Contributor hereby grants Recipient
-a non-exclusive, worldwide, royalty-free copyright license to<span
-style='color:red'> </span>reproduce, prepare derivative works of, publicly
-display, publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and object code
-form.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-Subject to the terms of this Agreement, each Contributor hereby grants
-Recipient a non-exclusive, worldwide,<span style='color:green'> </span>royalty-free
-patent license under Licensed Patents to make, use, sell, offer to sell, import
-and otherwise transfer the Contribution of such Contributor, if any, in source
-code and object code form. This patent license shall apply to the combination
-of the Contribution and the Program if, at the time the Contribution is added
-by the Contributor, such addition of the Contribution causes such combination
-to be covered by the Licensed Patents. The patent license shall not apply to
-any other combinations which include the Contribution. No hardware per se is
-licensed hereunder. </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>c)
-Recipient understands that although each Contributor grants the licenses to its
-Contributions set forth herein, no assurances are provided by any Contributor
-that the Program does not infringe the patent or other intellectual property
-rights of any other entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement of intellectual
-property rights or otherwise. As a condition to exercising the rights and
-licenses granted hereunder, each Recipient hereby assumes sole responsibility
-to secure any other intellectual property rights needed, if any. For example,
-if a third party patent license is required to allow Recipient to distribute
-the Program, it is Recipient's responsibility to acquire that license before
-distributing the Program.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>d)
-Each Contributor represents that to its knowledge it has sufficient copyright
-rights in its Contribution, if any, to grant the copyright license set forth in
-this Agreement. </span></p>
-
-<p><b><span style='font-size:10.0pt'>3. REQUIREMENTS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>A Contributor may choose to distribute the
-Program in object code form under its own license agreement, provided that:</span>
-</p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it complies with the terms and conditions of this Agreement; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-its license agreement:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-effectively disclaims on behalf of all Contributors all warranties and
-conditions, express and implied, including warranties or conditions of title
-and non-infringement, and implied warranties or conditions of merchantability
-and fitness for a particular purpose; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-effectively excludes on behalf of all Contributors all liability for damages,
-including direct, indirect, special, incidental and consequential damages, such
-as lost profits; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iii)
-states that any provisions which differ from this Agreement are offered by that
-Contributor alone and not by any other party; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iv)
-states that source code for the Program is available from such Contributor, and
-informs licensees how to obtain it in a reasonable manner on or through a
-medium customarily used for software exchange.<span style='color:blue'> </span></span></p>
-
-<p><span style='font-size:10.0pt'>When the Program is made available in source
-code form:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it must be made available under this Agreement; and </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b) a
-copy of this Agreement must be included with each copy of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Contributors may not remove or alter any
-copyright notices contained within the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Each Contributor must identify itself as the
-originator of its Contribution, if any, in a manner that reasonably allows
-subsequent Recipients to identify the originator of the Contribution. </span></p>
-
-<p><b><span style='font-size:10.0pt'>4. COMMERCIAL DISTRIBUTION</span></b> </p>
-
-<p><span style='font-size:10.0pt'>Commercial distributors of software may
-accept certain responsibilities with respect to end users, business partners
-and the like. While this license is intended to facilitate the commercial use
-of the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create potential
-liability for other Contributors. Therefore, if a Contributor includes the
-Program in a commercial product offering, such Contributor (&quot;Commercial
-Contributor&quot;) hereby agrees to defend and indemnify every other
-Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and
-costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified Contributor to
-the extent caused by the acts or omissions of such Commercial Contributor in
-connection with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any claims or Losses
-relating to any actual or alleged intellectual property infringement. In order
-to qualify, an Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial Contributor
-to control, and cooperate with the Commercial Contributor in, the defense and
-any related settlement negotiations. The Indemnified Contributor may participate
-in any such claim at its own expense.</span> </p>
-
-<p><span style='font-size:10.0pt'>For example, a Contributor might include the
-Program in a commercial product offering, Product X. That Contributor is then a
-Commercial Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance claims and
-warranties are such Commercial Contributor's responsibility alone. Under this
-section, the Commercial Contributor would have to defend claims against the
-other Contributors related to those performance claims and warranties, and if a
-court requires any other Contributor to pay any damages as a result, the
-Commercial Contributor must pay those damages.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>5. NO WARRANTY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING,
-WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and distributing the
-Program and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program errors,
-compliance with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations. </span></p>
-
-<p><b><span style='font-size:10.0pt'>6. DISCLAIMER OF LIABILITY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF
-THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF
-THE POSSIBILITY OF SUCH DAMAGES.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>7. GENERAL</span></b> </p>
-
-<p><span style='font-size:10.0pt'>If any provision of this Agreement is invalid
-or unenforceable under applicable law, it shall not affect the validity or
-enforceability of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be reformed to the
-minimum extent necessary to make such provision valid and enforceable.</span> </p>
-
-<p><span style='font-size:10.0pt'>If Recipient institutes patent litigation
-against any entity (including a cross-claim or counterclaim in a lawsuit)
-alleging that the Program itself (excluding combinations of the Program with
-other software or hardware) infringes such Recipient's patent(s), then such
-Recipient's rights granted under Section 2(b) shall terminate as of the date
-such litigation is filed. </span></p>
-
-<p><span style='font-size:10.0pt'>All Recipient's rights under this Agreement
-shall terminate if it fails to comply with any of the material terms or
-conditions of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If all Recipient's
-rights under this Agreement terminate, Recipient agrees to cease use and
-distribution of the Program as soon as reasonably practicable. However,
-Recipient's obligations under this Agreement and any licenses granted by
-Recipient relating to the Program shall continue and survive. </span></p>
-
-<p><span style='font-size:10.0pt'>Everyone is permitted to copy and distribute
-copies of this Agreement, but in order to avoid inconsistency the Agreement is
-copyrighted and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including revisions) of
-this Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the initial
-Agreement Steward. The Eclipse Foundation may assign the responsibility to
-serve as the Agreement Steward to a suitable separate entity. Each new version
-of the Agreement will be given a distinguishing version number. The Program
-(including Contributions) may always be distributed subject to the version of
-the Agreement under which it was received. In addition, after a new version of
-the Agreement is published, Contributor may elect to distribute the Program
-(including its Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to
-the intellectual property of any Contributor under this Agreement, whether
-expressly, by implication, estoppel or otherwise. All rights in the Program not
-expressly granted under this Agreement are reserved.</span> </p>
-
-<p><span style='font-size:10.0pt'>This Agreement is governed by the laws of the
-State of New York and the intellectual property laws of the United States of
-America. No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose. Each party waives
-its rights to a jury trial in any resulting litigation.</span> </p>
-
-<p class=MsoNormal></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor-feature/feature.properties b/plugins/org.eclipse.jet.editor-feature/feature.properties
deleted file mode 100644
index ab8721e..0000000
--- a/plugins/org.eclipse.jet.editor-feature/feature.properties
+++ /dev/null
@@ -1,141 +0,0 @@
-# /**
-# * <copyright>
-# *
-# * Copyright (c) 2004, 2008 IBM Corporation and others.
-# * All rights reserved. This program and the accompanying materials
-# * are made available under the terms of the Eclipse Public License v1.0
-# * which accompanies this distribution, and is available at
-# * http://www.eclipse.org/legal/epl-v10.html
-# *
-# * Contributors:
-# * IBM - Initial API and implementation
-# *
-# * </copyright>
-# *
-# * $Id: feature.properties,v 1.3 2008/02/11 17:22:46 pelder Exp $
-# */
-
-# NLS_MESSAGEFORMAT_VAR
-
-featureName=JET Editor (Incubation)
-providerName=Eclipse.org
-description=JET Editor (Incubation)
-# "copyright" property - text of the "Feature Update Copyright"
-copyright=\
-Copyright (c) 2000, 2008 IBM Corporation and others.\n\
-All rights reserved. This program and the accompanying materials\n\
-are made available under the terms of the Eclipse Public License v1.0\n\
-which accompanies this distribution, and is available at\n\
-http://www.eclipse.org/legal/epl-v10.html\n\
-\n\
-Contributors:\n\
- IBM Corporation - initial API and implementation\n
-################ end of copyright property ####################################
-
-# "licenseURL" property - URL of the "Feature License"
-# do not translate value - just change to point to a locale-specific HTML page
-licenseURL=license.html
-
-# "license" property - text of the "Feature Update License"
-# should be plain text version of license agreement pointed to be "licenseURL"
-license=\
-ECLIPSE FOUNDATION SOFTWARE USER AGREEMENT\n\
-March 17, 2005\n\
-\n\
-Usage Of Content\n\
-\n\
-THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\
-OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\
-USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\
-AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\
-NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\
-AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\
-AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\
-OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\
-TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\
-OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\
-BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\
-\n\
-Applicable Licenses\n\
-\n\
-Unless otherwise indicated, all Content made available by the Eclipse Foundation\n\
-is provided to you under the terms and conditions of the Eclipse Public\n\
-License Version 1.0 ("EPL"). A copy of the EPL is provided with this\n\
-Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\
-For purposes of the EPL, "Program" will mean the Content.\n\
-\n\
-Content includes, but is not limited to, source code, object code,\n\
-documentation and other files maintained in the Eclipse.org CVS\n\
-repository ("Repository") in CVS modules ("Modules") and made available\n\
-as downloadable archives ("Downloads").\n\
-\n\
- - Content may be structured and packaged into modules to facilitate delivering,\n\
- extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\
- plug-in fragments ("Fragments"), and features ("Features").\n\
- - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java? ARchive)\n\
- in a directory named "plugins".\n\
- - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\
- Each Feature may be packaged as a sub-directory in a directory named "features".\n\
- Within a Feature, files named "feature.xml" may contain a list of the names and version\n\
- numbers of the Plug-ins and/or Fragments associated with that Feature.\n\
- - Features may also include other Features ("Included Features"). Within a Feature, files\n\
- named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\
-\n\
-Features may also include other Features ("Included Features"). Files named\n\
-"feature.xml" may contain a list of the names and version numbers of\n\
-Included Features.\n\
-\n\
-The terms and conditions governing Plug-ins and Fragments should be\n\
-contained in files named "about.html" ("Abouts"). The terms and\n\
-conditions governing Features and Included Features should be contained\n\
-in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\
-Licenses may be located in any directory of a Download or Module\n\
-including, but not limited to the following locations:\n\
-\n\
- - The top-level (root) directory\n\
- - Plug-in and Fragment directories\n\
- - Inside Plug-ins and Fragments packaged as JARs\n\
- - Sub-directories of the directory named "src" of certain Plug-ins\n\
- - Feature directories\n\
-\n\
-Note: if a Feature made available by the Eclipse Foundation is installed using the\n\
-Eclipse Update Manager, you must agree to a license ("Feature Update\n\
-License") during the installation process. If the Feature contains\n\
-Included Features, the Feature Update License should either provide you\n\
-with the terms and conditions governing the Included Features or inform\n\
-you where you can locate them. Feature Update Licenses may be found in\n\
-the "license" property of files named "feature.properties". Such Abouts,\n\
-Feature Licenses and Feature Update Licenses contain the terms and\n\
-conditions (or references to such terms and conditions) that govern your\n\
-use of the associated Content in that directory.\n\
-\n\
-THE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER\n\
-TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\
-SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\
-\n\
- - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\
- - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\
- - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\
- - IBM Public License 1.0 (available at http://oss.software.ibm.com/developerworks/opensource/license10.html)\n\
- - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\
- - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\
-\n\
-IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\
-TO USE OF THE CONTENT. If no About, Feature License or Feature Update License\n\
-is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\
-govern that particular Content.\n\
-\n\
-Cryptography\n\
-\n\
-Content may contain encryption software. The country in which you are\n\
-currently may have restrictions on the import, possession, and use,\n\
-and/or re-export to another country, of encryption software. BEFORE\n\
-using any encryption software, please check the country's laws,\n\
-regulations and policies concerning the import, possession, or use,\n\
-and re-export of encryption software, to see if this is permitted.\n\
-\n\
-Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.\n
-########### end of license property ##########################################
-
-# "updateSiteName" property - label for the M2T update site
-updateSiteName=Eclipse Model to Text (M2T) Updates
diff --git a/plugins/org.eclipse.jet.editor-feature/feature.xml b/plugins/org.eclipse.jet.editor-feature/feature.xml
deleted file mode 100644
index 8dd0b33..0000000
--- a/plugins/org.eclipse.jet.editor-feature/feature.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.jet.editor"
- label="%featureName"
- version="0.9.0.qualifier"
- provider-name="%providerName">
-
- <description>
- %description
- </description>
-
- <copyright>
- %copyright
- </copyright>
-
- <license url="%licenseURL">
- %license
- </license>
-
- <requires>
- <import plugin="org.eclipse.core.runtime" version="3.3.0" match="compatible"/>
- <import plugin="org.eclipse.core.resources" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.jface.text" version="3.3.0" match="compatible"/>
- <import plugin="org.eclipse.ui" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.ui.ide" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.ui.editors" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.ui.workbench.texteditor" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.ui.views" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.ui.views.properties.tabbed" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.jdt.core" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.jdt.ui" version="3.3.0" match="compatible"/>
- <import plugin="org.eclipse.jet" version="0.8.0" match="compatible"/>
- <import plugin="org.eclipse.emf.codegen.ecore" version="2.2.0" match="compatible"/>
- <import plugin="org.eclipse.emf.ecore" version="2.2.0" match="compatible"/>
- <import plugin="org.eclipse.emf.codegen.ecore.ui" version="2.2.0" match="compatible"/>
- </requires>
-
- <plugin
- id="org.eclipse.jet.editor"
- download-size="0"
- install-size="0"
- version="0.0.0"
- unpack="false"/>
-
-</feature>
diff --git a/plugins/org.eclipse.jet.editor-feature/license.html b/plugins/org.eclipse.jet.editor-feature/license.html
deleted file mode 100644
index 74122b2..0000000
--- a/plugins/org.eclipse.jet.editor-feature/license.html
+++ /dev/null
@@ -1,79 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<title>Eclipse.org Software User Agreement</title>
-</head>
-
-<body lang="EN-US" link=blue vlink=purple>
-<h2>Eclipse Foundation Software User Agreement</h2>
-<p>March 17, 2005</p>
-
-<h3>Usage Of Content</h3>
-
-<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
- (COLLECTIVELY &quot;CONTENT&quot;). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
- CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
- OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
- NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
- CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
-
-<h3>Applicable Licenses</h3>
-
-<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
- (&quot;EPL&quot;). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository (&quot;Repository&quot;) in CVS
- modules (&quot;Modules&quot;) and made available as downloadable archives (&quot;Downloads&quot;).</p>
-
-<ul>
- <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins (&quot;Plug-ins&quot;), plug-in fragments (&quot;Fragments&quot;), and features (&quot;Features&quot;).</li>
- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java<sup>TM</sup> ARchive) in a directory named &quot;plugins&quot;.</li>
- <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named &quot;features&quot;. Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of the Plug-ins
- and/or Fragments associated with that Feature.</li>
- <li>Features may also include other Features (&quot;Included Features&quot;). Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of Included Features.</li>
-</ul>
-
-<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named &quot;about.html&quot; (&quot;Abouts&quot;). The terms and conditions governing Features and
-Included Features should be contained in files named &quot;license.html&quot; (&quot;Feature Licenses&quot;). Abouts and Feature Licenses may be located in any directory of a Download or Module
-including, but not limited to the following locations:</p>
-
-<ul>
- <li>The top-level (root) directory</li>
- <li>Plug-in and Fragment directories</li>
- <li>Inside Plug-ins and Fragments packaged as JARs</li>
- <li>Sub-directories of the directory named &quot;src&quot; of certain Plug-ins</li>
- <li>Feature directories</li>
-</ul>
-
-<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license (&quot;Feature Update License&quot;) during the
-installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
-inform you where you can locate them. Feature Update Licenses may be found in the &quot;license&quot; property of files named &quot;feature.properties&quot; found within a Feature.
-Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
-that directory.</p>
-
-<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
-OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
-
-<ul>
- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
-</ul>
-
-<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
-contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
-
-<h3>Cryptography</h3>
-
-<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
- another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
- possession, or use, and re-export of encryption software, to see if this is permitted.</p>
-
-<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.editor-feature/rootfiles/epl-v10.html b/plugins/org.eclipse.jet.editor-feature/rootfiles/epl-v10.html
deleted file mode 100644
index cb1073a..0000000
--- a/plugins/org.eclipse.jet.editor-feature/rootfiles/epl-v10.html
+++ /dev/null
@@ -1,304 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html xmlns:o="urn:schemas-microsoft-com:office:office"
-xmlns:w="urn:schemas-microsoft-com:office:word"
-xmlns="http://www.w3.org/TR/REC-html40">
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-font-pitch:variable;
- mso-font-signature:553679495 -2147483648 8 0 66047 0;}
- /* Style Definitions */
-p.MsoNormal, li.MsoNormal, div.MsoNormal
- {mso-style-parent:"";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p
- {margin-right:0in;
- mso-margin-top-alt:auto;
- mso-margin-bottom-alt:auto;
- margin-left:0in;
- mso-pagination:widow-orphan;
- font-size:12.0pt;
- }
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
-
- }
-@page Section1
- {size:8.5in 11.0in;
- margin:1.0in 1.25in 1.0in 1.25in;
- mso-header-margin:.5in;
- mso-footer-margin:.5in;
- mso-paper-source:0;}
-div.Section1
- {page:Section1;}
--->
-</style>
-</head>
-
-<body lang="EN-US" style='tab-interval:.5in'>
-
-<div class=Section1>
-
-<p align=center style='text-align:center'><b>Eclipse Public License - v 1.0</b>
-</p>
-
-<p><span style='font-size:10.0pt'>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER
-THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (&quot;AGREEMENT&quot;). ANY USE,
-REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>1. DEFINITIONS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Contribution&quot; means:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-in the case of the initial Contributor, the initial code and documentation
-distributed under this Agreement, and<br clear=left>
-b) in the case of each subsequent Contributor:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-changes to the Program, and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-additions to the Program;</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>where
-such changes and/or additions to the Program originate from and are distributed
-by that particular Contributor. A Contribution 'originates' from a Contributor
-if it was added to the Program by such Contributor itself or anyone acting on
-such Contributor's behalf. Contributions do not include additions to the
-Program which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii) are not derivative
-works of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Contributor&quot; means any person or
-entity that distributes the Program.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Licensed Patents &quot; mean patent
-claims licensable by a Contributor which are necessarily infringed by the use
-or sale of its Contribution alone or when combined with the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>&quot;Program&quot; means the Contributions
-distributed in accordance with this Agreement.</span> </p>
-
-<p><span style='font-size:10.0pt'>&quot;Recipient&quot; means anyone who
-receives the Program under this Agreement, including all Contributors.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>2. GRANT OF RIGHTS</span></b> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-Subject to the terms of this Agreement, each Contributor hereby grants Recipient
-a non-exclusive, worldwide, royalty-free copyright license to<span
-style='color:red'> </span>reproduce, prepare derivative works of, publicly
-display, publicly perform, distribute and sublicense the Contribution of such
-Contributor, if any, and such derivative works, in source code and object code
-form.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-Subject to the terms of this Agreement, each Contributor hereby grants
-Recipient a non-exclusive, worldwide,<span style='color:green'> </span>royalty-free
-patent license under Licensed Patents to make, use, sell, offer to sell, import
-and otherwise transfer the Contribution of such Contributor, if any, in source
-code and object code form. This patent license shall apply to the combination
-of the Contribution and the Program if, at the time the Contribution is added
-by the Contributor, such addition of the Contribution causes such combination
-to be covered by the Licensed Patents. The patent license shall not apply to
-any other combinations which include the Contribution. No hardware per se is
-licensed hereunder. </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>c)
-Recipient understands that although each Contributor grants the licenses to its
-Contributions set forth herein, no assurances are provided by any Contributor
-that the Program does not infringe the patent or other intellectual property
-rights of any other entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement of intellectual
-property rights or otherwise. As a condition to exercising the rights and
-licenses granted hereunder, each Recipient hereby assumes sole responsibility
-to secure any other intellectual property rights needed, if any. For example,
-if a third party patent license is required to allow Recipient to distribute
-the Program, it is Recipient's responsibility to acquire that license before
-distributing the Program.</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>d)
-Each Contributor represents that to its knowledge it has sufficient copyright
-rights in its Contribution, if any, to grant the copyright license set forth in
-this Agreement. </span></p>
-
-<p><b><span style='font-size:10.0pt'>3. REQUIREMENTS</span></b> </p>
-
-<p><span style='font-size:10.0pt'>A Contributor may choose to distribute the
-Program in object code form under its own license agreement, provided that:</span>
-</p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it complies with the terms and conditions of this Agreement; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b)
-its license agreement:</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>i)
-effectively disclaims on behalf of all Contributors all warranties and
-conditions, express and implied, including warranties or conditions of title
-and non-infringement, and implied warranties or conditions of merchantability
-and fitness for a particular purpose; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>ii)
-effectively excludes on behalf of all Contributors all liability for damages,
-including direct, indirect, special, incidental and consequential damages, such
-as lost profits; </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iii)
-states that any provisions which differ from this Agreement are offered by that
-Contributor alone and not by any other party; and</span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>iv)
-states that source code for the Program is available from such Contributor, and
-informs licensees how to obtain it in a reasonable manner on or through a
-medium customarily used for software exchange.<span style='color:blue'> </span></span></p>
-
-<p><span style='font-size:10.0pt'>When the Program is made available in source
-code form:</span> </p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>a)
-it must be made available under this Agreement; and </span></p>
-
-<p class=MsoNormal style='margin-left:.5in'><span style='font-size:10.0pt'>b) a
-copy of this Agreement must be included with each copy of the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Contributors may not remove or alter any
-copyright notices contained within the Program. </span></p>
-
-<p><span style='font-size:10.0pt'>Each Contributor must identify itself as the
-originator of its Contribution, if any, in a manner that reasonably allows
-subsequent Recipients to identify the originator of the Contribution. </span></p>
-
-<p><b><span style='font-size:10.0pt'>4. COMMERCIAL DISTRIBUTION</span></b> </p>
-
-<p><span style='font-size:10.0pt'>Commercial distributors of software may
-accept certain responsibilities with respect to end users, business partners
-and the like. While this license is intended to facilitate the commercial use
-of the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create potential
-liability for other Contributors. Therefore, if a Contributor includes the
-Program in a commercial product offering, such Contributor (&quot;Commercial
-Contributor&quot;) hereby agrees to defend and indemnify every other
-Contributor (&quot;Indemnified Contributor&quot;) against any losses, damages and
-costs (collectively &quot;Losses&quot;) arising from claims, lawsuits and other
-legal actions brought by a third party against the Indemnified Contributor to
-the extent caused by the acts or omissions of such Commercial Contributor in
-connection with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any claims or Losses
-relating to any actual or alleged intellectual property infringement. In order
-to qualify, an Indemnified Contributor must: a) promptly notify the Commercial
-Contributor in writing of such claim, and b) allow the Commercial Contributor
-to control, and cooperate with the Commercial Contributor in, the defense and
-any related settlement negotiations. The Indemnified Contributor may participate
-in any such claim at its own expense.</span> </p>
-
-<p><span style='font-size:10.0pt'>For example, a Contributor might include the
-Program in a commercial product offering, Product X. That Contributor is then a
-Commercial Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance claims and
-warranties are such Commercial Contributor's responsibility alone. Under this
-section, the Commercial Contributor would have to defend claims against the
-other Contributors related to those performance claims and warranties, and if a
-court requires any other Contributor to pay any damages as a result, the
-Commercial Contributor must pay those damages.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>5. NO WARRANTY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, THE PROGRAM IS PROVIDED ON AN &quot;AS IS&quot; BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING,
-WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT,
-MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and distributing the
-Program and assumes all risks associated with its exercise of rights under this
-Agreement , including but not limited to the risks and costs of program errors,
-compliance with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations. </span></p>
-
-<p><b><span style='font-size:10.0pt'>6. DISCLAIMER OF LIABILITY</span></b> </p>
-
-<p><span style='font-size:10.0pt'>EXCEPT AS EXPRESSLY SET FORTH IN THIS
-AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
-NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF
-THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF
-THE POSSIBILITY OF SUCH DAMAGES.</span> </p>
-
-<p><b><span style='font-size:10.0pt'>7. GENERAL</span></b> </p>
-
-<p><span style='font-size:10.0pt'>If any provision of this Agreement is invalid
-or unenforceable under applicable law, it shall not affect the validity or
-enforceability of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be reformed to the
-minimum extent necessary to make such provision valid and enforceable.</span> </p>
-
-<p><span style='font-size:10.0pt'>If Recipient institutes patent litigation
-against any entity (including a cross-claim or counterclaim in a lawsuit)
-alleging that the Program itself (excluding combinations of the Program with
-other software or hardware) infringes such Recipient's patent(s), then such
-Recipient's rights granted under Section 2(b) shall terminate as of the date
-such litigation is filed. </span></p>
-
-<p><span style='font-size:10.0pt'>All Recipient's rights under this Agreement
-shall terminate if it fails to comply with any of the material terms or
-conditions of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If all Recipient's
-rights under this Agreement terminate, Recipient agrees to cease use and
-distribution of the Program as soon as reasonably practicable. However,
-Recipient's obligations under this Agreement and any licenses granted by
-Recipient relating to the Program shall continue and survive. </span></p>
-
-<p><span style='font-size:10.0pt'>Everyone is permitted to copy and distribute
-copies of this Agreement, but in order to avoid inconsistency the Agreement is
-copyrighted and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including revisions) of
-this Agreement from time to time. No one other than the Agreement Steward has
-the right to modify this Agreement. The Eclipse Foundation is the initial
-Agreement Steward. The Eclipse Foundation may assign the responsibility to
-serve as the Agreement Steward to a suitable separate entity. Each new version
-of the Agreement will be given a distinguishing version number. The Program
-(including Contributions) may always be distributed subject to the version of
-the Agreement under which it was received. In addition, after a new version of
-the Agreement is published, Contributor may elect to distribute the Program
-(including its Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to
-the intellectual property of any Contributor under this Agreement, whether
-expressly, by implication, estoppel or otherwise. All rights in the Program not
-expressly granted under this Agreement are reserved.</span> </p>
-
-<p><span style='font-size:10.0pt'>This Agreement is governed by the laws of the
-State of New York and the intellectual property laws of the United States of
-America. No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose. Each party waives
-its rights to a jury trial in any resulting litigation.</span> </p>
-
-<p class=MsoNormal></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor-feature/rootfiles/notice.html b/plugins/org.eclipse.jet.editor-feature/rootfiles/notice.html
deleted file mode 100644
index da529cb..0000000
--- a/plugins/org.eclipse.jet.editor-feature/rootfiles/notice.html
+++ /dev/null
@@ -1,86 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<title>Eclipse.org Software User Agreement</title>
-</head>
-
-<body lang="EN-US" link=blue vlink=purple>
-<h2>Eclipse Foundation Software User Agreement</h2>
-<p>March 17, 2005</p>
-
-<h3>Usage Of Content</h3>
-
-<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
- (COLLECTIVELY &quot;CONTENT&quot;). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
- CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
- OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
- NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
- CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
-
-<h3>Applicable Licenses</h3>
-
-<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
- (&quot;EPL&quot;). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository (&quot;Repository&quot;) in CVS
- modules (&quot;Modules&quot;) and made available as downloadable archives (&quot;Downloads&quot;).</p>
-
-<ul>
- <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins (&quot;Plug-ins&quot;), plug-in fragments (&quot;Fragments&quot;), and features (&quot;Features&quot;).</li>
-
- <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java<sup>TM</sup> ARchive) in a directory named &quot;plugins&quot;.</li>
- <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named &quot;features&quot;. Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of the Plug-ins
- and/or Fragments associated with that Feature.</li>
- <li>Features may also include other Features (&quot;Included Features&quot;). Within a Feature, files named &quot;feature.xml&quot; may contain a list of the names and version numbers of Included Features.</li>
-
-</ul>
-
-<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named &quot;about.html&quot; (&quot;Abouts&quot;). The terms and conditions governing Features and
-Included Features should be contained in files named &quot;license.html&quot; (&quot;Feature Licenses&quot;). Abouts and Feature Licenses may be located in any directory of a Download or Module
-including, but not limited to the following locations:</p>
-
-<ul>
- <li>The top-level (root) directory</li>
-
- <li>Plug-in and Fragment directories</li>
- <li>Inside Plug-ins and Fragments packaged as JARs</li>
- <li>Sub-directories of the directory named &quot;src&quot; of certain Plug-ins</li>
- <li>Feature directories</li>
-</ul>
-
-
-<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license (&quot;Feature Update License&quot;) during the
-installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
-inform you where you can locate them. Feature Update Licenses may be found in the &quot;license&quot; property of files named &quot;feature.properties&quot; found within a Feature.
-Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
-that directory.</p>
-
-<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
-OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
-
-<ul>
- <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
-
- <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
- <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
- <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
- <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
-
- <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
-</ul>
-
-<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
-contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
-
-<h3>Cryptography</h3>
-
-<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
- another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
- possession, or use, and re-export of encryption software, to see if this is permitted.</p>
-
-<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
-
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.editor/.classpath b/plugins/org.eclipse.jet.editor/.classpath
deleted file mode 100644
index 64c5e31..0000000
--- a/plugins/org.eclipse.jet.editor/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/plugins/org.eclipse.jet.editor/.cvsignore b/plugins/org.eclipse.jet.editor/.cvsignore
deleted file mode 100644
index ba077a4..0000000
--- a/plugins/org.eclipse.jet.editor/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/plugins/org.eclipse.jet.editor/.jetproperties b/plugins/org.eclipse.jet.editor/.jetproperties
deleted file mode 100644
index 5585019..0000000
--- a/plugins/org.eclipse.jet.editor/.jetproperties
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<jet-settings>
- <template-container>templates</template-container> <source-container>src</source-container>
-</jet-settings>
diff --git a/plugins/org.eclipse.jet.editor/.project b/plugins/org.eclipse.jet.editor/.project
deleted file mode 100644
index 9c4f7a4..0000000
--- a/plugins/org.eclipse.jet.editor/.project
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jet.editor</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jet.builder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <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.jet.jet2Nature</nature>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/org.eclipse.jet.editor/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.jet.editor/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 2a73a63..0000000
--- a/plugins/org.eclipse.jet.editor/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Mon Jan 26 16:58:07 EST 2009
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.source=1.5
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
diff --git a/plugins/org.eclipse.jet.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.jet.editor/META-INF/MANIFEST.MF
deleted file mode 100644
index 6c27615..0000000
--- a/plugins/org.eclipse.jet.editor/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,33 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jet.editor; singleton:=true
-Bundle-Version: 0.9.1.qualifier
-Bundle-Activator: org.eclipse.jet.internal.editor.Activator
-Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.resources;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jface.text;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.ide;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.editors;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.workbench.texteditor;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.views;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.views.properties.tabbed;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.core;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jet;bundle-version="[0.8.0,1.0.0)",
- org.eclipse.emf.codegen.ecore;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.emf.ecore;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.emf.codegen.ecore.ui;bundle-version="[2.2.0,3.0.0)"
-Eclipse-LazyStart: true
-Export-Package: org.eclipse.jet.internal.editor,
- org.eclipse.jet.internal.editor.configuration,
- org.eclipse.jet.internal.editor.configuration.delegates,
- org.eclipse.jet.internal.editor.outline,
- org.eclipse.jet.internal.editor.partition,
- org.eclipse.jet.internal.editor.rules,
- org.eclipse.jet.internal.editor.scanners
-Bundle-Vendor: %providerName
-Bundle-Localization: plugin
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/plugins/org.eclipse.jet.editor/ModelingFeature.png b/plugins/org.eclipse.jet.editor/ModelingFeature.png
deleted file mode 100644
index 6b08de2..0000000
--- a/plugins/org.eclipse.jet.editor/ModelingFeature.png
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/about.html b/plugins/org.eclipse.jet.editor/about.html
deleted file mode 100644
index d4f39ad..0000000
--- a/plugins/org.eclipse.jet.editor/about.html
+++ /dev/null
@@ -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">
- <h3>About This Content</h3>
-
- <p>June 5, 2007</p>
- <h3>License</h3>
-
- <p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).
- Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
- Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
- at <a href="http://www.eclipse.org/org/documents/epl-v10.php">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; 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 (&quot;Redistributor&quot;) 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>
- <p align="right"><small><a href="#top">go to top</a></small></p>
-
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.editor/about.ini b/plugins/org.eclipse.jet.editor/about.ini
deleted file mode 100644
index 93fc30a..0000000
--- a/plugins/org.eclipse.jet.editor/about.ini
+++ /dev/null
@@ -1,28 +0,0 @@
-# about.ini
-# contains information about a feature
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# "%key" are externalized strings defined in about.properties
-# This file does not need to be translated.
-
-# Property "aboutText" contains blurb for "About" dialog (translated)
-aboutText=%blurb
-
-# Property "windowImage" contains path to window icon (16x16)
-# needed for primary features only
-
-# Property "featureImage" contains path to feature image (32x32)
-featureImage=ModelingFeature.png
-
-# Property "aboutImage" contains path to product image (500x330 or 115x164)
-# needed for primary features only
-
-# Property "appName" contains name of the application (not translated)
-# needed for primary features only
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-# Property "tipsAndTricksHref" contains the Help topic href to a tips and tricks page
-# optional
-#tipsAndTricksHref=/org.eclipse.jet.doc/tips/jet_tips.html \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/about.mappings b/plugins/org.eclipse.jet.editor/about.mappings
deleted file mode 100644
index a28390a..0000000
--- a/plugins/org.eclipse.jet.editor/about.mappings
+++ /dev/null
@@ -1,6 +0,0 @@
-# about.mappings
-# contains fill-ins for about.properties
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file does not need to be translated.
-
-0=@build@
diff --git a/plugins/org.eclipse.jet.editor/about.properties b/plugins/org.eclipse.jet.editor/about.properties
deleted file mode 100644
index e772ff5..0000000
--- a/plugins/org.eclipse.jet.editor/about.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2006, 2008 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-# about.properties
-# contains externalized strings for about.ini
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# fill-ins are supplied by about.mappings
-# This file should be translated.
-
-blurb=Java Emitter Templates (JET) Editor\n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright IBM Corporation and others 2005, 2008. All rights reserved.\n\
-Visit http://www.eclipse.org/modeling/m2t/?project=jet#jet \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/build.properties b/plugins/org.eclipse.jet.editor/build.properties
deleted file mode 100644
index 91f7dcb..0000000
--- a/plugins/org.eclipse.jet.editor/build.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-source.. = src/
-output.. = bin/
-bin.includes = plugin.xml,\
- META-INF/,\
- .,\
- icons/,\
- ModelingFeature.png,\
- about.html,\
- about.ini,\
- about.mappings,\
- about.properties,\
- plugin.properties
diff --git a/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETFileWizard.gif b/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETFileWizard.gif
deleted file mode 100644
index b603b01..0000000
--- a/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETFileWizard.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETProjectWizard.gif b/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETProjectWizard.gif
deleted file mode 100644
index 8d97ee5..0000000
--- a/plugins/org.eclipse.jet.editor/icons/full/ctool16/JETProjectWizard.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/icons/full/obj16/JETTemplateFile.gif b/plugins/org.eclipse.jet.editor/icons/full/obj16/JETTemplateFile.gif
deleted file mode 100644
index 66f8c76..0000000
--- a/plugins/org.eclipse.jet.editor/icons/full/obj16/JETTemplateFile.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/icons/full/wizban/JETProjectWizard.gif b/plugins/org.eclipse.jet.editor/icons/full/wizban/JETProjectWizard.gif
deleted file mode 100644
index 8d97ee5..0000000
--- a/plugins/org.eclipse.jet.editor/icons/full/wizban/JETProjectWizard.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/icons/sample.gif b/plugins/org.eclipse.jet.editor/icons/sample.gif
deleted file mode 100644
index 34fb3c9..0000000
--- a/plugins/org.eclipse.jet.editor/icons/sample.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.editor/plugin.properties b/plugins/org.eclipse.jet.editor/plugin.properties
deleted file mode 100644
index c0c9b70..0000000
--- a/plugins/org.eclipse.jet.editor/plugin.properties
+++ /dev/null
@@ -1,4 +0,0 @@
-pluginName = JET Editor (Incubation)
-providerName = Eclipse.org
-_UI_SetContentColorerAction.label=Set Non-JET Text Content Colorer ...
-editor.name.0 = JET - Java Emitter Templates Editor \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/plugin.xml b/plugins/org.eclipse.jet.editor/plugin.xml
deleted file mode 100644
index 8edf41c..0000000
--- a/plugins/org.eclipse.jet.editor/plugin.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
- <extension-point id="defaultContentColorerDelegates" name="Default JET Text Content Colorer Delegates" schema="schema/defaultContentColorerDelegates.exsd"/>
-
- <extension
- point="org.eclipse.ui.editors">
- <editor
- class="org.eclipse.jet.internal.editor.JETTextEditor"
- contributorClass="org.eclipse.ui.texteditor.BasicTextEditorActionContributor"
- default="true"
- extensions="jet"
- icon="icons/full/obj16/JETTemplateFile.gif"
- id="org.eclipse.jet.editor.JETEditor"
- name="%editor.name.0">
- </editor>
- </extension>
- <extension
- point="org.eclipse.jet.editor.defaultContentColorerDelegates">
- <defaultContentColorerDelegate
- delegateClass="org.eclipse.jet.internal.editor.configuration.delegates.java.JavaContentPartitionConfigurationDelegate">
- </defaultContentColorerDelegate>
- <defaultContentColorerDelegate
- delegateClass="org.eclipse.jet.internal.editor.configuration.delegates.xml.XMLContentPartitionConfigurationDelegate">
- </defaultContentColorerDelegate>
- </extension>
- <extension
- point="org.eclipse.ui.editorActions">
- <editorContribution
- id="org.eclipse.jet.editor.JETEditor.actionsContributor"
- targetID="org.eclipse.jet.editor.JETEditor">
- <action
- actionID="setDelegateColorerActionID"
- class="org.eclipse.jet.internal.editor.actions.SetContentColorerAction"
- id="org.eclipse.jet.editor.setDelegateColorerActionID"
- label="%_UI_SetContentColorerAction.label"
- style="push">
- </action>
- </editorContribution>
- </extension>
- <extension
- point="org.eclipse.ui.editors.annotationTypes">
- <type
- markerSeverity="2"
- name="org.eclipse.jet.editor.error"
- super="org.eclipse.ui.workbench.texteditor.error">
- </type>
- <type
- markerSeverity="1"
- name="org.eclipse.jet.editor.warning"
- super="org.eclipse.ui.workbench.texteditor.warning">
- </type>
- <type
- markerSeverity="0"
- name="org.eclipse.jet.editor.info"
- super="org.eclipse.ui.workbench.texteditor.info">
- </type>
- </extension>
-
-</plugin>
diff --git a/plugins/org.eclipse.jet.editor/schema/defaultContentColorerDelegates.exsd b/plugins/org.eclipse.jet.editor/schema/defaultContentColorerDelegates.exsd
deleted file mode 100644
index 4f13c0f..0000000
--- a/plugins/org.eclipse.jet.editor/schema/defaultContentColorerDelegates.exsd
+++ /dev/null
@@ -1,105 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.jet.internal.editor">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.jet.internal.editor" id="defaultContentColorerDelegates" name="Default Content Colorer Delegates"/>
- </appInfo>
- <documentation>
- [Enter description of this extension point.]
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="defaultContentColorerDelegate" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
-
- </documentation>
- <appInfo>
- <meta.attribute translatable="true"/>
- </appInfo>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="defaultContentColorerDelegate">
- <complexType>
- <attribute name="delegateClass" type="string" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- <appInfo>
- <meta.attribute kind="java" basedOn="org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate"/>
- </appInfo>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="since"/>
- </appInfo>
- <documentation>
- [Enter the first release in which this extension point appears.]
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- [Enter extension point usage example here.]
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
- [Enter API information here.]
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
- [Enter information about supplied implementation of this extension point.]
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
-
- </documentation>
- </annotation>
-
-</schema>
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/Activator.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/Activator.java
deleted file mode 100644
index 0db1e31..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/Activator.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends AbstractUIPlugin {
-
- // The plug-in ID
- public static final String PLUGIN_ID = "org.eclipse.jet.internal.editor";
-
- // The shared instance
- private static Activator plugin;
-
- /**
- * The constructor
- */
- public Activator() {
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- */
- public void start(BundleContext context) throws Exception {
- super.start(context);
- plugin = this;
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
- */
- public void stop(BundleContext context) throws Exception {
- plugin = null;
- super.stop(context);
- }
-
- /**
- * Returns the shared instance
- *
- * @return the shared instance
- */
- public static Activator getDefault() {
- return plugin;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path
- *
- * @param path the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return imageDescriptorFromPlugin(PLUGIN_ID, path);
- }
-
- /**
- * Log an exception in Eclipse's logger with this plugin ID
- * @param e
- */
- public static void log(Exception e) {
- IStatus status = new Status(IStatus.ERROR, PLUGIN_ID, e.getMessage(), e);
- getDefault().getLog().log(status);
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETDocumentReader.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETDocumentReader.java
deleted file mode 100644
index 49388d9..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETDocumentReader.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.IDocument;
-
-/**
- * @author jcheuoua
- *
- * To change the template for this generated type comment go to Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code
- * and Comments
- * @version $Revision: 1.2 $
- */
-public class JETDocumentReader {
- public static final int EOF = -1;
-
- private IDocument document;
-
- private int offset;
-
- /**
- * Constructor for JETDocumentReader.
- *
- * @param document
- * IDocument
- * @param documentOffset
- * int
- */
- public JETDocumentReader(IDocument document, int documentOffset) {
- this.document = null;
- offset = -1;
- if (documentOffset > 0)
- offset = documentOffset;
- this.document = document;
- }
-
- /**
- * Method readForward.
- *
- * @return char
- */
- public char readForward() {
- try {
- if (document.getChar(offset) == '\uFFFF') {
- return '\uFFFF';
- } else {
- offset++;
- return document.getChar(offset);
- }
- } catch (BadLocationException ex) {
- return '\uFFFF';
- }
- }
-
- /**
- * Method readBackward.
- *
- * @return char
- */
- public char readBackward() {
- if (offset <= 0)
- return '\uFFFF';
- try {
- offset--;
- return document.getChar(offset);
- } catch (BadLocationException e) {
- return '\uFFFF';
- }
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditor.java
deleted file mode 100644
index e7023e1..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditor.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.action.*;
-import org.eclipse.jface.viewers.*;
-import org.eclipse.ui.*;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.ide.IGotoMarker;
-import org.eclipse.ui.part.MultiPageSelectionProvider;
-import org.eclipse.ui.texteditor.IStatusField;
-import org.eclipse.ui.texteditor.ITextEditorExtension;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-import org.eclipse.ui.views.properties.PropertySheetPage;
-
-public class JETEditor extends FormEditor implements ITextEditorExtension, IMenuListener, IGotoMarker {
-
- public static final String ID = "org.eclipse.jet.internal.editor";
- public static final String copyright = "(c) 2006 Joel Cheuoua & Contributors";
- protected IStatusLineManager contentOutlineStatusLineManager;
- protected TreeViewer contentOutlineViewer;
- protected PropertySheetPage propertySheetPage;
- protected ISelectionChangedListener selectionChangedListener;
- protected JETTextEditor jetTextEditor;
-
- public JETEditor() {
- jetTextEditor = new JETTextEditor();
- }
-
- public JETTextEditor getJetTextEditor() {
- return jetTextEditor;
- }
-
- public void addPages() {
- try {
- int pageIndex = addPage(jetTextEditor, getEditorInput());
- setPageText(pageIndex, "Edition");
- } catch (PartInitException e) {
- e.printStackTrace();
- }
- Viewer viewer = new JETTextPreviewViewer(getContainer());
- viewer.setInput(getEditorInput());
- int pageIndex = addPage(viewer.getControl());
- setPageText(pageIndex, "Preview");
- }
-
- public Object getAdapter(Class key) {
- if (key.equals(IContentOutlinePage.class))
- return jetTextEditor.getAdapter(key);
- if (key.equals(IPropertySheetPage.class))
- return getPropertySheetPage();
- if (key.equals(IGotoMarker.class))
- return this;
- else
- return super.getAdapter(key);
- }
-
- public IPropertySheetPage getPropertySheetPage() {
- return propertySheetPage;
- }
-
- public boolean isDirty() {
- return jetTextEditor != null && jetTextEditor.isDirty();
- }
-
- public void doSave(IProgressMonitor progressMonitor) {
- if (jetTextEditor != null)
- jetTextEditor.doSave(progressMonitor);
- }
-
- public boolean isSaveAsAllowed() {
- if (jetTextEditor != null)
- return jetTextEditor.isSaveAsAllowed();
- else
- return true;
- }
-
- public void doSaveAs() {
- if (jetTextEditor != null)
- jetTextEditor.doSaveAs();
- }
-
- public void gotoMarker(IMarker marker) {
- if (jetTextEditor != null) {
- IGotoMarker gotoMarker = (IGotoMarker) jetTextEditor.getAdapter(IGotoMarker.class);
- if (gotoMarker != null)
- gotoMarker.gotoMarker(marker);
- }
- }
-
- public void init(IEditorSite site, IEditorInput editorInput) throws PartInitException {
- setSite(site);
- setInput(editorInput);
- jetTextEditor.init(site, editorInput);
- setPartName(editorInput.getName());
- site.setSelectionProvider(new MultiPageSelectionProvider(this));
- }
-
- public void menuAboutToShow(IMenuManager menuManager) {
- ((IMenuListener) getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
- }
-
- public void dispose() {
- if (jetTextEditor != null)
- jetTextEditor.dispose();
- super.dispose();
- }
-
- public void setStatusField(IStatusField field, String category) {
- if (jetTextEditor != null)
- jetTextEditor.setStatusField(field, category);
- }
-
- public boolean isEditorInputReadOnly() {
- if (jetTextEditor != null)
- jetTextEditor.isEditorInputReadOnly();
- return false;
- }
-
- public void addRulerContextMenuListener(IMenuListener listener) {
- if (jetTextEditor != null)
- jetTextEditor.addRulerContextMenuListener(listener);
- }
-
- public void removeRulerContextMenuListener(IMenuListener listener) {
- if (jetTextEditor != null)
- jetTextEditor.removeRulerContextMenuListener(listener);
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditorHelper.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditorHelper.java
deleted file mode 100644
index 2adf8c1..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETEditorHelper.java
+++ /dev/null
@@ -1,455 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import java.net.URI;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.IProblemRequestor;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.WorkingCopyOwner;
-import org.eclipse.jdt.core.compiler.IProblem;
-import org.eclipse.jdt.core.eval.IEvaluationContext;
-import org.eclipse.jdt.internal.ui.text.java.AbstractJavaCompletionProposal;
-import org.eclipse.jdt.ui.text.java.CompletionProposalCollector;
-import org.eclipse.jdt.ui.text.java.IJavaCompletionProposal;
-import org.eclipse.jet.compiler.CompileOptionsManager;
-import org.eclipse.jet.core.compiler.JETCompilerOptions;
-import org.eclipse.jet.core.parser.ProblemSeverity;
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.JavaDeclaration;
-import org.eclipse.jet.core.parser.ast.JavaExpression;
-import org.eclipse.jet.core.parser.ast.JavaScriptlet;
-import org.eclipse.jet.core.parser.ast.Problem;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.Document;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Position;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.ui.IFileEditorInput;
-
-/**
- * Helper class for code completion and JET compilation unit processing purposespurposes
- * @author Joel
- *
- */
-public class JETEditorHelper {
- /**
- * Problem requestor for java expressions of the JET template
- * @author Joel
- *
- */
- private static final class JETJavaContentProblemRequestor implements IProblemRequestor {
-
- /**
- * The JET problems computed from the java problems
- */
- private List problems;
-
- /**
- * The problems collected from the compiled java source
- */
- private List javaProblems;
-
- /**
- * The jet source
- */
- private IDocument jetDocument;
-
- private Map mappingPositions;
-
- private JETJavaContentProblemRequestor(List problems, Map mappings, IDocument jetDocument) {
- this.problems = problems;
- mappingPositions = mappings;
- javaProblems = new ArrayList();
- this.jetDocument = jetDocument;
- }
-
- /**
- * @return
- */
- public List getProblems() {
- return problems;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.core.IProblemRequestor#acceptProblem(org.eclipse.jdt.core.compiler.IProblem)
- */
- public void acceptProblem(IProblem problem) {
- javaProblems.add(problem);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.core.IProblemRequestor#beginReporting()
- */
- public void beginReporting() {
- javaProblems.clear();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.core.IProblemRequestor#endReporting()
- */
- public void endReporting() {
- Problem problem;
- // walk through the java problems collected from the generated java source and create the
- // corresponding JET problems in the JET source using the position mappings
- for (Iterator iter = javaProblems.iterator(); iter.hasNext(); ) {
- IProblem javaProblem = (IProblem) iter.next();
-
- int javaProblemOffset = javaProblem.getSourceStart();
- int problemLength = (javaProblem.getSourceEnd() - javaProblemOffset) + 1;
-
- // Retrieve the corresponding JET AST Element and its position in the JET source
- JETASTElement astElement = getElementForJavaOffset(javaProblemOffset);
- Position pos = (Position) mappingPositions.get(astElement);
-
- // jetOffset =
- // start position of the AST element in JET Code +
- // offset till the position delimited by the javaProblemOffset
- // The offset till the position delimited by the javaProblemOffset
- // depends on the starting offset of the java content in the JET AST element.
- // This is due to the fact that the JET AST element first position does not represents the starting offset of
- // offset of its java content.
-
- int astElementJavaContentStart = pos == null ? -1 : pos.getOffset();
- int jetOffset = pos == null ? 0 : JETEditorHelper.getASTElementContentStart(astElement, jetDocument) + (javaProblemOffset - astElementJavaContentStart);
-
- // Create the problem at the specified location
- URI baseLocation = URI.create("");
- problem = new Problem(baseLocation,
- "",
- javaProblem.isWarning() ? ProblemSeverity.WARNING : ProblemSeverity.ERROR,
- -1,
- javaProblem.getMessage(),
- javaProblem.getArguments(),
- jetOffset,
- jetOffset + problemLength,
- -1,
- -1);
- // add the problem to the problems list
- problems.add(problem);
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.core.IProblemRequestor#isActive()
- */
- public boolean isActive() {
- return true;
- }
-
- /**
- * Find the JET AST element that matches the given java offset in
- * the generated java template source
- * @param javaOffset
- * @return
- */
- private JETASTElement getElementForJavaOffset(int javaOffset) {
- for (Iterator iterator = mappingPositions.keySet().iterator(); iterator.hasNext();) {
- JETASTElement element = (JETASTElement) iterator.next();
- Position pos = (Position) mappingPositions.get(element);
- if (pos.getOffset() <= javaOffset && javaOffset < pos.getOffset() + pos.getLength())
- return element;
- }
- return null;
- }
- } // End class JETJavaContentProblemRequestor
-
- /**
- * @param astElement
- * @param jetDocument
- * @return
- */
- public static int getASTElementContentStart(JETASTElement astElement, IDocument jetDocument) {
- int jetStart = astElement.getStart();
- if (astElement instanceof JavaDeclaration)
- jetStart += 3;
- if ((astElement instanceof JavaExpression) || (astElement instanceof JavaScriptlet))
- try {
- String jetSnippet = jetDocument.get(jetStart, astElement.getEnd() - jetStart);
- String javaContent = (astElement instanceof JavaExpression) ? ((JavaExpression) astElement).getJavaContent()
- : ((JavaScriptlet) astElement).getJavaContent();
- int idx = jetSnippet.indexOf(javaContent);
- jetStart += idx;
- } catch (BadLocationException e) {
- Activator.log(e);
- }
- return jetStart;
- }
-
- public static boolean checkOffsetPositions(String javaSource, String jetSource, int jetOffset, int javaOffset, int checkDepth) {
- boolean result = false;
-
- String javaCheckString = javaSource.substring(javaOffset, Math.min(javaSource.length(), javaOffset + checkDepth));
- String jetCheckString = jetSource.substring(jetOffset, Math.min(jetSource.length(), jetOffset + checkDepth));
- result = javaCheckString.compareTo(jetCheckString) == 0;
- if (!result) {
- System.err.println("position matching error");
- System.err.println("JET Check String : " + jetCheckString);
- System.err.println("Java Check String : " + javaCheckString);
- }
- return result;
- }
-
- /**
- * @param jetEditor
- * @param cu
- * @param jetDocument
- * @return
- */
- public static List evaluateProblems(JETTextEditor jetEditor, IDocument jetDocument) {
- JETCompilationUnit cu = jetEditor.requestCompilationUnit();
- String packageName = cu.getOutputJavaPackage();
- String className = cu.getOutputJavaClassName();
- List problems = new ArrayList();
- if (packageName == null || className == null)
- return problems;
- Map mappingPositions = new HashMap();
- String javaSource = jetEditor.compilationHelper().getJavaCode(cu, mappingPositions);
- JETJavaContentProblemRequestor problemRequestor =
- new JETJavaContentProblemRequestor(problems,
- mappingPositions,
- jetDocument);
- try {
- ICompilationUnit compilationUnit = null;
- IJavaProject javaProject = jetEditor.getJavaProject();
- IPackageFragmentRoot roots[] = javaProject.getPackageFragmentRoots();
- for (int i = 0; i < roots.length;) {
- IPackageFragmentRoot root = roots[i];
- IPackageFragment packageFragment = root.getPackageFragment(packageName);
- if (packageFragment == null || !packageFragment.exists())
- packageFragment = root.createPackageFragment(packageName, true, new NullProgressMonitor());
- compilationUnit = packageFragment.createCompilationUnit(
- (new StringBuilder(String.valueOf(className))).append(".java").toString(),
- javaSource,
- true,
- new NullProgressMonitor());
- break;
- }
- WorkingCopyOwner owner = new WorkingCopyOwner() {};
- ICompilationUnit copy = compilationUnit.getWorkingCopy(owner, problemRequestor, null);
- copy.reconcile(0, true, owner, null);
- } catch (JavaModelException e) {
- Activator.log(e);
- }
- return problems;
- }
-
- /**
- * @param javaProject
- * @param cu
- * @param codeSnippet
- * @param offset
- * @return
- */
- public static CompletionProposalCollector collect(IJavaProject javaProject, JETCompilationUnit cu,
- String codeSnippet, int offset) {
- IEvaluationContext context;
- CompletionProposalCollector proposalCollector;
- context = javaProject.newEvaluationContext();
- List importList = new ArrayList();
- importList.addAll(cu.getImports());
- importList.add("org.eclipse.jet.JET2Context");
- importList.add("org.eclipse.jet.JET2Template");
- importList.add("org.eclipse.jet.JET2Writer");
- importList.add("org.eclipse.jet.taglib.RuntimeTagElement");
- importList.add("org.eclipse.jet.taglib.TagInfo");
- String imports[] = new String[importList.size()];
- importList.toArray(imports);
- String packageName = cu.getOutputJavaPackage();
- if (packageName == null) {
- Map options = CompileOptionsManager.getOptions(javaProject.getProject());
- if (options.isEmpty())
- options = JETCompilerOptions.getDefaultCompilerOptions();
- packageName = (String) options.get("org.eclipse.jet.compiledTemplatePackage");
- }
- context.setPackageName(packageName);
- context.setImports(imports);
- proposalCollector = new CompletionProposalCollector(javaProject);
- try {
- context.codeComplete(codeSnippet, offset, proposalCollector);
- return proposalCollector;
- } catch (JavaModelException e) {
- Activator.log(e);
- }
- return null;
- }
-
- /**
- * @param editor
- * @param viewer
- * @param completionOffset
- * @return
- */
- public static IJavaCompletionProposal[] getJavaCompletionProposal(JETTextEditor jetEditor, ITextViewer viewer,
- int completionOffset) {
- IJavaProject javaProject;
- String packageName;
- String className;
- Map mappingPositions;
- IDocument javaDocument;
- JETCompilationUnit cu = jetEditor.requestCompilationUnit();
- javaProject = jetEditor.getJavaProject();
- packageName = cu.getOutputJavaPackage();
- className = cu.getOutputJavaClassName();
- if (packageName == null) {
- Map options = CompileOptionsManager.getOptions(javaProject.getProject());
- if (options.isEmpty())
- options = JETCompilerOptions.getDefaultCompilerOptions();
- packageName = (String) options.get("org.eclipse.jet.compiledTemplatePackage");
- }
- if (className == null && (jetEditor.getEditorInput() instanceof IFileEditorInput)) {
- IFile file = ((IFileEditorInput) jetEditor.getEditorInput()).getFile();
- String inputName = file.getFullPath().removeFileExtension().lastSegment();
- String baseClassName = makeJavaClassName(inputName);
- className = baseClassName;
- }
- if (packageName == null || className == null)
- return new IJavaCompletionProposal[0];
- mappingPositions = new HashMap();
- javaDocument = new Document(jetEditor.compilationHelper().getJavaCode(cu, mappingPositions));
- IJavaCompletionProposal results[];
- ICompilationUnit compilationUnit = null;
- try {
- IPackageFragmentRoot roots[] = javaProject.getPackageFragmentRoots();
- for (int i = 0; i < roots.length;) {
- IPackageFragmentRoot root = roots[i];
- IPackageFragment packageFragment = root.getPackageFragment(packageName);
- if (packageFragment == null || !packageFragment.exists())
- packageFragment = root.createPackageFragment(packageName, true, new NullProgressMonitor());
- compilationUnit = packageFragment.createCompilationUnit((new StringBuilder(String.valueOf(className))).append(
- ".java").toString(), javaDocument.get(), true, new NullProgressMonitor());
- break;
- }
-
- CompletionProposalCollector proposalCollector = new CompletionProposalCollector(compilationUnit);
- JETASTElement astElement = jetEditor.getASTElement(completionOffset);
- Position javaPosition = (Position) mappingPositions.get(astElement);
- int jetStart = getASTElementContentStart(astElement, viewer.getDocument());
- int javaStart = javaPosition.getOffset();
- int javaCompletionOffset = javaStart + (completionOffset - jetStart);
- compilationUnit.codeComplete(javaCompletionOffset, proposalCollector);
- Point selection = viewer.getSelectedRange();
- if (selection.y > 0)
- proposalCollector.setReplacementLength(selection.y);
- IJavaCompletionProposal javaProposals[] = proposalCollector.getJavaCompletionProposals();
- IJavaCompletionProposal keywordsProposals[] = proposalCollector.getKeywordCompletionProposals();
- IJavaCompletionProposal unsortedJavaProposals[] = new IJavaCompletionProposal[javaProposals.length
- + keywordsProposals.length];
- System.arraycopy(keywordsProposals, 0, unsortedJavaProposals, 0, keywordsProposals.length);
- System.arraycopy(javaProposals, 0, unsortedJavaProposals, keywordsProposals.length, javaProposals.length);
- List sortedJavaProposals = new LinkedList();
- for (int i = 0; i < unsortedJavaProposals.length; i++) {
- IJavaCompletionProposal unsortedJavaProposal = unsortedJavaProposals[i];
- int index = 0;
- for (Iterator iterator = sortedJavaProposals.iterator(); iterator.hasNext();) {
- IJavaCompletionProposal proposal = (IJavaCompletionProposal) iterator.next();
- if (proposal.getRelevance() <= unsortedJavaProposal.getRelevance()) {
- index = sortedJavaProposals.indexOf(proposal);
- break;
- }
- }
-
- sortedJavaProposals.add(index, unsortedJavaProposal);
- }
-
- results = new IJavaCompletionProposal[sortedJavaProposals.size()];
- sortedJavaProposals.toArray(results);
- adjustResults(results, completionOffset);
- return results;
- } catch (JavaModelException e) {
- Activator.log(e);
- }
- return new IJavaCompletionProposal[0];
- }
-
- /**
- * @param javaProject
- * @param cu
- * @param codeSnippet
- * @param viewer
- * @param offset
- * @return
- */
- public static IJavaCompletionProposal[] getJavaCompletionProposal(IJavaProject javaProject, JETCompilationUnit cu,
- String codeSnippet, ITextViewer viewer, int offset) {
- CompletionProposalCollector proposalCollector = collect(javaProject, cu, codeSnippet, offset);
- if (proposalCollector != null) {
- Point selection = viewer.getSelectedRange();
- if (selection.y > 0)
- proposalCollector.setReplacementLength(selection.y);
- IJavaCompletionProposal javaProposals[] = proposalCollector.getJavaCompletionProposals();
- IJavaCompletionProposal keywordsProposals[] = proposalCollector.getKeywordCompletionProposals();
- IJavaCompletionProposal unsortedJavaProposals[] = new IJavaCompletionProposal[javaProposals.length
- + keywordsProposals.length];
- System.arraycopy(keywordsProposals, 0, unsortedJavaProposals, 0, keywordsProposals.length);
- System.arraycopy(javaProposals, 0, unsortedJavaProposals, keywordsProposals.length, javaProposals.length);
- List sortedJavaProposals = new LinkedList();
- for (int i = 0; i < unsortedJavaProposals.length; i++) {
- IJavaCompletionProposal unsortedJavaProposal = unsortedJavaProposals[i];
- int index = 0;
- for (Iterator iterator = sortedJavaProposals.iterator(); iterator.hasNext();) {
- IJavaCompletionProposal proposal = (IJavaCompletionProposal) iterator.next();
- if (proposal.getRelevance() <= unsortedJavaProposal.getRelevance()) {
- index = sortedJavaProposals.indexOf(proposal);
- break;
- }
- }
- sortedJavaProposals.add(index, unsortedJavaProposal);
- }
-
- IJavaCompletionProposal results[] = new IJavaCompletionProposal[sortedJavaProposals.size()];
- sortedJavaProposals.toArray(results);
- return results;
- } else {
- return new IJavaCompletionProposal[0];
- }
- }
-
- /**
- * @param results
- * @param offset
- */
- public static void adjustResults(IJavaCompletionProposal[] results, int offset) {
- for (int i = 0; i < results.length; i++)
- if (results[i] instanceof AbstractJavaCompletionProposal) {
- AbstractJavaCompletionProposal proposal = (AbstractJavaCompletionProposal) results[i];
- proposal.setReplacementOffset(offset);
- }
- }
-
- /**
- * @param name
- * @return
- */
- public static String makeJavaClassName(String name) {
- StringBuffer result = new StringBuffer("_jet_");
- for (int i = 0; i < name.length(); i++) {
- char c = name.charAt(i);
- if (Character.isJavaIdentifierPart(c))
- result.append(c);
- }
- return result.toString();
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETSourceViewer.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETSourceViewer.java
deleted file mode 100644
index 0101961..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETSourceViewer.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.text.source.IOverviewRuler;
-import org.eclipse.jface.text.source.IVerticalRuler;
-import org.eclipse.jface.text.source.projection.ProjectionViewer;
-import org.eclipse.jface.util.IPropertyChangeListener;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.swt.custom.StyledText;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
-
-public class JETSourceViewer extends ProjectionViewer implements IPropertyChangeListener {
-
- private IPreferenceStore preferenceStore;
- private Color foregroundColor;
- private Color backgroundColor;
- private Color selectionForegroundColor;
- private Color selectionBackgroundColor;
-
- public JETSourceViewer(Composite parent, IVerticalRuler ruler, IOverviewRuler overviewRuler,
- boolean showsAnnotationOverview, int styles, IPreferenceStore store) {
- super(parent, ruler, overviewRuler, showsAnnotationOverview, styles);
- setPreferenceStore(store);
- }
-
- public void setPreferenceStore(IPreferenceStore store) {
- if (preferenceStore != null)
- preferenceStore.removePropertyChangeListener(this);
- preferenceStore = store;
- if (preferenceStore != null) {
- preferenceStore.addPropertyChangeListener(this);
- initializeViewerColors();
- }
- }
-
- private void initializeViewerColors() {
- if (preferenceStore != null) {
- StyledText styledText = getTextWidget();
- if (styledText == null || styledText.isDisposed())
- return;
- Color color = preferenceStore.getBoolean("AbstractTextEditor.Color.Foreground.SystemDefault") ? null
- : createColor(preferenceStore, "AbstractTextEditor.Color.Foreground", styledText.getDisplay());
- styledText.setForeground(color);
- if (foregroundColor != null)
- foregroundColor.dispose();
- foregroundColor = color;
- color = preferenceStore.getBoolean("AbstractTextEditor.Color.Background.SystemDefault") ? null : createColor(
- preferenceStore, "AbstractTextEditor.Color.Background", styledText.getDisplay());
- styledText.setBackground(color);
- if (backgroundColor != null)
- backgroundColor.dispose();
- backgroundColor = color;
- color = preferenceStore.getBoolean("AbstractTextEditor.Color.SelectionForeground.SystemDefault") ? null
- : createColor(preferenceStore, "AbstractTextEditor.Color.SelectionForeground", styledText.getDisplay());
- styledText.setSelectionForeground(color);
- if (selectionForegroundColor != null)
- selectionForegroundColor.dispose();
- selectionForegroundColor = color;
- color = preferenceStore.getBoolean("AbstractTextEditor.Color.SelectionBackground.SystemDefault") ? null
- : createColor(preferenceStore, "AbstractTextEditor.Color.SelectionBackground", styledText.getDisplay());
- styledText.setSelectionBackground(color);
- if (selectionBackgroundColor != null)
- selectionBackgroundColor.dispose();
- selectionBackgroundColor = color;
- }
- }
-
- private Color createColor(IPreferenceStore store, String key, Display display) {
- org.eclipse.swt.graphics.RGB rgb = null;
- if (store.contains(key)) {
- if (store.isDefault(key))
- rgb = PreferenceConverter.getDefaultColor(store, key);
- else
- rgb = PreferenceConverter.getColor(store, key);
- if (rgb != null)
- return new Color(display, rgb);
- }
- return null;
- }
-
- public void propertyChange(PropertyChangeEvent event) {
- String property = event.getProperty();
- if ("AbstractTextEditor.Color.Foreground".equals(property)
- || "AbstractTextEditor.Color.Foreground.SystemDefault".equals(property)
- || "AbstractTextEditor.Color.Background".equals(property)
- || "AbstractTextEditor.Color.Background.SystemDefault".equals(property)
- || "AbstractTextEditor.Color.SelectionForeground".equals(property)
- || "AbstractTextEditor.Color.SelectionForeground.SystemDefault".equals(property)
- || "AbstractTextEditor.Color.SelectionBackground".equals(property)
- || "AbstractTextEditor.Color.SelectionBackground.SystemDefault".equals(property))
- initializeViewerColors();
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextEditor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextEditor.java
deleted file mode 100644
index f8c5f14..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextEditor.java
+++ /dev/null
@@ -1,449 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2009 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IExtensionRegistry;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jet.core.parser.ast.Comment;
-import org.eclipse.jet.core.parser.ast.IncludedContent;
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JETASTVisitor;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.JETDirective;
-import org.eclipse.jet.core.parser.ast.JavaDeclaration;
-import org.eclipse.jet.core.parser.ast.JavaExpression;
-import org.eclipse.jet.core.parser.ast.JavaScriptlet;
-import org.eclipse.jet.core.parser.ast.TextElement;
-import org.eclipse.jet.core.parser.ast.XMLBodyElement;
-import org.eclipse.jet.core.parser.ast.XMLBodyElementEnd;
-import org.eclipse.jet.core.parser.ast.XMLEmptyElement;
-import org.eclipse.jet.internal.compiler.CompilationHelper;
-import org.eclipse.jet.internal.editor.configuration.JETDocumentProvider;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETSourceViewerConfiguration;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate;
-import org.eclipse.jet.internal.editor.outline.JETOutlinePage;
-import org.eclipse.jet.internal.editor.partition.JETDocumentPartitionScanner;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.internal.text.html.HTMLTextPresenter;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.DefaultInformationControl;
-import org.eclipse.jface.text.DocumentEvent;
-import org.eclipse.jface.text.IInformationControl;
-import org.eclipse.jface.text.IInformationControlCreator;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.jface.text.source.IVerticalRuler;
-import org.eclipse.jface.text.source.projection.ProjectionSupport;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.editors.text.IEncodingSupport;
-import org.eclipse.ui.editors.text.TextEditor;
-import org.eclipse.ui.texteditor.ContentAssistAction;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.osgi.framework.Bundle;
-
-/**
- * The editor for JET templates files
- * @author Joel
- */
-public class JETTextEditor extends TextEditor {
-
- private JETTokenStyleManager tokenStyleManager;
-
- private JETSourceViewer sourceViewer;
-
- private JETDocumentPartitionScanner partitionScanner;
-
- private ProjectionSupport projectionSupport;
-
- private IContentOutlinePage outlinePage;
-
- private JETCompilationUnit cUnit;
-
- private IProject project;
-
- private Map positions;
-
- private boolean cUnitInvalidated;
-
- private ArrayList defaultContentColorerDelegates;
-
- private IJETDefaultTextColorerDelegate currentDelegate;
-
- /**
- * Creates a new JET editor
- */
- public JETTextEditor() {
- positions = Collections.EMPTY_MAP;
- IPreferenceStore preferenceStore = Activator.getDefault().getPreferenceStore();
- JETEditorPreferenceConstants.initializeDefaultValues(preferenceStore);
- setPreferenceStore(preferenceStore);
- tokenStyleManager = new JETTokenStyleManager(preferenceStore);
- partitionScanner = new JETDocumentPartitionScanner(this);
- setSourceViewerConfiguration(new JETSourceViewerConfiguration(this));
- setDocumentProvider(new JETDocumentProvider(this));
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.editors.text.TextEditor#dispose()
- */
- public void dispose() {
- tokenStyleManager.dispose();
- super.dispose();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.texteditor.AbstractTextEditor#init(org.eclipse.ui.IEditorSite, org.eclipse.ui.IEditorInput)
- */
- public void init(IEditorSite site, IEditorInput input) throws PartInitException {
- if (input instanceof IFileEditorInput)
- project = ((IFileEditorInput) input).getFile().getProject();
- super.init(site, input);
- initDefaultContentColorerDelegetes();
- if (!defaultContentColorerDelegates.isEmpty())
- currentDelegate = (IJETDefaultTextColorerDelegate) defaultContentColorerDelegates.get(0);
- }
-
- /**
- * Set the content colorer delegate (used for syntax coloring of non JET text) to use.
- * @param delegate
- */
- public void setCurrentColorerDelegate(IJETDefaultTextColorerDelegate delegate) {
- currentDelegate = delegate;
- // notify the damager repairers so that they recompute the partitions and the tokens to colorize
- partitionScanner.updateJETTextContentDamagerRepairer();
- // reset the text display
- if (isDirty())
- getSourceViewer().getDocument().set(getSourceViewer().getDocument().get());
- else
- setInput(getEditorInput());
- }
-
- /**
- * Returns the content colorer delegate (used for syntax coloring of non JET text) in use.
- * @return the content colorer delegate
- */
- public IJETDefaultTextColorerDelegate getCurrentColorerDelegate() {
- return currentDelegate;
- }
-
- /**
- * Returns the list of all the available (registered) content colorer delegates.
- * @return
- */
- public IJETDefaultTextColorerDelegate[] getColorerDelegates() {
- IJETDefaultTextColorerDelegate results[] = new IJETDefaultTextColorerDelegate[defaultContentColorerDelegates.size()];
- defaultContentColorerDelegates.toArray(results);
- return results;
- }
-
- /**
- * Compute the list of the registered content colorer delegates.
- */
- private void initDefaultContentColorerDelegetes() {
- defaultContentColorerDelegates = new ArrayList();
- IExtensionRegistry registry = Platform.getExtensionRegistry();
- IConfigurationElement elements[] = registry.getConfigurationElementsFor("org.eclipse.jet.internal.editor",
- "defaultContentColorerDelegates");
- for (int i = 0; i < elements.length; i++) {
- IConfigurationElement element = elements[i];
- Bundle bundle = Platform.getBundle(element.getNamespaceIdentifier());
- String delegateClass = element.getAttribute("delegateClass");
- IJETDefaultTextColorerDelegate delegate = null;
- try {
- Class clazz = bundle.loadClass(delegateClass);
- Class argTypes[] = { JETTextEditor.class };
- Constructor ctorWithTextEditor = null;
- try {
- ctorWithTextEditor = clazz.getConstructor(argTypes);
- } catch (SecurityException e) {
- Activator.log(e);
- } catch (NoSuchMethodException e) {
- Activator.log(e);
- }
- if (ctorWithTextEditor != null)
- delegate = (IJETDefaultTextColorerDelegate) ctorWithTextEditor.newInstance(new Object[] { this });
- else
- delegate = (IJETDefaultTextColorerDelegate) clazz.newInstance();
- defaultContentColorerDelegates.add(delegate);
- } catch (ClassNotFoundException e) {
- Activator.log(e);
- } catch (InstantiationException e) {
- Activator.log(e);
- } catch (IllegalAccessException e) {
- Activator.log(e);
- } catch (IllegalArgumentException e) {
- Activator.log(e);
- } catch (InvocationTargetException e) {
- Activator.log(e);
- }
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.texteditor.AbstractDecoratedTextEditor#createSourceViewer(org.eclipse.swt.widgets.Composite, org.eclipse.jface.text.source.IVerticalRuler, int)
- */
- protected ISourceViewer createSourceViewer(Composite parent, IVerticalRuler ruler, int styles) {
- fAnnotationAccess = getAnnotationAccess();
- fOverviewRuler = createOverviewRuler(getSharedColors());
- sourceViewer = new JETSourceViewer(parent, ruler, getOverviewRuler(), isOverviewRulerVisible(), styles,
- getPreferenceStore());
- getSourceViewerDecorationSupport(sourceViewer);
- projectionSupport = new ProjectionSupport(sourceViewer, getAnnotationAccess(), getSharedColors());
- projectionSupport.addSummarizableAnnotationType("org.eclipse.ui.workbench.texteditor.error");
- projectionSupport.addSummarizableAnnotationType("org.eclipse.ui.workbench.texteditor.warning");
- projectionSupport.setHoverControlCreator(new IInformationControlCreator() {
- public IInformationControl createInformationControl(Shell shell) {
- return new DefaultInformationControl(shell, getOrientation(), 0, new HTMLTextPresenter());
- }
- });
- projectionSupport.install();
- return sourceViewer;
- }
-
- /**
- * Return the editor's source viewer. This method exist to make this viewer accessible to other classes.
- * @return the editor's source viewer
- */
- public ISourceViewer getEditorSourceViewer() {
- return sourceViewer;
- }
-
- /**
- * Returns the editor's preference store. This method exist to make the preference store accessible to other classes.
- * @return the editor's preference store
- */
- public IPreferenceStore getEditorPreferenceStore() {
- return super.getPreferenceStore();
- }
-
- public JETDocumentPartitionScanner getPartitionScanner() {
- return partitionScanner;
- }
-
- public JETTokenStyleManager getTokenStyleManager() {
- return tokenStyleManager;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.texteditor.StatusTextEditor#handleEditorInputChanged()
- */
- protected void handleEditorInputChanged() {
- super.handleEditorInputChanged();
- handleDocumentChange(null);
- }
-
- public void handleDocumentChange(DocumentEvent e) {
- cUnitInvalidated = true;
- if (outlinePage != null && outlinePage.getControl().isVisible())
- ((JETOutlinePage) outlinePage).setInput();
- }
-
- public boolean isCUnitInvalidated() {
- return cUnitInvalidated;
- }
-
- public CompilationHelper compilationHelper() {
- CompilationHelper jetCompilationHelper = new CompilationHelper(project);
- return jetCompilationHelper;
- }
-
- /**
- * Compute and retrun the compilation unit of this document
- * @return the computed (or recomputed) compilation unit for this template
- */
- public JETCompilationUnit requestCompilationUnit() {
- if (cUnit == null || cUnitInvalidated) {
- IEditorInput editorInput = getEditorInput();
- String templatePath = editorInput.getName();
- if (editorInput instanceof IFileEditorInput)
- templatePath = ((IFileEditorInput)editorInput).getFile().getProjectRelativePath().toString();
- if (sourceViewer == null) { // sourceViewer is null ... we can parse from the file directly
- cUnit = compilationHelper().getAST(templatePath);
- } else {
- cUnit = compilationHelper().getASTFromSource(sourceViewer.getDocument().get(), templatePath);
- }
- PositionsCollector collector = new PositionsCollector();
- cUnit.accept(collector);
- positions = collector.getPositions();
- cUnitInvalidated = false;
- }
- return cUnit;
- }
-
- public JETASTElement getASTElement(int offset) {
- requestCompilationUnit();
- return getCachedASTElement(offset);
- }
-
- public JETASTElement getCachedASTElement(int offset) {
- for (Iterator iterator = positions.keySet().iterator(); iterator.hasNext();) {
- Position pos = (Position) iterator.next();
- if (pos.offset <= offset && pos.length + pos.offset > offset)
- return (JETASTElement) positions.get(pos);
- }
- return null;
- }
-
- public IJavaProject getJavaProject() {
- return JavaCore.create(project);
- }
-
- protected void createActions() {
- super.createActions();
- ResourceBundle resourceBundle = ResourceBundle.getBundle("org.eclipse.jet.internal.editor.i18n.TextEditorMessages");
- Action action = new ContentAssistAction(resourceBundle, "ContentAssistProposal.", this);
- action.setActionDefinitionId("org.eclipse.ui.edit.text.contentAssist.proposals");
- setAction("ContentAssistProposal", action);
- markAsStateDependentAction("ContentAssistProposal", true);
- }
-
- protected void handlePreferenceStoreChanged(PropertyChangeEvent event) {
- super.handlePreferenceStoreChanged(event);
- if (event.getNewValue() instanceof RGB)
- getTokenStyleManager().bindColor(event.getProperty(), (RGB) event.getNewValue());
- }
-
- public Object getAdapter(Class required) {
- if (IContentOutlinePage.class.equals(required)) {
- if (outlinePage == null)
- outlinePage = createOutlinePage();
- return outlinePage;
- }
- if (IEncodingSupport.class.equals(required))
- return fEncodingSupport;
- if (projectionSupport != null) {
- Object adapter = projectionSupport.getAdapter(getSourceViewer(), required);
- if (adapter != null)
- return adapter;
- }
- return super.getAdapter(required);
- }
-
- public void editorContextMenuAboutToShow(IMenuManager menu) {
- super.editorContextMenuAboutToShow(menu);
- addAction(menu, "settings", "setDelegateColorerActionID");
- }
-
- protected IContentOutlinePage createOutlinePage() {
- JETOutlinePage page = new JETOutlinePage(this);
- page.addSelectionChangedListener(new ISelectionChangedListener() {
- public void selectionChanged(SelectionChangedEvent event) {
- handleContentOutlineSelection(event.getSelection());
- }
- });
- return page;
- }
-
- protected void handleContentOutlineSelection(ISelection selection) {
- IStructuredSelection ssel = (IStructuredSelection) selection;
- Object firstElement = ssel.getFirstElement();
- if (firstElement instanceof JETASTElement) {
- JETASTElement astElement = (JETASTElement) firstElement;
- int start = astElement.getStart();
- int end = astElement.getEnd();
- int length = end - start;
- if (astElement instanceof TextElement) {
- if (astElement.getPrevElement() != null)
- start = astElement.getPrevElement().getEnd();
- else
- start = 0;
- length = ((TextElement) astElement).getText().length;
- }
- sourceViewer.setSelectedRange(start, length);
- sourceViewer.revealRange(start, length);
- }
- }
-
- private static class PositionsCollector extends JETASTVisitor {
- private Map positions;
-
- private PositionsCollector() {
- positions = new HashMap();
- }
-
- public Map getPositions() {
- return positions;
- }
-
- public boolean visit(JavaDeclaration declaration) {
- return matchOffset(declaration);
- }
-
- public boolean visit(JETDirective directive) {
- return matchOffset(directive);
- }
-
- public boolean visit(JavaExpression expression) {
- return matchOffset(expression);
- }
-
- public boolean visit(IncludedContent content) {
- // don't process include content
- return false;
- }
-
- public boolean visit(JavaScriptlet scriptlet) {
- return matchOffset(scriptlet);
- }
-
- public boolean visit(XMLEmptyElement xmlEmptyElement) {
- return matchOffset(xmlEmptyElement);
- }
-
- public boolean visit(XMLBodyElement xmlBodyElement) {
- return matchOffset(xmlBodyElement);
- }
-
- public boolean visit(XMLBodyElementEnd xmlBodyElementEnd) {
- return matchOffset(xmlBodyElementEnd);
- }
-
- public boolean visit(Comment comment) {
- return matchOffset(comment);
- }
-
- public boolean matchOffset(JETASTElement astElement) {
- int start = astElement.getStart();
- int end = astElement.getEnd();
- int length = end - start;
- positions.put(new Position(start, length), astElement);
- return true;
- }
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextPreviewViewer.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextPreviewViewer.java
deleted file mode 100644
index b36e0d5..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/JETTextPreviewViewer.java
+++ /dev/null
@@ -1,203 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.emf.codegen.ecore.genmodel.provider.GenModelItemProviderAdapterFactory;
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.resource.ResourceSet;
-import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl;
-import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
-import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory;
-import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.text.source.SourceViewer;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.dialogs.ResourceSelectionDialog;
-import org.eclipse.ui.editors.text.EditorsUI;
-import org.eclipse.ui.editors.text.TextSourceViewerConfiguration;
-import org.eclipse.ui.forms.ManagedForm;
-import org.eclipse.ui.forms.SectionPart;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.forms.widgets.Section;
-
-public class JETTextPreviewViewer extends Viewer {
-
- private SourceViewer sourceViewer;
-
- private Object fInput;
-
- private ScrolledForm sForm;
-
- private Text inputResource;
-
- private Button browseWorkspace;
-
- private Tree tree;
-
- private TreeViewer treeViewer;
-
- private ISelection selection;
-
- public JETTextPreviewViewer(Composite parent) {
- inputResource = null;
- browseWorkspace = null;
- tree = null;
- treeViewer = null;
- org.eclipse.swt.widgets.Display display = parent.getDisplay();
- FormToolkit formToolkit = new FormToolkit(display);
- sForm = formToolkit.createScrolledForm(parent);
- ManagedForm overviewForm = new ManagedForm(formToolkit, sForm);
- Composite body = sForm.getBody();
- GridLayout layout = new GridLayout();
- layout.numColumns = 1;
- layout.marginWidth = 10;
- layout.horizontalSpacing = 10;
- layout.verticalSpacing = 10;
- body.setLayout(layout);
- createInputArgumentsSection(overviewForm, body, formToolkit);
- createTextViewerSection(overviewForm, body, formToolkit);
- overviewForm.initialize();
- overviewForm.refresh();
- }
-
- private void createInputArgumentsSection(ManagedForm mForm, Composite body, FormToolkit formToolkit) {
- final Section section = formToolkit.createSection(body, 256);
- section.setText("Input Argument");
- Composite client = formToolkit.createComposite(section);
- GridLayout layout = new GridLayout();
- layout.marginWidth = formToolkit.getBorderStyle() == 0 ? 2 : 0;
- layout.numColumns = 2;
- client.setLayout(layout);
- inputResource = formToolkit.createText(client, "<Empty>");
- inputResource.setEditable(false);
- GridData gd = new GridData();
- gd.horizontalSpan = 1;
- gd.grabExcessHorizontalSpace = true;
- gd.horizontalAlignment = 4;
- gd.grabExcessVerticalSpace = false;
- inputResource.setLayoutData(gd);
- browseWorkspace = formToolkit.createButton(client, "Browse ...", 0);
- browseWorkspace.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- ResourceSelectionDialog resSelectionDialog = new ResourceSelectionDialog(section.getShell(),
- ResourcesPlugin.getWorkspace().getRoot(), "Select a workspace resource");
- if (resSelectionDialog.open() == 0) {
- Object result[] = resSelectionDialog.getResult();
- if (result.length == 1) {
- String inputFile = ((IResource) result[0]).getFullPath().toString();
- inputResource.setText(inputFile);
- ResourceSet resourceSet = new ResourceSetImpl();
- URI uri = URI.createPlatformResourceURI(inputFile, true);
- org.eclipse.emf.ecore.resource.Resource resource = resourceSet.getResource(uri, true);
- if (resource != null)
- treeViewer.setInput(resourceSet);
- }
- }
- }
- });
- tree = formToolkit.createTree(client, 2052);
- gd = new GridData();
- gd.horizontalSpan = 2;
- gd.horizontalAlignment = 4;
- gd.verticalAlignment = 4;
- gd.grabExcessVerticalSpace = true;
- tree.setLayoutData(gd);
- treeViewer = new TreeViewer(tree);
- List factories = new ArrayList();
- factories.add(new ResourceItemProviderAdapterFactory());
- factories.add(new GenModelItemProviderAdapterFactory());
- factories.add(new ReflectiveItemProviderAdapterFactory());
- org.eclipse.emf.common.notify.AdapterFactory adapterFactory = new ComposedAdapterFactory(factories);
- treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
- treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
- Button button = formToolkit.createButton(client, "Apply", 0x800008);
- button.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- IFileEditorInput fileInput = (IFileEditorInput) getInput();
- IFile file = fileInput.getFile();
- JavaCore.create(file.getProject());
- }
- });
- section.setClient(client);
- gd = new GridData();
- gd.grabExcessHorizontalSpace = true;
- gd.horizontalAlignment = 4;
- gd.verticalAlignment = 1;
- section.setLayoutData(gd);
- SectionPart sectionPart = new SectionPart(section);
- mForm.addPart(sectionPart);
- }
-
- private void createTextViewerSection(ManagedForm mForm, Composite body, FormToolkit formToolkit) {
- Section section = formToolkit.createSection(body, 256);
- section.setText("Preview");
- org.eclipse.jface.preference.IPreferenceStore store = EditorsUI.getPreferenceStore();
- sourceViewer = new SourceViewer(section, null, 768);
- sourceViewer.configure(new TextSourceViewerConfiguration(store));
- sourceViewer.getTextWidget().setFont(JFaceResources.getFont("org.eclipse.jdt.ui.editors.textfont"));
- sourceViewer.setEditable(false);
- section.setClient(sourceViewer.getControl());
- GridData gd = new GridData();
- gd.horizontalAlignment = 4;
- gd.verticalAlignment = 4;
- gd.grabExcessHorizontalSpace = true;
- gd.grabExcessVerticalSpace = true;
- section.setLayoutData(gd);
- SectionPart sectionPart = new SectionPart(section);
- mForm.addPart(sectionPart);
- }
-
- public Control getControl() {
- return sForm;
- }
-
- public void setInput(Object input) {
- fInput = input;
- }
-
- public Object getInput() {
- return fInput;
- }
-
- public ISelection getSelection() {
- return selection;
- }
-
- public void setSelection(ISelection s, boolean reveal) {
- selection = s;
- }
-
- public void refresh() {
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/actions/SetContentColorerAction.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/actions/SetContentColorerAction.java
deleted file mode 100644
index 45f0470..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/actions/SetContentColorerAction.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.actions;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.*;
-import org.eclipse.ui.dialogs.ListDialog;
-
-public class SetContentColorerAction implements IEditorActionDelegate {
- private JETTextEditor editor;
-
- public SetContentColorerAction() {
- }
-
- public void setActiveEditor(IAction action, IEditorPart targetEditor) {
- editor = (JETTextEditor) targetEditor;
- action.setText("Set default content colorer ...");
- }
-
- public void run(IAction action) {
- ListDialog dialog = new ListDialog(editor.getSite().getShell());
- dialog.setLabelProvider(new LabelProvider() {
- public String getText(Object element) {
- if (element instanceof IJETDefaultTextColorerDelegate)
- return ((IJETDefaultTextColorerDelegate) element).getName();
- else
- return super.getText(element);
- }
-
- public Image getImage(Object element) {
- if (element instanceof IJETDefaultTextColorerDelegate)
- return ((IJETDefaultTextColorerDelegate) element).getImage();
- else
- return super.getImage(element);
- }
- });
- dialog.setContentProvider(new IStructuredContentProvider() {
- public Object[] getElements(Object inputElement) {
- return editor.getColorerDelegates();
- }
- public void dispose() {
- }
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- // TODO Auto-generated method stub
- }
- });
- dialog.setTitle("JET default text content colorer");
- dialog.setMessage("Select the content colorer to the default text embeded in the JET template");
- dialog.setInitialSelections(editor.getColorerDelegates());
- dialog.setInput(editor);
- int result = dialog.open();
- if (result == 0) {
- IJETDefaultTextColorerDelegate delegate = (IJETDefaultTextColorerDelegate) dialog.getResult()[0];
- editor.setCurrentColorerDelegate(delegate);
- }
- }
-
- public void selectionChanged(IAction iaction, ISelection iselection) {
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationHover.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationHover.java
deleted file mode 100644
index 8980eb3..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationHover.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.annotations;
-
-import java.util.*;
-import org.eclipse.jface.text.*;
-import org.eclipse.jface.text.source.*;
-
-public class JETAnnotationHover implements IAnnotationHover {
-
- /**
- * Returns the distance to the ruler line.
- * @param position Position
- * @param document IDocument
- * @param line int
- * @return int
- */
- protected int compareRulerLine(Position position, IDocument document, int line) {
- if (position.getOffset() > -1 && position.getLength() > -1) {
- try {
- int javaAnnotationLine = document.getLineOfOffset(position.getOffset());
- if (line == javaAnnotationLine)
- return 1;
- if (javaAnnotationLine <= line
- && line <= document.getLineOfOffset(position.getOffset() + position.getLength()))
- return 2;
- } catch (BadLocationException x) {
- }
- }
- return 0;
- }
- /**
- * Selects a set of markers from the two lists. By default, it just returns the set of exact
- * matches.
- * @param exactMatch List
- * @param including List
- * @return List
- */
- protected List select(List exactMatch, List including) {
- return exactMatch;
- }
- /**
- * Returns one marker which includes the ruler's line of activity.
- * @param viewer ISourceViewer
- * @param line int
- * @return List
- */
- protected List getAnnotationsForLine(ISourceViewer viewer, int line) {
- IDocument document = viewer.getDocument();
- IAnnotationModel model = viewer.getAnnotationModel();
- if (model == null)
- return null;
- List exact = new ArrayList();
- List including = new ArrayList();
- Iterator e = model.getAnnotationIterator();
- HashMap messagesAtPosition = new HashMap();
- while (e.hasNext()) {
- Object o = e.next();
- if (o instanceof JETProblemAnnotation) {
- JETProblemAnnotation a = (JETProblemAnnotation) o;
- Position position = model.getPosition(a);
- if (position != null && !isDuplicateAnnotation(messagesAtPosition, position, a.getText()))
- switch (compareRulerLine(position, document, line)) {
- case 1: // '\001'
- exact.add(a);
- break;
-
- case 2: // '\002'
- including.add(a);
- break;
- }
- }
- }
- return select(exact, including);
- }
- /**
- * Method isDuplicateAnnotation.
- * @param messagesAtPosition Map
- * @param position Position
- * @param message String
- * @return boolean
- */
- private boolean isDuplicateAnnotation(Map messagesAtPosition, Position position, String message) {
- if (messagesAtPosition.containsKey(position)) {
- Object value = messagesAtPosition.get(position);
- if (message.equals(value))
- return true;
- if (value instanceof List) {
- List messages = (List) value;
- if (messages.contains(message))
- return true;
- messages.add(message);
- } else {
- ArrayList messages = new ArrayList();
- messages.add(value);
- messages.add(message);
- messagesAtPosition.put(position, messages);
- }
- } else {
- messagesAtPosition.put(position, message);
- }
- return false;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.text.source.IAnnotationHover#getHoverInfo(org.eclipse.jface.text.source.ISourceViewer, int)
- */
- public String getHoverInfo(ISourceViewer sourceViewer, int lineNumber) {
- List annotations = getAnnotationsForLine(sourceViewer, lineNumber);
- if (annotations != null)
- if (annotations.size() == 1) {
- JETProblemAnnotation annotation = (JETProblemAnnotation) annotations.get(0);
- String message = annotation.getText();
- if (message != null && message.trim().length() > 0)
- return message;
- } else {
- List messages = new ArrayList();
- for (Iterator e = annotations.iterator(); e.hasNext();) {
- JETProblemAnnotation javaAnnotation = (JETProblemAnnotation) e.next();
- String message = javaAnnotation.getText();
- if (message != null && message.trim().length() > 0)
- messages.add(message.trim());
- }
-
- if (messages.size() == 1)
- return (String) messages.get(0);
- if (messages.size() > 1)
- return messages.toString();
- }
- return null;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationModel.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationModel.java
deleted file mode 100644
index b7f347a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETAnnotationModel.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.annotations;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.ui.texteditor.MarkerAnnotation;
-import org.eclipse.ui.texteditor.ResourceMarkerAnnotationModel;
-
-public class JETAnnotationModel extends ResourceMarkerAnnotationModel {
- private boolean fireChanges;
-
- public JETAnnotationModel(IResource resource) {
- super(resource);
- fireChanges = true;
- }
-
- public synchronized boolean isFireChanges() {
- return fireChanges;
- }
-
- public synchronized void setFireChanges(boolean b) {
- fireChanges = b;
- }
-
- public synchronized void addAnnotation(Annotation annotation, Position position) {
- try {
- addAnnotation(annotation, position, fireChanges);
- } catch (BadLocationException _ex) {
- }
- }
-
- public synchronized void removeAllAnnotations() {
- super.removeAllAnnotations(fireChanges);
- }
-
- public synchronized void removeAnnotation(Annotation annotation) {
- super.removeAnnotation(annotation, fireChanges);
- }
-
- public MarkerAnnotation createMarkerAnnotation(IMarker marker) {
- return super.createMarkerAnnotation(marker);
- }
-
- public Position createPositionFromMarker(IMarker marker) {
- return super.createPositionFromMarker(marker);
- }
-
- public void fireAnnotationModelChanged() {
- fireModelChanged();
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETProblemAnnotation.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETProblemAnnotation.java
deleted file mode 100644
index 0f7ad2a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/annotations/JETProblemAnnotation.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.annotations;
-
-import org.eclipse.jet.core.parser.ProblemSeverity;
-import org.eclipse.jet.core.parser.ast.Problem;
-import org.eclipse.jface.text.source.Annotation;
-
-public class JETProblemAnnotation extends Annotation {
-
- public static final String ERROR_ANNOTATION_TYPE = "org.eclipse.jet.editor.error";
-
- public static final String WARNING_ANNOTATION_TYPE = "org.eclipse.jet.editor.warning";
-
- public static final String INFO_ANNOTATION_TYPE = "org.eclipse.jet.editor.info";
-
- public JETProblemAnnotation(Problem problem) {
- if (problem.getProblemSeverity() == ProblemSeverity.ERROR)
- setType(ERROR_ANNOTATION_TYPE);
- else if (problem.getProblemSeverity() == ProblemSeverity.WARNING)
- setType(WARNING_ANNOTATION_TYPE);
- setText(problem.getMessage());
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/autoedit/JETTemplateAutoEditStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/autoedit/JETTemplateAutoEditStrategy.java
deleted file mode 100644
index 427471c..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/autoedit/JETTemplateAutoEditStrategy.java
+++ /dev/null
@@ -1,276 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.autoedit;
-
-import org.eclipse.jface.text.*;
-
-public class JETTemplateAutoEditStrategy extends DefaultIndentLineAutoEditStrategy {
-
- public JETTemplateAutoEditStrategy() {
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.text.IAutoEditStrategy#customizeDocumentCommand(IDocument, DocumentCommand)
- */
- public void customizeDocumentCommand(IDocument d, DocumentCommand c) {
- if (c.length == 0 && c.text != null && endsWithDelimiter(d, c.text))
- smartIndentAfterNewLine(d, c);
- else if ("%>".equals(c.text)) { //$NON-NLS-1$
- smartInsertAfterBracket(d, c);
- }
- }
-
- /**
- * Returns whether or not the text ends with one of the given search strings.
- * @param d IDocument
- * @param txt String
- * @return boolean
- */
- private boolean endsWithDelimiter(IDocument d, String txt) {
- String[] delimiters = d.getLegalLineDelimiters();
- for (int i = 0; i < delimiters.length; i++) {
- if (txt.endsWith(delimiters[i]))
- return true;
- }
- return false;
- }
-
- /**
- * Returns the line number of the next bracket after end.
- * @param document - the document being parsed
- * @param line - the line to start searching back from
- * @param end - the end position to search back from
- * @param closingBracketIncrease - the number of brackets to skip
- * @return int
- * @throws BadLocationException
- */
- protected int findMatchingOpenBracket(IDocument document, int line, int end, int closingBracketIncrease)
- throws BadLocationException {
-
- int start = document.getLineOffset(line);
- int brackcount = getBracketCount(document, start, end, false) - closingBracketIncrease;
-
- // sum up the brackets counts of each line (closing brackets count negative,
- // opening positive) until we find a line the brings the count to zero
- while (brackcount < 0) {
- line--;
- if (line < 0) {
- return -1;
- }
- start = document.getLineOffset(line);
- end = start + document.getLineLength(line) - 1;
- brackcount += getBracketCount(document, start, end, false);
- }
- return line;
- }
-
- /**
- * Returns the bracket value of a section of text. Closing brackets have a value of -1 and
- * open brackets have a value of 1.
- * @param document - the document being parsed
- * @param start - the start position for the search
- * @param end - the end position for the search
- * @param ignoreCloseJspTags boolean
- * @return int
- * @throws BadLocationException
- */
- private int getBracketCount(IDocument document, int start, int end, boolean ignoreCloseJspTags)
- throws BadLocationException {
-
- int begin = start;
- int jsptagcount = 0;
- while (begin < end) {
- char curr = document.getChar(begin);
- begin++;
- switch (curr) {
- case '/':
- begin = adjustBeginOnComment(document, end, begin);
- break;
- case '*':
- if (begin < end) {
- char next = document.getChar(begin);
- if (next == '/') {
- // we have been in a comment: forget what we read before
- jsptagcount = 0;
- begin++;
- }
- }
- break;
- case '<':
- if ((begin + 1 < document.getLength()) && (document.getChar(begin + 1) == '%')) {
- jsptagcount++;
- ignoreCloseJspTags = false;
- }
- break;
- case '>':
- if (!ignoreCloseJspTags && (begin > 1) && (document.getChar(begin - 1) == '%')) {
- jsptagcount--;
- }
- break;
- case '"':
- case '\'':
- begin = getStringEnd(document, begin, end, curr);
- break;
- default:
- }
- }
- return jsptagcount;
- }
-
- private int adjustBeginOnComment(IDocument document, int end, int begin) throws BadLocationException {
- if (begin < end) {
- char next = document.getChar(begin);
- if (next == '*') {
- // a comment starts, advance to the comment end
- begin = getCommentEnd(document, begin + 1, end);
- } else if (next == '/') {
- // '//'-comment: nothing to do anymore on this line
- begin = end;
- }
- }
- return begin;
- }
-
- /**
- * Returns the end position a comment starting at pos.
- * @param document - the document being parsed
- * @param position - the start position for the search
- * @param end - the end position for the search
- * @return int
- * @throws BadLocationException
- */
- private int getCommentEnd(IDocument document, int position, int end) throws BadLocationException {
- int currentPosition = position;
- while (currentPosition < end) {
- char curr = document.getChar(currentPosition);
- currentPosition++;
- if (curr == '*') {
- if (currentPosition < end && document.getChar(currentPosition) == '/') {
- return currentPosition + 1;
- }
- }
- }
- return end;
- }
-
- /**
- * Returns the String at line with the leading whitespace removed.
- * @param document - the document being parsed
- * @param line - the line being searched
- * @return String
- * @throws BadLocationException
- */
- protected String getIndentOfLine(IDocument document, int line) throws BadLocationException {
- if (line > -1) {
- int start = document.getLineOffset(line);
- int end = start + document.getLineLength(line) - 1;
- int whiteend = findEndOfWhiteSpace(document, start, end);
- return document.get(start, whiteend - start);
- } else {
- return ""; //$NON-NLS-1$
- }
- }
-
- /**
- * Returns the position of the character in the document after position.
- * @param document - the document being parsed
- * @param position - the position to start searching from
- * @param end - the end of the document
- * @param character - the character you are trying to match
- * @return int
- * @throws BadLocationException
- */
- private int getStringEnd(IDocument document, int position, int end, char character) throws BadLocationException {
- int currentPosition = position;
- while (currentPosition < end) {
- char currentCharacter = document.getChar(currentPosition);
- currentPosition++;
- if (currentCharacter == '\\') {
- // ignore escaped characters
- currentPosition++;
- } else if (currentCharacter == character) {
- return currentPosition;
- }
- }
- return end;
- }
-
- /**
- * Set the indent of a new line based on the command provided in the supplied document.
- * @param document - the document being parsed
- * @param command - the command being performed
- */
- protected void smartIndentAfterNewLine(IDocument document, DocumentCommand command) {
-
- int docLength = document.getLength();
- if (command.offset == -1 || docLength == 0)
- return;
-
- try {
- int p = (command.offset == docLength ? command.offset - 1 : command.offset);
- int line = document.getLineOfOffset(p);
-
- StringBuffer buf = new StringBuffer(command.text);
- if (command.offset < docLength && document.getChar(command.offset) == '}') {
- int indLine = findMatchingOpenBracket(document, line, command.offset, 0);
- if (indLine == -1) {
- indLine = line;
- }
- buf.append(getIndentOfLine(document, indLine));
- } else {
- int start = document.getLineOffset(line);
- int whiteend = findEndOfWhiteSpace(document, start, command.offset);
- buf.append(document.get(start, whiteend - start));
- if (getBracketCount(document, start, command.offset, true) > 0) {
- buf.append('\t');
- }
- }
- command.text = buf.toString();
-
- } catch (BadLocationException excp) {
- }
- }
-
- /**
- * Set the indent of a bracket based on the command provided in the supplied document.
- * @param document - the document being parsed
- * @param command - the command being performed
- */
- protected void smartInsertAfterBracket(IDocument document, DocumentCommand command) {
- if (command.offset == -1 || document.getLength() == 0)
- return;
-
- try {
- int p = (command.offset == document.getLength() ? command.offset - 1 : command.offset);
- int line = document.getLineOfOffset(p);
- int start = document.getLineOffset(line);
- int whiteend = findEndOfWhiteSpace(document, start, command.offset);
-
- // shift only when line does not contain any text up to the closing bracket
- if (whiteend == command.offset) {
- // evaluate the line with the opening bracket that matches out closing bracket
- int indLine = findMatchingOpenBracket(document, line, command.offset, 1);
- if (indLine != -1 && indLine != line) {
- // take the indent of the found line
- StringBuffer replaceText = new StringBuffer(getIndentOfLine(document, indLine));
- // add the rest of the current line including the just added close bracket
- replaceText.append(document.get(whiteend, command.offset - whiteend));
- replaceText.append(command.text);
- // modify document command
- command.length = command.offset - start;
- command.offset = start;
- command.text = replaceText.toString();
- }
- }
- } catch (BadLocationException excp) {
- }
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/DoubleClickStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/DoubleClickStrategy.java
deleted file mode 100644
index dd46718..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/DoubleClickStrategy.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.jface.text.*;
-
-public class DoubleClickStrategy implements ITextDoubleClickStrategy {
- protected ITextViewer fText;
-
- public void doubleClicked(ITextViewer part) {
- int pos = part.getSelectedRange().x;
-
- if (pos < 0)
- return;
-
- fText = part;
-
- if (!selectComment(pos)) {
- selectWord(pos);
- }
- }
- protected boolean selectComment(int caretPos) {
- IDocument doc = fText.getDocument();
- int startPos, endPos;
-
- try {
- int pos = caretPos;
- char c = ' ';
-
- while (pos >= 0) {
- c = doc.getChar(pos);
- if (c == '\\') {
- pos -= 2;
- continue;
- }
- if (c == Character.LINE_SEPARATOR || c == '\"')
- break;
- --pos;
- }
-
- if (c != '\"')
- return false;
-
- startPos = pos;
-
- pos = caretPos;
- int length = doc.getLength();
- c = ' ';
-
- while (pos < length) {
- c = doc.getChar(pos);
- if (c == Character.LINE_SEPARATOR || c == '\"')
- break;
- ++pos;
- }
- if (c != '\"')
- return false;
-
- endPos = pos;
-
- int offset = startPos + 1;
- int len = endPos - offset;
- fText.setSelectedRange(offset, len);
- return true;
- } catch (BadLocationException x) {
- }
-
- return false;
- }
- protected boolean selectWord(int caretPos) {
-
- IDocument doc = fText.getDocument();
- int startPos, endPos;
-
- try {
-
- int pos = caretPos;
- char c;
-
- while (pos >= 0) {
- c = doc.getChar(pos);
- if (!Character.isJavaIdentifierPart(c))
- break;
- --pos;
- }
-
- startPos = pos;
-
- pos = caretPos;
- int length = doc.getLength();
-
- while (pos < length) {
- c = doc.getChar(pos);
- if (!Character.isJavaIdentifierPart(c))
- break;
- ++pos;
- }
-
- endPos = pos;
- selectRange(startPos, endPos);
- return true;
-
- } catch (BadLocationException x) {
- }
-
- return false;
- }
-
- private void selectRange(int startPos, int stopPos) {
- int offset = startPos + 1;
- int length = stopPos - offset;
- fText.setSelectedRange(offset, length);
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/IJETColorConstants.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/IJETColorConstants.java
deleted file mode 100644
index ab8f041..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/IJETColorConstants.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.swt.graphics.RGB;
-
-public interface IJETColorConstants {
- RGB JET_CUSTOM_TAG_FG = new RGB(180, 128, 0);
- RGB JET_COMMENT_FG = new RGB(0, 155, 50);
- RGB JET_DIRECTIVE_FG = new RGB(180, 128, 0);
- RGB JET_EXPRESSION_FG = new RGB (180, 128, 0);
- RGB JET_SCRIPTLET_FG = new RGB(180, 128, 0);
-
- RGB JET_EXPRESSION_BG = new RGB(220, 230, 255);
- RGB JET_DEFAULT_BG = new RGB(230, 230, 230);
-
- RGB JET_JAVA_CODE = new RGB(128, 128, 128);
- RGB PROC_INSTR = new RGB(128, 128, 128);
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETDocumentProvider.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETDocumentProvider.java
deleted file mode 100644
index 86a7053..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETDocumentProvider.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.core.runtime.CoreException;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.annotations.JETAnnotationModel;
-import org.eclipse.jet.internal.editor.partition.JETDocumentPartitionScanner;
-import org.eclipse.jface.text.DocumentEvent;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IDocumentPartitioner;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.rules.FastPartitioner;
-import org.eclipse.jface.text.source.IAnnotationModel;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.editors.text.FileDocumentProvider;
-
-public class JETDocumentProvider extends FileDocumentProvider {
-
- private JETTextEditor editor;
-
- public JETDocumentProvider(JETTextEditor editor) {
- this.editor = editor;
- }
-
- protected IDocument createDocument(Object element) throws CoreException {
- IDocument document = super.createDocument(element);
- JETDocumentPartitionScanner partitionScanner = editor.getPartitionScanner();
- if (document != null) {
- IDocumentPartitioner partitioner = new FastPartitioner(partitionScanner, partitionScanner.getContentTypes()) {
- public IRegion documentChanged2(DocumentEvent e) {
- editor.handleDocumentChange(e);
- return super.documentChanged2(e);
- }
- };
- partitioner.connect(document);
- document.setDocumentPartitioner(partitioner);
- }
- return document;
- }
-
- protected IAnnotationModel createAnnotationModel(Object element) throws CoreException {
- if (element instanceof IFileEditorInput) {
- IFileEditorInput input = (IFileEditorInput) element;
- return new JETAnnotationModel(input.getFile());
- } else {
- return super.createAnnotationModel(element);
- }
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETEditorPreferenceConstants.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETEditorPreferenceConstants.java
deleted file mode 100644
index f02faa9..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETEditorPreferenceConstants.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 - 2006 Joel Cheuoua & others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants;
-
-/**
- * Preference Constants used for the IRL Editor
- * @author lmirguet
- * @version $Revision: 1.1 $
- */
-public class JETEditorPreferenceConstants {
- public static final String JET_CUSTOM_TAG_FG_COLOR = "jet_custom_tag_foreground";
- public static final String JET_CUSTOM_TAG_BOLD = "jet_custom_tag_bold";
- public static final String JET_CUSTOM_TAG_ITALIC = "jet_custom_tag_italic";
- public static final String JET_CUSTOM_TAG_UNDERLINE = "jet_custom_tag_underline";
-
- public static final String JET_COMMENT_FG_COLOR = "jet_comment_foreground";
- public static final String JET_COMMENT_BOLD = "jet_comment_bold";
- public static final String JET_COMMENT_ITALIC = "jet_comment_italic";
- public static final String JET_COMMENT_UNDERLINE = "jet_comment_underline";
-
- public static final String JET_EXPRESSION_FG_COLOR = "jet_expression_foreground";
- public static final String JET_EXPRESSION_BOLD = "jet_expression_bold";
- public static final String JET_EXPRESSION_ITALIC = "jet_expression_italic";
- public static final String JET_EXPRESSION_UNDERLINE = "jet_expression_underline";
-
- public static final String JET_SCRIPTLET_FG_COLOR = "jet_scriptlet_foreground";
- public static final String JET_SCRIPTLET_BOLD = "jet_scriptlet_bold";
- public static final String JET_SCRIPTLET_ITALIC = "jet_scriptlet_italic";
- public static final String JET_SCRIPTLET_UNDERLINE = "jet_scriptlet_underline";
-
- public static final String JET_DIRECTIVE_FG_COLOR = "jet_directive_foreground";
- public static final String JET_DIRECTIVE_BOLD = "jet_directive_bold";
- public static final String JET_DIRECTIVE_ITALIC = "jet_directive_italic";
- public static final String JET_DIRECTIVE_UNDERLINE = "jet_directive_underline";
-
- public static final String JET_DIRECTIVE_KEYWORD_BOLD = "jet_directive_keyword_bold";
- public static final String JET_EXPRESSION_BG_COLOR = "jet_expression_background";
- public static final String JET_DEFAULT_BG_COLOR = "jet_default_background";
-
- public static final String AUTO_COMPLETE_ENABLED = "autoCompleteEnable";
- public static final String AUTO_COMPLETE_DELAY = "autoCompleteDelay";
-
- /**
- * Should not be instanciated.
- *
- */
- private JETEditorPreferenceConstants() {
- }
-
- /**
- * Initialize with the default values.
- * @param store IPreferenceStore
- */
- public static void initializeDefaultValues(IPreferenceStore store) {
-
- PreferenceConstants.initializeDefaultValues(store);
- AbstractDecoratedTextEditorPreferenceConstants.initializeDefaultValues(store);
-
- PreferenceConverter.setDefault(store, JET_COMMENT_FG_COLOR, IJETColorConstants.JET_COMMENT_FG);
- store.setDefault(JET_COMMENT_BOLD, false);
- store.setDefault(JET_COMMENT_ITALIC, true);
- store.setDefault(JET_COMMENT_UNDERLINE, false);
-
- PreferenceConverter.setDefault(store, JET_CUSTOM_TAG_FG_COLOR, IJETColorConstants.JET_CUSTOM_TAG_FG);
- store.setDefault(JET_CUSTOM_TAG_BOLD, false);
- store.setDefault(JET_CUSTOM_TAG_ITALIC, false);
- store.setDefault(JET_CUSTOM_TAG_UNDERLINE, true);
-
- PreferenceConverter.setDefault(store, JET_EXPRESSION_FG_COLOR, IJETColorConstants.JET_EXPRESSION_FG);
- store.setDefault(JET_EXPRESSION_BOLD, false);
- store.setDefault(JET_EXPRESSION_ITALIC, false);
- store.setDefault(JET_EXPRESSION_UNDERLINE, false);
-
- PreferenceConverter.setDefault(store, JET_DIRECTIVE_FG_COLOR, IJETColorConstants.JET_DIRECTIVE_FG);
- store.setDefault(JET_DIRECTIVE_BOLD, false);
- store.setDefault(JET_DIRECTIVE_KEYWORD_BOLD, true);
- store.setDefault(JET_DIRECTIVE_ITALIC, false);
- store.setDefault(JET_DIRECTIVE_UNDERLINE, false);
-
- PreferenceConverter.setDefault(store, JET_SCRIPTLET_FG_COLOR, IJETColorConstants.JET_SCRIPTLET_FG);
- store.setDefault(JET_SCRIPTLET_BOLD, false);
- store.setDefault(JET_SCRIPTLET_ITALIC, true);
- store.setDefault(JET_SCRIPTLET_UNDERLINE, false);
-
- PreferenceConverter.setDefault(store, JET_DEFAULT_BG_COLOR, IJETColorConstants.JET_DEFAULT_BG);
- PreferenceConverter.setDefault(store, JET_EXPRESSION_BG_COLOR, IJETColorConstants.JET_EXPRESSION_BG);
-
- store.setDefault(AUTO_COMPLETE_ENABLED, store.getDefaultBoolean(PreferenceConstants.CODEASSIST_AUTOACTIVATION));
- store.setDefault(AUTO_COMPLETE_DELAY, store.getDefaultInt(PreferenceConstants.CODEASSIST_AUTOACTIVATION_DELAY));
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETReconcilingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETReconcilingStrategy.java
deleted file mode 100644
index 01c5c67..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETReconcilingStrategy.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.Problem;
-import org.eclipse.jet.internal.editor.JETEditorHelper;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.annotations.JETAnnotationModel;
-import org.eclipse.jet.internal.editor.annotations.JETProblemAnnotation;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.reconciler.DirtyRegion;
-import org.eclipse.jface.text.reconciler.IReconcilingStrategy;
-import org.eclipse.jface.text.reconciler.IReconcilingStrategyExtension;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.ui.texteditor.MarkerAnnotation;
-
-/**
- * The reconciling strategy for the JET editor
- * @author Joel
- */
-public class JETReconcilingStrategy implements IReconcilingStrategy, IReconcilingStrategyExtension {
-
- private JETTextEditor jetEditor;
-
- private ISourceViewer sourceViewer;
-
- /**
- * Main constructor
- * @param sourceViewer
- * @param jetEditor
- */
- public JETReconcilingStrategy(ISourceViewer sourceViewer, JETTextEditor jetEditor) {
- this.jetEditor = jetEditor;
- this.sourceViewer = sourceViewer;
- }
-
- /**
- * This is the single method that performs the annotation model problems evaluations and update
- */
- private void internalReconcile() {
- JETCompilationUnit cUnit = jetEditor.requestCompilationUnit();
- List cUnitProblems = cUnit.getProblems();
- List javaContentProblems = JETEditorHelper.evaluateProblems(jetEditor, sourceViewer.getDocument());
- JETAnnotationModel annotationModel = (JETAnnotationModel) sourceViewer.getAnnotationModel();
- if (annotationModel != null) {
- // avoid changes to the annotation model to be notified to the viewers until the job is done
- annotationModel.setFireChanges(false);
-
- // Remove all the previous annotations related to JET problems
- // and related to resource markers
- for (Iterator it = annotationModel.getAnnotationIterator(); it.hasNext();) {
- Annotation annotation = (Annotation) it.next();
- if ((annotation instanceof JETProblemAnnotation) || (annotation instanceof MarkerAnnotation))
- annotationModel.removeAnnotation(annotation);
- }
-
- // Problems for JET document structure
- for (Iterator iterator = cUnitProblems.iterator(); iterator.hasNext(); ) {
- Problem problem = (Problem) iterator.next();
- JETProblemAnnotation annotation = new JETProblemAnnotation(problem);
- Position position = new Position(problem.getStart(), problem.getEnd() - problem.getStart());
- annotationModel.addAnnotation(annotation, position);
- }
-
- // Problems in java contents of the JET document
- for (Iterator iterator = javaContentProblems.iterator(); iterator.hasNext(); ) {
- Problem problem = (Problem) iterator.next();
- JETProblemAnnotation annotation = new JETProblemAnnotation(problem);
- Position position = new Position(problem.getStart(), problem.getEnd() - problem.getStart());
- annotationModel.addAnnotation(annotation, position);
- }
-
- annotationModel.setFireChanges(true);
- annotationModel.fireAnnotationModelChanged();
- }
- }
-
- public void setDocument(IDocument idocument) {
- }
-
- public void initialReconcile() {
- internalReconcile();
- }
-
- public void reconcile(DirtyRegion dirtyRegion, IRegion subRegion) {
- internalReconcile();
- }
-
- public void reconcile(IRegion partition) {
- internalReconcile();
- }
-
- public void setProgressMonitor(IProgressMonitor iprogressmonitor) {
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETSourceViewerConfiguration.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETSourceViewerConfiguration.java
deleted file mode 100644
index 95ee783..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETSourceViewerConfiguration.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.annotations.JETAnnotationHover;
-import org.eclipse.jface.text.IAutoEditStrategy;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.ITextDoubleClickStrategy;
-import org.eclipse.jface.text.contentassist.ContentAssistant;
-import org.eclipse.jface.text.contentassist.IContentAssistant;
-import org.eclipse.jface.text.formatter.IContentFormatter;
-import org.eclipse.jface.text.formatter.MultiPassContentFormatter;
-import org.eclipse.jface.text.presentation.IPresentationReconciler;
-import org.eclipse.jface.text.presentation.PresentationReconciler;
-import org.eclipse.jface.text.reconciler.IReconciler;
-import org.eclipse.jface.text.reconciler.MonoReconciler;
-import org.eclipse.jface.text.source.*;
-
-public class JETSourceViewerConfiguration extends SourceViewerConfiguration {
-
- private DoubleClickStrategy doubleClickStrategy;
- private JETTextEditor editor;
-
- public JETSourceViewerConfiguration(JETTextEditor editor) {
- this.editor = editor;
- }
-
- public String[] getConfiguredContentTypes(ISourceViewer sourceViewer) {
- return editor.getPartitionScanner().getContentTypes();
- }
-
- public ITextDoubleClickStrategy getDoubleClickStrategy(ISourceViewer sourceViewer, String contentType) {
- if (doubleClickStrategy == null)
- doubleClickStrategy = new DoubleClickStrategy();
- return doubleClickStrategy;
- }
-
- public IReconciler getReconciler(ISourceViewer sourceViewer) {
- JETReconcilingStrategy strategy = new JETReconcilingStrategy(sourceViewer, editor);
- MonoReconciler reconciler = new MonoReconciler(strategy, false);
- reconciler.setProgressMonitor(new NullProgressMonitor());
- reconciler.setDelay(500);
- return reconciler;
- }
-
- public IAnnotationHover getAnnotationHover(ISourceViewer sourceViewer) {
- return new JETAnnotationHover();
- }
-
- public IAutoEditStrategy[] getAutoEditStrategies(ISourceViewer sourceViewer, String contentType) {
- IAutoEditStrategy strategies[] = editor.getPartitionScanner().getAutoEditStrategies(contentType);
- if (strategies == null)
- strategies = super.getAutoEditStrategies(sourceViewer, contentType);
- return strategies;
- }
-
- public IContentAssistant getContentAssistant(ISourceViewer sourceViewer) {
- ContentAssistant assistant = new ContentAssistant();
- assistant.setDocumentPartitioning(getConfiguredDocumentPartitioning(sourceViewer));
- String configuredContentTypes[] = getConfiguredContentTypes(sourceViewer);
- for (int i = 0; i < configuredContentTypes.length; i++) {
- String contentType = configuredContentTypes[i];
- org.eclipse.jface.text.contentassist.IContentAssistProcessor processor = editor.getPartitionScanner()
- .getCompletionProcessor(contentType, assistant);
- if (processor != null)
- assistant.setContentAssistProcessor(processor, contentType);
- }
-
- assistant.setContextInformationPopupOrientation(20);
- assistant.setInformationControlCreator(getInformationControlCreator(sourceViewer));
- assistant.enableAutoInsert(false);
- assistant.enableAutoActivation(true);
- return assistant;
- }
-
- public IContentFormatter getContentFormatter(ISourceViewer sourceViewer) {
- MultiPassContentFormatter formatter = new MultiPassContentFormatter(
- getConfiguredDocumentPartitioning(sourceViewer), IDocument.DEFAULT_CONTENT_TYPE);
- String configuredContentTypes[] = getConfiguredContentTypes(sourceViewer);
- for (int i = 0; i < configuredContentTypes.length; i++) {
- String contentType = configuredContentTypes[i];
- org.eclipse.jface.text.formatter.IFormattingStrategy strategy = editor.getPartitionScanner()
- .getFormattingStrategy(contentType);
- if (strategy != null)
- if (IDocument.DEFAULT_CONTENT_TYPE.equals(contentType))
- formatter.setMasterStrategy(strategy);
- else
- formatter.setSlaveStrategy(strategy, contentType);
- }
-
- return formatter;
- }
-
- public IPresentationReconciler getPresentationReconciler(ISourceViewer sourceViewer) {
- PresentationReconciler reconciler = new PresentationReconciler();
- String configuredContentTypes[] = getConfiguredContentTypes(sourceViewer);
- for (int i = 0; i < configuredContentTypes.length; i++) {
- String contentType = configuredContentTypes[i];
- org.eclipse.jface.text.presentation.IPresentationDamager damager = editor.getPartitionScanner().getDamager(
- contentType);
- org.eclipse.jface.text.presentation.IPresentationRepairer repairer = editor.getPartitionScanner().getRepairer(
- contentType);
- if (damager != null)
- reconciler.setDamager(damager, contentType);
- if (repairer != null)
- reconciler.setRepairer(repairer, contentType);
- }
-
- return reconciler;
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETTokenStyleManager.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETTokenStyleManager.java
deleted file mode 100644
index 2f7f579..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETTokenStyleManager.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.jdt.ui.text.IColorManager;
-import org.eclipse.jdt.ui.text.IColorManagerExtension;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.text.TextAttribute;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.Token;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.texteditor.AbstractTextEditor;
-
-public class JETTokenStyleManager implements IColorManager, IColorManagerExtension {
- private IPreferenceStore preferenceStore;
-
- protected Map colorTable = new HashMap(10);
- protected Map keyTable= new HashMap(10);
- protected Map tokenMap = new HashMap(10);
-
- public JETTokenStyleManager(IPreferenceStore store) {
- this.preferenceStore = store;
- }
- public void dispose() {
- Iterator e = colorTable.values().iterator();
- while (e.hasNext())
- ((Color) e.next()).dispose();
- }
- public Color getColor(RGB rgb) {
- Color color = (Color) colorTable.get(rgb);
- if (color == null) {
- color = new Color(Display.getCurrent(), rgb);
- colorTable.put(rgb, color);
- }
- return color;
- }
- public Color getColor(String key) {
- if (key == null)
- return null;
- RGB rgb= (RGB) keyTable.get(key);
- if (rgb == null) {
- rgb= PreferenceConverter.getColor(preferenceStore, key);
- if (rgb == null)
- return null;
- keyTable.put(key, rgb);
- }
- return getColor(rgb);
- }
-
- /*
- * @see IColorManagerExtension#bindColor(String, RGB)
- */
- public void bindColor(String key, RGB rgb) {
- Object value= keyTable.get(key);
- if (value != null)
- throw new UnsupportedOperationException();
- keyTable.put(key, rgb);
- }
-
- /*
- * @see IColorManagerExtension#unbindColor(String)
- */
- public void unbindColor(String key) {
- keyTable.remove(key);
- }
-
- public IToken getCachedToken(String id) {
- return ((IToken)tokenMap.get(id));
- }
-
- public IToken requestToken(String id,
- String fgColorKey,
- String bgColorKey,
- String boldKey,
- String italicKey,
- String strikethroughKey,
- String underlineKey) {
- if (fgColorKey != null && getColor(fgColorKey) == null) {
- RGB rgb= PreferenceConverter.getColor(preferenceStore, fgColorKey);
- unbindColor(fgColorKey);
- bindColor(fgColorKey, rgb);
- }
-
- if (bgColorKey != null && getColor(bgColorKey) == null) {
- RGB rgb= PreferenceConverter.getColor(preferenceStore, bgColorKey);
- unbindColor(bgColorKey);
- bindColor(bgColorKey, rgb);
- }
-
- Token token= ((Token)tokenMap.get(id));
- if (token == null) {
- token = new Token(createTextAttribute(fgColorKey, bgColorKey, boldKey, italicKey, strikethroughKey, underlineKey));
- tokenMap.put(id, token);
- } else {
- token.setData(createTextAttribute(fgColorKey, bgColorKey, boldKey, italicKey, strikethroughKey, underlineKey));
- }
- return token;
- }
-
- /**
- * Create a text attribute based on the given color, bold, italic, strikethrough and underline preference keys.
- *
- * @param fgColorKey the fg color preference key
- * @param bgColorKey the fg color preference key
- * @param boldKey the bold preference key
- * @param italicKey the italic preference key
- * @param strikethroughKey the strikethrough preference key
- * @param underlineKey the italic preference key
- * @return the created text attribute
- * @since 3.0
- */
- private TextAttribute createTextAttribute(String fgColorKey, String bgColorKey, String boldKey, String italicKey, String strikethroughKey, String underlineKey) {
- Color fgColor= null;
- if (fgColorKey != null)
- fgColor= getColor(fgColorKey);
- Color bgColor= null;
- if (bgColorKey != null)
- bgColor= getColor(bgColorKey);
-
- int style = (boldKey != null && preferenceStore.getBoolean(boldKey))? SWT.BOLD : SWT.NORMAL;
-
- if (italicKey != null && preferenceStore.getBoolean(italicKey))
- style |= SWT.ITALIC;
-
- if (strikethroughKey != null && preferenceStore.getBoolean(strikethroughKey))
- style |= TextAttribute.STRIKETHROUGH;
-
- if (underlineKey != null && preferenceStore.getBoolean(underlineKey))
- style |= TextAttribute.UNDERLINE;
-
- return new TextAttribute(fgColor, bgColor, style);
- }
-
- public IToken requestDefaultToken() {
- return requestToken("__jet_default_return_token",
- AbstractTextEditor.PREFERENCE_COLOR_FOREGROUND,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- null,
- null,
- null,
- null);
-
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETWhitespaceDetector.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETWhitespaceDetector.java
deleted file mode 100644
index a5bd04a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/JETWhitespaceDetector.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.jface.text.rules.IWhitespaceDetector;
-
-public class JETWhitespaceDetector implements IWhitespaceDetector {
-
- public boolean isWhitespace(char c) {
- return (c == ' ' || c == '\t' || c == '\n' || c == '\r');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/NonRuleBasedDamagerRepairer.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/NonRuleBasedDamagerRepairer.java
deleted file mode 100644
index 019c755..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/NonRuleBasedDamagerRepairer.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.DocumentEvent;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.ITypedRegion;
-import org.eclipse.jface.text.Region;
-import org.eclipse.jface.text.TextAttribute;
-import org.eclipse.jface.text.TextPresentation;
-import org.eclipse.jface.text.presentation.IPresentationDamager;
-import org.eclipse.jface.text.presentation.IPresentationRepairer;
-import org.eclipse.swt.custom.StyleRange;
-
-public class NonRuleBasedDamagerRepairer
- implements IPresentationDamager, IPresentationRepairer {
-
- /** The document this object works on */
- protected IDocument fDocument;
- /** The default text attribute if non is returned as data by the current token */
- protected TextAttribute fDefaultTextAttribute;
-
- /**
- * Constructor for NonRuleBasedDamagerRepairer.
- */
- public NonRuleBasedDamagerRepairer(TextAttribute defaultTextAttribute) {
- Assert.isNotNull(defaultTextAttribute);
-
- fDefaultTextAttribute = defaultTextAttribute;
- }
-
- /**
- * @see IPresentationRepairer#setDocument(IDocument)
- */
- public void setDocument(IDocument document) {
- fDocument = document;
- }
-
- /**
- * Returns the end offset of the line that contains the specified offset or
- * if the offset is inside a line delimiter, the end offset of the next line.
- *
- * @param offset the offset whose line end offset must be computed
- * @return the line end offset for the given offset
- * @exception BadLocationException if offset is invalid in the current document
- */
- protected int endOfLineOf(int offset) throws BadLocationException {
-
- IRegion info = fDocument.getLineInformationOfOffset(offset);
- if (offset <= info.getOffset() + info.getLength())
- return info.getOffset() + info.getLength();
-
- int line = fDocument.getLineOfOffset(offset);
- try {
- info = fDocument.getLineInformation(line + 1);
- return info.getOffset() + info.getLength();
- } catch (BadLocationException x) {
- return fDocument.getLength();
- }
- }
-
- /**
- * @see IPresentationDamager#getDamageRegion(ITypedRegion, DocumentEvent, boolean)
- */
- public IRegion getDamageRegion(
- ITypedRegion partition,
- DocumentEvent event,
- boolean documentPartitioningChanged) {
- if (!documentPartitioningChanged) {
- try {
-
- IRegion info =
- fDocument.getLineInformationOfOffset(event.getOffset());
- int start = Math.max(partition.getOffset(), info.getOffset());
-
- int end =
- event.getOffset()
- + (event.getText() == null
- ? event.getLength()
- : event.getText().length());
-
- if (info.getOffset() <= end
- && end <= info.getOffset() + info.getLength()) {
- // optimize the case of the same line
- end = info.getOffset() + info.getLength();
- } else
- end = endOfLineOf(end);
-
- end =
- Math.min(
- partition.getOffset() + partition.getLength(),
- end);
- return new Region(start, end - start);
-
- } catch (BadLocationException x) {
- }
- }
-
- return partition;
- }
-
- /**
- * @see IPresentationRepairer#createPresentation(TextPresentation, ITypedRegion)
- */
- public void createPresentation(
- TextPresentation presentation,
- ITypedRegion region) {
- addRange(
- presentation,
- region.getOffset(),
- region.getLength(),
- fDefaultTextAttribute);
- }
-
- /**
- * Adds style information to the given text presentation.
- *
- * @param presentation the text presentation to be extended
- * @param offset the offset of the range to be styled
- * @param length the length of the range to be styled
- * @param attr the attribute describing the style of the range to be styled
- */
- protected void addRange(
- TextPresentation presentation,
- int offset,
- int length,
- TextAttribute attr) {
- if (attr != null)
- presentation.addStyleRange(
- new StyleRange(
- offset,
- length,
- attr.getForeground(),
- attr.getBackground(),
- attr.getStyle()));
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/IJETDefaultTextColorerDelegate.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/IJETDefaultTextColorerDelegate.java
deleted file mode 100644
index a463706..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/IJETDefaultTextColorerDelegate.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration.delegates;
-
-import org.eclipse.jet.internal.editor.partition.ITokenScannerProvider;
-import org.eclipse.jface.text.rules.IPredicateRule;
-import org.eclipse.swt.graphics.Image;
-
-public interface IJETDefaultTextColorerDelegate extends ITokenScannerProvider {
- IPredicateRule[] getPartitioningRules();
- String getName();
- Image getImage();
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/java/JavaContentPartitionConfigurationDelegate.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/java/JavaContentPartitionConfigurationDelegate.java
deleted file mode 100644
index 807bb0f..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/java/JavaContentPartitionConfigurationDelegate.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration.delegates.java;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.eclipse.jdt.ui.ISharedImages;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jdt.ui.text.JavaSourceViewerConfiguration;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.rules.*;
-import org.eclipse.swt.graphics.Image;
-
-public class JavaContentPartitionConfigurationDelegate implements IJETDefaultTextColorerDelegate {
- private JETJavaSourceViewerConfiguration javaConfiguration;
-
- public JavaContentPartitionConfigurationDelegate(JETTextEditor editor) {
- javaConfiguration = new JETJavaSourceViewerConfiguration(editor);
- }
-
- public String getName() {
- return "Java Text Content Colorer";
- }
-
- public Image getImage() {
- return JavaUI.getSharedImages().getImage(ISharedImages.IMG_OBJS_CUNIT);
- }
-
- public IPredicateRule[] getPartitioningRules() {
- org.eclipse.jface.text.rules.IToken string = new Token("__java_string");
- org.eclipse.jface.text.rules.IToken character = new Token("__java_character");
- org.eclipse.jface.text.rules.IToken javaDoc = new Token("__java_javadoc");
- org.eclipse.jface.text.rules.IToken multiLineComment = new Token("__java_multiline_comment");
- org.eclipse.jface.text.rules.IToken singleLineComment = new Token("__java_singleline_comment");
- List rules = new ArrayList();
- rules.add(new EndOfLineRule("//", singleLineComment));
- rules.add(new SingleLineRule("\"", "\"", string, '\\'));
- rules.add(new SingleLineRule("'", "'", character, '\\'));
- EmptyCommentRule wordRule = new EmptyCommentRule(multiLineComment);
- rules.add(wordRule);
- rules.add(new MultiLineRule("/**", "*/", javaDoc));
- rules.add(new MultiLineRule("/*", "*/", multiLineComment));
- IPredicateRule result[] = new IPredicateRule[rules.size()];
- rules.toArray(result);
- return result;
- }
-
- public ITokenScanner getTokenScanner(String contentType) {
- if (IDocument.DEFAULT_CONTENT_TYPE.equals(contentType))
- return javaConfiguration.getCodeScanner();
- if ("__java_javadoc".equals(contentType))
- return javaConfiguration.getJavaDocScanner();
- if ("__java_multiline_comment".equals(contentType))
- return javaConfiguration.getMultilineCommentScanner();
- if ("__java_singleline_comment".equals(contentType))
- return javaConfiguration.getSinglelineCommentScanner();
- if ("__java_string".equals(contentType))
- return javaConfiguration.getStringScanner();
- if ("__java_character".equals(contentType))
- return javaConfiguration.getStringScanner();
- else
- return javaConfiguration.getCodeScanner();
- }
-
- private class JETJavaSourceViewerConfiguration extends JavaSourceViewerConfiguration {
- public RuleBasedScanner getCodeScanner() {
- return super.getCodeScanner();
- }
- public RuleBasedScanner getMultilineCommentScanner() {
- return super.getMultilineCommentScanner();
- }
- public RuleBasedScanner getSinglelineCommentScanner() {
- return super.getSinglelineCommentScanner();
- }
- public RuleBasedScanner getStringScanner() {
- return super.getStringScanner();
- }
- public RuleBasedScanner getJavaDocScanner() {
- return super.getJavaDocScanner();
- }
- public JETJavaSourceViewerConfiguration(JETTextEditor editor) {
- super(JavaUI.getColorManager(), editor.getEditorPreferenceStore(), editor, null);
- }
- }
-
- private class EmptyCommentDetector implements IWordDetector {
- public boolean isWordStart(char c) {
- return c == '/';
- }
-
- public boolean isWordPart(char c) {
- return c == '*' || c == '/';
- }
- }
-
- private class EmptyCommentRule extends WordRule implements IPredicateRule {
- public IToken evaluate(ICharacterScanner scanner, boolean resume) {
- return evaluate(scanner);
- }
-
- public IToken getSuccessToken() {
- return fSuccessToken;
- }
-
- private IToken fSuccessToken;
-
- public EmptyCommentRule(IToken successToken) {
- super(new EmptyCommentDetector());
- fSuccessToken = successToken;
- addWord("/**/", fSuccessToken);
- }
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/xml/XMLContentPartitionConfigurationDelegate.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/xml/XMLContentPartitionConfigurationDelegate.java
deleted file mode 100644
index bb0c6af..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/configuration/delegates/xml/XMLContentPartitionConfigurationDelegate.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.configuration.delegates.xml;
-
-import org.eclipse.jdt.ui.text.IColorManager;
-import org.eclipse.jet.internal.editor.Activator;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.TextAttribute;
-import org.eclipse.jface.text.rules.ICharacterScanner;
-import org.eclipse.jface.text.rules.IPredicateRule;
-import org.eclipse.jface.text.rules.IRule;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.ITokenScanner;
-import org.eclipse.jface.text.rules.IWhitespaceDetector;
-import org.eclipse.jface.text.rules.MultiLineRule;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
-import org.eclipse.jface.text.rules.SingleLineRule;
-import org.eclipse.jface.text.rules.Token;
-import org.eclipse.jface.text.rules.WhitespaceRule;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.RGB;
-
-public class XMLContentPartitionConfigurationDelegate implements IJETDefaultTextColorerDelegate {
- public static final String XML_COMMENT = "__xml_comment";
- public static final String XML_TAG = "__xml_tag";
-
- private XMLTagScanner tagScanner;
- private XMLScanner scanner;
- private XMLScanner commentScanner;
- private IColorManager colorManager;
-
- public static interface IXMLColorConstants {
- RGB XML_COMMENT = new RGB(128, 0, 0);
- RGB PROC_INSTR = new RGB(128, 128, 128);
- RGB STRING = new RGB(0, 128, 0);
- RGB DEFAULT = new RGB(0, 0, 0);
- RGB TAG = new RGB(0, 0, 128);
- }
-
- public class TagRule extends MultiLineRule {
-
- protected boolean sequenceDetected(ICharacterScanner scanner, char sequence[], boolean eofAllowed) {
- int c = scanner.read();
- if (sequence[0] == '<') {
- if (c == 63) {
- scanner.unread();
- return false;
- }
- if (c == 33) {
- scanner.unread();
- return false;
- }
- } else if (sequence[0] == '>')
- scanner.unread();
- return super.sequenceDetected(scanner, sequence, eofAllowed);
- }
-
- public TagRule(IToken token) {
- super("<", ">", token);
- }
- }
-
- public class XMLWhitespaceDetector implements IWhitespaceDetector {
- public boolean isWhitespace(char c) {
- return c == ' ' || c == '\t' || c == '\n' || c == '\r';
- }
-
- public XMLWhitespaceDetector() {
- super();
- }
- }
-
- public class XMLScanner extends RuleBasedScanner {
-
- public XMLScanner(IColorManager manager) {
- super();
- org.eclipse.jface.text.rules.IToken procInstr = new Token(new TextAttribute(manager
- .getColor(IXMLColorConstants.PROC_INSTR)));
- IRule rules[] = new IRule[2];
- rules[0] = new SingleLineRule("<?", "?>", procInstr);
- rules[1] = new WhitespaceRule(new XMLWhitespaceDetector());
- setRules(rules);
- }
- }
-
- public class XMLTagScanner extends RuleBasedScanner {
-
- public XMLTagScanner(IColorManager manager) {
- super();
- org.eclipse.jface.text.rules.IToken string = new Token(new TextAttribute(manager
- .getColor(IXMLColorConstants.STRING)));
- IRule rules[] = new IRule[3];
- rules[0] = new SingleLineRule("\"", "\"", string, '\\');
- rules[1] = new SingleLineRule("'", "'", string, '\\');
- rules[2] = new WhitespaceRule(new XMLWhitespaceDetector());
- setRules(rules);
- }
- }
-
- public XMLContentPartitionConfigurationDelegate(JETTextEditor editor) {
- colorManager = editor.getTokenStyleManager();
- }
-
- public String getName() {
- return "XML Text Content Colorer";
- }
-
- public Image getImage() {
- return Activator.getDefault().getWorkbench().getSharedImages().getImage("IMG_OBJ_FILE");
- }
-
- public IPredicateRule[] getPartitioningRules() {
- org.eclipse.jface.text.rules.IToken xmlComment = new Token(XML_COMMENT);
- org.eclipse.jface.text.rules.IToken tag = new Token(XML_TAG);
- IPredicateRule rules[] = new IPredicateRule[2];
- rules[0] = new MultiLineRule("<!--", "-->", xmlComment);
- rules[1] = new TagRule(tag);
- return rules;
- }
-
- public ITokenScanner getTokenScanner(String contentType) {
- if (IDocument.DEFAULT_CONTENT_TYPE.equals(contentType))
- return getXMLScanner();
- if (XML_TAG.equals(contentType))
- return getXMLTagScanner();
- if (XML_COMMENT.equals(contentType))
- return getCommentScanner();
- else
- return getXMLScanner();
- }
-
- protected XMLScanner getCommentScanner() {
- if (commentScanner == null) {
- commentScanner = new XMLScanner(colorManager);
- commentScanner.setDefaultReturnToken(new Token(new TextAttribute(colorManager
- .getColor(IXMLColorConstants.XML_COMMENT))));
- }
- return commentScanner;
- }
-
- protected XMLScanner getXMLScanner() {
- if (scanner == null) {
- scanner = new XMLScanner(colorManager);
- scanner.setDefaultReturnToken(new Token(new TextAttribute(colorManager.getColor(IXMLColorConstants.DEFAULT))));
- }
- return scanner;
- }
-
- protected XMLTagScanner getXMLTagScanner() {
- if (tagScanner == null) {
- tagScanner = new XMLTagScanner(colorManager);
- tagScanner.setDefaultReturnToken(new Token(new TextAttribute(colorManager.getColor(IXMLColorConstants.TAG))));
- }
- return tagScanner;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractJETAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractJETAssistProcessor.java
deleted file mode 100644
index 969069e..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractJETAssistProcessor.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-
-public abstract class AbstractJETAssistProcessor implements IContentAssistProcessor {
- protected JETTextEditor editor;
- public AbstractJETAssistProcessor(JETTextEditor editor) {
- this.editor = editor;
- }
-
- public String getErrorMessage() {
- // TODO Auto-generated method stub
- return null;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractXMLTagsBasedAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractXMLTagsBasedAssistProcessor.java
deleted file mode 100644
index 85951e4..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/AbstractXMLTagsBasedAssistProcessor.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import java.util.*;
-
-import org.eclipse.jet.internal.editor.JETDocumentReader;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.CompletionProposal;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-
-public abstract class AbstractXMLTagsBasedAssistProcessor extends AbstractJETAssistProcessor {
-
- private TreeSet keywordSet;
- private TreeSet innerKeywordSet;
- private TreeMap innerMap;
-
- public AbstractXMLTagsBasedAssistProcessor(JETTextEditor editor) {
- super(editor);
- keywordSet = new TreeSet();
- innerKeywordSet = new TreeSet();
- innerMap = new TreeMap();
- String tagAttrs[][] = getTagAttributes();
- for (int i = 0; i < tagAttrs.length; i++)
- keywordSet.add(tagAttrs[i][0]);
-
- for (int i = 0; i < tagAttrs.length; i++) {
- TreeSet innerSet = new TreeSet();
- for (int j = 1; j < tagAttrs[i].length; j++) {
- innerSet.add(tagAttrs[i][j]);
- innerKeywordSet.add(tagAttrs[i][j]);
- }
-
- innerMap.put(tagAttrs[i][0], innerSet);
- }
-
- }
-
- public abstract String[] getRootTags();
-
- public abstract String[][] getTagAttributes();
-
- public String[] getAllKeywords() {
- return (String[]) keywordSet.toArray(new String[keywordSet.size()]);
- }
-
- public String[] getAllInnerKeywords() {
- return (String[]) innerKeywordSet.toArray(new String[innerKeywordSet.size()]);
- }
-
- public String[] getInnerKeywordsFor(String key) {
- TreeSet set = (TreeSet) (TreeSet) innerMap.get(key);
- if (set == null && key.length() == 0)
- return getRootTags();
- else if (set != null)
- return (String[]) set.toArray(new String[set.size()]);
- return new String[0];
- }
-
- private boolean prefixMatches(String prefix, String word) {
- prefix = prefix.toLowerCase();
- return word.startsWith(prefix);
- }
-
- public String[] getAllWordsWithPrefix(String prefix) {
- String all[] = getAllKeywords();
- return getMatched(prefix, all);
- }
-
- private String[] getMatched(String prefix, String all[]) {
- ArrayList matched = new ArrayList(10);
- for (int i = 0; i < all.length; i++)
- if (prefixMatches(prefix, all[i]))
- matched.add(all[i]);
-
- return (String[]) matched.toArray(new String[matched.size()]);
- }
-
- public String[] getTagsWithPrefix(String prefix) {
- return getMatched(prefix, getRootTags());
- }
-
- public String[] getNonTagsKeywordsWithPrefix(String key, String prefix) {
- return getMatched(prefix, getInnerKeywordsFor(key));
- }
-
- protected String[] getAllWords(char c, JETDocumentReader reader) {
- ArrayList all = new ArrayList(20);
- char currChar = c;
- currChar = trimBlanksBackward(reader, currChar);
- for (boolean done = false; !done;) {
- Stack stack = new Stack();
- for (; currChar != '\uFFFF' && !Character.isWhitespace(currChar); currChar = reader.readBackward())
- stack.push(new Character(currChar));
-
- String s;
- for (s = new String(); !stack.empty(); s = (new StringBuilder(String.valueOf(s))).append(
- ((Character) stack.pop()).toString()).toString())
- ;
- int jspPt = s.indexOf("<%@");
- if (jspPt >= 0) {
- s = s.substring(jspPt + 3);
- done = true;
- }
- all.add(s);
- currChar = trimBlanksBackward(reader, currChar);
- if (currChar == '\uFFFF' || currChar == '@')
- done = true;
- }
-
- return (String[]) all.toArray(new String[all.size()]);
- }
-
- private char trimBlanksBackward(JETDocumentReader reader, char currChar) {
- for (; currChar != '\uFFFF' && Character.isWhitespace(currChar); currChar = reader.readBackward())
- ;
- return currChar;
- }
-
- protected abstract char getRootTagPrevChar();
-
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
- org.eclipse.jface.text.IDocument doc = viewer.getDocument();
- JETDocumentReader reader = new JETDocumentReader(doc, offset);
- char c = reader.readBackward();
- ICompletionProposal result[] = (ICompletionProposal[]) null;
- String allWords[] = getAllWords(c, reader);
- if (Character.isSpaceChar(c)) {
- String nonTagWords[] = getInnerKeywordsFor(allWords[allWords.length - 1]);
- result = new ICompletionProposal[nonTagWords.length];
- for (int i = 0; i < nonTagWords.length; i++)
- result[i] = new CompletionProposal(nonTagWords[i], offset, 0, nonTagWords[i].length());
-
- } else if (c == getRootTagPrevChar()) {
- String words[] = getRootTags();
- result = new ICompletionProposal[words.length];
- for (int i = 0; i < words.length; i++)
- result[i] = new CompletionProposal(words[i].substring(allWords[0].length()), offset, 0, words[i].length()
- - allWords[0].length(), null, words[i], null, null);
-
- } else if (Character.isLetter(c)) {
- String words[];
- if (allWords.length > 1)
- words = getNonTagsKeywordsWithPrefix(allWords[allWords.length - 1], allWords[0]);
- else
- words = getTagsWithPrefix(allWords[0]);
- result = new ICompletionProposal[words.length];
- for (int i = 0; i < words.length; i++)
- result[i] = new CompletionProposal(words[i].substring(allWords[0].length()), offset, 0, words[i].length()
- - allWords[0].length(), null, words[i], null, null);
-
- }
- return result;
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETCustomTagAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETCustomTagAssistProcessor.java
deleted file mode 100644
index 869dc5a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETCustomTagAssistProcessor.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import java.util.*;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.taglib.*;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-public class JETCustomTagAssistProcessor extends AbstractXMLTagsBasedAssistProcessor {
-
- private String rootTags[];
- private String tagAttributes[][];
-
- public JETCustomTagAssistProcessor(JETTextEditor editor) {
- super(editor);
- }
-
- public String[] getRootTags() {
- if (rootTags == null) {
- Collection tagNames = new ArrayList();
- String tagLibIds[] = TagLibraryManager.getInstance().getKnownLibraryIds();
- for (int i = 0; i < tagLibIds.length; i++) {
- String id = tagLibIds[i];
- TagLibrary tagLib = TagLibraryManager.getInstance().getTagLibrary(id, true);
- String names[] = tagLib.getTagNames();
- for (int j = 0; j < names.length; j++) {
- String name = names[j];
- tagNames.add((new StringBuilder(String.valueOf(tagLib.getDefaultPrefix()))).append(":").append(name)
- .toString());
- }
-
- }
-
- rootTags = new String[tagNames.size()];
- tagNames.toArray(rootTags);
- }
- return rootTags;
- }
-
- public String[][] getTagAttributes() {
- if (tagAttributes == null) {
- Map tagAttributesMap = new HashMap();
- String tagLibIds[] = TagLibraryManager.getInstance().getKnownLibraryIds();
- for (int i = 0; i < tagLibIds.length; i++) {
- String id = tagLibIds[i];
- TagLibrary tagLib = TagLibraryManager.getInstance().getTagLibrary(id, true);
- String names[] = tagLib.getTagNames();
- for (int j = 0; j < names.length; j++) {
- String name = names[j];
- TagDefinition tagDef = tagLib.getTagDefinition(name);
- Collection tagAttributeDefinitions = tagDef.getAttributeDefinitions();
- String attributeNames[] = new String[tagAttributeDefinitions.size() + 1];
- attributeNames[0] = (new StringBuilder(String.valueOf(tagLib.getDefaultPrefix()))).append(":").append(name)
- .toString();
- int cpt = 1;
- for (Iterator iterator = tagAttributeDefinitions.iterator(); iterator.hasNext();) {
- TagAttributeDefinition tagAttributeDef = (TagAttributeDefinition) iterator.next();
- attributeNames[cpt++] = tagAttributeDef.getName();
- }
-
- tagAttributesMap.put((new StringBuilder(String.valueOf(tagLib.getDefaultPrefix()))).append(":").append(name)
- .toString(), attributeNames);
- }
-
- }
-
- int cpt = 0;
- tagAttributes = new String[tagAttributesMap.size()][];
- for (Iterator iterator = tagAttributesMap.keySet().iterator(); iterator.hasNext();) {
- String tagName = (String) iterator.next();
- String attributeNames[] = (String[]) tagAttributesMap.get(tagName);
- tagAttributes[cpt++] = attributeNames;
- }
-
- }
- return tagAttributes;
- }
-
- protected char getRootTagPrevChar() {
- return '<';
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- return null;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- return null;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETDirectiveAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETDirectiveAssistProcessor.java
deleted file mode 100644
index 3b48a71..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETDirectiveAssistProcessor.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-public class JETDirectiveAssistProcessor extends AbstractXMLTagsBasedAssistProcessor {
- private static String rootTags[] = { "jet", "taglib", "include", "start", "end" };
- private static String tagAttributes[][] = { { "jet", "package", "class", "imports", "startTag", "endTag" },
- { "taglib", "id", "prefix" }, { "include", "file" }, { "start", "id" }, { "end", "id" } };
-
- public JETDirectiveAssistProcessor(JETTextEditor editor) {
- super(editor);
- }
-
- public String[] getRootTags() {
- return rootTags;
- }
-
- public String[][] getTagAttributes() {
- return tagAttributes;
- }
-
- protected char getRootTagPrevChar() {
- return '@';
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- return null;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- return null;
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaDeclarationAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaDeclarationAssistProcessor.java
deleted file mode 100644
index 845e288..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaDeclarationAssistProcessor.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.ui.text.java.IJavaCompletionProposal;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.JavaDeclaration;
-import org.eclipse.jet.internal.editor.JETEditorHelper;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-public class JETJavaDeclarationAssistProcessor extends AbstractJETAssistProcessor {
- private char completionProposalAutoActivationCharacters[];
-
- public JETJavaDeclarationAssistProcessor(JETTextEditor editor) {
- super(editor);
- completionProposalAutoActivationCharacters = editor.getEditorPreferenceStore().getString(
- "content_assist_autoactivation_triggers_java").toCharArray();
- }
-
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
- JETCompilationUnit cu = editor.requestCompilationUnit();
- JavaDeclaration declaration = (JavaDeclaration) editor.getASTElement(offset);
-
- // locate the java content first offset start in the JET document.
- // a java element is of the form <% {java content} %>
- // in order to have an exact matching between the completion offset in the JET document and the
- // completion offset of the java content, we should perform the offset matching with the java content start
- // not with the element offset start (the "<%" char offset start)
- int javaContentStart = declaration.getJavaStart();
-
- IJavaProject javaProject = editor.getJavaProject();
- if (javaProject != null) {
- Map mappingPositions = new HashMap();
- String javaSource = editor.compilationHelper().getJavaCode(cu, mappingPositions);
- int javaStartOffset = ((Position)mappingPositions.get(declaration)).offset;
- int javaOffset = javaStartOffset + (offset - javaContentStart);
-
- // check that the positions matches
- JETEditorHelper.checkOffsetPositions(javaSource, viewer.getDocument().get(), javaContentStart, javaStartOffset, declaration.getJavaEnd() - javaContentStart);
-
- IJavaCompletionProposal javaCompletionProposals[] = JETEditorHelper
- .getJavaCompletionProposal(javaProject, cu, javaSource, viewer, javaOffset);
- JETEditorHelper.adjustResults(javaCompletionProposals, offset);
- return javaCompletionProposals;
- } else {
- return null;
- }
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- return completionProposalAutoActivationCharacters;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- return null;
- }
-
- public String getErrorMessage() {
- return null;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaExpressionAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaExpressionAssistProcessor.java
deleted file mode 100644
index fbfc977..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaExpressionAssistProcessor.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.ui.text.java.IJavaCompletionProposal;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.JavaExpression;
-import org.eclipse.jet.internal.editor.JETEditorHelper;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-public class JETJavaExpressionAssistProcessor extends AbstractJETAssistProcessor {
- private char completionProposalAutoActivationCharacters[];
-
- /**
- * @param editor
- */
- public JETJavaExpressionAssistProcessor(JETTextEditor editor) {
- super(editor);
- completionProposalAutoActivationCharacters = editor.getEditorPreferenceStore().getString(
- "content_assist_autoactivation_triggers_java").toCharArray();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.text.contentassist.IContentAssistProcessor#computeCompletionProposals(org.eclipse.jface.text.ITextViewer, int)
- */
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
- JETCompilationUnit cu = editor.requestCompilationUnit();
- JavaExpression expression = (JavaExpression) editor.getASTElement(offset);
-
- // locate the java content first offset start in the JET document.
- // a java element is of the form <% {java content} %>
- // in order to have an exact matching between the completion offset in the JET document and the
- // completion offset of the java content, we should perform the offset matching with the java content start
- // not with the element offset start (the "<%" char offset start)
- int javaContentStart = expression.getJavaStart();
-
- IJavaProject javaProject = editor.getJavaProject();
- if (javaProject != null) {
- // fetch the java content generated for all the AST elements till the current expression
- Map mappingPositions = new HashMap();
- String javaSource = editor.compilationHelper().getJavaCode(cu, mappingPositions);
- int javaStartOffset = ((Position)mappingPositions.get(expression)).offset;
- // check that the positions matches
- JETEditorHelper.checkOffsetPositions(javaSource, viewer.getDocument().get(), javaContentStart, javaStartOffset, expression.getJavaEnd() - javaContentStart);
-
- // calculate where the cursor would be (offset) within the javaSource...
- int javaCursorOffset = javaStartOffset + (offset - javaContentStart);
- IJavaCompletionProposal javaCompletionProposals[] = JETEditorHelper
- .getJavaCompletionProposal(javaProject, cu, javaSource, viewer, javaCursorOffset);
- JETEditorHelper.adjustResults(javaCompletionProposals, offset);
- return javaCompletionProposals;
- } else {
- return null;
- }
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- return completionProposalAutoActivationCharacters;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- return null;
- }
-
- public String getErrorMessage() {
- return null;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaScriptletAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaScriptletAssistProcessor.java
deleted file mode 100644
index c25e71d..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETJavaScriptletAssistProcessor.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.ui.text.java.IJavaCompletionProposal;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.JavaScriptlet;
-import org.eclipse.jet.internal.editor.JETEditorHelper;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Position;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-public class JETJavaScriptletAssistProcessor extends AbstractJETAssistProcessor {
- private char completionProposalAutoActivationCharacters[];
-
- public JETJavaScriptletAssistProcessor(JETTextEditor editor) {
- super(editor);
- completionProposalAutoActivationCharacters = editor.getEditorPreferenceStore().getString(
- "content_assist_autoactivation_triggers_java").toCharArray();
- }
-
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
- JETCompilationUnit cu = editor.requestCompilationUnit();
- JavaScriptlet scriptlet = (JavaScriptlet) editor.getASTElement(offset);
-
- // locate the java content first offset start in the JET document.
- // a java element is of the form <% {java content} %>
- // in order to have an exact matching between the completion offset in the JET document and the
- // completion offset of the java content, we should perform the offset matching with the java content start
- // not with the element offset start (the "<%" char offset start)
- int javaContentStart = scriptlet.getJavaStart();
-
- IJavaProject javaProject = editor.getJavaProject();
- if (javaProject != null) {
- // fetch the java content generated for all the AST elements till the current expression
- Map mappingPositions = new HashMap();
- String javaSource = editor.compilationHelper().getJavaCode(cu, mappingPositions);
- int javaStartOffset = ((Position)mappingPositions.get(scriptlet)).offset;
- // check that the positions matches
- JETEditorHelper.checkOffsetPositions(javaSource, viewer.getDocument().get(), javaContentStart, javaStartOffset, scriptlet.getJavaEnd() - javaContentStart);
-
- // calculate where the cursor would be (offset) within the javaSource...
- int javaCursorOffset = javaStartOffset + (offset - javaContentStart);
- IJavaCompletionProposal javaCompletionProposals[] = JETEditorHelper
- .getJavaCompletionProposal(javaProject, cu, javaSource, viewer, javaCursorOffset);
- JETEditorHelper.adjustResults(javaCompletionProposals, offset);
- return javaCompletionProposals;
- } else {
- return null;
- }
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- return completionProposalAutoActivationCharacters;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- return null;
- }
-
- public String getErrorMessage() {
- return null;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETTagAssistProcessor.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETTagAssistProcessor.java
deleted file mode 100644
index 4c12527..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/contentassist/JETTagAssistProcessor.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.contentassist;
-
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-
-
-public class JETTagAssistProcessor extends AbstractJETAssistProcessor {
-
- public JETTagAssistProcessor(JETTextEditor editor) {
- super(editor);
- // TODO Auto-generated constructor stub
- }
-
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer, int offset) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public String getErrorMessage() {
- // TODO Auto-generated method stub
- return null;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETCustomTagFormattingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETCustomTagFormattingStrategy.java
deleted file mode 100644
index 4f41e0d..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETCustomTagFormattingStrategy.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.formatter;
-
-import org.eclipse.jface.text.formatter.IFormattingContext;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.formatter.IFormattingStrategyExtension;
-
-public class JETCustomTagFormattingStrategy implements IFormattingStrategy, IFormattingStrategyExtension {
-
- public String format(String content, boolean isLineStart, String indentation, int[] positions) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void formatterStarts(String initialIndentation) {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStops() {
- // TODO Auto-generated method stub
-
- }
-
- public void format() {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStarts(IFormattingContext context) {
- // TODO Auto-generated method stub
-
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETDirectiveFormattingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETDirectiveFormattingStrategy.java
deleted file mode 100644
index 05df61a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETDirectiveFormattingStrategy.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.formatter;
-
-import org.eclipse.jface.text.formatter.IFormattingContext;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.formatter.IFormattingStrategyExtension;
-
-public class JETDirectiveFormattingStrategy implements IFormattingStrategy, IFormattingStrategyExtension {
-
- public String format(String content, boolean isLineStart, String indentation, int[] positions) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void formatterStarts(String initialIndentation) {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStops() {
- // TODO Auto-generated method stub
-
- }
-
- public void format() {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStarts(IFormattingContext context) {
- // TODO Auto-generated method stub
-
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaDeclarationFormattingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaDeclarationFormattingStrategy.java
deleted file mode 100644
index 6bb8011..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaDeclarationFormattingStrategy.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.formatter;
-
-import org.eclipse.jface.text.formatter.IFormattingContext;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.formatter.IFormattingStrategyExtension;
-
-public class JETJavaDeclarationFormattingStrategy implements IFormattingStrategy, IFormattingStrategyExtension {
-
- public String format(String content, boolean isLineStart, String indentation, int[] positions) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void formatterStarts(String initialIndentation) {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStops() {
- // TODO Auto-generated method stub
-
- }
-
- public void format() {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStarts(IFormattingContext context) {
- // TODO Auto-generated method stub
-
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaExpressionFormattingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaExpressionFormattingStrategy.java
deleted file mode 100644
index 7f7a128..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaExpressionFormattingStrategy.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.formatter;
-
-import org.eclipse.jface.text.formatter.IFormattingContext;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.formatter.IFormattingStrategyExtension;
-
-public class JETJavaExpressionFormattingStrategy implements IFormattingStrategy, IFormattingStrategyExtension {
-
- public String format(String content, boolean isLineStart, String indentation, int[] positions) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void formatterStarts(String initialIndentation) {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStops() {
- // TODO Auto-generated method stub
-
- }
-
- public void format() {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStarts(IFormattingContext context) {
- // TODO Auto-generated method stub
-
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaScriptletFormattingStrategy.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaScriptletFormattingStrategy.java
deleted file mode 100644
index 81ef27b..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/formatter/JETJavaScriptletFormattingStrategy.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.formatter;
-
-import org.eclipse.jface.text.formatter.IFormattingContext;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.formatter.IFormattingStrategyExtension;
-
-public class JETJavaScriptletFormattingStrategy implements IFormattingStrategy, IFormattingStrategyExtension {
-
- public String format(String content, boolean isLineStart, String indentation, int[] positions) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void formatterStarts(String initialIndentation) {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStops() {
- // TODO Auto-generated method stub
-
- }
-
- public void format() {
- // TODO Auto-generated method stub
-
- }
-
- public void formatterStarts(IFormattingContext context) {
- // TODO Auto-generated method stub
-
- }
-
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/i18n/TextEditorMessages.properties b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/i18n/TextEditorMessages.properties
deleted file mode 100644
index 7deaa82..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/i18n/TextEditorMessages.properties
+++ /dev/null
@@ -1 +0,0 @@
-ContentAssistProposal.label = Content Assist \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineContentProvider.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineContentProvider.java
deleted file mode 100644
index 08e62cd..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineContentProvider.java
+++ /dev/null
@@ -1,187 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.outline;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Iterator;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.core.parser.ast.TextElement;
-import org.eclipse.jet.core.parser.ast.XMLBodyElement;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-
-public class JETOutlineContentProvider implements ITreeContentProvider {
- private ImportsContainerInput importContainerInput;
- private CompilationUnitContainerInput astContainerInput;
- private OutputPackageInput outputPackageInput;
- private JETCompilationUnit cu;
- private OutputClassInput outputClassInput;
- private JETTextEditor editor;
-
- public class OutputClassInput {
- private JETCompilationUnit compilationUnit;
- public OutputClassInput(JETCompilationUnit cu) {
- this.compilationUnit = cu;
- }
- public JETCompilationUnit getCompilationUnit() {
- return compilationUnit;
- }
- }
-
- public class OutputPackageInput {
- private JETCompilationUnit compilationUnit;
- public OutputPackageInput(JETCompilationUnit cu) {
- this.compilationUnit = cu;
- }
- public JETCompilationUnit getCompilationUnit() {
- return compilationUnit;
- }
- }
-
- public class ImportInput {
- private ImportsContainerInput container;
- private String imp;
- public ImportInput(ImportsContainerInput container, String imp) {
- this.container = container;
- this.imp = imp;
- }
- public ImportsContainerInput getImportsContainerInput() {
- return container;
- }
- public String toString() {
- return imp;
- }
- }
-
- public class ImportsContainerInput {
- private JETCompilationUnit compilationUnit;
- private Collection importInputs;
- public ImportsContainerInput(JETCompilationUnit cu) {
- this.compilationUnit = cu;
- importInputs = new ArrayList();
- for (Iterator iterator = cu.getImports().iterator(); iterator.hasNext();) {
- String imp = (String) iterator.next();
- importInputs.add(new ImportInput(this, imp));
- }
- }
- public JETCompilationUnit getCompilationUnit() {
- return compilationUnit;
- }
- public Collection getImportImputs() {
- return importInputs;
- }
- }
-
- public class CompilationUnitContainerInput {
- private Collection bodyElements;
-
- private JETCompilationUnit compilationUnit;
-
- public CompilationUnitContainerInput(JETCompilationUnit cu) {
- this.bodyElements = new ArrayList();
- this.compilationUnit = cu;
- for (Iterator iterator = cu.getBodyElements().iterator(); iterator.hasNext();) {
- JETASTElement elt = (JETASTElement) iterator.next();
- if (isFiltered(elt))
- continue;
- bodyElements.add(elt);
- }
- }
-
- public Collection getFilteredASTElements() {
- return bodyElements;
- }
-
- public JETCompilationUnit getCompilationUnit() {
- return compilationUnit;
- }
-
- private boolean isFiltered(JETASTElement elt) {
- if (elt instanceof TextElement) {
- String text = new String(((TextElement) elt).getText());
- text = text.replace('\r', ' ');
- text = text.replace('\n', ' ');
- text = text.replace('\t', ' ');
- text = text.trim();
- return text.length() == 0;
- }
- return false;
- }
- }
-
- public JETOutlineContentProvider(JETTextEditor editor) {
- this.editor = editor;
- }
-
- public void dispose() {
- // TODO Auto-generated method stub
- }
-
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- cu = (JETCompilationUnit) newInput;
- }
-
- public Object[] getElements(Object inputElement) {
- Collection results = new ArrayList();
- if (inputElement instanceof JETCompilationUnit) {
- JETCompilationUnit cu = (JETCompilationUnit) inputElement;
- results.add(outputPackageInput = new OutputPackageInput(cu));
- results.add(importContainerInput = new ImportsContainerInput(cu));
- results.add(astContainerInput = new CompilationUnitContainerInput(cu));
- results.addAll(Arrays.asList(cu.getTagLibraryReferences()));
- }
- return results.toArray();
- }
-
- public Object[] getChildren(Object parentElement) {
- if (parentElement == outputPackageInput) {
- return new Object[] { outputClassInput = new OutputClassInput(cu) };
- }
- if (parentElement == importContainerInput) {
- return importContainerInput.getImportImputs().toArray();
- }
- if (parentElement == astContainerInput) {
- return astContainerInput.bodyElements.toArray();
- }
- if (parentElement instanceof XMLBodyElement) {
- XMLBodyElement astElement = (XMLBodyElement) parentElement;
- return astElement.getBodyElements().toArray();
- }
- return null;
- }
-
- public Object getParent(Object element) {
- if (element == outputPackageInput || element == importContainerInput || element == astContainerInput)
- return cu;
- if (element == outputClassInput)
- return outputPackageInput;
- if (element instanceof ImportInput)
- return ((ImportInput) element).getImportsContainerInput();
- if (element instanceof JETASTElement) {
- if (((JETASTElement) element).getParent() == cu)
- return astContainerInput;
- return ((JETASTElement) element).getParent();
- }
- if (importContainerInput.getCompilationUnit().getImports().contains(element))
- return importContainerInput;
- return null;
- }
-
- public boolean hasChildren(Object element) {
- return (element instanceof XMLBodyElement) || (element == outputPackageInput) || (element == importContainerInput)
- || (element == astContainerInput);
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineLabelProvider.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineLabelProvider.java
deleted file mode 100644
index bd9b7d8..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlineLabelProvider.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.outline;
-
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jet.compiler.CompileOptionsManager;
-import org.eclipse.jet.core.compiler.JETCompilerOptions;
-import org.eclipse.jet.core.parser.ast.Comment;
-import org.eclipse.jet.core.parser.ast.JETDirective;
-import org.eclipse.jet.core.parser.ast.JavaDeclaration;
-import org.eclipse.jet.core.parser.ast.JavaExpression;
-import org.eclipse.jet.core.parser.ast.JavaScriptlet;
-import org.eclipse.jet.core.parser.ast.TextElement;
-import org.eclipse.jet.core.parser.ast.XMLElement;
-import org.eclipse.jet.internal.editor.Activator;
-import org.eclipse.jet.internal.editor.JETEditorHelper;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.taglib.TagLibraryReference;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.ISharedImages;
-
-public class JETOutlineLabelProvider extends LabelProvider {
- private JETTextEditor editor;
-
- public JETOutlineLabelProvider(JETTextEditor editor) {
- this.editor = editor;
- }
-
- public Image getImage(Object element) {
- if (element instanceof Comment) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_JAVADOCTAG);
- } else if (element instanceof JavaDeclaration) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_PUBLIC);
- } else if (element instanceof JavaExpression) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_DEFAULT);
- } else if (element instanceof JavaScriptlet) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_PUBLIC);
- } else if (element instanceof JETDirective) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_PROTECTED);
- } else if (element instanceof TextElement) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_IMPDECL);
- } else if (element instanceof XMLElement) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_PROTECTED);
- } else if (element instanceof JETOutlineContentProvider.ImportsContainerInput) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_IMPCONT);
- } else if (element instanceof JETOutlineContentProvider.ImportInput) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_IMPDECL);
- } else if (element instanceof JETOutlineContentProvider.CompilationUnitContainerInput) {
- return Activator.getDefault().getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FILE);
- } else if (element instanceof JETOutlineContentProvider.OutputPackageInput) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_PACKDECL);
- } else if (element instanceof JETOutlineContentProvider.OutputClassInput) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_CUNIT);
- } else if (element instanceof TagLibraryReference) {
- return JavaUI.getSharedImages().getImage(org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_ANNOTATION);
- }
- return super.getImage(element);
- }
-
- public String getText(Object element) {
- if (element instanceof Comment)
- return getShortText(((Comment) element).getCommentText());
- if (element instanceof JavaDeclaration)
- return (new StringBuilder("<%!")).append(getShortText(((JavaDeclaration) element).getJavaContent())).append("%>")
- .toString();
- if (element instanceof JavaExpression)
- return (new StringBuilder("<%=")).append(getShortText(((JavaExpression) element).getJavaContent())).append("%>")
- .toString();
- if (element instanceof JavaScriptlet)
- return (new StringBuilder("<%")).append(getShortText(((JavaScriptlet) element).getJavaContent())).append("%>")
- .toString();
- if (element instanceof JETDirective)
- return (new StringBuilder("<%@")).append(((JETDirective) element).getName()).append(" ").append(
- getAttributesText((JETDirective) element)).append("%>").toString();
- if (element instanceof TextElement)
- return getShortText(new String(((TextElement) element).getText()));
- if (element instanceof XMLElement)
- return (new StringBuilder("<")).append(((XMLElement) element).getName()).append(" ").append(
- getAttributesText((XMLElement) element)).append(">").toString();
- if (element instanceof JETOutlineContentProvider.ImportsContainerInput)
- return "import declarations";
- if (element instanceof JETOutlineContentProvider.CompilationUnitContainerInput)
- return "Template AST";
- if (element instanceof JETOutlineContentProvider.OutputPackageInput) {
- String packageName = ((JETOutlineContentProvider.OutputPackageInput) element).getCompilationUnit()
- .getOutputJavaPackage();
- if (packageName == null) {
- Map options = CompileOptionsManager.getOptions(editor.getJavaProject().getProject());
- if (options.isEmpty())
- options = JETCompilerOptions.getDefaultCompilerOptions();
- packageName = (String) options.get("org.eclipse.jet.compiledTemplatePackage");
- }
- return packageName;
- }
- if (element instanceof JETOutlineContentProvider.OutputClassInput) {
- String className = ((JETOutlineContentProvider.OutputClassInput) element).getCompilationUnit()
- .getOutputJavaClassName();
- if (className == null && (editor.getEditorInput() instanceof IFileEditorInput)) {
- IFile file = ((IFileEditorInput) editor.getEditorInput()).getFile();
- String inputName = file.getFullPath().removeFileExtension().lastSegment();
- String baseClassName = JETEditorHelper.makeJavaClassName(inputName);
- className = baseClassName;
- }
- return className;
- }
- if (element instanceof TagLibraryReference)
- return ((TagLibraryReference) element).getTagLibraryId();
- else
- return super.getText(element);
- }
-
- private String getShortText(String text) {
- if (text.length() > 25)
- text = text.substring(0, 25) + "...";
- return text;
- }
-
- private String getAttributesText(XMLElement element) {
- Map attributes = element.getAttributes();
- StringBuffer textBuffer = new StringBuffer(attributes.size() * 5);
- for (Iterator iterator = attributes.keySet().iterator(); iterator.hasNext();) {
- String attrName = (String) iterator.next();
- String attrValue = (String) attributes.get(attrName);
- textBuffer.append(attrName).append("=\"").append(attrValue).append("\"");
- textBuffer.append(' ');
- }
- return textBuffer.toString();
- }
-
- private String getAttributesText(JETDirective directive) {
- Map attributes = directive.getAttributes();
- StringBuffer textBuffer = new StringBuffer(attributes.size() * 5);
- for (Iterator iterator = attributes.keySet().iterator(); iterator.hasNext();) {
- String attrName = (String) iterator.next();
- String attrValue = (String) attributes.get(attrName);
- textBuffer.append(attrName).append("=\"").append(attrValue).append("\"");
- textBuffer.append(' ');
- }
- return textBuffer.toString();
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlinePage.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlinePage.java
deleted file mode 100644
index d46ee26..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/outline/JETOutlinePage.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.outline;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jet.core.parser.ast.JETCompilationUnit;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.views.contentoutline.ContentOutlinePage;
-
-public class JETOutlinePage extends ContentOutlinePage implements IAdaptable {
- private JETTextEditor editor;
-
- private TreeViewer contentOutlineViewer;
-
- public JETOutlinePage(JETTextEditor editor) {
- this.editor = editor;
- }
-
- public void createControl(Composite parent) {
- super.createControl(parent);
- contentOutlineViewer = getTreeViewer();
- contentOutlineViewer.addSelectionChangedListener(this);
- contentOutlineViewer.setContentProvider(new JETOutlineContentProvider(editor));
- contentOutlineViewer.setLabelProvider(new JETOutlineLabelProvider(editor));
- setInput();
- }
-
- public void setInput() {
- JETCompilationUnit cu = editor.requestCompilationUnit();
- contentOutlineViewer.setInput(cu);
- contentOutlineViewer.refresh();
- }
-
- public Object getAdapter(Class adapter) {
- return null;
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/ITokenScannerProvider.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/ITokenScannerProvider.java
deleted file mode 100644
index d4a7430..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/ITokenScannerProvider.java
+++ /dev/null
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.partition;
-
-import org.eclipse.jface.text.rules.ITokenScanner;
-
-public interface ITokenScannerProvider {
-
- public abstract ITokenScanner getTokenScanner(String s);
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/JETDocumentPartitionScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/JETDocumentPartitionScanner.java
deleted file mode 100644
index 6a58e72..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/JETDocumentPartitionScanner.java
+++ /dev/null
@@ -1,375 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.partition;
-
-import java.util.*;
-import org.eclipse.jdt.internal.ui.text.java.JavaAutoIndentStrategy;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.autoedit.JETTemplateAutoEditStrategy;
-import org.eclipse.jet.internal.editor.configuration.delegates.IJETDefaultTextColorerDelegate;
-import org.eclipse.jet.internal.editor.contentassist.*;
-import org.eclipse.jet.internal.editor.formatter.*;
-import org.eclipse.jet.internal.editor.rules.*;
-import org.eclipse.jet.internal.editor.scanners.*;
-import org.eclipse.jface.text.IAutoEditStrategy;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.contentassist.ContentAssistant;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.jface.text.formatter.IFormattingStrategy;
-import org.eclipse.jface.text.presentation.IPresentationDamager;
-import org.eclipse.jface.text.presentation.IPresentationRepairer;
-import org.eclipse.jface.text.rules.*;
-
-public class JETDocumentPartitionScanner extends RuleBasedPartitionScanner {
-
- public static final String JET_COMMENT = "__jet_comment";
- public static final String JET_CUSTOM_TAG = "__jet_xml_tag";
- public static final String JET_DIRECTIVE = "__jet_directive";
- public static final String JET_JAVA_DECLARATION = "__jet_java_declaration";
- public static final String JET_JAVA_EXPRESSION = "__jet_java_expression";
- public static final String JET_JAVA_SCRIPTLET = "__jet_java_scriptlet";
-
- private Map tokenScanners;
- private Map damagerRepairers;
- private Map damagersOnly;
- private Map repairersOnly;
- private Map completionProcessors;
- private Map formattingStrategies;
- private JETTextEditor editor;
-
- private List contentTypes;
- private JETCustomTagScanner tagScanner;
- private JETDirectiveScanner directiveScanner;
- private JETJavaDeclarationScanner declarationScanner;
- private JETJavaExpressionScanner expressionScanner;
- private JETJavaScriptletScanner scriptletScanner;
- private JETCommentScanner commentScanner;
-
- private IContentAssistProcessor tagAssistProcessor;
- private IContentAssistProcessor scriptletAssistProcessor;
- private IContentAssistProcessor expressionAssistProcessor;
- private IContentAssistProcessor declarationAssistProcessor;
-
- private IContentAssistProcessor directiveAssistProcessor;
- private IFormattingStrategy tagFormattingStrategy;
- private IFormattingStrategy scriptletFormattingStrategy;
- private IFormattingStrategy expressionFormattingStrategy;
- private IFormattingStrategy declarationFormattingStrategy;
- private IFormattingStrategy directiveFormattingStrategy;
-
- private PartitionScannerBasedDamagerRepairer jetTextContentDamagerRepairer;
-
- public JETDocumentPartitionScanner(JETTextEditor editor) {
- this.editor = editor;
- List rules = new ArrayList();
- org.eclipse.jface.text.rules.IToken jetComments = new Token("__jet_comment");
- org.eclipse.jface.text.rules.IToken jetCustomTags = new Token("__jet_xml_tag");
- org.eclipse.jface.text.rules.IToken jetDirective = new Token("__jet_directive");
- org.eclipse.jface.text.rules.IToken jetJavaDeclaration = new Token("__jet_java_declaration");
- org.eclipse.jface.text.rules.IToken jetJavaExpression = new Token("__jet_java_expression");
- org.eclipse.jface.text.rules.IToken jetJavaScriptlet = new Token("__jet_java_scriptlet");
- rules.add(new ASTJETCommentRule(editor, jetComments));
- rules.add(new ASTJETCustomTagRule(editor, jetCustomTags));
- rules.add(new ASTJETDirectiveRule(editor, jetDirective));
- rules.add(new ASTJETJavaDeclarationRule(editor, jetJavaDeclaration));
- rules.add(new ASTJETJavaExpressionRule(editor, jetJavaExpression));
- rules.add(new ASTJETJavaScriptletRule(editor, jetJavaScriptlet));
- IPredicateRule result[] = new IPredicateRule[rules.size()];
- result = (IPredicateRule[]) rules.toArray(result);
- setPredicateRules(result);
- }
-
- public int getNextCharacterOffset() {
- return fOffset;
- }
-
- public String[] getContentTypes() {
- if (contentTypes == null) {
- contentTypes = new ArrayList();
- contentTypes.add(IDocument.DEFAULT_CONTENT_TYPE);
- contentTypes.add("__jet_comment");
- contentTypes.add("__jet_xml_tag");
- contentTypes.add("__jet_directive");
- contentTypes.add("__jet_java_declaration");
- contentTypes.add("__jet_java_expression");
- contentTypes.add("__jet_java_scriptlet");
- }
- String result[] = new String[contentTypes.size()];
- result = (String[]) contentTypes.toArray(result);
- return result;
- }
-
- private void initTokenScanners() {
- tokenScanners = new HashMap();
- tokenScanners.put("__jet_comment", getCommentScanner());
- tokenScanners.put("__jet_xml_tag", getCustomTagScanner());
- tokenScanners.put("__jet_directive", getDirectiveScanner());
- tokenScanners.put("__jet_java_declaration", getJavaDeclarationScanner());
- tokenScanners.put("__jet_java_expression", getJavaExpressionScanner());
- tokenScanners.put("__jet_java_scriptlet", getJavaScriptletScanner());
- }
-
- private void initCompletionProcessors(ContentAssistant assistant) {
- completionProcessors = new HashMap();
- completionProcessors.put(IDocument.DEFAULT_CONTENT_TYPE, getTextElementAssistProcessor(assistant));
- completionProcessors.put("__jet_comment", getCommentAssistProcessor(assistant));
- completionProcessors.put("__jet_xml_tag", getCustomTagAssistProcessor(assistant));
- completionProcessors.put("__jet_directive", getDirectiveAssistProcessor(assistant));
- completionProcessors.put("__jet_java_declaration", getJavaDeclarationAssistProcessor(assistant));
- completionProcessors.put("__jet_java_expression", getJavaExpressionAssistProcessor(assistant));
- completionProcessors.put("__jet_java_scriptlet", getJavaScriptletAssistProcessor(assistant));
- }
-
- private void initFormattingStrategies() {
- formattingStrategies = new HashMap();
- formattingStrategies.put(IDocument.DEFAULT_CONTENT_TYPE, getTextElementFormattingStrategy());
- formattingStrategies.put("__jet_comment", getCommentFormattingStrategy());
- formattingStrategies.put("__jet_xml_tag", getCustomTagFormattingStrategy());
- formattingStrategies.put("__jet_directive", getDirectiveFormattingStrategy());
- formattingStrategies.put("__jet_java_declaration", getJavaDeclarationFormattingStrategy());
- formattingStrategies.put("__jet_java_expression", getJavaExpressionFormattingStrategy());
- formattingStrategies.put("__jet_java_scriptlet", getJavaScriptletFormattingStrategy());
- }
-
- private void initDamagerRepairers() {
- damagerRepairers = new HashMap();
- damagerRepairers.put("__jet_comment", createDefaultDamagerRepairer("__jet_comment"));
- damagerRepairers.put("__jet_xml_tag", createDefaultDamagerRepairer("__jet_xml_tag"));
- damagerRepairers.put("__jet_directive", createDefaultDamagerRepairer("__jet_directive"));
- damagerRepairers.put("__jet_java_declaration", createDefaultDamagerRepairer("__jet_java_declaration"));
- damagerRepairers.put("__jet_java_expression", createDefaultDamagerRepairer("__jet_java_expression"));
- damagerRepairers.put("__jet_java_scriptlet", createDefaultDamagerRepairer("__jet_java_scriptlet"));
- if (createJETTextContentDamagerRepairer() != null)
- damagerRepairers.put(IDocument.DEFAULT_CONTENT_TYPE, jetTextContentDamagerRepairer);
- }
-
- private void initDamagersOnly() {
- damagersOnly = new HashMap();
- }
-
- protected void initRepairersOnly() {
- repairersOnly = new HashMap();
- }
-
- protected IFormattingStrategy getTextElementFormattingStrategy() {
- return null;
- }
-
- protected IFormattingStrategy getCommentFormattingStrategy() {
- return null;
- }
-
- protected IFormattingStrategy getCustomTagFormattingStrategy() {
- if (tagFormattingStrategy == null)
- tagFormattingStrategy = new JETCustomTagFormattingStrategy();
- return tagFormattingStrategy;
- }
-
- protected IFormattingStrategy getJavaScriptletFormattingStrategy() {
- if (scriptletFormattingStrategy == null)
- scriptletFormattingStrategy = new JETJavaScriptletFormattingStrategy();
- return scriptletFormattingStrategy;
- }
-
- protected IFormattingStrategy getJavaExpressionFormattingStrategy() {
- if (expressionFormattingStrategy == null)
- expressionFormattingStrategy = new JETJavaExpressionFormattingStrategy();
- return expressionFormattingStrategy;
- }
-
- protected IFormattingStrategy getJavaDeclarationFormattingStrategy() {
- if (declarationFormattingStrategy == null)
- declarationFormattingStrategy = new JETJavaDeclarationFormattingStrategy();
- return declarationFormattingStrategy;
- }
-
- protected IFormattingStrategy getDirectiveFormattingStrategy() {
- if (directiveFormattingStrategy == null)
- directiveFormattingStrategy = new JETDirectiveFormattingStrategy();
- return directiveFormattingStrategy;
- }
-
- protected IContentAssistProcessor getTextElementAssistProcessor(ContentAssistant assistant) {
- return null;
- }
-
- protected IContentAssistProcessor getCommentAssistProcessor(ContentAssistant assistant) {
- return null;
- }
-
- protected IContentAssistProcessor getCustomTagAssistProcessor(ContentAssistant assistant) {
- if (tagAssistProcessor == null)
- tagAssistProcessor = new JETCustomTagAssistProcessor(editor);
- return tagAssistProcessor;
- }
-
- protected IContentAssistProcessor getJavaScriptletAssistProcessor(ContentAssistant assistant) {
- if (scriptletAssistProcessor == null)
- scriptletAssistProcessor = new JETJavaScriptletAssistProcessor(editor);
- return scriptletAssistProcessor;
- }
-
- protected IContentAssistProcessor getJavaExpressionAssistProcessor(ContentAssistant assistant) {
- if (expressionAssistProcessor == null)
- expressionAssistProcessor = new JETJavaExpressionAssistProcessor(editor);
- return expressionAssistProcessor;
- }
-
- protected IContentAssistProcessor getJavaDeclarationAssistProcessor(ContentAssistant assistant) {
- if (declarationAssistProcessor == null)
- declarationAssistProcessor = new JETJavaDeclarationAssistProcessor(editor);
- return declarationAssistProcessor;
- }
-
- protected IContentAssistProcessor getDirectiveAssistProcessor(ContentAssistant assistant) {
- if (directiveAssistProcessor == null)
- directiveAssistProcessor = new JETDirectiveAssistProcessor(editor);
- return directiveAssistProcessor;
- }
-
- protected ITokenScanner getCommentScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (commentScanner == null)
- commentScanner = new JETCommentScanner(tokenStyleManager, preferenceStore);
- return commentScanner;
- }
-
- protected ITokenScanner getCustomTagScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (tagScanner == null)
- tagScanner = new JETCustomTagScanner(tokenStyleManager, preferenceStore);
- return tagScanner;
- }
-
- protected ITokenScanner getJavaScriptletScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (scriptletScanner == null)
- scriptletScanner = new JETJavaScriptletScanner(tokenStyleManager, preferenceStore);
- return scriptletScanner;
- }
-
- protected ITokenScanner getJavaExpressionScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (expressionScanner == null)
- expressionScanner = new JETJavaExpressionScanner(tokenStyleManager, preferenceStore);
- return expressionScanner;
- }
-
- protected ITokenScanner getJavaDeclarationScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (declarationScanner == null)
- declarationScanner = new JETJavaDeclarationScanner(tokenStyleManager, preferenceStore);
- return declarationScanner;
- }
-
- protected ITokenScanner getDirectiveScanner() {
- org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager tokenStyleManager = editor.getTokenStyleManager();
- org.eclipse.jface.preference.IPreferenceStore preferenceStore = editor.getEditorPreferenceStore();
- if (directiveScanner == null)
- directiveScanner = new JETDirectiveScanner(tokenStyleManager, preferenceStore);
- return directiveScanner;
- }
-
- public ITokenScanner getTokenScanner(String contentType) {
- if (tokenScanners == null)
- initTokenScanners();
- ITokenScanner scanner = (ITokenScanner) tokenScanners.get(contentType);
- return scanner;
- }
-
- private PartitionScannerBasedDamagerRepairer createJETTextContentDamagerRepairer() {
- if (jetTextContentDamagerRepairer == null) {
- IJETDefaultTextColorerDelegate delegate = editor.getCurrentColorerDelegate();
- if (delegate != null) {
- RuleBasedPartitionScanner partitionScanner = new RuleBasedPartitionScanner();
- partitionScanner.setPredicateRules(delegate.getPartitioningRules());
- jetTextContentDamagerRepairer = new PartitionScannerBasedDamagerRepairer(partitionScanner, delegate);
- }
- }
- return jetTextContentDamagerRepairer;
- }
-
- public void updateJETTextContentDamagerRepairer() {
- if (jetTextContentDamagerRepairer != null) {
- IJETDefaultTextColorerDelegate delegate = editor.getCurrentColorerDelegate();
- if (delegate != null) {
- RuleBasedPartitionScanner partitionScanner = new RuleBasedPartitionScanner();
- partitionScanner.setPredicateRules(delegate.getPartitioningRules());
- jetTextContentDamagerRepairer.setPartitionScanner(partitionScanner);
- jetTextContentDamagerRepairer.setTokenScannerProvider(delegate);
- }
- }
- }
-
- private DefaultDamagerRepairer createDefaultDamagerRepairer(String contentType) {
- ITokenScanner tokenScanner = getTokenScanner(contentType);
- return tokenScanner != null ? new DefaultDamagerRepairer(tokenScanner) : null;
- }
-
- public IPresentationDamager getDamager(String contentType) {
- if (damagerRepairers == null)
- initDamagerRepairers();
- IPresentationDamager damager = (IPresentationDamager) damagerRepairers.get(contentType);
- if (damager == null) {
- if (damagersOnly == null)
- initDamagersOnly();
- damager = (IPresentationDamager) damagersOnly.get(contentType);
- }
- return damager;
- }
-
- public IPresentationRepairer getRepairer(String contentType) {
- if (damagerRepairers == null)
- initDamagerRepairers();
- IPresentationRepairer repairer = (IPresentationRepairer) damagerRepairers.get(contentType);
- if (repairer == null) {
- if (repairersOnly == null)
- initRepairersOnly();
- repairer = (IPresentationRepairer) repairersOnly.get(contentType);
- }
- return repairer;
- }
-
- public IContentAssistProcessor getCompletionProcessor(String contentType, ContentAssistant assistant) {
- if (completionProcessors == null)
- initCompletionProcessors(assistant);
- IContentAssistProcessor processor = (IContentAssistProcessor) completionProcessors.get(contentType);
- return processor;
- }
-
- public IFormattingStrategy getFormattingStrategy(String contentType) {
- if (formattingStrategies == null)
- initFormattingStrategies();
- IFormattingStrategy formatter = (IFormattingStrategy) formattingStrategies.get(contentType);
- return formatter;
- }
-
- public IAutoEditStrategy[] getAutoEditStrategies(String contentType) {
- IAutoEditStrategy result[] = (IAutoEditStrategy[]) null;
- if ("__jet_directive".equals(contentType))
- result = (new IAutoEditStrategy[] { new JETTemplateAutoEditStrategy() });
- else if ("__jet_java_scriptlet".equals(contentType))
- result = (new IAutoEditStrategy[] {
- new JavaAutoIndentStrategy("__dftl_partitioning", editor.getJavaProject()),
- new JETTemplateAutoEditStrategy() });
- else if ("__jet_java_declaration".equals(contentType))
- result = (new IAutoEditStrategy[] {
- new JavaAutoIndentStrategy("__dftl_partitioning", editor.getJavaProject()),
- new JETTemplateAutoEditStrategy() });
- return result;
- }
-
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/PartitionScannerBasedDamagerRepairer.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/PartitionScannerBasedDamagerRepairer.java
deleted file mode 100644
index a02e101..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/partition/PartitionScannerBasedDamagerRepairer.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.partition;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.text.*;
-import org.eclipse.jface.text.presentation.IPresentationDamager;
-import org.eclipse.jface.text.presentation.IPresentationRepairer;
-import org.eclipse.jface.text.rules.*;
-import org.eclipse.swt.custom.StyleRange;
-
-public class PartitionScannerBasedDamagerRepairer implements IPresentationDamager, IPresentationRepairer {
-
- protected IDocument document;
- protected IPartitionTokenScanner partitionScanner;
- protected ITokenScannerProvider tokenScannerProvider;
- protected TextAttribute defaultTextAttribute;
-
- public PartitionScannerBasedDamagerRepairer(IPartitionTokenScanner scanner, ITokenScannerProvider provider) {
- Assert.isNotNull(scanner);
- Assert.isNotNull(provider);
- partitionScanner = scanner;
- tokenScannerProvider = provider;
- defaultTextAttribute = new TextAttribute(null);
- }
-
- public void setDocument(IDocument document) {
- this.document = document;
- }
-
- public void setPartitionScanner(IPartitionTokenScanner partitionScanner) {
- this.partitionScanner = partitionScanner;
- }
-
- public void setTokenScannerProvider(ITokenScannerProvider provider) {
- tokenScannerProvider = provider;
- }
-
- public IRegion getDamageRegion(ITypedRegion partition, DocumentEvent e, boolean documentPartitioningChanged) {
- if (!documentPartitioningChanged)
- return new Region(partition.getOffset(), partition.getLength());
- else
- return partition;
- }
-
- public void createPresentation(TextPresentation presentation, ITypedRegion region) {
- partitionScanner.setRange(document, region.getOffset(), region.getLength());
- String lastContentType = null;
- int partitionScannerTokenLength = 0;
- int partitionScannerTokenOffset = region.getOffset();
- do {
- IToken partitionToken = partitionScanner.nextToken();
- if (partitionToken.isEOF()) {
- if (lastContentType != null) {
- ITokenScanner tokenScanner = tokenScannerProvider.getTokenScanner(lastContentType);
- if (tokenScanner == null)
- addRange(presentation, partitionScanner.getTokenOffset(), partitionScanner.getTokenLength(),
- defaultTextAttribute);
- else
- applyTokenScanner(presentation, partitionScannerTokenLength, partitionScannerTokenOffset, tokenScanner);
- }
- break;
- }
- String contentType = getTokenContentType(partitionToken);
- if (contentType == null)
- contentType = IDocument.DEFAULT_CONTENT_TYPE;
- if (contentType.equals(lastContentType)) {
- partitionScannerTokenLength += partitionScanner.getTokenLength();
- } else {
- if (lastContentType != null) {
- ITokenScanner tokenScanner = tokenScannerProvider.getTokenScanner(lastContentType);
- if (tokenScanner == null)
- addRange(presentation, partitionScanner.getTokenOffset(), partitionScanner.getTokenLength(),
- defaultTextAttribute);
- else
- applyTokenScanner(presentation, partitionScannerTokenLength, partitionScannerTokenOffset, tokenScanner);
- }
- lastContentType = contentType;
- partitionScannerTokenOffset = partitionScanner.getTokenOffset();
- partitionScannerTokenLength = partitionScanner.getTokenLength();
- }
- } while (true);
- }
-
- private void applyTokenScanner(TextPresentation presentation, int partitionScannerTokenLength,
- int partitionScannerTokenOffset, ITokenScanner tokenScanner) {
- int lastStart = partitionScannerTokenOffset;
- int length = 0;
- boolean firstToken = true;
- IToken lastToken = Token.UNDEFINED;
- TextAttribute lastAttribute = getTokenTextAttribute(lastToken);
- tokenScanner.setRange(document, partitionScannerTokenOffset, partitionScannerTokenLength);
- do {
- IToken token = tokenScanner.nextToken();
- if (!token.isEOF()) {
- TextAttribute attribute = getTokenTextAttribute(token);
- if (lastAttribute != null && lastAttribute.equals(attribute)) {
- length += tokenScanner.getTokenLength();
- firstToken = false;
- } else {
- if (!firstToken)
- addRange(presentation, lastStart, length, lastAttribute);
- firstToken = false;
- lastToken = token;
- lastAttribute = attribute;
- lastStart = tokenScanner.getTokenOffset();
- length = tokenScanner.getTokenLength();
- }
- } else {
- addRange(presentation, lastStart, length, lastAttribute);
- return;
- }
- } while (true);
- }
-
- protected String getTokenContentType(IToken token) {
- Object data = token.getData();
- if (data instanceof String)
- return (String) data;
- else
- return null;
- }
-
- protected TextAttribute getTokenTextAttribute(IToken token) {
- Object data = token.getData();
- if (data instanceof TextAttribute)
- return (TextAttribute) data;
- else
- return defaultTextAttribute;
- }
-
- protected void addRange(TextPresentation presentation, int offset, int length, TextAttribute attr) {
- if (attr != null) {
- int style = attr.getStyle();
- int fontStyle = style & 3;
- StyleRange styleRange = new StyleRange(offset, length, attr.getForeground(), attr.getBackground(), fontStyle);
- styleRange.strikeout = (style & 0x20000000) != 0;
- styleRange.underline = (style & 0x40000000) != 0;
- styleRange.font = attr.getFont();
- presentation.addStyleRange(styleRange);
- }
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTElementScannerRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTElementScannerRule.java
deleted file mode 100644
index aa40ef1..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTElementScannerRule.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jet.internal.editor.partition.JETDocumentPartitionScanner;
-import org.eclipse.jface.text.rules.*;
-
-public abstract class ASTElementScannerRule implements IPredicateRule {
- private JETTextEditor editor;
-
- private IToken successToken;
-
- public ASTElementScannerRule(JETTextEditor editor, IToken successToken) {
- this.editor = editor;
- this.successToken = successToken;
- }
-
- public IToken getSuccessToken() {
- return successToken;
- }
-
- public IToken evaluate(ICharacterScanner scanner) {
- return evaluate(scanner, false);
- }
-
- public IToken evaluate(ICharacterScanner scanner, boolean resume) {
- JETDocumentPartitionScanner jetScanner = (JETDocumentPartitionScanner) scanner;
- int offset = jetScanner.getNextCharacterOffset();
- JETASTElement element = editor.getASTElement(offset);
- if (element != null && isAcceptedElement(element)) {
- int length = element.getEnd() - offset;
- for (int i = 0; i < length; i++)
- scanner.read();
-
- return successToken;
- } else {
- return Token.UNDEFINED;
- }
- }
-
- protected abstract boolean isAcceptedElement(JETASTElement jet2astelement);
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCommentRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCommentRule.java
deleted file mode 100644
index 94ac578..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCommentRule.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.Comment;
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETCommentRule extends ASTElementScannerRule {
-
- public ASTJETCommentRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return element instanceof Comment;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCustomTagRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCustomTagRule.java
deleted file mode 100644
index d415f94..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETCustomTagRule.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.XMLBodyElementEnd;
-import org.eclipse.jet.core.parser.ast.XMLElement;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETCustomTagRule extends ASTElementScannerRule {
-
- public ASTJETCustomTagRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return (element instanceof XMLElement) || (element instanceof XMLBodyElementEnd);
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETDirectiveRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETDirectiveRule.java
deleted file mode 100644
index 92fab86..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETDirectiveRule.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETDirective;
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETDirectiveRule extends ASTElementScannerRule {
-
- public ASTJETDirectiveRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return element instanceof JETDirective;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaDeclarationRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaDeclarationRule.java
deleted file mode 100644
index ffa27dc..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaDeclarationRule.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JavaDeclaration;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETJavaDeclarationRule extends ASTElementScannerRule {
-
- public ASTJETJavaDeclarationRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return element instanceof JavaDeclaration;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaExpressionRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaExpressionRule.java
deleted file mode 100644
index 255c929..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaExpressionRule.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JavaExpression;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETJavaExpressionRule extends ASTElementScannerRule {
-
- public ASTJETJavaExpressionRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return element instanceof JavaExpression;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaScriptletRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaScriptletRule.java
deleted file mode 100644
index 36bd08a..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/ASTJETJavaScriptletRule.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jet.core.parser.ast.JETASTElement;
-import org.eclipse.jet.core.parser.ast.JavaScriptlet;
-import org.eclipse.jet.internal.editor.JETTextEditor;
-import org.eclipse.jface.text.rules.IToken;
-
-public class ASTJETJavaScriptletRule extends ASTElementScannerRule {
-
- public ASTJETJavaScriptletRule(JETTextEditor editor, IToken token) {
- super(editor, token);
- }
-
- protected boolean isAcceptedElement(JETASTElement element) {
- return element instanceof JavaScriptlet;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETBracketRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETBracketRule.java
deleted file mode 100644
index 68d18ef..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETBracketRule.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 - 2006 Joel Cheuoua & others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.ICharacterScanner;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.MultiLineRule;
-import org.eclipse.jface.text.rules.Token;
-
-/**
- * @author jcheuoua
- * @version $Revision: 1.2 $
- */
-public class JETBracketRule extends MultiLineRule {
- protected IToken token;
-
- /**
- * Constructor for JETBracketRule.
- *
- * @param token
- * IToken
- */
- public JETBracketRule(IToken token) {
- super("<%", "%>", token);
- this.token = token;
- }
-
- /**
- * Method evaluate.
- *
- * @param scanner
- * ICharacterScanner
- * @return IToken
- * @see org.eclipse.jface.text.rules.IRule#evaluate(ICharacterScanner)
- */
- public IToken evaluate(ICharacterScanner scanner) {
- char c = (char) scanner.read();
- if (c == '%') { // we're reaching the end of the token zone
- c = (char) scanner.read();
- if (c == '>') {
- return token;
- } else {
- scanner.unread();
- scanner.unread();
- return Token.UNDEFINED;
- }
- }
- if (c == '<') { // we're at the beginning of the token zone
- c = (char) scanner.read();
- if (c == '%') {
- c = (char) scanner.read();
- if (c == '!' || c == '@' || c == '=' || c == '-') {
- return token;
- } else {
- scanner.unread();
- return token;
- }
- } else {
- scanner.unread();
- scanner.unread();
- return Token.UNDEFINED;
- }
- } else {
- scanner.unread();
- return Token.UNDEFINED;
- }
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCommentRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCommentRule.java
deleted file mode 100644
index 2f1ee7f..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCommentRule.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.*;
-
-public class JETCommentRule extends MultiLineRule {
-
- public JETCommentRule(IToken token) {
- super("<%--", "--%>", token, '\\');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCustomTagRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCustomTagRule.java
deleted file mode 100644
index fed5476..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETCustomTagRule.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.jet.taglib.TagLibrary;
-import org.eclipse.jet.taglib.TagLibraryManager;
-import org.eclipse.jface.text.rules.*;
-
-public class JETCustomTagRule extends MultiLineRule {
- private Set tagElementNames;
- public JETCustomTagRule(IToken token) {
- super("<", ">", token, '\\');
- String[] tagLibIds = TagLibraryManager.getInstance().getKnownLibraryIds();
- tagElementNames = new HashSet();
- for (int i = 0; i < tagLibIds.length; i++) {
- String id = tagLibIds[i];
- TagLibrary tagLib = TagLibraryManager.getInstance().getTagLibrary(id, true);
- String[] names = tagLib.getTagNames();
- for (int j = 0; j < names.length; j++) {
- String name = names[j];
- tagElementNames.add(tagLib.getDefaultPrefix() + ":" + name);
- }
- }
- }
-
- public IToken evaluate(ICharacterScanner scanner, boolean resume) {
- // TODO Auto-generated method stub
- return super.evaluate(scanner, resume);
- }
-
- protected boolean sequenceDetected(ICharacterScanner scanner, char[] sequence, boolean eofAllowed) {
- int c = scanner.read();
- int readCount = 1;
- if (sequence[0] == '<') {
- // Cut through obvious cases
- if ((char)c == '%') {
- // processing jet instruction - abort
- scanner.unread();
- return false;
- }
- if ((char)c == '?') {
- // processing instruction - abort
- scanner.unread();
- return false;
- }
- if ((char)c == '!') {
- scanner.unread();
- // comment - abort
- return false;
- }
- StringBuffer name = new StringBuffer();
- while ((char)c == ' ') {
- c = scanner.read();
- readCount++;
- }
- if (c == ICharacterScanner.EOF) {
- for (int i = 0; i < readCount; i++) scanner.unread();
- return false;
- }
- while ((char)c != ' ' && c != ICharacterScanner.EOF && (char)c != '>') {
- name.append((char)c);
- c = scanner.read();
- readCount++;
- }
- if (tagElementNames.contains(name.toString())) {
- scanner.unread();
- return true;
- } else {
- for (int i = 0; i < readCount; i++) scanner.unread();
- return false;
- }
- } else if (sequence[0] == '>') {
- scanner.unread();
- }
- return super.sequenceDetected(scanner, sequence, eofAllowed);
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETDirectiveRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETDirectiveRule.java
deleted file mode 100644
index 2745f87..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETDirectiveRule.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.*;
-
-public class JETDirectiveRule extends MultiLineRule {
-
- public JETDirectiveRule(IToken token) {
- super("<%@", "%>", token, '\\');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaDeclarationRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaDeclarationRule.java
deleted file mode 100644
index 79595da..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaDeclarationRule.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.*;
-
-public class JETJavaDeclarationRule extends MultiLineRule {
-
- public JETJavaDeclarationRule(IToken token) {
- super("<%!", "%>", token, '\\');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaExpressionRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaExpressionRule.java
deleted file mode 100644
index 47c9d9d..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaExpressionRule.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.*;
-
-public class JETJavaExpressionRule extends MultiLineRule {
-
- public JETJavaExpressionRule(IToken token) {
- super("<%=", "%>", token, '\\');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaScriptletRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaScriptletRule.java
deleted file mode 100644
index e10ecb8..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/JETJavaScriptletRule.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import org.eclipse.jface.text.rules.*;
-
-public class JETJavaScriptletRule extends MultiLineRule {
-
- public JETJavaScriptletRule(IToken token) {
- super("<%", "%>", token, '\\');
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/WordListDetectorRule.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/WordListDetectorRule.java
deleted file mode 100644
index ef740f8..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/rules/WordListDetectorRule.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.rules;
-
-import java.util.Collection;
-
-import org.eclipse.jface.text.rules.ICharacterScanner;
-import org.eclipse.jface.text.rules.IRule;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.Token;
-
-public class WordListDetectorRule implements IRule {
- private IToken success;
- private String[] words;
- public WordListDetectorRule(IToken token, String[] words) {
- this.success = token;
- this.words = words;
- }
- public WordListDetectorRule(IToken token, Collection words) {
- this.success = token;
- this.words = new String[words.size()];
- this.words = (String[]) words.toArray(this.words);
- }
- public IToken evaluate(ICharacterScanner scanner) {
- char c = (char) scanner.read();
- char initialChar = c;
- for (int i = 0; i < words.length; i++) {
- String keyword = words[i];
- int index = 0;
- while (keyword.length() > index && c == keyword.charAt(index)) {
- c = (char) scanner.read();
- index++;
- }
- if (index == keyword.length()) {// success for this keyword ... we'read until the end
- scanner.unread(); // there is one read in excess at the end
- return success;
- }
- // otherwise, unread and proceed to the next word
- for (int j = 0; j < index; j++) {
- scanner.unread();
- }
- c = initialChar;
- }
- scanner.unread();
- return Token.UNDEFINED;
- }
-} \ No newline at end of file
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCommentScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCommentScanner.java
deleted file mode 100644
index 72ca195..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCommentScanner.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
-
-public class JETCommentScanner extends RuleBasedScanner {
-
- public JETCommentScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- setDefaultReturnToken(manager.requestToken("__jet_comment",
- JETEditorPreferenceConstants.JET_COMMENT_FG_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- JETEditorPreferenceConstants.JET_COMMENT_BOLD,
- JETEditorPreferenceConstants.JET_COMMENT_ITALIC,
- null,
- null));
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCustomTagScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCustomTagScanner.java
deleted file mode 100644
index 1db0a3b..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETCustomTagScanner.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.rules.WordListDetectorRule;
-import org.eclipse.jet.taglib.TagLibrary;
-import org.eclipse.jet.taglib.TagLibraryManager;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.IRule;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
-import org.eclipse.jface.text.rules.SingleLineRule;
-
-public class JETCustomTagScanner extends RuleBasedScanner {
-
- public JETCustomTagScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- IToken tagElementName = manager.requestToken("__jet_custom_tag_elementName",
- JETEditorPreferenceConstants.JET_CUSTOM_TAG_FG_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- JETEditorPreferenceConstants.JET_CUSTOM_TAG_BOLD,
- JETEditorPreferenceConstants.JET_CUSTOM_TAG_ITALIC,
- null,
- JETEditorPreferenceConstants.JET_CUSTOM_TAG_UNDERLINE);
-
- IToken string = manager.requestToken("__jet_custom_tag_string",
- PreferenceConstants.EDITOR_STRING_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- PreferenceConstants.EDITOR_STRING_BOLD,
- PreferenceConstants.EDITOR_STRING_ITALIC,
- null,
- PreferenceConstants.EDITOR_STRING_UNDERLINE);
-
- Collection tagNames = new ArrayList();
- String[] tagLibIds = TagLibraryManager.getInstance().getKnownLibraryIds();
- for (int i = 0; i < tagLibIds.length; i++) {
- String id = tagLibIds[i];
- TagLibrary tagLib = TagLibraryManager.getInstance().getTagLibrary(id, true);
- String[] names = tagLib.getTagNames();
- for (int j = 0; j < names.length; j++) {
- String name = names[j];
- tagNames.add(tagLib.getDefaultPrefix() + ":" + name);
- }
- }
-
- IRule[] rules = new IRule[3];
-
- // Add rule for double quotes
- rules[0] = new SingleLineRule("\"", "\"", string, '\\');
- // Add a rule for single quotes
- rules[1] = new SingleLineRule("'", "'", string, '\\');
- // Add a rule for the custom tag identifier
- rules[2] = new WordListDetectorRule(tagElementName, tagNames);
-
- setRules(rules);
-
- IToken defaultReturnToken = manager.requestToken("__jet_custom_tag",
- JETEditorPreferenceConstants.JET_CUSTOM_TAG_FG_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- null,
- null,
- null,
- null);
- setDefaultReturnToken(defaultReturnToken);
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDefaultContentScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDefaultContentScanner.java
deleted file mode 100644
index c79d6cd..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDefaultContentScanner.java
+++ /dev/null
@@ -1,22 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
-
-public class JETDefaultContentScanner extends RuleBasedScanner {
-
- public JETDefaultContentScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- setDefaultReturnToken(manager.requestDefaultToken());
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDirectiveScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDirectiveScanner.java
deleted file mode 100644
index 996b0cd..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETDirectiveScanner.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.rules.JETBracketRule;
-import org.eclipse.jet.internal.editor.rules.WordListDetectorRule;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.IRule;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
-import org.eclipse.jface.text.rules.SingleLineRule;
-
-public class JETDirectiveScanner extends RuleBasedScanner {
-
- public JETDirectiveScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- IToken keyword = manager.requestToken("__jet_directive_keyword",
- JETEditorPreferenceConstants.JET_DIRECTIVE_FG_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- JETEditorPreferenceConstants.JET_DIRECTIVE_KEYWORD_BOLD,
- JETEditorPreferenceConstants.JET_DIRECTIVE_ITALIC,
- null,
- JETEditorPreferenceConstants.JET_DIRECTIVE_UNDERLINE);
- IToken string = manager.requestToken("__jet_directive_string",
- PreferenceConstants.EDITOR_STRING_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- PreferenceConstants.EDITOR_STRING_BOLD,
- PreferenceConstants.EDITOR_STRING_ITALIC,
- null,
- PreferenceConstants.EDITOR_STRING_UNDERLINE);
- IToken bracket = manager.requestToken("__jet_bracket",
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC,
- null,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_UNDERLINE);
-
- IRule[] rules = new IRule[4];
-
- // Add rule for brackets
- rules[0] = new JETBracketRule(bracket);
- // Add rule for double quotes
- rules[1] = new SingleLineRule("\"", "\"", string, '\\');
- // Add a rule for single quotes
- rules[2] = new SingleLineRule("'", "'", string, '\\');
- // Add word rule for reserved jet directive words
- rules[3] = new WordListDetectorRule(keyword, new String[] {"jet", "taglib", "include", "start", "end"});
-
- setRules(rules);
-
- IToken defaultReturnToken = manager.requestToken("__jet_directive",
- JETEditorPreferenceConstants.JET_DIRECTIVE_FG_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- JETEditorPreferenceConstants.JET_DIRECTIVE_BOLD,
- JETEditorPreferenceConstants.JET_DIRECTIVE_ITALIC,
- null,
- JETEditorPreferenceConstants.JET_DIRECTIVE_UNDERLINE);
- setDefaultReturnToken(defaultReturnToken);
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaCodeScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaCodeScanner.java
deleted file mode 100644
index b424cdd..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaCodeScanner.java
+++ /dev/null
@@ -1,251 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jface.text.rules.BufferedRuleBasedScanner;
-import org.eclipse.jface.text.rules.ICharacterScanner;
-import org.eclipse.jface.text.rules.IRule;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.IWordDetector;
-import org.eclipse.jface.text.rules.MultiLineRule;
-import org.eclipse.jface.text.rules.SingleLineRule;
-import org.eclipse.jface.text.rules.Token;
-import org.eclipse.jface.text.rules.WordRule;
-
-
-/**
- * A Java code scanner for JET-java sections.
- */
-public class JETJavaCodeScanner extends BufferedRuleBasedScanner {
-
- /**
- * Rule to detect java operators.
- */
- private class OperatorRule implements IRule {
- private char[] JAVA_OPERATORS= { ';', '.', '=', '/', '\\', '+', '-', '*', '<', '>', ':', '?', '!', ',', '|', '&', '^', '%', '~'};
- private IToken fToken;
-
- public OperatorRule(IToken token) {
- fToken= token;
- }
-
- public boolean isOperator(char character) {
- for (int index= 0; index < JAVA_OPERATORS.length; index++) {
- if (JAVA_OPERATORS[index] == character)
- return true;
- }
- return false;
- }
-
- /*
- * @see org.eclipse.jface.text.rules.IRule#evaluate(org.eclipse.jface.text.rules.ICharacterScanner)
- */
- public IToken evaluate(ICharacterScanner scanner) {
- int character= scanner.read();
- if (isOperator((char) character)) {
- do {
- character= scanner.read();
- } while (isOperator((char) character));
- scanner.unread();
- return fToken;
- } else {
- scanner.unread();
- return Token.UNDEFINED;
- }
- }
- }
-
- /**
- * Rule to detect java brackets.
- */
- private class BracketRule implements IRule {
-
- private char[] JAVA_BRACKETS= { '(', ')', '{', '}', '[', ']' };
- private final IToken success;
-
- public BracketRule(IToken token) {
- success= token;
- }
-
- public boolean isBracket(char character) {
- for (int index= 0; index < JAVA_BRACKETS.length; index++) {
- if (JAVA_BRACKETS[index] == character)
- return true;
- }
- return false;
- }
-
- /*
- * @see org.eclipse.jface.text.rules.IRule#evaluate(org.eclipse.jface.text.rules.ICharacterScanner)
- */
- public IToken evaluate(ICharacterScanner scanner) {
- int character= scanner.read();
- if (isBracket((char) character)) {
- do {
- character= scanner.read();
- } while (isBracket((char) character));
- scanner.unread();
- return success;
- } else {
- scanner.unread();
- return Token.UNDEFINED;
- }
- }
- }
-
- private class JavaWordDetector implements IWordDetector {
- /*
- * @see IWordDetector#isWordStart
- */
- public boolean isWordStart(char c) {
- return Character.isJavaIdentifierStart(c);
- }
-
- /*
- * @see IWordDetector#isWordPart
- */
- public boolean isWordPart(char c) {
- return Character.isJavaIdentifierPart(c);
- }
- }
-
- private String[] javaKeywords= {
- "abstract", //$NON-NLS-1$
- "break", //$NON-NLS-1$
- "case", "catch", "class", "const", "continue", //$NON-NLS-5$ //$NON-NLS-4$ //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "default", "do", //$NON-NLS-2$ //$NON-NLS-1$
- "else", "extends", //$NON-NLS-2$ //$NON-NLS-1$
- "final", "finally", "for", //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "goto", //$NON-NLS-1$
- "if", "implements", "import", "instanceof", "interface", //$NON-NLS-5$ //$NON-NLS-4$ //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "native", "new", //$NON-NLS-2$ //$NON-NLS-1$
- "package", "private", "protected", "public", //$NON-NLS-4$ //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "static", "super", "switch", "synchronized", //$NON-NLS-4$ //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "this", "throw", "throws", "transient", "try", //$NON-NLS-5$ //$NON-NLS-4$ //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
- "volatile", //$NON-NLS-1$
- "while", //$NON-NLS-1$
- "assert", //$NON-NLS-1$
- "enum", //$NON-NLS-1$
- "return" //$NON-NLS-1$
- };
-
- private String[] javaTypes= { "class", "interface", "void", "boolean", "char", "byte", "short", "strictfp", "int", "long", "float", "double" }; //$NON-NLS-1$ //$NON-NLS-5$ //$NON-NLS-7$ //$NON-NLS-6$ //$NON-NLS-8$ //$NON-NLS-9$ //$NON-NLS-10$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-2$
-
- private String[] javaConstants= { "false", "null", "true" }; //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$
-
- private String defaultBg;
- /**
- * Creates a Java code scanner
- *
- * @param manager the color manager
- * @param store the preference store
- */
- public JETJavaCodeScanner(JETTokenStyleManager manager, String defaultBg) {
- this.defaultBg = defaultBg;
- List rules = createRules(manager);
- IRule[] result= new IRule[rules.size()];
- rules.toArray(result);
- setRules(result);
- }
-
-
- protected List createRules(JETTokenStyleManager manager) {
- List rules= new ArrayList();
-
- // Add rule for character constants.
- IToken token= manager.requestToken("__jet_java_string_" + defaultBg,
- PreferenceConstants.EDITOR_STRING_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_STRING_BOLD,
- PreferenceConstants.EDITOR_STRING_ITALIC,
- PreferenceConstants.EDITOR_STRING_STRIKETHROUGH,
- PreferenceConstants.EDITOR_STRING_UNDERLINE);
- rules.add(new SingleLineRule("'", "'", token, '\\')); //$NON-NLS-2$ //$NON-NLS-1$
-
-
- // Add generic whitespace rule.
- //rules.add(new WhitespaceRule(new JETWhitespaceDetector()));
-
- // Add rule for multiline comments
- token= manager.requestToken("__jet_java_multi_line_comment_" + defaultBg,
- PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_BOLD,
- PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_ITALIC,
- PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_STRIKETHROUGH,
- PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_UNDERLINE);
- MultiLineRule multiLineCommentsRule = new MultiLineRule("/*", "*/", token, '\\');
- rules.add(multiLineCommentsRule);
-
- // Add rule for single line comments
- token= manager.requestToken("__jet_java_single_line_comment_" + defaultBg,
- PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_BOLD,
- PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_ITALIC,
- PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_STRIKETHROUGH,
- PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_UNDERLINE);
- SingleLineRule singleLineCommentsRule = new SingleLineRule("//", null, token);
- rules.add(singleLineCommentsRule);
-
- // Add word rule for keywords,types and constants
- JavaWordDetector wordDetector= new JavaWordDetector();
- token= manager.requestToken("__jet_java_default_" + defaultBg,
- PreferenceConstants.EDITOR_JAVA_DEFAULT_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_JAVA_DEFAULT_BOLD,
- PreferenceConstants.EDITOR_JAVA_DEFAULT_ITALIC,
- PreferenceConstants.EDITOR_JAVA_DEFAULT_STRIKETHROUGH,
- PreferenceConstants.EDITOR_JAVA_DEFAULT_UNDERLINE);
- WordRule wordRule= new WordRule(wordDetector, token);
-
- token = manager.requestToken("__jet_java_keyword_" + defaultBg,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_STRIKETHROUGH,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_UNDERLINE);
- for (int i=0; i<javaKeywords.length; i++)
- wordRule.addWord(javaKeywords[i], token);
- for (int i=0; i<javaTypes.length; i++)
- wordRule.addWord(javaTypes[i], token);
- for (int i=0; i<javaConstants.length; i++)
- wordRule.addWord(javaConstants[i], token);
- rules.add(wordRule);
-
- // Add rule for operators
- token = manager.requestToken("__jet_java_operator_" + defaultBg,
- PreferenceConstants.EDITOR_JAVA_OPERATOR_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_JAVA_OPERATOR_BOLD,
- PreferenceConstants.EDITOR_JAVA_OPERATOR_ITALIC,
- PreferenceConstants.EDITOR_JAVA_OPERATOR_STRIKETHROUGH,
- PreferenceConstants.EDITOR_JAVA_OPERATOR_UNDERLINE);;
- rules.add(new OperatorRule(token));
-
- // Add rule for brackets
- token = manager.requestToken("__jet_java_bracket_" + defaultBg,
- PreferenceConstants.EDITOR_JAVA_BRACKET_COLOR,
- defaultBg,
- PreferenceConstants.EDITOR_JAVA_BRACKET_BOLD,
- PreferenceConstants.EDITOR_JAVA_BRACKET_ITALIC,
- PreferenceConstants.EDITOR_JAVA_BRACKET_STRIKETHROUGH,
- PreferenceConstants.EDITOR_JAVA_BRACKET_UNDERLINE);;
- rules.add(new BracketRule(token));
- return rules;
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaDeclarationScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaDeclarationScanner.java
deleted file mode 100644
index af23128..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaDeclarationScanner.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.rules.JETBracketRule;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.IToken;
-
-public class JETJavaDeclarationScanner extends JETJavaCodeScanner {
- public JETJavaDeclarationScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- super(manager, JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR);
- setDefaultReturnToken(manager.requestDefaultToken());
- }
-
- protected List createRules(JETTokenStyleManager manager) {
- List rules = new ArrayList();
- List parentRules = super.createRules(manager);
- IToken bracket = manager.requestToken("__jet_bracket",
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC,
- null,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_UNDERLINE);
- // Add rule for brackets
- rules.add(new JETBracketRule(bracket));
- rules.addAll(parentRules);
- return rules;
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaExpressionScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaExpressionScanner.java
deleted file mode 100644
index d9b0369..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaExpressionScanner.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.rules.JETBracketRule;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.IToken;
-
-public class JETJavaExpressionScanner extends JETJavaCodeScanner {
-
- public JETJavaExpressionScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- super(manager, JETEditorPreferenceConstants.JET_EXPRESSION_BG_COLOR);
- setDefaultReturnToken(manager.requestToken("__jet_expression_default",
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- JETEditorPreferenceConstants.JET_EXPRESSION_BG_COLOR,
- null,
- null,
- null,
- null));
- }
-
- protected List createRules(JETTokenStyleManager manager) {
- List rules = new ArrayList();
- List parentRules = super.createRules(manager);
- IToken bracket = manager.requestToken("__jet_expression_bracket",
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- JETEditorPreferenceConstants.JET_EXPRESSION_BG_COLOR,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC,
- null,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_UNDERLINE);
- // Add rule for brackets
- rules.add(new JETBracketRule(bracket));
- rules.addAll(parentRules);
- return rules;
- }
-}
diff --git a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaScriptletScanner.java b/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaScriptletScanner.java
deleted file mode 100644
index 7f711f2..0000000
--- a/plugins/org.eclipse.jet.editor/src/org/eclipse/jet/internal/editor/scanners/JETJavaScriptletScanner.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2007 ILOG and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Joel Cheuoua - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.editor.scanners;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jdt.ui.PreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETEditorPreferenceConstants;
-import org.eclipse.jet.internal.editor.configuration.JETTokenStyleManager;
-import org.eclipse.jet.internal.editor.rules.JETBracketRule;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.rules.IToken;
-
-public class JETJavaScriptletScanner extends JETJavaCodeScanner {
-
- public JETJavaScriptletScanner(JETTokenStyleManager manager, IPreferenceStore preferenceStore) {
- super(manager, JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR);
- setDefaultReturnToken(manager.requestDefaultToken());
- }
-
- protected List createRules(JETTokenStyleManager manager) {
- List rules = new ArrayList();
- List parentRules = super.createRules(manager);
- IToken bracket = manager.requestToken("__jet_bracket",
- PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR,
- JETEditorPreferenceConstants.JET_DEFAULT_BG_COLOR,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC,
- null,
- PreferenceConstants.EDITOR_JAVA_KEYWORD_UNDERLINE);
- // Add rule for brackets
- rules.add(new JETBracketRule(bracket));
- rules.addAll(parentRules);
- return rules;
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/.classpath b/plugins/org.eclipse.jet.ui/.classpath
deleted file mode 100644
index ce73933..0000000
--- a/plugins/org.eclipse.jet.ui/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.4"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/plugins/org.eclipse.jet.ui/.cvsignore b/plugins/org.eclipse.jet.ui/.cvsignore
deleted file mode 100644
index 21c69d5..0000000
--- a/plugins/org.eclipse.jet.ui/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-bin
-org
-dump.xml
diff --git a/plugins/org.eclipse.jet.ui/.project b/plugins/org.eclipse.jet.ui/.project
deleted file mode 100644
index 337c3aa..0000000
--- a/plugins/org.eclipse.jet.ui/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jet.ui</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <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>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/plugins/org.eclipse.jet.ui/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.jet.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index 0d55ce5..0000000
--- a/plugins/org.eclipse.jet.ui/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Thu Feb 23 13:40:34 EST 2006
-eclipse.preferences.version=1
-encoding//src/org/eclipse/jet/internal/ui/l10n/messages.properties=8859_1
diff --git a/plugins/org.eclipse.jet.ui/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.jet.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index a641476..0000000
--- a/plugins/org.eclipse.jet.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,70 +0,0 @@
-#Sun Apr 20 15:46:33 EDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.2
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.4
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=warning
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.deprecation=warning
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=warning
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=error
-org.eclipse.jdt.core.compiler.problem.nullReference=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=warning
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.3
diff --git a/plugins/org.eclipse.jet.ui/META-INF/MANIFEST.MF b/plugins/org.eclipse.jet.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index 663d1b7..0000000
--- a/plugins/org.eclipse.jet.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,27 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jet.ui;singleton:=true
-Bundle-Version: 0.9.0.qualifier
-Bundle-Activator: org.eclipse.jet.ui.Activator
-Bundle-Vendor: %providerName
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.core.resources;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jet;bundle-version="[0.7.0,1.0.0)",
- org.eclipse.debug.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.debug.core;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.ide;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.core;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.launching;bundle-version="[3.2.0,4.0.0)"
-Eclipse-LazyStart: true
-Export-Package: org.eclipse.jet.internal.ui.filters;x-internal:=true,
- org.eclipse.jet.internal.ui.l10n;x-internal:=true,
- org.eclipse.jet.internal.ui.launch;x-internal:=true,
- org.eclipse.jet.internal.ui.popup.actions;x-internal:=true,
- org.eclipse.jet.internal.ui.prefs;x-internal:=true,
- org.eclipse.jet.ui,
- org.eclipse.jet.ui.newproject
-Bundle-RequiredExecutionEnvironment: J2SE-1.4
-Bundle-ActivationPolicy: lazy
diff --git a/plugins/org.eclipse.jet.ui/NewJETProject.p1.wzPage.xml b/plugins/org.eclipse.jet.ui/NewJETProject.p1.wzPage.xml
deleted file mode 100644
index 00ba758..0000000
--- a/plugins/org.eclipse.jet.ui/NewJETProject.p1.wzPage.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../ui.maker/schema.xsd">
- <wizardPage qualifiedName="org.eclipse.jet.ui.newproject.NewJETProjectPage1" helpContextId="org.eclipse.jet.ui.trjt0010">
- <baseClass qualifiedName="org.eclipse.ui.dialogs.WizardNewProjectCreationPage"/>
- <control parentID="TOP" id="gProjSet">
- <type><group text="Project Settings" shadow="NONE"><gridLayout numColumns="2"/></group></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <control parentID="gProjSet" id="lblTemplateFolder">
- <type><label text="&amp;Template folder:"/></type>
- </control>
- <control parentID="gProjSet" id="txtTemplateFolder">
- <var name="txtTemplateFolder"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <control parentID="gProjSet" id="lblJETOutput">
- <type><label text="J&amp;ET output folder:"/></type>
- </control>
- <control parentID="gProjSet" id="txtJETOutput">
- <var name="txtJETOutput"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <control parentID="gProjSet" id="lblJavaOutput">
- <type><label text="J&amp;ava output folder:"/></type>
- </control>
- <control parentID="gProjSet" id="txtJavaOutput">
- <var name="txtJavaOutput"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <control parentID="gProjSet" id="lblDefJavaPackage">
- <type><label text="Default &amp;Java package:"/></type>
- </control>
- <control parentID="gProjSet" id="txtDefJavaPackage">
- <var name="txtDefJavaPackage"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- </wizardPage>
-</root>
diff --git a/plugins/org.eclipse.jet.ui/NewJETProject.p2.wzPage.xml b/plugins/org.eclipse.jet.ui/NewJETProject.p2.wzPage.xml
deleted file mode 100644
index 08aa1d2..0000000
--- a/plugins/org.eclipse.jet.ui/NewJETProject.p2.wzPage.xml
+++ /dev/null
@@ -1,72 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../ui.maker/schema.xsd">
- <wizardPage qualifiedName="org.eclipse.jet.ui.newproject.NewJETProjectPage2" helpContextId="org.eclipse.jet.ui.trjt0020">
- <control parentID="TOP" id="top">
- <type><composite><gridLayout numColumns="1"/></composite></type>
- <gridData><hAlign value="FILL"/><vAlign value="FILL"/><hGrabExcessSpace/><vGrabExcessSpace/></gridData>
- </control>
- <control parentID="top" id="grpTransProps">
- <type><group text="Transformation (plug-in) Properties" shadow="NONE"><gridLayout numColumns="2"/></group></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <!-- Transformation ID: -->
- <control parentID="grpTransProps" id="lblID">
- <type><label text="Transformation &amp;ID:"/></type>
- </control>
- <control parentID="grpTransProps" id="txtID">
- <var name="txtID"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
-
- <!-- Transformation Name: -->
- <control parentID="grpTransProps" id="lblName">
- <type><label text="Transformation na&amp;me:"/></type>
- </control>
- <control parentID="grpTransProps" id="txtName">
- <var name="txtName"/>
- <type><text multi="false" readOnly="false"></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <!-- Description -->
- <control parentID="grpTransProps" id="lblDescription">
- <type><label text="Transformation &amp;description:"/></type>
- </control>
- <control parentID="grpTransProps" id="txtDescription">
- <var name="txtDescription"/>
- <type><text multi="false" readOnly="false"></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <!-- Template Loader -->
- <control parentID="grpTransProps" id="lblTemplateLoader">
- <type><label text="Template &amp;loader:"/></type>
- </control>
- <control parentID="grpTransProps" id="txtTemplateLoader">
- <var name="txtTemplateLoader"/>
- <type><text multi="false" readOnly="false"><modify/></text></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
-
- <!-- Extensions -->
- <control parentID="top" id="grpExtensions">
- <var name="grpExtensions"/>
- <type><group text="Extensions" shadow="NONE"><gridLayout numColumns="2"/></group></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- <control parentID="grpExtensions" id="cbxExtends">
- <var name="cbxExtends"/>
- <type><checkButton text="E&amp;xtend an existing JET Transformation"><selection/></checkButton></type>
- <gridData><hSpan columns="2"/></gridData>
- </control>
- <control parentID="grpExtensions" id="lblBaseTx">
- <var name="lblBaseTx"/>
- <type><label text="Base &amp;transformation:"/></type>
- <gridData><hIndent chars="4"/></gridData>
- </control>
- <control parentID="grpExtensions" id="ddlBaseTx">
- <var name="ddlBaseTx"/>
- <type><combo dropDown="true" readOnly="true"><modify/></combo></type>
- <gridData><hAlign value="FILL"/><hGrabExcessSpace/></gridData>
- </control>
- </wizardPage>
-</root>
diff --git a/plugins/org.eclipse.jet.ui/about.html b/plugins/org.eclipse.jet.ui/about.html
deleted file mode 100644
index d4f39ad..0000000
--- a/plugins/org.eclipse.jet.ui/about.html
+++ /dev/null
@@ -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">
- <h3>About This Content</h3>
-
- <p>June 5, 2007</p>
- <h3>License</h3>
-
- <p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).
- Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
- Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
- at <a href="http://www.eclipse.org/org/documents/epl-v10.php">http://www.eclipse.org/legal/epl-v10.html</a>.
- For purposes of the EPL, &quot;Program&quot; 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 (&quot;Redistributor&quot;) 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>
- <p align="right"><small><a href="#top">go to top</a></small></p>
-
-</body>
-</html>
diff --git a/plugins/org.eclipse.jet.ui/build.properties b/plugins/org.eclipse.jet.ui/build.properties
deleted file mode 100644
index dfccf68..0000000
--- a/plugins/org.eclipse.jet.ui/build.properties
+++ /dev/null
@@ -1,19 +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 v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- icons/,\
- plugin.properties,\
- about.html
-src.includes = about.html
diff --git a/plugins/org.eclipse.jet.ui/icons/JET2File.gif b/plugins/org.eclipse.jet.ui/icons/JET2File.gif
deleted file mode 100644
index 8f74869..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JET2File.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/JET2LaunchIcon.gif b/plugins/org.eclipse.jet.ui/icons/JET2LaunchIcon.gif
deleted file mode 100644
index 1eab989..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JET2LaunchIcon.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/JET2Project.gif b/plugins/org.eclipse.jet.ui/icons/JET2Project.gif
deleted file mode 100644
index 1685dfa..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JET2Project.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizard.gif b/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizard.gif
deleted file mode 100644
index 8d97ee5..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizard.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizardBanner.gif b/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizardBanner.gif
deleted file mode 100644
index 945a6f5..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JET2ProjectWizardBanner.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/JETRuntimeError.gif b/plugins/org.eclipse.jet.ui/icons/JETRuntimeError.gif
deleted file mode 100644
index 66bc6e5..0000000
--- a/plugins/org.eclipse.jet.ui/icons/JETRuntimeError.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/icons/sample.gif b/plugins/org.eclipse.jet.ui/icons/sample.gif
deleted file mode 100644
index 34fb3c9..0000000
--- a/plugins/org.eclipse.jet.ui/icons/sample.gif
+++ /dev/null
Binary files differ
diff --git a/plugins/org.eclipse.jet.ui/plugin.properties b/plugins/org.eclipse.jet.ui/plugin.properties
deleted file mode 100644
index 35ee6fc..0000000
--- a/plugins/org.eclipse.jet.ui/plugin.properties
+++ /dev/null
@@ -1,40 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-pluginName = JET Transformations UI Plug-in (Incubation)
-providerName = Eclipse.org
-
-newWizards.jet2Project.name = JET Transformation Project
-newWizards.jet2Project.description = Create a JET Transformation Project
-
-editors.jet2.name = JET Editor
-
-editorTemplates.name = JET Template
-
-preferencePages.jet2.name = JET Preferences
-preferencePages.templates.name = Templates
-
-javaElementFilters.javaInJET2Projects.name = Java elements from JET Transformation projects
-javaElementFilters.javaInJET2Projects.description = Hide Java elements such as Java source folders and reference libraries from JET Transformation projects
-
-popupMenus.group.jet2Debug = JET Debug
-popupMenus.action.unload = Unload
-
-launchShortcut.label = JET Transformation
-launchShortcut.contextLabel = Input for JET Transformation
-
-prefPage.jet.title = JET Transformations
-prefpage.jet.compilerOptions.title = Compiler Options
-
-propPage.jet.title = JET Compiler
-
-jet.wizards.category.name = JET Transformations
-
-runtime.error.label = JET Runtime Error
diff --git a/plugins/org.eclipse.jet.ui/plugin.xml b/plugins/org.eclipse.jet.ui/plugin.xml
deleted file mode 100644
index 529d4eb..0000000
--- a/plugins/org.eclipse.jet.ui/plugin.xml
+++ /dev/null
@@ -1,137 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin>
- <extension
- point="org.eclipse.debug.ui.launchConfigurationTabGroups">
- <launchConfigurationTabGroup
- class="org.eclipse.jet.internal.ui.launch.JET2TransformationTabGroup"
- id="org.eclipse.jet.ui.launch.jet2Transformation.tabgroup"
- type="org.eclipse.jet.jet2Transformation"/>
- </extension>
- <extension
- point="org.eclipse.debug.ui.launchConfigurationTypeImages">
- <launchConfigurationTypeImage
- configTypeID="org.eclipse.jet.jet2Transformation"
- icon="icons/JET2LaunchIcon.gif"
- id="org.eclipse.jet.ui.launch.jet2Transformation.icon"/>
- </extension>
- <extension
- point="org.eclipse.debug.ui.launchShortcuts">
- <shortcut
- class="org.eclipse.jet.internal.ui.launch.LaunchShortcut"
- icon="icons/JET2LaunchIcon.gif"
- id="org.eclipse.jet.ui.shortcut1"
- label="%launchShortcut.label"
- modes="run">
- <contextualLaunch>
- <contextLabel
- label="%launchShortcut.contextLabel"
- mode="run"/>
- <enablement>
- <with variable="selection">
- <count value="1"/>
- <iterate operator="or">
- <test
- property="org.eclipse.debug.ui.matchesPattern"
- value="*.xml"/>
- </iterate>
- </with>
- </enablement>
- </contextualLaunch>
- <perspective id="org.eclipse.jdt.ui.JavaPerspective"/>
- <perspective id="org.eclipse.ui.resourcePerspective"/>
- </shortcut>
- </extension>
- <extension
- point="org.eclipse.jdt.ui.javaElementFilters">
- <filter
- class="org.eclipse.jet.internal.ui.filters.JavaFilter"
- description="%javaElementFilters.javaInJET2Projects.description"
- enabled="true"
- id="org.eclipse.jet.javafilter"
- name="%javaElementFilters.javaInJET2Projects.name"
- targetId="org.eclipse.jdt.ui.PackageExplorer"/>
- </extension>
- <extension
- point="org.eclipse.ui.newWizards">
- <wizard
- category="org.eclipse.jet.wizards"
- class="org.eclipse.jet.ui.newproject.NewProjectWizard"
- hasPages="true"
- icon="icons/JET2ProjectWizard.gif"
- id="org.eclipse.jet.ui.newJet2ProjectWizard"
- name="%newWizards.jet2Project.name"
- project="true">
- <description>%newWizards.jet2Project.description</description>
- </wizard>
- <category
- id="org.eclipse.jet.wizards"
- name="%jet.wizards.category.name"/>
- </extension>
-
- <extension
- point="org.eclipse.ui.editors.annotationTypes">
- <type
- markerSeverity="2"
- markerType="org.eclipse.jet.runtimeProblem"
- name="org.eclipse.jet.runtime.error"
- super="org.eclipse.ui.workbench.texteditor.error"/>
- </extension>
- <extension
- point="org.eclipse.ui.editors.markerAnnotationSpecification">
- <specification
- annotationType="org.eclipse.jet.runtime.error"
- colorPreferenceKey="jetErrorColor"
- colorPreferenceValue="255,0,0"
- icon="icons/JETRuntimeError.gif"
- includeOnPreferencePage="true"
- isGoToNextNavigationTarget="false"
- isGoToNextNavigationTargetKey="jetErrorIsGoToNextNavigationTarget"
- isGoToPreviousNavigationTarget="false"
- isGoToPreviousNavigationTargetKey="jetErrorIsGoToPrevNavigationTarget"
- label="%runtime.error.label"
- overviewRulerPreferenceKey="jetErrorOverviewRuler"
- overviewRulerPreferenceValue="true"
- showInNextPrevDropdownToolbarAction="true"
- showInNextPrevDropdownToolbarActionKey="jetErrorShowInNextPrevDowndownToolbarAction"
- textPreferenceKey="jetErrorText"
- textPreferenceValue="true"
- textStylePreferenceKey="jetErrorTextStyle"
- textStylePreferenceValue="SQUIGGLES"
- verticalRulerPreferenceKey="jetErrorVerticalRuler"
- verticalRulerPreferenceValue="true"/>
- </extension>
- <extension
- point="org.eclipse.ui.preferencePages">
- <page
- category="org.eclipse.jet.ui.jet"
- class="org.eclipse.jet.internal.ui.prefs.CompilePreferencePage"
- id="org.eclipse.jet.ui.compiler"
- name="%prefpage.jet.compilerOptions.title"/>
- <page
- class="org.eclipse.jet.internal.ui.prefs.JETPreferencePage"
- id="org.eclipse.jet.ui.jet"
- name="%prefPage.jet.title"/>
- </extension>
- <extension
- point="org.eclipse.ui.propertyPages">
- <page
- adaptable="true"
- class="org.eclipse.jet.internal.ui.prefs.CompilePreferencePage"
- id="org.eclipse.jet.ui.project.jet"
- name="%propPage.jet.title"
- objectClass="org.eclipse.core.resources.IProject">
- <filter
- name="nature"
- value="org.eclipse.jet.jet2Nature"/>
- </page>
- </extension>
- <extension
- point="org.eclipse.debug.ui.consoleColorProviders">
- <consoleColorProvider
- class="org.eclipse.jet.internal.ui.launch.JETConsoleColorProvider"
- id="org.eclipse.jet.ui.consoleColorProvider"
- processType="org.eclipse.jet.process"/>
- </extension>
-
-</plugin>
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/filters/JavaFilter.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/filters/JavaFilter.java
deleted file mode 100644
index 160acc0..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/filters/JavaFilter.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.internal.ui.filters;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-
-/**
- * Filter Java elements from the Package Explorer view for JET2 projects.
- *
- */
-public class JavaFilter extends ViewerFilter {
-
- /**
- *
- */
- public JavaFilter() {
- super();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ViewerFilter#select(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- */
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- final boolean isJET2Project = isJET2Project(parentElement);
- // Note: ClassPathContainer is a JDT internal class - it doesn't implement
- // any useful public interfacts (IAdapter and IWorkspaceAdapter only). To
- // avoid a direct internal dependency, we check the class name instead of
- // doing an instanceof. The risk is that JDT will refactor, and we will loose
- // this feature.
- if (element.getClass().getName().endsWith(".ClassPathContainer") && isJET2Project) { //$NON-NLS-1$
- return false;
- }
- if(element instanceof IPackageFragmentRoot && isJET2Project) {
- return false;
- }
- return true;
- }
-
- /**
- * @param element
- * @return
- * @throws CoreException
- */
- private boolean isJET2Project(Object element) {
- if(element instanceof IJavaProject) {
- IJavaProject jp = (IJavaProject)element;
- try {
- return jp.getProject().hasNature(JET2Platform.JET2_NATURE_ID);
- } catch (CoreException e) {
- // No action required:
- // only happens if the project doesn't exist. But we won't get here unless the project does
- }
- }
- return false;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/Messages.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/Messages.java
deleted file mode 100644
index 2a40b37..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/Messages.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*******************************************************************************
- * 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.ui.l10n;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jet.internal.ui.l10n.messages"; //$NON-NLS-1$
-
- private Messages() {
- }
-
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- public static String CompilePreferencePage_BaseLocationsLabel;
-
- public static String CompilePreferencePage_CompileBaseTemplates;
-
- public static String CompilePreferencePage_DependenciesGroupLabel;
-
- public static String CompilePreferencePage_DeriveJavaFiles;
-
- public static String CompilePreferencePage_Description;
-
- public static String CompilePreferencePage_EnableProjectSettings;
-
- public static String CompilePreferencePage_FileExtensions;
-
- public static String CompilePreferencePage_InvalidBaseLocations;
-
- public static String CompilePreferencePage_JavaGenerationGroupLabel;
-
- public static String CompilePreferencePage_JavaPackage;
-
- public static String CompilePreferencePage_JET1_OPTION;
-
- public static String CompilePreferencePage_JET1OptionsGroupLabel;
-
- public static String CompilePreferencePage_JET2_Option;
-
- public static String CompilePreferencePage_JET2_OPTIONS_GROUP_LABEL;
-
- public static String CompilePreferencePage_JETComformanceGroupLabel;
-
- public static String CompilePreferencePage_OverrideTemplatesOption;
-
- public static String CompilePreferencePage_SourceFolder;
-
- public static String CompilePreferencePage_TemplatesDirLabel;
-
- public static String CompilePreferencePage_use_java5;
-
- public static String ExtensionListEditor_AddDialogErrorMsg;
-
- public static String ExtensionListEditor_AddDialogPrompt;
-
- public static String ExtensionListEditor_AddDialogTitle;
-
- public static String JETPreferencePage_Description;
-
- public static String JETPreferencePage_LocationsAddDialogTitle;
-
- public static String JETPreferencePage_LocationsLabel;
-
- public static String JETTransformMainTab_BrowseButtonLabel;
-
- public static String JETTransformMainTab_DebugSeverity;
-
- public static String JETTransformMainTab_DescriptionLabel;
-
- public static String JETTransformMainTab_DisplayMessage_Gropu;
-
- public static String JETTransformMainTab_ErrorSeverity;
-
- public static String JETTransformMainTab_IdLabel;
-
- public static String JETTransformMainTab_InformationSeverity;
-
- public static String JETTransformMainTab_NameLabel;
-
- public static String JETTransformMainTab_SelectResourceDialogTitle;
-
- public static String JETTransformMainTab_SeverityLabel;
-
- public static String JETTransformMainTab_TraceSeverity;
-
- public static String JETTransformMainTab_TransformGroupLabel;
-
- public static String JETTransformMainTab_TransformInputGroup;
-
- public static String JETTransformMainTab_WarningSeverity;
-
- public static String LaunchShortcut_DefaultLaunchName;
-
- public static String NewProjectWizard_WindowTitle;
-
- public static String NewProjectWizard_ErrorCreatingProject;
-
- public static String NewProjectWizard_MainPageTabText;
-
- public static String NewProjectWizard_MainPageTitle;
-
- public static String NewProjectWizard_MainPageDescription;
-
- public static String LaunchWizard_MainTab_Name;
-
- public static String JET2TemplateAccess_ErrorLoadingTemplateStore;
-
- public static String UnloadAction_DialogTitle;
-
- public static String UnloadAction_UnloadSuccessful;
-
- public static String UnloadAction_UnloadFailed;
-
- public static String UnloadAction_NotLoaded;
-
- public static String NewProjectWizard_ErrorInJETTransform;
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/messages.properties b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/messages.properties
deleted file mode 100644
index db65712..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/l10n/messages.properties
+++ /dev/null
@@ -1,66 +0,0 @@
-###############################################################################
-# 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 v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-NewProjectWizard_WindowTitle=New JET Transformation Project
-NewProjectWizard_ErrorCreatingProject=Error attempting to create project
-NewProjectWizard_ErrorInJETTransform=The JET transformation that creates the new project had execution errors
-NewProjectWizard_MainPageTabText=Main
-NewProjectWizard_MainPageTitle=JET Transformation Project
-NewProjectWizard_MainPageDescription=Create a JET Transformation Project in the workspace.
-
-LaunchShortcut_DefaultLaunchName=JET Transformation
-LaunchWizard_MainTab_Name=&Main
-
-JET2TemplateAccess_ErrorLoadingTemplateStore=Error loading editor template store.
-JETTransformMainTab_SelectResourceDialogTitle=Select resource
-
-UnloadAction_DialogTitle=Unload JET Transformation
-UnloadAction_UnloadSuccessful=Unloaded "{0}". Refresh the Plugins View to confirm success.
-UnloadAction_UnloadFailed=Failed to unloaded "{0}". Reason: {1}.
-UnloadAction_NotLoaded=Bundle is not loaded "{0}". No action was taken.
-
-JETTransformMainTab_TransformGroupLabel=Transformation
-JETTransformMainTab_DescriptionLabel=Description:
-JETTransformMainTab_SeverityLabel=&Severity (at or above):
-JETTransformMainTab_ErrorSeverity=error
-JETTransformMainTab_WarningSeverity=warning
-JETTransformMainTab_DebugSeverity=debug
-JETTransformMainTab_NameLabel=Name:
-JETPreferencePage_Description=JET General options
-JETTransformMainTab_IdLabel=&ID:
-JETTransformMainTab_TransformInputGroup=&Transformation Input
-JETTransformMainTab_DisplayMessage_Gropu=Display Messages
-JETTransformMainTab_InformationSeverity=information
-JETTransformMainTab_TraceSeverity=trace
-JETTransformMainTab_BrowseButtonLabel=&Browse...
-CompilePreferencePage_Description=JET Compiler options
-CompilePreferencePage_EnableProjectSettings=&Enable Project specific settings
-CompilePreferencePage_JETComformanceGroupLabel=Generate Method Conformance
-CompilePreferencePage_JET2_OPTIONS_GROUP_LABEL=JET2 Options
-CompilePreferencePage_JET1OptionsGroupLabel=JET1 Options
-CompilePreferencePage_JavaGenerationGroupLabel=Java Generation Options
-CompilePreferencePage_InvalidBaseLocations=Base locations must be a comma seperated lists of URIs
-CompilePreferencePage_DependenciesGroupLabel=Dependencies (JET1 only)
-CompilePreferencePage_OverrideTemplatesOption=&Override templates from a base plug-in
-CompilePreferencePage_CompileBaseTemplates=&Compile all base templates to Java classes in this project
-CompilePreferencePage_JavaPackage=Default Java &Package:
-CompilePreferencePage_JET1_OPTION=JET&1 - String generate(Object argument)
-CompilePreferencePage_JET2_Option=JET&2 - void generate(JET2Context context, JET2Writer out)
-CompilePreferencePage_use_java5=Use &Java 5 language features
-CompilePreferencePage_FileExtensions=&File extensions for templates:
-CompilePreferencePage_SourceFolder=Java &Source folder:
-CompilePreferencePage_DeriveJavaFiles=&Hide compiled Java from Team system (mark .java files derived)
-CompilePreferencePage_BaseLocationsLabel=&Base Location URIs (comma separated):
-CompilePreferencePage_TemplatesDirLabel=Templates directory
-ExtensionListEditor_AddDialogTitle=Add extension
-ExtensionListEditor_AddDialogPrompt=Enter an extension
-ExtensionListEditor_AddDialogErrorMsg=Extension must be a sequence of letters and/or digits
-JETPreferencePage_LocationsLabel=&Additional locations for JET Transformations
-JETPreferencePage_LocationsAddDialogTitle=Select a Folder
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JET2TransformationTabGroup.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JET2TransformationTabGroup.java
deleted file mode 100644
index 44035bf..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JET2TransformationTabGroup.java
+++ /dev/null
@@ -1,48 +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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- * /
- *******************************************************************************/
-
-package org.eclipse.jet.internal.ui.launch;
-
-import org.eclipse.debug.ui.AbstractLaunchConfigurationTabGroup;
-import org.eclipse.debug.ui.CommonTab;
-import org.eclipse.debug.ui.ILaunchConfigurationDialog;
-import org.eclipse.debug.ui.ILaunchConfigurationTab;
-
-/**
- * @author pelder
- *
- */
-public class JET2TransformationTabGroup extends
- AbstractLaunchConfigurationTabGroup {
-
- /**
- *
- */
- public JET2TransformationTabGroup() {
- super();
- // TODO Auto-generated constructor stub
- }
-
- public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
- ILaunchConfigurationTab[] tabs = new ILaunchConfigurationTab[] {
-// new JET2TransformMainTab(),
- new JETTransformMainTab(),
- new CommonTab(),
- };
-
- setTabs(tabs);
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETConsoleColorProvider.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETConsoleColorProvider.java
deleted file mode 100644
index 24b7db0..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETConsoleColorProvider.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.internal.ui.launch;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.debug.core.model.IProcess;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.debug.ui.console.ConsoleColorProvider;
-import org.eclipse.debug.ui.console.IConsole;
-import org.eclipse.debug.ui.console.IConsoleColorProvider;
-import org.eclipse.jet.internal.JETPreferences;
-import org.eclipse.jet.internal.launch.JETProcess;
-import org.eclipse.jet.internal.launch.JETStreamsProxy;
-import org.eclipse.jet.ui.Activator;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.widgets.Display;
-
-/**
- * Colorize the JET execution console
- *
- */
-public class JETConsoleColorProvider extends ConsoleColorProvider implements IConsoleColorProvider {
-
- private Map colors;
- /**
- *
- */
- public JETConsoleColorProvider() {
- super();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.console.IConsoleColorProvider#connect(org.eclipse.debug.core.model.IProcess, org.eclipse.debug.ui.console.IConsole)
- */
- public void connect(IProcess process, IConsole console) {
- colors = new HashMap();
- JETProcess jetProcess = (JETProcess) process;
- final JETStreamsProxy jetStreamsProxy = (JETStreamsProxy) jetProcess
- .getStreamsProxy();
-
- if (jetStreamsProxy != null) {
- if (jetStreamsProxy.getWarningStreamMonitor() != null) {
- console.connect(jetStreamsProxy.getWarningStreamMonitor(),
- JETStreamsProxy.JET_WARNING_STREAM);
- }
- if (jetStreamsProxy.getTraceStreamMonitor() != null) {
- console.connect(jetStreamsProxy.getTraceStreamMonitor(),
- JETStreamsProxy.JET_TRACE_STREAM);
- }
- if (jetStreamsProxy.getDebugStreamMonitor() != null) {
- console.connect(jetStreamsProxy.getDebugStreamMonitor(),
- JETStreamsProxy.JET_DEBUG_STREAM);
- }
- }
- super.connect(process, console);
- }
-
- public void disconnect() {
- for (Iterator i = colors.values().iterator(); i.hasNext();) {
- Color color = (Color) i.next();
- color.dispose();
- }
- colors.clear();
- super.disconnect();
- }
-
- private Color getPrefColor(String prefKey) {
- Color color = (Color) colors.get(prefKey);
- if(color == null) {
- final IPreferenceStore store = Activator.getDefault().getPreferenceStore();
- final RGB rgb = PreferenceConverter.getColor(store, prefKey);
- color = new Color(Display.getCurrent(), rgb);
- colors.put(prefKey, color);
- }
- return color;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.console.IConsoleColorProvider#getColor(java.lang.String)
- */
- public Color getColor(String streamIdentifer) {
- if (streamIdentifer.equals(IDebugUIConstants.ID_STANDARD_OUTPUT_STREAM)) {
- return getPrefColor(JETPreferences.CONSOLE_INFO_COLOR);
- }
- if (streamIdentifer.equals(IDebugUIConstants.ID_STANDARD_ERROR_STREAM)) {
- return getPrefColor(JETPreferences.CONSOLE_ERROR_COLOR);
- }
- if (streamIdentifer.equals(JETStreamsProxy.JET_DEBUG_STREAM)) {
- return getPrefColor(JETPreferences.CONSOLE_DEBUG_COLOR);
- }
- if (streamIdentifer.equals(JETStreamsProxy.JET_TRACE_STREAM)) {
- return getPrefColor(JETPreferences.CONSOLE_TRACE_COLOR);
- }
- if (streamIdentifer.equals(JETStreamsProxy.JET_WARNING_STREAM)) {
- return getPrefColor(JETPreferences.CONSOLE_WARNING_COLOR);
- }
- return super.getColor(streamIdentifer);
- }
-
- public boolean isReadOnly() {
- return true;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETLaunchHelper.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETLaunchHelper.java
deleted file mode 100644
index 2fe324c..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETLaunchHelper.java
+++ /dev/null
@@ -1,311 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-package org.eclipse.jet.internal.ui.launch;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.debug.ui.DebugUITools;
-import org.eclipse.debug.ui.IDebugUIConstants;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jet.transform.IJETBundleDescriptor;
-import org.eclipse.jet.transform.JETLaunchConstants;
-import org.eclipse.jet.ui.Activator;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.window.Window;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.ElementListSelectionDialog;
-import org.eclipse.ui.dialogs.ElementTreeSelectionDialog;
-import org.eclipse.ui.dialogs.ISelectionStatusValidator;
-import org.eclipse.ui.model.WorkbenchContentProvider;
-import org.eclipse.ui.model.WorkbenchLabelProvider;
-
-public class JETLaunchHelper {
-
- private static ILaunchConfigurationType jetLaunchType = getConfigurationType();
- /**
- * @param resource
- * @param mode
- */
- public static ILaunchConfiguration createConfig(String id,
- IResource resource) {
- try {
- final ILaunchConfigurationWorkingCopy wConfig = jetLaunchType
- .newInstance(null, generateLaunchName(id, resource,
- Messages.LaunchShortcut_DefaultLaunchName));
- wConfig.setAttribute(JETLaunchConstants.ID, id);
- wConfig.setAttribute(JETLaunchConstants.SOURCE,
- resource != null
- ? resource.getFullPath().toString()
- : ""); //$NON-NLS-1$
- final ILaunchConfiguration config = wConfig.doSave();
- return config;
- } catch (CoreException e) {
- throw convertToRuntimeException(e);
- }
- }
-
- public static void findAndLaunchForTransformAndResource(Shell shell, String mode, String transformId, IResource resource) {
- ILaunchConfiguration[] configs = findConfigsForTransformAndResource(mode, transformId, resource);
- ILaunchConfiguration configToLaunch;
- switch(configs.length) {
- case 0:
- configToLaunch = createConfig(transformId, resource);
- break;
- case 1:
- configToLaunch = configs[0];
- break;
- default:
- configToLaunch = chooseExistingConfig(shell, configs);
- break;
- }
- if(configToLaunch != null) {
- DebugUITools.launch(configToLaunch, mode);
- }
- }
-
- public static boolean findAndLaunchForTransform(Shell shell, String mode, String transformId, boolean showConfigFirst) {
- ILaunchConfiguration[] configs = findConfigsForTransform(transformId);
- ILaunchConfiguration configToLaunch = null;
- switch(configs.length) {
- case 0:
- IResource resource = chooseResource(shell);
- if(resource != null) {
- configToLaunch = createConfig(transformId, resource);
- }
- break;
- case 1:
- configToLaunch = configs[0];
- break;
- default:
- configToLaunch = chooseExistingConfig(shell, configs);
- break;
- }
- if(configToLaunch != null) {
- boolean doLaunch = true;
- if(showConfigFirst) {
- int dialogResult = DebugUITools.openLaunchConfigurationDialog(shell, configToLaunch,
- IDebugUIConstants.ID_RUN_LAUNCH_GROUP, null);
- doLaunch = dialogResult != Window.CANCEL;
- }
- if(doLaunch) {
- DebugUITools.launch(configToLaunch, mode);
- }
- }
- return configToLaunch != null;
- }
-
- private static IResource chooseResource(Shell shell) {
- IResource resource = null;
- ElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog(
- shell, new WorkbenchLabelProvider(),
- new WorkbenchContentProvider());
-
- dialog.setInput(ResourcesPlugin.getWorkspace().getRoot());
- dialog.setAllowMultiple(false);
- dialog.setTitle(Messages.JETTransformMainTab_SelectResourceDialogTitle);
- dialog.setMessage(Messages.JETTransformMainTab_SelectResourceDialogTitle);
- dialog.setValidator(new ISelectionStatusValidator() {
- public IStatus validate(Object[] selection) {
- if (selection.length > 0) {
- return new Status(IStatus.OK, Activator.getDefault()
- .getBundle().getSymbolicName(), IStatus.OK,
- "", null); //$NON-NLS-1$
- }
-
- return new Status(IStatus.ERROR, Activator.getDefault()
- .getBundle().getSymbolicName(), IStatus.ERROR, "", null); //$NON-NLS-1$
- }
- });
- if (dialog.open() == ElementTreeSelectionDialog.OK) {
- resource = (IResource) dialog.getFirstResult();
- }
- return resource;
- }
-
- public static boolean findAndLauchForResource(Shell shell, String mode, IResource resource) {
- ILaunchConfiguration[] configs = findConfigsForResource(mode, resource);
- ILaunchConfiguration configToLaunch = null;
- switch(configs.length) {
- case 0:
-// MessageDialog.openError(shell, "Run JET Transform", "No JET transforms found.");
- IJETBundleDescriptor jetBundleDesc = JET2Platform.getProjectDescription(resource.getProject().getName());
- if(jetBundleDesc != null) {
- configToLaunch = createConfig(jetBundleDesc.getId(), resource);
- } else {
- configToLaunch = createConfig("", resource); //$NON-NLS-1$
- if(configToLaunch != null) {
- int dialogResult = DebugUITools.openLaunchConfigurationPropertiesDialog(shell, configToLaunch,
- IDebugUIConstants.ID_RUN_LAUNCH_GROUP, null);
- if(dialogResult == Window.CANCEL) {
- try {
- configToLaunch.delete();
- } catch (CoreException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- configToLaunch = null;
- } else {
- configs = findConfigsForResource(mode, resource);
- configToLaunch = configs.length > 0 ? configs[0] : null;
- }
- }
- }
- break;
- case 1:
- configToLaunch = configs[0];
- break;
- default:
- configToLaunch = chooseExistingConfig(shell, configs);
- break;
- }
- if(configToLaunch != null) {
- DebugUITools.launch(configToLaunch, mode);
- }
- return configToLaunch != null;
- }
-
- private static ILaunchConfiguration chooseExistingConfig(Shell shell,
- ILaunchConfiguration[] configs) {
- ILabelProvider labelProvider = new LabelProvider() {
-
- public String getText(Object element) {
- return ((ILaunchConfiguration)element).getName();
- } };
-
- ElementListSelectionDialog dlg = new ElementListSelectionDialog(shell, labelProvider);
- dlg.setElements(configs);
- dlg.setTitle(Messages.LaunchShortcut_DefaultLaunchName);
- dlg.setMessage(Messages.LaunchShortcut_DefaultLaunchName);
- dlg.setMultipleSelection(false);
- int result = dlg.open();
- labelProvider.dispose();
- if (result == Window.OK) {
- return (ILaunchConfiguration) dlg.getFirstResult();
- }
- return null;
- }
-
- public static ILaunchConfiguration[] findConfigsForResource(String mode, IResource resource) {
- final List finds = new ArrayList();
- final ILaunchConfiguration[] configs = getJETLaunchConfigs();
- final IPath fullPath = resource.getFullPath().makeRelative();
- for (int i = 0; i < configs.length; i++) {
- if(fullPath.equals(new Path(getSource(configs[i])).makeRelative())){
- finds.add(configs[i]);
- }
- }
- return (ILaunchConfiguration[]) finds.toArray(new ILaunchConfiguration[finds.size()]);
- }
-
- public static ILaunchConfiguration[] findConfigsForTransformAndResource(String mode, String transformId, IResource resource) {
- final List finds = new ArrayList();
- final ILaunchConfiguration[] configs = getJETLaunchConfigs();
- final String fullPath = resource.getFullPath().toString();
- for (int i = 0; i < configs.length; i++) {
- if(fullPath.equals(getSource(configs[i]))
- && transformId.equals(getTransformID(configs[i]))){
- finds.add(configs[i]);
- }
- }
-
- return (ILaunchConfiguration[]) finds.toArray(new ILaunchConfiguration[finds.size()]);
- }
-
- public static ILaunchConfiguration[] findConfigsForTransform(String transformId) {
- final ILaunchConfiguration[] configs = getJETLaunchConfigs();
- List finds = new ArrayList();
- for (int i = 0; i < configs.length; i++) {
- if(transformId.equals(getTransformID(configs[i]))){
- finds.add(configs[i]);
- }
- }
- return (ILaunchConfiguration[]) finds.toArray(new ILaunchConfiguration[finds.size()]);
- }
-
-
- private static String getSource(ILaunchConfiguration config) {
- try {
- return config.getAttribute(JETLaunchConstants.SOURCE, (String)null);
- } catch (CoreException e) {
- throw convertToRuntimeException(e);
- }
- }
-
- private static String getTransformID(ILaunchConfiguration config) {
- try {
- return config.getAttribute(JETLaunchConstants.ID, (String)null);
- } catch (CoreException e) {
- throw convertToRuntimeException(e);
- }
- }
-
- private static RuntimeException convertToRuntimeException(CoreException e) {
- return new RuntimeException("Unexpected exception", e); //$NON-NLS-1$
- }
-
- private static ILaunchConfiguration[] getJETLaunchConfigs() {
- try {
- ILaunchManager lm = DebugPlugin.getDefault().getLaunchManager();
- return lm.getLaunchConfigurations(jetLaunchType);
- } catch (CoreException e) {
- throw convertToRuntimeException(e);
- }
- }
-
- private static ILaunchConfigurationType getConfigurationType() {
- ILaunchManager lm= DebugPlugin.getDefault().getLaunchManager();
- return lm.getLaunchConfigurationType(JETLaunchConstants.CONFIG_ID);
- }
-
- public static String generateLaunchName(String id, IResource input, String defaultName)
- {
- ILaunchManager lm = DebugPlugin.getDefault().getLaunchManager();
- String prefix;
- if (id == null && input == null) {
- prefix = defaultName;
- } else if(input == null) {
- prefix = id;
- } else if(id == null)
- {
- prefix = input.getName();
- } else {
- prefix = id + " (" + input.getName() + ")"; //$NON-NLS-1$//$NON-NLS-2$
- }
-
- return lm.generateUniqueLaunchConfigurationNameFrom(prefix);
- }
-
- public static ILaunchConfiguration[] findAllConfigs() {
- return getJETLaunchConfigs();
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETTransformMainTab.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETTransformMainTab.java
deleted file mode 100644
index 4d38ae7..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/JETTransformMainTab.java
+++ /dev/null
@@ -1,402 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.internal.ui.launch;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-import org.eclipse.debug.ui.AbstractLaunchConfigurationTab;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jet.internal.runtime.RuntimeLoggerContextExtender;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jet.transform.IJETBundleDescriptor;
-import org.eclipse.jet.transform.JETLaunchConstants;
-import org.eclipse.jet.ui.Activator;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.accessibility.AccessibleAdapter;
-import org.eclipse.swt.accessibility.AccessibleEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.dialogs.ElementTreeSelectionDialog;
-import org.eclipse.ui.dialogs.ISelectionStatusValidator;
-import org.eclipse.ui.model.WorkbenchContentProvider;
-import org.eclipse.ui.model.WorkbenchLabelProvider;
-
-/**
- * Main tab for JET Launch Configuraitons
- *
- */
-public class JETTransformMainTab extends AbstractLaunchConfigurationTab {
-
- private static final String EMPTY_STRING = ""; //$NON-NLS-1$
- // input block controls
- private Text sourceField;
- private Button workspaceLocationButton;
-
- private final Listener fListener = new Listener();;
-
- private Image tabImage;
- private Combo transformCombo;
- private Text transformName;
- private Text transformDescription;
- private Combo logLevelCombo;
- private String[] logLevels;
-
-
- private class Listener extends SelectionAdapter implements ModifyListener
- {
-
- public void widgetSelected(SelectionEvent e) {
- setDirty(true);
- final Object source = e.getSource();
- if(source == transformCombo) {
- handleTransformSelection();
- }
- updateLaunchConfigurationDialog();
- }
- public void modifyText(ModifyEvent e) {
- setDirty(true);
- updateLaunchConfigurationDialog();
- }
- }
-
- /**
- *
- */
- public JETTransformMainTab() {
- super();
- }
-
- private void handleTransformSelection() {
- String id = transformCombo.getText();
- final IJETBundleDescriptor descriptor = JET2Platform.getJETBundleManager().getDescriptor(id);
- transformName.setText(descriptor.getName());
- transformDescription.setText(descriptor.getDescription().trim());
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.verticalSpacing = 15;
- composite.setLayout(layout);
- composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- createInputBlock(composite);
- createTransformBlock(composite);
- createMessagesBlock(composite);
-
- setControl(composite);
- Dialog.applyDialogFont(composite);
- }
-
- private void createMessagesBlock(Composite composite) {
- Group group = new Group(composite, SWT.NONE);
- group.setText(Messages.JETTransformMainTab_DisplayMessage_Gropu);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- group.setLayout(layout);
- group.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- createLogLevelsSection(group);
- }
-
- private void createLogLevelsSection(Group parent) {
- Label label = new Label(parent, SWT.NONE);
- label.setText(Messages.JETTransformMainTab_SeverityLabel);
-
- logLevelCombo = new Combo(parent, SWT.DROP_DOWN | SWT.READ_ONLY);
- logLevelCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- logLevelCombo.setItems(getLogLevels());
- logLevelCombo.addSelectionListener(fListener);
- }
-
- /**
- * @param composite
- */
- private void createTransformBlock(Composite parent) {
- Group group = new Group(parent, SWT.NONE);
- group.setText(Messages.JETTransformMainTab_TransformGroupLabel);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- group.setLayout(layout);
- group.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- createTransformIdSection(group);
- createTransformNameSection(group);
- createTransformDescriptionSection(group);
- }
-
- private void createTransformDescriptionSection(Group parent) {
- Label label = new Label(parent, SWT.NONE);
- label.setText(Messages.JETTransformMainTab_DescriptionLabel);
-
- transformDescription = new Text(parent, SWT.BORDER | SWT.READ_ONLY | SWT.MULTI);
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.widthHint = 300;
- gd.heightHint = 40;
- transformDescription.setLayoutData(gd);
- }
-
- private void createTransformNameSection(Group parent) {
- Label label = new Label(parent, SWT.NONE);
- label.setText(Messages.JETTransformMainTab_NameLabel);
-
- transformName = new Text(parent, SWT.BORDER | SWT.READ_ONLY);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.widthHint = 300;
- transformName.setLayoutData(gd);
-
- }
-
- private void createTransformIdSection(Group parent) {
- Label label = new Label(parent, SWT.NONE);
- label.setText(Messages.JETTransformMainTab_IdLabel);
-
- transformCombo = new Combo(parent, SWT.DROP_DOWN | SWT.READ_ONLY);
- transformCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- transformCombo.setItems(JET2Platform.getJETBundleManager().getAllTransformIds());
- transformCombo.addSelectionListener(fListener);
- }
-
- private void createInputBlock(Composite parent)
- {
- Group group = new Group(parent, SWT.NONE);
- group.setText(Messages.JETTransformMainTab_TransformInputGroup);
- GridLayout layout = new GridLayout();
- layout.numColumns = 1;
- group.setLayout(layout);
- group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- sourceField = new Text(group, SWT.BORDER);
- GridData gridData = new GridData(GridData.FILL_HORIZONTAL);
- gridData.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
- sourceField.setLayoutData(gridData);
- sourceField.addModifyListener(fListener);
- final String accessibleName = group.getText().replaceFirst("(?<!&)&", ""); //$NON-NLS-1$ //$NON-NLS-2$
- sourceField.getAccessible().addAccessibleListener(new AccessibleAdapter() {
-
- public void getName(AccessibleEvent e) {
- e.result = accessibleName;
- }
- });
-
- Composite buttonComposite = new Composite(group, SWT.NONE);
- layout = new GridLayout();
- layout.marginHeight = 0;
- layout.marginWidth = 0;
- layout.numColumns = 3;
- gridData = new GridData(GridData.HORIZONTAL_ALIGN_END);
- buttonComposite.setLayout(layout);
- buttonComposite.setLayoutData(gridData);
- buttonComposite.setFont(parent.getFont());
-
- workspaceLocationButton= createPushButton(buttonComposite, Messages.JETTransformMainTab_BrowseButtonLabel, null);
- workspaceLocationButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
-
- IResource resource = chooseResource(getShell());
- if(resource != null) {
- sourceField.setText(resource.getFullPath().makeRelative().toString());
- }
- }
- });
-
- }
-
- private static IResource chooseResource(Shell shell) {
- IResource resource = null;
- ElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog(
- shell, new WorkbenchLabelProvider(),
- new WorkbenchContentProvider());
-
- dialog.setInput(ResourcesPlugin.getWorkspace().getRoot());
- dialog.setAllowMultiple(false);
- dialog.setTitle(Messages.JETTransformMainTab_SelectResourceDialogTitle);
- dialog.setMessage(Messages.JETTransformMainTab_SelectResourceDialogTitle);
- dialog.setValidator(new ISelectionStatusValidator() {
- public IStatus validate(Object[] selection) {
- if (selection.length > 0)
- return new Status(IStatus.OK, Activator.getDefault().getBundle().getSymbolicName(),
- IStatus.OK, "", null); //$NON-NLS-1$
-
- return new Status(IStatus.ERROR, Activator.getDefault().getBundle().getSymbolicName(),
- IStatus.ERROR, "", null); //$NON-NLS-1$
- }
- });
- if (dialog.open() == ElementTreeSelectionDialog.OK) {
- resource = (IResource) dialog.getFirstResult();
- }
- return resource;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
- */
- public String getName() {
- return Messages.LaunchWizard_MainTab_Name;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#initializeFrom(org.eclipse.debug.core.ILaunchConfiguration)
- */
- public void initializeFrom(ILaunchConfiguration configuration) {
- try {
- final String id = configuration.getAttribute(JETLaunchConstants.ID, EMPTY_STRING);
- transformCombo.setText(id);
- final IJETBundleDescriptor descriptor = JET2Platform.getJETBundleManager().getDescriptor(id);
- if(descriptor != null)
- {
- transformName.setText(descriptor.getName());
- transformDescription.setText(descriptor.getDescription().trim());
- }
- } catch (CoreException e) {
- transformCombo.setText(EMPTY_STRING);
- }
- try {
- sourceField.setText(configuration.getAttribute(JETLaunchConstants.SOURCE, EMPTY_STRING));
- } catch (CoreException e) {
- sourceField.setText(EMPTY_STRING);
- }
-
- int level;
- try {
- level = configuration.getAttribute(JETLaunchConstants.LOG_FILTER_LEVEL, RuntimeLoggerContextExtender.INFO_LEVEL);
- } catch (CoreException e) {
- level = RuntimeLoggerContextExtender.INFO_LEVEL;
- }
- logLevelCombo.setText(getLogLevelText(level));
- }
-
- private String[] getLogLevels() {
- if (logLevels == null) {
- logLevels = new String[] {
- Messages.JETTransformMainTab_ErrorSeverity,
- Messages.JETTransformMainTab_WarningSeverity,
- Messages.JETTransformMainTab_InformationSeverity,
- Messages.JETTransformMainTab_TraceSeverity,
- Messages.JETTransformMainTab_DebugSeverity,
- };
- }
- return logLevels;
- }
-
- private int getLogLevelFromIndex(int selectionIndex) {
- // list is from highest (5) to lowest (1)
- return getLogLevels().length - selectionIndex;
- }
-
- private String getLogLevelText(int logLevel) {
- // log levels list are from highest (5) to lowest (1)
- return getLogLevels()[getLogLevels().length - logLevel];
- }
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#performApply(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy)
- */
- public void performApply(ILaunchConfigurationWorkingCopy configuration) {
- configuration.setAttribute(JETLaunchConstants.ID, transformCombo.getText());
-
- configuration.setAttribute(JETLaunchConstants.SOURCE, sourceField.getText());
-
- configuration.setAttribute(JETLaunchConstants.LOG_FILTER_LEVEL, getLogLevelFromIndex(logLevelCombo.getSelectionIndex()));
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#setDefaults(org.eclipse.debug.core.ILaunchConfigurationWorkingCopy)
- */
- public void setDefaults(ILaunchConfigurationWorkingCopy configuration) {
- ISelection selection = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getSelection();
-
- IFile resource = null;
- String id = null;
-
- if(selection instanceof IStructuredSelection) {
- IStructuredSelection iss = (IStructuredSelection) selection;
- Object firstElement = iss.getFirstElement();
- if(firstElement instanceof IFile) {
- resource = (IFile)firstElement;
- } else if (firstElement instanceof IAdaptable) {
- resource = (IFile) ((IAdaptable)firstElement).getAdapter(IFile.class);
- }
- }
- if(resource != null) {
- configuration.setAttribute(JETLaunchConstants.SOURCE,
- resource.getFullPath().makeRelative().toString());
-
- final IProject project = resource.getProject();
- final IJETBundleDescriptor descriptor = JET2Platform.getProjectDescription(project.getName());
- if(descriptor != null) {
- id = descriptor.getId();
- configuration.setAttribute(JETLaunchConstants.ID, id);
-
-
-
- }
- }
- configuration.setAttribute(JETLaunchConstants.LOG_FILTER_LEVEL, RuntimeLoggerContextExtender.INFO_LEVEL);
-
- configuration.rename(LaunchShortcut.generateLaunchName(id, resource));
- }
-
- public Image getImage() {
- if(tabImage == null) {
- ImageDescriptor imageDescriptor = Activator.getImageDescriptor("icons/JET2LaunchIcon.gif"); //$NON-NLS-1$
- tabImage = imageDescriptor.createImage();
- }
- return tabImage;
- }
-
- public void dispose() {
- if(tabImage != null) {
- tabImage.dispose();
- }
- super.dispose();
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/LaunchShortcut.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/LaunchShortcut.java
deleted file mode 100644
index 7c0cd0c..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/launch/LaunchShortcut.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.internal.ui.launch;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.debug.core.ILaunchManager;
-import org.eclipse.debug.ui.ILaunchShortcut;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Launch shortcut for launching JET transforms on an XML document.
- *
- */
-public class LaunchShortcut implements ILaunchShortcut {
-
- /**
- *
- */
- public LaunchShortcut() {
- super();
- // TODO Auto-generated constructor stub
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchShortcut#launch(org.eclipse.jface.viewers.ISelection, java.lang.String)
- */
- public void launch(ISelection selection, String mode) {
- // TODO Auto-generated method stub
- if(!(selection instanceof IStructuredSelection)) {
- return;
- }
- IResource resource = (IResource) ((IStructuredSelection)selection).getFirstElement();
- JETLaunchHelper.findAndLauchForResource(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),
- ILaunchManager.RUN_MODE, resource);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchShortcut#launch(org.eclipse.ui.IEditorPart, java.lang.String)
- */
- public void launch(IEditorPart editor, String mode) {
- final IResource resource = (IResource) editor.getEditorInput().getAdapter(IResource.class);
- JETLaunchHelper.findAndLauchForResource(editor.getSite().getShell(), ILaunchManager.RUN_MODE, resource);
-// findAndLaunch(resource, mode);
-
- }
-
- public static String generateLaunchName(String id, IResource input)
- {
- return JETLaunchHelper.generateLaunchName(id, input, Messages.LaunchShortcut_DefaultLaunchName);
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/popup/actions/UnloadAction.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/popup/actions/UnloadAction.java
deleted file mode 100644
index 3215591..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/popup/actions/UnloadAction.java
+++ /dev/null
@@ -1,91 +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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.internal.ui.popup.actions;
-
-import java.text.MessageFormat;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jet.internal.InternalJET2Platform;
-import org.eclipse.jet.internal.runtime.JETBundleInstaller;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IActionDelegate;
-import org.eclipse.ui.IObjectActionDelegate;
-import org.eclipse.ui.IWorkbenchPart;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleException;
-
-public class UnloadAction implements IObjectActionDelegate, IActionDelegate {
-
- private String bundleName;
- /**
- * Constructor for Action1.
- */
- public UnloadAction() {
- super();
- }
-
- /**
- * @see IObjectActionDelegate#setActivePart(IAction, IWorkbenchPart)
- */
- public void setActivePart(IAction action, IWorkbenchPart targetPart) {
- }
-
- /**
- * @see IActionDelegate#run(IAction)
- */
- public void run(IAction action) {
- Shell shell = new Shell();
- final JETBundleInstaller mgr = InternalJET2Platform.getDefault().getJETBundleInstaller();
- Bundle bundle = Platform.getBundle(bundleName);
- final String DialogTitle = Messages.UnloadAction_DialogTitle;
- if(bundle != null) {
- try {
- mgr.uninstallBundle(bundle);
- MessageDialog.openInformation(
- shell,
- DialogTitle,
- MessageFormat.format(Messages.UnloadAction_UnloadSuccessful, new Object[] {bundleName}));
- } catch (BundleException e) {
- e.printStackTrace();
- MessageDialog.openInformation(
- shell,
- DialogTitle,
- MessageFormat.format(Messages.UnloadAction_UnloadFailed, new Object[] {bundleName, e.toString()}));
- }}
- else {
- MessageDialog.openInformation(
- shell,
- DialogTitle,
- MessageFormat.format(Messages.UnloadAction_NotLoaded, new Object[] {bundleName}));
-
- }
- }
-
- /**
- * @see IActionDelegate#selectionChanged(IAction, ISelection)
- */
- public void selectionChanged(IAction action, ISelection selection) {
- IStructuredSelection se = (IStructuredSelection) selection;
-
- final Object firstElement = se.getFirstElement();
- if(firstElement instanceof IProject) {
- IProject project = (IProject) firstElement;
- bundleName = project.getName();
- }
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/CompilePreferencePage.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/CompilePreferencePage.java
deleted file mode 100644
index 8e0819c..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/CompilePreferencePage.java
+++ /dev/null
@@ -1,313 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- * /
- *******************************************************************************/
-
-package org.eclipse.jet.internal.ui.prefs;
-
-import java.net.URI;
-import java.net.URISyntaxException;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IncrementalProjectBuilder;
-import org.eclipse.core.resources.ProjectScope;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.preferences.InstanceScope;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jet.core.compiler.JETCompilerOptions;
-import org.eclipse.jet.core.parser.ast.JETAST;
-import org.eclipse.jet.internal.JETPreferences;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.FieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
-import org.eclipse.jface.preference.StringFieldEditor;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.eclipse.ui.IWorkbenchPropertyPage;
-import org.eclipse.ui.preferences.ScopedPreferenceStore;
-
-/**
- * @author pelder
- *
- */
-public class CompilePreferencePage extends FieldEditorPreferencePage implements
- IWorkbenchPreferencePage, IWorkbenchPropertyPage {
-
- private IProject element;
- private StringFieldEditor packageFieldEditor;
- private ExtensionListEditor extFieldEditor;
- private StringFieldEditor srcFolderFieldEditor;
- private StringFieldEditor templatesFolderFieldEditor;
- private BooleanFieldEditor derivedJavaFieldEditor;
- private BooleanFieldEditor projectSpecificSettingsEditor = null;
- private RadioGroupFieldEditor jetVersionFieldEditor;
- private BooleanFieldEditor compileBaseTemplatesFieldEditor = null;
- private StringFieldEditor baseTransformationFieldEditor = null;
- private Composite javaGenerationGroup;
- private Composite v1OptionsGroup;
- private Composite v2OptionsGroup;
- private boolean v1OptionsEnabled;
- private BooleanFieldEditor useJava5FieldEditor;
-
- /**
- * @param style
- */
- public CompilePreferencePage() {
- super(GRID);
-// setDescription(Messages.CompilePreferencePage_Description);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.preference.FieldEditorPreferencePage#createFieldEditors()
- */
- protected void createFieldEditors() {
-
- // determine whether the page is showing the workspace scope (Windows > Preferences)
- // or in project scope (Project properties)
- final boolean projectSettings = element != null;
- if(projectSettings) {
- setPreferenceStore(new ScopedPreferenceStore(new ProjectScope(element), JET2Platform.PLUGIN_ID));
- } else {
- setPreferenceStore(new ScopedPreferenceStore(new InstanceScope(), JET2Platform.PLUGIN_ID));
- }
-
- if(projectSettings) {
- // add a check box to use project specific settings
- projectSpecificSettingsEditor = new BooleanFieldEditor(JETPreferences.PROJECT_SPECIFIC_SETTINGS,
- Messages.CompilePreferencePage_EnableProjectSettings, getFieldEditorParent());
- addField(projectSpecificSettingsEditor);
- Label horizontalLine= new Label(getFieldEditorParent(), SWT.SEPARATOR | SWT.HORIZONTAL);
- horizontalLine.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false, 2, 1));
- horizontalLine.setFont(getFieldEditorParent().getFont());
- }
-
- // create "global" option editors...
- jetVersionFieldEditor = new RadioGroupFieldEditor(JETCompilerOptions.OPTION_JET_SPECIFICATION_VERSION, Messages.CompilePreferencePage_JETComformanceGroupLabel, 1,
- new String[][] {
- {Messages.CompilePreferencePage_JET1_OPTION, String.valueOf(JETAST.JET_SPEC_V1)},
- {Messages.CompilePreferencePage_JET2_Option, String.valueOf(JETAST.JET_SPEC_V2)},
- },
- getFieldEditorParent(), true);
- addField(jetVersionFieldEditor);
-
- v1OptionsEnabled = getPreferenceStore().getInt(JETCompilerOptions.OPTION_JET_SPECIFICATION_VERSION) == JETAST.JET_SPEC_V1;
-
-
-
- // common generation group
- javaGenerationGroup = createGroup(Messages.CompilePreferencePage_JavaGenerationGroupLabel);
-
- srcFolderFieldEditor = new StringFieldEditor(JETCompilerOptions.OPTION_COMPILED_TEMPLATE_SRC_DIR,
- Messages.CompilePreferencePage_SourceFolder, javaGenerationGroup);
- addField(srcFolderFieldEditor);
-
- derivedJavaFieldEditor = new BooleanFieldEditor(JETCompilerOptions.OPTION_SET_JAVA_FILES_AS_DERIVED,
- Messages.CompilePreferencePage_DeriveJavaFiles, javaGenerationGroup);
- addField(derivedJavaFieldEditor);
-
- useJava5FieldEditor = new BooleanFieldEditor(JETCompilerOptions.OPTION_USE_JAVA5, Messages.CompilePreferencePage_use_java5, javaGenerationGroup);
- addField(useJava5FieldEditor);
-
- // v1 options group
- v1OptionsGroup = createGroup(Messages.CompilePreferencePage_JET1OptionsGroupLabel);
- templatesFolderFieldEditor = new StringFieldEditor(JETCompilerOptions.OPTION_V1_TEMPLATES_DIR,
- Messages.CompilePreferencePage_TemplatesDirLabel, v1OptionsGroup);
- addField(templatesFolderFieldEditor);
- if(projectSettings) {
- baseTransformationFieldEditor = new StringFieldEditor(JETCompilerOptions.OPTION_V1_BASE_TRANSFORMATION,
- Messages.CompilePreferencePage_BaseLocationsLabel,
- StringFieldEditor.UNLIMITED,
- StringFieldEditor.VALIDATE_ON_KEY_STROKE,
- v1OptionsGroup) {
- protected boolean doCheckState() {
- String trimmedValue = getStringValue().trim();
- return trimmedValue.length() == 0 || isValidURIList(trimmedValue);
- }
-
- };
- baseTransformationFieldEditor.setErrorMessage(Messages.CompilePreferencePage_InvalidBaseLocations);
- addField(baseTransformationFieldEditor);
-
- compileBaseTemplatesFieldEditor = new BooleanFieldEditor(JETCompilerOptions.OPTION_V1_COMPILE_BASE_TEMPLATES, Messages.CompilePreferencePage_CompileBaseTemplates, v1OptionsGroup);
- addField(compileBaseTemplatesFieldEditor);
-
- }
-
- // v2 options group
- v2OptionsGroup = createGroup(Messages.CompilePreferencePage_JET2_OPTIONS_GROUP_LABEL);
-
- extFieldEditor = new ExtensionListEditor(JETCompilerOptions.OPTION_TEMPLATE_EXT,
- Messages.CompilePreferencePage_FileExtensions, v2OptionsGroup);
- addField(extFieldEditor);
-
- packageFieldEditor = new StringFieldEditor(JETCompilerOptions.OPTION_COMPILED_TEMPLATE_PACKAGE,
- Messages.CompilePreferencePage_JavaPackage, v2OptionsGroup);
- addField(packageFieldEditor);
-
-
-
- }
-
- private boolean isValidURIList(String uriList) {
- String[] uriStrings = uriList.split(","); //$NON-NLS-1$
- boolean ok = true;
- for (int i = 0; i < uriStrings.length; i++) {
- try {
- new URI(uriStrings[i]);
- } catch (URISyntaxException e) {
- ok = false;
- }
- }
- return ok;
- }
-
- /**
- * @param groupTitle
- * @return
- */
- private Composite createGroup(final String groupTitle) {
-
- final Group group = new Group(getFieldEditorParent(), SWT.NONE);
- group.setFont(getFieldEditorParent().getFont());
- group.setText(groupTitle);
- group.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false, 2, 1));
- setGroupLayout(group, 2);
-
- return group;
- }
-
- /**
- * @param group
- * @param numColumns TODO
- */
- private void setGroupLayout(final Composite group, int numColumns) {
- GridLayout layout = new GridLayout();
- layout.numColumns = numColumns;
- group.setLayout(layout);
- }
-
- /**
- *
- */
- private void updateControlEnablement() {
- final boolean projectSettings = projectSpecificSettingsEditor != null;
- // enable "global" options
- boolean enabledGlobalSettings = !projectSettings || projectSpecificSettingsEditor.getBooleanValue();
- jetVersionFieldEditor.setEnabled(enabledGlobalSettings, getFieldEditorParent());
- srcFolderFieldEditor.setEnabled(enabledGlobalSettings, javaGenerationGroup);
- derivedJavaFieldEditor.setEnabled(enabledGlobalSettings, javaGenerationGroup);
- useJava5FieldEditor.setEnabled(enabledGlobalSettings, javaGenerationGroup);
- if(!enabledGlobalSettings) {
- srcFolderFieldEditor.loadDefault();
- derivedJavaFieldEditor.loadDefault();
- jetVersionFieldEditor.loadDefault();
- useJava5FieldEditor.loadDefault();
- }
-
- // Enable JET1 options
- if(projectSettings) {
- boolean enableV1Options = v1OptionsEnabled && enabledGlobalSettings;
- baseTransformationFieldEditor.setEnabled(enableV1Options, v1OptionsGroup);
- compileBaseTemplatesFieldEditor.setEnabled(enableV1Options, v1OptionsGroup);
- templatesFolderFieldEditor.setEnabled(enableV1Options, v1OptionsGroup);
- if(!enableV1Options) {
- baseTransformationFieldEditor.loadDefault();
- compileBaseTemplatesFieldEditor.loadDefault();
- templatesFolderFieldEditor.loadDefault();
- }
- }
-
- // Enable JET2 options
- if(projectSettings) {
- boolean enableV2Options = !v1OptionsEnabled && enabledGlobalSettings;
- extFieldEditor.setEnabled(enableV2Options, v2OptionsGroup);
- packageFieldEditor.setEnabled(enableV2Options, v2OptionsGroup);
- if(!enableV2Options) {
- extFieldEditor.loadDefault();
- packageFieldEditor.loadDefault();
- }
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
- */
- public void init(IWorkbench workbench) {
- }
-
- public IAdaptable getElement() {
- return element;
- }
-
- public void setElement(IAdaptable element) {
- this.element = (IProject)element;
- }
-
- protected void initialize() {
- super.initialize();
- if(projectSpecificSettingsEditor != null)
- {
- updateControlEnablement();
- }
- }
-
- public void propertyChange(PropertyChangeEvent event) {
- super.propertyChange(event);
- if(event.getSource() == projectSpecificSettingsEditor && FieldEditor.VALUE.equals(event.getProperty())) {
- updateControlEnablement();
- } else if(event.getSource() == jetVersionFieldEditor && FieldEditor.VALUE.equals(event.getProperty())) {
- v1OptionsEnabled = String.valueOf(JETAST.JET_SPEC_V1).equals(event.getNewValue());
- updateControlEnablement();
- }
- }
-
- protected void performDefaults() {
- super.performDefaults();
- if (projectSpecificSettingsEditor != null) {
- updateControlEnablement();
- }
-
- }
-
- public boolean performOk() {
- final boolean ok = super.performOk();
- if(ok) {
- try {
- if(element != null)
- {
- element.build(IncrementalProjectBuilder.CLEAN_BUILD, null);
- }
- else
- {
- ResourcesPlugin.getWorkspace().build(IncrementalProjectBuilder.CLEAN_BUILD, null);
- }
- } catch (CoreException e) {
- // build failed, we don't care
- }
- }
- return ok;
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/ExtensionListEditor.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/ExtensionListEditor.java
deleted file mode 100644
index 2130113..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/ExtensionListEditor.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.internal.ui.prefs;
-
-import java.util.regex.Pattern;
-
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jface.dialogs.IInputValidator;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.preference.ListEditor;
-import org.eclipse.swt.widgets.Composite;
-
-
-/**
- * @author pelder
- *
- */
-public class ExtensionListEditor extends ListEditor {
-
- /**
- *
- */
- public ExtensionListEditor(String name, String labelText, Composite parent) {
- init(name, labelText);
- createControl(parent);
- }
-
- protected String createList(String[] items) {
- StringBuffer buffer = new StringBuffer();
- for (int i = 0; i < items.length; i++) {
- if(i != 0)
- {
- buffer.append(","); //$NON-NLS-1$
- }
- buffer.append(items[i]);
- }
- return buffer.toString();
- }
-
- protected String getNewInputObject() {
- InputDialog dialog = new InputDialog(getShell(), Messages.ExtensionListEditor_AddDialogTitle, Messages.ExtensionListEditor_AddDialogPrompt, "", new IInputValidator() { //$NON-NLS-1$
-
- public String isValid(String newText) {
- return !Pattern.matches("(\\p{L}|\\d)+", newText) ? //$NON-NLS-1$
- Messages.ExtensionListEditor_AddDialogErrorMsg : null;
- }});
- final int result = dialog.open();
- return result == InputDialog.OK ? dialog.getValue() : null;
- }
-
- protected String[] parseString(String stringList) {
- return stringList.split(","); //$NON-NLS-1$
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/JETPreferencePage.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/JETPreferencePage.java
deleted file mode 100644
index bf47b66..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/internal/ui/prefs/JETPreferencePage.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- * /
- *******************************************************************************/
-
-package org.eclipse.jet.internal.ui.prefs;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ProjectScope;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.preferences.InstanceScope;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jet.internal.JETPreferences;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.PathEditor;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.eclipse.ui.IWorkbenchPropertyPage;
-import org.eclipse.ui.preferences.ScopedPreferenceStore;
-
-/**
- * @author pelder
- *
- */
-public class JETPreferencePage extends FieldEditorPreferencePage implements
- IWorkbenchPreferencePage, IWorkbenchPropertyPage {
-
- private IAdaptable element;
-
- /**
- * @param style
- */
- public JETPreferencePage() {
- super(GRID);
-
-// setDescription(Messages.JETPreferencePage_Description);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.preference.FieldEditorPreferencePage#createFieldEditors()
- */
- protected void createFieldEditors() {
- if(element != null)
- {
- setPreferenceStore(new ScopedPreferenceStore(new ProjectScope((IProject)element), JET2Platform.PLUGIN_ID));
- }
- else {
- setPreferenceStore(new ScopedPreferenceStore(new InstanceScope(), JET2Platform.PLUGIN_ID));
- }
- addField(new PathEditor(JETPreferences.ADDITIONAL_TEMPLATE_JAR_LOCATIONS,
- Messages.JETPreferencePage_LocationsLabel,
- Messages.JETPreferencePage_LocationsAddDialogTitle,
- getFieldEditorParent()));
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)
- */
- public void init(IWorkbench workbench) {
- // TODO Auto-generated method stub
-
- }
-
- public IAdaptable getElement() {
- return element;
- }
-
- public void setElement(IAdaptable element) {
- this.element = element;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/Activator.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/Activator.java
deleted file mode 100644
index 0799b47..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/Activator.java
+++ /dev/null
@@ -1,82 +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 v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jet.ui;
-
-import org.eclipse.core.runtime.preferences.InstanceScope;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.eclipse.ui.preferences.ScopedPreferenceStore;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class Activator extends AbstractUIPlugin {
-
- //The shared instance.
- private static Activator plugin;
- private IPreferenceStore preferenceStore;
-
- /**
- * The constructor.
- */
- public Activator() {
- plugin = this;
- }
-
- /**
- * This method is called upon plug-in activation
- */
- public void start(BundleContext context) throws Exception {
- super.start(context);
- }
-
- /**
- * This method is called when the plug-in is stopped
- */
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- }
-
- /**
- * Returns the shared instance.
- */
- public static Activator getDefault() {
- return plugin;
- }
-
- /**
- * Returns an image descriptor for the image file at the given
- * plug-in relative path.
- *
- * @param path the path
- * @return the image descriptor
- */
- public static ImageDescriptor getImageDescriptor(String path) {
- return AbstractUIPlugin.imageDescriptorFromPlugin(getDefault()
- .getBundle().getSymbolicName(), path);
- }
-
- /**
- * Return the prefence store shared by ui and core plugins.
- */
- public IPreferenceStore getPreferenceStore() {
- // Create the preference store lazily.
- if (preferenceStore == null) {
- preferenceStore = new ScopedPreferenceStore(new InstanceScope(),JET2Platform.PLUGIN_ID);
-
- }
- return preferenceStore;
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/Messages.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/Messages.java
deleted file mode 100644
index 890484c..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/Messages.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * /
- *******************************************************************************/
-package org.eclipse.jet.ui.newproject;
-
-import org.eclipse.osgi.util.NLS;
-
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jet.ui.newproject.messages"; //$NON-NLS-1$
- public static String NewJETProjectPage2_description;
- public static String NewJETProjectPage2_InvalidID;
- public static String NewJETProjectPage2_title;
- public static String NewJETProjectPage2Controls__groupgrpTransProps_text;
- public static String NewJETProjectPage2Controls__labellblID_text;
- public static String NewJETProjectPage2Controls__labellblName_text;
- public static String NewJETProjectPage2Controls__labellblDescription_text;
- public static String NewJETProjectPage2Controls__labellblTemplateLoader_text;
- public static String NewJETProjectPage2Controls_grpExtensions_text;
- public static String NewJETProjectPage2Controls_cbxExtends_text;
- public static String NewJETProjectPage2Controls_lblBaseTx_text;
- public static String NewJETProjectPage1Controls__groupgProjSet_text;
- public static String NewJETProjectPage1Controls__labellblTemplateFolder_text;
- public static String NewJETProjectPage1Controls__labellblJETOutput_text;
- public static String NewJETProjectPage1Controls__labellblJavaOutput_text;
- public static String NewJETProjectPage1Controls__labellblDefJavaPackage_text;
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- private Messages() {
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1.java
deleted file mode 100644
index c9aa50f..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1.java
+++ /dev/null
@@ -1,139 +0,0 @@
-
-package org.eclipse.jet.ui.newproject;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.JavaConventions;
-import org.eclipse.jet.core.compiler.JETCompilerOptions;
-import org.eclipse.jet.ui.Activator;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-
-public class NewJETProjectPage1 extends NewJETProjectPage1Controls {
-
-
- private String lastBaseID = null;
-
- public NewJETProjectPage1(String pageName) {
- super(pageName);
- }
-
- public void createControl(Composite parent) {
- // super.createControl guarantees all controls are created.
- super.createControl(parent);
-
- // initialize control data
- final IPreferenceStore preferenceStore = Activator.getDefault().getPreferenceStore();
-
- txtTemplateFolder.setText("templates"); //$NON-NLS-1$
- txtJETOutput.setText(preferenceStore.getDefaultString(JETCompilerOptions.OPTION_COMPILED_TEMPLATE_SRC_DIR));
- txtJavaOutput.setText(preferenceStore.getDefaultString(JETCompilerOptions.OPTION_JAVA_OUTPUT_FOLDER));
- txtDefJavaPackage.setText(preferenceStore.getDefaultString(JETCompilerOptions.OPTION_COMPILED_TEMPLATE_PACKAGE));
-
- }
-
- protected void txtTemplateFolder_modify(ModifyEvent e) {
- validatePage();
- }
-
- protected void txtJETOutput_modify(ModifyEvent e) {
- validatePage();
- }
-
- protected void txtJavaOutput_modify(ModifyEvent e) {
- validatePage();
- }
-
- protected void txtDefJavaPackage_modify(ModifyEvent e) {
- validatePage();
- }
-
- protected boolean validatePage() {
- final boolean parentValid = super.validatePage();
- if(!parentValid) {
- return false;
- }
-
- final String id = getBaseID();
- if(!id.equals(lastBaseID)) {
- lastBaseID = id;
- final String newDefPackage = id + ".compiled"; //$NON-NLS-1$
- txtDefJavaPackage.setText(newDefPackage);
- }
-
- if(!validateFolder(txtTemplateFolder)) {
- return false;
- }
- if(!validateFolder(txtJavaOutput)) {
- return false;
- }
- if(!validateFolder(txtJETOutput)) {
- return false;
- }
- final String defaultJavaPackage = getDefaultJavaPackage();
- final IStatus status = validateJavaPackage(defaultJavaPackage);
- if(!status.isOK()) {
- setErrorMessage(status.getMessage());
- return false;
- }
- return true;
- }
-
- /**
- * @param defaultJavaPackage
- * @return
- */
- private IStatus validateJavaPackage(final String defaultJavaPackage) {
- IStatus status = JavaConventions.validatePackageName(defaultJavaPackage);
- return status;
- }
-
- /**
- * @param folderField
- */
- private boolean validateFolder(final Text folderField) {
- final IWorkspace workspace = ResourcesPlugin.getWorkspace();
- final IStatus status = workspace.validatePath("/" + getProjectName() + "/" + folderField.getText().trim(), IResource.FOLDER); //$NON-NLS-1$ //$NON-NLS-2$
- if(!status.isOK()) {
- setErrorMessage(status.getMessage());
- return false;
- } else {
- return true;
- }
- }
-
- /**
- * @return
- */
- String getBaseID() {
- final String projectName = getProjectName();
-
- final String id = projectName.replaceAll("[^a-zA-Z0-9\\._]", "_"); //$NON-NLS-1$//$NON-NLS-2$
- return id;
- }
-
- public String getDefJavaPackage() {
- return txtDefJavaPackage.getText();
- }
-
- public String getTemplateFolder() {
- return txtTemplateFolder.getText().trim();
- }
-
- public String getJETOutputFolder() {
- return txtJETOutput.getText().trim();
- }
-
- public String getJavaOutputFolder() {
- return txtJavaOutput.getText().trim();
- }
-
- public String getDefaultJavaPackage() {
- return txtDefJavaPackage.getText().trim();
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1Controls.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1Controls.java
deleted file mode 100644
index 95abe98..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage1Controls.java
+++ /dev/null
@@ -1,183 +0,0 @@
-package org.eclipse.jet.ui.newproject;
-
-import org.eclipse.ui.dialogs.WizardNewProjectCreationPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.*;
-import org.eclipse.swt.layout.*;
-import org.eclipse.swt.widgets.*;
-
-public abstract class NewJETProjectPage1Controls
- extends WizardNewProjectCreationPage {
-
- protected Text txtTemplateFolder;
- protected Text txtJETOutput;
- protected Text txtJavaOutput;
- protected Text txtDefJavaPackage;
-
-
- protected NewJETProjectPage1Controls(String pageName) {
- super(pageName);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- super.createControl(parent);
- // retarget parent to the control composite established by the base class
- parent = (Composite)getControl();
- initializeDialogUnits(parent);
-
- // working variables for creating grid layout info
- GridLayout _gl;
- GridData _gd;
-
- Group _groupgProjSet;
- _groupgProjSet = new Group(parent, SWT.NONE);
- _groupgProjSet.setText(Messages.NewJETProjectPage1Controls__groupgProjSet_text);
- _groupgProjSet.setFont(parent.getFont());
- org.eclipse.ui.PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), "org.eclipse.jet.ui.trjt0010"); //$NON-NLS-1$
-
-
- // layout _groupgProjSet within parent
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- _groupgProjSet.setLayoutData(_gd);
-
- // Initialize _groupgProjSet layout
- _gl = new GridLayout();
- _gl.numColumns = 2;
- _groupgProjSet.setLayout(_gl);
-
- Label _labellblTemplateFolder;
- _labellblTemplateFolder = new Label(_groupgProjSet, SWT.NONE);
- _labellblTemplateFolder.setText(Messages.NewJETProjectPage1Controls__labellblTemplateFolder_text);
- _labellblTemplateFolder.setFont(_groupgProjSet.getFont());
-
-
-
- txtTemplateFolder = new Text(_groupgProjSet, SWT.BORDER);
- txtTemplateFolder.setFont(_groupgProjSet.getFont());
-
-
- // layout txtTemplateFolder within _groupgProjSet
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtTemplateFolder.setLayoutData(_gd);
- // register event handlers for txtTemplateFolder
- txtTemplateFolder.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtTemplateFolder_modify(e);
- }});
-
- Label _labellblJETOutput;
- _labellblJETOutput = new Label(_groupgProjSet, SWT.NONE);
- _labellblJETOutput.setText(Messages.NewJETProjectPage1Controls__labellblJETOutput_text);
- _labellblJETOutput.setFont(_groupgProjSet.getFont());
-
-
-
- txtJETOutput = new Text(_groupgProjSet, SWT.BORDER);
- txtJETOutput.setFont(_groupgProjSet.getFont());
-
-
- // layout txtJETOutput within _groupgProjSet
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtJETOutput.setLayoutData(_gd);
- // register event handlers for txtJETOutput
- txtJETOutput.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtJETOutput_modify(e);
- }});
-
- Label _labellblJavaOutput;
- _labellblJavaOutput = new Label(_groupgProjSet, SWT.NONE);
- _labellblJavaOutput.setText(Messages.NewJETProjectPage1Controls__labellblJavaOutput_text);
- _labellblJavaOutput.setFont(_groupgProjSet.getFont());
-
-
-
- txtJavaOutput = new Text(_groupgProjSet, SWT.BORDER);
- txtJavaOutput.setFont(_groupgProjSet.getFont());
-
-
- // layout txtJavaOutput within _groupgProjSet
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtJavaOutput.setLayoutData(_gd);
- // register event handlers for txtJavaOutput
- txtJavaOutput.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtJavaOutput_modify(e);
- }});
-
- Label _labellblDefJavaPackage;
- _labellblDefJavaPackage = new Label(_groupgProjSet, SWT.NONE);
- _labellblDefJavaPackage.setText(Messages.NewJETProjectPage1Controls__labellblDefJavaPackage_text);
- _labellblDefJavaPackage.setFont(_groupgProjSet.getFont());
-
-
-
- txtDefJavaPackage = new Text(_groupgProjSet, SWT.BORDER);
- txtDefJavaPackage.setFont(_groupgProjSet.getFont());
-
-
- // layout txtDefJavaPackage within _groupgProjSet
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtDefJavaPackage.setLayoutData(_gd);
- // register event handlers for txtDefJavaPackage
- txtDefJavaPackage.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtDefJavaPackage_modify(e);
- }});
-
-
- }
-
-
- /**
- * Modify event handler for {@link #txtTemplateFolder}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtTemplateFolder_modify(ModifyEvent e);
-
- /**
- * Modify event handler for {@link #txtJETOutput}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtJETOutput_modify(ModifyEvent e);
-
- /**
- * Modify event handler for {@link #txtJavaOutput}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtJavaOutput_modify(ModifyEvent e);
-
- /**
- * Modify event handler for {@link #txtDefJavaPackage}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtDefJavaPackage_modify(ModifyEvent e);
-
-
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2.java
deleted file mode 100644
index d44983b..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2.java
+++ /dev/null
@@ -1,169 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * /
- *******************************************************************************/
-
-package org.eclipse.jet.ui.newproject;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.JavaConventions;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-
-public class NewJETProjectPage2 extends NewJETProjectPage2Controls {
-
-
- private NewJETProjectPage1 page1;
- private boolean showExtensionsGroup;
-
-
- public NewJETProjectPage2(String pageName) {
- super(pageName);
- setTitle(Messages.NewJETProjectPage2_title);
- setDescription(Messages.NewJETProjectPage2_description);
- }
-
- public void createControl(Composite parent) {
- // super.createControl guarantees all controls are created.
- super.createControl(parent);
-
- // initialize control data
- setExtends(false);
-
- final String[] allIDs = JET2Platform.getJETBundleManager().getAllTransformIds();
- for (int i = 0; i < allIDs.length; i++) {
- ddlBaseTx.add(allIDs[i]);
- }
-
- if(!showExtensionsGroup) {
- final boolean visible = false;
- grpExtensions.setVisible(visible);
- ddlBaseTx.setVisible(visible);
- cbxExtends.setVisible(visible);
- lblBaseTx.setVisible(visible);
- }
-
- setPageComplete(validatePage());
- }
-
- private boolean validatePage() {
- if(!validateTranformID()) {
- return false;
- }
- if(!validateTemplateLoader()) {
- return false;
- }
- if(cbxExtends.getSelection() && cbxExtends.isVisible() && ddlBaseTx.getText().trim().length() == 0) {
- return false;
- }
-
- setMessage(null);
- setErrorMessage(null);
- return true;
- }
-
- private boolean validateTemplateLoader() {
- final IStatus status = JavaConventions.validateJavaTypeName(getTemplateLoader());
- if(status.getSeverity() == IStatus.ERROR) {
- setErrorMessage(status.getMessage());
- return false;
- }
- return true;
- }
-
- private boolean validateTranformID() {
- final String transformID = getTransformID();
- if(!transformID.matches("[a-zA-Z0-9\\._]*")) { //$NON-NLS-1$
- setErrorMessage(Messages.NewJETProjectPage2_InvalidID);
- return false;
- }
- return true;
- }
-
- protected void txtID_modify(ModifyEvent e) {
- setPageComplete(validatePage());
- }
-
- protected void txtTemplateLoader_modify(ModifyEvent e) {
- setPageComplete(validatePage());
- }
-
- private void setExtends(boolean setExtends) {
- if(setExtends != cbxExtends.getSelection()) {
- cbxExtends.setSelection(setExtends);
- }
- lblBaseTx.setEnabled(setExtends);
- ddlBaseTx.setEnabled(setExtends);
-
- }
-
- public void setJETProjectPage1(NewJETProjectPage1 page1) {
- this.page1 = page1;
-
- }
- /* (non-Javadoc)
- * @see org.eclipse.jet.ui.newproject.NewJETProjectPage2Controls#cbxExtends_selection(org.eclipse.swt.events.SelectionEvent)
- */
- protected void cbxExtends_selection(SelectionEvent e) {
- final boolean selected = cbxExtends.getSelection();
- setExtends(selected);
- if(selected) {
- ddlBaseTx.setFocus();
- }
- setPageComplete(validatePage());
- getContainer().updateButtons();
- }
-
-
- protected void ddlBaseTx_modify(ModifyEvent e) {
- setPageComplete(validatePage());
- }
-
- public void setVisible(boolean visible) {
- super.setVisible(visible);
- if(visible && page1 != null) {
- txtTemplateLoader.setText(page1.getDefJavaPackage() + "._jet_transformation"); //$NON-NLS-1$
- txtID.setText(page1.getBaseID());
- txtName.setText(page1.getBaseID());
- txtID.setFocus();
- }
- }
-
- public boolean isExtension() {
- return cbxExtends.getSelection();
- }
-
- public String getTransformID() {
- return txtID.getText().trim();
- }
-
- public String getTransformName() {
- return txtName.getText().trim();
- }
-
- public String getTransformDescription() {
- return txtDescription.getText().trim();
- }
-
- public String getTemplateLoader() {
- return txtTemplateLoader.getText().trim();
- }
-
- public String getBaseTransformID() {
- return ddlBaseTx.getText().trim();
- }
-
- void showExtensionsGroup(boolean show) {
- this.showExtensionsGroup = show;
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2Controls.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2Controls.java
deleted file mode 100644
index 5e25d74..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewJETProjectPage2Controls.java
+++ /dev/null
@@ -1,265 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * /
- *******************************************************************************/
-package org.eclipse.jet.ui.newproject;
-
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.*;
-import org.eclipse.swt.layout.*;
-import org.eclipse.swt.widgets.*;
-
-public abstract class NewJETProjectPage2Controls
- extends WizardPage {
-
- protected Text txtID;
- protected Text txtName;
- protected Text txtDescription;
- protected Text txtTemplateLoader;
- protected Group grpExtensions;
- protected Button cbxExtends;
- protected Label lblBaseTx;
- protected Combo ddlBaseTx;
-
-
- protected NewJETProjectPage2Controls(String pageName) {
- super(pageName);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- initializeDialogUnits(parent);
-
- // working variables for creating grid layout info
- GridLayout _gl;
- GridData _gd;
-
- Composite _compositetop;
- _compositetop = new Composite(parent, SWT.NULL);
- _compositetop.setFont(parent.getFont());
- setControl(_compositetop);
- org.eclipse.ui.PlatformUI.getWorkbench().getHelpSystem().setHelp(getControl(), "org.eclipse.jet.ui.trjt0020"); //$NON-NLS-1$
-
-
- // layout _compositetop within parent
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- _gd.verticalAlignment = GridData.FILL;
- _gd.grabExcessVerticalSpace = true;
- _compositetop.setLayoutData(_gd);
-
- // Initialize _compositetop layout
- _gl = new GridLayout();
- _gl.numColumns = 1;
- _compositetop.setLayout(_gl);
-
- Group _groupgrpTransProps;
- _groupgrpTransProps = new Group(_compositetop, SWT.NONE);
- _groupgrpTransProps.setText(Messages.NewJETProjectPage2Controls__groupgrpTransProps_text);
- _groupgrpTransProps.setFont(_compositetop.getFont());
-
-
- // layout _groupgrpTransProps within _compositetop
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- _groupgrpTransProps.setLayoutData(_gd);
-
- // Initialize _groupgrpTransProps layout
- _gl = new GridLayout();
- _gl.numColumns = 2;
- _groupgrpTransProps.setLayout(_gl);
-
- Label _labellblID;
- _labellblID = new Label(_groupgrpTransProps, SWT.NONE);
- _labellblID.setText(Messages.NewJETProjectPage2Controls__labellblID_text);
- _labellblID.setFont(_groupgrpTransProps.getFont());
-
-
-
- txtID = new Text(_groupgrpTransProps, SWT.BORDER);
- txtID.setFont(_groupgrpTransProps.getFont());
-
-
- // layout txtID within _groupgrpTransProps
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtID.setLayoutData(_gd);
- // register event handlers for txtID
- txtID.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtID_modify(e);
- }});
-
- Label _labellblName;
- _labellblName = new Label(_groupgrpTransProps, SWT.NONE);
- _labellblName.setText(Messages.NewJETProjectPage2Controls__labellblName_text);
- _labellblName.setFont(_groupgrpTransProps.getFont());
-
-
-
- txtName = new Text(_groupgrpTransProps, SWT.BORDER);
- txtName.setFont(_groupgrpTransProps.getFont());
-
-
- // layout txtName within _groupgrpTransProps
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtName.setLayoutData(_gd);
-
- Label _labellblDescription;
- _labellblDescription = new Label(_groupgrpTransProps, SWT.NONE);
- _labellblDescription.setText(Messages.NewJETProjectPage2Controls__labellblDescription_text);
- _labellblDescription.setFont(_groupgrpTransProps.getFont());
-
-
-
- txtDescription = new Text(_groupgrpTransProps, SWT.BORDER);
- txtDescription.setFont(_groupgrpTransProps.getFont());
-
-
- // layout txtDescription within _groupgrpTransProps
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtDescription.setLayoutData(_gd);
-
- Label _labellblTemplateLoader;
- _labellblTemplateLoader = new Label(_groupgrpTransProps, SWT.NONE);
- _labellblTemplateLoader.setText(Messages.NewJETProjectPage2Controls__labellblTemplateLoader_text);
- _labellblTemplateLoader.setFont(_groupgrpTransProps.getFont());
-
-
-
- txtTemplateLoader = new Text(_groupgrpTransProps, SWT.BORDER);
- txtTemplateLoader.setFont(_groupgrpTransProps.getFont());
-
-
- // layout txtTemplateLoader within _groupgrpTransProps
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- txtTemplateLoader.setLayoutData(_gd);
- // register event handlers for txtTemplateLoader
- txtTemplateLoader.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- txtTemplateLoader_modify(e);
- }});
-
- grpExtensions = new Group(_compositetop, SWT.NONE);
- grpExtensions.setText(Messages.NewJETProjectPage2Controls_grpExtensions_text);
- grpExtensions.setFont(_compositetop.getFont());
-
-
- // layout grpExtensions within _compositetop
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- grpExtensions.setLayoutData(_gd);
-
- // Initialize grpExtensions layout
- _gl = new GridLayout();
- _gl.numColumns = 2;
- grpExtensions.setLayout(_gl);
-
- cbxExtends = new Button(grpExtensions, SWT.CHECK | SWT.RIGHT);
- cbxExtends.setText(Messages.NewJETProjectPage2Controls_cbxExtends_text);
-
- cbxExtends.setFont(grpExtensions.getFont());
-
-
- // layout cbxExtends within grpExtensions
- _gd = new GridData();
- _gd.horizontalSpan = 2;
- cbxExtends.setLayoutData(_gd);
- // register event handlers for cbxExtends
- cbxExtends.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- cbxExtends_selection(e);
- }
- });
-
- lblBaseTx = new Label(grpExtensions, SWT.NONE);
- lblBaseTx.setText(Messages.NewJETProjectPage2Controls_lblBaseTx_text);
- lblBaseTx.setFont(grpExtensions.getFont());
-
-
- // layout lblBaseTx within grpExtensions
- _gd = new GridData();
- _gd.horizontalIndent = convertWidthInCharsToPixels(4);
- lblBaseTx.setLayoutData(_gd);
-
- ddlBaseTx = new Combo(grpExtensions, SWT.RIGHT
- | SWT.DROP_DOWN
- | SWT.READ_ONLY
- );
- ddlBaseTx.setFont(grpExtensions.getFont());
-
-
- // layout ddlBaseTx within grpExtensions
- _gd = new GridData();
- _gd.horizontalAlignment = GridData.FILL;
- _gd.grabExcessHorizontalSpace = true;
- ddlBaseTx.setLayoutData(_gd);
- // register event handlers for ddlBaseTx
- ddlBaseTx.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- ddlBaseTx_modify(e);
- }});
-
-
- }
-
-
- /**
- * Modify event handler for {@link #txtID}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtID_modify(ModifyEvent e);
-
- /**
- * Modify event handler for {@link #txtTemplateLoader}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void txtTemplateLoader_modify(ModifyEvent e);
-
- /**
- * Selection event handler for {@link #cbxExtends}.
- * @param e an event containing information on the selection
- * @see SelectionListener
- * @see SelectionListener#widgetSelected(SelectionEvent)
- */
- protected abstract void cbxExtends_selection(SelectionEvent e);
-
- /**
- * Modify event handler for {@link #ddlBaseTx}.
- *
- * @param e the Modify Event
- * @see ModifyListener
- * @see ModifyListener#modifyText(ModifyEvent)
- */
- protected abstract void ddlBaseTx_modify(ModifyEvent e);
-
-
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectInfo.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectInfo.java
deleted file mode 100644
index c3b28e8..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectInfo.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/**
- * <copyright>
- *
- * Copyright (c) 2006, 2008 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- */
-
-package org.eclipse.jet.ui.newproject;
-
-import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.Map;
-
-/**
- * Represents information required to create a new JET2 Project
- *
- */
-public final class NewProjectInfo {
-
- private String projectName;
- private Map otherInfo = null;
- private static final String NL = System.getProperty("line.separator"); //$NON-NLS-1$
- private static final String INDENT = " "; //$NON-NLS-1$
- private final Map projectAttributes = new LinkedHashMap();
-
- public NewProjectInfo() {
- // nothing to do
- }
- /**
- * Return the currently set project Name.
- * @return the projectName or <code>null</code>
- */
- public final String getProjectName() {
- return projectName;
- }
-
- /**
- * Set the projectName.
- * @param projectName the projectName to set
- */
- public final void setProjectName(String projectName) {
- this.projectName = projectName;
- setProjectAttribute("name", projectName); //$NON-NLS-1$
- }
-
- public String toXmlString() {
- if(projectName == null) {
- throw new IllegalStateException("projectName not set"); //$NON-NLS-1$
- }
- StringBuffer xml = new StringBuffer();
- xml.append("<newProjectModel>").append(NL); //$NON-NLS-1$
- xml.append(INDENT).append("<project"); //$NON-NLS-1$
- for (Iterator i = projectAttributes.entrySet().iterator(); i.hasNext();) {
- Map.Entry entry = (Map.Entry) i.next();
- addAttribute(xml, (String)entry.getKey(), (String)entry.getValue());
- }
-// addAttribute(xml, "name", projectName); //$NON-NLS-1$
-// addAttribute(xml, "location", location); //$NON-NLS-1$
- xml.append("/>").append(NL); //$NON-NLS-1$
- if(otherInfo != null) {
- for (Iterator i = otherInfo.values().iterator(); i.hasNext();) {
- String otherElement = (String) i.next();
- xml.append(INDENT).append(otherElement).append(NL);
- }
- }
- xml.append("</newProjectModel>").append(NL); //$NON-NLS-1$
- return xml.toString();
- }
- /**
- * @param xml
- * @param name
- * @param value
- */
- private void addAttribute(StringBuffer xml, String name, final String value) {
- if(value != null) {
- xml.append(' ').append(name).append("=\"").append(value).append("\""); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-
-
- public void setOtherInfo(String key, String xmlContent) {
- if(otherInfo == null) {
- otherInfo = new LinkedHashMap();
- }
- if(xmlContent != null) {
- otherInfo.put(key, xmlContent);
- } else {
- otherInfo.remove(key);
- }
-
- }
- public void setLocation(String location) {
- setProjectAttribute("location", location); //$NON-NLS-1$
- }
-
- public void setProjectAttribute(String attributeName, String value) {
- projectAttributes.put(attributeName, value);
- }
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectWizard.java b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectWizard.java
deleted file mode 100644
index ab120b6..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/NewProjectWizard.java
+++ /dev/null
@@ -1,171 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2008 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM - Initial API and implementation
- *
- * </copyright>
- *
- * $Id$
- * /
- *******************************************************************************/
-
-package org.eclipse.jet.ui.newproject;
-
-import java.lang.reflect.InvocationTargetException;
-import java.util.Arrays;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.launching.IVMInstall;
-import org.eclipse.jdt.launching.JavaRuntime;
-import org.eclipse.jdt.launching.environments.IExecutionEnvironment;
-import org.eclipse.jet.JET2Platform;
-import org.eclipse.jet.internal.InternalJET2Platform;
-import org.eclipse.jet.internal.ui.l10n.Messages;
-import org.eclipse.jet.transform.IJETBundleDescriptor;
-import org.eclipse.jet.ui.Activator;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.operation.IRunnableWithProgress;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.ui.INewWizard;
-import org.eclipse.ui.IWorkbench;
-
-/**
- * Implement New Project Wizard for JET2 transforms.
- *
- */
-public class NewProjectWizard extends Wizard implements INewWizard {
-
- private static final String NEW_PROJECT_WIZARD_TX_ID = "org.eclipse.jet.transforms.newproject"; //$NON-NLS-1$
- private NewJETProjectPage1 projectPage;
-
- protected final NewProjectInfo newProjectInfo = new NewProjectInfo();
- private NewJETProjectPage2 projectPropertiesPage;
-
- /**
- *
- */
- public NewProjectWizard() {
- super();
- setWindowTitle(Messages.NewProjectWizard_WindowTitle);
- setDefaultPageImageDescriptor(Activator.getImageDescriptor("/icons/JET2ProjectWizardBanner.gif")); //$NON-NLS-1$
- setNeedsProgressMonitor(true);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.wizard.Wizard#performFinish()
- */
- public boolean performFinish() {
- try {
- getContainer().run(false, false, new IRunnableWithProgress() {
-
- public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
- IStatus result = JET2Platform.runTransformOnString(NEW_PROJECT_WIZARD_TX_ID, getBuildModel(), "xml", monitor); //$NON-NLS-1$
- if(!result.isOK()) {
- InternalJET2Platform.log(result);
- new ErrorDialog(getShell(), NewProjectWizard.this.getWindowTitle(),
- Messages.NewProjectWizard_ErrorInJETTransform,
- result, IStatus.ERROR | IStatus.WARNING).open();
- }
- }});
- } catch (InvocationTargetException e) {
- InternalJET2Platform.logError(Messages.NewProjectWizard_ErrorCreatingProject, e);
- } catch (InterruptedException e) {
- // cancelled, nothing to do
- }
- return true;
- }
-
- protected final String getBuildModel() {
- newProjectInfo.setProjectName(projectPage.getProjectName());
- if(!projectPage.useDefaults()) {
- newProjectInfo.setLocation(projectPage.getLocationPath().toString());
- }
- newProjectInfo.setProjectAttribute("binDir", projectPage.getJavaOutputFolder()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("jet2javaDir", projectPage.getJETOutputFolder()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("templatesDir", projectPage.getTemplateFolder()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("bundleName", projectPropertiesPage.getTransformName()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("bundleSymbolicName", projectPropertiesPage.getTransformID()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("dfltJavaPackage", projectPage.getDefaultJavaPackage()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("description", projectPropertiesPage.getTransformDescription()); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("templateLoader", projectPropertiesPage.getTemplateLoader()); //$NON-NLS-1$
- final String defaultEE = getDefaultExecutionEnv();
- if(defaultEE != null) {
- newProjectInfo.setProjectAttribute("executionEnv", defaultEE); //$NON-NLS-1$
- newProjectInfo.setProjectAttribute("useJava5", Boolean.toString(isDefaultEEJava5Compatible())); //$NON-NLS-1$
- }
- if(projectPropertiesPage.isExtension()) {
- newProjectInfo.setProjectAttribute("baseID", projectPropertiesPage.getBaseTransformID()); //$NON-NLS-1$
- final IJETBundleDescriptor descriptor = JET2Platform.getJETBundleManager().getDescriptor(projectPropertiesPage.getBaseTransformID());
- if(descriptor != null) {
- newProjectInfo.setProjectAttribute("baseStartTemplate", descriptor.getMainTemplate()); //$NON-NLS-1$
- }
- }
-
- return newProjectInfo.toXmlString();
- }
-
- private boolean isDefaultEEJava5Compatible() {
-
- final IVMInstall defaultVMInstall = JavaRuntime.getDefaultVMInstall();
- final IExecutionEnvironment java5ee = JavaRuntime.getExecutionEnvironmentsManager().getEnvironment("J2SE-1.5"); //$NON-NLS-1$
- return Arrays.asList(java5ee.getCompatibleVMs()).contains(defaultVMInstall);
- }
-
- private String getDefaultExecutionEnv() {
- final IVMInstall defaultVMInstall = JavaRuntime.getDefaultVMInstall();
- final IExecutionEnvironment[] ee = JavaRuntime.getExecutionEnvironmentsManager().getExecutionEnvironments();
- for (int i = 0; i < ee.length; i++) {
- if(ee[i].isStrictlyCompatible(defaultVMInstall)) {
- return ee[i].getId();
- }
- }
-
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection)
- */
- public void init(IWorkbench workbench, IStructuredSelection selection) {
- // nothing to do here
- }
-
- public void addPages() {
- super.addPages();
-
- projectPage= new NewJETProjectPage1(Messages.NewProjectWizard_MainPageTabText);
- projectPage.setTitle(Messages.NewProjectWizard_MainPageTitle);
- projectPage.setDescription(Messages.NewProjectWizard_MainPageDescription);
- addPage(projectPage);
-
- projectPropertiesPage = new NewJETProjectPage2(Messages.NewProjectWizard_MainPageTabText);
- projectPropertiesPage.setJETProjectPage1(projectPage);
- projectPropertiesPage.showExtensionsGroup(allowExtensionSpecification());
- addPage(projectPropertiesPage);
- }
-
-
-
- /**
- * Indicates whether the wizard will allow specification of JET transformation extensions.
- * Clients may override this method. Default implementation returns <code>true</code>.
- * @return <code>true</code> if extension transformations will be allowed.
- */
- protected boolean allowExtensionSpecification() {
- return true;
- }
-
- public boolean canFinish() {
- final IWizardPage currentPage = getContainer().getCurrentPage();
- return super.canFinish() && currentPage != projectPage;
- }
-
-}
diff --git a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/messages.properties b/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/messages.properties
deleted file mode 100644
index 6a49c18..0000000
--- a/plugins/org.eclipse.jet.ui/src/org/eclipse/jet/ui/newproject/messages.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-#NLS_MESSAGEFORMAT_VAR
-NewJETProjectPage1Controls__groupgProjSet_text=Project Settings
-NewJETProjectPage1Controls__labellblTemplateFolder_text=&Template folder:
-NewJETProjectPage1Controls__labellblJETOutput_text=J&ET output folder:
-NewJETProjectPage1Controls__labellblJavaOutput_text=J&ava output folder:
-NewJETProjectPage1Controls__labellblDefJavaPackage_text=Default &Java package:
-
-NewJETProjectPage2Controls__groupgrpTransProps_text=Transformation (plug-in) Properties
-NewJETProjectPage2Controls__labellblID_text=Transformation &ID:
-NewJETProjectPage2Controls__labellblName_text=Transformation na&me:
-NewJETProjectPage2Controls__labellblDescription_text=Transformation &description:
-NewJETProjectPage2Controls__labellblTemplateLoader_text=Template &loader:
-NewJETProjectPage2Controls_grpExtensions_text=Extensions
-NewJETProjectPage2Controls_cbxExtends_text=E&xtend an existing JET Transformation
-NewJETProjectPage2Controls_lblBaseTx_text=Base &transformation:
-
-NewJETProjectPage2_description=Enter the data required to generate the JET transformation
-NewJETProjectPage2_InvalidID=Invalid ID. Legal characters are A-Z a-z 0-9 . _
-NewJETProjectPage2_title=JET Transformation Properties

Back to the top