Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrsrinivasan2009-02-03 06:10:23 +0000
committerrsrinivasan2009-02-03 06:10:23 +0000
commitf31b0e40a46f723d35a8f2ad31c28af62a2f3149 (patch)
tree92dfc4b71305cdd12f9f9df4f74948cf584d5f27
parent0f95e516b26a78af311a8dccd66e097a965e05f0 (diff)
downloadwebtools.jsf-f31b0e40a46f723d35a8f2ad31c28af62a2f3149.tar.gz
webtools.jsf-f31b0e40a46f723d35a8f2ad31c28af62a2f3149.tar.xz
webtools.jsf-f31b0e40a46f723d35a8f2ad31c28af62a2f3149.zip
This commit was manufactured by cvs2svn to create tag 'v20090202'.v20090202
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/.classpath4
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/.cvsignore4
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/.project28
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/META-INF/MANIFEST.MF7
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/about.html22
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/about.ini29
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/about.mappings6
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/about.properties24
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/build.properties20
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/component.xml23
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/eclipse32.gifbin1706 -> 0 bytes
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/eclipse32.pngbin4594 -> 0 bytes
-rw-r--r--assembly/plugins/org.eclipse.jsf.branding/plugin.properties13
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.cvsignore1
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.project17
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/build.properties15
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/eclipse_update_120.jpgbin21695 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/epl-v10.html328
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.properties144
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.xml45
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/license.html97
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.html27
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.ini31
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.mappings6
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.properties27
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/build.properties13
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.gifbin1706 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.pngbin4634 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/plugin.properties20
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/build.properties19
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/eclipse_update_120.jpgbin21695 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/epl-v10.html328
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/feature.properties147
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/license.html82
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.html27
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.ini31
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.mappings6
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.properties27
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/build.properties13
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.gifbin1706 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.pngbin4634 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/plugin.properties20
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/.project17
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/build.properties17
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/eclipse_update_120.jpgbin21695 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/epl-v10.html328
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.properties144
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.xml33
-rw-r--r--jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/license.html97
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.cvsignore1
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.project17
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/build.properties18
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/eclipse_update_120.jpgbin21695 -> 0 bytes
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/epl-v10.html328
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.properties144
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.xml33
-rw-r--r--jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/license.html97
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.cvsignore2
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.jdt.core.prefs65
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/META-INF/MANIFEST.MF26
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/build.properties21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chart.gifbin1053 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseColor.gifbin1035 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseDate.gifbin931 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/chart.gifbin963 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputColor.gifbin868 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputDate.gifbin884 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputListOfValues.gifbin888 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputNumberSpinbox.gifbin899 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/importScript.gifbin924 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/inputHidden.gifbin341 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/message.gifbin163 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/messages.gifbin175 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/poll.gifbin904 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/selectItem.gifbin914 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/spacer.gifbin86 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/styleSheet.gifbin579 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.properties13
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.xml4192
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_dti.xml1433
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.properties14
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.xml408
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_dti.xml100
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_pi.xml24
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_pi.xml133
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad.xml1913
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad_html.xml193
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.properties27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.xml110
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/ITrinidadConstants.java2557
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/Messages.java114
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadTagSupportActivator.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadUtils.java67
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractLabelAndHelpOperation.java250
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractTrinidadTransformOperation.java122
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/CreateStyleAttributeOperation.java50
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputFileOperation.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextOperation.java98
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextWithIconOperation.java70
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/OutputFormattedOperation.java166
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelFormLayoutOperation.java427
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelGroupLayoutOperation.java164
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelLabelAndMessageOperation.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelTabbedOperation.java290
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectBooleanOperation.java65
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectListboxChoiceOperation.java91
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectManyCheckboxOneRadioOperation.java73
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectShuttleOperation.java257
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/ShowDetailItemOperation.java90
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/el/TrinidadDecorativeVariableResolver.java94
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/DefaultTrinidadCoreElementEdit.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelFormLayoutChildElementEdit.java58
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelTabbedElementEdit.java248
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/ShowDetailItemElementEdit.java98
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/TrinidadCoreElementEditFactory.java64
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/messages.properties28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItem.java78
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItemModel.java117
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/.cvsignore3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.jdt.core.prefs82
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/META-INF/MANIFEST.MF22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/build.properties16
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/WebContent/WEB-INF/faces-config.xml12
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/jar/jsfrt.jarbin21005 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/MyMonitorMessageFactory.java132
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/PhaseListener1.java342
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/plugin.properties11
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/JSFCommonRuntimePlugin.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/ComponentTreeMessage.java246
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/JSFMonitorMessage.java26
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/MonitorMessageFactory.java37
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderAttribute.java59
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderNode.java85
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/IDesigntimeAdapter.java26
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/ViewObject.java542
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/DataModelInfo.java82
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/SerializableObject.java79
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo.java85
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo2.java54
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/EditableValueHolderInfo.java144
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSource2Info.java30
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSourceInfo.java66
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IEditableValueHolderInfo.java103
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/INamingContainerInfo.java51
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IValueHolderInfo.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ValueHolderInfo.java68
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/AbstractVisitor.java96
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentFactory.java399
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentInfo.java930
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTreeVisitor.java39
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTypeInfo.java106
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/IVisitable.java32
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UICommandInfo.java117
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIDataInfo.java219
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIFormInfo.java86
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIInputInfo.java182
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIOutputInfo.java132
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/datatypes/ELExpression.java25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ActionListenerDecorator.java35
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ComponentDecorator.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterDecorator.java48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterTypeInfo.java146
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/Decorator.java31
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/FacetDecorator.java45
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorDecorator.java45
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorTypeInfo.java103
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValueChangeListenerDecorator.java36
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IActionListenerInfo.java21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IFacesListenerInfo.java21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IValueChangeListenerInfo.java21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/ClassTypeInfo.java137
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IAttributeValueProxy.java23
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IClassTypeInfo.java53
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/TypeInfo.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ComponentPropertyHandler.java46
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentPropertyHandler.java25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentTagElement.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IConverterTagElement.java29
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IHandlerTagElement.java80
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IJSFTagElement.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagAttributeHandler.java39
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagElement.java59
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IValidatorTagElement.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/Namespace.java80
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagAttributeHandler.java57
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagElement.java48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.cvsignore4
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs82
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.ui.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/META-INF/MANIFEST.MF36
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/about.ini29
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/about.mappings6
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/about.properties27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/default.properties52
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/eclipse32.gifbin1706 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/Editor_Help.gifbin2701 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_GotoEditor.gifbin1562 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Introduction.gifbin2683 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Tutorial.gifbin2778 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/PD_Palette_Default.gifbin82 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/back_nav_16.gifbin108 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/configs.gifbin368 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/form_banner.gifbin5600 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/forward_nav_16.gifbin138 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/help.gifbin259 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_converter.gifbin226 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_validator.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_view.gifbin368 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/object.gifbin561 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/overview_obj.gifbin2701 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/refresh_nav_16.gifbin182 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/reload_nav_16.gifbin367 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/stop_nav_16.gifbin163 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.properties16
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.xml6
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/introductionPage.exsd213
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/overviewPage.exsd213
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/CommonResources.properties113
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/IFileFolderConstants.java96
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/JSFUICommonPlugin.java418
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/IOpenPage.java28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadCheatSheetAction.java69
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadHelpAction.java68
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/OpenPageAction.java118
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/AbstractClassButtonDialogField.java238
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ClassButtonDialogField.java68
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorButtonDialogField.java339
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorPalette.java125
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ComboDialogField.java320
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogField.java149
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldBase.java559
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroup.java113
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroupPage.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.java62
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.properties48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldApplyListener.java32
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldChangeListener.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IStringButtonAdapter.java24
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ISupportTextValue.java37
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizard.java186
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizardPage.java249
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScope.java221
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScopeDecorator.java139
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaUIHelper.java140
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/LayoutUtil.java116
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/RadiosDialogField.java233
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ResourceButtonDialogField.java231
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/Separator.java128
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/SourceFolderButtonDialogField.java340
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusInfo.java198
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusUtil.java114
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringButtonDialogField.java186
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringDialogField.java291
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StyleComboDialogField.java398
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedElementSelectionValidator.java110
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedViewerFilter.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonResourceDialog.java368
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonWizardDialog.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/ResourceOnClasspathDialog.java254
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/TreeViewerSelectionDialog.java393
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractDetailsForm.java147
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterDetailBlock.java206
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterForm.java165
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractXMLSectionsDetailsForm.java186
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/BlankDetailsForm.java61
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Alerts.java837
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/BrowserWindow.java391
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/CollapsableSection.java148
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/FavoriteSection.java152
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/ImageContainer.java105
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/IntroductionSection.java351
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Messages.java35
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/OverviewSection.java287
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/SWTUtils.java1032
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/TextWindow.java63
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/messages.properties3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/logging/Logger.java215
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.java40
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.properties12
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/StrategyOrderingPanel.java322
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/FavoriteConfigurations.java257
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JSFSharedImages.java62
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JavaModelUtil.java1032
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PathUtil.java307
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PixelConverter.java80
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PluginImageHelper.java213
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PropertyUtils.java789
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/ResourceUtils.java286
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StringUtil.java157
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StyleCombo.java1877
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/UTF8Util.java89
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WebrootUtil.java256
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WorkspaceUtil.java283
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.cvsignore3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.core.prefs82
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.ui.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.wst.validation.prefs6
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/META-INF/MANIFEST.MF57
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/build.properties21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/cheatsheets/facesconfigeditor.xml276
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_GotoEditor.gifbin1562 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Introduction.gifbin2683 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Tutorial.gifbin2778 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope.gifbin981 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Application.gifbin990 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_None.gifbin879 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Request.gifbin895 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Session.gifbin899 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_ManagedBean.gifbin916 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Pageflow16.gifbin1022 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Plugin.gifbin1022 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Action16.gifbin150 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_BooleanValue.gifbin321 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_GenericValue.gifbin324 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_IntegralValue.gifbin211 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link.gifbin601 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link24.gifbin735 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline.gifbin167 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline_Overview.gifbin133 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page.gifbin1225 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page16.gifbin571 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page24.gifbin718 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Quickfix_Error.gifbin559 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_TextValue.gifbin322 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/form_banner.gifbin5600 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/help.gifbin259 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/overview_obj.gifbin2701 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties60
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml109
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.java1567
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.properties453
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPlugin.java268
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPluginResources.properties85
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigActionBarContributor.java179
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java1392
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/IFacesConfigConstants.java160
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/INestedActionContributor.java25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/ModelLoader.java215
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MultiPageEditorOutlinePage.java706
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MyEditingDomainActionContributor.java66
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/SubPageSite.java167
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditAttributeDialog.java269
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditFacetDialog.java226
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditManagedPropertyDialog.java529
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditMapEntryDialog.java255
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditPropertyDialog.java270
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditRendererDialog.java297
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/CommonListDialog.java245
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ComponentListDialog.java77
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/DialogUtil.java151
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditListEntriesDialog.java414
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditMapEntriesDialog.java449
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditValueDialog.java226
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ListChoiceDialog.java121
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/LocaleDialog.java184
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleSelectionDialog.java108
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleViewerSorter.java58
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/StatusDialog.java126
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ComponentsPage.java286
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/FacesConfigMasterDetailPage.java396
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IFacesConfigPage.java43
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IntroductionPage.java176
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ManagedBeanPage.java205
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OthersPage.java836
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OverviewPage.java248
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/WaitForLoadPage.java46
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ComponentDetailsPage.java68
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ConverterDetailsPage.java62
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/FacesConfigDetailsPage.java185
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ManagedBeanDetailsPage.java56
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/RenderkitDetailsPage.java55
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ValidatorDetailsPage.java61
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/DelegatingZoomManager.java374
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowActionBarContributor.java129
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditor.java1225
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorContextMenuProvider.java242
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorOutlinePage.java545
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.java483
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.properties155
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowPaletteRoot.java105
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowTemplateTransferDropTargetListener.java48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/ResourceTransferDropTargetListener.java212
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/AlignmentAction.java329
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/InternalImages.java101
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/OpenEditorAction.java122
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/ShowPropertyViewAction.java120
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom.gifbin928 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom_d.gifbin190 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter.gifbin924 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter_d.gifbin90 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft.gifbin919 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft_d.gifbin90 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid.gifbin929 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid_d.gifbin94 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright.gifbin923 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright_d.gifbin90 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop.gifbin931 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop_d.gifbin92 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AbstractBatchEditCommand.java114
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddConnectionCommand.java98
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddNodeCommand.java115
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/BendpointCommand.java143
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommand.java154
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommandFactory.java43
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateBendpointCommand.java66
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateNodeCommand.java253
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DelegatingCommandStack.java262
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteBendpointCommand.java57
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteConnectionCommand.java47
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteNodeCommand.java189
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandGEFAdapter.java124
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandStackGEFAdapter.java199
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/IPreExecuteCommand.java28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/MoveBendpointCommand.java91
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OpenEditorCommand.java173
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OrphanChildCommand.java101
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/PreExecuteCommandStack.java49
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ReconnectConnectionCommand.java114
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/RenameNodeCommand.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/SetConstraintCommand.java137
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ConfigurableRootEditPart.java76
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/DirectEditCellEditorLocator.java92
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IAnnotationEditPart.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IConnectionPreference.java62
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IFigurePreference.java48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ILayerPanePreference.java67
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/INodePreference.java35
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PFValidator.java23
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowContainerEditPart.java108
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowDirectEditManager.java138
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPart.java424
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPartsFactory.java43
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementEditPart.java362
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementTreeEditPart.java257
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowLinkEditPart.java491
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowNodeEditPart.java502
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreeEditPart.java56
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreePartFactory.java41
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkBendpointEditPolicy.java98
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEditPolicy.java46
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEndpointEditPolicy.java61
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowContainerEditPolicy.java62
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowElementEditPolicy.java40
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeDirectEditPolicy.java51
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeEditPolicy.java162
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeSelectionEditPolicy.java53
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowXYLayoutEditPolicy.java118
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ConnectionLabel.java79
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ILabelDecorator.java55
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/NodeLabel.java92
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PFLinkFigure.java318
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PageflowNodeFigure.java376
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/layout/PageflowLayoutManager.java550
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/Pageflow.java121
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowElement.java292
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowFactory.java78
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLink.java326
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLinkBendpoint.java237
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowNode.java115
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPackage.java1161
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPage.java117
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/LinkReferenceElement.java274
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageReferenceElement.java400
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowElementImpl.java616
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowFactoryImpl.java112
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowImpl.java472
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkBendpointImpl.java552
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkImpl.java893
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowNodeImpl.java390
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPackageImpl.java782
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPageImpl.java531
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/ReferenceElement.java168
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionDialogCellEditor.java75
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeDialogCellEditor.java103
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeSelectionDialog.java379
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionSectionDescriptor.java11
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditableDialogCellEditor.java147
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditorSectionDescriptor.java110
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ExistingPagePathDialogCellEditor.java101
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSection.java379
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSectionDescriptor.java132
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ITabbedPropertiesConstants.java59
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/LinkSectionDescriptor.java111
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PagePathDialogCellEditor.java74
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageSectionDescriptor.java108
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowElementPropertySource.java478
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowLinkPropertySource.java189
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionDescriptorProvider.java46
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionLabelProvider.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ProjectWebPageSelectionDialog.java63
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.java85
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.properties22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartGroup.java99
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartSection.java238
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorGroup.java86
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorSection.java117
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkGroup.java216
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkSection.java126
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageGroup.java173
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageSection.java168
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/SetPropertyValueCommand.java92
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFSynchronizer.java271
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFTransformer.java983
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PF2FCSynchronizer.java218
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PFBatchAdapter.java64
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/TransformUtil.java131
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/EditPartMarkerUtil.java216
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPDomAdapter.java216
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPUtil.java86
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/ModelCreationFactory.java65
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAdapterFactory.java256
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAnnotationUtil.java168
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowModelManager.java279
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactory.java78
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactoryImpl.java40
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceImpl.java36
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowSwitch.java262
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowTransform.java164
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowValidation.java288
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseFigureDecorator.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseNodeFigure.java946
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ColorFontFieldEditor.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ComboFieldEditor.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundFigureListener.java28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundNodeFigure.java480
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/FigureConstants.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/GEMPreferences.java792
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IBaseFigure.java90
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IContainerFigure.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IconFigure.java415
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/InputPortFigure.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/LinkFigure.java336
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ObserveVisibleXYLayout.java92
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/OutputPortFigure.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortConnectionAnchor.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortFigure.java1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.java225
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.properties54
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PrintedPageLayer.java177
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/RectangleList.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedTitleBarBorder.java591
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedWindowBorder.java252
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TitleBarButton.java240
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigure.java620
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigureListener.java27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFreeformHelper.java139
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanContentProvider.java138
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanLabelProvider.java121
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractFacesConfigSection.java295
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractOverviewSection.java136
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ApplicationSection.java216
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AttributeSection.java509
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentGeneralSection.java406
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentMasterSection.java88
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterGeneralSection.java490
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterMasterSection.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacesConfigMasterSection.java325
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacetSection.java455
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FactorySection.java169
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IDialogFieldGroup.java33
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IFacesConfigSection.java58
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/InitializationSection.java363
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LifecycleSection.java159
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ListEntriesEditGroup.java626
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LocaleConfigSection.java421
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanGeneralSection.java330
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanMasterSection.java375
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanScopeTreeItem.java94
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedPropertyEditGroup.java575
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/MapEntriesEditGroup.java692
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OthersPageBaseSection.java320
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewComponentsSection.java107
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewGeneralSection.java116
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewManagedBeanSection.java109
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewNavigationSection.java403
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewOthersSection.java361
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/PropertySection.java505
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RendererSection.java531
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitGeneralSection.java416
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitMasterSection.java86
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorGeneralSection.java416
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorMasterSection.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanProperty.java90
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanUtils.java775
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaClassUtils.java529
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ManagedBeanUtil.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ModelUtil.java189
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/WebrootUtil.java113
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ISummaryDataSource.java30
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanClassSelectionPage.java322
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanPropertyPage.java321
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewJavaClassPage.java92
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewManagedBeanWizard.java229
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/SummaryPage.java147
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.java461
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.properties128
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.cvsignore5
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.jdt.core.prefs65
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/META-INF/MANIFEST.MF15
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/build.properties21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_A.gifbin1039 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_FORM.gifbin788 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HEAD.gifbin1074 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HR.gifbin192 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_IMG.gifbin1220 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_BUTTON.gifbin325 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_CHECKBOX.gifbin418 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_HIDDEN.gifbin1109 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_IMAGE.gifbin464 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_PASSWORD.gifbin816 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_RADIO.gifbin663 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_TEXT.gifbin289 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_OBJECT.gifbin728 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_SELECT.gifbin467 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TABLE.gifbin467 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TEXTAREA.gifbin704 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_A.gifbin218 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_BR.gifbin885 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_FORM.gifbin959 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HEAD.gifbin1074 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HR.gifbin88 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_IMG.gifbin585 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_BUTTON.gifbin150 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_CHECKBOX.gifbin149 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_HIDDEN.gifbin341 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_IMAGE.gifbin218 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_PASSWORD.gifbin949 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_RADIO.gifbin166 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_TEXT.gifbin117 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_OBJECT.gifbin176 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_SELECT.gifbin914 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TABLE.gifbin343 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TEXTAREA.gifbin139 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ACTIONLISTENER.gifbin697 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ATTRIBUTE.gifbin479 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTDATETIME.gifbin1264 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTER.gifbin712 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTNUMBER.gifbin1167 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_FACET.gifbin744 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_LOADBUNDLE.gifbin713 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_PARAM.gifbin636 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEM.gifbin467 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEMS.gifbin730 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SUBVIEW.gifbin757 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATEDOUBLERANGE.gifbin1105 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELENGTH.gifbin1105 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELONGRANGE.gifbin1105 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATOR.gifbin1105 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALUECHANGELISTENER.gifbin782 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VERBATIM.gifbin447 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VIEW.gifbin502 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ACTIONLISTENER.gifbin222 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ATTRIBUTE.gifbin169 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTDATETIME.gifbin1005 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTER.gifbin226 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTNUMBER.gifbin932 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_FACET.gifbin950 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_LOADBUNDLE.gifbin415 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_PARAM.gifbin333 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEM.gifbin914 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEMS.gifbin931 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SUBVIEW.gifbin964 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATEDOUBLERANGE.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELENGTH.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELONGRANGE.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATOR.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALUECHANGELISTENER.gifbin958 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VERBATIM.gifbin122 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VIEW.gifbin368 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COLUMN.gifbin471 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDBUTTON.gifbin325 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDLINK.gifbin1039 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_DATATABLE.gifbin467 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_FORM.gifbin788 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_GRAPHICIMAGE.gifbin1141 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTHIDDEN.gifbin1109 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTSECRET.gifbin1087 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXT.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXTAREA.gifbin704 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGE.gifbin490 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGES.gifbin528 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTFORMAT.gifbin759 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLABEL.gifbin804 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLINK.gifbin823 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTTEXT.gifbin800 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGRID.gifbin316 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGROUP.gifbin438 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTBOOLEANCHECKBOX.gifbin418 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYCHECKBOX.gifbin1154 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYLISTBOX.gifbin493 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYMENU.gifbin731 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONELISTBOX.gifbin500 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONEMENU.gifbin663 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONERADIO.gifbin663 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COLUMN.gifbin162 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDBUTTON.gifbin150 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDLINK.gifbin218 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_DATATABLE.gifbin343 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_FORM.gifbin959 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_GRAPHICIMAGE.gifbin601 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTHIDDEN.gifbin341 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTSECRET.gifbin227 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXT.gifbin117 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXTAREA.gifbin139 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGE.gifbin163 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGES.gifbin175 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTFORMAT.gifbin954 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLABEL.gifbin956 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLINK.gifbin958 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTTEXT.gifbin954 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGRID.gifbin123 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGROUP.gifbin206 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTBOOLEANCHECKBOX.gifbin149 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYCHECKBOX.gifbin352 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYLISTBOX.gifbin926 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYMENU.gifbin177 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONELISTBOX.gifbin924 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONEMENU.gifbin160 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONERADIO.gifbin166 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DECLARATION.gifbin535 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.INCLUDE.gifbin449 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.PAGE.gifbin1157 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.TAGLIB.gifbin728 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_EXPRESSION.gifbin452 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FALLBACK.gifbin973 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FORWARD.gifbin582 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_GETPROPERTY.gifbin425 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_INCLUDE.gifbin567 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAM.gifbin636 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAMS.gifbin726 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PLUGIN.gifbin758 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_ROOT.gifbin464 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SCRIPTLET.gifbin1013 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SETPROPERTY.gifbin425 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_TEXT.gifbin358 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_USEBEAN.gifbin791 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DECLARATION.gifbin190 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.INCLUDE.gifbin934 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.PAGE.gifbin585 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.TAGLIB.gifbin338 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_EXPRESSION.gifbin126 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FALLBACK.gifbin327 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FORWARD.gifbin215 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_GETPROPERTY.gifbin284 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_INCLUDE.gifbin213 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAM.gifbin333 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAMS.gifbin948 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PLUGIN.gifbin244 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_ROOT.gifbin152 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SCRIPTLET.gifbin531 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SETPROPERTY.gifbin284 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_TEXT.gifbin117 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_USEBEAN.gifbin176 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.properties96
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.xml729
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core.xml509
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_dti.xml306
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.properties11
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.xml188
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.properties50
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.xml1244
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_dti.xml842
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.properties36
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.xml443
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.properties60
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.xml282
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/symbolInfoMetadata.xml17
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_core.xml188
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_html.xml558
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.properties27
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.xml43
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/src/org/eclipse/jst/jsf/standard/tagsupport/StandardTagSupportPlugin.java63
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.cvsignore5
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.options6
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.core.resources.prefs4
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.core.prefs82
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.ui.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/META-INF/MANIFEST.MF46
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/build.properties21
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/attr_val.gifbin124 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/full/wizban/addlibrary_wiz.gifbin3148 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_l_obj.gifbin581 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_obj.gifbin587 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/library_obj.gifbin338 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/icons/sample.gifbin983 -> 0 bytes
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/plugin.properties44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/plugin.xml320
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUITraceOptions.java72
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUiPlugin.java143
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/Messages.java331
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryContainerWizardPage.java558
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryEditControl.java465
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationEvent.java54
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationListener.java23
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryWizard.java162
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialog.java137
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialogWithToggle.java144
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/Messages.java48
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/MetadataTagImageManager.java202
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/ViewObjectPresenter.java244
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/messages.properties14
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentInstanceDetailsForm.java224
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterDetailBlock.java61
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterForm.java307
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeView.java175
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeViewProvider.java93
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/DTJSFViewModel.java255
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/Messages.java134
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/messages.properties25
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/JSFContentAssistProcessor.java296
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/el/JSFELContentAssistProcessor.java124
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/IJSFImplLibraryCreationListener.java26
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFImplLibraryCreationEvent.java44
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControl.java690
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeEvent.java36
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeListener.java24
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/BeanSuffixHyperlink.java117
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ELHyperlinkDetector.java100
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ITestHyperlink.java26
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSFELHover.java77
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSPSourceUtil.java130
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JavaElementHyperlink.java86
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/messages.properties91
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/EmptyRootPreferencePage.java109
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/JSPTagRegistryPreferencePage.java161
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/Messages.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/messages.properties4
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFFacetInstallPage.java467
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFLibraryPropertyPage.java22
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ComponentDetailSubForm.java73
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ConverterDetailsForm.java78
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/GenerateMetadataAction.java100
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/Messages.java106
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/NamespaceDetailsForm.java68
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ProjectTracker.java207
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/SetInputRunnable.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryDetailsForm.java93
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterDetailBlock.java99
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterForm.java501
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryView.java97
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TaglibContentProvider.java451
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ValidatorDetailsForm.java71
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/messages.properties20
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ELPrefPanel.java126
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidationPreferencePage.java87
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidator.java148
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/Messages.java33
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/MyLocalizedMessage.java103
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/OptionsConfigurationBlock.java979
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PixelConverter.java74
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PreferencesMessages.java237
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ProblemSeveritiesConfigurationBlock.java470
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ScrolledPageContent.java81
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/SeverityOverrideStrategy.java47
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationMessageFactory.java159
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationReporter.java58
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/messages.properties74
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.classpath7
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.cvsignore3
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.project28
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.core.prefs82
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.ui.prefs3
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.pde.prefs22
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/META-INF/MANIFEST.MF27
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/about.html22
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/build.properties20
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.properties17
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.xml5
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/schema/pageVar.exsd172
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/IJSPCoreConstants.java279
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/JSPCorePlugin.java95
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/ListenerList.java142
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/ELParser.java69
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/JSFELParserHelper.java267
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/DocumentPageVariableAdapter.java212
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdapter.java164
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdatperRegistry.java248
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/TagVarDescriptor.java114
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/VariableInfo.java90
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IChangeListener.java25
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IPageVariablesProvider.java38
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IVariableInfo.java56
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IDocumentPageVariableAdapter.java26
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IPageVariableAdapter.java51
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/PageVariableAdapterFactory.java42
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/util/CMUtil.java97
914 files changed, 0 insertions, 122744 deletions
diff --git a/assembly/plugins/org.eclipse.jsf.branding/.classpath b/assembly/plugins/org.eclipse.jsf.branding/.classpath
deleted file mode 100644
index 7cec603db..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/.classpath
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/assembly/plugins/org.eclipse.jsf.branding/.cvsignore b/assembly/plugins/org.eclipse.jsf.branding/.cvsignore
deleted file mode 100644
index 7033a799b..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/.cvsignore
+++ /dev/null
@@ -1,4 +0,0 @@
-bin
-@dot*
-temp.folder
-build.xml
diff --git a/assembly/plugins/org.eclipse.jsf.branding/.project b/assembly/plugins/org.eclipse.jsf.branding/.project
deleted file mode 100644
index bd5000449..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jsf.branding</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/assembly/plugins/org.eclipse.jsf.branding/META-INF/MANIFEST.MF b/assembly/plugins/org.eclipse.jsf.branding/META-INF/MANIFEST.MF
deleted file mode 100644
index 852482211..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,7 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %plugin.Name
-Bundle-SymbolicName: org.eclipse.jsf
-Bundle-Version: 1.0.1.qualifier
-Bundle-Localization: plugin
-Bundle-Vendor: %plugin.Provider
diff --git a/assembly/plugins/org.eclipse.jsf.branding/about.html b/assembly/plugins/org.eclipse.jsf.branding/about.html
deleted file mode 100644
index 7c80c6cde..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June 06, 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/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>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.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/assembly/plugins/org.eclipse.jsf.branding/about.ini b/assembly/plugins/org.eclipse.jsf.branding/about.ini
deleted file mode 100644
index a21a3ecea..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/about.ini
+++ /dev/null
@@ -1,29 +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=eclipse32.gif
-
-# Property "aboutImage" contains path to product image (500x330 or 115x164)
-# needed for primary features only
-
-# Property "appName" contains name of the application (translated)
-# needed for primary features only
-
-# Property "welcomePage" contains path to welcome page (special XML-based format)
-# optional
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-
diff --git a/assembly/plugins/org.eclipse.jsf.branding/about.mappings b/assembly/plugins/org.eclipse.jsf.branding/about.mappings
deleted file mode 100644
index bddaab431..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/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@ \ No newline at end of file
diff --git a/assembly/plugins/org.eclipse.jsf.branding/about.properties b/assembly/plugins/org.eclipse.jsf.branding/about.properties
deleted file mode 100644
index c62b076f8..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/about.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-###############################################################################
-# Copyright (c) 2005 Oracle 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:
-# Oracle 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=JavaServer Faces Tools\n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright Eclipse contributors and others 2005. All rights reserved.\n\
-Visit http://www.eclipse.org/webtools
diff --git a/assembly/plugins/org.eclipse.jsf.branding/build.properties b/assembly/plugins/org.eclipse.jsf.branding/build.properties
deleted file mode 100644
index ab20e7886..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/build.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2006 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-bin.includes = META-INF/,\
- eclipse32.png,\
- eclipse32.gif,\
- about.properties,\
- about.mappings,\
- about.ini,\
- about.html,\
- plugin.properties,\
- component.xml
-
diff --git a/assembly/plugins/org.eclipse.jsf.branding/component.xml b/assembly/plugins/org.eclipse.jsf.branding/component.xml
deleted file mode 100644
index d470a56d8..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/component.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<component xmlns="http://eclipse.org/wtp/releng/tools/component-model" name="org.eclipse.jsf">
-<description url=""></description>
-<component-depends unrestricted="true"></component-depends>
-<plugin id="org.eclipse.jst.jsf.common" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.common.ui" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.core" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.ui" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.standard.tagsupport" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.facesconfig" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.facesconfig.ui" fragment="false"/>
-<plugin id="org.eclipse.jst.pagedesigner" fragment="false"/>
-<plugin id="org.eclipse.jst.pagedesigner.jsf.ui" fragment="false"/>
-<plugin id="org.eclipse.jst.pagedesigner.jsp.core" fragment="false"/>
-<plugin id="org.eclipse.jst.jsf.doc.dev" fragment="false"/>
-</component>
-
-
-
-
-
-
-
diff --git a/assembly/plugins/org.eclipse.jsf.branding/eclipse32.gif b/assembly/plugins/org.eclipse.jsf.branding/eclipse32.gif
deleted file mode 100644
index e6ad7ccd7..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/eclipse32.gif
+++ /dev/null
Binary files differ
diff --git a/assembly/plugins/org.eclipse.jsf.branding/eclipse32.png b/assembly/plugins/org.eclipse.jsf.branding/eclipse32.png
deleted file mode 100644
index 568fac1d0..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/eclipse32.png
+++ /dev/null
Binary files differ
diff --git a/assembly/plugins/org.eclipse.jsf.branding/plugin.properties b/assembly/plugins/org.eclipse.jsf.branding/plugin.properties
deleted file mode 100644
index 2b7a86451..000000000
--- a/assembly/plugins/org.eclipse.jsf.branding/plugin.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2006 Oracle 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
-###############################################################################
-
-plugin.Name=JavaServer Faces Tools
-plugin.Provider=Eclipse.org \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.cvsignore b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.cvsignore
deleted file mode 100644
index c14487cea..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-build.xml
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.project b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.project
deleted file mode 100644
index a1d85021a..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.apache.trinidad.tagsupport.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/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/build.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/build.properties
deleted file mode 100644
index 4576d2222..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/build.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-bin.includes = feature.xml,\
- license.html,\
- feature.properties,\
- epl-v10.html,\
- eclipse_update_120.jpg
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/eclipse_update_120.jpg b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/eclipse_update_120.jpg
deleted file mode 100644
index bfdf708ad..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/eclipse_update_120.jpg
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/epl-v10.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/epl-v10.html
deleted file mode 100644
index ed4b19665..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/epl-v10.html
+++ /dev/null
@@ -1,328 +0,0 @@
-<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=windows-1252">
-<meta name=ProgId content=Word.Document>
-<meta name=Generator content="Microsoft Word 9">
-<meta name=Originator content="Microsoft Word 9">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<!--[if gte mso 9]><xml>
- <o:DocumentProperties>
- <o:Revision>2</o:Revision>
- <o:TotalTime>3</o:TotalTime>
- <o:Created>2004-03-05T23:03:00Z</o:Created>
- <o:LastSaved>2004-03-05T23:03:00Z</o:LastSaved>
- <o:Pages>4</o:Pages>
- <o:Words>1626</o:Words>
- <o:Characters>9270</o:Characters>
- <o:Lines>77</o:Lines>
- <o:Paragraphs>18</o:Paragraphs>
- <o:CharactersWithSpaces>11384</o:CharactersWithSpaces>
- <o:Version>9.4402</o:Version>
- </o:DocumentProperties>
-</xml><![endif]--><!--[if gte mso 9]><xml>
- <w:WordDocument>
- <w:TrackRevisions/>
- </w:WordDocument>
-</xml><![endif]-->
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {font-family:Tahoma;
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-generic-font-family:swiss;
- 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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
- font-family:Tahoma;
- mso-fareast-font-family:"Times New Roman";}
-@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><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.properties
deleted file mode 100644
index da2ba1112..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.properties
+++ /dev/null
@@ -1,144 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# feature.properties
-# contains externalized strings for feature.xml
-# "%foo" in feature.xml corresponds to the key "foo" in this file
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file should be translated.
-
-# "featureName" property - name of the feature
-featureName=Apache MyFaces Trinidad Tag Support (Optional)
-
-# "providerName" property - name of the company that provides the feature
-providerName=Eclipse.org
-
-# "updateSiteName" property - label for the update site
-updateSiteName=The Eclipse Web Tools Platform (WTP) Project update site
-
-# "description" property - description of the feature
-description=Apache MyFaces Trinidad Tag Support (Optional)
-
-# "copyright" property - text of the "Feature Update Copyright"
-feature.copyright=\
-Copyright (c) 2007 Oracle Corporation.\
-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\
-\n\
-Contributors:\n\
- Oracle 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\
-June 7, 2007\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 ##########################################
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.xml b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.xml
deleted file mode 100644
index 8e25d12e9..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/feature.xml
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature"
- label="%featureName"
- version="2.1.0.qualifier"
- provider-name="%providerName">
-
- <description>
- %description
- </description>
-
- <copyright>
- %copyright
- </copyright>
-
- <license url="license.html">
- %license
- </license>
-
- <url>
- <update label="%updateSiteName" url="http://download.eclipse.org/webtools/updates"/>
- <discovery label="Web Tools Platform (WTP) Updates" url="http://download.eclipse.org/webtools/updates"/>
- </url>
-
- <requires>
- <import plugin="org.eclipse.ui" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.core.runtime" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.emf.ecore.xmi" version="2.2.0" match="compatible"/>
- <import plugin="org.eclipse.gef" version="3.2.0" match="compatible"/>
- <import plugin="org.eclipse.wst.sse.core" version="1.1.0" match="equivalent"/>
- <import plugin="org.eclipse.jst.jsf.common" version="1.1.0" match="compatible"/>
- <import plugin="org.eclipse.jst.pagedesigner" version="1.1.0" match="compatible"/>
- <import plugin="org.eclipse.jst.jsf.core" version="1.1.0" match="compatible"/>
- <import plugin="org.eclipse.jdt.core" version="3.4.0" match="compatible"/>
- <import plugin="org.eclipse.core.resources" version="3.4.0" match="compatible"/>
- </requires>
-
- <plugin
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport"
- download-size="0"
- install-size="0"
- version="0.0.0"
- unpack="false"/>
-
-</feature>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/license.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/license.html
deleted file mode 100644
index a450af950..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/license.html
+++ /dev/null
@@ -1,97 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0044)http://www.eclipse.org/legal/epl/notice.html -->
-<HTML><HEAD><TITLE>Eclipse.org Software User Agreement</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1479" name=GENERATOR></HEAD>
-<BODY lang=EN-US vLink=purple link=blue>
-<H2>Eclipse Foundation Software User Agreement</H2>
-
-<H3>Usage Of Content</H3>
-<P>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION
-AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT"). 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 ("EPL"). 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, "Program" 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
-("Repository") in CVS modules ("Modules") and made available as downloadable
-archives ("Downloads").</P>
-<P>Content may be apportioned into plug-ins ("Plug-ins"), plug-in fragments
-("Fragments"), and features ("Features"). A Feature is a bundle of one or more
-Plug-ins and/or Fragments and associated material. Files named "feature.xml" may
-contain a list of the names and version numbers of the Plug-ins and/or Fragments
-associated with a Feature. Plug-ins and Fragments are located in directories
-named "plugins" and Features are located in directories named "features".</P>
-<P>Features may also include other Features ("Included Features"). Files named
-"feature.xml" may contain a list of the names and version numbers of Included
-Features.</P>
-<P>The terms and conditions governing Plug-ins and Fragments should be contained
-in files named "about.html" ("Abouts"). The terms and conditions governing
-Features and Included Features should be contained in files named "license.html"
-("Feature Licenses"). 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>Plug-in and Fragment directories
- <LI>Subdirectories of the directory named "src" of certain Plug-ins
- <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 ("Feature Update
-License") 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 "license" property of
-files named "feature.properties". 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>Apache Software License 1.1 (available at <A
- href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</A>)
-
- <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>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>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>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>Common Development and Distribution License (CDDL) Version 1.0 (available at <A
- href="http://www.sun.com/cddl/cddl.html">http://www.sun.com/cddl/cddl.html)</A>
- </LI>
- </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></BODY></HTML>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.html
deleted file mode 100644
index fe81d46ac..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.html
+++ /dev/null
@@ -1,27 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<P>June, 2008</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/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>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.</p>
-
-<h3>Source Code</h3>
-<p>This plug-in contains source code zip files (&quot;Source Zips&quot;) that correspond to binary content in other plug-ins. These Source Zips may be distributed under different license
-agreements and/or notices. Details about these license agreements and notices are contained in &quot;about.html&quot; files (&quot;Abouts&quot;) located in sub-directories in the
-src/ directory of this plug-in. Such Abouts govern your use of the Source Zips in that directory, not the EPL.</p>
-
-</body>
-</html>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.ini b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.ini
deleted file mode 100644
index 2dee36a2e..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.ini
+++ /dev/null
@@ -1,31 +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=eclipse32.gif
-
-# 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 "welcomePage" contains path to welcome page (special XML-based format)
-# optional
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-
-
-
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.mappings b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.mappings
deleted file mode 100644
index a28390a75..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/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/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.properties
deleted file mode 100644
index c315cf8ac..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/about.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be translated.
-# 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.
-#
-# Do not translate any values surrounded by {}
-
-blurb=WTP Web Page Editor Apache MyFaces Trinidad Tag Support Source\n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright Eclipse contributors and others 2007. All rights reserved.\n\
-Visit http://www.eclipse.org/webtools
-
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/build.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/build.properties
deleted file mode 100644
index 85ef5b712..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/build.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-
-bin.includes = about.html, about.ini, about.mappings, about.properties, eclipse32.gif, plugin.properties, plugin.xml, src/**, META-INF/
-sourcePlugin = true
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.gif b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.gif
deleted file mode 100644
index e6ad7ccd7..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.png b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.png
deleted file mode 100644
index 50ae49de2..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/eclipse32.png
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/plugin.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/plugin.properties
deleted file mode 100644
index 09fcddc19..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateBundle/plugin.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be translated.
-# plugin.properties
-# contains externalized strings for manifest.mf
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# fill-ins are supplied by about.mappings
-# This file should be translated.
-#
-# Do not translate any values surrounded by {}
-pluginName=WTP Web Page Editor Apache MyFaces Trinidad Tag Support Source
-providerName=Eclipse.org
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/build.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/build.properties
deleted file mode 100644
index a52b18c34..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/build.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be NOT be translated.
-bin.includes =\
-epl-v10.html,\
-eclipse_update_120.jpg,\
-feature.xml,\
-feature.properties,\
-license.html
-
-
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/eclipse_update_120.jpg b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/eclipse_update_120.jpg
deleted file mode 100644
index bfdf708ad..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/eclipse_update_120.jpg
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/epl-v10.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/epl-v10.html
deleted file mode 100644
index 022ad2955..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/epl-v10.html
+++ /dev/null
@@ -1,328 +0,0 @@
-<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=windows-1252">
-<meta name=ProgId content=Word.Document>
-<meta name=Generator content="Microsoft Word 9">
-<meta name=Originator content="Microsoft Word 9">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<!--[if gte mso 9]><xml>
- <o:DocumentProperties>
- <o:Revision>2</o:Revision>
- <o:TotalTime>3</o:TotalTime>
- <o:Created>2004-03-05T23:03:00Z</o:Created>
- <o:LastSaved>2004-03-05T23:03:00Z</o:LastSaved>
- <o:Pages>4</o:Pages>
- <o:Words>1626</o:Words>
- <o:Characters>9270</o:Characters>
- <o:Lines>77</o:Lines>
- <o:Paragraphs>18</o:Paragraphs>
- <o:CharactersWithSpaces>11384</o:CharactersWithSpaces>
- <o:Version>9.4402</o:Version>
- </o:DocumentProperties>
-</xml><![endif]--><!--[if gte mso 9]><xml>
- <w:WordDocument>
- <w:TrackRevisions/>
- </w:WordDocument>
-</xml><![endif]-->
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {font-family:Tahoma;
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-generic-font-family:swiss;
- 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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
- font-family:Tahoma;
- mso-fareast-font-family:"Times New Roman";}
-@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><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
-
-</div>
-
-</body>
-
-</html>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/feature.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/feature.properties
deleted file mode 100644
index da7c26515..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/feature.properties
+++ /dev/null
@@ -1,147 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be translated.
-# feature.properties
-# contains externalized strings for feature.xml
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file should be translated.
-#
-# Do not translate any values surrounded by {}
-#
-# "featureName" property - name of the feature
-featureName=WTP Web Page Editor Apache MyFaces Trinidad Tag Support Source
-
-# "providerName" property - name of the company that provides the feature
-providerName=Eclipse.org
-
-# "updateSiteName" property - label for the update site
-updateSiteName=The Eclipse Web Tools Platform (WTP) Project update site
-
-# "description" property - description of the feature
-description=Source code zips for WTP Web Page Editor Apache MyFaces Trinidad Tag Support.
-
-# "copyright" property - text of the "Feature Update Copyright"
-copyright=\
-2007 Oracle 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\
-\n\
-Contributors:\n\
- Oracle 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\
-June 06, 2007\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\
- - Common Development and Distribution License (CDDL) Version 1.0 (available at http://www.sun.com/cddl/cddl.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 ##########################################
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/license.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/license.html
deleted file mode 100644
index d2e5e6e59..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplateFeature/license.html
+++ /dev/null
@@ -1,82 +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>June, 2008</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&trade; 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>
- <LI>Common Development and Distribution License (CDDL) Version 1.0 (available at <A
- href="http://www.sun.com/cddl/cddl.html">http://www.sun.com/cddl/cddl.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/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.html
deleted file mode 100644
index fe81d46ac..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.html
+++ /dev/null
@@ -1,27 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<P>June, 2008</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/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>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.</p>
-
-<h3>Source Code</h3>
-<p>This plug-in contains source code zip files (&quot;Source Zips&quot;) that correspond to binary content in other plug-ins. These Source Zips may be distributed under different license
-agreements and/or notices. Details about these license agreements and notices are contained in &quot;about.html&quot; files (&quot;Abouts&quot;) located in sub-directories in the
-src/ directory of this plug-in. Such Abouts govern your use of the Source Zips in that directory, not the EPL.</p>
-
-</body>
-</html>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.ini b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.ini
deleted file mode 100644
index 2dee36a2e..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.ini
+++ /dev/null
@@ -1,31 +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=eclipse32.gif
-
-# 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 "welcomePage" contains path to welcome page (special XML-based format)
-# optional
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-
-
-
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.mappings b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.mappings
deleted file mode 100644
index a28390a75..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/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/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.properties
deleted file mode 100644
index c315cf8ac..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/about.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be translated.
-# 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.
-#
-# Do not translate any values surrounded by {}
-
-blurb=WTP Web Page Editor Apache MyFaces Trinidad Tag Support Source\n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright Eclipse contributors and others 2007. All rights reserved.\n\
-Visit http://www.eclipse.org/webtools
-
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/build.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/build.properties
deleted file mode 100644
index 85ef5b712..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/build.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-
-bin.includes = about.html, about.ini, about.mappings, about.properties, eclipse32.gif, plugin.properties, plugin.xml, src/**, META-INF/
-sourcePlugin = true
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.gif b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.gif
deleted file mode 100644
index e6ad7ccd7..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.png b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.png
deleted file mode 100644
index 50ae49de2..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/eclipse32.png
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/plugin.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/plugin.properties
deleted file mode 100644
index 09fcddc19..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature/sourceTemplatePlugin/plugin.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file should be translated.
-# plugin.properties
-# contains externalized strings for manifest.mf
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# fill-ins are supplied by about.mappings
-# This file should be translated.
-#
-# Do not translate any values surrounded by {}
-pluginName=WTP Web Page Editor Apache MyFaces Trinidad Tag Support Source
-providerName=Eclipse.org
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/.project b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/.project
deleted file mode 100644
index 8ff04216f..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.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/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/build.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/build.properties
deleted file mode 100644
index bea9927bb..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/build.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-###############################################################################
-# Copyright (c) 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-bin.includes = feature.xml,\
- eclipse_update_120.jpg,\
- epl-v10.html,\
- feature.properties,\
- license.html
-
-generate.feature@org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature.source = org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/eclipse_update_120.jpg b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/eclipse_update_120.jpg
deleted file mode 100644
index bfdf708ad..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/eclipse_update_120.jpg
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/epl-v10.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/epl-v10.html
deleted file mode 100644
index ed4b19665..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/epl-v10.html
+++ /dev/null
@@ -1,328 +0,0 @@
-<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=windows-1252">
-<meta name=ProgId content=Word.Document>
-<meta name=Generator content="Microsoft Word 9">
-<meta name=Originator content="Microsoft Word 9">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<!--[if gte mso 9]><xml>
- <o:DocumentProperties>
- <o:Revision>2</o:Revision>
- <o:TotalTime>3</o:TotalTime>
- <o:Created>2004-03-05T23:03:00Z</o:Created>
- <o:LastSaved>2004-03-05T23:03:00Z</o:LastSaved>
- <o:Pages>4</o:Pages>
- <o:Words>1626</o:Words>
- <o:Characters>9270</o:Characters>
- <o:Lines>77</o:Lines>
- <o:Paragraphs>18</o:Paragraphs>
- <o:CharactersWithSpaces>11384</o:CharactersWithSpaces>
- <o:Version>9.4402</o:Version>
- </o:DocumentProperties>
-</xml><![endif]--><!--[if gte mso 9]><xml>
- <w:WordDocument>
- <w:TrackRevisions/>
- </w:WordDocument>
-</xml><![endif]-->
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {font-family:Tahoma;
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-generic-font-family:swiss;
- 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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
- font-family:Tahoma;
- mso-fareast-font-family:"Times New Roman";}
-@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><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.properties b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.properties
deleted file mode 100644
index 7aafb97dd..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.properties
+++ /dev/null
@@ -1,144 +0,0 @@
-###############################################################################
-# Copyright (c) 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# feature.properties
-# contains externalized strings for feature.xml
-# "%foo" in feature.xml corresponds to the key "foo" in this file
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file should be translated.
-
-# "featureName" property - name of the feature
-featureName=Apache MyFaces Trinidad Tag Support (Optional) SDK
-
-# "providerName" property - name of the company that provides the feature
-providerName=Eclipse.org
-
-# "updateSiteName" property - label for the update site
-updateSiteName=The Eclipse Web Tools Platform (WTP) Project update site
-
-# "description" property - description of the feature
-description=Apache MyFaces Trinidad Tag Support (Optional) SDK
-
-# "copyright" property - text of the "Feature Update Copyright"
-feature.copyright=\
-Copyright (c) 2008 Oracle Corporation.\
-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\
-\n\
-Contributors:\n\
- Oracle 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\
-June 7, 2007\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 ##########################################
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.xml b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.xml
deleted file mode 100644
index 5ab6a1a51..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/feature.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature"
- label="%featureName"
- version="2.1.0.qualifier"
- provider-name="%providerName">
-
- <description>
- %description
- </description>
-
- <copyright>
- %copyright
- </copyright>
-
- <license url="license.html">
- %license
- </license>
-
- <url>
- <update label="%updateSiteName" url="http://download.eclipse.org/webtools/updates"/>
- <discovery label="Web Tools Platform (WTP) Updates" url="http://download.eclipse.org/webtools/updates"/>
- </url>
-
- <includes
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature"
- version="0.0.0"/>
-
- <includes
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.feature.source"
- version="0.0.0"/>
-
-</feature>
diff --git a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/license.html b/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/license.html
deleted file mode 100644
index a450af950..000000000
--- a/jsf/features/org.eclipse.jst.jsf.apache.trinidad.tagsupport_sdk.feature/license.html
+++ /dev/null
@@ -1,97 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0044)http://www.eclipse.org/legal/epl/notice.html -->
-<HTML><HEAD><TITLE>Eclipse.org Software User Agreement</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1479" name=GENERATOR></HEAD>
-<BODY lang=EN-US vLink=purple link=blue>
-<H2>Eclipse Foundation Software User Agreement</H2>
-
-<H3>Usage Of Content</H3>
-<P>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION
-AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT"). 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 ("EPL"). 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, "Program" 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
-("Repository") in CVS modules ("Modules") and made available as downloadable
-archives ("Downloads").</P>
-<P>Content may be apportioned into plug-ins ("Plug-ins"), plug-in fragments
-("Fragments"), and features ("Features"). A Feature is a bundle of one or more
-Plug-ins and/or Fragments and associated material. Files named "feature.xml" may
-contain a list of the names and version numbers of the Plug-ins and/or Fragments
-associated with a Feature. Plug-ins and Fragments are located in directories
-named "plugins" and Features are located in directories named "features".</P>
-<P>Features may also include other Features ("Included Features"). Files named
-"feature.xml" may contain a list of the names and version numbers of Included
-Features.</P>
-<P>The terms and conditions governing Plug-ins and Fragments should be contained
-in files named "about.html" ("Abouts"). The terms and conditions governing
-Features and Included Features should be contained in files named "license.html"
-("Feature Licenses"). 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>Plug-in and Fragment directories
- <LI>Subdirectories of the directory named "src" of certain Plug-ins
- <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 ("Feature Update
-License") 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 "license" property of
-files named "feature.properties". 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>Apache Software License 1.1 (available at <A
- href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</A>)
-
- <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>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>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>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>Common Development and Distribution License (CDDL) Version 1.0 (available at <A
- href="http://www.sun.com/cddl/cddl.html">http://www.sun.com/cddl/cddl.html)</A>
- </LI>
- </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></BODY></HTML>
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.cvsignore b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.cvsignore
deleted file mode 100644
index c14487cea..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-build.xml
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.project b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.project
deleted file mode 100644
index 1e4ee0039..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/.project
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.webpageeditor_sdk.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/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/build.properties b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/build.properties
deleted file mode 100644
index 9c9428501..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/build.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-bin.includes = feature.xml,\
- license.html,\
- feature.properties,\
- epl-v10.html,\
- eclipse_update_120.jpg
-
-generate.feature@org.eclipse.jst.webpageeditor.feature.source = org.eclipse.jst.webpageeditor.feature
- \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/eclipse_update_120.jpg b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/eclipse_update_120.jpg
deleted file mode 100644
index bfdf708ad..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/eclipse_update_120.jpg
+++ /dev/null
Binary files differ
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/epl-v10.html b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/epl-v10.html
deleted file mode 100644
index ed4b19665..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/epl-v10.html
+++ /dev/null
@@ -1,328 +0,0 @@
-<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=windows-1252">
-<meta name=ProgId content=Word.Document>
-<meta name=Generator content="Microsoft Word 9">
-<meta name=Originator content="Microsoft Word 9">
-<link rel=File-List
-href="./Eclipse%20EPL%202003_11_10%20Final_files/filelist.xml">
-<title>Eclipse Public License - Version 1.0</title>
-<!--[if gte mso 9]><xml>
- <o:DocumentProperties>
- <o:Revision>2</o:Revision>
- <o:TotalTime>3</o:TotalTime>
- <o:Created>2004-03-05T23:03:00Z</o:Created>
- <o:LastSaved>2004-03-05T23:03:00Z</o:LastSaved>
- <o:Pages>4</o:Pages>
- <o:Words>1626</o:Words>
- <o:Characters>9270</o:Characters>
- <o:Lines>77</o:Lines>
- <o:Paragraphs>18</o:Paragraphs>
- <o:CharactersWithSpaces>11384</o:CharactersWithSpaces>
- <o:Version>9.4402</o:Version>
- </o:DocumentProperties>
-</xml><![endif]--><!--[if gte mso 9]><xml>
- <w:WordDocument>
- <w:TrackRevisions/>
- </w:WordDocument>
-</xml><![endif]-->
-<style>
-<!--
- /* Font Definitions */
-@font-face
- {font-family:Tahoma;
- panose-1:2 11 6 4 3 5 4 4 2 4;
- mso-font-charset:0;
- mso-generic-font-family:swiss;
- 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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-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;
- font-family:"Times New Roman";
- mso-fareast-font-family:"Times New Roman";}
-p.BalloonText, li.BalloonText, div.BalloonText
- {mso-style-name:"Balloon Text";
- margin:0in;
- margin-bottom:.0001pt;
- mso-pagination:widow-orphan;
- font-size:8.0pt;
- font-family:Tahoma;
- mso-fareast-font-family:"Times New Roman";}
-@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><![if !supportEmptyParas]>&nbsp;<![endif]><o:p></o:p></p>
-
-</div>
-
-</body>
-
-</html> \ No newline at end of file
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.properties b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.properties
deleted file mode 100644
index 4686754ac..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.properties
+++ /dev/null
@@ -1,144 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2007 Oracle 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:
-# Gerry Kessler - initial API and implementation
-###############################################################################
-# feature.properties
-# contains externalized strings for feature.xml
-# "%foo" in feature.xml corresponds to the key "foo" in this file
-# java.io.Properties file (ISO 8859-1 with "\" escapes)
-# This file should be translated.
-
-# "featureName" property - name of the feature
-featureName=Web Page Editor (Optional) SDK
-
-# "providerName" property - name of the company that provides the feature
-providerName=Eclipse.org
-
-# "updateSiteName" property - label for the update site
-updateSiteName=The Eclipse Web Tools Platform (WTP) Project update site
-
-# "description" property - description of the feature
-description=Web Page Editor (Optional) SDK
-
-# "copyright" property - text of the "Feature Update Copyright"
-feature.copyright=\
-Copyright (c) 2007 Oracle Corporation.\
-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\
-\n\
-Contributors:\n\
- Oracle 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\
-June 7, 2007\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 ##########################################
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.xml b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.xml
deleted file mode 100644
index 735ccf8bc..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/feature.xml
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
- id="org.eclipse.jst.webpageeditor_sdk.feature"
- label="%featureName"
- version="2.1.0.qualifier"
- provider-name="%providerName">
-
- <description>
- %description
- </description>
-
- <copyright>
- %copyright
- </copyright>
-
- <license url="license.html">
- %license
- </license>
-
- <url>
- <update label="%updateSiteName" url="http://download.eclipse.org/webtools/updates"/>
- <discovery label="Web Tools Platform (WTP) Updates" url="http://download.eclipse.org/webtools/updates"/>
- </url>
-
- <includes
- id="org.eclipse.jst.webpageeditor.feature"
- version="0.0.0"/>
-
- <includes
- id="org.eclipse.jst.webpageeditor.feature.source"
- version="0.0.0"/>
-
-</feature>
diff --git a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/license.html b/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/license.html
deleted file mode 100644
index a450af950..000000000
--- a/jsf/features/org.eclipse.jst.webpageeditor_sdk.feature/license.html
+++ /dev/null
@@ -1,97 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
-<!-- saved from url=(0044)http://www.eclipse.org/legal/epl/notice.html -->
-<HTML><HEAD><TITLE>Eclipse.org Software User Agreement</TITLE>
-<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
-<META content="MSHTML 6.00.2800.1479" name=GENERATOR></HEAD>
-<BODY lang=EN-US vLink=purple link=blue>
-<H2>Eclipse Foundation Software User Agreement</H2>
-
-<H3>Usage Of Content</H3>
-<P>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION
-AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT"). 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 ("EPL"). 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, "Program" 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
-("Repository") in CVS modules ("Modules") and made available as downloadable
-archives ("Downloads").</P>
-<P>Content may be apportioned into plug-ins ("Plug-ins"), plug-in fragments
-("Fragments"), and features ("Features"). A Feature is a bundle of one or more
-Plug-ins and/or Fragments and associated material. Files named "feature.xml" may
-contain a list of the names and version numbers of the Plug-ins and/or Fragments
-associated with a Feature. Plug-ins and Fragments are located in directories
-named "plugins" and Features are located in directories named "features".</P>
-<P>Features may also include other Features ("Included Features"). Files named
-"feature.xml" may contain a list of the names and version numbers of Included
-Features.</P>
-<P>The terms and conditions governing Plug-ins and Fragments should be contained
-in files named "about.html" ("Abouts"). The terms and conditions governing
-Features and Included Features should be contained in files named "license.html"
-("Feature Licenses"). 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>Plug-in and Fragment directories
- <LI>Subdirectories of the directory named "src" of certain Plug-ins
- <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 ("Feature Update
-License") 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 "license" property of
-files named "feature.properties". 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>Apache Software License 1.1 (available at <A
- href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</A>)
-
- <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>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>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>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>Common Development and Distribution License (CDDL) Version 1.0 (available at <A
- href="http://www.sun.com/cddl/cddl.html">http://www.sun.com/cddl/cddl.html)</A>
- </LI>
- </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></BODY></HTML>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.classpath b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.cvsignore
deleted file mode 100644
index 6577ed96c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-javaCompiler...args
-build.xml
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.project b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.project
deleted file mode 100644
index a17f88176..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.apache.trinidad.tagsupport</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/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index bff17373c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,65 +0,0 @@
-#Mon Jun 30 15:50:06 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-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=error
-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.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 12f045f8d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 12:01:04 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/META-INF/MANIFEST.MF
deleted file mode 100644
index bced9d020..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,26 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jst.jsf.apache.trinidad.tagsupport;singleton:=true
-Bundle-Version: 1.0.101.qualifier
-Bundle-Localization: plugin
-Bundle-Activator: org.eclipse.jst.jsf.apache.trinidad.tagsupport.TrinidadTagSupportActivator
-Bundle-Vendor: %pluginProvider
-Require-Bundle: org.eclipse.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.emf.ecore.xmi;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.gef;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.sse.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.jst.pagedesigner;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.jst.jsf.core;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.jdt.core;bundle-version="[3.4.0,4.0.0)",
- org.eclipse.core.resources;bundle-version="[3.4.0,4.0.0)",
- org.eclipse.jst.jsf.common.ui;bundle-version="[1.1.0,1.2.0)"
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
-Bundle-ActivationPolicy: lazy
-Export-Package: org.eclipse.jst.jsf.apache.trinidad.tagsupport;x-internal:=true,
- org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;x-internal:=true,
- org.eclipse.jst.jsf.apache.trinidad.tagsupport.el;x-internal:=true,
- org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;x-internal:=true,
- org.eclipse.jst.jsf.apache.trinidad.tagsupport.model;x-internal:=true
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/about.html b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/about.html
deleted file mode 100644
index 8e5605900..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/build.properties b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/build.properties
deleted file mode 100644
index aa99bac66..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/build.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- metadata/,\
- plugin.properties,\
- about.html,\
- icons/
-javacSource=1.5
-javacTarget=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chart.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chart.gif
deleted file mode 100644
index 08a36db67..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chart.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseColor.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseColor.gif
deleted file mode 100644
index d20f760b3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseColor.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseDate.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseDate.gif
deleted file mode 100644
index ca3b962ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/large/chooseDate.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/chart.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/chart.gif
deleted file mode 100644
index d37d0d324..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/chart.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputColor.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputColor.gif
deleted file mode 100644
index eb59712d8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputColor.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputDate.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputDate.gif
deleted file mode 100644
index df5eceb23..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputDate.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputListOfValues.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputListOfValues.gif
deleted file mode 100644
index 890e68e0b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputListOfValues.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputNumberSpinbox.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputNumberSpinbox.gif
deleted file mode 100644
index 2504705a5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/icon_inputNumberSpinbox.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/importScript.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/importScript.gif
deleted file mode 100644
index 7478ce7ef..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/importScript.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/inputHidden.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/inputHidden.gif
deleted file mode 100644
index f18865b9a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/inputHidden.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/message.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/message.gif
deleted file mode 100644
index 7d0c261e2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/message.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/messages.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/messages.gif
deleted file mode 100644
index 6f43980a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/messages.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/poll.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/poll.gif
deleted file mode 100644
index 35ba6f463..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/poll.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/selectItem.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/selectItem.gif
deleted file mode 100644
index 247efe030..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/selectItem.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/spacer.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/spacer.gif
deleted file mode 100644
index 3c1b4b470..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/spacer.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/styleSheet.gif b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/styleSheet.gif
deleted file mode 100644
index d8fde0054..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/icons/small/styleSheet.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.properties b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.properties
deleted file mode 100644
index 56cc50201..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-property.category.event=Event
-property.category.core=Core
-property.category.css=CSS
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.xml
deleted file mode 100644
index 0bb2dd10b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad.xml
+++ /dev/null
@@ -1,4192 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel id="http://myfaces.apache.org/trinidad" type="tagFile"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:qe="http://org.eclipse.jsf.pagedesigner/QuickEditTabSections.ecore"
- xmlns:cnst="http://org.eclipse.jst.jsf.core/constraints.ecore"
- >
- <entity id="forEach" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="items"/>
- <section id="var"/>
- <section id="begin"/>
- <section id="end"/>
- <section id="step"/>
- </value>
- </trait>
- <entity id="items"/>
- <entity id="var"/>
- <entity id="varStatus"/>
- <entity id="begin">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="end">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="step">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="setActionListener" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="to"/>
- <section id="from"/>
- </value>
- </trait>
- <entity id="to"/>
- <entity id="from"/>
- </entity>
- <entity id="fileDownloadActionListener" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="method"/>
- <section id="filename"/>
- <section id="contentType"/>
- </value>
- </trait>
- <entity id="contentType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ContentType</value>
- </trait>
- </entity>
- <entity id="filename"/>
- <entity id="method">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>javax.faces.context.FacesContext</item>
- <item>java.io.OutputStream</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="returnActionListener" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="value"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="resetActionListener" type="tag"/>
- <entity id="componentRef" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="componentType"/>
- </value>
- </trait>
- <entity id="componentType"/>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="rendered">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="componentDef" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="var"/>
- </value>
- </trait>
- <entity id="var">
- <trait id="contributes-value-binding">
- <value>true</value>
- </trait>
- <trait id="value-binding-scope">
- <value>request</value>
- </trait>
- <trait id="value-binding-symbol-factory">
- <value>org.eclipse.jst.jsf.common.unknownTypeSymbolFactory</value>
- </trait>
- </entity>
- </entity>
- <entity id="facetRef" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="facetName"/>
- </value>
- </trait>
- <entity id="facetName"/>
- </entity>
- <entity id="breadCrumbs" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="orientation"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="orientation">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>horizontal</item>
- <item>vertical</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="chart" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="type"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.ChartModel</value>
- </trait>
- </entity>
- <entity id="chartDrillDownListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.ChartDrillDownEvent</value>
- </trait>
- </entity>
- <entity id="type">
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>verticalBar</item>
- <item>horizontalBar</item>
- <item>stackedVerticalBar</item>
- <item>stackedHorizontalBar</item>
- <item>pie</item>
- <item>area</item>
- <item>stackedArea</item>
- <item>line</item>
- <item>barLine</item>
- <item>XYLine</item>
- <item>scatterPlot</item>
- <item>radar</item>
- <item>radarArea</item>
- <item>funnel</item>
- <item>circularGauge</item>
- <item>semiCircularGauge</item>
- </value>
- </trait>
- </entity>
- <entity id="templateSource"/>
- <entity id="perspective">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="legendPosition">
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>bottom</item>
- <item>top</item>
- <item>start</item>
- </value>
- </trait>
- </entity>
- <entity id="animationDuration">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="YMajorGridLineCount">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="YMinorGridLineCount">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="XMajorGridLineCount">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maxPrecision">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="gradientsUsed">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="tooltipsVisible">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="chooseColor" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="colorData"/>
- </value>
- </trait>
- <entity id="colorData"/>
- <entity id="customColorData"/>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- </entity>
- <entity id="chooseDate" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="shortDesc"/>
- </value>
- </trait>
- <entity id="minValue"/>
- <entity id="maxValue"/>
- </entity>
- <entity id="column" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>header</item>
- <item>footer</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="sortable"/>
- <section id="align"/>
- <section id="separateRows"/>
- <section id="headerNoWrap"/>
- </value>
- </trait>
- <entity id="sortProperty"/>
- <entity id="align">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>left</item>
- <item>center</item>
- <item>right</item>
- </value>
- </trait>
- </entity>
- <entity id="defaultSortOrder">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>ascending</item>
- <item>descending</item>
- </value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="headerText"/>
- <entity id="noWrap">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="headerNoWrap">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="sortable">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
-
- <entity id="separateRows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rowHeader"/>
- </entity>
- <entity id="commandButton" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-command-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="action"/>
- <section id="accessKey"/>
- <section id="immediate"/>
- </value>
- </trait>
- <entity id="blocking">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="icon"/>
-
- </entity>
- <entity id="commandLink" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-command-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="action"/>
- <section id="immediate"/>
- </value>
- </trait>
- <entity id="blocking">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="commandNavigationItem" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-command-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="action"/>
- <section id="immediate"/>
- </value>
- </trait>
- <entity id="destination"/>
- <entity id="icon"/>
- <entity id="selected">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="visited">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="targetFrame"/>
- </entity>
- <entity id="document" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>metaContainer</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="mode"/>
- <section id="initialFocusId"/>
- </value>
- </trait>
- <entity id="title">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- </entity>
- <entity id="mode">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>strict</item>
- <item>quirks</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- <entity id="onload">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onunload">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="initialFocusId"/>
- </entity>
- <entity id="form" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="defaultCommand"/>
- </value>
- </trait>
- <entity id="targetFrame"/>
- <entity id="usesUpload">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="defaultCommand"/>
- <entity id="onsubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- </entity>
- <entity id="goButton" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="textAndAccessKey"/>
- <section id="destination"/>
- </value>
- </trait>
- <entity id="destination"/>
- <entity id="text"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="textAndAccessKey"/>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="targetFrame"/>
- <entity id="icon"/>
- </entity>
- <entity id="goLink" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="textAndAccessKey"/>
- <section id="destination"/>
- </value>
- </trait>
- <entity id="destination"/>
- <entity id="text"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="textAndAccessKey"/>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="targetFrame"/>
- </entity>
- <entity id="icon" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="name"/>
- </value>
- </trait>
- <entity id="name"/>
- </entity>
- <entity id="image" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="source"/>
- <section id="shortDesc"/>
- </value>
- </trait>
- <entity id="source"/>
- <entity id="longDescURL"/>
- <entity id="imageMapType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>server</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="importScript" type="tag">
- <include-entity-group id="common-trinidad-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="names"/>
- </value>
- </trait>
- <entity id="names"/>
- </entity>
- <entity id="inputColor" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- </value>
- </trait>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="returnListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.ReturnEvent</value>
- </trait>
- </entity>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="compact">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="chooseId">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputDate" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- </value>
- </trait>
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="returnListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.ReturnEvent</value>
- </trait>
- </entity>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="chooseId"/>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maximumLength">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputFile" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- </value>
- </trait>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputHidden" type="tag">
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- </value>
- </trait>
- </entity>
- <entity id="inputListOfValues" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="action"/>
- <section id="searchDesc"/>
- <section id="columns"/>
- </value>
- </trait>
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="returnListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.ReturnEvent</value>
- </trait>
- </entity>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="searchDesc"/>
- <entity id="icon"/>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maximumLength">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="windowWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="windowHeight">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputNumberSpinbox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="minimum"/>
- <section id="maximum"/>
- <section id="stepSize"/>
- <section id="onclick"/>
- </value>
- </trait>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="stepSize">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="styleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>AFFieldTextMarker</item>
- <item>AFFieldTextLTRMarker</item>
- <item>AFFieldNumberMarker</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="inputText" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="showRequired"/>
- <section id="secret"/>
- <section id="autoSubmit"/>
- <section id="immediate"/>
- </value>
- </trait>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- <entity id="wrap">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>off</item>
- <item>soft</item>
- <item>hard</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>soft</value>
- </trait>
- </entity>
- <entity id="secret">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maximumLength">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="styleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>AFDataText</item>
- <item>AFFieldTextMarker</item>
- <item>AFFieldTextLTRMarker</item>
- <item>AFPhoneFieldTextMarker</item>
- <item>AFPostalCodeFieldTextMarker</item>
- <item>AFAddressFieldTextMarker</item>
- <item>AFFieldNumberMarker</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="legend" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="name"/>
- </value>
- </trait>
- <entity id="name">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>required</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>required</value>
- </trait>
- </entity>
- </entity>
- <entity id="media" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="source"/>
- <section id="shortDesc"/>
- <section id="innerWidth"/>
- <section id="innerHeight"/>
- <section id="autoStart"/>
- <section id="controls"/>
- <section id="player"/>
- </value>
- </trait>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="innerWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="innerHeight">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="source"/>
- <entity id="autostart">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="playCount">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="contentType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ContentType</value>
- </trait>
- </entity>
- <entity id="standbyText"/>
- <entity id="player">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>windows</item>
- <item>quicktime</item>
- <item>link</item>
- <item>real</item>
- </value>
- </trait>
- </entity>
- <entity id="controls">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>noneVisible</item>
- <item>minimal</item>
- <item>typical</item>
- <item>all</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>typical</value>
- </trait>
- </entity>
- </entity>
- <entity id="message" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="for"/>
- <section id="binding"/>
- <section id="messageType"/>
- <section id="inlineStyle"/>
- </value>
- </trait>
- <entity id="for"/>
- <entity id="message"/>
- <entity id="messageType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>info</item>
- <item>confirmation</item>
- <item>warning</item>
- <item>none</item>
- <item>error</item>
- </value>
- </trait>
- </entity>
-
- </entity>
- <entity id="messages" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="inlineStyle"/>
- <section id="layout"/>
- </value>
- </trait>
- <entity id="message"/>
- <entity id="text"/>
- <entity id="globalOnly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="navigationPane" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="hint"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="level">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="hint">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>bar</item>
- <item>buttons</item>
- <item>choice</item>
- <item>list</item>
- <item>tabs</item>
- </value>
- </trait>
- </entity>
- <entity id="title"/>
- </entity>
- <entity id="navigationTree" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="rowDisclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RowDisclosureEvent</value>
- </trait>
- </entity>
- <entity id="disclosedRowKeys"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="startLevel">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="outputDocument" type="tag">
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- </value>
- </trait>
- <entity id="titleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- </entity>
- <entity id="separatorClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- </entity>
- </entity>
- <entity id="outputFormatted" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="styleUsage"/>
- </value>
- </trait>
- <entity id="styleUsage">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>pageStamp</item>
- <item>instruction</item>
- <item>inContextBranding</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- </entity>
- <entity id="outputLabel" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="for"/>
- </value>
- </trait>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="showRequired">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="valueAndAccessKey"/>
- <entity id="for"/>
- </entity>
- <entity id="outputText" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- </value>
- </trait>
- <entity id="truncateAt"/>
- <entity id="description"/>
- <entity id="escape">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="page" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>actions</item>
- <item>appAbout</item>
- <item>appCopyright</item>
- <item>appPrivacy</item>
- <item>branding</item>
- <item>brandingApp</item>
- <item>brandingAppContextual</item>
- <item>contextSwitcher</item>
- <item>infoFootnote</item>
- <item>infoReturn</item>
- <item>infoStatus</item>
- <item>infoSupplemental</item>
- <item>infoUser</item>
- <item>location</item>
- <item>menuSwitch</item>
- <item>messages</item>
- <item>nodeStamp</item>
- <item>search</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="rowDisclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RowDisclosureEvent</value>
- </trait>
- </entity>
- <entity id="disclosedRowKeys"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="chromeType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>compact</item>
- <item>expanded</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="panelAccordion" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="discloseNone"/>
- <section id="discloseMany"/>
- </value>
- </trait>
- <entity id="discloseNone">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="discloseMany">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelBorderLayout" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>bottom</item>
- <item>end</item>
- <item>innerBottom</item>
- <item>innerEnd</item>
- <item>innerLeft</item>
- <item>innerRight</item>
- <item>innerStart</item>
- <item>innerTop</item>
- <item>left</item>
- <item>right</item>
- <item>start</item>
- <item>top</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="panelBox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="background"/>
- </value>
- </trait>
- <entity id="text"/>
- <entity id="background">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>light</item>
- <item>medium</item>
- <item>dark</item>
- <item>transparent</item>
- </value>
- </trait>
- </entity>
- <entity id="icon"/>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelButtonBar" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="halign"/>
- </value>
- </trait>
- <entity id="halign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="panelCaptionGroup" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>caption</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="captionText"/>
- </value>
- </trait>
- <entity id="captionText"/>
- </entity>
- <entity id="panelChoice" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="label"/>
- <section id="labelAndAccessKey"/>
- <section id="position"/>
- </value>
- </trait>
- <entity id="label"/>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="labelAndAccessKey"/>
- <entity id="position">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>start</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>start</value>
- </trait>
- </entity>
- <entity id="alignment">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>bottom</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>center</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelFormLayout" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>footer</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="labelWidth"/>
- <section id="fieldWidth"/>
- <section id="rows"/>
- </value>
- </trait>
- <entity id="fieldWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="labelWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="maxColumns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelGroupLayout" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>separator</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="layout"/>
- </value>
- </trait>
- <entity id="layout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>horizontal</item>
- <item>vertical</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="panelHeader" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- </value>
- </trait>
- <entity id="text"/>
- <entity id="icon"/>
- <entity id="messageType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>info</item>
- <item>confirmation</item>
- <item>warning</item>
- <item>none</item>
- <item>error</item>
- </value>
- </trait>
- </entity>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="default-value">
- <value>-1</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelHorizontalLayout" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>separator</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="halign"/>
- <section id="valign"/>
- </value>
- </trait>
- <entity id="valign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>middle</item>
- <item>bottom</item>
- <item>baseline</item>
- </value>
- </trait>
- </entity>
- <entity id="halign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="panelLabelAndMessage" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>end</item>
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="for"/>
- <section id="label"/>
- <section id="message"/>
- </value>
- </trait>
- <entity id="showRequired">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="label"/>
- <entity id="labelStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- </entity>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="labelAndAccessKey"/>
- <entity id="for"/>
- </entity>
- <entity id="panelList" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="rows"/>
- <section id="maxColumns"/>
- </value>
- </trait>
- <entity id="listStyle"/>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="maxColumns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelPage" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>appAbout</item>
- <item>appCopyright</item>
- <item>appPrivacy</item>
- <item>auxiliary1</item>
- <item>auxiliary2</item>
- <item>auxiliaryGlobal</item>
- <item>branding</item>
- <item>contextGlobal</item>
- <item>contextLocal</item>
- <item>infoFootnote</item>
- <item>infoReturn</item>
- <item>infoStatus</item>
- <item>infoUser</item>
- <item>location</item>
- <item>navigation1</item>
- <item>navigation2</item>
- <item>navigation3</item>
- <item>navigationGlobal</item>
- <item>search</item>
- <item>toolbar1</item>
- <item>toolbar2</item>
- <item>toolbarGlobal</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- <entity id="auxiliary1Size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="auxiliary2Size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="auxiliaryGlobalSize">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelPageHeader" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>branding</item>
- <item>brandingApp</item>
- <item>brandingAppContextual</item>
- <item>menuSwitch</item>
- <item>navigation1</item>
- <item>navigation2</item>
- <item>navigationGlobal</item>
- <item>search</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="chromeType"/>
- </value>
- </trait>
- <entity id="chromeType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>compact</item>
- <item>expanded</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="panelPopup" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>trigger</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="triggerType"/>
- <section id="position"/>
- <section id="modal"/>
- <section id="height"/>
- <section id="width"/>
- </value>
- </trait>
- <entity id="triggerType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>click</item>
- <item>hover</item>
- </value>
- </trait>
- </entity>
- <entity id="icon"/>
- <entity id="text"/>
- <entity id="title"/>
- <entity id="modal">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="position">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>relative</item>
- <item>centered</item>
- </value>
- </trait>
- </entity>
- <entity id="xoffset">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="yoffset">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelRadio" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="label"/>
- <section id="alignment"/>
- <section id="position"/>
- </value>
- </trait>
- <entity id="position">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>start</item>
- </value>
- </trait>
- </entity>
- <entity id="alignment">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>bottom</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>center</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelSideBar" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>filter</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="width"/>
- </value>
- </trait>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelTabbed" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="position"/>
- </value>
- </trait>
- <entity id="position">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>above</item>
- <item>below</item>
- <item>both</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>both</value>
- </trait>
- </entity>
- </entity>
- <entity id="panelTip" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="poll" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="interval"/>
- <section id="pollListener"/>
- </value>
- </trait>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="pollListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.PollEvent</value>
- </trait>
- </entity>
- <entity id="interval">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="value-minimum">
- <value>1</value>
- </trait>
- </entity>
- </entity>
- <entity id="processChoiceBar" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- <section id="shortDesc"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- </entity>
- <entity id="progressIndicator" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="action"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.BoundedRangeModel</value>
- </trait>
- </entity>
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="resetButton" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="accessKey"/>
- <section id="disabled"/>
- </value>
- </trait>
- <entity id="text"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="textAndAccessKey"/>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectBooleanCheckbox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="text"/>
- <section id="label"/>
- </value>
- </trait>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <entity id="selected">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectBooleanRadio" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="text"/>
- <section id="label"/>
- <section id="selected"/>
- <section id="group"/>
- </value>
- </trait>
- <entity id="selected">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="group"/>
- </entity>
- <entity id="selectItem" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.Object</value>
- </trait>
- </entity>
- <entity id="label"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="longDesc"/>
- <entity id="shortDesc"/>
- </entity>
- <entity id="selectManyCheckbox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- <entity id="layout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>horizontal</item>
- <item>vertical</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="selectManyListbox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectManyShuttle" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>filter</item>
- <item>leadingFooter</item>
- <item>trailingFooter</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="leadingHeader"/>
- <section id="trailingHeader"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>10</value>
- </trait>
- <trait id="valid-maximum">
- <value>20</value>
- </trait>
- </entity>
- <entity id="leadingHeader"/>
- <entity id="trailingHeader"/>
- <entity id="leadingDescShown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="trailingDescShown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectOneChoice" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="label"/>
- <section id="unselectedLabel"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- </entity>
- <entity id="selectOneListbox" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="label"/>
- <section id="unselectedLabel"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- </entity>
- <entity id="selectOneRadio" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-text-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>help</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="label"/>
- <section id="unselectedLabel"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
- <entity id="layout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>horizontal</item>
- <item>vertical</item>
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="selectOrderShuttle" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-value-holder-attributes"/>
- <include-entity-group id="common-input-tag-attributes"/>
- <include-entity-group id="common-select-tag-attributes"/>
- <include-entity-group id="common-label-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>filter</item>
- <item>leadingFooter</item>
- <item>trailingFooter</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="leadingHeader"/>
- <section id="trailingHeader"/>
- <section id="valueChangeListener"/>
- </value>
- </trait>
-
- <entity id="reorderOnly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="leadingHeader"/>
- <entity id="trailingHeader"/>
- <entity id="leadingDescShown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="trailingDescShown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectRangeChoiceBar" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>rangeLabel</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="label"/>
- <section id="first"/>
- <section id="rows"/>
- <section id="var"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rangeChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.event.RangeChangeEvent</item>
- </value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.Object</value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="first">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- </entity>
- <entity id="separator" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="showDetail" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-show-tag-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>prompt</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="disclosedText"/>
- <section id="undisclosedText"/>
- <section id="discloseListener"/>
- <section id="partialTriggers"/>
- </value>
- </trait>
- <entity id="disclosedText"/>
- <entity id="undisclosedText"/>
- </entity>
- <entity id="showDetailHeader" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-show-tag-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="discloseListener"/>
- <section id="partialTriggers"/>
- </value>
- </trait>
- <entity id="text"/>
- <entity id="icon"/>
- <entity id="messageType">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>info</item>
- <item>confirmation</item>
- <item>warning</item>
- <item>none</item>
- <item>error</item>
- </value>
- </trait>
- </entity>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="showDetailItem" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-show-tag-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="text"/>
- <section id="textAndAccessKey"/>
- <section id="disclosed"/>
- <section id="disabled"/>
- </value>
- </trait>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>toolbar</item>
- </value>
- </trait> -->
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="text">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- </entity>
- <entity id="textAndAccessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- </entity>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="flex">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="singleStepButtonBar" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="selectedStep"/>
- <section id="maxStep"/>
- <section id="nextAction"/>
- <section id="previousAction"/>
- </value>
- </trait>
- <entity id="selectedStep">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- <entity id="maxStep">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="previousActionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="nextActionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="nextAction">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="previousAction">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="text"/>
- </entity>
- <entity id="spacer" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="height"/>
- <section id="width"/>
- </value>
- </trait>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- </entity>
- <entity id="statusIndicator" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>busy</item>
- <item>ready</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="subform" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="default"/>
- </value>
- </trait>
- <entity id="default">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="switcher" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="defaultFacet"/>
- <section id="facetName"/>
- </value>
- </trait>
- <entity id="defaultFacet"/>
- <entity id="facetName"/>
- </entity>
- <entity id="table" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>actions</item>
- <item>detailStamp</item>
- <item>footer</item>
- <item>header</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- <section id="rows"/>
- <section id="rowBandingInterval"/>
- <section id="emptyText"/>
- <section id="summary"/>
- <section id="allDetailsEnabled"/>
- </value>
- </trait>
- <entity id="var">
- <trait id="contributes-value-binding">
- <value>true</value>
- </trait>
- <trait id="value-binding-scope">
- <value>request</value>
- </trait>
- <trait id="value-binding-symbol-factory">
- <value>org.eclipse.jst.jsf.common.unknownTypeSymbolFactory</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MultiSignatureValueBindingType</value>
- </trait>
- <trait id="runtime-return-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.model.CollectionModel</item>
- <item>java.util.List</item>
- <item>java.util.Set</item>
- <item>java.util.Map</item>
- <item>javax.faces.model.DataModel</item>
- <item>java.lang.Object[]</item>
- </value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="first">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="rowDisclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RowDisclosureEvent</value>
- </trait>
- </entity>
- <entity id="disclosedRowKeys"/>
- <entity id="selectionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.SelectionEvent</value>
- </trait>
- </entity>
- <entity id="selectedRowKeys"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="sortListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.SortEvent</value>
- </trait>
- </entity>
- <entity id="rangeChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RangeChangeEvent</value>
- </trait>
- </entity>
- <entity id="horizontalGridVisible">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="verticalGridVisible">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="emptyText"/>
- <entity id="columnBandingInterval">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="rowBandingInterval">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="rowSelection">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>single</item>
- <item>multiple</item>
- </value>
- </trait>
- </entity>
- <entity id="autoSubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="summary"/>
- <entity id="allDetailsEnabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="train" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.MenuModel</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- </entity>
- <entity id="tree" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>nodeStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- <section id="initiallyExpanded"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="selectedRowKeys"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rowDisclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RowDisclosureEvent</value>
- </trait>
- </entity>
- <entity id="disclosedRowKeys"/>
- <entity id="selectionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.SelectionEvent</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.TreeModel</value>
- </trait>
- </entity>
- <entity id="focusRowKey"/>
- <entity id="focusListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.FocusEvent</value>
- </trait>
- </entity>
- <entity id="initiallyExpanded">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="treeTable" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-trinidad-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <!-- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>actions</item>
- <item>footer</item>
- <item>header</item>
- <item>nodeStamp</item>
- <item>pathStamp</item>
- </value>
- </trait> -->
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="summary"/>
- <section id="emptyText"/>
- <section id="rowByDepth"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="selectedRowKeys"/>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rowDisclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.RowDisclosureEvent</value>
- </trait>
- </entity>
- <entity id="disclosedRowKeys"/>
- <entity id="selectionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.SelectionEvent</value>
- </trait>
- </entity>
- <entity id="varStatus"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>org.apache.myfaces.trinidad.model.TreeModel</value>
- </trait>
- </entity>
- <entity id="focusRowKey"/>
- <entity id="focusListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.FocusEvent</value>
- </trait>
- </entity>
- <entity id="initiallyExpanded">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rootNodeRendered">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rowsByDepth"/>
- <entity id="rangeChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.event.RangeChangeEvent</item>
- </value>
- </trait>
- </entity>
- <entity id="horizontalGridVisible">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="verticalGridVisible">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="emptyText"/>
- <entity id="columnBandingInterval">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="rowBandingInterval">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="rowSelection">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>single</item>
- <item>multiple</item>
- </value>
- </trait>
- </entity>
- <entity id="autoSubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="summary"/>
- <entity id="expandAllEnabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="group" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="iterator" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="value"/>
- <section id="var"/>
- <section id="varStat"/>
- <section id="first"/>
- <section id="rows"/>
- </value>
- </trait>
- <entity id="var"/>
- <entity id="varStatus"/>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MultiSignatureValueBindingType</value>
- </trait>
- <trait id="runtime-return-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.model.CollectionModel</item>
- <item>java.util.List</item>
- <item>java.util.Set</item>
- <item>java.util.Map</item>
- <item>javax.faces.model.DataModel</item>
- <item>java.lang.Object[]</item>
- </value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- <entity id="first">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- </entity>
- </entity>
- <entity id="convertColor" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="patterns"/>
- <section id="messageDetailConvert"/>
- <section id="transparentAllowed"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="patterns"/>
- <entity id="transparentAllowed">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="messageDetailConvert"/>
- </entity>
- <entity id="convertDateTime" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="section.general.convertDateTime" type="SECTION"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="messageDetailConvertDate"/>
- <entity id="messageDetailConvertTime"/>
- <entity id="messageDetailConvertBoth"/>
- <entity id="dateStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>short</item>
- <item>medium</item>
- <item>long</item>
- <item>full</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- <entity id="locale">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LocaleType</value>
- </trait>
- </entity>
- <entity id="pattern">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.DateTimePatternType</value>
- </trait>
- </entity>
- <entity id="secondaryPattern">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.DateTimePatternType</value>
- </trait>
- </entity>
- <entity id="timeStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>short</item>
- <item>medium</item>
- <item>long</item>
- <item>full</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- <entity id="timeZone"/>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>date</item>
- <item>time</item>
- <item>both</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>both</value>
- </trait>
- </entity>
- </entity>
- <entity id="convertNumber" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="section.general.convertNumber" type="SECTION"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="currencyCode">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.CurrencyCodeType
- </value>
- </trait>
- </entity>
- <entity id="messageDetailConvertCurrency"/>
- <entity id="messageDetailConvertNumber"/>
- <entity id="messageDetailConvertPattern"/>
- <entity id="messageDetailConvertPercent"/>
- <entity id="currencySymbol"/>
- <entity id="groupingUsed">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>true</value>
- </trait>
- </entity>
- <entity id="integerOnly">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- </entity>
- <entity id="locale">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LocaleType
- </value>
- </trait>
- </entity>
- <entity id="maxFractionDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="maxIntegerDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="minFractionDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="minIntegerDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="pattern">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.NumberPatternType</value>
- </trait>
- </entity>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>number</item>
- <item>currency</item>
- <item>percentage</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>number</value>
- </trait>
- </entity>
- </entity>
- <entity id="validateByteLength" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="maximum"/>
- <section id="messageDetailMaximum"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- <entity id="encoding"/>
- <entity id="messageDetailMaximum"/>
- </entity>
- <entity id="validateDateRestriction" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="invalidMonths"/>
- <entity id="invalidDaysOfWeek"/>
- <entity id="invalidDays"/>
- <entity id="messageDetailInvalidMonths"/>
- <entity id="messageDetailInvalidDaysOfWeek"/>
- <entity id="messageDetailInvalidDays"/>
- </entity>
- <entity id="validateDateTimeRange" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="minimum"/>
- <section id="messageDetailMinimum"/>
- <section id="maximum"/>
- <section id="messageDetailMaximum"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="maximum"/>
- <entity id="minimum"/>
- <entity id="messageDetailMaximum"/>
- <entity id="messageDetailMinimum"/>
- <entity id="messageDetailNotInRange"/>
- </entity>
- <entity id="validateDoubleRange" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="minimum"/>
- <section id="messageDetailMinimum"/>
- <section id="maximum"/>
- <section id="messageDetailMaximum"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.DoubleType</value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.DoubleType</value>
- </trait>
- </entity>
- <entity id="messageDetailMaximum"/>
- <entity id="messageDetailMinimum"/>
- <entity id="messageDetailNotInRange"/>
- </entity>
- <entity id="validateLength" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="minimum"/>
- <section id="messageDetailMinimum"/>
- <section id="maximum"/>
- <section id="messageDetailMaximum"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="messageDetailMaximum"/>
- <entity id="messageDetailMinimum"/>
- <entity id="messageDetailNotInRange"/>
- <entity id="messageDetailExact"/>
- </entity>
- <entity id="validateLongRange" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="minimum"/>
- <section id="messageDetailMinimum"/>
- <section id="maximum"/>
- <section id="messageDetailMaximum"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LongType</value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LongType</value>
- </trait>
- </entity>
- <entity id="messageDetailMaximum"/>
- <entity id="messageDetailMinimum"/>
- <entity id="messageDetailNotInRange"/>
- </entity>
- <entity id="validateRegExp" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="pattern"/>
- <section id="messageDetailNoMatch"/>
- </value>
- </trait>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- </entity>
- <entity id="pattern"/>
- <entity id="messageDetailNoMatch"/>
- </entity>
- <entityGroup id="common-core-attributes">
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="rendered">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="binding">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>javax.faces.component.UIComponent</value>
- </trait><trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="attributeChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.event.AttributeChangeEvent</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-trinidad-attributes">
- <entity id="inlineStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="styleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="shortDesc">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="partialTriggers">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-event-attributes">
- <entity id="onclick">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="ondblclick">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmousedown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseup">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseover">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmousemove">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeypress">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeydown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeyup">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <!--almost common events - should be refactored-->
- <entity id="onblur">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onchange">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onfocus">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onselect">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-show-tag-attributes">
- <entity id="disclosed">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="disclosedTransient">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="disclosureListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>org.apache.myfaces.trinidad.event.DisclosureEvent</item>
- </value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-value-holder-attributes">
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="converter">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.FacesConfigConverterIDType</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-input-tag-attributes">
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="required">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="validator">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>javax.faces.context.FacesContext</item>
- <item>javax.faces.component.UIComponent</item>
- <item>java.lang.Object</item>
- </value>
- </trait>
- </entity>
- <entity id="valueChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ValueChangeEvent</value>
- </trait>
- </entity>
- <entity id="requiredMessageDetail"/>
- </entityGroup>
- <entityGroup id="common-command-attributes">
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- </entity>
- <entity id="returnListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.ReturnEvent</value>
- </trait>
- </entity>
- <entity id="launchListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-param-types">
- <value>org.apache.myfaces.trinidad.event.LaunchEvent</value>
- </trait>
- </entity>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="useWindow">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="windowHeight">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="windowWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="text"/>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="textAndAccessKey"/>
- <entity id="partialSubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-select-tag-attributes">
- <entity id="contentStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.css</value>
- </trait>
- </entity>
- <entity id="valuePassThru">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="unselectedLabel"/>
- </entityGroup>
- <entityGroup id="common-text-attributes">
- <entity id="autoSubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="readOnly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="text"/>
- <entity id="textAndAccessKey"/>
- </entityGroup>
- <entityGroup id="common-label-attributes">
- <entity id="label"/>
- <entity id="accessKey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- </entity>
- <entity id="labelAndAccessKey"/>
- <entity id="simple">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="showRequired">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="readOnly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_dti.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_dti.xml
deleted file mode 100644
index 1fa8aea6d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_dti.xml
+++ /dev/null
@@ -1,1433 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:dti="http://org.eclipse.jsf.pagedesigner/dtinfo.ecore"
- id="http://myfaces.apache.org/trinidad"
- type="tagFile">
-
- <entity id="chart" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeFromXPathOperation">
- <parameter value="style"/>
- <parameter value="concat('border:1px solid silver;padding:2px;',@inlineStyle)"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="color:#999999; font-size:8pt; vertical-align:middle;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="src"/>
- <parameter value="$metadata-plugin-location$/icons/large/chart.gif"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="vertical-align:middle; margin:0px 3px 0px 0px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="chart"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- >
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="chooseColor" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeFromXPathOperation">
- <parameter value="style"/>
- <parameter value="concat('border:1px solid silver;padding:2px;width:72px;height:72px;',@inlineStyle)"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="color:#999999; font-size:8pt; vertical-align:middle;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="src"/>
- <parameter value="$metadata-plugin-location$/icons/large/chooseColor.gif"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="vertical-align:middle; margin:0px 3px 0px 0px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="chooseColor"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- >
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="chooseDate" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeFromXPathOperation">
- <parameter value="style"/>
- <parameter value="concat('border:1px solid silver;padding:2px;width:224px;height:152px;',@inlineStyle)"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="color:#999999; font-size:8pt; vertical-align:middle;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="src"/>
- <parameter value="$metadata-plugin-location$/icons/large/chooseDate.gif"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="vertical-align:middle; margin:0px 3px 0px 0px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="chooseDate"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- >
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="span/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="commandButton" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="button"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="button"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@disabled='true'"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="disabled"/>
- <parameter value=""/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;background-color:#e9e8e8;padding:0px;margin:1px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="textAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="text"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@icon"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="icon"/>
- <parameter value="src"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="commandLink" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#003333;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="textAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="text"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="document" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="html"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="head"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@title"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="title"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@title"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="body"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="background-color:#ffffff;font-family:Arial,Helvetica,Geneva,sans-serif;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="form" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="form"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="inlineStyle"/>
- <parameter value="style"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="goButton" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="button"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="button"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@disabled='true'"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="disabled"/>
- <parameter value=""/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;background-color:#e9e8e8;padding:0px;margin:1px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="textAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="text"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@icon"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="icon"/>
- <parameter value="src"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="goLink" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#003333;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="textAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="text"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="group" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="icon" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@name='required' or @name='AFRequiredIcon'"/>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="color:#669966;font-family:Courier,sans-serif;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="*"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@name='info' or @name='AFInfoIcon'"/>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="color:#669966;font-family:monospace;font-weight:bold;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="i"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@name='warning' or @name='AFWarningIcon'"/>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="color:#669966;font-family:monospace;font-weight:bold;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="!"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@name='error' or @name='AFErrorIcon'"/>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="color:#cc0000;font-family:monospace;font-weight:bold;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="X"/>
- </operation>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="image" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="source"/>
- <parameter value="src"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- widget="true"
- >
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="importScript" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/importScript.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="inputColor" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputTextWithIconOperation">
- <parameter value="$metadata-plugin-location$/icons/small/icon_inputColor.gif"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- >
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputDate" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputTextWithIconOperation">
- <parameter value="$metadata-plugin-location$/icons/small/icon_inputDate.gif"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- >
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputFile" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputFileOperation">
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="inputHidden" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/inputHidden.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="inputListOfValues" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputTextWithIconOperation">
- <parameter value="$metadata-plugin-location$/icons/small/icon_inputListOfValues.gif"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- >
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputNumberSpinbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputTextWithIconOperation">
- <parameter value="$metadata-plugin-location$/icons/small/icon_inputNumberSpinbox.gif"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- >
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName=".//a/img/src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputText" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.InputTextOperation">
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="message" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/message.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="messages" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/messages.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputFormatted" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.OutputFormattedOperation">
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputLabel" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="label"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="for"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;text-align:right;color:#000000;padding:0px 8px 0px 0px;font-weight:normal;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@valueAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="valueAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@valueAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputText" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="inlineStyle"/>
- <parameter value="style"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelFormLayout" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.PanelFormLayoutOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelGroupLayout" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.PanelGroupLayoutOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelLabelAndMessage" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.PanelLabelAndMessageOperation">
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelTabbed" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.PanelTabbedOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelTip" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#669966;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:bold;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="TIP "/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="poll" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/poll.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="progressIndicator" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="table"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="cellpadding"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="cellspacing"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="border"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="align"/>
- <parameter value="center"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="tr"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="td"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="align"/>
- <parameter value="center"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:bold;color:#669966;border-color:#99cc99;border-style:solid;border-width:1px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="Processing"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="tr"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="td"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="align"/>
- <parameter value="center"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="resetButton" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="button"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="reset"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@disabled='true'"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="disabled"/>
- <parameter value=""/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.CreateStyleAttributeOperation">
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;vertical-align:baseline;background-color:#e9e8e8;border-color:#999999;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="textAndAccessKey"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@textAndAccessKey"/>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="text"/>
- </operation>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectBooleanCheckbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectBooleanOperation">
- <parameter value="checkbox"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectBooleanRadio" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectBooleanOperation">
- <parameter value="radio"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectItem" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/selectItem.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyCheckbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectManyCheckboxOneRadioOperation">
- <parameter value="checkbox"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyListbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectListboxChoiceOperation">
- <parameter value="true"/>
- <parameter value="true"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyShuttle" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectShuttleOperation">
- <parameter value="false"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneChoice" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectListboxChoiceOperation">
- <parameter value="false"/>
- <parameter value="false"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneListbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectListboxChoiceOperation">
- <parameter value="false"/>
- <parameter value="true"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneRadio" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectManyCheckboxOneRadioOperation">
- <parameter value="radio"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOrderShuttle" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.SelectShuttleOperation">
- <parameter value="true"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectRangeChoiceBar" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="table"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="inlineStyle"/>
- <parameter value="style"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="cellpadding"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="cellspacing"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="border"/>
- <parameter value="0"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="tr"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="td"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="valign"/>
- <parameter value="middle"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="nowrap"/>
- <parameter value=""/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#003333;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="concat('Previous ',@rows)"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="td"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="valign"/>
- <parameter value="middle"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="nowrap"/>
- <parameter value=""/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="select"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;margin:0px 3px;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="Show All n"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="concat('1 - ',@rows,' of n')"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="concat(@rows + 1,' - ',@rows * 2,' of n')"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="td"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="valign"/>
- <parameter value="middle"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="nowrap"/>
- <parameter value=""/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#003333;"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="concat('Next ',@rows)"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="separator" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="hr"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="inlineStyle"/>
- <parameter value="style"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="showDetailItem" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.ShowDetailItemOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="spacer" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="src"/>
- <parameter value="$metadata-plugin-location$/icons/small/spacer.gif"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="alt"/>
- <parameter value=""/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="width"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="height"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- >
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.properties b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.properties
deleted file mode 100644
index fd5e7d168..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-
-###############################################################################
-# Copyright (c) 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-property.category.event=Event
-property.category.core=Core
-property.category.css=CSS
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.xml
deleted file mode 100644
index b6d4f6aa5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html.xml
+++ /dev/null
@@ -1,408 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel id="http://myfaces.apache.org/trinidad/html"
- type="tagFile"
- xmlns:cnst="http://org.eclipse.jst.jsf.core/constraints.ecore"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:qe="http://org.eclipse.jsf.pagedesigner/QuickEditTabSections.ecore">
- <entity id="body" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <include-entity-group id="common-event-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="initialFocusId"/>
- </value>
- </trait>
- <entity id="firstClickPassed">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="initialFocusId"/>
- </entity>
- <entity id="cellFormat" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <include-entity-group id="common-event-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="columnSpan"/>
- <section id="width"/>
- <section id="height"/>
- </value>
- </trait>
- <entity id="shortText"/>
- <entity id="halign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- </entity>
- <entity id="valign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>middle</item>
- <item>bottom</item>
- </value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="columnSpan">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="rowSpan">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="wrappingDisabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="headers"/>
- <entity id="header">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- </entity>
- <entity id="frame" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="source"/>
- <section id="name"/>
- </value>
- </trait>
- <entity id="source"/>
- <entity id="longDescURL"/>
- <entity id="name"/>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="marginWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- <entity id="marginHeight">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>1</value>
- </trait>
- </entity>
- <entity id="scrolling">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>auto</item>
- <item>yes</item>
- <item>no</item>>
- </value>
- </trait>
- <trait id="default-value">
- <value>auto</value>
- </trait>
- </entity>
- </entity>
- <entity id="frameBorderLayout" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <trait id="supported-facets">
- <value xsi:type="mdt:ListOfValues">
- <item>alternateContent</item>
- <item>bottom</item>
- <item>center</item>
- <item>end</item>
- <item>innerEnd</item>
- <item>innerLeft</item>
- <item>innerRight</item>
- <item>innerStart</item>
- <item>left</item>
- <item>right</item>
- <item>start</item>
- <item>top</item>
- </value>
- </trait>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="width"/>
- <section id="height"/>
- </value>
- </trait>
- <entity id="onload">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onunload">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="frameSpacing">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="borderWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="frameBorderWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- </entity>
- <entity id="head" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- <entity id="title"/>
- </entity>
- <entity id="html" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="mode"/>
- </value>
- </trait>
- <entity id="mode">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>strict</item>
- <item>quirks</item>>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- </entity>
- <entity id="rowLayout" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <include-entity-group id="common-event-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="width"/>
- <section id="halign"/>
- <section id="valign"/>
- </value>
- </trait>
- <entity id="halign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- </entity>
- <entity id="valign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>top</item>
- <item>middle</item>
- <item>bottom</item>
- </value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- </entity>
- <entity id="script" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="source"/>
- </value>
- </trait>
- <entity id="text" />
- <entity id="source" />
- <entity id="generatesContent" />
- </entity>
- <entity id="styleSheet" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="tableLayout" type="tag">
- <include-entity-group id="common-core-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <include-entity-group id="common-trinidadh-attributes"/>
- <include-entity-group id="common-partialTrigger-attribute"/>
- <include-entity-group id="common-event-attributes" uri="http://myfaces.apache.org/trinidad"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="binding"/>
- <section id="width"/>
- <section id="halign"/>
- </value>
- </trait>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- </entity>
- <entity id="halign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>start</item>
- <item>end</item>
- <item>center</item>
- </value>
- </trait>
- </entity>
- <entity id="cellSpacing">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="cellPadding">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="borderWidth">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- </entity>
- <entity id="summary"/>
- </entity>
- <entityGroup id="common-trinidadh-attributes">
- <entity id="inlineStyle">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="styleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.pagedesigner.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="shortDesc"/>
- </entityGroup>
- <entityGroup id="common-partialTrigger-attribute">
- <entity id="partialTriggers">
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_dti.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_dti.xml
deleted file mode 100644
index 1abc91f38..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_dti.xml
+++ /dev/null
@@ -1,100 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:dti="http://org.eclipse.jsf.pagedesigner/dtinfo.ecore"
- id="http://myfaces.apache.org/trinidad/html"
- type="tagFile">
-
- <entity id="body" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="body"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeWithRenameOperation">
- <parameter value="inlineStyle"/>
- <parameter value="style"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@styleClass"/>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@inlineStyle"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="style"/>
- <parameter value="background-color:#ffffff;font-family:Arial,Helvetica,Geneva,sans-serif;"/>
- </operation>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="head" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="head"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@title"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="title"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@title"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="html" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="html"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="styleSheet" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/small/styleSheet.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_pi.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_pi.xml
deleted file mode 100644
index ac1e50889..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_html_pi.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel id="http://myfaces.apache.org/trinidad/html"
- type="tagFile"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
-
- <trait id="is-jsf-component-library">
- <value>true</value>
- </trait>
-
- <entity id="styleSheet" type="tag"/>
- <entity id="body" type="tag"/>
- <entity id="cellFormat" type="tag"/>
- <entity id="frame" type="tag"/>
- <entity id="frameBorderLayout" type="tag"/>
- <entity id="head" type="tag"/>
- <entity id="html" type="tag"/>
- <entity id="rowLayout" type="tag"/>
- <entity id="script" type="tag"/>
- <entity id="tableLayout" type="tag"/>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_pi.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_pi.xml
deleted file mode 100644
index fc42ca67c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/trinidad_pi.xml
+++ /dev/null
@@ -1,133 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel id="http://myfaces.apache.org/trinidad"
- type="tagFile"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
-
- <trait id="is-jsf-component-library">
- <value>true</value>
- </trait>
-
- <entity id="forEach" type="tag"/>
- <entity id="setActionListener" type="tag"/>
- <entity id="fileDownloadActionListener" type="tag"/>
- <entity id="returnActionListener" type="tag"/>
- <entity id="resetActionListener" type="tag"/>
- <entity id="componentRef" type="tag"/>
- <entity id="componentDef" type="tag"/>
- <entity id="facetRef" type="tag"/>
- <entity id="breadCrumbs" type="tag"/>
- <entity id="chart" type="tag"/>
- <entity id="chooseColor" type="tag"/>
- <entity id="chooseDate" type="tag"/>
- <entity id="column" type="tag"/>
- <entity id="commandButton" type="tag"/>
- <entity id="commandLink" type="tag"/>
- <entity id="commandNavigationItem" type="tag"/>
- <entity id="document" type="tag"/>
- <entity id="form" type="tag"/>
- <entity id="goButton" type="tag"/>
- <entity id="goLink" type="tag"/>
- <entity id="icon" type="tag"/>
- <entity id="image" type="tag"/>
- <entity id="importScript" type="tag"/>
- <entity id="inputColor" type="tag"/>
- <entity id="inputDate" type="tag"/>
- <entity id="inputFile" type="tag"/>
- <entity id="inputHidden" type="tag"/>
- <entity id="inputListOfValues" type="tag"/>
- <entity id="inputNumberSpinbox" type="tag"/>
- <entity id="inputText" type="tag"/>
- <entity id="legend" type="tag"/>
- <entity id="media" type="tag"/>
- <entity id="message" type="tag"/>
- <entity id="messages" type="tag"/>
- <entity id="navigationPane" type="tag"/>
- <entity id="navigationTree" type="tag"/>
- <entity id="outputDocument" type="tag"/>
- <entity id="outputFormatted" type="tag"/>
- <entity id="outputLabel" type="tag"/>
- <entity id="outputText" type="tag"/>
- <entity id="page" type="tag"/>
- <entity id="panelAccordion" type="tag"/>
- <entity id="panelBorderLayout" type="tag"/>
- <entity id="panelBox" type="tag"/>
- <entity id="panelButtonBar" type="tag"/>
- <entity id="panelCaptionGroup" type="tag"/>
- <entity id="panelChoice" type="tag"/>
- <entity id="panelFormLayout" type="tag"/>
- <entity id="panelGroupLayout" type="tag"/>
- <entity id="panelHeader" type="tag"/>
- <entity id="panelHorizontalLayout" type="tag"/>
- <entity id="panelLabelAndMessage" type="tag"/>
- <entity id="panelList" type="tag"/>
- <entity id="panelPage" type="tag"/>
- <entity id="panelPageHeader" type="tag"/>
- <entity id="panelPopup" type="tag"/>
- <entity id="panelRadio" type="tag"/>
- <entity id="panelSideBar" type="tag"/>
- <entity id="panelTabbed" type="tag">
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <showDetailItem text="Tab 1"
- _uri_="http://myfaces.apache.org/trinidad"
- />
- <showDetailItem text="Tab 2"
- _uri_="http://myfaces.apache.org/trinidad"
- />
- ]]></template>
- </value>
- </trait>
- </entity>
- <entity id="panelTip" type="tag"/>
- <entity id="poll" type="tag"/>
- <entity id="processChoiceBar" type="tag"/>
- <entity id="progressIndicator" type="tag"/>
- <entity id="resetButton" type="tag"/>
- <entity id="selectBooleanCheckbox" type="tag"/>
- <entity id="selectBooleanRadio" type="tag"/>
- <entity id="selectItem" type="tag"/>
- <entity id="selectManyCheckbox" type="tag"/>
- <entity id="selectManyListbox" type="tag"/>
- <entity id="selectManyShuttle" type="tag"/>
- <entity id="selectOneChoice" type="tag"/>
- <entity id="selectOneListbox" type="tag"/>
- <entity id="selectOneRadio" type="tag"/>
- <entity id="selectOrderShuttle" type="tag"/>
- <entity id="selectRangeChoiceBar" type="tag"/>
- <entity id="separator" type="tag"/>
- <entity id="showDetail" type="tag"/>
- <entity id="showDetailHeader" type="tag"/>
- <entity id="showDetailItem" type="tag">
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <attribute id="text" value="Tab" />
- </value>
- </trait>
- </entity>
- <entity id="singleStepButtonBar" type="tag"/>
- <entity id="spacer" type="tag"/>
- <entity id="statusIndicator" type="tag"/>
- <entity id="subform" type="tag"/>
- <entity id="table" type="tag"/>
- <entity id="train" type="tag"/>
- <entity id="tree" type="tag"/>
- <entity id="treeTable" type="tag"/>
- <entity id="group" type="tag"/>
- <entity id="iterator" type="tag"/>
- <entity id="switcher" type="tag"/>
- <entity id="convertColor" type="tag"/>
- <entity id="convertDateTime" type="tag"/>
- <entity id="convertNumber" type="tag"/>
- <entity id="validateByteLength" type="tag"/>
- <entity id="validateDateRestriction" type="tag"/>
- <entity id="validateDateTimeRange" type="tag"/>
- <entity id="validateDoubleRange" type="tag"/>
- <entity id="validateLength" type="tag"/>
- <entity id="validateLongRange" type="tag"/>
- <entity id="validateRegExp" type="tag"/>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad.xml
deleted file mode 100644
index f030ebbe0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad.xml
+++ /dev/null
@@ -1,1913 +0,0 @@
-<?xml version="1.0" encoding="ASCII"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:viewMap="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xsi:noNamespaceSchemaLocation="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore" id="http://myfaces.apache.org/trinidad" type="tagFile">
- <entity id="panelList" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelList</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelList</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.List</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyListbox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectManyListbox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectMany</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectManyListbox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectMany</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Listbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="tree" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreTree</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXTree</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreTree</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Tree</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Tree</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateDateTimeRange" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.DateTimeRangeValidator</className>
- <validatorId>org.apache.myfaces.trinidad.DateTimeRange</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="showDetailItem" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CoreShowDetailItem</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowDetail</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreShowDetailItem</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowDetail</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Item</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelTabbed" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelTabbed</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelTabbed</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Tab</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectItem" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectItem</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectItem</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectItem</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectItem</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelPopup" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelPopup</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelPopup</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Popup</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="singleStepButtonBar" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreSingleStepButtonBar</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSingleStep</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSingleStepButtonBar</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SingleStep</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ButtonBar</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="componentRef" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.UIXComponentRef</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.ComponentRef</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ComponentRef</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelChoice" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelChoice</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelChoice</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Choice</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="showDetail" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CoreShowDetail</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowDetail</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreShowDetail</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowDetail</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ShowDetail</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="processChoiceBar" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreProcessChoiceBar</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXProcess</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreProcessChoiceBar</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Process</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ChoiceBar</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="treeTable" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreTreeTable</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXTreeTable</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXTree</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreTreeTable</componentType>
- <componentFamily>org.apache.myfaces.trinidad.TreeTable</componentFamily>
- <renderType>org.apache.myfaces.trinidad.TreeTable</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="subform" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CoreSubform</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSubform</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSubform</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Subform</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Subform</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelPage" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelPage</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelPage</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Page</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="page" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CorePage</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPage</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePage</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Page</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Page</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="messages" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreMessages</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXMessages</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreMessages</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Messages</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Messages</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="convertNumber" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.convert.NumberConverter</className>
- <converterId>org.apache.myfaces.trinidad.Number</converterId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="message" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreMessage</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXMessage</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreMessage</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Message</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Message</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="showDetailHeader" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CoreShowDetailHeader</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowDetail</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreShowDetailHeader</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowDetail</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Header</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="chart" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreChart</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXChart</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreChart</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Chart</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Chart</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateRegExp" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.RegExpValidator</className>
- <validatorId>org.apache.myfaces.trinidad.RegExp</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputDocument" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreOutputDocument</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXOutput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreOutputDocument</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Output</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Document</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="convertColor" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.convert.ColorConverter</className>
- <converterId>org.apache.myfaces.trinidad.Color</converterId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="icon" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreIcon</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreIcon</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Icon</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="image" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreImage</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreImage</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Image</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputText" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputText</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputText</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Input</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="poll" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CorePoll</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPoll</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePoll</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Poll</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Poll</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="goButton" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreGoButton</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXGo</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreGoButton</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Go</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Button</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateDoubleRange" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.DoubleRangeValidator</className>
- <validatorId>org.apache.myfaces.trinidad.DoubleRange</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="media" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreMedia</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreMedia</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Media</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputText" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreOutputText</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXOutput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreOutputText</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Output</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectRangeChoiceBar" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreSelectRangeChoiceBar</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectRange</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectRangeChoiceBar</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectRange</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ChoiceBar</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelHorizontalLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelHorizontalLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelHorizontalLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.HorizontalLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="resetButton" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreResetButton</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXReset</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreResetButton</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ResetButton</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Button</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputHidden" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputHidden</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputHidden</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Input</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Hidden</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="spacer" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreSpacer</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSpacer</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Spacer</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOneChoice" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectOneChoice</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectOneChoice</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Choice</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="table" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreTable</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXTable</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXIterator</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreTable</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Table</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Table</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="switcher" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.UIXSwitcher</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.Switcher</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Switcher</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelGroupLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelGroupLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelGroupLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.GroupLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelHeader" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelHeader</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelHeader</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Header</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelTip" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelTip</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelTip</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Tip</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyShuttle" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectManyShuttle</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectMany</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectManyShuttle</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectMany</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Shuttle</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelCaptionGroup" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelCaptionGroup</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelCaptionGroup</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.PanelCaptionGroup</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelPageHeader" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelPageHeader</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelPageHeader</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.PageHeader</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOneRadio" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectOneRadio</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectOneRadio</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Radio</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOneListbox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectOneListbox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectOneListbox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Listbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectBooleanRadio" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectBooleanRadio</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectBoolean</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectBooleanRadio</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectBoolean</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Radio</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="commandButton" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreCommandButton</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCommand</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.DialogSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreCommandButton</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Command</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Button</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputListOfValues" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputListOfValues</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputListOfValues</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectInput</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="goLink" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreGoLink</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXGo</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreGoLink</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Go</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Link</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="importScript" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CoreImportScript</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreImportScript</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ImportScript</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ImportScript</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="group" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.UIXGroup</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.Group</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Group</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="train" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreTrain</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXProcess</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreTrain</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Process</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Train</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="chooseColor" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreChooseColor</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXChoose</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreChooseColor</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Choose</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Color</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="commandNavigationItem" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreCommandNavigationItem</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCommand</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.DialogSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreCommandNavigationItem</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Command</componentFamily>
- <renderType>org.apache.myfaces.trinidad.NavigationItem</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="chooseDate" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreChooseDate</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXChoose</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreChooseDate</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Choose</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Date</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelButtonBar" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelButtonBar</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelButtonBar</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.ButtonBar</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="legend" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreLegend</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreLegend</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Legend</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputColor" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputColor</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputColor</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectInput</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Color</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputLabel" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreOutputLabel</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXOutput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreOutputLabel</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Output</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Label</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputFile" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputFile</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputFile</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Input</componentFamily>
- <renderType>org.apache.myfaces.trinidad.File</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelFormLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelFormLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelFormLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.FormLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="form" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CoreForm</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXForm</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreForm</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Form</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Form</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateLongRange" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.LongRangeValidator</className>
- <validatorId>org.apache.myfaces.trinidad.LongRange</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="column" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.data.CoreColumn</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXColumn</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreColumn</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Column</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Column</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputDate" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputDate</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputDate</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectInput</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Date</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateLength" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.LengthValidator</className>
- <validatorId>org.apache.myfaces.trinidad.Length</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="progressIndicator" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreProgressIndicator</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXProgress</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreProgressIndicator</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Progress</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Indicator</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateDateRestriction" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.DateRestrictionValidator</className>
- <validatorId>org.apache.myfaces.trinidad.DateRestriction</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelSideBar" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelSideBar</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelSideBar</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.SideBar</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="convertDateTime" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.convert.DateTimeConverter</className>
- <converterId>org.apache.myfaces.trinidad.DateTime</converterId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="separator" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreSeparator</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSeparator</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Separator</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="document" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CoreDocument</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXDocument</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreDocument</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Document</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Document</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputNumberSpinbox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreInputNumberSpinbox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXInput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreInputNumberSpinbox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Input</componentFamily>
- <renderType>org.apache.myfaces.trinidad.NumberSpinbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateByteLength" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>org.apache.myfaces.trinidadinternal.validator.ByteLengthValidator</className>
- <validatorId>org.apache.myfaces.trinidad.ByteLength</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="navigationTree" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreNavigationTree</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationTree</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreNavigationTree</componentType>
- <componentFamily>org.apache.myfaces.trinidad.NavigationTree</componentFamily>
- <renderType>org.apache.myfaces.trinidad.NavigationTree</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectBooleanCheckbox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectBooleanCheckbox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectBoolean</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectBooleanCheckbox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectBoolean</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Checkbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="navigationPane" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreNavigationPane</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationLevel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreNavigationPane</componentType>
- <componentFamily>org.apache.myfaces.trinidad.NavigationLevel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Pane</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyCheckbox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectManyCheckbox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectMany</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectManyCheckbox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectMany</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Checkbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="statusIndicator" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreStatusIndicator</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXObject</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreStatusIndicator</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Object</componentFamily>
- <renderType>org.apache.myfaces.trinidad.StatusIndicator</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelRadio" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelRadio</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXShowOne</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelRadio</componentType>
- <componentFamily>org.apache.myfaces.trinidad.ShowOne</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Radio</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelBox" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelBox</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelBox</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Box</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="iterator" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.UIXIterator</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.Iterator</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Iterator</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelBorderLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelBorderLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelBorderLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.BorderLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelAccordion" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelAccordion</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelAccordion</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Accordion</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="commandLink" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreCommandLink</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCommand</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.DialogSource</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreCommandLink</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Command</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Link</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelLabelAndMessage" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.layout.CorePanelLabelAndMessage</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXPanel</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CorePanelLabelAndMessage</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Panel</componentFamily>
- <renderType>org.apache.myfaces.trinidad.LabelAndMessage</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOrderShuttle" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.input.CoreSelectOrderShuttle</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectOrder</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXSelectMany</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXEditableValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreSelectOrderShuttle</componentType>
- <componentFamily>org.apache.myfaces.trinidad.SelectOrder</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Shuttle</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputFormatted" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.output.CoreOutputFormatted</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXOutput</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXValue</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreOutputFormatted</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Output</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Formatted</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="breadCrumbs" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.nav.CoreBreadCrumbs</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationPath</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXNavigationHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXHierarchy</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXCollection</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>org.apache.myfaces.trinidad.model.RowKeyIndex</interfaces>
- <interfaces>org.apache.myfaces.trinidad.component.CollectionComponent</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreBreadCrumbs</componentType>
- <componentFamily>org.apache.myfaces.trinidad.NavigationPath</componentFamily>
- <renderType>org.apache.myfaces.trinidad.BreadCrumbs</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad_html.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad_html.xml
deleted file mode 100644
index c1423b7dc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/metadata/viewMapping_trinidad_html.xml
+++ /dev/null
@@ -1,193 +0,0 @@
-<?xml version="1.0" encoding="ASCII"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:viewMap="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xsi:noNamespaceSchemaLocation="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore" id="http://myfaces.apache.org/trinidad/html" type="tagFile">
- <entity id="frame" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlFrame</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlFrame</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Frame</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Frame</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="html" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlHtml</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlHtml</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Html</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Html</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="script" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlScript</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlScript</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Script</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Script</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="head" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlHead</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlHead</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Head</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Head</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="rowLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlRowLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlRowLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.RowLayout</componentFamily>
- <renderType>org.apache.myfaces.trinidad.RowLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="frameBorderLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlFrameBorderLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlFrameBorderLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.FrameBorderLayout</componentFamily>
- <renderType>org.apache.myfaces.trinidad.FrameBorderLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="styleSheet" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.core.CoreStyleSheet</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.CoreStyleSheet</componentType>
- <componentFamily>org.apache.myfaces.trinidad.StyleSheet</componentFamily>
- <renderType>org.apache.myfaces.trinidad.StyleSheet</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="cellFormat" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlCellFormat</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlCellFormat</componentType>
- <componentFamily>org.apache.myfaces.trinidad.CellFormat</componentFamily>
- <renderType>org.apache.myfaces.trinidad.CellFormat</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="tableLayout" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlTableLayout</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlTableLayout</componentType>
- <componentFamily>org.apache.myfaces.trinidad.TableLayout</componentFamily>
- <renderType>org.apache.myfaces.trinidad.TableLayout</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="body" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>org.apache.myfaces.trinidad.component.html.HtmlBody</className>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponentBase</superClasses>
- <superClasses>org.apache.myfaces.trinidad.component.UIXComponent</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>org.apache.myfaces.trinidad.HtmlBody</componentType>
- <componentFamily>org.apache.myfaces.trinidad.Body</componentFamily>
- <renderType>org.apache.myfaces.trinidad.Body</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.properties
deleted file mode 100644
index 8a7fa9451..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-
-
-# ====================================================================
-# To code developer:
-# Do NOT change the properties between this line and the
-# "%%% END OF TRANSLATED PROPERTIES %%%" line.
-# Make a new property name, append to the end of the file and change
-# the code to use the new property.
-# ====================================================================
-
-# ====================================================================
-# %%% END OF TRANSLATED PROPERTIES %%%
-# ====================================================================
-
-pluginName = JavaServer Faces Tools - Taglibrary Metadata (Apache Trinidad)
-pluginProvider = Eclipse.org
-
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.xml
deleted file mode 100644
index 53c935305..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/plugin.xml
+++ /dev/null
@@ -1,110 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
- <extension
- point="org.eclipse.jst.jsf.common.standardMetaDataFiles">
- <standardMetaDataFile
- location="$nl$/metadata/trinidad.xml"
- uri="http://myfaces.apache.org/trinidad">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/trinidad_pi.xml"
- uri="http://myfaces.apache.org/trinidad">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/trinidad_dti.xml"
- uri="http://myfaces.apache.org/trinidad">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/trinidad_html.xml"
- uri="http://myfaces.apache.org/trinidad/html">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/trinidad_html_pi.xml"
- uri="http://myfaces.apache.org/trinidad/html">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/trinidad_html_dti.xml"
- uri="http://myfaces.apache.org/trinidad/html">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/viewMapping_trinidad.xml"
- uri="http://myfaces.apache.org/trinidad">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/viewMapping_trinidad_html.xml"
- uri="http://myfaces.apache.org/trinidad/html">
- </standardMetaDataFile>
- </extension>
- <extension
- point="org.eclipse.jst.pagedesigner.pageDesignerExtension">
- <elementEditFactory
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit.TrinidadCoreElementEditFactory">
- </elementEditFactory>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.CreateStyleAttributeOperation"
- id="CreateStyleAttributeOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.InputFileOperation"
- id="InputFileOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.InputTextOperation"
- id="InputTextOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.InputTextWithIconOperation"
- id="InputTextWithIconOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.OutputFormattedOperation"
- id="OutputFormattedOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.PanelFormLayoutOperation"
- id="PanelFormLayoutOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.PanelGroupLayoutOperation"
- id="PanelGroupLayoutOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.PanelLabelAndMessageOperation"
- id="PanelLabelAndMessageOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.PanelTabbedOperation"
- id="PanelTabbedOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.SelectBooleanOperation"
- id="SelectBooleanOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.SelectListboxChoiceOperation"
- id="SelectListboxChoiceOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.SelectManyCheckboxOneRadioOperation"
- id="SelectManyCheckboxOneRadioOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.SelectShuttleOperation"
- id="SelectShuttleOperation">
- </tagTransformOperation>
- <tagTransformOperation
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.ShowDetailItemOperation"
- id="ShowDetailItemOperation">
- </tagTransformOperation>
- </extension>
- <extension
- point="org.eclipse.jst.jsf.core.variableresolver">
- <variableresolver
- class="org.eclipse.jst.jsf.apache.trinidad.tagsupport.el.TrinidadDecorativeVariableResolver"
- forRuntimeClass="org.apache.myfaces.trinidadinternal.el.TrinidadVariableResolver"
- id="org.eclipse.jst.jsf.apache.trinidad.tagsupport.variableresolver1">
- </variableresolver>
- </extension>
-
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/ITrinidadConstants.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/ITrinidadConstants.java
deleted file mode 100644
index cbb8d88e1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/ITrinidadConstants.java
+++ /dev/null
@@ -1,2557 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport;
-
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-
-/**
- * Trinidad-related constants.
- *
- * @author Ian Trimble - Oracle
- */
-public interface ITrinidadConstants {
-
- /**
- * Trinidad "core" URI.
- */
- public static final String URI_CORE = "http://myfaces.apache.org/trinidad"; //$NON-NLS-1$
-
- /**
- * Trinidad "html" URI.
- */
- public static final String URI_HTML = "http://myfaces.apache.org/trinidad/html"; //$NON-NLS-1$
-
- // "Core" tags
- /**
- * Tag name for "tr:forEach"
- */
- public static final String TAG_FOREACH = "forEach"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:forEach"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FOREACH = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_FOREACH);
-
- /**
- * Tag name for "tr:setActionListener"
- */
- public static final String TAG_SETACTIONLISTENER = "setActionListener"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:setActionListener"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SETACTIONLISTENER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SETACTIONLISTENER);
-
- /**
- * Tag name for "tr:fileDownloadActionListener"
- */
- public static final String TAG_FILEDOWNLOADACTIONLISTENER = "fileDownloadActionListener"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:fileDownloadActionListener"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FILEDOWNLOADACTIONLISTENER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_FILEDOWNLOADACTIONLISTENER);
-
- /**
- * Tag name for "tr:returnActionListener"
- */
- public static final String TAG_RETURNACTIONLISTENER = "returnActionListener"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:returnActionListener"
- */
- public static final TagIdentifier TAG_IDENTIFIER_RETURNACTIONLISTENER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_RETURNACTIONLISTENER);
-
- /**
- * Tag name for "tr:resetActionListener"
- */
- public static final String TAG_RESETACTIONLISTENER = "resetActionListener"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:resetActionListener"
- */
- public static final TagIdentifier TAG_IDENTIFIER_RESETACTIONLISTENER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_RESETACTIONLISTENER);
-
- /**
- * Tag name for "tr:componentRef"
- */
- public static final String TAG_COMPONENTREF = "componentRef"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:componentRef"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COMPONENTREF = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COMPONENTREF);
-
- /**
- * Tag name for "tr:componentDef"
- */
- public static final String TAG_COMPONENTDEF = "componentDef"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:componentDef"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COMPONENTDEF = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COMPONENTDEF);
-
- /**
- * Tag name for "tr:facetRef"
- */
- public static final String TAG_FACETREF = "facetRef"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:facetRef"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FACETREF = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_FACETREF);
-
- /**
- * Tag name for "tr:breadCrumbs"
- */
- public static final String TAG_BREADCRUMBS = "breadCrumbs"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:breadCrumbs"
- */
- public static final TagIdentifier TAG_IDENTIFIER_BREADCRUMBS = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_BREADCRUMBS);
-
- /**
- * Tag name for "tr:chart"
- */
- public static final String TAG_CHART = "chart"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:chart"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CHART = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CHART);
-
- /**
- * Tag name for "tr:chooseColor"
- */
- public static final String TAG_CHOOSECOLOR = "chooseColor"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:chooseColor"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CHOOSECOLOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CHOOSECOLOR);
-
- /**
- * Tag name for "tr:chooseDate"
- */
- public static final String TAG_CHOOSEDATE = "chooseDate"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:chooseDate"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CHOOSEDATE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CHOOSEDATE);
-
- /**
- * Tag name for "tr:column"
- */
- public static final String TAG_COLUMN = "column"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:column"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COLUMN = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COLUMN);
-
- /**
- * Tag name for "tr:commandButton"
- */
- public static final String TAG_COMMANDBUTTON = "commandButton"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:commandButton"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COMMANDBUTTON = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COMMANDBUTTON);
-
- /**
- * Tag name for "tr:commandLink"
- */
- public static final String TAG_COMMANDLINK = "commandLink"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:commandLink"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COMMANDLINK = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COMMANDLINK);
-
- /**
- * Tag name for "tr:commandNavigationItem"
- */
- public static final String TAG_COMMANDNAVIGATIONITEM = "commandNavigationItem"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:commandNavigationItem"
- */
- public static final TagIdentifier TAG_IDENTIFIER_COMMANDNAVIGATIONITEM = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_COMMANDNAVIGATIONITEM);
-
- /**
- * Tag name for "tr:document"
- */
- public static final String TAG_DOCUMENT = "document"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:document"
- */
- public static final TagIdentifier TAG_IDENTIFIER_DOCUMENT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_DOCUMENT);
-
- /**
- * Tag name for "tr:form"
- */
- public static final String TAG_FORM = "form"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:form"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FORM = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_FORM);
-
- /**
- * Tag name for "tr:goButton"
- */
- public static final String TAG_GOBUTTON = "goButton"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:goButton"
- */
- public static final TagIdentifier TAG_IDENTIFIER_GOBUTTON = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_GOBUTTON);
-
- /**
- * Tag name for "tr:goLink"
- */
- public static final String TAG_GOLINK = "goLink"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:goLink"
- */
- public static final TagIdentifier TAG_IDENTIFIER_GOLINK = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_GOLINK);
-
- /**
- * Tag name for "tr:icon"
- */
- public static final String TAG_ICON = "icon"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:icon"
- */
- public static final TagIdentifier TAG_IDENTIFIER_ICON = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_ICON);
-
- /**
- * Tag name for "tr:image"
- */
- public static final String TAG_IMAGE = "image"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:image"
- */
- public static final TagIdentifier TAG_IDENTIFIER_IMAGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_IMAGE);
-
- /**
- * Tag name for "tr:importScript"
- */
- public static final String TAG_IMPORTSCRIPT = "importScript"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:importScript"
- */
- public static final TagIdentifier TAG_IDENTIFIER_IMPORTSCRIPT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_IMPORTSCRIPT);
-
- /**
- * Tag name for "tr:inputColor"
- */
- public static final String TAG_INPUTCOLOR = "inputColor"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputColor"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTCOLOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTCOLOR);
-
- /**
- * Tag name for "tr:inputDate"
- */
- public static final String TAG_INPUTDATE = "inputDate"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputDate"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTDATE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTDATE);
-
- /**
- * Tag name for "tr:inputFile"
- */
- public static final String TAG_INPUTFILE = "inputFile"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputFile"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTFILE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTFILE);
-
- /**
- * Tag name for "tr:inputHidden"
- */
- public static final String TAG_INPUTHIDDEN = "inputHidden"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputHidden"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTHIDDEN = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTHIDDEN);
-
- /**
- * Tag name for "tr:inputListOfValues"
- */
- public static final String TAG_INPUTLISTOFVALUES = "inputListOfValues"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputListOfValues"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTLISTOFVALUES = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTLISTOFVALUES);
-
- /**
- * Tag name for "tr:inputNumberSpinbox"
- */
- public static final String TAG_INPUTNUMBERSPINBOX = "inputNumberSpinbox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputNumberSpinbox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTNUMBERSPINBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTNUMBERSPINBOX);
-
- /**
- * Tag name for "tr:inputText"
- */
- public static final String TAG_INPUTTEXT = "inputText"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:inputText"
- */
- public static final TagIdentifier TAG_IDENTIFIER_INPUTTEXT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_INPUTTEXT);
-
- /**
- * Tag name for "tr:legend"
- */
- public static final String TAG_LEGEND = "legend"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:legend"
- */
- public static final TagIdentifier TAG_IDENTIFIER_LEGEND = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_LEGEND);
-
- /**
- * Tag name for "tr:media"
- */
- public static final String TAG_MEDIA = "media"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:media"
- */
- public static final TagIdentifier TAG_IDENTIFIER_MEDIA = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_MEDIA);
-
- /**
- * Tag name for "tr:message"
- */
- public static final String TAG_MESSAGE = "message"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:message"
- */
- public static final TagIdentifier TAG_IDENTIFIER_MESSAGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_MESSAGE);
-
- /**
- * Tag name for "tr:messages"
- */
- public static final String TAG_MESSAGES = "messages"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:messages"
- */
- public static final TagIdentifier TAG_IDENTIFIER_MESSAGES = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_MESSAGES);
-
- /**
- * Tag name for "tr:navigationPane"
- */
- public static final String TAG_NAVIGATIONPANE = "navigationPane"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:navigationPane"
- */
- public static final TagIdentifier TAG_IDENTIFIER_NAVIGATIONPANE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_NAVIGATIONPANE);
-
- /**
- * Tag name for "tr:navigationTree"
- */
- public static final String TAG_NAVIGATIONTREE = "navigationTree"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:navigationTree"
- */
- public static final TagIdentifier TAG_IDENTIFIER_NAVIGATIONTREE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_NAVIGATIONTREE);
-
- /**
- * Tag name for "tr:outputDocument"
- */
- public static final String TAG_OUTPUTDOCUMENT = "outputDocument"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:outputDocument"
- */
- public static final TagIdentifier TAG_IDENTIFIER_OUTPUTDOCUMENT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_OUTPUTDOCUMENT);
-
- /**
- * Tag name for "tr:outputFormatted"
- */
- public static final String TAG_OUTPUTFORMATTED = "outputFormatted"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:outputFormatted"
- */
- public static final TagIdentifier TAG_IDENTIFIER_OUTPUTFORMATTED = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_OUTPUTFORMATTED);
-
- /**
- * Tag name for "tr:outputLabel"
- */
- public static final String TAG_OUTPUTLABEL = "outputLabel"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:outputLabel"
- */
- public static final TagIdentifier TAG_IDENTIFIER_OUTPUTLABEL = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_OUTPUTLABEL);
-
- /**
- * Tag name for "tr:outputText"
- */
- public static final String TAG_OUTPUTTEXT = "outputText"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:outputText"
- */
- public static final TagIdentifier TAG_IDENTIFIER_OUTPUTTEXT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_OUTPUTTEXT);
-
- /**
- * Tag name for "tr:page"
- */
- public static final String TAG_PAGE = "page"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:page"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PAGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PAGE);
-
- /**
- * Tag name for "tr:panelAccordion"
- */
- public static final String TAG_PANELACCORDION = "panelAccordion"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelAccordion"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELACCORDION = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELACCORDION);
-
- /**
- * Tag name for "tr:panelBorderLayout"
- */
- public static final String TAG_PANELBORDERLAYOUT = "panelBorderLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelBorderLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELBORDERLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELBORDERLAYOUT);
-
- /**
- * Tag name for "tr:panelBox"
- */
- public static final String TAG_PANELBOX = "panelBox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelBox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELBOX);
-
- /**
- * Tag name for "tr:panelButtonBar"
- */
- public static final String TAG_PANELBUTTONBAR = "panelButtonBar"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelButtonBar"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELBUTTONBAR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELBUTTONBAR);
-
- /**
- * Tag name for "tr:panelCaptionGroup"
- */
- public static final String TAG_PANELCAPTIONGROUP = "panelCaptionGroup"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelCaptionGroup"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELCAPTIONGROUP = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELCAPTIONGROUP);
-
- /**
- * Tag name for "tr:panelChoice"
- */
- public static final String TAG_PANELCHOICE = "panelChoice"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelChoice"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELCHOICE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELCHOICE);
-
- /**
- * Tag name for "tr:panelFormLayout"
- */
- public static final String TAG_PANELFORMLAYOUT = "panelFormLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelFormLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELFORMLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELFORMLAYOUT);
-
- /**
- * Tag name for "tr:panelGroupLayout"
- */
- public static final String TAG_PANELGROUPLAYOUT = "panelGroupLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelGroupLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELGROUPLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELGROUPLAYOUT);
-
- /**
- * Tag name for "tr:panelHeader"
- */
- public static final String TAG_PANELHEADER = "panelHeader"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelHeader"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELHEADER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELHEADER);
-
- /**
- * Tag name for "tr:panelHorizontalLayout"
- */
- public static final String TAG_PANELHORIZONTALLAYOUT = "panelHorizontalLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelHorizontalLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELHORIZONTALLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELHORIZONTALLAYOUT);
-
- /**
- * Tag name for "tr:panelLabelAndMessage"
- */
- public static final String TAG_PANELLABELANDMESSAGE = "panelLabelAndMessage"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelLabelAndMessage"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELLABELANDMESSAGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELLABELANDMESSAGE);
-
- /**
- * Tag name for "tr:panelList"
- */
- public static final String TAG_PANELLIST = "panelList"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelList"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELLIST = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELLIST);
-
- /**
- * Tag name for "tr:panelPage"
- */
- public static final String TAG_PANELPAGE = "panelPage"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelPage"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELPAGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELPAGE);
-
- /**
- * Tag name for "tr:panelPageHeader"
- */
- public static final String TAG_PANELPAGEHEADER = "panelPageHeader"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelPageHeader"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELPAGEHEADER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELPAGEHEADER);
-
- /**
- * Tag name for "tr:panelPopup"
- */
- public static final String TAG_PANELPOPUP = "panelPopup"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelPopup"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELPOPUP = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELPOPUP);
-
- /**
- * Tag name for "tr:panelRadio"
- */
- public static final String TAG_PANELRADIO = "panelRadio"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelRadio"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELRADIO = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELRADIO);
-
- /**
- * Tag name for "tr:panelSideBar"
- */
- public static final String TAG_PANELSIDEBAR = "panelSideBar"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelSideBar"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELSIDEBAR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELSIDEBAR);
-
- /**
- * Tag name for "tr:panelTabbed"
- */
- public static final String TAG_PANELTABBED = "panelTabbed"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelTabbed"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELTABBED = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELTABBED);
-
- /**
- * Tag name for "tr:panelTip"
- */
- public static final String TAG_PANELTIP = "panelTip"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:panelTip"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PANELTIP = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PANELTIP);
-
- /**
- * Tag name for "tr:poll"
- */
- public static final String TAG_POLL = "poll"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:poll"
- */
- public static final TagIdentifier TAG_IDENTIFIER_POLL = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_POLL);
-
- /**
- * Tag name for "tr:processChoiceBar"
- */
- public static final String TAG_PROCESSCHOICEBAR = "processChoiceBar"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:processChoiceBar"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PROCESSCHOICEBAR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PROCESSCHOICEBAR);
-
- /**
- * Tag name for "tr:progressIndicator"
- */
- public static final String TAG_PROGRESSINDICATOR = "progressIndicator"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:progressIndicator"
- */
- public static final TagIdentifier TAG_IDENTIFIER_PROGRESSINDICATOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_PROGRESSINDICATOR);
-
- /**
- * Tag name for "tr:resetButton"
- */
- public static final String TAG_RESETBUTTON = "resetButton"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:resetButton"
- */
- public static final TagIdentifier TAG_IDENTIFIER_RESETBUTTON = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_RESETBUTTON);
-
- /**
- * Tag name for "tr:selectBooleanCheckbox"
- */
- public static final String TAG_SELECTBOOLEANCHECKBOX = "selectBooleanCheckbox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectBooleanCheckbox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTBOOLEANCHECKBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTBOOLEANCHECKBOX);
-
- /**
- * Tag name for "tr:selectBooleanRadio"
- */
- public static final String TAG_SELECTBOOLEANRADIO = "selectBooleanRadio"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectBooleanRadio"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTBOOLEANRADIO = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTBOOLEANRADIO);
-
- /**
- * Tag name for "tr:selectItem"
- */
- public static final String TAG_SELECTITEM = "selectItem"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectItem"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTITEM = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTITEM);
-
- /**
- * Tag name for "tr:selectManyCheckbox"
- */
- public static final String TAG_SELECTMANYCHECKBOX = "selectManyCheckbox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectManyCheckbox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTMANYCHECKBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTMANYCHECKBOX);
-
- /**
- * Tag name for "tr:selectManyListbox"
- */
- public static final String TAG_SELECTMANYLISTBOX = "selectManyListbox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectManyListbox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTMANYLISTBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTMANYLISTBOX);
-
- /**
- * Tag name for "tr:selectManyShuttle"
- */
- public static final String TAG_SELECTMANYSHUTTLE = "selectManyShuttle"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectManyShuttle"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTMANYSHUTTLE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTMANYSHUTTLE);
-
- /**
- * Tag name for "tr:selectOneChoice"
- */
- public static final String TAG_SELECTONECHOICE = "selectOneChoice"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectOneChoice"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTONECHOICE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTONECHOICE);
-
- /**
- * Tag name for "tr:selectOneListbox"
- */
- public static final String TAG_SELECTONELISTBOX = "selectOneListbox"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectOneListbox"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTONELISTBOX = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTONELISTBOX);
-
- /**
- * Tag name for "tr:selectOneRadio"
- */
- public static final String TAG_SELECTONERADIO = "selectOneRadio"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectOneRadio"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTONERADIO = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTONERADIO);
-
- /**
- * Tag name for "tr:selectOrderShuttle"
- */
- public static final String TAG_SELECTORDERSHUTTLE = "selectOrderShuttle"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectOrderShuttle"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTORDERSHUTTLE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTORDERSHUTTLE);
-
- /**
- * Tag name for "tr:selectRangeChoiceBar"
- */
- public static final String TAG_SELECTRANGECHOICEBAR = "selectRangeChoiceBar"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:selectRangeChoiceBar"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SELECTRANGECHOICEBAR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SELECTRANGECHOICEBAR);
-
- /**
- * Tag name for "tr:separator"
- */
- public static final String TAG_SEPARATOR = "separator"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:separator"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SEPARATOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SEPARATOR);
-
- /**
- * Tag name for "tr:showDetail"
- */
- public static final String TAG_SHOWDETAIL = "showDetail"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:showDetail"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SHOWDETAIL = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SHOWDETAIL);
-
- /**
- * Tag name for "tr:showDetailHeader"
- */
- public static final String TAG_SHOWDETAILHEADER = "showDetailHeader"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:showDetailHeader"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SHOWDETAILHEADER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SHOWDETAILHEADER);
-
- /**
- * Tag name for "tr:showDetailItem"
- */
- public static final String TAG_SHOWDETAILITEM = "showDetailItem"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:showDetailItem"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SHOWDETAILITEM = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SHOWDETAILITEM);
-
- /**
- * Tag name for "tr:singleStepButtonBar"
- */
- public static final String TAG_SINGLESTEPBUTTONBAR = "singleStepButtonBar"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:singleStepButtonBar"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SINGLESTEPBUTTONBAR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SINGLESTEPBUTTONBAR);
-
- /**
- * Tag name for "tr:spacer"
- */
- public static final String TAG_SPACER = "spacer"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:spacer"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SPACER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SPACER);
-
- /**
- * Tag name for "tr:statusIndicator"
- */
- public static final String TAG_STATUSINDICATOR = "statusIndicator"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:statusIndicator"
- */
- public static final TagIdentifier TAG_IDENTIFIER_STATUSINDICATOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_STATUSINDICATOR);
-
- /**
- * Tag name for "tr:subform"
- */
- public static final String TAG_SUBFORM = "subform"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:subform"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SUBFORM = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SUBFORM);
-
- /**
- * Tag name for "tr:table"
- */
- public static final String TAG_TABLE = "table"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:table"
- */
- public static final TagIdentifier TAG_IDENTIFIER_TABLE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_TABLE);
-
- /**
- * Tag name for "tr:train"
- */
- public static final String TAG_TRAIN = "train"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:train"
- */
- public static final TagIdentifier TAG_IDENTIFIER_TRAIN = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_TRAIN);
-
- /**
- * Tag name for "tr:tree"
- */
- public static final String TAG_TREE = "tree"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:tree"
- */
- public static final TagIdentifier TAG_IDENTIFIER_TREE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_TREE);
-
- /**
- * Tag name for "tr:treeTable"
- */
- public static final String TAG_TREETABLE = "treeTable"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:treeTable"
- */
- public static final TagIdentifier TAG_IDENTIFIER_TREETABLE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_TREETABLE);
-
- /**
- * Tag name for "tr:group"
- */
- public static final String TAG_GROUP = "group"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:group"
- */
- public static final TagIdentifier TAG_IDENTIFIER_GROUP = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_GROUP);
-
- /**
- * Tag name for "tr:iterator"
- */
- public static final String TAG_ITERATOR = "iterator"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:iterator"
- */
- public static final TagIdentifier TAG_IDENTIFIER_ITERATOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_ITERATOR);
-
- /**
- * Tag name for "tr:switcher"
- */
- public static final String TAG_SWITCHER = "switcher"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:switcher"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SWITCHER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_SWITCHER);
-
- /**
- * Tag name for "tr:convertColor"
- */
- public static final String TAG_CONVERTCOLOR = "convertColor"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:convertColor"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CONVERTCOLOR = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CONVERTCOLOR);
-
- /**
- * Tag name for "tr:convertDateTime"
- */
- public static final String TAG_CONVERTDATETIME = "convertDateTime"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:convertDateTime"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CONVERTDATETIME = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CONVERTDATETIME);
-
- /**
- * Tag name for "tr:convertNumber"
- */
- public static final String TAG_CONVERTNUMBER = "convertNumber"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:convertNumber"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CONVERTNUMBER = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_CONVERTNUMBER);
-
- /**
- * Tag name for "tr:validateByteLength"
- */
- public static final String TAG_VALIDATEBYTELENGTH = "validateByteLength"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateByteLength"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATEBYTELENGTH = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATEBYTELENGTH);
-
- /**
- * Tag name for "tr:validateDateRestriction"
- */
- public static final String TAG_VALIDATEDATERESTRICTION = "validateDateRestriction"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateDateRestriction"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATEDATERESTRICTION = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATEDATERESTRICTION);
-
- /**
- * Tag name for "tr:validateDateTimeRange"
- */
- public static final String TAG_VALIDATEDATETIMERANGE = "validateDateTimeRange"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateDateTimeRange"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATEDATETIMERANGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATEDATETIMERANGE);
-
- /**
- * Tag name for "tr:validateDoubleRange"
- */
- public static final String TAG_VALIDATEDOUBLERANGE = "validateDoubleRange"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateDoubleRange"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATEDOUBLERANGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATEDOUBLERANGE);
-
- /**
- * Tag name for "tr:validateLength"
- */
- public static final String TAG_VALIDATELENGTH = "validateLength"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateLength"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATELENGTH = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATELENGTH);
-
- /**
- * Tag name for "tr:validateLongRange"
- */
- public static final String TAG_VALIDATELONGRANGE = "validateLongRange"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateLongRange"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATELONGRANGE = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATELONGRANGE);
-
- /**
- * Tag name for "tr:validateRegExp"
- */
- public static final String TAG_VALIDATEREGEXP = "validateRegExp"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "tr:validateRegExp"
- */
- public static final TagIdentifier TAG_IDENTIFIER_VALIDATEREGEXP = TagIdentifierFactory
- .createJSPTagWrapper(URI_CORE, TAG_VALIDATEREGEXP);
-
- // "HTML" tags
- /**
- * Tag name for "trh:styleSheet"
- */
- public static final String TAG_STYLESHEET = "styleSheet"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:styleSheet"
- */
- public static final TagIdentifier TAG_IDENTIFIER_STYLESHEET = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_STYLESHEET);
-
- /**
- * Tag name for "trh:body"
- */
- public static final String TAG_BODY = "body"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:body"
- */
- public static final TagIdentifier TAG_IDENTIFIER_BODY = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_BODY);
-
- /**
- * Tag name for "trh:cellFormat"
- */
- public static final String TAG_CELLFORMAT = "cellFormat"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:cellFormat"
- */
- public static final TagIdentifier TAG_IDENTIFIER_CELLFORMAT = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_CELLFORMAT);
-
- /**
- * Tag name for "trh:frame"
- */
- public static final String TAG_FRAME = "frame"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:frame"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FRAME = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_FRAME);
-
- /**
- * Tag name for "trh:frameBorderLayout"
- */
- public static final String TAG_FRAMEBORDERLAYOUT = "frameBorderLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:frameBorderLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_FRAMEBORDERLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_FRAMEBORDERLAYOUT);
-
- /**
- * Tag name for "trh:head"
- */
- public static final String TAG_HEAD = "head"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:head"
- */
- public static final TagIdentifier TAG_IDENTIFIER_HEAD = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_HEAD);
-
- /**
- * Tag name for "trh:html"
- */
- public static final String TAG_HTML = "html"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:html"
- */
- public static final TagIdentifier TAG_IDENTIFIER_HTML = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_HTML);
-
- /**
- * Tag name for "trh:rowLayout"
- */
- public static final String TAG_ROWLAYOUT = "rowLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:rowLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_ROWLAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_ROWLAYOUT);
-
- /**
- * Tag name for "trh:script"
- */
- public static final String TAG_SCRIPT = "script"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:script"
- */
- public static final TagIdentifier TAG_IDENTIFIER_SCRIPT = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_SCRIPT);
-
- /**
- * Tag name for "trh:tableLayout"
- */
- public static final String TAG_TABLELAYOUT = "tableLayout"; //$NON-NLS-1$
-
- /**
- * TagIdentifier for "trh:tableLayout"
- */
- public static final TagIdentifier TAG_IDENTIFIER_TABLELAYOUT = TagIdentifierFactory
- .createJSPTagWrapper(URI_HTML, TAG_TABLELAYOUT);
-
-//Attributes
- /**
- * "summary" tag attribute name
- */
- public static final String ATTR_SUMMARY = "summary"; //$NON-NLS-1$
-
- /**
- * "initialFocusId" tag attribute name
- */
- public static final String ATTR_INITIALFOCUSID = "initialFocusId"; //$NON-NLS-1$
-
- /**
- * "accessKey" tag attribute name
- */
- public static final String ATTR_ACCESSKEY = "accessKey"; //$NON-NLS-1$
-
- /**
- * "colorData" tag attribute name
- */
- public static final String ATTR_COLORDATA = "colorData"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertBoth" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTBOTH = "messageDetailConvertBoth"; //$NON-NLS-1$
-
- /**
- * "defaultSortOrder" tag attribute name
- */
- public static final String ATTR_DEFAULTSORTORDER = "defaultSortOrder"; //$NON-NLS-1$
-
- /**
- * "columns" tag attribute name
- */
- public static final String ATTR_COLUMNS = "columns"; //$NON-NLS-1$
-
- /**
- * "chromeType" tag attribute name
- */
- public static final String ATTR_CHROMETYPE = "chromeType"; //$NON-NLS-1$
-
- /**
- * "rowHeader" tag attribute name
- */
- public static final String ATTR_ROWHEADER = "rowHeader"; //$NON-NLS-1$
-
- /**
- * "transparentAllowed" tag attribute name
- */
- public static final String ATTR_TRANSPARENTALLOWED = "transparentAllowed"; //$NON-NLS-1$
-
- /**
- * "rootNodeRendered" tag attribute name
- */
- public static final String ATTR_ROOTNODERENDERED = "rootNodeRendered"; //$NON-NLS-1$
-
- /**
- * "rangeChangeListener" tag attribute name
- */
- public static final String ATTR_RANGECHANGELISTENER = "rangeChangeListener"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertCurrency" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTCURRENCY = "messageDetailConvertCurrency"; //$NON-NLS-1$
-
- /**
- * "patterns" tag attribute name
- */
- public static final String ATTR_PATTERNS = "patterns"; //$NON-NLS-1$
-
- /**
- * "disclosedRowKeys" tag attribute name
- */
- public static final String ATTR_DISCLOSEDROWKEYS = "disclosedRowKeys"; //$NON-NLS-1$
-
- /**
- * "ondblclick" tag attribute name
- */
- public static final String ATTR_ONDBLCLICK = "ondblclick"; //$NON-NLS-1$
-
- /**
- * "windowWidth" tag attribute name
- */
- public static final String ATTR_WINDOWWIDTH = "windowWidth"; //$NON-NLS-1$
-
- /**
- * "rendered" tag attribute name
- */
- public static final String ATTR_RENDERED = "rendered"; //$NON-NLS-1$
-
- /**
- * "invalidDays" tag attribute name
- */
- public static final String ATTR_INVALIDDAYS = "invalidDays"; //$NON-NLS-1$
-
- /**
- * "styleUsage" tag attribute name
- */
- public static final String ATTR_STYLEUSAGE = "styleUsage"; //$NON-NLS-1$
-
- /**
- * "blocking" tag attribute name
- */
- public static final String ATTR_BLOCKING = "blocking"; //$NON-NLS-1$
-
- /**
- * "gradientsUsed" tag attribute name
- */
- public static final String ATTR_GRADIENTSUSED = "gradientsUsed"; //$NON-NLS-1$
-
- /**
- * "legendPosition" tag attribute name
- */
- public static final String ATTR_LEGENDPOSITION = "legendPosition"; //$NON-NLS-1$
-
- /**
- * "rowDisclosureListener" tag attribute name
- */
- public static final String ATTR_ROWDISCLOSURELISTENER = "rowDisclosureListener"; //$NON-NLS-1$
-
- /**
- * "binding" tag attribute name
- */
- public static final String ATTR_BINDING = "binding"; //$NON-NLS-1$
-
- /**
- * "disclosureListener" tag attribute name
- */
- public static final String ATTR_DISCLOSURELISTENER = "disclosureListener"; //$NON-NLS-1$
-
- /**
- * "separatorClass" tag attribute name
- */
- public static final String ATTR_SEPARATORCLASS = "separatorClass"; //$NON-NLS-1$
-
- /**
- * "showRequired" tag attribute name
- */
- public static final String ATTR_SHOWREQUIRED = "showRequired"; //$NON-NLS-1$
-
- /**
- * "messageDetailInvalidDaysOfWeek" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILINVALIDDAYSOFWEEK = "messageDetailInvalidDaysOfWeek"; //$NON-NLS-1$
-
- /**
- * "minimum" tag attribute name
- */
- public static final String ATTR_MINIMUM = "minimum"; //$NON-NLS-1$
-
- /**
- * "simple" tag attribute name
- */
- public static final String ATTR_SIMPLE = "simple"; //$NON-NLS-1$
-
- /**
- * "sortable" tag attribute name
- */
- public static final String ATTR_SORTABLE = "sortable"; //$NON-NLS-1$
-
- /**
- * "discloseMany" tag attribute name
- */
- public static final String ATTR_DISCLOSEMANY = "discloseMany"; //$NON-NLS-1$
-
- /**
- * "maximumLength" tag attribute name
- */
- public static final String ATTR_MAXIMUMLENGTH = "maximumLength"; //$NON-NLS-1$
-
- /**
- * "visited" tag attribute name
- */
- public static final String ATTR_VISITED = "visited"; //$NON-NLS-1$
-
- /**
- * "truncateAt" tag attribute name
- */
- public static final String ATTR_TRUNCATEAT = "truncateAt"; //$NON-NLS-1$
-
- /**
- * "auxiliary1Size" tag attribute name
- */
- public static final String ATTR_AUXILIARY1SIZE = "auxiliary1Size"; //$NON-NLS-1$
-
- /**
- * "converter" tag attribute name
- */
- public static final String ATTR_CONVERTER = "converter"; //$NON-NLS-1$
-
- /**
- * "reorderOnly" tag attribute name
- */
- public static final String ATTR_REORDERONLY = "reorderOnly"; //$NON-NLS-1$
-
- /**
- * "maxValue" tag attribute name
- */
- public static final String ATTR_MAXVALUE = "maxValue"; //$NON-NLS-1$
-
- /**
- * "rowSelection" tag attribute name
- */
- public static final String ATTR_ROWSELECTION = "rowSelection"; //$NON-NLS-1$
-
- /**
- * "tooltipsVisible" tag attribute name
- */
- public static final String ATTR_TOOLTIPSVISIBLE = "tooltipsVisible"; //$NON-NLS-1$
-
- /**
- * "sortProperty" tag attribute name
- */
- public static final String ATTR_SORTPROPERTY = "sortProperty"; //$NON-NLS-1$
-
- /**
- * "YMajorGridLineCount" tag attribute name
- */
- public static final String ATTR_YMAJORGRIDLINECOUNT = "YMajorGridLineCount"; //$NON-NLS-1$
-
- /**
- * "yoffset" tag attribute name
- */
- public static final String ATTR_YOFFSET = "yoffset"; //$NON-NLS-1$
-
- /**
- * "shortDesc" tag attribute name
- */
- public static final String ATTR_SHORTDESC = "shortDesc"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertNumber" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTNUMBER = "messageDetailConvertNumber"; //$NON-NLS-1$
-
- /**
- * "listStyle" tag attribute name
- */
- public static final String ATTR_LISTSTYLE = "listStyle"; //$NON-NLS-1$
-
- /**
- * "readOnly" tag attribute name
- */
- public static final String ATTR_READONLY = "readOnly"; //$NON-NLS-1$
-
- /**
- * "pattern" tag attribute name
- */
- public static final String ATTR_PATTERN = "pattern"; //$NON-NLS-1$
-
- /**
- * "background" tag attribute name
- */
- public static final String ATTR_BACKGROUND = "background"; //$NON-NLS-1$
-
- /**
- * "animationDuration" tag attribute name
- */
- public static final String ATTR_ANIMATIONDURATION = "animationDuration"; //$NON-NLS-1$
-
- /**
- * "labelAndAccessKey" tag attribute name
- */
- public static final String ATTR_LABELANDACCESSKEY = "labelAndAccessKey"; //$NON-NLS-1$
-
- /**
- * "titleClass" tag attribute name
- */
- public static final String ATTR_TITLECLASS = "titleClass"; //$NON-NLS-1$
-
- /**
- * "minFractionDigits" tag attribute name
- */
- public static final String ATTR_MINFRACTIONDIGITS = "minFractionDigits"; //$NON-NLS-1$
-
- /**
- * "to" tag attribute name
- */
- public static final String ATTR_TO = "to"; //$NON-NLS-1$
-
- /**
- * "player" tag attribute name
- */
- public static final String ATTR_PLAYER = "player"; //$NON-NLS-1$
-
- /**
- * "globalOnly" tag attribute name
- */
- public static final String ATTR_GLOBALONLY = "globalOnly"; //$NON-NLS-1$
-
- /**
- * "messageDetailInvalidMonths" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILINVALIDMONTHS = "messageDetailInvalidMonths"; //$NON-NLS-1$
-
- /**
- * "secondaryPattern" tag attribute name
- */
- public static final String ATTR_SECONDARYPATTERN = "secondaryPattern"; //$NON-NLS-1$
-
- /**
- * "previousAction" tag attribute name
- */
- public static final String ATTR_PREVIOUSACTION = "previousAction"; //$NON-NLS-1$
-
- /**
- * "columnBandingInterval" tag attribute name
- */
- public static final String ATTR_COLUMNBANDINGINTERVAL = "columnBandingInterval"; //$NON-NLS-1$
-
- /**
- * "noWrap" tag attribute name
- */
- public static final String ATTR_NOWRAP = "noWrap"; //$NON-NLS-1$
-
- /**
- * "startLevel" tag attribute name
- */
- public static final String ATTR_STARTLEVEL = "startLevel"; //$NON-NLS-1$
-
- /**
- * "valueChangeListener" tag attribute name
- */
- public static final String ATTR_VALUECHANGELISTENER = "valueChangeListener"; //$NON-NLS-1$
-
- /**
- * "compact" tag attribute name
- */
- public static final String ATTR_COMPACT = "compact"; //$NON-NLS-1$
-
- /**
- * "autoSubmit" tag attribute name
- */
- public static final String ATTR_AUTOSUBMIT = "autoSubmit"; //$NON-NLS-1$
-
- /**
- * "height" tag attribute name
- */
- public static final String ATTR_HEIGHT = "height"; //$NON-NLS-1$
-
- /**
- * "horizontalGridVisible" tag attribute name
- */
- public static final String ATTR_HORIZONTALGRIDVISIBLE = "horizontalGridVisible"; //$NON-NLS-1$
-
- /**
- * "YMinorGridLineCount" tag attribute name
- */
- public static final String ATTR_YMINORGRIDLINECOUNT = "YMinorGridLineCount"; //$NON-NLS-1$
-
- /**
- * "description" tag attribute name
- */
- public static final String ATTR_DESCRIPTION = "description"; //$NON-NLS-1$
-
- /**
- * "onblur" tag attribute name
- */
- public static final String ATTR_ONBLUR = "onblur"; //$NON-NLS-1$
-
- /**
- * "longDesc" tag attribute name
- */
- public static final String ATTR_LONGDESC = "longDesc"; //$NON-NLS-1$
-
- /**
- * "perspective" tag attribute name
- */
- public static final String ATTR_PERSPECTIVE = "perspective"; //$NON-NLS-1$
-
- /**
- * "trailingHeader" tag attribute name
- */
- public static final String ATTR_TRAILINGHEADER = "trailingHeader"; //$NON-NLS-1$
-
- /**
- * "text" tag attribute name
- */
- public static final String ATTR_TEXT = "text"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvert" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERT = "messageDetailConvert"; //$NON-NLS-1$
-
- /**
- * "onmouseout" tag attribute name
- */
- public static final String ATTR_ONMOUSEOUT = "onmouseout"; //$NON-NLS-1$
-
- /**
- * "partialSubmit" tag attribute name
- */
- public static final String ATTR_PARTIALSUBMIT = "partialSubmit"; //$NON-NLS-1$
-
- /**
- * "align" tag attribute name
- */
- public static final String ATTR_ALIGN = "align"; //$NON-NLS-1$
-
- /**
- * "width" tag attribute name
- */
- public static final String ATTR_WIDTH = "width"; //$NON-NLS-1$
-
- /**
- * "onkeyup" tag attribute name
- */
- public static final String ATTR_ONKEYUP = "onkeyup"; //$NON-NLS-1$
-
- /**
- * "onfocus" tag attribute name
- */
- public static final String ATTR_ONFOCUS = "onfocus"; //$NON-NLS-1$
-
- /**
- * "label" tag attribute name
- */
- public static final String ATTR_LABEL = "label"; //$NON-NLS-1$
-
- /**
- * "componentType" tag attribute name
- */
- public static final String ATTR_COMPONENTTYPE = "componentType"; //$NON-NLS-1$
-
- /**
- * "autostart" tag attribute name
- */
- public static final String ATTR_AUTOSTART = "autostart"; //$NON-NLS-1$
-
- /**
- * "discloseNone" tag attribute name
- */
- public static final String ATTR_DISCLOSENONE = "discloseNone"; //$NON-NLS-1$
-
- /**
- * "size" tag attribute name
- */
- public static final String ATTR_SIZE = "size"; //$NON-NLS-1$
-
- /**
- * "standbyText" tag attribute name
- */
- public static final String ATTR_STANDBYTEXT = "standbyText"; //$NON-NLS-1$
-
- /**
- * "onselect" tag attribute name
- */
- public static final String ATTR_ONSELECT = "onselect"; //$NON-NLS-1$
-
- /**
- * "items" tag attribute name
- */
- public static final String ATTR_ITEMS = "items"; //$NON-NLS-1$
-
- /**
- * "names" tag attribute name
- */
- public static final String ATTR_NAMES = "names"; //$NON-NLS-1$
-
- /**
- * "maximum" tag attribute name
- */
- public static final String ATTR_MAXIMUM = "maximum"; //$NON-NLS-1$
-
- /**
- * "disclosed" tag attribute name
- */
- public static final String ATTR_DISCLOSED = "disclosed"; //$NON-NLS-1$
-
- /**
- * "rowsByDepth" tag attribute name
- */
- public static final String ATTR_ROWSBYDEPTH = "rowsByDepth"; //$NON-NLS-1$
-
- /**
- * "maxStep" tag attribute name
- */
- public static final String ATTR_MAXSTEP = "maxStep"; //$NON-NLS-1$
-
- /**
- * "var" tag attribute name
- */
- public static final String ATTR_VAR = "var"; //$NON-NLS-1$
-
- /**
- * "focusRowKey" tag attribute name
- */
- public static final String ATTR_FOCUSROWKEY = "focusRowKey"; //$NON-NLS-1$
-
- /**
- * "unselectedLabel" tag attribute name
- */
- public static final String ATTR_UNSELECTEDLABEL = "unselectedLabel"; //$NON-NLS-1$
-
- /**
- * "searchDesc" tag attribute name
- */
- public static final String ATTR_SEARCHDESC = "searchDesc"; //$NON-NLS-1$
-
- /**
- * "pollListener" tag attribute name
- */
- public static final String ATTR_POLLLISTENER = "pollListener"; //$NON-NLS-1$
-
- /**
- * "name" tag attribute name
- */
- public static final String ATTR_NAME = "name"; //$NON-NLS-1$
-
- /**
- * "valueAndAccessKey" tag attribute name
- */
- public static final String ATTR_VALUEANDACCESSKEY = "valueAndAccessKey"; //$NON-NLS-1$
-
- /**
- * "XMajorGridLineCount" tag attribute name
- */
- public static final String ATTR_XMAJORGRIDLINECOUNT = "XMajorGridLineCount"; //$NON-NLS-1$
-
- /**
- * "nextActionListener" tag attribute name
- */
- public static final String ATTR_NEXTACTIONLISTENER = "nextActionListener"; //$NON-NLS-1$
-
- /**
- * "maxIntegerDigits" tag attribute name
- */
- public static final String ATTR_MAXINTEGERDIGITS = "maxIntegerDigits"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertTime" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTTIME = "messageDetailConvertTime"; //$NON-NLS-1$
-
- /**
- * "icon" tag attribute name
- */
- public static final String ATTR_ICON = "icon"; //$NON-NLS-1$
-
- /**
- * "undisclosedText" tag attribute name
- */
- public static final String ATTR_UNDISCLOSEDTEXT = "undisclosedText"; //$NON-NLS-1$
-
- /**
- * "disclosedText" tag attribute name
- */
- public static final String ATTR_DISCLOSEDTEXT = "disclosedText"; //$NON-NLS-1$
-
- /**
- * "onmouseover" tag attribute name
- */
- public static final String ATTR_ONMOUSEOVER = "onmouseover"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertPattern" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTPATTERN = "messageDetailConvertPattern"; //$NON-NLS-1$
-
- /**
- * "message" tag attribute name
- */
- public static final String ATTR_MESSAGE = "message"; //$NON-NLS-1$
-
- /**
- * "immediate" tag attribute name
- */
- public static final String ATTR_IMMEDIATE = "immediate"; //$NON-NLS-1$
-
- /**
- * "messageDetailNoMatch" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILNOMATCH = "messageDetailNoMatch"; //$NON-NLS-1$
-
- /**
- * "source" tag attribute name
- */
- public static final String ATTR_SOURCE = "source"; //$NON-NLS-1$
-
- /**
- * "usesUpload" tag attribute name
- */
- public static final String ATTR_USESUPLOAD = "usesUpload"; //$NON-NLS-1$
-
- /**
- * "onclick" tag attribute name
- */
- public static final String ATTR_ONCLICK = "onclick"; //$NON-NLS-1$
-
- /**
- * "valign" tag attribute name
- */
- public static final String ATTR_VALIGN = "valign"; //$NON-NLS-1$
-
- /**
- * "disabled" tag attribute name
- */
- public static final String ATTR_DISABLED = "disabled"; //$NON-NLS-1$
-
- /**
- * "nextAction" tag attribute name
- */
- public static final String ATTR_NEXTACTION = "nextAction"; //$NON-NLS-1$
-
- /**
- * "facetName" tag attribute name
- */
- public static final String ATTR_FACETNAME = "facetName"; //$NON-NLS-1$
-
- /**
- * "for" tag attribute name
- */
- public static final String ATTR_FOR = "for"; //$NON-NLS-1$
-
- /**
- * "defaultFacet" tag attribute name
- */
- public static final String ATTR_DEFAULTFACET = "defaultFacet"; //$NON-NLS-1$
-
- /**
- * "defaultCommand" tag attribute name
- */
- public static final String ATTR_DEFAULTCOMMAND = "defaultCommand"; //$NON-NLS-1$
-
- /**
- * "minValue" tag attribute name
- */
- public static final String ATTR_MINVALUE = "minValue"; //$NON-NLS-1$
-
- /**
- * "labelStyle" tag attribute name
- */
- public static final String ATTR_LABELSTYLE = "labelStyle"; //$NON-NLS-1$
-
- /**
- * "textAndAccessKey" tag attribute name
- */
- public static final String ATTR_TEXTANDACCESSKEY = "textAndAccessKey"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertPercent" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTPERCENT = "messageDetailConvertPercent"; //$NON-NLS-1$
-
- /**
- * "valuePassThru" tag attribute name
- */
- public static final String ATTR_VALUEPASSTHRU = "valuePassThru"; //$NON-NLS-1$
-
- /**
- * "imageMapType" tag attribute name
- */
- public static final String ATTR_IMAGEMAPTYPE = "imageMapType"; //$NON-NLS-1$
-
- /**
- * "chartDrillDownListener" tag attribute name
- */
- public static final String ATTR_CHARTDRILLDOWNLISTENER = "chartDrillDownListener"; //$NON-NLS-1$
-
- /**
- * "fieldWidth" tag attribute name
- */
- public static final String ATTR_FIELDWIDTH = "fieldWidth"; //$NON-NLS-1$
-
- /**
- * "auxiliaryGlobalSize" tag attribute name
- */
- public static final String ATTR_AUXILIARYGLOBALSIZE = "auxiliaryGlobalSize"; //$NON-NLS-1$
-
- /**
- * "triggerType" tag attribute name
- */
- public static final String ATTR_TRIGGERTYPE = "triggerType"; //$NON-NLS-1$
-
- /**
- * "orientation" tag attribute name
- */
- public static final String ATTR_ORIENTATION = "orientation"; //$NON-NLS-1$
-
- /**
- * "inlineStyle" tag attribute name
- */
- public static final String ATTR_INLINESTYLE = "inlineStyle"; //$NON-NLS-1$
-
- /**
- * "timeStyle" tag attribute name
- */
- public static final String ATTR_TIMESTYLE = "timeStyle"; //$NON-NLS-1$
-
- /**
- * "flex" tag attribute name
- */
- public static final String ATTR_FLEX = "flex"; //$NON-NLS-1$
-
- /**
- * "destination" tag attribute name
- */
- public static final String ATTR_DESTINATION = "destination"; //$NON-NLS-1$
-
- /**
- * "innerWidth" tag attribute name
- */
- public static final String ATTR_INNERWIDTH = "innerWidth"; //$NON-NLS-1$
-
- /**
- * "useWindow" tag attribute name
- */
- public static final String ATTR_USEWINDOW = "useWindow"; //$NON-NLS-1$
-
- /**
- * "verticalGridVisible" tag attribute name
- */
- public static final String ATTR_VERTICALGRIDVISIBLE = "verticalGridVisible"; //$NON-NLS-1$
-
- /**
- * "onmousedown" tag attribute name
- */
- public static final String ATTR_ONMOUSEDOWN = "onmousedown"; //$NON-NLS-1$
-
- /**
- * "invalidDaysOfWeek" tag attribute name
- */
- public static final String ATTR_INVALIDDAYSOFWEEK = "invalidDaysOfWeek"; //$NON-NLS-1$
-
- /**
- * "headerNoWrap" tag attribute name
- */
- public static final String ATTR_HEADERNOWRAP = "headerNoWrap"; //$NON-NLS-1$
-
- /**
- * "invalidMonths" tag attribute name
- */
- public static final String ATTR_INVALIDMONTHS = "invalidMonths"; //$NON-NLS-1$
-
- /**
- * "headerText" tag attribute name
- */
- public static final String ATTR_HEADERTEXT = "headerText"; //$NON-NLS-1$
-
- /**
- * "actionListener" tag attribute name
- */
- public static final String ATTR_ACTIONLISTENER = "actionListener"; //$NON-NLS-1$
-
- /**
- * "attributeChangeListener" tag attribute name
- */
- public static final String ATTR_ATTRIBUTECHANGELISTENER = "attributeChangeListener"; //$NON-NLS-1$
-
- /**
- * "position" tag attribute name
- */
- public static final String ATTR_POSITION = "position"; //$NON-NLS-1$
-
- /**
- * "previousActionListener" tag attribute name
- */
- public static final String ATTR_PREVIOUSACTIONLISTENER = "previousActionListener"; //$NON-NLS-1$
-
- /**
- * "interval" tag attribute name
- */
- public static final String ATTR_INTERVAL = "interval"; //$NON-NLS-1$
-
- /**
- * "allDetailsEnabled" tag attribute name
- */
- public static final String ATTR_ALLDETAILSENABLED = "allDetailsEnabled"; //$NON-NLS-1$
-
- /**
- * "validator" tag attribute name
- */
- public static final String ATTR_VALIDATOR = "validator"; //$NON-NLS-1$
-
- /**
- * "onunload" tag attribute name
- */
- public static final String ATTR_ONUNLOAD = "onunload"; //$NON-NLS-1$
-
- /**
- * "maxFractionDigits" tag attribute name
- */
- public static final String ATTR_MAXFRACTIONDIGITS = "maxFractionDigits"; //$NON-NLS-1$
-
- /**
- * "leadingDescShown" tag attribute name
- */
- public static final String ATTR_LEADINGDESCSHOWN = "leadingDescShown"; //$NON-NLS-1$
-
- /**
- * "emptyText" tag attribute name
- */
- public static final String ATTR_EMPTYTEXT = "emptyText"; //$NON-NLS-1$
-
- /**
- * "trailingDescShown" tag attribute name
- */
- public static final String ATTR_TRAILINGDESCSHOWN = "trailingDescShown"; //$NON-NLS-1$
-
- /**
- * "escape" tag attribute name
- */
- public static final String ATTR_ESCAPE = "escape"; //$NON-NLS-1$
-
- /**
- * "mode" tag attribute name
- */
- public static final String ATTR_MODE = "mode"; //$NON-NLS-1$
-
- /**
- * "messageDetailInvalidDays" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILINVALIDDAYS = "messageDetailInvalidDays"; //$NON-NLS-1$
-
- /**
- * "title" tag attribute name
- */
- public static final String ATTR_TITLE = "title"; //$NON-NLS-1$
-
- /**
- * "captionText" tag attribute name
- */
- public static final String ATTR_CAPTIONTEXT = "captionText"; //$NON-NLS-1$
-
- /**
- * "stepSize" tag attribute name
- */
- public static final String ATTR_STEPSIZE = "stepSize"; //$NON-NLS-1$
-
- /**
- * "encoding" tag attribute name
- */
- public static final String ATTR_ENCODING = "encoding"; //$NON-NLS-1$
-
- /**
- * "modal" tag attribute name
- */
- public static final String ATTR_MODAL = "modal"; //$NON-NLS-1$
-
- /**
- * "end" tag attribute name
- */
- public static final String ATTR_END = "end"; //$NON-NLS-1$
-
- /**
- * "onkeypress" tag attribute name
- */
- public static final String ATTR_ONKEYPRESS = "onkeypress"; //$NON-NLS-1$
-
- /**
- * "onkeydown" tag attribute name
- */
- public static final String ATTR_ONKEYDOWN = "onkeydown"; //$NON-NLS-1$
-
- /**
- * "innerHeight" tag attribute name
- */
- public static final String ATTR_INNERHEIGHT = "innerHeight"; //$NON-NLS-1$
-
- /**
- * "messageType" tag attribute name
- */
- public static final String ATTR_MESSAGETYPE = "messageType"; //$NON-NLS-1$
-
- /**
- * "onsubmit" tag attribute name
- */
- public static final String ATTR_ONSUBMIT = "onsubmit"; //$NON-NLS-1$
-
- /**
- * "selectedStep" tag attribute name
- */
- public static final String ATTR_SELECTEDSTEP = "selectedStep"; //$NON-NLS-1$
-
- /**
- * "rowBandingInterval" tag attribute name
- */
- public static final String ATTR_ROWBANDINGINTERVAL = "rowBandingInterval"; //$NON-NLS-1$
-
- /**
- * "varStatus" tag attribute name
- */
- public static final String ATTR_VARSTATUS = "varStatus"; //$NON-NLS-1$
-
- /**
- * "xoffset" tag attribute name
- */
- public static final String ATTR_XOFFSET = "xoffset"; //$NON-NLS-1$
-
- /**
- * "currencySymbol" tag attribute name
- */
- public static final String ATTR_CURRENCYSYMBOL = "currencySymbol"; //$NON-NLS-1$
-
- /**
- * "selectedRowKeys" tag attribute name
- */
- public static final String ATTR_SELECTEDROWKEYS = "selectedRowKeys"; //$NON-NLS-1$
-
- /**
- * "method" tag attribute name
- */
- public static final String ATTR_METHOD = "method"; //$NON-NLS-1$
-
- /**
- * "messageDetailExact" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILEXACT = "messageDetailExact"; //$NON-NLS-1$
-
- /**
- * "messageDetailNotInRange" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILNOTINRANGE = "messageDetailNotInRange"; //$NON-NLS-1$
-
- /**
- * "launchListener" tag attribute name
- */
- public static final String ATTR_LAUNCHLISTENER = "launchListener"; //$NON-NLS-1$
-
- /**
- * "templateSource" tag attribute name
- */
- public static final String ATTR_TEMPLATESOURCE = "templateSource"; //$NON-NLS-1$
-
- /**
- * "maxPrecision" tag attribute name
- */
- public static final String ATTR_MAXPRECISION = "maxPrecision"; //$NON-NLS-1$
-
- /**
- * "targetFrame" tag attribute name
- */
- public static final String ATTR_TARGETFRAME = "targetFrame"; //$NON-NLS-1$
-
- /**
- * "messageDetailConvertDate" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILCONVERTDATE = "messageDetailConvertDate"; //$NON-NLS-1$
-
- /**
- * "focusListener" tag attribute name
- */
- public static final String ATTR_FOCUSLISTENER = "focusListener"; //$NON-NLS-1$
-
- /**
- * "contentType" tag attribute name
- */
- public static final String ATTR_CONTENTTYPE = "contentType"; //$NON-NLS-1$
-
- /**
- * "type" tag attribute name
- */
- public static final String ATTR_TYPE = "type"; //$NON-NLS-1$
-
- /**
- * "initiallyExpanded" tag attribute name
- */
- public static final String ATTR_INITIALLYEXPANDED = "initiallyExpanded"; //$NON-NLS-1$
-
- /**
- * "selectionListener" tag attribute name
- */
- public static final String ATTR_SELECTIONLISTENER = "selectionListener"; //$NON-NLS-1$
-
- /**
- * "level" tag attribute name
- */
- public static final String ATTR_LEVEL = "level"; //$NON-NLS-1$
-
- /**
- * "action" tag attribute name
- */
- public static final String ATTR_ACTION = "action"; //$NON-NLS-1$
-
- /**
- * "value" tag attribute name
- */
- public static final String ATTR_VALUE = "value"; //$NON-NLS-1$
-
- /**
- * "auxiliary2Size" tag attribute name
- */
- public static final String ATTR_AUXILIARY2SIZE = "auxiliary2Size"; //$NON-NLS-1$
-
- /**
- * "required" tag attribute name
- */
- public static final String ATTR_REQUIRED = "required"; //$NON-NLS-1$
-
- /**
- * "integerOnly" tag attribute name
- */
- public static final String ATTR_INTEGERONLY = "integerOnly"; //$NON-NLS-1$
-
- /**
- * "wrap" tag attribute name
- */
- public static final String ATTR_WRAP = "wrap"; //$NON-NLS-1$
-
- /**
- * "chooseId" tag attribute name
- */
- public static final String ATTR_CHOOSEID = "chooseId"; //$NON-NLS-1$
-
- /**
- * "requiredMessageDetail" tag attribute name
- */
- public static final String ATTR_REQUIREDMESSAGEDETAIL = "requiredMessageDetail"; //$NON-NLS-1$
-
- /**
- * "styleClass" tag attribute name
- */
- public static final String ATTR_STYLECLASS = "styleClass"; //$NON-NLS-1$
-
- /**
- * "customColorData" tag attribute name
- */
- public static final String ATTR_CUSTOMCOLORDATA = "customColorData"; //$NON-NLS-1$
-
- /**
- * "rows" tag attribute name
- */
- public static final String ATTR_ROWS = "rows"; //$NON-NLS-1$
-
- /**
- * "groupingUsed" tag attribute name
- */
- public static final String ATTR_GROUPINGUSED = "groupingUsed"; //$NON-NLS-1$
-
- /**
- * "playCount" tag attribute name
- */
- public static final String ATTR_PLAYCOUNT = "playCount"; //$NON-NLS-1$
-
- /**
- * "default" tag attribute name
- */
- public static final String ATTR_DEFAULT = "default"; //$NON-NLS-1$
-
- /**
- * "contentStyle" tag attribute name
- */
- public static final String ATTR_CONTENTSTYLE = "contentStyle"; //$NON-NLS-1$
-
- /**
- * "maxColumns" tag attribute name
- */
- public static final String ATTR_MAXCOLUMNS = "maxColumns"; //$NON-NLS-1$
-
- /**
- * "alignment" tag attribute name
- */
- public static final String ATTR_ALIGNMENT = "alignment"; //$NON-NLS-1$
-
- /**
- * "leadingHeader" tag attribute name
- */
- public static final String ATTR_LEADINGHEADER = "leadingHeader"; //$NON-NLS-1$
-
- /**
- * "locale" tag attribute name
- */
- public static final String ATTR_LOCALE = "locale"; //$NON-NLS-1$
-
- /**
- * "messageDetailMaximum" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILMAXIMUM = "messageDetailMaximum"; //$NON-NLS-1$
-
- /**
- * "windowHeight" tag attribute name
- */
- public static final String ATTR_WINDOWHEIGHT = "windowHeight"; //$NON-NLS-1$
-
- /**
- * "timeZone" tag attribute name
- */
- public static final String ATTR_TIMEZONE = "timeZone"; //$NON-NLS-1$
-
- /**
- * "from" tag attribute name
- */
- public static final String ATTR_FROM = "from"; //$NON-NLS-1$
-
- /**
- * "messageDetailMinimum" tag attribute name
- */
- public static final String ATTR_MESSAGEDETAILMINIMUM = "messageDetailMinimum"; //$NON-NLS-1$
-
- /**
- * "id" tag attribute name
- */
- public static final String ATTR_ID = "id"; //$NON-NLS-1$
-
- /**
- * "returnListener" tag attribute name
- */
- public static final String ATTR_RETURNLISTENER = "returnListener"; //$NON-NLS-1$
-
- /**
- * "controls" tag attribute name
- */
- public static final String ATTR_CONTROLS = "controls"; //$NON-NLS-1$
-
- /**
- * "disclosedTransient" tag attribute name
- */
- public static final String ATTR_DISCLOSEDTRANSIENT = "disclosedTransient"; //$NON-NLS-1$
-
- /**
- * "selected" tag attribute name
- */
- public static final String ATTR_SELECTED = "selected"; //$NON-NLS-1$
-
- /**
- * "dateStyle" tag attribute name
- */
- public static final String ATTR_DATESTYLE = "dateStyle"; //$NON-NLS-1$
-
- /**
- * "minIntegerDigits" tag attribute name
- */
- public static final String ATTR_MININTEGERDIGITS = "minIntegerDigits"; //$NON-NLS-1$
-
- /**
- * "onmouseup" tag attribute name
- */
- public static final String ATTR_ONMOUSEUP = "onmouseup"; //$NON-NLS-1$
-
- /**
- * "layout" tag attribute name
- */
- public static final String ATTR_LAYOUT = "layout"; //$NON-NLS-1$
-
- /**
- * "expandAllEnabled" tag attribute name
- */
- public static final String ATTR_EXPANDALLENABLED = "expandAllEnabled"; //$NON-NLS-1$
-
- /**
- * "onmousemove" tag attribute name
- */
- public static final String ATTR_ONMOUSEMOVE = "onmousemove"; //$NON-NLS-1$
-
- /**
- * "halign" tag attribute name
- */
- public static final String ATTR_HALIGN = "halign"; //$NON-NLS-1$
-
- /**
- * "labelWidth" tag attribute name
- */
- public static final String ATTR_LABELWIDTH = "labelWidth"; //$NON-NLS-1$
-
- /**
- * "currencyCode" tag attribute name
- */
- public static final String ATTR_CURRENCYCODE = "currencyCode"; //$NON-NLS-1$
-
- /**
- * "partialTriggers" tag attribute name
- */
- public static final String ATTR_PARTIALTRIGGERS = "partialTriggers"; //$NON-NLS-1$
-
- /**
- * "separateRows" tag attribute name
- */
- public static final String ATTR_SEPARATEROWS = "separateRows"; //$NON-NLS-1$
-
- /**
- * "hint" tag attribute name
- */
- public static final String ATTR_HINT = "hint"; //$NON-NLS-1$
-
- /**
- * "onchange" tag attribute name
- */
- public static final String ATTR_ONCHANGE = "onchange"; //$NON-NLS-1$
-
- /**
- * "begin" tag attribute name
- */
- public static final String ATTR_BEGIN = "begin"; //$NON-NLS-1$
-
- /**
- * "longDescURL" tag attribute name
- */
- public static final String ATTR_LONGDESCURL = "longDescURL"; //$NON-NLS-1$
-
- /**
- * "onload" tag attribute name
- */
- public static final String ATTR_ONLOAD = "onload"; //$NON-NLS-1$
-
- /**
- * "sortListener" tag attribute name
- */
- public static final String ATTR_SORTLISTENER = "sortListener"; //$NON-NLS-1$
-
- /**
- * "filename" tag attribute name
- */
- public static final String ATTR_FILENAME = "filename"; //$NON-NLS-1$
-
- /**
- * "secret" tag attribute name
- */
- public static final String ATTR_SECRET = "secret"; //$NON-NLS-1$
-
- /**
- * "group" tag attribute name
- */
- public static final String ATTR_GROUP = "group"; //$NON-NLS-1$
-
- /**
- * "first" tag attribute name
- */
- public static final String ATTR_FIRST = "first"; //$NON-NLS-1$
-
- /**
- * "step" tag attribute name
- */
- public static final String ATTR_STEP = "step"; //$NON-NLS-1$
-
- /**
- * "headers" tag attribute name
- */
- public static final String ATTR_HEADERS = "headers"; //$NON-NLS-1$
-
- /**
- * "generatesContent" tag attribute name
- */
- public static final String ATTR_GENERATESCONTENT = "generatesContent"; //$NON-NLS-1$
-
- /**
- * "marginHeight" tag attribute name
- */
- public static final String ATTR_MARGINHEIGHT = "marginHeight"; //$NON-NLS-1$
-
- /**
- * "cellPadding" tag attribute name
- */
- public static final String ATTR_CELLPADDING = "cellPadding"; //$NON-NLS-1$
-
- /**
- * "wrappingDisabled" tag attribute name
- */
- public static final String ATTR_WRAPPINGDISABLED = "wrappingDisabled"; //$NON-NLS-1$
-
- /**
- * "rowSpan" tag attribute name
- */
- public static final String ATTR_ROWSPAN = "rowSpan"; //$NON-NLS-1$
-
- /**
- * "columnSpan" tag attribute name
- */
- public static final String ATTR_COLUMNSPAN = "columnSpan"; //$NON-NLS-1$
-
- /**
- * "frameSpacing" tag attribute name
- */
- public static final String ATTR_FRAMESPACING = "frameSpacing"; //$NON-NLS-1$
-
- /**
- * "cellSpacing" tag attribute name
- */
- public static final String ATTR_CELLSPACING = "cellSpacing"; //$NON-NLS-1$
-
- /**
- * "header" tag attribute name
- */
- public static final String ATTR_HEADER = "header"; //$NON-NLS-1$
-
- /**
- * "scrolling" tag attribute name
- */
- public static final String ATTR_SCROLLING = "scrolling"; //$NON-NLS-1$
-
- /**
- * "borderWidth" tag attribute name
- */
- public static final String ATTR_BORDERWIDTH = "borderWidth"; //$NON-NLS-1$
-
- /**
- * "frameBorderWidth" tag attribute name
- */
- public static final String ATTR_FRAMEBORDERWIDTH = "frameBorderWidth"; //$NON-NLS-1$
-
- /**
- * "shortText" tag attribute name
- */
- public static final String ATTR_SHORTTEXT = "shortText"; //$NON-NLS-1$
-
- /**
- * "marginWidth" tag attribute name
- */
- public static final String ATTR_MARGINWIDTH = "marginWidth"; //$NON-NLS-1$
-
- /**
- * "firstClickPassed" tag attribute name
- */
- public static final String ATTR_FIRSTCLICKPASSED = "firstClickPassed"; //$NON-NLS-1$
-
- /**
- * Value for "style" attribute on elements used to indicate an empty source
- * element.
- */
- public static final String STYLE_EMPTYELEMENT = "color:silver;font-family:Arial,Helvetica,Geneva,sans-serif;font-size:8pt;"; //$NON-NLS-1$
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/Messages.java
deleted file mode 100644
index 02407b16b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/Messages.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler.
- *
- * @author Ian Trimble - Oracle
- */
-public class Messages extends NLS {
-
- private static final String BUNDLE_NAME =
- "org.eclipse.jst.jsf.apache.trinidad.tagsupport.messages"; //$NON-NLS-1$
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- /**
- * See messages.properties.
- */
- public static String PanelTabbedOperation_EmptyPanelTabbedTag;
-
- /**
- * See messages.properties.
- */
- public static String ShowDetailItemOperation_EmptyShowDetailItemTag;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem1Label;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem1Value;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem2Label;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem2Value;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem3Label;
-
- /**
- * See messages.properties.
- */
- public static String SelectItemModel_SampleItem3Value;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_Description;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkMove;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkMoveAll;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkRemove;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkRemoveAll;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkTop;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkUp;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkDown;
-
- /**
- * See messages.properties.
- */
- public static String SelectShuttleOperation_LinkBottom;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadTagSupportActivator.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadTagSupportActivator.java
deleted file mode 100644
index a276157f8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadTagSupportActivator.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport;
-
-import org.eclipse.core.runtime.ILog;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class TrinidadTagSupportActivator extends AbstractUIPlugin {
-
- /**
- * the plugin id
- */
- public static final String PLUGIN_ID = "org.eclipse.jst.jsf.apache.trinidad.tagsupport"; //$NON-NLS-1$
-
- // The shared instance
- private static TrinidadTagSupportActivator plugin;
-
- /**
- * The constructor
- */
- public TrinidadTagSupportActivator() {
- // do nothing
- }
-
- /*
- * (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 TrinidadTagSupportActivator getDefault() {
- return plugin;
- }
-
- /**
- * Writes an informational message to this plug-in's log.
- *
- * @param message Informational message to be written.
- */
- public static void logInfo(String message) {
- ILog log = getDefault().getLog();
- log.log(new Status(IStatus.INFO, PLUGIN_ID, message));
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadUtils.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadUtils.java
deleted file mode 100644
index 97991e448..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/TrinidadUtils.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport;
-
-import org.w3c.dom.Node;
-
-/**
- * Utility class for the Trinidad Tag Support plug-in.
- *
- * @author Ian Trimble - Oracle
- */
-public class TrinidadUtils {
-
- private static final String KEY_CURRENT_CHILD_INDEX =
- "KEY_CURRENT_CHILD_INDEX"; //$NON-NLS-1$
-
- /**
- * Sets the index of the Node instance's "current" child as user data on
- * the Node instance.
- *
- * @param node Node instance on which to set index.
- * @param index Index of node's "current" child.
- * @return true if index has changed, else false.
- */
- public static boolean setCurrentChildIndex(Node node, int index) {
- boolean indexChanged = false;
- if (node != null) {
- int currentIndex = getCurrentChildIndex(node);
- if (currentIndex != index) {
- node.setUserData(
- KEY_CURRENT_CHILD_INDEX,
- new Integer(index),
- null);
- indexChanged = true;
- }
- }
- return indexChanged;
- }
-
- /**
- * Gets the index of the Node instance's "current" child from user data on
- * the Node instance.
- *
- * @param node Node instance from which to get index.
- * @return Index of node's "current" child. A value of -1 indicates
- * inability to get index from node.
- */
- public static int getCurrentChildIndex(Node node) {
- int index = -1;
- if (node != null) {
- Object obj = node.getUserData(KEY_CURRENT_CHILD_INDEX);
- if (obj instanceof Integer) {
- index = ((Integer)obj).intValue();
- }
- }
- return index;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractLabelAndHelpOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractLabelAndHelpOperation.java
deleted file mode 100644
index 4232cc356..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractLabelAndHelpOperation.java
+++ /dev/null
@@ -1,250 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.IJSFConstants;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.ITransformOperation;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.operations.TransformOperationFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.Text;
-
-/**
- * Abstract ITransformOperation implementation for tags which may be preceded by
- * a label and may have a "help" facet.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public abstract class AbstractLabelAndHelpOperation extends AbstractTrinidadTransformOperation {
-
- private static final String STYLE_OUTERELEMENT = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;"; //$NON-NLS-1$
- private static final String STYLE_LABELTD = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;text-align:right;color:#000000;padding:0px 8px 0px 0px;font-weight:normal;"; //$NON-NLS-1$
- private static final String STYLE_REQUIREDSPAN = "color:#669966;font-family:Courier,sans-serif;"; //$NON-NLS-1$
- protected static final String STYLE_CONTROLELEMENT = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;"; //$NON-NLS-1$
- private static final String STYLE_HELPSPAN = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:8pt;font-weight:normal;color:#669966;"; //$NON-NLS-1$
-
- /**
- * Subclasses must implement this method to append the desired DOM structure
- * that represents the HTML control(s) to parentElement.
- *
- * @param srcElement Source Element representing source document tag.
- * @param parentElement Parent Element to which structure is appended.
- */
- protected abstract void appendControl(Element srcElement, Element parentElement);
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- Element outerElement;
-
- //create outer Element
- String simple = srcElement.getAttribute("simple"); //$NON-NLS-1$
- if (Boolean.valueOf(simple)) {
- outerElement = createElement("span"); //$NON-NLS-1$
- } else {
- outerElement = createElement("table"); //$NON-NLS-1$
- //append table-specific attributes
- appendAttribute(outerElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- //append common attributes
- ITransformOperation operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"styleClass", "class"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(srcElement, outerElement);
- appendAttribute(outerElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_OUTERELEMENT, srcElement, "inlineStyle")); //$NON-NLS-1$
-
- if (Boolean.valueOf(simple)) {
- //continue building simple variant
- appendControl(srcElement, outerElement);
- } else {
- //continue building non-simple variant
- Element trElement = appendChildElement("tr", outerElement); //$NON-NLS-1$
-
- if (isRequired(srcElement) || getLabel(srcElement) != null) {
- //if either required or has label, build top-left table cell
- Element tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdElement, "style", STYLE_LABELTD); //$NON-NLS-1$
- appendAttribute(tdElement, "valign", "top"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
-
- if (isRequired(srcElement)) {
- Element spanElement = appendChildElement("span", tdElement); //$NON-NLS-1$
- appendAttribute(spanElement, "title", "Required"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(spanElement, "style", STYLE_REQUIREDSPAN); //$NON-NLS-1$
- appendChildText("* ", spanElement); //$NON-NLS-1$
- }
-
- if (getLabel(srcElement) != null) {
- Element labelElement = appendChildElement("label", tdElement); //$NON-NLS-1$
- appendChildText(getLabel(srcElement), labelElement);
- }
- }
-
- //build content table cell
- Element tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdElement, "valign", "top"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendControl(srcElement, tdElement);
-
- List<Node> helpFacetChildNodes = getHelpFacetChildNodes(srcElement);
- if (helpFacetChildNodes.size() > 0) {
- //build help table row
- trElement = appendChildElement("tr", outerElement); //$NON-NLS-1$
- if (isRequired(srcElement) || getLabel(srcElement) != null) {
- tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- }
- tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- Element spanElement = appendChildElement("span", tdElement); //$NON-NLS-1$
- operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"styleClass", "class"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(srcElement, spanElement);
- appendAttribute(spanElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_HELPSPAN, srcElement, "inlineStyle")); //$NON-NLS-1$
- Iterator<Node> itHelpFacetChildNodes = helpFacetChildNodes.iterator();
- int curPos = 0;
- while (itHelpFacetChildNodes.hasNext()) {
- Node curNode = itHelpFacetChildNodes.next();
- if (curNode instanceof Text) {
- if (curNode.getNodeValue() != null && curNode.getNodeValue().length() > 0) {
- tagConverterContext.addChild(
- curNode,
- new ConvertPosition(spanElement, curPos));
- }
- } else {
- tagConverterContext.addChild(
- curNode,
- new ConvertPosition(spanElement, curPos));
- }
- curPos++;
- }
- }
- }
-
- return outerElement;
- }
-
- protected String calculateStyle(
- String baseStyle, Element srcElement, String styleAttributeName) {
- String style = baseStyle;
- if (srcElement != null && styleAttributeName != null) {
- String srcElementStyle = srcElement.getAttribute(styleAttributeName);
- if (srcElementStyle != null && srcElementStyle.length() > 0) {
- if (style != null) {
- if (!style.endsWith(";")) { //$NON-NLS-1$
- style += ";"; //$NON-NLS-1$
- }
- style += srcElementStyle;
- } else {
- style = srcElementStyle;
- }
- }
- }
- return style;
- }
-
- protected boolean isRequired(Element srcElement) {
- boolean required = false;
- if (!isChildOfPanelFormLayout(srcElement)) {
- if (srcElement != null) {
- String requiredVal = srcElement.getAttribute("required"); //$NON-NLS-1$
- String showRequiredVal = srcElement.getAttribute("showRequired"); //$NON-NLS-1$
- //if either are true, for the purposes of tag conversion, consider required to be true
- required =
- Boolean.parseBoolean(requiredVal) ||
- Boolean.parseBoolean(showRequiredVal);
- }
- }
- return required;
- }
-
- protected String getLabel(Element srcElement) {
- String label = null;
- if (!isChildOfPanelFormLayout(srcElement)) {
- if (srcElement != null) {
- String labelAndAccessKeyVal = srcElement.getAttribute("labelAndAccessKey"); //$NON-NLS-1$
- if (labelAndAccessKeyVal != null && labelAndAccessKeyVal.length() > 0) {
- label = labelAndAccessKeyVal;
- } else {
- String labelVal = srcElement.getAttribute("label"); //$NON-NLS-1$
- if (labelVal != null && labelVal.length() > 0) {
- label = labelVal;
- }
- }
- }
- }
- return label;
- }
-
- protected List<Node> getHelpFacetChildNodes(Element srcElement) {
- @SuppressWarnings("unchecked")
- List<Node> children = Collections.EMPTY_LIST;
- Element helpFacet = getChildFacetByName(srcElement, "help"); //$NON-NLS-1$
- if (helpFacet != null) {
- children = getCopyChildrenNodes(helpFacet);
- }
- return children;
- }
-
- protected int getColumns(Element srcElement) {
- int columns = 30;
- if (srcElement != null) {
- String columnsValue = srcElement.getAttribute("columns"); //$NON-NLS-1$
- if (columnsValue != null && columnsValue.length() > 0) {
- try {
- columns = Integer.parseInt(columnsValue);
- } catch(NumberFormatException nfe) {
- //ignore; default value will be returned
- }
- }
- }
- return columns;
- }
-
- protected boolean isChildOfPanelFormLayout(Element srcElement) {
- boolean isChild = false;
- if (srcElement != null) {
- Node parent = srcElement.getParentNode();
- if (parent instanceof Element) {
- TagIdentifier tagID = TagIdentifierFactory.createDocumentTagWrapper((Element)parent);
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELFORMLAYOUT.isSameTagType(tagID)) {
- isChild = true;
- } else if (ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(tagID)) {
- isChild = isChildOfPanelFormLayout((Element)parent);
- } else if (IJSFConstants.TAG_IDENTIFIER_FACET.isSameTagType(tagID)) {
- isChild = isChildOfPanelFormLayout((Element)parent);
- }
- }
- }
- return isChild;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractTrinidadTransformOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractTrinidadTransformOperation.java
deleted file mode 100644
index 83e392960..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/AbstractTrinidadTransformOperation.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.pagedesigner.dtmanager.converter.ITransformOperation;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.operations.TransformOperationFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Extends AbstractTransformOperation to supply extra convenience methods.
- *
- * @author Ian Trimble - Oracle
- */
-public abstract class AbstractTrinidadTransformOperation extends AbstractTransformOperation {
-
- /**
- * Appends the specified attribute with the specified value to the specified
- * Element instance.
- *
- * @param element Element instance to append attribute to.
- * @param attributeName Name of attribute to be appended.
- * @param attributeValue Value of attribute to be appended.
- */
- protected void appendAttribute(
- Element element, String attributeName, String attributeValue) {
- ITransformOperation operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CreateAttributeOperation,
- new String[]{attributeName, attributeValue});
- operation.transform(null, element);
- }
-
- /**
- * Gets a child Element of the specified parent Element that has the node
- * name "facet" and the specified value of the "name" attribute.
- *
- * @param srcElement Parent Element instance.
- * @param facetName Name of the facet Element for which to search.
- * @return Child Element that is a facet with the specified name.
- */
- protected Element getChildFacetByName(Element srcElement, String facetName) {
- Element element = null;
- @SuppressWarnings("unchecked")
- List facets = getChildElements(srcElement, "facet"); //$NON-NLS-1$
- @SuppressWarnings("unchecked")
- Iterator itFacets = facets.iterator();
- while (itFacets.hasNext()) {
- Element facet = (Element)itFacets.next();
- String facetAttrName = facet.getAttribute("name"); //$NON-NLS-1$
- if (facetAttrName != null && facetAttrName.equals(facetName)) {
- element = facet;
- break;
- }
- }
- return element;
- }
-
- /**
- * Gets a list of child Elements of the specified parent Element, skipping
- * any "facet" Elements.
- *
- * @param srcElement Parent Element instance.
- * @return List of child Elements of the specified parent Element that does
- * not include any child "facet" Elements.
- */
- protected List<Element> getChildElementsSkipFacets(Element srcElement) {
- List<Element> childElementsList = new ArrayList<Element>();
- NodeList childNodes = srcElement.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- Node childNode = childNodes.item(i);
- if (childNode.getNodeType() == Node.ELEMENT_NODE) {
- if (!childNode.getLocalName().equals("facet")) { //$NON-NLS-1$
- childElementsList.add((Element)childNode);
- }
- }
- }
- return childElementsList;
- }
-
- /**
- * Returns a List of child Node instances that will be added by the
- * "CopyChildrenOperation" ITransformOperation. This can be useful in
- * determining if any Node instances will, in fact, be copied.
- *
- * @param srcElement Source Element instance to query for child Node
- * instances.
- * @return A List of child Node instances that will be added by the
- * "CopyChildrenOperation" ITransformOperation.
- */
- protected List<Node> getCopyChildrenNodes(Element srcElement) {
- List<Node> children = new ArrayList<Node>();
- if (srcElement != null) {
- NodeList childNodes = srcElement.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- Node childNode = childNodes.item(i);
- short childNodeType = childNode.getNodeType();
- if (childNodeType == Node.ELEMENT_NODE ||
- childNodeType == Node.TEXT_NODE ||
- childNodeType == Node.CDATA_SECTION_NODE) {
- children.add(childNode);
- }
- }
- }
- return children;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/CreateStyleAttributeOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/CreateStyleAttributeOperation.java
deleted file mode 100644
index b0baffaa5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/CreateStyleAttributeOperation.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation to handle merging of an Element's optional
- * default style with a specified "inlineStyle" as the current Element's "style"
- * attribute.
- *
- * @author Ian Trimble - Oracle
- */
-public class CreateStyleAttributeOperation extends AbstractTrinidadTransformOperation {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- String styleValue = null;
- if (getParameters().length > 0) {
- styleValue = getParameters()[0];
- }
- String inlineStyle = srcElement.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (inlineStyle != null && inlineStyle.length() > 0) {
- if (styleValue == null) {
- styleValue = inlineStyle;
- } else {
- if (styleValue.length() > 0 && !styleValue.endsWith(";")) { //$NON-NLS-1$
- styleValue += ";"; //$NON-NLS-1$
- }
- styleValue += inlineStyle;
- }
- }
- if (styleValue != null && curElement != null) {
- curElement.setAttribute("style", styleValue); //$NON-NLS-1$
- }
- return curElement;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputFileOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputFileOperation.java
deleted file mode 100644
index a3ce1d328..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputFileOperation.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for the "inputFile" JSF
- * Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class InputFileOperation extends AbstractLabelAndHelpOperation {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- Element controlElement = appendChildElement("input", parentElement); //$NON-NLS-1$
- appendAttribute(controlElement, "size", //$NON-NLS-1$
- String.valueOf(getColumns(srcElement)));
- appendAttribute(controlElement, "type", "file"); //$NON-NLS-1$ //$NON-NLS-2$
- String value = srcElement.getAttribute("value"); //$NON-NLS-1$
- if (value != null) {
- appendAttribute(controlElement, "value", value); //$NON-NLS-1$
- }
- appendAttribute(controlElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextOperation.java
deleted file mode 100644
index 585fda34d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextOperation.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for the "inputText" JSF
- * Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class InputTextOperation extends AbstractLabelAndHelpOperation {
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- int rows = getRows(srcElement);
- Element controlElement;
- if (rows < 2) {
- controlElement = appendChildElement("input", parentElement); //$NON-NLS-1$
- appendAttribute(controlElement, "size", //$NON-NLS-1$
- String.valueOf(getColumns(srcElement)));
- appendAttribute(controlElement, "type", getType(srcElement)); //$NON-NLS-1$
- String value = srcElement.getAttribute("value"); //$NON-NLS-1$
- if (value != null) {
- appendAttribute(controlElement, "value", value); //$NON-NLS-1$
- }
- } else {
- controlElement = appendChildElement("textarea", parentElement); //$NON-NLS-1$
- appendAttribute(controlElement, "cols", //$NON-NLS-1$
- String.valueOf(getColumns(srcElement)));
- appendAttribute(controlElement, "rows", //$NON-NLS-1$
- String.valueOf(getRows(srcElement)));
- appendAttribute(controlElement, "wrap", getWrap(srcElement)); //$NON-NLS-1$
- String value = srcElement.getAttribute("value"); //$NON-NLS-1$
- if (value != null) {
- appendChildText(value, controlElement);
- }
- }
- //append common attributes
- appendAttribute(controlElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
- }
-
- private int getRows(Element srcElement) {
- int rows = 1;
- if (srcElement != null) {
- String rowsValue = srcElement.getAttribute("rows"); //$NON-NLS-1$
- if (rowsValue != null && rowsValue.length() > 0) {
- try {
- rows = Integer.parseInt(rowsValue);
- } catch(NumberFormatException nfe) {
- //ignore; default value will be returned
- }
- }
- }
- return rows;
- }
-
- private String getWrap(Element srcElement) {
- String wrap = "soft"; //$NON-NLS-1$
- if (srcElement != null) {
- String wrapValue = srcElement.getAttribute("wrap"); //$NON-NLS-1$
- if (wrapValue != null && wrapValue.length() > 0) {
- wrap = wrapValue;
- }
- }
- return wrap;
- }
-
- private String getType(Element srcElement) {
- String type = "text"; //$NON-NLS-1$
- if (srcElement != null) {
- String secret = srcElement.getAttribute("secret"); //$NON-NLS-1$
- if (Boolean.valueOf(secret)) {
- type = "password"; //$NON-NLS-1$
- }
- }
- return type;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextWithIconOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextWithIconOperation.java
deleted file mode 100644
index f412a7dae..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/InputTextWithIconOperation.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for any "input..." JSF
- * Elements that are basically comprised of an inputText followed by an icon.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class InputTextWithIconOperation extends AbstractLabelAndHelpOperation {
-
- private String imageFilename;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- if (getParameters().length < 1) {
- getLog().error("Warning.TransformOperationFactory.TooFewParameters", getTransformOperationID()); //$NON-NLS-1$
- return null;
- } else {
- imageFilename = getParameters()[0];
- }
- return super.transform(srcElement, curElement);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- //append input
- Element inputElement = appendChildElement("input", parentElement); //$NON-NLS-1$
- appendAttribute(inputElement, "size", //$NON-NLS-1$
- String.valueOf(getColumns(srcElement)));
- appendAttribute(inputElement, "type", "text"); //$NON-NLS-1$ //$NON-NLS-2$
- String value = srcElement.getAttribute("value"); //$NON-NLS-1$
- if (value != null) {
- appendAttribute(inputElement, "value", value); //$NON-NLS-1$
- }
- appendAttribute(inputElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
-
- //append anchor with child image
- Element aElement = appendChildElement("a", parentElement); //$NON-NLS-1$
- appendAttribute(aElement, "href", "#"); //$NON-NLS-1$ //$NON-NLS-2$
- Element imgElement = appendChildElement("img", aElement); //$NON-NLS-1$
- appendAttribute(imgElement, "align", "absmiddle"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(imgElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(imgElement, "src", imageFilename); //$NON-NLS-1$
- appendAttribute(imgElement, "style", "margin-left:4px;"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/OutputFormattedOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/OutputFormattedOperation.java
deleted file mode 100644
index 780ec1132..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/OutputFormattedOperation.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.io.ByteArrayInputStream;
-import java.io.InputStream;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-
-import org.eclipse.jst.pagedesigner.dtmanager.converter.ITransformOperation;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.operations.TransformOperationFactory;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Text;
-
-/**
- * ITransformOperation implementation specifically for the "outputFormatted" JSF
- * Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class OutputFormattedOperation extends AbstractTrinidadTransformOperation {
-
- /*
- * NOTICE (especially if looking for missing whitespace):
- * Because this operation can potentially return a mix of child Element
- * and Text nodes inside a span Element, it can suffer from bug #221629
- * (see https://bugs.eclipse.org/bugs/show_bug.cgi?id=221629).
- * This operation is not the cause of the above-mentioned bug.
- */
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- //create outer span element and set class attribute
- Element spanElement = createElement("span"); //$NON-NLS-1$
- ITransformOperation operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"styleClass", "class"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(srcElement, spanElement);
- String styleClass = srcElement.getAttribute("styleClass"); //$NON-NLS-1$
-
- //deal with styleClass, inlineStyle, and styleUsage to mimic runtime
- String style = null;
- if (styleClass == null || styleClass.length() < 1) {
- String styleUsage = srcElement.getAttribute("styleUsage"); //$NON-NLS-1$
- if (styleUsage != null && styleUsage.length() > 8) {
- if (styleUsage.equals("instruction")) { //$NON-NLS-1$
- style = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;"; //$NON-NLS-1$
- } else if (styleUsage.equals("pageStamp")) { //$NON-NLS-1$
- style = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#669966;"; //$NON-NLS-1$
- } else if (styleUsage.equals("inContextBranding")) { //$NON-NLS-1$
- style = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#999999;"; //$NON-NLS-1$
- }
- }
- }
- String inlineStyle = srcElement.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (inlineStyle != null && inlineStyle.length() > 0) {
- if (style != null) {
- style += inlineStyle;
- } else {
- style = inlineStyle;
- }
- }
- if (style != null) {
- appendAttribute(spanElement, "style", style); //$NON-NLS-1$
- }
-
- //deal with value
- String value = srcElement.getAttribute("value"); //$NON-NLS-1$
- if (value != null && value.length() > 0) {
- StringBuffer wrappedValue = new StringBuffer();
- wrappedValue.append("<?xml version=\"1.0\"?><value>"); //$NON-NLS-1$
- wrappedValue.append(value);
- wrappedValue.append("</value>"); //$NON-NLS-1$
- InputStream inputStream = new ByteArrayInputStream(wrappedValue.toString().getBytes());
- Element valueElement = getValueDocumentElement(inputStream);
- if (valueElement != null) {
- if (!appendValueNodes(spanElement, valueElement)) {
- //remove any children added before appendValueNodes failed
- NodeList childNodes = spanElement.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- spanElement.removeChild(childNodes.item(i));
- }
- //set as simple text
- appendChildText(value, spanElement);
- }
- } else {
- //set as simple text
- appendChildText(value, spanElement);
- }
- }
-
- return spanElement;
- }
-
- private Element getValueDocumentElement(InputStream inputStream) {
- Element element = null;
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- //TODO: entity expansion should be set to false for ".jsp", true for ".jspx"
- factory.setExpandEntityReferences(true);
- try {
- DocumentBuilder builder = factory.newDocumentBuilder();
- Document document = builder.parse(inputStream);
- element = document.getDocumentElement();
- } catch(Exception e) {
- //fail on any exception - text with markup will be rendered instead
- }
- return element;
- }
-
- private boolean appendValueNodes(Node parentNode, Node currentNode) {
- boolean success = true;
- try {
- NodeList childNodes = currentNode.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- Node childNode = childNodes.item(i);
- if (childNode instanceof Element) {
- //TODO: elements should be filtered to only create elements specified for this tag
- Element newElement = (Element)parentNode.appendChild(
- parentNode.getOwnerDocument().createElement(
- childNode.getNodeName()));
- NamedNodeMap attrMap = childNode.getAttributes();
- if (attrMap != null) {
- for (int j = 0; j < attrMap.getLength(); j++) {
- Attr attr = (Attr)attrMap.item(j);
- //TODO: attributes should be filtered to only create attributes specified for this tag
- newElement.setAttribute(
- attr.getName(), attr.getValue());
- }
- }
- success &= appendValueNodes(newElement, childNode);
- } else if (childNode instanceof Text) {
- parentNode.appendChild(
- parentNode.getOwnerDocument().createTextNode(
- childNode.getTextContent()));
- }
- }
- } catch(Exception e) {
- //fail on any exception - text with markup will be rendered instead
- success = false;
- }
- return success;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelFormLayoutOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelFormLayoutOperation.java
deleted file mode 100644
index cf6c194ff..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelFormLayoutOperation.java
+++ /dev/null
@@ -1,427 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for the "panelFormLayout"
- * JSF Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelFormLayoutOperation extends AbstractTrinidadTransformOperation {
-
- private static final String STYLE_REQUIREDSPAN = "color:#669966;font-family:Courier,sans-serif;"; //$NON-NLS-1$
- private static final String STYLE_GROUPSEPARATOR = "background-color:gray;height:1px;font-size:1px;margin-top:3px;margin-bottom:3px;"; //$NON-NLS-1$
- private static final String STYLE_LABELCELL = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;text-align:right;color:#000000;padding:0px 8px 0px 0px;font-weight:normal;"; //$NON-NLS-1$
- private static final String STYLE_FIELDCELL = "padding:1px 0px;"; //$NON-NLS-1$
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- //calculate required values
- int columnCount = calculateColumnCount(srcElement);
- int rowCount = calculateRowCount(srcElement);
- String fieldWidth = calculateFieldWidth(srcElement);
- String labelWidth = calculateLabelWidth(srcElement);
-
- //initialize current column/row variables
- int currentColumn = 1;
- int currentRow = 1;
-
- //build outer table
- Element outerTableElement = createElement("table"); //$NON-NLS-1$
- String styleClass = srcElement.getAttribute("styleClass"); //$NON-NLS-1$
- if (styleClass != null && styleClass.length() > 0) {
- appendAttribute(outerTableElement, "class", styleClass); //$NON-NLS-1$
- }
- String inlineStyle = srcElement.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (inlineStyle != null && inlineStyle.length() > 0) {
- appendAttribute(outerTableElement, "style", inlineStyle + ";width:100%;"); //$NON-NLS-1$ //$NON-NLS-2$
- } else {
- appendAttribute(outerTableElement, "style", "width:100%;"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- appendAttribute(outerTableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerTableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerTableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- Element outerTBodyElement = appendChildElement("tbody", outerTableElement); //$NON-NLS-1$
- Element outerTopTRElement = appendChildElement("tr", outerTBodyElement); //$NON-NLS-1$
-
- //build start of column
- Element currentTBodyElement = buildColumnStart(outerTopTRElement, columnCount, currentColumn, labelWidth, fieldWidth);
-
- //build controls
- List<Element> childElements = getChildElementsSkipFacets(srcElement);
- Iterator<Element> itChildElements = childElements.iterator();
- while (itChildElements.hasNext()) {
- Element childElement = itChildElements.next();
- if (ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper(childElement))) {
- if (currentRow > 1) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- List<Element> groupChildElements = getChildElementsSkipFacets(childElement);
- Iterator<Element> itGroupChildElements = groupChildElements.iterator();
- while (itGroupChildElements.hasNext()) {
- Element groupChildElement = itGroupChildElements.next();
- buildControlRow(groupChildElement, currentTBodyElement);
- }
- currentRow += groupChildElements.size();
- if (currentRow <= rowCount) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- if (currentRow > rowCount && currentColumn < columnCount) {
- currentRow = 1;
- currentColumn++;
- currentTBodyElement = buildColumnStart(
- outerTopTRElement, columnCount, currentColumn, labelWidth, fieldWidth);
- }
- } else {
- buildControlRow(childElement, currentTBodyElement);
- currentRow++;
- if (currentRow > rowCount && currentColumn < columnCount) {
- currentRow = 1;
- currentColumn++;
- currentTBodyElement = buildColumnStart(
- outerTopTRElement, columnCount, currentColumn, labelWidth, fieldWidth);
- }
- }
- }
-
- //handle "footer" facet
- Element footerElement = getChildFacetByName(srcElement, "footer"); //$NON-NLS-1$
- if (footerElement != null) {
- List<Element> footerChildElements = getChildElementsSkipFacets(footerElement);
- if (footerChildElements.size() > 0) {
- Element outerBottomTRElement = appendChildElement("tr", outerTBodyElement); //$NON-NLS-1$
- currentTBodyElement = buildFooterStart(
- outerBottomTRElement, columnCount, labelWidth);
- rowCount = countChildElements(footerElement);
- currentRow = 1;
- Iterator<Element> itFooterChildElements = footerChildElements.iterator();
- while (itFooterChildElements.hasNext()) {
- Element footerChildElement = itFooterChildElements.next();
- if (ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper(footerChildElement))) {
- if (currentRow > 1) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- List<Element> groupFooterChildElements = getChildElementsSkipFacets(footerChildElement);
- Iterator<Element> itGroupFooterChildElements = groupFooterChildElements.iterator();
- while (itGroupFooterChildElements.hasNext()) {
- Element groupFooterChildElement = itGroupFooterChildElements.next();
- if (ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper(groupFooterChildElement))) {
- if (currentRow > 1) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- List<Element> subGroupFooterChildElements = getChildElementsSkipFacets(groupFooterChildElement);
- Iterator<Element> itSubGroupFooterChildElements = subGroupFooterChildElements.iterator();
- while (itSubGroupFooterChildElements.hasNext()) {
- Element subGroupFooterChildElement = itSubGroupFooterChildElements.next();
- buildControlRow(subGroupFooterChildElement, currentTBodyElement, true);
- currentRow++;
- }
- if (currentRow <= rowCount) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- } else {
- buildControlRow(groupFooterChildElement, currentTBodyElement, true);
- currentRow++;
- }
- }
- if (currentRow <= rowCount) {
- buildGroupSeparatorRow(currentTBodyElement);
- }
- } else {
- buildControlRow(footerChildElement, currentTBodyElement, true);
- currentRow++;
- }
- }
- }
- }
-
- return outerTableElement;
- }
-
- private int calculateRowCount(Element srcElement) {
- int rowCount = Integer.MAX_VALUE;
- int specifiedRows = Integer.MAX_VALUE;
- String rows = srcElement.getAttribute("rows"); //$NON-NLS-1$
- if (rows != null && rows.length() > 0) {
- try {
- //not spec'ed, but observed that setting rows < 5 is ignored
- specifiedRows = Math.max(5, Integer.parseInt(rows));
- } catch(NumberFormatException nfe) {
- //ignore - specifiedRows will default to Integer.MAX_VALUE
- }
- }
- int specifiedMaxColumns = Integer.MAX_VALUE;
- String maxColumns = srcElement.getAttribute("maxColumns"); //$NON-NLS-1$
- if (maxColumns != null && maxColumns.length() > 0) {
- try {
- specifiedMaxColumns = Integer.parseInt(maxColumns);
- } catch(NumberFormatException nfe) {
- //ignore - specifiedMaxColumns will default to Integer.MAX_VALUE
- }
- }
- int childElementCount = countChildElements(srcElement);
- int calculatedColumns = childElementCount / specifiedRows;
- if (childElementCount % specifiedRows > 0) {
- calculatedColumns++;
- }
- if (calculatedColumns > specifiedMaxColumns) {
- rowCount = childElementCount / specifiedMaxColumns;
- } else {
- rowCount = specifiedRows;
- }
- return rowCount;
- }
-
- private int calculateColumnCount(Element srcElement) {
- int columnCount = Integer.MAX_VALUE;
- int specifiedRows = Integer.MAX_VALUE;
- String rows = srcElement.getAttribute("rows"); //$NON-NLS-1$
- if (rows != null && rows.length() > 0) {
- try {
- //not spec'ed, but observed that setting rows < 5 is ignored
- specifiedRows = Math.max(5, Integer.parseInt(rows));
- } catch(NumberFormatException nfe) {
- //ignore - specifiedRows will default to Integer.MAX_VALUE
- }
- }
- int specifiedMaxColumns = Integer.MAX_VALUE;
- String maxColumns = srcElement.getAttribute("maxColumns"); //$NON-NLS-1$
- if (maxColumns != null && maxColumns.length() > 0) {
- try {
- specifiedMaxColumns = Integer.parseInt(maxColumns);
- } catch(NumberFormatException nfe) {
- //ignore - specifiedMaxColumns will default to Integer.MAX_VALUE
- }
- }
- int childElementCount = countChildElements(srcElement);
- int calculatedColumns = childElementCount / specifiedRows;
- if (childElementCount % specifiedRows > 0) {
- calculatedColumns++;
- }
- columnCount = Math.min(specifiedMaxColumns, calculatedColumns);
- return columnCount;
- }
-
- private int countChildElements(Element srcElement) {
- int count = 0;
- List<Element> childElements = getChildElementsSkipFacets(srcElement);
- Iterator<Element> itChildElements = childElements.iterator();
- while (itChildElements.hasNext()) {
- Element childElement = itChildElements.next();
- if (ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper(childElement))) {
- count += countChildElements(childElement);
- } else {
- count++;
- }
- }
- return count;
- }
-
- private String calculateFieldWidth(Element srcElement) {
- String width = null;
- String fieldWidth = srcElement.getAttribute("fieldWidth"); //$NON-NLS-1$
- if (fieldWidth != null && fieldWidth.length() > 0) {
- width = fieldWidth;
- } else {
- String labelWidth = srcElement.getAttribute("labelWidth"); //$NON-NLS-1$
- if (labelWidth != null && labelWidth.length() > 1) {
- if (labelWidth.endsWith("%")) { //$NON-NLS-1$
- try {
- int iLabelWidth = Integer.parseInt(labelWidth.substring(0, labelWidth.length() - 1));
- if (iLabelWidth <= 100) {
- width = String.valueOf(100 - iLabelWidth) + "%"; //$NON-NLS-1$
- }
- } catch(NumberFormatException nfe) {
- //ignore - cannot calculate and so will return null
- }
- }
- }
- }
- return width;
- }
-
- private String calculateLabelWidth(Element srcElement) {
- String width = null;
- String labelWidth = srcElement.getAttribute("labelWidth"); //$NON-NLS-1$
- if (labelWidth != null && labelWidth.length() > 0) {
- width = labelWidth;
- } else {
- String fieldWidth = srcElement.getAttribute("fieldWidth"); //$NON-NLS-1$
- if (fieldWidth != null && fieldWidth.length() > 1) {
- if (fieldWidth.endsWith("%")) { //$NON-NLS-1$
- try {
- int iFieldWidth = Integer.parseInt(fieldWidth.substring(0, fieldWidth.length() - 1));
- if (iFieldWidth <= 100) {
- width = String.valueOf(100 - iFieldWidth) + "%"; //$NON-NLS-1$
- }
- } catch(NumberFormatException nfe) {
- //ignore - cannot calculate and so will return null
- }
- }
- }
- }
- return width;
- }
-
- private Element buildColumnStart(
- Element parentElement, int columnCount, int currentColumn,
- String labelWidth, String fieldWidth) {
- Element tdElement = appendChildElement("td", parentElement); //$NON-NLS-1$
- appendAttribute(tdElement, "style", "vertical-align:top;"); //$NON-NLS-1$ //$NON-NLS-2$
- if (currentColumn < columnCount) {
- String width = String.valueOf(100 / columnCount) + "%"; //$NON-NLS-1$
- appendAttribute(tdElement, "width", width); //$NON-NLS-1$
- }
- Element tableElement = appendChildElement("table", tdElement); //$NON-NLS-1$
- appendAttribute(tableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "width", "100%"); //$NON-NLS-1$ //$NON-NLS-2$
- Element tBodyElement = appendChildElement("tbody", tableElement); //$NON-NLS-1$
- Element trElement = appendChildElement("tr", tBodyElement); //$NON-NLS-1$
- Element tdLabelElement = appendChildElement("td", trElement); //$NON-NLS-1$
- if (labelWidth != null && labelWidth.length() > 0) {
- appendAttribute(tdLabelElement, "style", "width:" + labelWidth); //$NON-NLS-1$ //$NON-NLS-2$
- }
- Element tdFieldElement = appendChildElement("td", trElement); //$NON-NLS-1$
- if (fieldWidth != null && fieldWidth.length() > 0) {
- appendAttribute(tdFieldElement, "style", "width:" + fieldWidth); //$NON-NLS-1$ //$NON-NLS-2$
- }
- return tBodyElement;
- }
-
- private void buildControlRow(Element srcElement, Element parentElement, boolean alignLabelsTop) {
- Element trElement = appendChildElement("tr", parentElement); //$NON-NLS-1$
- Element tdLabelElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdLabelElement, "style", STYLE_LABELCELL); //$NON-NLS-1$
- if (alignLabelsTop) {
- appendAttribute(tdLabelElement, "valign", "top"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- appendAttribute(tdLabelElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- buildLabel(srcElement, tdLabelElement);
- Element tdFieldElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdFieldElement, "style", STYLE_FIELDCELL); //$NON-NLS-1$
- appendAttribute(tdFieldElement, "valign", "top"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFieldElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- tagConverterContext.addChild(srcElement, new ConvertPosition(tdFieldElement, 0));
- }
-
- private void buildControlRow(Element srcElement, Element parentElement) {
- buildControlRow(srcElement, parentElement, false);
- }
-
- private void buildLabel(Element srcElement, Element parentElement) {
- TagIdentifier tagID = TagIdentifierFactory.createDocumentTagWrapper(srcElement);
- if (
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTCOLOR) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTDATE) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTFILE) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTLISTOFVALUES) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTNUMBERSPINBOX) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_INPUTTEXT) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTBOOLEANCHECKBOX) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTBOOLEANRADIO) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTMANYCHECKBOX) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTMANYLISTBOX) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTONECHOICE) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTONELISTBOX) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTONERADIO) ||
- tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_PANELLABELANDMESSAGE)) {
- String required = srcElement.getAttribute("required"); //$NON-NLS-1$
- String showRequired = srcElement.getAttribute("showRequired"); //$NON-NLS-1$
- if (Boolean.parseBoolean(required) || Boolean.parseBoolean(showRequired)) {
- Element spanElement = appendChildElement("span", parentElement); //$NON-NLS-1$
- appendAttribute(spanElement, "title", "Required"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(spanElement, "style", STYLE_REQUIREDSPAN); //$NON-NLS-1$
- appendChildText("* ", spanElement); //$NON-NLS-1$
- }
- String label = srcElement.getAttribute("labelAndAccessKey"); //$NON-NLS-1$
- if (label == null || label.length() < 1) {
- label = srcElement.getAttribute("label"); //$NON-NLS-1$
- }
- if (label != null && label.length() > 0) {
- Element labelElement = appendChildElement("label", parentElement); //$NON-NLS-1$
- appendChildText(label, labelElement);
- }
- }
- }
-
- private void buildGroupSeparatorRow(Element parentElement) {
- Element trElement = appendChildElement("tr", parentElement); //$NON-NLS-1$
- Element tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdElement, "colspan", "2"); //$NON-NLS-1$ //$NON-NLS-2$
- Element divElement = appendChildElement("div", tdElement); //$NON-NLS-1$
- appendAttribute(divElement, "style", STYLE_GROUPSEPARATOR); //$NON-NLS-1$
- }
-
- private Element buildFooterStart(
- Element parentElement, int columnCount, String labelWidth) {
- Element tdElement = appendChildElement("td", parentElement); //$NON-NLS-1$
- appendAttribute(tdElement, "style", "vertical-align:top;"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "colspan", String.valueOf(columnCount)); //$NON-NLS-1$
- Element tableElement = appendChildElement("table", tdElement); //$NON-NLS-1$
- appendAttribute(tableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "width", "100%"); //$NON-NLS-1$ //$NON-NLS-2$
- Element tBodyElement = appendChildElement("tbody", tableElement); //$NON-NLS-1$
- Element trElement = appendChildElement("tr", tBodyElement); //$NON-NLS-1$
- String footerLabelWidth = null;
- String footerFieldWidth = null;
- if (labelWidth != null && labelWidth.length() > 0) {
- if (labelWidth.endsWith("%")) { //$NON-NLS-1$
- try {
- int iLabelWidth = Integer.parseInt(labelWidth.substring(0, labelWidth.length() - 1));
- iLabelWidth = iLabelWidth / columnCount;
- footerLabelWidth = String.valueOf(iLabelWidth) + "%"; //$NON-NLS-1$
- footerFieldWidth = String.valueOf(100 - iLabelWidth) + "%"; //$NON-NLS-1$
- } catch(NumberFormatException nfe) {
- //ignore - cannot calculate, widths remain null
- }
- } else {
- footerLabelWidth = labelWidth;
- }
- }
- Element tdLabelElement = appendChildElement("td", trElement); //$NON-NLS-1$
- if (footerLabelWidth != null && footerLabelWidth.length() > 0) {
- //appendAttribute(tdLabelElement, "style", "width:" + footerLabelWidth); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdLabelElement, "width", footerLabelWidth); //$NON-NLS-1$
- }
- Element tdFieldElement = appendChildElement("td", trElement); //$NON-NLS-1$
- if (footerFieldWidth != null && footerFieldWidth.length() > 0) {
- //appendAttribute(tdFieldElement, "style", "width:" + footerFieldWidth); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFieldElement, "width", footerFieldWidth); //$NON-NLS-1$
- }
- return tBodyElement;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelGroupLayoutOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelGroupLayoutOperation.java
deleted file mode 100644
index cc303c7e1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelGroupLayoutOperation.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.core.internal.tld.IJSFConstants;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Text;
-
-/**
- * ITransformOperation implementation specifically for the "panelGroupLayout"
- * JSF Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelGroupLayoutOperation extends AbstractTrinidadTransformOperation {
-
- private static final int LAYOUT_DEFAULT = 0;
- private static final int LAYOUT_HORIZONTAL = 1;
- private static final int LAYOUT_VERTICAL = 2;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- Element outerElement;
-
- //create outer element and set element-specific attributes
- final int layout = getLayout(srcElement);
- Element containerElement;
- switch (layout) {
- case LAYOUT_HORIZONTAL:
- outerElement = createElement("table"); //$NON-NLS-1$
- outerElement.setAttribute("cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- outerElement.setAttribute("cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- outerElement.setAttribute("border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- containerElement = appendChildElement("tr", outerElement); //$NON-NLS-1$
- break;
- case LAYOUT_VERTICAL:
- outerElement = createElement("div"); //$NON-NLS-1$
- containerElement = outerElement;
- break;
- default:
- outerElement = createElement("span"); //$NON-NLS-1$
- containerElement = outerElement;
- break;
- }
-
- //set common attributes on outer element
- final String styleClass = srcElement.getAttribute("styleClass"); //$NON-NLS-1$
- if (styleClass != null && styleClass.length() > 0) {
- outerElement.setAttribute("class", styleClass); //$NON-NLS-1$
- }
- final String inlineStyle = srcElement.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (inlineStyle != null && inlineStyle.length() > 0) {
- outerElement.setAttribute("style", inlineStyle); //$NON-NLS-1$
- }
-
- //get child nodes, skipping "facet" elements and empty Text nodes
- List<Node> childNodes = new ArrayList<Node>();
- Iterator<Node> itCopyChildrenNodes = getCopyChildrenNodes(srcElement).iterator();
- while (itCopyChildrenNodes.hasNext()) {
- Node copyChildrenNode = itCopyChildrenNodes.next();
- if (!(copyChildrenNode instanceof Element && TagIdentifierFactory.createDocumentTagWrapper((Element)copyChildrenNode).isSameTagType(IJSFConstants.TAG_IDENTIFIER_FACET))) {
- if (!(copyChildrenNode instanceof Text && copyChildrenNode.getNodeValue().trim().length() < 1)) {
- childNodes.add(copyChildrenNode);
- }
- }
- }
-
- //get "separator" facet's first child Element (only one used at runtime)
- Element separatorElement = null;
- final Element facetElement = getChildFacetByName(srcElement, "separator"); //$NON-NLS-1$
- if (facetElement != null) {
- NodeList facetChildNodes = facetElement.getChildNodes();
- for (int i = 0; i < facetChildNodes.getLength(); i++) {
- Node curChildNode = facetChildNodes.item(i);
- if (curChildNode instanceof Element) {
- separatorElement = (Element)curChildNode;
- break;
- }
- }
- }
-
- //iterate over child nodes, interspersing separator(s) as required
- int curChildNodeIndex = 0;
- int curIndex = 0;
- Iterator<Node> itChildNodes = childNodes.iterator();
- switch (layout) {
- case LAYOUT_HORIZONTAL:
- while (itChildNodes.hasNext()) {
- final Element childTDElement = appendChildElement("td", containerElement); //$NON-NLS-1$
- tagConverterContext.addChild(itChildNodes.next(), new ConvertPosition(childTDElement, 0));
- if (++curChildNodeIndex < childNodes.size()) {
- if (separatorElement != null) {
- final Element sepTDElement = appendChildElement("td", containerElement); //$NON-NLS-1$
- tagConverterContext.addChild(separatorElement, new ConvertPosition(sepTDElement, 0));
- }
- }
- }
- break;
- case LAYOUT_VERTICAL:
- while (itChildNodes.hasNext()) {
- tagConverterContext.addChild(itChildNodes.next(), new ConvertPosition(containerElement, curIndex++));
- if (++curChildNodeIndex < childNodes.size()) {
- final Element divElement = appendChildElement("div", containerElement); //$NON-NLS-1$
- curIndex++;
- if (separatorElement != null) {
- tagConverterContext.addChild(separatorElement, new ConvertPosition(divElement, 0));
- }
- }
- }
- break;
- default:
- while (itChildNodes.hasNext()) {
- tagConverterContext.addChild(itChildNodes.next(), new ConvertPosition(containerElement, curIndex++));
- if (++curChildNodeIndex < childNodes.size()) {
- if (separatorElement != null) {
- tagConverterContext.addChild(separatorElement, new ConvertPosition(containerElement, curIndex++));
- }
- }
- }
- break;
- }
-
- return outerElement;
- }
-
- private int getLayout(Element srcElement) {
- int layout = LAYOUT_DEFAULT;
- if (srcElement != null) {
- String layoutValue = srcElement.getAttribute("layout"); //$NON-NLS-1$
- if (layoutValue != null) {
- if (layoutValue.equals("horizontal")) { //$NON-NLS-1$
- layout = LAYOUT_HORIZONTAL;
- } else if (layoutValue.equals("vertical")) { //$NON-NLS-1$
- layout = LAYOUT_VERTICAL;
- }
- }
- }
- return layout;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelLabelAndMessageOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelLabelAndMessageOperation.java
deleted file mode 100644
index 93d9f7a9d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelLabelAndMessageOperation.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.core.internal.tld.IJSFConstants;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * ITransformOperation implementation specifically for the "panelLabelAndMessage"
- * JSF Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelLabelAndMessageOperation extends
- AbstractLabelAndHelpOperation {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- handleLabelStyle(srcElement, parentElement);
- Element tableElement = appendChildElement("table", parentElement); //$NON-NLS-1$
- appendAttribute(tableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- Element trElement = appendChildElement("tr", tableElement); //$NON-NLS-1$
- Element tdElementLeft = appendChildElement("td", trElement); //$NON-NLS-1$
- List<Node> childNodes = getCopyChildrenNodes(srcElement);
- Iterator<Node> itChildNodes = childNodes.iterator();
- int curIndex = 0;
- while (itChildNodes.hasNext()) {
- Node childNode = itChildNodes.next();
- if (!(childNode instanceof Element &&
- IJSFConstants.TAG_IDENTIFIER_FACET.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper((Element)childNode)))) {
- tagConverterContext.addChild(
- childNode, new ConvertPosition(tdElementLeft, curIndex++));
- }
- }
- Element tdElementRight = appendChildElement("td", trElement); //$NON-NLS-1$
- Element endFacetElement = getChildFacetByName(srcElement, "end"); //$NON-NLS-1$
- if (endFacetElement != null) {
- tagConverterContext.addChild(
- endFacetElement, new ConvertPosition(tdElementRight, 0));
- }
- }
-
- private void handleLabelStyle(Element srcElement, Element parentElement) {
- String labelStyle = srcElement.getAttribute("labelStyle"); //$NON-NLS-1$
- if (labelStyle != null && labelStyle.length() > 0) {
- if (parentElement.getPreviousSibling() instanceof Element) {
- Element labelTDElement = (Element)parentElement.getPreviousSibling();
- labelTDElement.removeAttribute("valign"); //$NON-NLS-1$
- String style = labelTDElement.getAttribute("style"); //$NON-NLS-1$
- if (style != null && style.length() > 0) {
- if (!style.endsWith(";")) { //$NON-NLS-1$
- style += ";"; //$NON-NLS-1$
- }
- style += labelStyle;
- appendAttribute(labelTDElement, "style", style); //$NON-NLS-1$
- } else {
- appendAttribute(labelTDElement, "style", labelStyle); //$NON-NLS-1$
- }
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelTabbedOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelTabbedOperation.java
deleted file mode 100644
index e6641df81..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/PanelTabbedOperation.java
+++ /dev/null
@@ -1,290 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.Messages;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.TrinidadUtils;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.ITransformOperation;
-import org.eclipse.jst.pagedesigner.dtmanager.converter.operations.TransformOperationFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * ITransformOperation implementation specifically for the "panelTabbed" JSF
- * Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelTabbedOperation extends AbstractTrinidadTransformOperation {
-
- private static final int SEP_POS_BETWEEN = -1;
- private static final int SEP_POS_START = 0;
- private static final int SEP_POS_END = 1;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- //create outer span element and set style and class attributes
- Element spanElement = createElement("span"); //$NON-NLS-1$
- ITransformOperation operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"styleClass", "class"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(srcElement, spanElement);
- operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"inlineStyle", "style"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(srcElement, spanElement);
-
- //get child showDetailItem elements
- @SuppressWarnings("unchecked")
- List<Node> showDetailItems = getChildElements(
- srcElement, "showDetailItem"); //$NON-NLS-1$
- if (showDetailItems.size() > 0) {
-
- //determine tabs position ("both", "above", or "below" - default "both")
- String tabsPosition = srcElement.getAttribute("position"); //$NON-NLS-1$
- if (tabsPosition == null ||
- !(tabsPosition.equalsIgnoreCase("above") || //$NON-NLS-1$
- tabsPosition.equalsIgnoreCase("below"))) { //$NON-NLS-1$
- tabsPosition = "both"; //$NON-NLS-1$
- }
-
- //need to track where showDetailItem is in relation to "tabs"
- int showDetailItemConvertPosition = 0;
-
- //write tabs "above" if specified
- if ("above".equalsIgnoreCase(tabsPosition) || //$NON-NLS-1$
- "both".equalsIgnoreCase(tabsPosition)) { //$NON-NLS-1$
- appendTabs(srcElement, showDetailItems, spanElement, true);
- showDetailItemConvertPosition++;
- }
-
- //copy current child showDetailItem
- int currentEditorItem =
- getCurrentShowDetailItem(srcElement, showDetailItems);
- int curItem = 0;
- Iterator<Node> itItems = showDetailItems.iterator();
- while (itItems.hasNext()) {
- Node nodeItem = itItems.next();
- if (currentEditorItem == curItem) {
- if (nodeItem instanceof Element) {
- Element elemItem = (Element)nodeItem;
- tagConverterContext.addChild(
- elemItem,
- new ConvertPosition(
- spanElement,
- showDetailItemConvertPosition));
- break;
- }
- }
- curItem++;
- }
-
- //write tabs "below" if specified
- if ("below".equalsIgnoreCase(tabsPosition) || //$NON-NLS-1$
- "both".equalsIgnoreCase(tabsPosition)) { //$NON-NLS-1$
- appendTabs(srcElement, showDetailItems, spanElement, false);
- }
- } else {
- appendAttribute(
- spanElement,
- "style", //$NON-NLS-1$
- ITrinidadConstants.STYLE_EMPTYELEMENT);
- appendChildText(
- Messages.PanelTabbedOperation_EmptyPanelTabbedTag,
- spanElement);
- }
-
- return spanElement;
- }
-
- private void appendTabs(Element srcElement, List<Node> showDetailItems, Element spanElement, boolean above) {
- Element tableElement = appendChildElement("table", spanElement); //$NON-NLS-1$
- String tableStyle;
- if (above) {
- tableStyle = "background-color:#e9e8e8;border-color:#99cc99;text-align:center;border-style:solid;padding:2px 0px;margin:4px 0px;border-width:1px 0px 0px;"; //$NON-NLS-1$
- } else {
- tableStyle = "background-color:#e9e8e8;border-color:#99cc99;text-align:center;border-style:solid;padding:2px 0px;margin:4px 0px;border-width:0px 0px 1px;"; //$NON-NLS-1$
- }
- appendAttribute(tableElement, "style", tableStyle); //$NON-NLS-1$
- appendAttribute(tableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "width", "100%"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement, "summary", ""); //$NON-NLS-1$ //$NON-NLS-2$
- Element trElement = appendChildElement("tr", tableElement); //$NON-NLS-1$
-
- //append first separator
- appendSeparatorTD(trElement, SEP_POS_START);
-
- int currentItem = getCurrentShowDetailItem(srcElement, showDetailItems);
- int disclosedItem = calculateDisclosedShowDetailItem(showDetailItems);
- int curItem = 0;
-
- //iterate over showDetailItem elements
- Iterator<Node> itItems = showDetailItems.iterator();
- while (itItems.hasNext()) {
- Node nodeItem = itItems.next();
- if (nodeItem instanceof Element) {
- Element elemItem = (Element)nodeItem;
- appendShowDetailItemTD(
- trElement,
- elemItem,
- currentItem == curItem,
- disclosedItem == curItem);
- if (curItem < showDetailItems.size() - 1) {
- appendSeparatorTD(trElement);
- }
- curItem++;
- }
- }
-
- //append last separator
- appendSeparatorTD(trElement, SEP_POS_END);
- }
-
- private void appendSeparatorTD(Element trElement, int sepPosition) {
- Element tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- if (sepPosition == SEP_POS_START) {
- appendAttribute(tdElement, "style", "width:0%;"); //$NON-NLS-1$ //$NON-NLS-2$
- } else if (sepPosition == SEP_POS_END) {
- appendAttribute(tdElement, "style", "width:100%;"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- Element bElement = appendChildElement("b", tdElement); //$NON-NLS-1$
- appendAttribute(bElement, "style", "margin-left:0px;"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- private void appendSeparatorTD(Element trElement) {
- appendSeparatorTD(trElement, SEP_POS_BETWEEN);
- }
-
- private void appendShowDetailItemTD(Element trElement, Element showDetailItem, boolean isCurrent, boolean isDisclosed) {
- boolean isDisabled = false;
- String attrShowDetailItemDisabled = showDetailItem.getAttribute("disabled"); //$NON-NLS-1$
- if (Boolean.TRUE.toString().equalsIgnoreCase(attrShowDetailItemDisabled)) {
- isDisabled = true;
- }
- Element tdElement = appendChildElement("td", trElement); //$NON-NLS-1$
- appendAttribute(tdElement, "height", "1"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "nowrap", "nowrap"); //$NON-NLS-1$ //$NON-NLS-2$
- String tdStyle;
- if (isDisclosed && !isDisabled) {
- tdStyle = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:bold;padding:0px 8px;"; //$NON-NLS-1$
- } else {
- tdStyle = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;padding:0px 8px;"; //$NON-NLS-1$
- }
- appendAttribute(tdElement, "style", tdStyle); //$NON-NLS-1$
- Element aElement = appendChildElement("a", tdElement); //$NON-NLS-1$
- String aStyle;
- if (isDisabled) {
- appendAttribute(aElement, "name", "name"); //$NON-NLS-1$ //$NON-NLS-2$
- aStyle = "color:#999999;"; //$NON-NLS-1$
- } else {
- appendAttribute(aElement, "href", "#"); //$NON-NLS-1$ //$NON-NLS-2$
- if (isDisclosed) {
- aStyle = "color:#669966;text-decoration:none;"; //$NON-NLS-1$
- } else {
- aStyle = "color:#003333;"; //$NON-NLS-1$
- }
- }
- if (isCurrent) {
- aStyle += "border:1px solid #99cc99;padding:2px;"; //$NON-NLS-1$
- }
- String attrShowDetailItemInlineStyle = showDetailItem.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (attrShowDetailItemInlineStyle != null &&
- attrShowDetailItemInlineStyle.length() > 0) {
- aStyle += attrShowDetailItemInlineStyle;
- }
- if (aStyle.length() > 0) {
- appendAttribute(aElement, "style", aStyle); //$NON-NLS-1$
- }
- ITransformOperation operation =
- TransformOperationFactory.getInstance().getTransformOperation(
- TransformOperationFactory.OP_CopyAttributeWithRenameOperation,
- new String[]{"styleClass", "class"}); //$NON-NLS-1$ //$NON-NLS-2$
- operation.transform(showDetailItem, aElement);
- String attrShowDetailItemTextAndAccessKey = showDetailItem.getAttribute("textAndAccessKey"); //$NON-NLS-1$
- if (attrShowDetailItemTextAndAccessKey != null &&
- attrShowDetailItemTextAndAccessKey.length() > 0) {
- appendChildText(attrShowDetailItemTextAndAccessKey, aElement);
- } else {
- String attrShowDetailItemText = showDetailItem.getAttribute("text"); //$NON-NLS-1$
- if (attrShowDetailItemText != null && attrShowDetailItemText.length() > 0) {
- appendChildText(attrShowDetailItemText, aElement);
- }
- }
- }
-
- private int getCurrentShowDetailItem(
- Element srcElement, List<Node> showDetailItems) {
- int disclosedItem = TrinidadUtils.getCurrentChildIndex(srcElement);
- if (disclosedItem == -1) {
- disclosedItem = calculateDisclosedShowDetailItem(showDetailItems);
- TrinidadUtils.setCurrentChildIndex(srcElement, disclosedItem);
- }
- return disclosedItem;
- }
-
- private int calculateDisclosedShowDetailItem(List<Node> showDetailItems) {
- int disclosedItem = -1;
- int curItem = 0;
- Iterator<Node> itItems = showDetailItems.iterator();
- while (itItems.hasNext()) {
- Node item = itItems.next();
- if (item instanceof Element) {
- Element elemItem = (Element)item;
- String attrDisclosedVal = elemItem.getAttribute("disclosed"); //$NON-NLS-1$
- if (Boolean.TRUE.toString().equalsIgnoreCase(
- attrDisclosedVal)) {
- disclosedItem = curItem;
- break;
- }
- }
- curItem++;
- }
- //if none explicitly disclosed, consider first non-disabled tab disclosed
- if (disclosedItem == -1) {
- curItem = 0;
- itItems = showDetailItems.iterator();
- while (itItems.hasNext()) {
- Node item = itItems.next();
- if (item instanceof Element) {
- Element elemItem = (Element)item;
- String attrDisabledVal = elemItem.getAttribute("disabled"); //$NON-NLS-1$
- if (!(Boolean.TRUE.toString().equalsIgnoreCase(attrDisabledVal))) {
- disclosedItem = curItem;
- break;
- }
- }
- curItem++;
- }
- }
- //if none explicitly disclosed and all disabled, consider first tab disclosed
- if (disclosedItem == -1) {
- disclosedItem = 0;
- }
- return disclosedItem;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectBooleanOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectBooleanOperation.java
deleted file mode 100644
index 15c31d7aa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectBooleanOperation.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for any "selectBoolean..."
- * JSF Elements.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectBooleanOperation extends AbstractLabelAndHelpOperation {
-
- private String inputType;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- if (getParameters().length < 1) {
- getLog().error("Warning.TransformOperationFactory.TooFewParameters", getTransformOperationID()); //$NON-NLS-1$
- return null;
- } else {
- inputType = getParameters()[0];
- }
- return super.transform(srcElement, curElement);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- Element spanElement = appendChildElement("span", parentElement); //$NON-NLS-1$
- Element inputElement = appendChildElement("input", spanElement); //$NON-NLS-1$
- appendAttribute(inputElement, "type", inputType); //$NON-NLS-1$
- Element labelElement = appendChildElement("label", spanElement); //$NON-NLS-1$
- String textAndAccessKey = srcElement.getAttribute("textAndAccessKey"); //$NON-NLS-1$
- if (textAndAccessKey != null && textAndAccessKey.length() > 0) {
- appendChildText(textAndAccessKey, labelElement);
- } else {
- String text = srcElement.getAttribute("text"); //$NON-NLS-1$
- if (text != null) {
- appendChildText(text, labelElement);
- }
- }
- appendAttribute(spanElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectListboxChoiceOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectListboxChoiceOperation.java
deleted file mode 100644
index b69db5fd9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectListboxChoiceOperation.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItem;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItemModel;
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for "selectManyListbox",
- * "selectOneListbox", and "selectOneChoice" JSF Elements.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectListboxChoiceOperation extends AbstractLabelAndHelpOperation {
-
- private boolean isMultiple;
- private boolean showSize;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- if (getParameters().length < 2) {
- getLog().error("Warning.TransformOperationFactory.TooFewParameters", getTransformOperationID()); //$NON-NLS-1$
- return null;
- } else {
- isMultiple = Boolean.parseBoolean(getParameters()[0]);
- showSize = Boolean.parseBoolean(getParameters()[1]);
- }
- return super.transform(srcElement, curElement);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- Element selectElement = appendChildElement("select", parentElement); //$NON-NLS-1$
- if (isMultiple) {
- appendAttribute(selectElement, "multiple", ""); //$NON-NLS-1$ //$NON-NLS-2$
- }
- List<SelectItem> selectItems = SelectItemModel.getModel(srcElement);
- if (showSize) {
- int size;
- String attrSize = srcElement.getAttribute("size"); //$NON-NLS-1$
- if (attrSize != null && attrSize.length() > 0) {
- try {
- size = Integer.parseInt(attrSize);
- } catch(NumberFormatException nfe) {
- size = 1;
- }
- } else {
- size = 1;
- }
- size = Math.max(size, selectItems.size());
- appendAttribute(selectElement, "size", String.valueOf(size)); //$NON-NLS-1$
- }
- boolean isFirstSelectItem = !isMultiple;
- Iterator<SelectItem> itSelectItems = selectItems.iterator();
- while (itSelectItems.hasNext()) {
- SelectItem selectItem = itSelectItems.next();
- Element optionElement = appendChildElement("option", selectElement); //$NON-NLS-1$
- if (isFirstSelectItem) {
- appendAttribute(optionElement, "selected", ""); //$NON-NLS-1$ //$NON-NLS-2$
- isFirstSelectItem = false;
- }
- appendChildText(selectItem.getLabel(), optionElement);
- }
- //TODO: append option elements
- appendAttribute(selectElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectManyCheckboxOneRadioOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectManyCheckboxOneRadioOperation.java
deleted file mode 100644
index d28008c15..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectManyCheckboxOneRadioOperation.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItem;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItemModel;
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for "selectManyCheckbox" and
- * "selectOneRadio" JSF Elements.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectManyCheckboxOneRadioOperation extends AbstractLabelAndHelpOperation {
-
- private String inputType;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- if (getParameters().length < 1) {
- getLog().error("Warning.TransformOperationFactory.TooFewParameters", getTransformOperationID()); //$NON-NLS-1$
- return null;
- } else {
- inputType = getParameters()[0];
- }
- return super.transform(srcElement, curElement);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations.AbstractLabelAndHelpOperation#appendControl(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- protected void appendControl(Element srcElement, Element parentElement) {
- Element spanElement = appendChildElement("span", parentElement); //$NON-NLS-1$
- String layout = srcElement.getAttribute("layout"); //$NON-NLS-1$
- List<SelectItem> selectItems = SelectItemModel.getModel(srcElement);
- Iterator<SelectItem> itSelectItems = selectItems.iterator();
- while (itSelectItems.hasNext()) {
- SelectItem selectItem = itSelectItems.next();
- Element inputElement = appendChildElement("input", spanElement); //$NON-NLS-1$
- appendAttribute(inputElement, "type", inputType); //$NON-NLS-1$
- Element labelElement = appendChildElement("label", spanElement); //$NON-NLS-1$
- appendChildText(selectItem.getLabel(), labelElement);
- if (layout == null || !layout.equals("horizontal")) { //$NON-NLS-1$
- if (itSelectItems.hasNext()) {
- appendChildElement("br", spanElement); //$NON-NLS-1$
- }
- }
- }
- appendAttribute(spanElement, "style", //$NON-NLS-1$
- calculateStyle(STYLE_CONTROLELEMENT, srcElement, "contentStyle")); //$NON-NLS-1$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectShuttleOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectShuttleOperation.java
deleted file mode 100644
index 20553dd74..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/SelectShuttleOperation.java
+++ /dev/null
@@ -1,257 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.Messages;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItem;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.model.SelectItemModel;
-import org.eclipse.jst.pagedesigner.converter.ConvertPosition;
-import org.w3c.dom.Element;
-
-/**
- * ITransformOperation implementation specifically for "selectManyShuttle" and
- * "selectOrderShuttle" JSF Elements.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectShuttleOperation extends AbstractTrinidadTransformOperation {
-
- private static final String STYLE_HEADER = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:9pt;color:#669966;font-weight:bold;padding:0px 0px 0px 18px;"; //$NON-NLS-1$
- private static final String STYLE_REQUIRED = "color:#669966;font-family:Courier,sans-serif;"; //$NON-NLS-1$
- private static final String STYLE_LISTCOLUMN = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;"; //$NON-NLS-1$
- private static final String STYLE_SELECT = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;"; //$NON-NLS-1$
- private static final String STYLE_DESCRIPTION = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#000000;"; //$NON-NLS-1$
- private static final String STYLE_LINK = "font-family:Arial,Helvetica,Geneva,sans-serif;font-size:10pt;font-weight:normal;color:#003333;"; //$NON-NLS-1$
- private static final String DEFAULT_SIZE = "10"; //$NON-NLS-1$
-
- private static final String[] LINKS_MOVE = new String[]{
- Messages.SelectShuttleOperation_LinkMove,
- Messages.SelectShuttleOperation_LinkMoveAll,
- Messages.SelectShuttleOperation_LinkRemove,
- Messages.SelectShuttleOperation_LinkRemoveAll
- };
- private static final String[] LINKS_ORDER = new String[]{
- Messages.SelectShuttleOperation_LinkTop,
- Messages.SelectShuttleOperation_LinkUp,
- Messages.SelectShuttleOperation_LinkDown,
- Messages.SelectShuttleOperation_LinkBottom
- };
-
- private boolean showOrderLinks;
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
- //get parameter
- if (getParameters().length < 1) {
- getLog().error("Warning.TransformOperationFactory.TooFewParameters", getTransformOperationID()); //$NON-NLS-1$
- return null;
- } else {
- showOrderLinks = Boolean.parseBoolean(getParameters()[0]);
- }
-
- //build outer table element
- Element outerTableElement = createElement("table"); //$NON-NLS-1$
- appendAttribute(outerTableElement, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerTableElement, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerTableElement, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(outerTableElement, "width", "10%"); //$NON-NLS-1$ //$NON-NLS-2$
- String inlineStyle = srcElement.getAttribute("inlineStyle"); //$NON-NLS-1$
- if (inlineStyle != null && inlineStyle.length() > 0) {
- appendAttribute(outerTableElement, "style", inlineStyle); //$NON-NLS-1$
- }
- String styleClass = srcElement.getAttribute("styleClass"); //$NON-NLS-1$
- if (styleClass != null && styleClass.length() > 0) {
- appendAttribute(outerTableElement, "class", styleClass); //$NON-NLS-1$
- }
-
- //build header row
- Element trHeaderElement = appendChildElement("tr", outerTableElement); //$NON-NLS-1$
- Element tdLeadingHeaderElement = appendChildElement("td", trHeaderElement); //$NON-NLS-1$
- String leadingHeader = srcElement.getAttribute("leadingHeader"); //$NON-NLS-1$
- if (leadingHeader != null && leadingHeader.length() > 0) {
- appendAttribute(tdLeadingHeaderElement, "style", STYLE_HEADER); //$NON-NLS-1$
- appendAttribute(tdLeadingHeaderElement, "valign", "bottom"); //$NON-NLS-1$ //$NON-NLS-2$
- appendChildText(leadingHeader, tdLeadingHeaderElement);
- }
- appendChildElement("td", trHeaderElement); //$NON-NLS-1$
- Element tdTrailingHeaderElement = appendChildElement("td", trHeaderElement); //$NON-NLS-1$
- String required = srcElement.getAttribute("required"); //$NON-NLS-1$
- String trailingHeader = srcElement.getAttribute("trailingHeader"); //$NON-NLS-1$
- if ((required != null && Boolean.parseBoolean(required)) || (trailingHeader != null && trailingHeader.length() > 0)) {
- appendAttribute(tdTrailingHeaderElement, "style", STYLE_HEADER); //$NON-NLS-1$
- appendAttribute(tdTrailingHeaderElement, "valign", "bottom"); //$NON-NLS-1$ //$NON-NLS-2$
- if (required != null && Boolean.parseBoolean(required)) {
- Element spanRequiredElement = appendChildElement("span", tdTrailingHeaderElement); //$NON-NLS-1$
- appendAttribute(spanRequiredElement, "style", STYLE_REQUIRED); //$NON-NLS-1$
- appendChildText("*", spanRequiredElement); //$NON-NLS-1$
- }
- if (trailingHeader != null && trailingHeader.length() > 0) {
- appendChildText(trailingHeader, tdTrailingHeaderElement);
- }
- }
-
- //build content row
- Element trContentElement = appendChildElement("tr", outerTableElement); //$NON-NLS-1$
- buildListColumn(srcElement, trContentElement, true);
- buildLinkColumn(trContentElement, LINKS_MOVE);
- buildListColumn(srcElement, trContentElement, false);
-
- return outerTableElement;
- }
-
- private void buildListColumn(Element srcElement, Element parentElement, boolean isLeadingColumn) {
- //build outer structure
- Element tdElement0 = appendChildElement("td", parentElement); //$NON-NLS-1$
- Element tableElement0 = appendChildElement("table", tdElement0); //$NON-NLS-1$
- appendAttribute(tableElement0, "style", "width:100%;"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement0, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement0, "cellspacing", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement0, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- Element tbodyElement0 = appendChildElement("tbody", tableElement0); //$NON-NLS-1$
- Element trElement0 = appendChildElement("tr", tbodyElement0); //$NON-NLS-1$
- Element tdElement1 = appendChildElement("td", trElement0); //$NON-NLS-1$
- Element divElement0 = appendChildElement("div", tdElement1); //$NON-NLS-1$
- appendAttribute(divElement0, "style", STYLE_LISTCOLUMN); //$NON-NLS-1$
- Element tableElement1 = appendChildElement("table", divElement0); //$NON-NLS-1$
- appendAttribute(tableElement1, "cellpadding", "0"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tableElement1, "border", "0"); //$NON-NLS-1$ //$NON-NLS-2$
-
- //build filter structure
- if (isLeadingColumn) {
- Element filterFacet = getChildFacetByName(srcElement, "filter"); //$NON-NLS-1$
- if (filterFacet != null) {
- Element trFilterElement = appendChildElement("tr", tableElement1); //$NON-NLS-1$
- Element tdFilterElement = appendChildElement("td", trFilterElement); //$NON-NLS-1$
- appendAttribute(tdFilterElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFilterElement, "valign", "middle"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFilterElement, "colspan", "3"); //$NON-NLS-1$ //$NON-NLS-2$
- tagConverterContext.addChild(filterFacet, new ConvertPosition(tdFilterElement, 0));
- }
- }
-
- //build select element structure
- Element trSelectElement = appendChildElement("tr", tableElement1); //$NON-NLS-1$
- Element tdSelectElement = appendChildElement("td", trSelectElement); //$NON-NLS-1$
- appendAttribute(tdSelectElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdSelectElement, "valign", "middle"); //$NON-NLS-1$ //$NON-NLS-2$
- Element spanSelectElement = appendChildElement("span", tdSelectElement); //$NON-NLS-1$
- Element selectElement = appendChildElement("select", spanSelectElement); //$NON-NLS-1$
- appendAttribute(selectElement, "multiple", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(selectElement, "style", STYLE_SELECT); //$NON-NLS-1$
- appendAttribute(selectElement, "size", getSizeString(srcElement)); //$NON-NLS-1$
-
- if (isLeadingColumn) {
- List<SelectItem> selectItems = SelectItemModel.getModel(srcElement);
- Iterator<SelectItem> itSelectItems = selectItems.iterator();
- while (itSelectItems.hasNext()) {
- SelectItem selectItem = itSelectItems.next();
- Element optionElement = appendChildElement("option", selectElement); //$NON-NLS-1$
- appendChildText(selectItem.getLabel(), optionElement);
- }
- }
- Element optionElement = appendChildElement("option", selectElement); //$NON-NLS-1$
- appendChildText("_______________", optionElement); //$NON-NLS-1$
-
- //build order links
- if (!isLeadingColumn && showOrderLinks) {
- buildLinkColumn(trSelectElement, LINKS_ORDER);
- }
-
- //build description structure
- boolean showDesc = false;
- String showDescAttrName;
- if (isLeadingColumn) {
- showDescAttrName = "leadingDescShown"; //$NON-NLS-1$
- } else {
- showDescAttrName = "trailingDescShown"; //$NON-NLS-1$
- }
- String showDescAttr = srcElement.getAttribute(showDescAttrName);
- if (showDescAttr != null && showDescAttr.length() > 0) {
- showDesc = Boolean.parseBoolean(showDescAttr);
- }
- if (showDesc) {
- Element trDescElement = appendChildElement("tr", tableElement1); //$NON-NLS-1$
- Element tdDescElement = appendChildElement("td", trDescElement); //$NON-NLS-1$
- appendAttribute(tdDescElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdDescElement, "valign", "middle"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdDescElement, "colspan", "3"); //$NON-NLS-1$ //$NON-NLS-2$
- Element spanDescElement = appendChildElement("span", tdDescElement); //$NON-NLS-1$
- appendAttribute(spanDescElement, "style", STYLE_DESCRIPTION); //$NON-NLS-1$
- appendChildText(Messages.SelectShuttleOperation_Description, spanDescElement);
- appendChildElement("div", tdDescElement); //$NON-NLS-1$
- Element textareaElement = appendChildElement("textarea", tdDescElement); //$NON-NLS-1$
- appendAttribute(textareaElement, "rows", "2"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(textareaElement, "cols", "18"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(textareaElement, "readonly", ""); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- //build footer structure
- String footerFacetName;
- if (isLeadingColumn) {
- footerFacetName = "leadingFooter"; //$NON-NLS-1$
- } else {
- footerFacetName = "trailingFooter"; //$NON-NLS-1$
- }
- Element footerFacet = getChildFacetByName(srcElement, footerFacetName);
- if (footerFacet != null) {
- Element trFooterElement = appendChildElement("tr", tableElement1); //$NON-NLS-1$
- Element tdFooterElement = appendChildElement("td", trFooterElement); //$NON-NLS-1$
- appendAttribute(tdFooterElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFooterElement, "valign", "middle"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdFooterElement, "colspan", "3"); //$NON-NLS-1$ //$NON-NLS-2$
- tagConverterContext.addChild(footerFacet, new ConvertPosition(tdFooterElement, 0));
- }
- }
-
- private void buildLinkColumn(Element parentElement, String[] linkText) {
- Element tdElement = appendChildElement("td", parentElement); //$NON-NLS-1$
- appendAttribute(tdElement, "align", "center"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "valign", "middle"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "nowrap", ""); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(tdElement, "style", "padding:5px;"); //$NON-NLS-1$ //$NON-NLS-2$
- for (int i = 0; i < linkText.length; i++) {
- Element aElement = appendChildElement("a", tdElement); //$NON-NLS-1$
- appendAttribute(aElement, "href", "#"); //$NON-NLS-1$ //$NON-NLS-2$
- appendAttribute(aElement, "style", STYLE_LINK); //$NON-NLS-1$
- appendChildText(linkText[i], aElement);
- if (i < linkText.length - 1) {
- appendChildElement("br", tdElement); //$NON-NLS-1$
- }
- }
- }
-
- private String getSizeString(Element srcElement) {
- String size = DEFAULT_SIZE;
- String sizeAttr = srcElement.getAttribute("size"); //$NON-NLS-1$
- if (sizeAttr != null && sizeAttr.length() > 0) {
- try {
- int iSize = Integer.parseInt(sizeAttr);
- iSize = Math.max(iSize, 10);
- iSize = Math.min(iSize, 20);
- size = String.valueOf(iSize);
- } catch(NumberFormatException nfe) {
- //ignore - default of "10" will be returned
- }
- }
- return size;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/ShowDetailItemOperation.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/ShowDetailItemOperation.java
deleted file mode 100644
index 4cc395290..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/converter/operations/ShowDetailItemOperation.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.converter.operations;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.Messages;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * ITransformOperation implementation specifically for the "showDetailItem" JSF
- * Element.
- *
- * <br><b>Note:</b> requires ITransformOperation.setTagConverterContext(...) to
- * have been called to provide a valid ITagConverterContext instance prior to
- * a call to the transform(...) method.
- *
- * @author Ian Trimble - Oracle
- */
-public class ShowDetailItemOperation extends AbstractTrinidadTransformOperation {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.dtmanager.converter.operations.AbstractTransformOperation#transform(org.w3c.dom.Element, org.w3c.dom.Element)
- */
- @Override
- public Element transform(Element srcElement, Element curElement) {
-
- /*
- * We need to represent showDetailItem as a container on the design
- * canvas, so we need to return a top-level element to contain converted
- * child elements. However, at runtime, it is the parent that renders
- * the container element for showDetailItem's children. Therefore, we
- * need to determine the parent element in order to know what top-level
- * element it will render at runtime. There's no obvious way to do this
- * using generic operations alone; hence, we need this specialization.
- */
-
- Element topElement = null;
-
- /*
- * create top-level element type, which may differ depending on parent
- * element
- */
- Element parentSrcElement = getParentElement(srcElement);
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELTABBED.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper(parentSrcElement))) {
- topElement = createElement("div"); //$NON-NLS-1$
- } else {
- //default to div element
- topElement = createElement("div"); //$NON-NLS-1$
- }
-
- if (getCopyChildrenNodes(srcElement).size() > 0) {
- //copy all children
- tagConverterContext.copyChildren(srcElement, topElement);
- } else {
- appendAttribute(
- topElement,
- "style", //$NON-NLS-1$
- ITrinidadConstants.STYLE_EMPTYELEMENT);
- appendChildText(
- Messages.ShowDetailItemOperation_EmptyShowDetailItemTag,
- topElement);
- }
- return topElement;
- }
-
- private Element getParentElement(Node node) {
- Element parentElement = null;
- Node curNode = node;
- while (curNode != null) {
- curNode = curNode.getParentNode();
- if (curNode instanceof Element) {
- parentElement = (Element)curNode;
- break;
- }
- }
- return parentElement;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/el/TrinidadDecorativeVariableResolver.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/el/TrinidadDecorativeVariableResolver.java
deleted file mode 100644
index d9c6c29d7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/el/TrinidadDecorativeVariableResolver.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.el;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jst.jsf.context.symbol.ERuntimeSource;
-import org.eclipse.jst.jsf.context.symbol.ISymbol;
-import org.eclipse.jst.jsf.designtime.context.DTFacesContext;
-import org.eclipse.jst.jsf.designtime.el.AbstractDTVariableResolver;
-import org.eclipse.jst.jsf.designtime.el.IDecorativeResolver;
-import org.eclipse.jst.jsf.designtime.symbols.JSFSymbolFactory;
-
-/**
- * A decorative dt variable resolver that shadows Trinidad's runtime resolver.
- *
- * @author cbateman
- *
- */
-public class TrinidadDecorativeVariableResolver extends
- AbstractDTVariableResolver implements IDecorativeResolver
-{
- private final static JSFSymbolFactory _symbolFactory = new JSFSymbolFactory();
-
- public final static String PAGE_FLOW_SCOPE_VARIABLE_NAME = "pageFlowScope"; //$NON-NLS-1$
- public final static String PROCESS_SCOPE_VARIABLE_NAME = "processScope"; //$NON-NLS-1$
-
- public final static String REQUEST_CONTEXT_VARIABLE_NAME = "requestContext"; //$NON-NLS-1$
- public final static String REQUEST_CONTEXT_CLASS_NAME = "org.apache.myfaces.trinidad.context.RequestContext"; //$NON-NLS-1$
-
- @Override
- public ISymbol[] getAllVariables(final DTFacesContext facesContext,
- final IAdaptable externalContextKey)
- {
- final Map<String, ISymbol> symbols = createSymbols(facesContext);
- return symbols.values().toArray(ISymbol.EMPTY_SYMBOL_ARRAY);
- }
-
- @Override
- public ISymbol resolveVariable(final DTFacesContext context,
- final String name, final IAdaptable externalContextKey)
- {
- return createSymbols(context).get(name);
- }
-
- private Map<String, ISymbol> createSymbols(final DTFacesContext context)
- {
- final IResource res = context.adaptContextObject();
-
- if (res != null)
- {
- final IProject project = res.getProject();
- if (project != null)
- {
- final Map<String, ISymbol> symbols = new HashMap<String, ISymbol>();
-
- final ISymbol requestContextVar = _symbolFactory
- .createBeanOrUnknownInstanceSymbol(project,
- REQUEST_CONTEXT_CLASS_NAME,
- PAGE_FLOW_SCOPE_VARIABLE_NAME,
- ERuntimeSource.OTHER_LITERAL);
- symbols.put(REQUEST_CONTEXT_VARIABLE_NAME, requestContextVar);
-
- // both pageFlowScope and processScope return the same variable
- // TODO: we may be able to populate this map
- final ISymbol pageFlowVar = _symbolFactory
- .createUnknownInstanceSymbol(
- PAGE_FLOW_SCOPE_VARIABLE_NAME,
- ERuntimeSource.OTHER_LITERAL);
- symbols.put(PAGE_FLOW_SCOPE_VARIABLE_NAME, pageFlowVar);
- final ISymbol processScopeVar = _symbolFactory
- .createUnknownInstanceSymbol(
- PROCESS_SCOPE_VARIABLE_NAME,
- ERuntimeSource.OTHER_LITERAL);
- symbols.put(PROCESS_SCOPE_VARIABLE_NAME, processScopeVar);
- return symbols;
- }
- }
- return Collections.emptyMap();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/DefaultTrinidadCoreElementEdit.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/DefaultTrinidadCoreElementEdit.java
deleted file mode 100644
index a12ea8ebe..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/DefaultTrinidadCoreElementEdit.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;
-
-import org.eclipse.jst.pagedesigner.elementedit.AbstractElementEdit;
-
-/**
- * Default IElementEdit implementation for Trinidad core tag library.
- *
- * @author Ian Trimble - Oracle
- */
-public class DefaultTrinidadCoreElementEdit extends AbstractElementEdit {
-
- /*
- * Currently no default behaviour, but likely we will add some.
- * Delete this comment when functionality added.
- */
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelFormLayoutChildElementEdit.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelFormLayoutChildElementEdit.java
deleted file mode 100644
index 47b376f6d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelFormLayoutChildElementEdit.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.IJSFConstants;
-import org.eclipse.jst.pagedesigner.parts.ElementEditPart;
-import org.w3c.dom.Element;
-
-/**
- * IElementEdit implementation for Trinidad tags that are potentially children
- * of the panelFormLayout tag, and therefore may need to refresh panelFormLayout
- * on model change.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelFormLayoutChildElementEdit extends
- DefaultTrinidadCoreElementEdit {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.elementedit.AbstractElementEdit#handleModelChange(org.w3c.dom.Element, org.eclipse.jst.pagedesigner.parts.ElementEditPart, boolean)
- */
- @Override
- public boolean handleModelChange(Element ele, ElementEditPart part,
- boolean recursive) {
- boolean handled = false;
- EditPart parentPart = part.getParent();
- while (parentPart instanceof ElementEditPart) {
- ElementEditPart parentElementEditPart = (ElementEditPart)parentPart;
- TagIdentifier tagID = parentElementEditPart.getTagIdentifier();
- if (tagID != null) {
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELFORMLAYOUT.isSameTagType(tagID)) {
- parentElementEditPart.refreshModelChange(recursive);
- handled = true;
- break;
- } else if (
- ITrinidadConstants.TAG_IDENTIFIER_GROUP.isSameTagType(tagID) ||
- IJSFConstants.TAG_IDENTIFIER_FACET.isSameTagType(tagID)) {
- parentPart = parentPart.getParent();
- } else {
- break;
- }
- }
- }
- return handled;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelTabbedElementEdit.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelTabbedElementEdit.java
deleted file mode 100644
index dc086aaac..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/PanelTabbedElementEdit.java
+++ /dev/null
@@ -1,248 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.DragTracker;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.requests.DropRequest;
-import org.eclipse.gef.requests.LocationRequest;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.TrinidadUtils;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.eclipse.jst.pagedesigner.editpolicies.DragMoveEditPolicy;
-import org.eclipse.jst.pagedesigner.editpolicies.ElementResizableEditPolicy;
-import org.eclipse.jst.pagedesigner.itemcreation.ItemCreationEditPolicy;
-import org.eclipse.jst.pagedesigner.itemcreation.ItemCreationRequest;
-import org.eclipse.jst.pagedesigner.parts.ElementEditPart;
-import org.eclipse.jst.pagedesigner.parts.NodeEditPart;
-import org.eclipse.jst.pagedesigner.tools.ObjectModeDragTracker;
-import org.eclipse.jst.pagedesigner.validation.caret.ActionData;
-import org.eclipse.jst.pagedesigner.validation.caret.DefaultPositionRule;
-import org.eclipse.jst.pagedesigner.validation.caret.DnDPositionValidator;
-import org.eclipse.jst.pagedesigner.validation.caret.DropActionData;
-import org.eclipse.jst.pagedesigner.validation.caret.IPositionMediator;
-import org.eclipse.jst.pagedesigner.validation.caret.Target;
-import org.eclipse.jst.pagedesigner.validation.caret.DropActionData.DropData;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * IElementEdit implementation for Trinidad's panelTabbed tag.
- *
- * @author Ian Trimble - Oracle
- */
-public class PanelTabbedElementEdit extends DefaultTrinidadCoreElementEdit {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.elementedit.AbstractElementEdit#createEditPolicies(org.eclipse.jst.pagedesigner.parts.ElementEditPart)
- */
- @Override
- public void createEditPolicies(ElementEditPart part) {
- part.installEditPolicy(
- EditPolicy.SELECTION_FEEDBACK_ROLE,
- new PanelTabbedElementResizableEditPolicy());
- part.installEditPolicy(
- EditPolicy.PRIMARY_DRAG_ROLE,
- new PanelTabbedDragMoveEditPolicy());
- part.installEditPolicy(
- ItemCreationRequest.REQ_ITEM_CREATION,
- new PanelTabbedItemCreationEditPolicy());
- }
-
- /**
- * Extends ElementResizableEditPolicy to determine if tab is clicked and
- * respond accordingly.
- *
- * @author Ian Trimble - Oracle
- */
- public static class PanelTabbedElementResizableEditPolicy extends ElementResizableEditPolicy {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.editpolicies.ElementResizableEditPolicy#getSelectionDragTracker(org.eclipse.gef.requests.LocationRequest)
- */
- @Override
- public DragTracker getSelectionDragTracker(LocationRequest request) {
- return getSelectionTracker(request);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.editpolicies.ElementResizableEditPolicy#getSelectionTracker(org.eclipse.gef.requests.LocationRequest)
- */
- @Override
- protected DragTracker getSelectionTracker(LocationRequest request) {
- final GraphicalEditPart part = (GraphicalEditPart)getHost();
- if (part instanceof NodeEditPart) {
- final Node node = ((NodeEditPart)part).getDOMNode();
- if (getShowDetailItemCount(node) > 0) {
- ObjectModeDragTracker dragTracker = new ObjectModeDragTracker(getHost()) {
- protected boolean handleButtonDown(int button) {
- if (button == 1) {
- final int tabIndex = getTabIndex(getLocation());
- final EditPart editPart = getSourceEditPart();
- if (editPart instanceof ElementEditPart) {
- final Node node = ((ElementEditPart)editPart).getDOMNode();
- if (TrinidadUtils.setCurrentChildIndex(node, tabIndex)) {
- ((ElementEditPart)editPart).refresh(true);
- }
- }
- }
- return super.handleButtonDown(button);
- }
- };
- return dragTracker;
- }
- }
- return new ObjectModeDragTracker(getHost());
- }
-
- private int getTabIndex(Point location) {
- int tabIndex = -1;
- final GraphicalEditPart part = (GraphicalEditPart)getHost();
- if (part instanceof NodeEditPart) {
- final Node node = ((NodeEditPart)part).getDOMNode();
- final IFigure figure = part.getFigure();
- Point relLocation = location.getCopy();
- figure.translateToRelative(relLocation);
- final int showDetailItemCount = getShowDetailItemCount(node);
- if (showDetailItemCount > 0) {
- final int tabWidth = figure.getBounds().width / showDetailItemCount;
- tabIndex = relLocation.x / tabWidth;
- if (tabIndex > showDetailItemCount - 1) {
- tabIndex = showDetailItemCount - 1;
- }
- }
- }
- return tabIndex;
- }
-
- private int getShowDetailItemCount(Node node) {
- int count = 0;
- if (node != null) {
- NodeList childNodes = node.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- Node childNode = childNodes.item(i);
- if (childNode instanceof Element) {
- if (ITrinidadConstants.TAG_IDENTIFIER_SHOWDETAILITEM.isSameTagType(
- TagIdentifierFactory.createDocumentTagWrapper((Element)childNode))) {
- count++;
- }
- }
- }
- }
- return count;
- }
-
- }
-
- /**
- * Extends DragMoveEditPolicy to add OnlyShowDetailItemsRule as a rule.
- *
- * @author Ian Trimble - Oracle
- */
- public static class PanelTabbedDragMoveEditPolicy extends DragMoveEditPolicy {
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.editpolicies.DropEditPolicy#createDropChildValidator(org.eclipse.gef.requests.DropRequest)
- */
- @Override
- protected IPositionMediator createDropChildValidator(DropRequest r) {
- DropData dropData = createDropData(r);
- if (dropData != null) {
- DnDPositionValidator validator =
- new DnDPositionValidator(new DropActionData(
- ActionData.COMPONENT_MOVE, dropData));
- validator.addRule(new OnlyShowDetailItemsRule(validator.getActionData()));
- return validator;
- }
- return null;
- }
-
- }
-
- /**
- * Extends ItemCreationEditPolicy to add OnlyShowDetailItemsRule as a rule.
- *
- * @author Ian Trimble - Oracle
- */
- public static class PanelTabbedItemCreationEditPolicy extends ItemCreationEditPolicy {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.editpolicies.DropEditPolicy#createDropChildValidator(org.eclipse.gef.requests.DropRequest)
- */
- @Override
- protected IPositionMediator createDropChildValidator(DropRequest r) {
- DropData dropData = createDropData(r);
- if (dropData != null) {
- DnDPositionValidator validator =
- new DnDPositionValidator(new DropActionData(
- ActionData.PALETTE_DND, dropData));
- validator.addRule(new OnlyShowDetailItemsRule(validator.getActionData()));
- return validator;
- }
- return null;
- }
-
- }
-
- /**
- * Extends DefaultPositionRule to only allow showDetailItem tags to be
- * dropped on panelTabbed tag.
- *
- * @author Ian Trimble - Oracle
- */
- private static class OnlyShowDetailItemsRule extends DefaultPositionRule {
-
- /**
- * Instantiates an instance.
- *
- * @param actionData ActionData instance.
- */
- public OnlyShowDetailItemsRule(ActionData actionData) {
- super(actionData);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.validation.caret.DefaultPositionRule#isEditable(org.eclipse.jst.pagedesigner.validation.caret.Target)
- */
- @Override
- public boolean isEditable(Target target) {
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELTABBED.isSameTagType(
- target.getTagWrapper())) {
- return isDataDroppable();
- }
- return true;
- }
-
- private boolean isDataDroppable() {
- ActionData actionData = getActionData();
- if (actionData instanceof DropActionData) {
- DropActionData dropActionData = (DropActionData)actionData;
- TagIdentifier tagIdentifier =
- (TagIdentifier)dropActionData.getDropData().getTagIdentifiers().get(0);
- if (ITrinidadConstants.TAG_IDENTIFIER_SHOWDETAILITEM.isSameTagType(
- tagIdentifier)) {
- return true;
- }
- }
- return false;
- }
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/ShowDetailItemElementEdit.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/ShowDetailItemElementEdit.java
deleted file mode 100644
index f0ba5bde8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/ShowDetailItemElementEdit.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;
-
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.pagedesigner.parts.ElementEditPart;
-import org.eclipse.jst.pagedesigner.validation.caret.IPositionMediator;
-import org.eclipse.jst.pagedesigner.validation.caret.Target;
-import org.eclipse.jst.pagedesigner.viewer.DefaultDropLocationStrategy;
-import org.eclipse.jst.pagedesigner.viewer.DesignPosition;
-import org.eclipse.jst.pagedesigner.viewer.IDropLocationStrategy;
-import org.w3c.dom.Element;
-
-/**
- * IElementEdit implementation for Trinidad's showDetailItem tag.
- *
- * @author Ian Trimble - Oracle
- */
-public class ShowDetailItemElementEdit extends DefaultTrinidadCoreElementEdit {
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.elementedit.AbstractElementEdit#handleModelChange(org.w3c.dom.Element, org.eclipse.jst.pagedesigner.parts.ElementEditPart, boolean)
- */
- @Override
- public boolean handleModelChange(
- Element ele, ElementEditPart part, boolean recursive) {
- boolean handled = false;
- EditPart parentPart = part.getParent();
- if (parentPart instanceof ElementEditPart) {
- ((ElementEditPart)parentPart).refreshModelChange(recursive);
- handled = true;
- }
- return handled;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.elementedit.AbstractElementEdit#getDropRequestorLocationStrategy(org.eclipse.jst.jsf.common.dom.TagIdentifier, org.eclipse.gef.EditPartViewer)
- */
- @Override
- public IDropLocationStrategy getDropRequestorLocationStrategy(
- TagIdentifier tag, EditPartViewer viewer) {
- return new ShowDetailItemDropLocationStrategy(viewer);
- }
-
- /**
- * Extends DefaultDropLocationStrategy.
- *
- * @author Ian Trimble - Oracle
- */
- private static class ShowDetailItemDropLocationStrategy extends DefaultDropLocationStrategy {
-
- /**
- * Instantiates an instance.
- *
- * @param viewer EditPartViewer instance.
- */
- public ShowDetailItemDropLocationStrategy(EditPartViewer viewer) {
- super(viewer);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.viewer.DefaultDropLocationStrategy#calculateDesignPosition(org.eclipse.gef.EditPart, org.eclipse.draw2d.geometry.Point, org.eclipse.jst.pagedesigner.validation.caret.IPositionMediator)
- */
- @Override
- public DesignPosition calculateDesignPosition(
- EditPart host, Point p, IPositionMediator validator) {
- DesignPosition position = null;
- //check if host is editable or get nearest editable ancestor
- host = validator.getEditableContainer(new Target(host));
- if (host instanceof ElementEditPart) {
- final TagIdentifier hostTagId =
- ((ElementEditPart)host).getTagIdentifier();
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELTABBED.isSameTagType(hostTagId)) {
- final int showDetailItemCount = host.getChildren().size();
- position = new DesignPosition(host, showDetailItemCount);
- if (!validator.isValidPosition(position)) {
- position = null;
- }
- }
- }
- return position;
- }
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/TrinidadCoreElementEditFactory.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/TrinidadCoreElementEditFactory.java
deleted file mode 100644
index 3a1d3c688..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/elementedit/TrinidadCoreElementEditFactory.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.elementedit;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.pagedesigner.elementedit.AbstractElementEditFactory;
-import org.eclipse.jst.pagedesigner.elementedit.IElementEdit;
-
-/**
- * AbstractElementEditFactory extension for Trinidad core tag library.
- *
- * @author Ian Trimble - Oracle
- */
-public class TrinidadCoreElementEditFactory extends AbstractElementEditFactory {
-
- /**
- * Instantiates an instance, with ITrinidadConstants.URI_CORE as the
- * supported URI.
- */
- public TrinidadCoreElementEditFactory() {
- super(ITrinidadConstants.URI_CORE);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jst.pagedesigner.elementedit.AbstractElementEditFactory#createElementEdit(org.eclipse.jst.jsf.common.dom.TagIdentifier)
- */
- public IElementEdit createElementEdit(final TagIdentifier tagIdentifier) {
- if (ITrinidadConstants.TAG_IDENTIFIER_PANELTABBED.isSameTagType(tagIdentifier)) {
- return new PanelTabbedElementEdit();
- } else if (ITrinidadConstants.TAG_IDENTIFIER_SHOWDETAILITEM.isSameTagType(tagIdentifier)) {
- return new ShowDetailItemElementEdit();
- } else if (
- ITrinidadConstants.TAG_IDENTIFIER_INPUTCOLOR.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_INPUTDATE.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_INPUTFILE.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_INPUTLISTOFVALUES.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_INPUTNUMBERSPINBOX.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_INPUTTEXT.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTBOOLEANCHECKBOX.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTBOOLEANRADIO.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTMANYCHECKBOX.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTMANYLISTBOX.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTONECHOICE.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTONELISTBOX.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_SELECTONERADIO.isSameTagType(tagIdentifier) ||
- ITrinidadConstants.TAG_IDENTIFIER_PANELLABELANDMESSAGE.isSameTagType(tagIdentifier)
- ) {
- return new PanelFormLayoutChildElementEdit();
- } else {
- return new DefaultTrinidadCoreElementEdit();
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/messages.properties
deleted file mode 100644
index 41e07169f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/messages.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-#
-###############################################################################
-PanelTabbedOperation_EmptyPanelTabbedTag=Empty panelTabbed tag - add child showDetailItem tags
-ShowDetailItemOperation_EmptyShowDetailItemTag=Empty showDetailItem tag - add children
-SelectItemModel_SampleItem1Label=Sample Label 1
-SelectItemModel_SampleItem1Value=Sample Value 1
-SelectItemModel_SampleItem2Label=Sample Label 2
-SelectItemModel_SampleItem2Value=Sample Value 2
-SelectItemModel_SampleItem3Label=Sample Label 3
-SelectItemModel_SampleItem3Value=Sample Value 3
-SelectShuttleOperation_Description=Description
-SelectShuttleOperation_LinkMove=Move
-SelectShuttleOperation_LinkMoveAll=Move All
-SelectShuttleOperation_LinkRemove=Remove
-SelectShuttleOperation_LinkRemoveAll=Remove All
-SelectShuttleOperation_LinkTop=Top
-SelectShuttleOperation_LinkUp=Up
-SelectShuttleOperation_LinkDown=Down
-SelectShuttleOperation_LinkBottom=Bottom \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItem.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItem.java
deleted file mode 100644
index f6a06bb31..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItem.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.model;
-
-/**
- * A simplified representation of a "selectItem" tag's most useful properties.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectItem {
-
- private String label;
- private String value;
-
- /**
- * Creates an instance.
- *
- * @param label The label.
- * @param value The value.
- */
- public SelectItem(String label, String value) {
- setLabel(label);
- setValue(value);
- }
-
- /**
- * Sets the label of this instance.
- *
- * @param label The new label.
- */
- public void setLabel(String label) {
- if (label != null) {
- this.label = label;
- } else {
- this.label = ""; //$NON-NLS-1$
- }
- }
-
- /**
- * Gets the label of this instance.
- *
- * @return The current label.
- */
- public String getLabel() {
- return label;
- }
-
- /**
- * Sets the value of this instance.
- *
- * @param value The new value.
- */
- public void setValue(String value) {
- if (value != null) {
- this.value = value;
- } else {
- this.value = ""; //$NON-NLS-1$
- }
- }
-
- /**
- * Gets the value of this instance.
- *
- * @return The current value.
- */
- public String getValue() {
- return value;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItemModel.java b/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItemModel.java
deleted file mode 100644
index 74d802e64..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.apache.trinidad.tagsupport/src/org/eclipse/jst/jsf/apache/trinidad/tagsupport/model/SelectItemModel.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/**
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- */
-package org.eclipse.jst.jsf.apache.trinidad.tagsupport.model;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.ITrinidadConstants;
-import org.eclipse.jst.jsf.apache.trinidad.tagsupport.Messages;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.core.internal.tld.IJSFConstants;
-import org.eclipse.jst.jsf.core.internal.tld.TagIdentifierFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.NodeList;
-
-/**
- * Provides a simple "selectItem"-like model to facilitate handling of both
- * standard JSF core selectItem tags and Trinidad selectItem tags, or a sample
- * model in the absence of either.
- *
- * @author Ian Trimble - Oracle
- */
-public class SelectItemModel {
-
- private static final List<SelectItem> SAMPLE_MODEL = new ArrayList<SelectItem>();
- static {
- SAMPLE_MODEL.add(new SelectItem(
- Messages.SelectItemModel_SampleItem1Label,
- Messages.SelectItemModel_SampleItem1Value));
- SAMPLE_MODEL.add(new SelectItem(
- Messages.SelectItemModel_SampleItem2Label,
- Messages.SelectItemModel_SampleItem2Value));
- SAMPLE_MODEL.add(new SelectItem(
- Messages.SelectItemModel_SampleItem3Label,
- Messages.SelectItemModel_SampleItem3Value));
- }
-
- /**
- * Gets a model as a List of SelectItem instances, derived from child
- * selectItem Elements, or a sample model if no suitable child Elements are
- * found.
- *
- * @param parentElement Parent Element instance to scan for child selectItem
- * Elements.
- * @return List of SelectItem instances.
- */
- public static final List<SelectItem> getModel(Element parentElement) {
- return getModel(parentElement, true);
- }
-
- /**
- * Gets a model as a List of SelectItem instances, derived from child
- * selectItem Elements, or (optionally) a sample model if no suitable
- * child Elements are found.
- *
- * @param parentElement Parent Element instance to scan for child selectItem
- * Elements.
- * @param fallbackOnSampleModel If true and no suitable child Elements are
- * found, return sample model.
- * @return List of SelectItem instances (may be empty, but not null).
- */
- public static final List<SelectItem> getModel(
- Element parentElement, boolean fallbackOnSampleModel) {
- List<SelectItem> selectItems = new ArrayList<SelectItem>();
- if (parentElement != null) {
- NodeList childNodes = parentElement.getChildNodes();
- for (int i = 0; i < childNodes.getLength(); i++) {
- if (childNodes.item(i) instanceof Element) {
- Element childElement = (Element)childNodes.item(i);
- TagIdentifier tagID =
- TagIdentifierFactory.createDocumentTagWrapper(childElement);
- if (tagID.isSameTagType(ITrinidadConstants.TAG_IDENTIFIER_SELECTITEM)) {
- String label = childElement.getAttribute("label"); //$NON-NLS-1$
- if (label == null || label.length() < 1) {
- label = childElement.getAttribute("value"); //$NON-NLS-1$
- }
- selectItems.add(new SelectItem(
- label, childElement.getAttribute("value"))); //$NON-NLS-1$
- } else if (tagID.isSameTagType(IJSFConstants.TAG_IDENTIFIER_SELECTITEM)) {
- String value = childElement.getAttribute("value"); //$NON-NLS-1$
- if (value == null || value.length() < 1) {
- value = childElement.getAttribute("itemValue"); //$NON-NLS-1$
- }
- String label = childElement.getAttribute("itemLabel"); //$NON-NLS-1$
- if (label == null || label.length() < 1) {
- label = value;
- }
- selectItems.add(new SelectItem(label, value));
- }
- }
- }
- }
- if (selectItems.size() > 0 || !fallbackOnSampleModel) {
- return selectItems;
- } else {
- return getSampleModel();
- }
- }
-
- /**
- * Gets a sample model as a List of SelectItem instances.
- *
- * @return Sample model as a List of SelectItem instances.
- */
- public static final List<SelectItem> getSampleModel() {
- return SAMPLE_MODEL;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.classpath b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.classpath
deleted file mode 100644
index ce7393340..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.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/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.cvsignore
deleted file mode 100644
index a179f165b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-@dot
-build.xml
-javaCompiler...args
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.project b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.project
deleted file mode 100644
index 4fe172b47..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.common.runtime</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/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index a9a7aa76e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,82 +0,0 @@
-#Mon Jun 30 15:54:56 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled
-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.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=warning
-org.eclipse.jdt.core.compiler.problem.autoboxing=warning
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=ignore
-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=warning
-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=warning
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-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=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
-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=ignore
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=error
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-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=error
-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/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 997a93007..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 11:44:25 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/META-INF/MANIFEST.MF
deleted file mode 100644
index b96fe12da..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,22 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name.0
-Bundle-SymbolicName: org.eclipse.jst.jsf.common.runtime
-Bundle-Version: 1.0.101.qualifier
-Bundle-Activator: org.eclipse.jst.jsf.common.runtime.internal.JSFCommonRuntimePlugin
-Require-Bundle: org.eclipse.core.runtime
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: J2SE-1.4
-Export-Package: org.eclipse.jst.jsf.common.runtime.internal;x-internal:=true,
- org.eclipse.jst.jsf.common.runtime.internal.debug;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.bean;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.component;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.datatypes;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.decorator;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.event;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.model.types;x-friends:="org.eclipse.jst.jsf.common.runtime.tests",
- org.eclipse.jst.jsf.common.runtime.internal.view.model.common;x-friends:="org.eclipse.jst.jsf.common.runtime.tests"
-Bundle-Vendor: %Bundle-Vendor.0
-Bundle-Localization: plugin
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/about.html b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/about.html
deleted file mode 100644
index 8e5605900..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/build.properties b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/build.properties
deleted file mode 100644
index ce7a0fa8d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/build.properties
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.properties,\
- about.html
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/WebContent/WEB-INF/faces-config.xml b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/WebContent/WEB-INF/faces-config.xml
deleted file mode 100644
index 15eef3bf0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/WebContent/WEB-INF/faces-config.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!DOCTYPE faces-config PUBLIC
- "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
- "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
-
-<faces-config>
- <lifecycle>
- <phase-listener>
- instrument.PhaseListener1</phase-listener>
- </lifecycle>
-</faces-config>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/jar/jsfrt.jar b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/jar/jsfrt.jar
deleted file mode 100644
index 50936737b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/jar/jsfrt.jar
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/MyMonitorMessageFactory.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/MyMonitorMessageFactory.java
deleted file mode 100644
index 3f06d6d5b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/MyMonitorMessageFactory.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package instrument;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ObjectInputStream;
-import java.util.Iterator;
-
-import javax.faces.component.UIComponent;
-import javax.faces.component.UIInput;
-import javax.faces.component.UIOutput;
-
-import org.eclipse.jst.jsf.common.runtime.internal.debug.JSFMonitorMessage;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.FacetInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.UIInputInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.UIOutputInfo;
-
-public class MyMonitorMessageFactory
-{
- public static JSFMonitorMessage createJSFMonitorMessage(InputStream inStream) throws IOException, ClassCastException, ClassNotFoundException
- {
- ObjectInputStream objectStream = new ObjectInputStream(inStream);
- Object nextObject = objectStream.readObject();
- return (JSFMonitorMessage) nextObject;
- }
-
- static ComponentInfo buildComponentTree(UIComponent component, boolean isFacet)
- {
- final ComponentInfo componentInfo = getComponentData(component, isFacet);
-
- for (Iterator it = component.getChildren().iterator(); it.hasNext();)
- {
- UIComponent child = (UIComponent) it.next();
- componentInfo.getChildren().add(buildComponentTree(child, false));
- }
-
- for (Iterator it = component.getFacets().values().iterator(); it.hasNext();)
- {
- UIComponent facet = (UIComponent) it.next();
- componentInfo.getChildren().add(buildComponentTree(facet, true));
- }
-
- return componentInfo;
- }
-
- private static ComponentInfo getComponentData(final UIComponent component, boolean isFacet)
- {
- if (isFacet)
- {
- return calculateFacetInfo(component);
- }
- else if (component instanceof UIInput)
- {
- return calculateUIInput((UIInput)component);
- }
- else if (component instanceof UIOutput)
- {
- return calculateUIOutput((UIOutput)component);
- }
-
- // default; just make a component
- return calculateComponentInfo(component);
- }
-
- private static ComponentInfo calculateComponentInfo(UIComponent component)
- {
- final String id = component.getId();
- final String parentId = component.getParent() == null ? null : component.getParent().getId();
- final String componentFamily = component.getFamily();
- final String renderFamily = component.getRendererType();
- final String componentType = null;
- final String componentClass = component.getClass().getCanonicalName();
-
- return ComponentFactory.createComponentInfo
- (id, parentId, componentFamily, renderFamily, componentType, componentClass);
- }
-
- private static FacetInfo calculateFacetInfo(UIComponent component)
- {
- final String id = component.getId();
- final String parentId = component.getParent() == null ? null : component.getParent().getId();
- final String componentFamily = component.getFamily();
- final String renderFamily = component.getRendererType();
- final String componentType = null;
- final String componentClass = component.getClass().getCanonicalName();
-
- return ComponentFactory.createFacetInfo
- (id, parentId, componentFamily, renderFamily, componentType, componentClass);
- }
-
- private static UIInputInfo calculateUIInput(UIInput uiInput)
- {
- final String id = uiInput.getId();
- final String parentId = uiInput.getParent() == null ? null : uiInput.getParent().getId();
- final String componentFamily = uiInput.getFamily();
- final String renderFamily = uiInput.getRendererType();
- final String componentType = null;
- final String componentClass = uiInput.getClass().getCanonicalName();
- final String isValid = Boolean.toString(uiInput.isValid());
- final String isImmediate = Boolean.toString(uiInput.isImmediate());
- final String isRequired = Boolean.toString(uiInput.isRequired());
- final String isRendered = Boolean.toString(uiInput.isRendered());
-
- return ComponentFactory.createUIInputInfo
- (id, parentId, componentFamily, renderFamily, isValid, isImmediate, isRequired, isRendered, componentType, componentClass);
- }
-
- private static UIOutputInfo calculateUIOutput(UIOutput uiOutput)
- {
- final String id = uiOutput.getId();
- final String parentId = uiOutput.getParent() == null ? null : uiOutput.getParent().getId();
- final String componentFamily = uiOutput.getFamily();
- final String renderFamily = uiOutput.getRendererType();
- final String componentType = null;
- final String componentClass = uiOutput.getClass().getCanonicalName();
- final String isRendered = Boolean.toString(uiOutput.isRendered());
-
- return ComponentFactory.createUIOutputInfo
- (id, parentId, componentFamily, renderFamily, isRendered, componentType, componentClass);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/PhaseListener1.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/PhaseListener1.java
deleted file mode 100644
index e93e02858..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/instrumentation/src/instrument/PhaseListener1.java
+++ /dev/null
@@ -1,342 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package instrument;
-
-import java.io.IOException;
-import java.io.ObjectOutputStream;
-import java.io.Writer;
-import java.net.Socket;
-import java.net.UnknownHostException;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Stack;
-import java.util.concurrent.LinkedBlockingQueue;
-
-import javax.faces.FactoryFinder;
-import javax.faces.component.UIComponent;
-import javax.faces.component.UIViewRoot;
-import javax.faces.context.FacesContext;
-import javax.faces.context.ResponseWriter;
-import javax.faces.event.PhaseEvent;
-import javax.faces.event.PhaseId;
-import javax.faces.event.PhaseListener;
-import javax.faces.render.RenderKit;
-import javax.faces.render.RenderKitFactory;
-import javax.servlet.ServletRequest;
-import javax.servlet.ServletResponse;
-
-import org.eclipse.jst.jsf.common.runtime.internal.debug.ComponentTreeMessage;
-import org.eclipse.jst.jsf.common.runtime.internal.debug.JSFMonitorMessage;
-import org.eclipse.jst.jsf.common.runtime.internal.debug.MonitorMessageFactory;
-import org.eclipse.jst.jsf.common.runtime.internal.debug.RenderAttribute;
-import org.eclipse.jst.jsf.common.runtime.internal.debug.RenderNode;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * @author cbateman
- *
- */
-public class PhaseListener1 implements PhaseListener
-{
- SocketClient _socketClient;
- ResponseWriter _savedRW;
- LoggingResponseWriter _injectRW;
-
- /**
- *
- */
- private static final long serialVersionUID = 6564874625827591775L;
-
- public PhaseListener1()
- {
- System.out.println("Initialized PhaseListener: "+this);
- _socketClient = new SocketClient(3702);
- Thread thread = new Thread(_socketClient);
- thread.start();
-
- }
-
- public void afterPhase(PhaseEvent event) {
- if(PhaseId.RENDER_RESPONSE.equals(event.getPhaseId()))
- {
- System.out.printf("afterPhase: %s, for view id: %s\n",event.getPhaseId(),event.getFacesContext().getViewRoot().getViewId());
- dumpComponentTree(event.getFacesContext());
-
- if (_savedRW != null)
- {
- event.getFacesContext().setResponseWriter(_savedRW);
- }
-
- if (_injectRW != null)
- {
- dumpNode(_injectRW._rootComponentNode, "");
- }
- }
- }
-
- private void dumpNode(RenderNode node, String prefix)
- {
- System.out.printf("%s%s for component %s\n", prefix, node.getRenderedNodeName(), node.getComponentId());
-
- for (final Iterator it = node.getChildren().iterator();it.hasNext();)
- {
- RenderNode child = (RenderNode) it.next();
- dumpNode(child, prefix+"\t");
- }
- }
-
- public void beforePhase(PhaseEvent event) {
- if (PhaseId.RENDER_RESPONSE.equals(event.getPhaseId()))
- {
- FacesContext facesContext = event.getFacesContext();
- RenderKitFactory renderFactory =
- (RenderKitFactory)FactoryFinder.getFactory(FactoryFinder.RENDER_KIT_FACTORY);
- RenderKit renderKit = renderFactory.getRenderKit(facesContext,
- facesContext.getViewRoot().getRenderKitId());
-
- _savedRW = facesContext.getResponseWriter();
-
- try
- {
- Writer writer = ((ServletResponse) facesContext.getExternalContext().getResponse()).getWriter();
- String charEncoding = ((ServletRequest)facesContext.getExternalContext().getRequest()).getCharacterEncoding();
- ResponseWriter responseWriter = renderKit.createResponseWriter
- (writer,
- null /*Default: get the allowed content-types from the accept-header*/,
- charEncoding);
- _injectRW = new LoggingResponseWriter(responseWriter);
- facesContext.setResponseWriter(_injectRW);
- }
- catch (IOException ioe)
- {
- ioe.printStackTrace();
- }
- }
-// System.out.printf("beforePhase: %s, for view id: %s\n",event.getPhaseId(),event.getFacesContext().getViewRoot().getViewId());
-// dumpComponentTree(event.getFacesContext());
- }
-
- public PhaseId getPhaseId() {
- return PhaseId.ANY_PHASE;
- }
-
- private void dumpComponentTree(final FacesContext facesContext)
- {
- final UIViewRoot root = facesContext.getViewRoot();
-
- if (root != null)
- {
- final String viewId = root.getViewId();
- final ComponentInfo rootComponent = MyMonitorMessageFactory.buildComponentTree(root,false);
- ComponentTreeMessage message =
- MonitorMessageFactory.createTreeMessage(viewId, rootComponent, _injectRW._rootComponentNode);
- _socketClient.put(message);
- }
- }
-
-
- private static class SocketClient implements Runnable
- {
- private final int _port;
-
- private LinkedBlockingQueue<JSFMonitorMessage> _queue =
- new LinkedBlockingQueue<JSFMonitorMessage>();
-
- SocketClient(final int port)
- {
- _port = port;
- }
-
- public void run()
- {
- JSFMonitorMessage buffer = null;
-
- try
- {
- while ((buffer = _queue.take()) != null)
- {
- Socket socket = null;
-
- try
- {
- socket = new Socket("127.0.0.1", _port);
- ObjectOutputStream stream = new ObjectOutputStream(socket.getOutputStream());
- stream.writeObject(buffer);
-// PrintWriter writer = new PrintWriter(socket.getOutputStream(), true);
-// writer.println(buffer);
-// writer.flush();
- } catch (UnknownHostException e) {
- e.printStackTrace();
- } catch (IOException e) {
- e.printStackTrace();
- }
- finally
- {
- if (socket != null && !socket.isClosed())
- {
- try {
- socket.close();
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
- }
- }
- catch (InterruptedException e)
- {
- e.printStackTrace();
- }
- }
-
- public void put(JSFMonitorMessage message)
- {
- _queue.add(message);
- }
- }
-
- private static class LoggingResponseWriter extends ResponseWriter
- {
- private final ResponseWriter _wrapWriter;
- private final Stack/*<RenderNode>*/ _parentStack;
- private RenderNode _curNode;
- private RenderNode _rootComponentNode;
-
- // map component id to the root rendernode rendered for it
- private Map _componentToHtml;
-
- LoggingResponseWriter(ResponseWriter wrapWriter)
- {
- _wrapWriter = wrapWriter;
- _parentStack = new Stack();
-
- _componentToHtml = new HashMap/*<String,RenderNode>*/();
- }
-
- public ResponseWriter cloneWithWriter(Writer writer) {
- return _wrapWriter.cloneWithWriter(writer);
- }
-
- public void endDocument() throws IOException {
- _wrapWriter.endDocument();
- }
-
- public void endElement(String element) throws IOException {
- _curNode = (RenderNode) _parentStack.pop();
- _wrapWriter.endElement(element);
- }
-
- public void flush() throws IOException {
- _wrapWriter.flush();
- }
-
- public String getCharacterEncoding() {
- return _wrapWriter.getCharacterEncoding();
- }
-
- public String getContentType() {
- return _wrapWriter.getContentType();
- }
-
- public void startDocument() throws IOException {
- _rootComponentNode = new RenderNode(null, null);
- _wrapWriter.startDocument();
- }
-
- public void startElement(String elementName, UIComponent component)
- throws IOException
- {
- String componentId = null;
-
- if (component != null)
- {
- componentId = component.getId();
- }
-
- RenderNode oldNode = _curNode;
- // push the curNode. Pushing null indicates the root of the document
- _parentStack.push(oldNode);
-
- _curNode = new RenderNode(componentId, elementName);
-
- // note that assumption here is that the first html element
- // we see corresponding to a component is the root of its
- // html tree. This may not be true if a component renders
- // more than one root element or if the output is generated
- // any thing but pre-order (parent first) tranversal of the
- // component tree. TODO: this algorithm needs refining
- if (!_componentToHtml.containsKey(componentId))
- {
- _componentToHtml.put(componentId, _curNode);
- }
-
- // if the current node isn't null, then append this new element
- if (oldNode != null)
- {
- oldNode.getChildren().add(_curNode);
- }
- // otherwise, we are at the doc root, so append there instead
- else
- {
- _rootComponentNode.getChildren().add(_curNode);
- }
-
-
- // do the normal write
- _wrapWriter.startElement(elementName, component);
- }
-
- public void writeAttribute(String name, Object value, String componentPropertyName)
- throws IOException {
-
- System.out.printf("%s: [%s,%s]\n", name, value.toString(), componentPropertyName);
- final RenderAttribute attribute =
- new RenderAttribute(name, value.toString(), componentPropertyName);
-
- if (_curNode != null)
- {
- _curNode.getRenderedAttributes().add(attribute);
- }
- _wrapWriter.writeAttribute(name, value, componentPropertyName);
- }
-
- public void writeComment(Object obj) throws IOException {
- _wrapWriter.writeComment(obj);
- }
-
- public void writeText(Object arg0, String arg1) throws IOException {
- _wrapWriter.writeText(arg0, arg1);
- }
-
- public void writeText(char[] arg0, int arg1, int arg2)
- throws IOException {
- _wrapWriter.writeText(arg0, arg1, arg2);
- }
-
- public void writeURIAttribute(String arg0, Object arg1, String arg2)
- throws IOException {
- _wrapWriter.writeURIAttribute(arg0, arg1, arg2);
- }
-
- public void close() throws IOException {
- _wrapWriter.close();
- }
-
- public void write(char[] cbuf, int off, int len) throws IOException {
- _wrapWriter.write(cbuf, off, len);
- }
-
- public ResponseWriter getWrapWriter() {
- return _wrapWriter;
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/plugin.properties
deleted file mode 100644
index 2279dd94d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/plugin.properties
+++ /dev/null
@@ -1,11 +0,0 @@
-###############################################################################
-# Copyright (c) 2008 Oracle Corporation.
-# 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
-#
-###############################################################################
-#Properties file for org.eclipse.jst.jsf.common.runtime
-Bundle-Vendor.0 = Eclipse.org
-Bundle-Name.0 = JavaServer Faces Tools - Common Runtime \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/JSFCommonRuntimePlugin.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/JSFCommonRuntimePlugin.java
deleted file mode 100644
index 6f9d5f14c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/JSFCommonRuntimePlugin.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal;
-
-import org.eclipse.core.runtime.ILog;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.core.runtime.Status;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class JSFCommonRuntimePlugin extends Plugin {
-
- /**
- * The plug-in ID
- */
- public static final String PLUGIN_ID = "CommonComponentPlugin"; //$NON-NLS-1$
-
- // The shared instance
- private static JSFCommonRuntimePlugin plugin;
-
- /**
- * The constructor
- */
- public JSFCommonRuntimePlugin() {
- // empty constructor
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- */
- public void start(final 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(final BundleContext context) throws Exception {
- plugin = null;
- super.stop(context);
- }
-
- /**
- * Returns the shared instance
- *
- * @return the shared instance
- */
- public static JSFCommonRuntimePlugin getDefault() {
- return plugin;
- }
-
- /**
- * @param message
- * @param t
- */
- public static void log(final String message, final Throwable t)
- {
- final ILog log = getDefault().getLog();
- final IStatus status = new Status(IStatus.ERROR, PLUGIN_ID, message, t);
- log.log(status);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/ComponentTreeMessage.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/ComponentTreeMessage.java
deleted file mode 100644
index f6687f461..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/ComponentTreeMessage.java
+++ /dev/null
@@ -1,246 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.debug;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-
-/**
- * Represents a component tree in message for that can be serialized.
- *
- * @author cbateman
- *
- */
-public class ComponentTreeMessage extends JSFMonitorMessage
-{
- /**
- *
- */
- private static final long serialVersionUID = -6282344329821994209L;
- private String _viewId;
- private ComponentInfo _treeRoot;
- private RenderNode _renderRoot;
- // private HashMap<String, ComponentInfo> _idIndex;
-
- /**
- * default constructor
- */
- public ComponentTreeMessage()
- {
- //_idIndex = new HashMap<String, ComponentInfo>();
- }
-
- /**
- * @return the view id
- */
- public final String getViewId() {
- return _viewId;
- }
-
- /**
- * @return the componentinfo at the root of the component tree
- */
- public final ComponentInfo getTreeRoot() {
- return _treeRoot;
- }
-
- /**
- * @return the rendered root node
- */
- public final RenderNode getRenderRoot() {
- return _renderRoot;
- }
-
- final void setRenderRoot(RenderNode renderRoot) {
- _renderRoot = renderRoot;
- }
-
- final void setTreeRoot(ComponentInfo treeRoot)
- {
- _treeRoot = treeRoot;
- }
-
- final void setViewId(final String viewId)
- {
- _viewId = viewId;
- }
-
-// @Override
-// protected void deserialize(InputStream inStream) throws IOException, ClassNotFoundException
-// {
-// ObjectInputStream objectInputStream = new ObjectInputStream(inStream);
-//
-// Object obj = objectInputStream.readObject();
-// int bytesRead = super.deserialize(inStream);
-//
-// // first line must be startView
-// final BufferedReader reader =
-// new BufferedReader(new InputStreamReader(inStream));
-//
-// String line = reader.readLine();
-//
-// if (line != null
-// && line.startsWith(START_VIEW))
-// {
-// _viewId = line.substring(START_VIEW.length()).trim();
-// bytesRead += line.length()+1;
-// }
-//
-// // loop until EOF
-// while ((line = reader.readLine())!=null)
-// {
-// bytesRead += line.length()+1;
-//
-// if (line.startsWith("component:"))
-// {
-// parseComponent(line.substring("component:".length()).trim());
-// }
-// else if (line.startsWith("facet:"))
-// {
-// parseFacet(line.substring("facet:".length()).trim());
-// }
-// else if (line.startsWith("uiInput:"))
-// {
-// parseUIInput(line.substring("uiInput:".length()).trim());
-// }
-// else if (line.startsWith("uiOutput:"))
-// {
-// parseUIOutput(line.substring("uiOutput:".length()).trim());
-// }
-// else if (line.startsWith("endView"))
-// {
-// //
-// }
-// }
-// return bytesRead;
-// }
-
-// private ComponentInfo parseComponent(final String line)
-// {
-// final String[] fields = line.split(",");
-// if (fields.length >= 4)
-// {
-// String parentId = "!".equals(fields[0]) ? null : fields[0];
-// String id = "!".equals(fields[1]) ? null : fields[1];
-// String componentFamily = fields[2];
-// String renderFamily = fields[3];
-//
-// ComponentInfo componentInfo =
-// ComponentFactory.createComponentInfo
-// (id, parentId, componentFamily, renderFamily);
-//
-// if (id == null)
-// {
-// _treeRoot = componentInfo;
-// _idIndex.put(null, componentInfo);
-// }
-// else
-// {
-// _idIndex.put(id, componentInfo);
-//
-// ComponentInfo parent =
-// (ComponentInfo)_idIndex.get(parentId);
-//
-// if (parent != null)
-// {
-// parent.getChildren().add(componentInfo);
-// }
-// else
-// {
-// _treeRoot.getChildren().add(componentInfo);
-// }
-// }
-// }
-// return null;
-// }
-//
-// private FacetInfo parseFacet(final String line)
-// {
-// final String[] fields = line.split(",");
-//
-// if (fields.length >= 4)
-// {
-// String parentId = "!".equals(fields[0]) ? null : fields[0];
-// String id = "!".equals(fields[1]) ? null : fields[1];
-// String componentFamily = fields[2];
-// String renderFamily = fields[3];
-//
-// FacetInfo facetInfo =
-// ComponentFactory.createFacetInfo(id, parentId, componentFamily, renderFamily);
-// ComponentInfo parent = _idIndex.get(parentId);
-//
-// if (parent != null)
-// {
-// parent.getChildren().add(facetInfo);
-// }
-//
-// return facetInfo;
-// }
-// return null;
-// }
-//
-// private UIInputInfo parseUIInput(final String line)
-// {
-// final String[] fields = line.split(",");
-//
-// if (fields.length >= 7)
-// {
-// String parentId = "!".equals(fields[0]) ? null : fields[0];
-// String id = "!".equals(fields[1]) ? null : fields[1];
-// String componentFamily = fields[2];
-// String renderFamily = fields[3];
-// String isValid = fields[4];
-// String isImmediate = fields[5];
-// String isRequired = fields[6];
-// String isRendered = fields[7];
-//
-// UIInputInfo uiInputInfo =
-// ComponentFactory.createUIInputInfo
-// (id, parentId, componentFamily, renderFamily, isValid, isImmediate, isRequired, isRendered);
-// ComponentInfo parent = _idIndex.get(parentId);
-//
-// if (parent != null)
-// {
-// parent.getChildren().add(uiInputInfo);
-// }
-//
-// return uiInputInfo;
-// }
-// return null;
-// }
-//
-// private UIOutputInfo parseUIOutput(final String line)
-// {
-// final String[] fields = line.split(",");
-//
-// if (fields.length >= 4)
-// {
-// String parentId = "!".equals(fields[0]) ? null : fields[0];
-// String id = "!".equals(fields[1]) ? null : fields[1];
-// String componentFamily = fields[2];
-// String renderFamily = fields[3];
-// String isRendered = fields[4];
-//
-// UIOutputInfo uiOutputInfo =
-// ComponentFactory.createUIOutputInfo(id, parentId, componentFamily, renderFamily, isRendered);
-//
-// ComponentInfo parent = _idIndex.get(parentId);
-//
-// if (parent != null)
-// {
-// parent.getChildren().add(uiOutputInfo);
-// }
-//
-// return uiOutputInfo;
-// }
-// return null;
-// }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/JSFMonitorMessage.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/JSFMonitorMessage.java
deleted file mode 100644
index 4b2be53fb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/JSFMonitorMessage.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.debug;
-
-import java.io.Serializable;
-
-/**
- * Super of all messages that are sent by the JSF debug monitor
- * @author cbateman
- *
- */
-public abstract class JSFMonitorMessage implements Serializable
-{
- /**
- *
- */
- private static final long serialVersionUID = -5417558019077000040L;
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/MonitorMessageFactory.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/MonitorMessageFactory.java
deleted file mode 100644
index eb5767780..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/MonitorMessageFactory.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.debug;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * Creates JSF remote monitor messages.
- *
- * @author cbateman
- *
- */
-public class MonitorMessageFactory
-{
- /**
- * @param viewId
- * @param root
- * @param renderRoot
- * @return a new component tree message for the parameters
- */
- public static ComponentTreeMessage createTreeMessage(final String viewId, final ComponentInfo root, final RenderNode renderRoot)
- {
- ComponentTreeMessage message = new ComponentTreeMessage();
- message.setViewId(viewId);
- message.setTreeRoot(root);
- message.setRenderRoot(renderRoot);
- return message;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderAttribute.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderAttribute.java
deleted file mode 100644
index e0c1b9176..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderAttribute.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.debug;
-
-/**
- * Information about a rendered XML attribute
- *
- * @author cbateman
- *
- */
-public class RenderAttribute extends JSFMonitorMessage {
-
- /**
- *
- */
- private static final long serialVersionUID = -4601065346261130623L;
-
- private final String _name; // the name of the attribute. TODO: local vs. namespace?
- private final String _value; // the rendered value of the node
- private final String _propertyName; // the property name on the corresponding component
- // may be null
- /**
- * @param name
- * @param value
- * @param propertyName
- */
- public RenderAttribute(String name, String value, String propertyName) {
- super();
- _name = name;
- _propertyName = propertyName;
- _value = value;
- }
- /**
- * @return the name of the attribute
- */
- public final String getName() {
- return _name;
- }
- /**
- * @return the attribute's value
- */
- public final String getValue() {
- return _value;
- }
- /**
- * @return the name of the corresponding component property if any.
- */
- public final String getPropertyName() {
- return _propertyName;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderNode.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderNode.java
deleted file mode 100644
index 2679c622b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/debug/RenderNode.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.debug;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * A rendered XML node.
- *
- * @author cbateman
- *
- */
-public class RenderNode extends JSFMonitorMessage
-{
- /**
- *
- */
- private static final long serialVersionUID = -2843929405836710015L;
-
- private final String _componentId; // the id of the component id that caused the node to render
- private final String _renderedNodeName; // the node
- private final List/*<RenderedAttribute>*/ _renderedAttributes; // attributes
- private final List _children; // the rendered children of renderedNode based
- // on the output document hiearchy
- /**
- * @param componentId
- * @param renderedNodeName
- */
- public RenderNode(String componentId, String renderedNodeName) {
- super();
- _componentId = componentId;
- _renderedNodeName = renderedNodeName;
-
- _children = new ArrayList();
- _renderedAttributes = new ArrayList();
- }
- /**
- * @return the corresponding component's id
- */
- public final String getComponentId() {
- return _componentId;
- }
- /**
- * @return the node's children
- */
- public final List getChildren() {
- return _children;
- }
- /**
- * @return the name of the rendered node (element)
- */
- public final String getRenderedNodeName() {
- return _renderedNodeName;
- }
- /**
- * @return the attributes of this node as rendered.
- */
- public final List getRenderedAttributes() {
- return _renderedAttributes;
- }
- public String toString()
- {
- String toString = "Root node: "+_renderedNodeName+", attributes: ["; //$NON-NLS-1$ //$NON-NLS-2$
-
- for (Iterator it = _renderedAttributes.iterator(); it.hasNext();)
- {
- final RenderAttribute attribute = (RenderAttribute) it.next();
- toString+=attribute.getName() + "=" + attribute.getValue(); //$NON-NLS-1$
-
- toString+=it.hasNext() ? ", " : "]"; //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- return toString;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/IDesigntimeAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/IDesigntimeAdapter.java
deleted file mode 100644
index bd427e6a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/IDesigntimeAdapter.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model;
-
-/**
- * Implemented by design time adapters that represent runtime interfaces.
- *
- * @author cbateman
- *
- */
-public interface IDesigntimeAdapter
-{
- /**
- * @return the list of runtime interfaces that this runtime adapter
- * represents.
- */
- String[] getInterfaces();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/ViewObject.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/ViewObject.java
deleted file mode 100644
index 9c36f726c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/ViewObject.java
+++ /dev/null
@@ -1,542 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.Decorator;
-
-/**
- * The base type of all objects that participate in the lifecycle of a view.
- * This may be used to hold either design time or runtime information.
- *
- * @author cbateman
- *
- */
-public abstract class ViewObject implements Serializable /* IAdaptable? */
-{
- private final ViewObjectData _data;
-
- /**
- *
- */
- private static final long serialVersionUID = 1592205691642453075L;
-
- /**
- *
- */
- protected ViewObject()
- {
- this(new ViewObjectData(false));
- }
-
- /**
- * @param delegate
- */
- protected ViewObject(final ViewObjectData delegate)
- {
- _data = delegate;
- _data.setOwner(this);
- }
-
- /**
- * @return the object containing all this view object's data
- */
- protected ViewObjectData getData()
- {
- return _data;
- }
-
- /**
- * IMPORTANT: if this method returns false, then calling a mutator method
- * (basically anything that is not a get/isX() will throw any
- * IllegalStateException).
- *
- * @return if the object can still be modified.
- */
- public final boolean isModifiable()
- {
- return !getData().isProtected();
- }
-
- /**
- * Calling this method sets the state to not modifiable
- */
- public final void setProtected()
- {
- getData().setLocked();
- }
-
- /**
- * This call may be create a new data structure and should be considered of
- * much higher cost than most calls.
- *
- * @return all decorators of this object. List should be assumed by clients
- * to be unmodifiable and may throw mutation exceptions
- */
- public List getAllDecorators()
- {
- final int size = getDecoratorMap().size();
-
- if (size == 0)
- {
- return Collections.EMPTY_LIST;
- }
-
- final List allDecorators = new ArrayList();
- for (final Iterator entryIt = getDecoratorMap().entrySet().iterator(); entryIt
- .hasNext();)
- {
- final Map.Entry entry = (Map.Entry) entryIt.next();
- final List decorators = (List) entry.getValue();
- allDecorators.addAll(decorators);
- }
-
- return Collections.unmodifiableList(allDecorators);
- }
-
- /**
- * @param decoratorType
- * @return all decorators of this object associated with the class type. The
- * returned list should be assumed to be unmodifiable. Returns an
- * empty list if no decorators are associated with decoratorType
- */
- public List getDecorators(final Class decoratorType)
- {
- final List decorators = (List) getDecoratorMap().get(decoratorType);
-
- if (decorators == null)
- {
- return Collections.EMPTY_LIST;
- }
- return Collections.unmodifiableList(decorators);
- }
-
- /**
- * Add the decorator using decorator.getClass to associate the type. Must be
- * equivalent to addDecorator(decorator, decorator.getClass());
- *
- * @param decorator
- * the decorator to add. <b>Must NOT be null.</b>
- * @throws IllegalArgumentException
- * if decorator is null.
- */
- public void addDecorator(final Decorator decorator)
- {
- _data.addDecorator(decorator);
- }
-
- /**
- * Add the decorator using the associatedType. Normally you should call
- * {@link #addDecorator(Decorator)} however in some cases you may wish to
- * associated a decorator with a class type other than its own. For example,
- * sub-classes of ValidatorDecorator will want to associated with
- * ValidatorDecorator.getClass() in most cases so that it is included in any
- * common examination of component validators.
- *
- * @param decorator
- * to add. <b>Must NOT be null.</b>
- * @param associatedType
- * the key to store decorator <b>Must NOT be null</b>
- * @throws IllegalArgumentException
- * if decorator or associatedType is null
- */
- public void addDecorator(final Decorator decorator,
- final Class associatedType)
- {
- _data.addDecorator(decorator, associatedType);
- }
-
- /**
- * Removes decorator if it is associated to associatedType on this view
- * object.
- *
- * @param decorator
- * @param associatedType
- * @return true if the decorator was found and removed.
- * @throws IllegalArgumentException
- * if decorator or associatedType is null
- */
- public boolean removeDecorator(final Decorator decorator,
- final Class associatedType)
- {
- return _data.removeDecorator(decorator, associatedType);
- }
-
- /**
- * <p>
- * Get the adapter associated the class key.
- * </p>
- *
- * <p>
- * If addAdapter has been called with adapterType, then this adapter object
- * should always be called. In the default implementation, if there is no
- * explicit adapter, "this" is returned if (this instanceof adapterType).
- *
- * @param adapterType
- * @return the interface adapter associated with the class key or null if
- * not found
- */
- public Object getAdapter(final Class adapterType)
- {
- if (adapterType == null)
- {
- return null;
- }
-
- Object adapter = getAdapterMap().get(adapterType);
-
- if (adapter == null)
- {
- if (adapterType.isInstance(this))
- {
- adapter = this;
- }
- }
-
- return adapter;
- }
-
- /**
- * Adds the interface adapter object under adapterType key. There can be at
- * most one adapter registered for each class key.
- *
- * It is an error (throws exception) to try to add an adapter for
- * adapterType which this is already instance. This restriction is necessary
- * because otherwise local getters/setters would need to be aware of the
- * adapter mechanism and verify inheritance hierarchies on every calls. This
- * mechanism is intended only for adding interfaces to view object impls
- * that don't already have them.
- *
- * @param adapterType
- * @param adapter
- * @throws IllegalArgumentException
- * if adapterType or adapter is null or if casting adapter to
- * adapterType would * cause a ClassCastException (i.e. if
- * !(adapter instanceof adapterType)) OR if this is already an
- * instance of adapterType.
- */
- public void addAdapter(final Class adapterType, final Object adapter)
- {
- _data.addAdapter(adapterType, adapter);
- }
-
- /**
- * Note that {@link #getAdapter(Class)} may still return non-null after this
- * is called if (this instanceof adapterType).
- *
- * @param adapterType
- * @return the adapter for adapterType that was just removed or null if not
- * found
- */
- public Object removeAdapter(final Class adapterType)
- {
- return getAdapterMap().remove(adapterType);
- }
-
- /**
- * Note that this only returns those adapters added using
- * {@link #addAdapter(Class, Object)}. It does not return any implicit
- * adapters resulting from (this instanceof type).
- *
- * @return the map of all adapters. Maps is immutable and may throw
- * exceptions on attempts to mutate.
- */
- public Map getAllAdapters()
- {
- if (getAdapterMap().size() == 0)
- {
- return Collections.EMPTY_MAP;
- }
- return Collections.unmodifiableMap(getAdapterMap());
- }
-
- /**
- * <p>
- * The contract for this method is that it must always return a usable Map
- * and that map must be the same on every call. Lazy construction may be
- * used (as it is by default). The default map size is 4 and load factor is
- * 3 meaning that there should be decent tradeoff between wasted table size
- * and overhead used to increase it should the number of decorators exceed
- * 3. <b>Must never return null.</b>
- * </p>
- *
- * <p>
- * Generally, the method should not need to be overridden, however it is
- * provided to allow sub-classes to change the way the decorators map is
- * constructed.
- * </p>
- *
- * @return the map containing lists of decorators keyed by class.
- *
- */
- protected Map getDecoratorMap()
- {
- return _data.getDecoratorMap();
- }
-
- /**
- * <p>
- * The contract for this method is that it must always return a usable Map
- * and that map must be the same on every call. Lazy construction may be
- * used (as it is by default). The default map size is 4 and load factor is
- * 3 meaning that there should be decent tradeoff between wasted table size
- * and overhead used to increase it should the number of decorators exceed
- * 3. <b>Must never return null.</b>
- * </p>
- *
- * <p>
- * Generally, the method should not need to be overridden, however it is
- * provided to allow sub-classes to change the way the decorators map is
- * constructed.
- * </p>
- *
- * @return the map containing lists of adapters keyed by class.
- *
- */
- protected Map getAdapterMap()
- {
- return _data.getAdapterMap();
- }
-
- // ALL ViewObject's must use reference equals
- public final boolean equals(final Object obj)
- {
- return super.equals(obj);
- }
-
- public final int hashCode()
- {
- return super.hashCode();
- }
-
- /**
- * The protectable view object data.
- *
- */
- public static class ViewObjectData extends ProtectedDataObject
- {
- /**
- *
- */
- private static final long serialVersionUID = -4216980607447926035L;
- private Map _decorators;
- private Map _adapters;
- private Object _owner;
-
- /**
- * @param isProtected
- */
- public ViewObjectData(final boolean isProtected)
- {
- super(isProtected);
- }
-
- private void setOwner(final ViewObject viewObject)
- {
- _owner = viewObject;
- }
-
- /**
- * For serialization only.
- */
- // public ViewObjectData()
- // {
- // // for serializability
- // super(false);
- // }
-
- /**
- * @param decorator
- * @param associatedType
- * @return true if the decorator was removed.
- */
- public boolean removeDecorator(final Decorator decorator, final Class associatedType)
- {
- enforceProtection();
-
- if (decorator == null || associatedType == null)
- {
- throw new IllegalArgumentException("Arguments must not be null"); //$NON-NLS-1$
- }
-
- final List decoratorsByType = (List) getDecoratorMap().get(
- associatedType);
-
- if (decoratorsByType != null)
- {
- return decoratorsByType.remove(decorator);
- }
-
- return false;
- }
-
- /**
- * @param adapterType
- * @param adapter
- */
- public void addAdapter(final Class adapterType, final Object adapter)
- {
- enforceProtection();
-
- if (adapterType == null || adapter == null)
- {
- throw new IllegalArgumentException("Arguments must not be null"); //$NON-NLS-1$
- }
-
- if (!adapterType.isInstance(adapter))
- {
- throw new IllegalArgumentException("adapter: " + adapter //$NON-NLS-1$
- + " must be cast compatible to class: " + adapterType); //$NON-NLS-1$
- }
- else if (adapterType.isInstance(_owner))
- {
- throw new IllegalArgumentException("this: " + _owner //$NON-NLS-1$
- + " must not already be an instance of class: " //$NON-NLS-1$
- + adapterType);
- }
- getAdapterMap().put(adapterType, adapter);
- }
-
- /**
- * @param decorator
- */
- public void addDecorator(final Decorator decorator)
- {
- enforceProtection();
-
- if (decorator == null)
- {
- throw new IllegalArgumentException("Arguments must not be null"); //$NON-NLS-1$
- }
- final Class associationType = decorator.getClass();
- addDecorator(decorator, associationType);
- }
-
- /**
- * @param decorator
- * @param associatedType
- */
- public void addDecorator(final Decorator decorator, final Class associatedType)
- {
- enforceProtection();
-
- if (decorator == null || associatedType == null)
- {
- throw new IllegalArgumentException("Arguments must not be null"); //$NON-NLS-1$
- }
-
- List decoratorsByType = (List) getDecoratorMap().get(associatedType);
-
- if (decoratorsByType == null)
- {
- decoratorsByType = new ArrayList(2);
- getDecoratorMap().put(associatedType, decoratorsByType);
- }
-
- decoratorsByType.add(decorator);
- }
-
- /**
- * @return the decorator map, creating it if necessary
- */
- protected synchronized Map getDecoratorMap()
- {
- if (_decorators == null)
- {
- if (isProtected())
- {
- _decorators = Collections.EMPTY_MAP;
- }
- _decorators = new HashMap(4);
- }
- return _decorators;
- }
-
- /**
- * @return the adapter map, creating if necessary.
- */
- protected synchronized Map getAdapterMap()
- {
- if (_adapters == null)
- {
- _adapters = new HashMap(4);
- }
-
- return _adapters;
- }
- }
-
- /**
- * An object that enforces that mutation can only happen up to point where
- * the object is designated protected at which point is it is forever
- * immutable.
- *
- */
- public static abstract class ProtectedDataObject implements Serializable
- {
- /**
- *
- */
- private static final long serialVersionUID = 4470279408370430399L;
- private boolean _isProtected;
-
- /**
- * @param isProtected
- */
- public ProtectedDataObject(final boolean isProtected)
- {
- _isProtected = isProtected;
- }
-
- /**
- * @throws UnsupportedOperationException
- */
- protected final synchronized void enforceProtection() throws UnsupportedOperationException
- {
- if (isProtected())
- {
- throw new UnsupportedOperationException("Object "+this.toString()+ " is locked for modification"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-
- /**
- * @return true if this object is protected and irrevocablly immutable.
- */
- public final synchronized boolean isProtected()
- {
- return _isProtected;
- }
-
- /**
- * Executed right before setProtected irrevocably sets the protection
- * flag. Does nothing by default
- */
- protected void doBeforeProtecting()
- {
- // do nothing by default
- }
- /**
- * Makes this object irrevocably immutable.
- */
- public final synchronized void setLocked()
- {
- doBeforeProtecting();
- _isProtected = true;
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/DataModelInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/DataModelInfo.java
deleted file mode 100644
index e7c2e93c0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/DataModelInfo.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.bean;
-
-import java.io.Serializable;
-
-/**
- * Design time analog of runtime DataModel bean
- *
- * @author cbateman
- *
- */
-public class DataModelInfo implements Serializable
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 6461056497382677871L;
-
- private final boolean _rowAvailable;
- private final int _rowCount;
- private final SerializableObject _rowData;
- private final int _rowIndex;
- private final SerializableObject _wrappedData;
-
- /**
- * @param rowAvailable
- * @param rowCount
- * @param rowData
- * @param rowIndex
- * @param wrappedData
- */
- public DataModelInfo(boolean rowAvailable, int rowCount, Object rowData,
- int rowIndex, Object wrappedData) {
- super();
- _rowAvailable = rowAvailable;
- _rowCount = rowCount;
- _rowData = new SerializableObject(rowData);
- _rowIndex = rowIndex;
- _wrappedData = new SerializableObject(wrappedData);
- }
-
- /**
- * @return true if the current row is available
- */
- public final boolean isRowAvailable() {
- return _rowAvailable;
- }
- /**
- * @return the row count of this model
- */
- public final int getRowCount() {
- return _rowCount;
- }
- /**
- * @return the row data
- */
- public final Object getRowData() {
- return _rowData.getMaybeSerializable();
- }
- /**
- * @return the row index
- */
- public final int getRowIndex() {
- return _rowIndex;
- }
- /**
- * @return the wrapped data. may be null if wrapped object was not
- * serializable.
- */
- public final Object getWrappedData() {
- return _wrappedData.getMaybeSerializable();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/SerializableObject.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/SerializableObject.java
deleted file mode 100644
index e3b066a1f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/bean/SerializableObject.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.bean;
-
-import java.io.IOException;
-import java.io.NotSerializableException;
-import java.io.Serializable;
-
-/**
- * A special object used in place of Object to ensure that when an interface
- * requires a generic #{@link java.lang.Object}, it won't throw serialization
- * exception when a containing object is serialized.
- *
- * @author cbateman
- *
- */
-public class SerializableObject implements Serializable
-{
- /**
- *
- */
- private static final long serialVersionUID = 9133733048469500692L;
- private Object _maybeSerializable;
-
- /**
- * @param maybeSerializable
- */
- public SerializableObject(Object maybeSerializable)
- {
- _maybeSerializable = maybeSerializable;
- }
-
-
-// /**
-// * Provided to support serialization. Should not be used by sub-classes
-// * or clients except in this regard.
-// */
-// protected SerializableObject()
-// {
-// _maybeSerializable = null;
-// }
-
- /**
- * @return the actual value
- */
- public final Object getMaybeSerializable() {
- return _maybeSerializable;
- }
-
-
- private void writeObject(java.io.ObjectOutputStream out)
- throws IOException
- {
- try
- {
- out.writeObject(_maybeSerializable);
- }
- catch (NotSerializableException nse)
- {
- // do nothing, the object isn't guaranteed to be serializable,
- // but we don't want this be an error
- out.writeObject(null);
- }
- }
-
- private void readObject(java.io.ObjectInputStream in)
- throws IOException, ClassNotFoundException
- {
- _maybeSerializable = in.readObject();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo.java
deleted file mode 100644
index 6e7348d65..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ActionListenerDecorator;
-
-/**
- * Implementation of the ActionSourceInfo.
- *
- * @author cbateman
- *
- */
-public class ActionSourceInfo implements IActionSourceInfo, IDesigntimeAdapter
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 6531166406473466685L;
- private static final String[] INTERFACE = new String[]{ComponentFactory.INTERFACE_ACTIONSOURCE};
- private final String _action;
- private final String _actionListener;
- private final boolean _immediate;
- private List/*<ActionListenerDecorator>*/ _actionListeners;
-
- /**
- * @param action
- * @param actionListener
- * @param immediate
- */
- public ActionSourceInfo(final String action, final String actionListener,
- final boolean immediate)
- {
- super();
- _action = action;
- _actionListener = actionListener;
- _immediate = immediate;
- }
-
- public void addActionListener(final ActionListenerDecorator actionListener) {
- if (_actionListeners == null)
- {
- _actionListeners = new ArrayList(2);
- }
- _actionListeners.add(actionListener);
- }
-
- public String getAction() {
- return _action;
- }
-
- public String getActionListener() {
- return _actionListener;
- }
-
- public List getActionListeners() {
- if (_actionListeners == null)
- {
- return Collections.EMPTY_LIST;
- }
- return Collections.unmodifiableList(_actionListeners);
- }
-
- public boolean isImmediate() {
- return _immediate;
- }
-
- public String[] getInterfaces()
- {
- return INTERFACE;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo2.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo2.java
deleted file mode 100644
index d36b95b76..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ActionSourceInfo2.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-
-/**
- * Implementation of the IActionSource2Info
- *
- * @author cbateman
- *
- */
-public class ActionSourceInfo2 extends ActionSourceInfo implements
- IActionSource2Info, IDesigntimeAdapter
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 5811194815559772378L;
- private static final String[] INTERFACE = new String[]{ComponentFactory.INTERFACE_ACTIONSOURCE2};
-
- private final String _actionExpression;
-
- /**
- * @param action
- * @param actionListener
- * @param immediate
- * @param actionExpression
- */
- public ActionSourceInfo2(final String action, final String actionListener,
- final boolean immediate, final String actionExpression) {
- super(action, actionListener, immediate);
- _actionExpression = actionExpression;
- }
-
- public String getActionExpression() {
- return _actionExpression;
- }
-
- public String[] getInterfaces()
- {
- return INTERFACE;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/EditableValueHolderInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/EditableValueHolderInfo.java
deleted file mode 100644
index 8b07c45a5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/EditableValueHolderInfo.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValueChangeListenerDecorator;
-
-/**
- * Implementation of the IEditableValueHolderInfo
- *
- * @author cbateman
- *
- */
-public class EditableValueHolderInfo extends ValueHolderInfo implements
- IEditableValueHolderInfo, IDesigntimeAdapter
-{
- /**
- *
- */
- private static final long serialVersionUID = -2115990809157328451L;
- private static final String[] INTERFACE = new String[] {ComponentFactory.INTERFACE_EDITABLEVALUEHOLDER};
-
- private final boolean _localSetValue;
- private final Object _submittedValue;
- private final String _validator;
- private final String _valueChangeListener;
- private final boolean _isImmediate;
- private final boolean _isRequired;
- private final boolean _isValid;
- private List _validators;
- private List _valueChangeListeners;
-
- /**
- * @param converterDecorator
- * @param localValue
- * @param value
- * @param isImmediate
- * @param isRequired
- * @param isValid
- * @param localSetValue
- * @param submittedValue
- * @param validator
- * @param valueChangeListener
- */
- public EditableValueHolderInfo(final ConverterDecorator converterDecorator,
- final Object localValue, final Object value, final boolean isImmediate,
- final boolean isRequired, final boolean isValid, final boolean localSetValue,
- final Object submittedValue, final String validator, final String valueChangeListener)
- {
- super(converterDecorator, localValue, value);
- _isImmediate = isImmediate;
- _isRequired = isRequired;
- _isValid = isValid;
- _localSetValue = localSetValue;
- _submittedValue = submittedValue;
- _validator = validator;
- _valueChangeListener = valueChangeListener;
- }
-
- public final boolean isLocalSetValue() {
- return _localSetValue;
- }
-
- public final Object getSubmittedValue() {
- return _submittedValue;
- }
-
- public final String getValidator() {
- return _validator;
- }
-
- public final String getValueChangeListener() {
- return _valueChangeListener;
- }
-
- public final boolean isImmediate() {
- return _isImmediate;
- }
-
- public final boolean isRequired() {
- return _isRequired;
- }
-
- public final boolean isValid() {
- return _isValid;
- }
-
- public void addValidator(final ValidatorDecorator validator)
- {
- if (_validators == null)
- {
- _validators = new ArrayList(2);
- }
- _validators.add(validator);
- }
-
- public void addValueChangeListener(
- final ValueChangeListenerDecorator valueChangeListenerInfo)
- {
- if (_valueChangeListeners == null)
- {
- _valueChangeListeners = new ArrayList(2);
- }
- _valueChangeListeners.add(valueChangeListenerInfo);
- }
-
- public List getValidators() {
- if (_validators == null)
- {
- return Collections.EMPTY_LIST;
- }
-
- return Collections.unmodifiableList(_validators);
- }
-
- public List getValueChangeListeners() {
- if (_valueChangeListeners == null)
- {
- return Collections.EMPTY_LIST;
- }
-
- return Collections.unmodifiableList(_valueChangeListeners);
- }
-
- public String[] getInterfaces()
- {
- return INTERFACE;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSource2Info.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSource2Info.java
deleted file mode 100644
index 21966e118..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSource2Info.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-/**
- * Design-time analog for the ActionSource2 interface.
- *
- * @author cbateman
- *
- */
-public interface IActionSource2Info extends IActionSourceInfo
-{
- /**
- * TODO: this method is similar to getAction on ActionSource from
- * our perspective since the actual string rep of the EL is basically
- * the same...
- *
- * @return an EL method expression that represents a call to
- * an action method.
- */
- String getActionExpression();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSourceInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSourceInfo.java
deleted file mode 100644
index 3d2dd2e61..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IActionSourceInfo.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.io.Serializable;
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ActionListenerDecorator;
-
-/**
- * A design time analog for the runtime ActionSource interface.
- *
- * @author cbateman
- *
- */
-public interface IActionSourceInfo extends Serializable
-{
- /**
- * @return true if action listener associated with this action source
- * should be executed immediately after the apply request values phase.
- * Default is false.
- */
- boolean isImmediate();
-
-
- /**
- * Add the action listener to the list
- *
- * @param actionListener
- */
- void addActionListener(ActionListenerDecorator actionListener);
-
- /**
- * @return all action listeners registered. List should be considered
- * immutable and may throw exceptions if modified.
- */
- List/*<ActionListenerDecorator>*/ getActionListeners();
-
- /**
- * <b> NOTE: this method is deprecated in the runtime spec and exists for
- * backward compatibility with JSF 1.1. You should avoid using it except in
- * conjunction with JSF 1.1 tooling support. This method will be deprecated
- * once the runtime spec removes the underlying API</b>
-
- * @return a method binding expression describing an action handler
- */
- String getAction();
-
- /**
- * <b> NOTE: this method is deprecated in the runtime spec and exists for
- * backward compatibility with JSF 1.1. You should avoid using it except in
- * conjunction with JSF 1.1 tooling support. This method will be deprecated
- * once the runtime spec removes the underlying API</b>
- *
- * @return a method binding expression describing an action listener
- */
- String getActionListener();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IEditableValueHolderInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IEditableValueHolderInfo.java
deleted file mode 100644
index 53403d12a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IEditableValueHolderInfo.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValueChangeListenerDecorator;
-
-/**
- * A design time analog for the JSF runtime EditableValueHolder interface.
- *
- * @author cbateman
- *
- */
-public interface IEditableValueHolderInfo extends IValueHolderInfo {
- /**
- * @return the flag indicating whether the value of the value holder should
- * be evaluated in the apply request values phase instead of the
- * process validations phase
- */
- boolean isImmediate();
-
- /**
- * @return true if the value has been set
- */
- boolean isLocalSetValue();
-
- /**
- * @return true if validation should consider this field required (must be
- * non-empty).
- */
- boolean isRequired();
-
- /**
- * @return the submitted, unconverted value of the component.
- */
- Object getSubmittedValue();
-
- /**
- * @return false if validation has determined that the value property of
- * this component is not valid.
- */
- boolean isValid();
-
- /**
- * <b> NOTE: this method is deprecated in the runtime spec and exists for
- * backward compatibility with JSF 1.1. You should avoid using it except in
- * conjunction with JSF 1.1 tooling support. This method will be deprecated
- * once the runtime spec removes the underlying API</b>
- *
- * @return a method binding expression that refers to a validator method
- */
- String getValidator();
-
- /**
- * <b> NOTE: this method is deprecated in the runtime spec and exists for
- * backward compatibility with JSF 1.1. You should avoid using it except in
- * conjunction with JSF 1.1 tooling support. This method will be deprecated
- * once the runtime spec removes the underlying API</b>
- *
- * @return a method binding expression that refers to a value change
- * listener
- */
- String getValueChangeListener();
-
- /**
- * Add validator to the list of validators for this component. Should be
- * equivalent to
- * {@link org.eclipse.jst.jsf.common.runtime.internal.model.ViewObject#addDecorator(org.eclipse.jst.jsf.common.runtime.internal.model.decorator.Decorator, Class)}.
- *
- * @param validator
- */
- void addValidator(ValidatorDecorator validator);
-
- /**
- * @return the list of validators for this component. Should be considered
- * unmodifiable (may throw exception).
- */
- List/* <ValidatorDecorator> */getValidators();
-
- /**
- * Add the value change listener to this component.
- *
- * @param valueChangeListenerInfo
- */
- void addValueChangeListener(
- ValueChangeListenerDecorator valueChangeListenerInfo);
-
- /**
- * @return the list of value change listeners. Should be considered
- * unmodifiable (may throw exception).
- */
- List/* <ValueChangeListenerDecorator> */getValueChangeListeners();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/INamingContainerInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/INamingContainerInfo.java
deleted file mode 100644
index aeb1e985c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/INamingContainerInfo.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.io.Serializable;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-
-/**
- * Design time analog for the NamingContainer interface.
- *
- * @author cbateman
- *
- */
-public interface INamingContainerInfo extends Serializable
-{
- // tagging interface
-
- /**
- * Used as an adapter impl
- */
- public final static INamingContainerInfo ADAPTER = new NamingContainerInfo();
-
- /**
- * A default naming container info
- * @author cbateman
- *
- */
- public static class NamingContainerInfo implements INamingContainerInfo, IDesigntimeAdapter
- {
- /**
- *
- */
- private static final long serialVersionUID = 7214529928361444126L;
-
- public String[] getInterfaces()
- {
- return new String[] {ComponentFactory.INTERFACE_NAMINGCONTAINER};
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IValueHolderInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IValueHolderInfo.java
deleted file mode 100644
index 661dd8192..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/IValueHolderInfo.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import java.io.Serializable;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-
-/**
- * Represents design time information about the ValueHolder behavioural
- * interface.
- *
- * @author cbateman
- *
- */
-public interface IValueHolderInfo extends Serializable
-{
- /**
- * @return the value, may be null
- */
- Object getValue();
-
- /**
- * @return the raw value without expression value evaluation. Note that
- * {@link #getValue()} may return the same value in cases where this value
- * holder is derived at design time without EL expression evaluation. May be null.
- */
- Object getLocalValue();
-
- /**
- * @return the converter for this value holder or null if none.
- */
- ConverterDecorator getConverter();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ValueHolderInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ValueHolderInfo.java
deleted file mode 100644
index 25c8e2ea6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/behavioural/ValueHolderInfo.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.behavioural;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentFactory;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-
-/**
- * Implementation of the IValueHolderInfo.
- *
- * @author cbateman
- *
- */
-public class ValueHolderInfo implements IValueHolderInfo, IDesigntimeAdapter
-{
- /**
- *
- */
- private static final long serialVersionUID = 5000699728360703727L;
-
- /**
- * the value (may include EL evaluation)
- */
- protected final Object _value;
- /**
- * the raw value before EL evaluation.
- */
- protected final Object _localValue;
- /**
- * the converter or null if none.
- */
- protected final ConverterDecorator _converterDecorator;
-
- /**
- * @param converterDecorator
- * @param localValue
- * @param value
- */
- public ValueHolderInfo(final ConverterDecorator converterDecorator,
- final Object localValue, final Object value) {
- super();
- _converterDecorator = converterDecorator;
- _localValue = localValue;
- _value = value;
- }
- public final Object getValue() {
- return _value;
- }
- public final Object getLocalValue() {
- return _localValue;
- }
- public final ConverterDecorator getConverter() {
- return _converterDecorator;
- }
- public String[] getInterfaces()
- {
- return new String[] {ComponentFactory.INTERFACE_VALUEHOLDER};
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/AbstractVisitor.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/AbstractVisitor.java
deleted file mode 100644
index a18b04fc0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/AbstractVisitor.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-/**
- * Implemented by visitors
- *
- * @author cbateman
- *
- */
-public abstract class AbstractVisitor
-{
- /**
- * A policy to control visitation
- */
- protected final VisitationPolicy _policy;
-
- /**
- * @param policy
- */
- protected AbstractVisitor(final VisitationPolicy policy)
- {
- super();
- _policy = policy;
- }
-
- /**
- * @param object
- */
- public abstract void visit(Object object);
-
- /**
- * @return the visitation policy
- */
- public VisitationPolicy getPolicy()
- {
- return _policy;
- }
-
- /**
- * A policy that allows a visitor to configure how it will visit a tree.
- *
- */
- public static final class VisitationPolicy
- {
- /**
- * indicates pre-order, parent first traversal (root visited first)
- */
- public static final int VISIT_PARENT_FIRST = 0; // pre-order
- // tree
- // visit
- /**
- * indicates post-order, children first traveral (root visited last)
- */
- public static final int VISIT_CHILDREN_FIRST = 1; // post-order
- // tree
- // visit
- /**
- * A default parent first policy
- */
- public final static VisitationPolicy ParentFirstPolicy = new VisitationPolicy(
- VISIT_PARENT_FIRST);
- /**
- * A default children first policy
- */
- public final static VisitationPolicy ChildrenFirstPolicy = new VisitationPolicy(
- VISIT_CHILDREN_FIRST);
-
- private final int _ordering;
-
- /**
- * @param ordering
- */
- public VisitationPolicy(final int ordering)
- {
- _ordering = ordering;
- }
-
- /**
- * @return the ordering
- */
- public final int getOrdering()
- {
- return _ordering;
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentFactory.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentFactory.java
deleted file mode 100644
index a3c376252..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentFactory.java
+++ /dev/null
@@ -1,399 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.bean.DataModelInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IActionSource2Info;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IActionSourceInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IEditableValueHolderInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.INamingContainerInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IValueHolderInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.FacetDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.event.IActionListenerInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.event.IValueChangeListenerInfo;
-
-/**
- * Factory for creating component related objects.
- *
- * @author cbateman
- *
- */
-public class ComponentFactory
-{
-
- /**
- * The key for the standard ValueHolder adapter interface
- */
- public final static Class VALUE_HOLDER = IValueHolderInfo.class;
- /**
- * The key for the standard EditableValueHolder adapter interface
- */
- public final static Class EDITABLE_VALUE_HOLDER = IEditableValueHolderInfo.class;
- /**
- * The key for the standard ActionSource adapter interface
- */
- public final static Class ACTION_SOURCE = IActionSourceInfo.class;
- /**
- * The key for the standard ActionSource2 adapter interface
- */
- public final static Class ACTION_SOURCE2 = IActionSource2Info.class;
- /**
- * The key for the standard NamingContainer adapter interface
- */
- public final static Class NAMING_CONTAINER = INamingContainerInfo.class;
-
- /**
- * The key for the standard Converter decorator
- */
- public final static Class CONVERTER = ConverterDecorator.class;
- /**
- * The key for the standard Facet decorator
- */
- public final static Class FACET = FacetDecorator.class;
- /**
- * The key for the standard Validator decorator
- */
- public final static Class VALIDATOR = ValidatorDecorator.class;
- /**
- * The key for the standard ValueChangeListener decorator
- */
- public final static Class VALUE_CHANGE_LISTENER = IValueChangeListenerInfo.class;
- /**
- * The key for the standard ActionListener decorator
- */
- public final static Class ACTION_LISTENER = IActionListenerInfo.class;
-
- /**
- * Base class name for UIInput's
- */
- public final static String BASE_CLASS_UIINPUT = "javax.faces.component.UIInput"; //$NON-NLS-1$
- /**
- * Base class name for UIOutput's
- */
- public final static String BASE_CLASS_UIOUTPUT = "javax.faces.component.UIOutput"; //$NON-NLS-1$
- /**
- * Base class name for UICommand's
- */
- public final static String BASE_CLASS_UICOMMAND = "javax.faces.component.UICommand"; //$NON-NLS-1$
- /**
- * Base class name for UIData's
- */
- public final static String BASE_CLASS_UIDATA = "javax.faces.component.UIData"; //$NON-NLS-1$
- /**
- * Base class name for UIForm's
- */
- public final static String BASE_CLASS_UIFORM = "javax.faces.component.UIForm"; //$NON-NLS-1$
-
- /**
- * Interface name for ValueHolder's
- */
- public final static String INTERFACE_VALUEHOLDER = "javax.faces.component.ValueHolder"; //$NON-NLS-1$
- /**
- * Interface name for EditableValueHolder's
- */
- public final static String INTERFACE_EDITABLEVALUEHOLDER = "javax.faces.component.EditableValueHolder"; //$NON-NLS-1$
- /**
- * Interface name for ActionSource's
- */
- public final static String INTERFACE_ACTIONSOURCE = "javax.faces.component.ActionSource"; //$NON-NLS-1$
- /**
- * Interface name for ActionSource2's
- */
- public final static String INTERFACE_ACTIONSOURCE2 = "javax.faces.component.ActionSource2"; //$NON-NLS-1$
- /**
- * Interface name for NamingContainer's
- */
- public final static String INTERFACE_NAMINGCONTAINER = "javax.faces.component.NamingContainer"; //$NON-NLS-1$
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param isRendered
- * @return a new component info
- */
- public static ComponentInfo createComponentInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final boolean isRendered)
- {
- return new ComponentInfo(id, parent, typeInfo, isRendered);
- }
-
- /**
- * If the rendered attribute isn't set, defaults it.
- *
- * @param attributes
- */
- public static void maybeDefaultRendered(final Map attributes)
- {
- if (!(attributes.get("rendered") instanceof Boolean)) //$NON-NLS-1$
- {
- attributes.put("rendered", Boolean.TRUE); //$NON-NLS-1$
- }
- }
-
- /**
- * @param parent
- * @param componentTypeInfo
- * @param attributes
- * @return a new component info
- */
- public static ComponentInfo createComponentInfo(final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- return new ComponentInfo(parent, componentTypeInfo, attributes);
- }
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param editableValueHolder
- * @param isRendered
- * @return a new UIInputInfo
- */
- public static UIInputInfo createUIInputInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final IEditableValueHolderInfo editableValueHolder,
- final boolean isRendered)
- {
- return new UIInputInfo(id, parent, typeInfo, editableValueHolder,
- isRendered);
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- * @return a new UIInputInfo
- */
- public static UIInputInfo createUIInputInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- return new UIInputInfo(parent, typeInfo, attributes);
- }
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param valueHolderInfo
- * @param isRendered
- * @return a new UIOutputInfo
- */
- public static UIOutputInfo createUIOutputInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final IValueHolderInfo valueHolderInfo, final boolean isRendered)
- {
- return new UIOutputInfo(id, parent, typeInfo, valueHolderInfo,
- isRendered);
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- * @return a new UIOutputInfo
- */
- public static UIOutputInfo createUIOutputInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- return new UIOutputInfo(parent, typeInfo, attributes);
- }
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param actionSourceInfo
- * @param isRendered
- * @return a new UICommandInfo
- */
- public static UICommandInfo createUICommandInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final IActionSourceInfo actionSourceInfo, final boolean isRendered)
- {
- return new UICommandInfo(id, parent, typeInfo, isRendered,
- actionSourceInfo);
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- * @return a new UICommandInfo
- */
- public static UICommandInfo createUICommandInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- return new UICommandInfo(parent, typeInfo, attributes);
- }
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param isRendered
- * @param prependId
- * @param submitted
- * @return a new UIFormInfo
- */
- public static UIFormInfo createUIFormInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final boolean isRendered, final boolean prependId,
- final boolean submitted)
- {
- return new UIFormInfo(id, parent, typeInfo, isRendered, prependId,
- submitted);
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- * @return a new UIFormInfo
- */
- public static UIFormInfo createUIFormInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- maybeDefaultPrependId(attributes);
- maybeDefaultSubmitted(attributes);
- return new UIFormInfo(parent, typeInfo, attributes);
- }
-
- private static void maybeDefaultSubmitted(Map attributes)
- {
- if (!(attributes.get("submitted") instanceof Boolean)) //$NON-NLS-1$
- {
- attributes.put("submitted", Boolean.FALSE); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultPrependId(Map attributes)
- {
- if (!(attributes.get("prependId") instanceof Boolean)) //$NON-NLS-1$
- {
- attributes.put("prependId", Boolean.FALSE); //$NON-NLS-1$
- }
- }
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param isRendered
- * @param dataModel
- * @param first
- * @param footer
- * @param header
- * @param rowCount
- * @param rowAvailable
- * @param rowData
- * @param rowIndex
- * @param rows
- * @param value
- * @param var
- * @return a new UIDataInfo
- */
- public static UIDataInfo createUIDataInfo(final String id,
- final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final boolean isRendered, final DataModelInfo dataModel,
- final int first, final ComponentInfo footer,
- final ComponentInfo header, final int rowCount,
- final boolean rowAvailable, final Object rowData,
- final int rowIndex, final int rows, final Object value,
- final String var)
- {
- return new UIDataInfo(id, parent, typeInfo, isRendered, dataModel,
- first, footer, header, rowCount, rowAvailable, rowData,
- rowIndex, rows, value, var);
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- * @return the UIDataInfo
- */
- public static UIDataInfo createUIDataInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, final Map attributes)
- {
- maybeDefaultRendered(attributes);
- maybeDefaultFirst(attributes);
- maybeDefaultRowCount(attributes);
- maybeDefaultRowAvailable(attributes);
- maybeDefaultRowIndex(attributes);
- maybeDefaultRows(attributes);
- maybeDefaultVar(attributes);
- return new UIDataInfo(parent, typeInfo, attributes);
- }
-
-
- private static final Integer ZERO = new Integer(0);
- private static final Integer MINUS_ONE = new Integer(-1);
-
- private static void maybeDefaultFirst(Map attributes)
- {
- if (!(attributes.get("first") instanceof Integer)) //$NON-NLS-1$
- {
- attributes.put("first", ZERO); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultRowCount(Map attributes)
- {
- if (!(attributes.get("rowCount") instanceof Integer)) //$NON-NLS-1$
- {
- attributes.put("rowCount", MINUS_ONE); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultRowAvailable(Map attributes)
- {
- if (! (attributes.get("rowAvailable") instanceof Boolean)) //$NON-NLS-1$
- {
- attributes.put("rowAvailable", Boolean.FALSE); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultRowIndex(Map attributes)
- {
- if (! (attributes.get("rowIndex") instanceof Integer)) //$NON-NLS-1$
- {
- attributes.put("rowIndex", MINUS_ONE); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultRows(Map attributes)
- {
- if (! (attributes.get("rows") instanceof Integer)) //$NON-NLS-1$
- {
- attributes.put("rows", ZERO); //$NON-NLS-1$
- }
- }
-
- private static void maybeDefaultVar(Map attributes)
- {
- if (! (attributes.get("var") instanceof String)) //$NON-NLS-1$
- {
- attributes.put("var", "** default variable **"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentInfo.java
deleted file mode 100644
index 6bb462940..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentInfo.java
+++ /dev/null
@@ -1,930 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.beans.BeanInfo;
-import java.beans.IntrospectionException;
-import java.beans.Introspector;
-import java.beans.PropertyDescriptor;
-import java.io.Serializable;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.Map.Entry;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.ViewObject;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.AbstractVisitor.VisitationPolicy;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.FacetDecorator;
-
-/**
- * Models a basic UI component instance
- *
- * TODO: should implement a visitor pattern to traverse component trees
- *
- * @author cbateman
- *
- */
-public class ComponentInfo extends ViewObject implements Serializable,
- IVisitable
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 2517204356825585699L;
-
- private final static int DEFAULT_ARRAY_SIZE = 4;
-
- private transient BeanPropertyManager _beanPropertyManager;
- /**
- * Encapsulates all of the data for the view object
- */
- protected final ComponentInfoData _data;
-
- // initialized
- // by
- // getBeanProperties
-
- /**
- * @param id
- * @param parent
- * @param componentTypeInfo
- * @param isRendered
- */
- protected ComponentInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo, final boolean isRendered)
- {
- super(new ComponentInfoData(id, parent, componentTypeInfo, isRendered));
- _data = (ComponentInfoData) super.getData();
-
- final Set propExclude = new HashSet();
- propExclude.add("attributeNames"); //$NON-NLS-1$
- propExclude.add("componentTypeInfo"); //$NON-NLS-1$
- propExclude.add("valueChangeListeners"); //$NON-NLS-1$
- propExclude.add("visitableChildren"); //$NON-NLS-1$
-
- _beanPropertyManager = new BeanPropertyManager(this, propExclude);
- }
-
- /**
- * @param data
- */
- protected ComponentInfo(final ComponentInfoData data)
- {
- super(data);
- _data = data;
- }
-
- /**
- * Construct a new component info using the attributes keyed by name in
- * attributes to set values. The names must match the corresponding bean
- * property names. Primitives should be wrapped in their corresponding
- * object types. Exceptions will be thrown if there is a type mismatch on an
- * expected type. Number will be used for all numeric primitive wrappers an
- * the corresponding "to" will be called.
- *
- * @param parent
- * @param componentTypeInfo
- * @param attributes
- * @throws ClassCastException
- * if an attribute's value doesn't match the expected type
- * @throws NullPointerException
- * if an attribute value is null for a value whose type is
- * expected to be primitive
- * @throws IllegalArgumentException
- * if attributes does not contain a required key.
- */
- protected ComponentInfo(final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo, final Map attributes)
- {
- this(getStringProperty("id", attributes, false), parent, //$NON-NLS-1$
- componentTypeInfo, getBooleanProperty("rendered", attributes, false)); //$NON-NLS-1$
- }
-
- /**
- * @param key
- * @param attributes
- * @param mandatory
- * @return the value in attributes at location key, forcing a
- * ClassCastException if it turns out not to be a String.
- * @throws ClassCastException
- * if the attribute for key is not a String
- * @throws IllegalArgumentException
- * if the attribute for key is null but mandatory is true.
- */
- protected static String getStringProperty(final String key,
- final Map attributes, final boolean mandatory)
- {
- final Object value = attributes.get(key);
-
- if (mandatory && value == null)
- {
- throw new IllegalArgumentException(key
- + " is a mandatory attribute"); //$NON-NLS-1$
- }
- return (String) value;
- }
-
- /**
- * @param key
- * @param attributes
- * @param mandatory
- *
- * @return the value in attributes at location, forcing a ClassCastExceptio
- * if it is not a Boolean and mandatory. returns false if no value
- * and not mandatory
- * @throws IllegalArgumentException
- * if key is not found and value is mandatory
- */
- protected static boolean getBooleanProperty(final String key,
- final Map attributes, final boolean mandatory)
- {
- final Boolean value = (Boolean) attributes.get(key);
-
- if (value == null)
- {
- if (mandatory)
- {
- throw new IllegalArgumentException(key + "is mandatory"); //$NON-NLS-1$
- }
- return false;
- }
-
- return value.booleanValue();
- }
-
- /**
- * @param key
- * @param attributes
- * @return the integer property for key. Casts the value to Number and calls
- * Number.intValue(). 0 if no value.
- */
- protected static int getIntegerProperty(final String key,
- final Map attributes)
- {
- final Number value = (Number) attributes.get(key);
-
- if (value == null)
- {
- return 0;
- }
-
- return value.intValue();
- }
-
- /**
- * @param key
- * @param attributes
- * @return the component info value from attributes
- */
- protected static ComponentInfo getComponentProperty(final String key,
- final Map attributes)
- {
- return (ComponentInfo) attributes.get(key);
- }
-
- /**
- * @return the id
- */
- public final String getId()
- {
- return _data.getId();
- }
-
- /**
- * @return the component type info
- */
- public final ComponentTypeInfo getComponentTypeInfo()
- {
- return _data.getComponentTypeInfo();
- }
-
- /**
- * Pre-condition: isModifiable() == true Post-condition: getChildren() will
- * return an empty list.
- */
- protected final void clearChildren()
- {
- _data.getChildren().clear();
- }
-
- /**
- * @return the children. List is unmodifiable. List contains all children
- * including facets.
- */
- public final List/* <ComponentInfo> */getChildren()
- {
- if (_data.isProtected())
- {
- return _data.getChildren();
- }
- return Collections.unmodifiableList(_data.getChildren());
- }
-
- /**
- * Get the sub-set of {@link #getChildren()} that are facets. This is a
- * convenience method for {@link #getDecorators(Class)}
- *
- * @return all component children that are facets
- */
- public final List getFacets()
- {
- return getDecorators(ComponentFactory.FACET);
- }
-
- /**
- * @param childComponent
- */
- public final void addChild(final ComponentInfo childComponent)
- {
- if (childComponent == this)
- {
- throw new IllegalArgumentException(
- "A component cannot be its own child"); //$NON-NLS-1$
- }
- _data.addChild(childComponent);
- // we need to reset the child's parent to me
- childComponent.setParent(this);
- }
-
- /**
- * @param parent
- */
- public final void setParent(ComponentInfo parent)
- {
- _data.setParent(parent);
- }
-
- /**
- * @param name
- * @param facetComponent
- */
- public final void addFacet(final String name,
- final ComponentInfo facetComponent)
- {
- addChild(facetComponent);
- addDecorator(new FacetDecorator(name, facetComponent));
- }
-
- /**
- * @param component
- * @return if component corresponds to a facet of this component, returns
- * the name of that facet. Returns null if not found.
- */
- public final String getFacetName(final ComponentInfo component)
- {
- if (component == null)
- {
- return null;
- }
-
- final List facets = getDecorators(ComponentFactory.FACET);
-
- for (final Iterator it = facets.iterator(); it.hasNext();)
- {
- final FacetDecorator facet = (FacetDecorator) it.next();
- if (component == facet.getDecorates())
- {
- return facet.getName();
- }
- }
-
- // component is not a facet
- return null;
- }
-
- /**
- * @param name
- * @return if this has a facet called name, then returns it's single root
- * component.
- */
- public final ComponentInfo getFacet(final String name)
- {
- if (name == null)
- {
- return null;
- }
-
- final List facets = getDecorators(ComponentFactory.FACET);
-
- for (final Iterator it = facets.iterator(); it.hasNext();)
- {
- final FacetDecorator facet = (FacetDecorator) it.next();
- if (name.equals(facet.getName()))
- {
- return facet.getDecorates();
- }
- }
-
- // not found
- return null;
- }
-
- public String toString()
- {
- final String parentId = getParent() != null ? getParent().getId()
- : "null"; //$NON-NLS-1$
- String toString = getMostSpecificComponentName() + ": id=" //$NON-NLS-1$
- + _data.getId() + ", parentId: " + parentId + ", family=" //$NON-NLS-1$ //$NON-NLS-2$
- + getComponentTypeInfo().getComponentFamily() + ", render=" //$NON-NLS-1$
- + getComponentTypeInfo().getRenderFamily() + ", rendered=" //$NON-NLS-1$
- + isRendered();
-
- // use bean introspection to dump child properties
- if (this.getClass() != ComponentInfo.class)
- {
- toString += dumpProperties();
- }
-
- return toString;
- }
-
- private String dumpProperties()
- {
- String properties = ""; //$NON-NLS-1$
- try
- {
- final BeanInfo beanInfo = Introspector.getBeanInfo(this.getClass(),
- ComponentInfo.class);
-
- final PropertyDescriptor[] descriptors = beanInfo
- .getPropertyDescriptors();
- for (int i = 0; i < descriptors.length; i++)
- {
- final PropertyDescriptor desc = descriptors[i];
- final String name = desc.getName();
- final Object valueObj = desc.getValue(name);
- final String value = valueObj != null ? valueObj.toString()
- : "null"; //$NON-NLS-1$
- properties += ", " + name + "=" + value; //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- catch (final IntrospectionException e)
- {
- return "Error introspecting bean: " + e.getLocalizedMessage(); //$NON-NLS-1$
- }
-
- return properties;
- }
-
- /**
- * @return used for toString. Clients should not use.
- */
- protected String getMostSpecificComponentName()
- {
- return "UIComponent"; //$NON-NLS-1$
- }
-
- /**
- * @return the parent of this component or null.
- */
- public final ComponentInfo getParent()
- {
- return _data.getParent();
- }
-
- /**
- * @return the rendered flag
- */
- public final boolean isRendered()
- {
- return _data.isRendered();
- }
-
- public synchronized void addAdapter(final Class adapterType,
- final Object adapter)
- {
- super.addAdapter(adapterType, adapter);
-
- // force an update on the next call to getBeanProperties
- _beanPropertyManager.reset();
- }
-
- public synchronized Object removeAdapter(final Class adapterType)
- {
- final Object removed = super.removeAdapter(adapterType);
-
- _beanPropertyManager.reset();
-
- return removed;
- }
-
- /**
- * @return the set of all bean property names for this component. The set is
- * unmodifiable and will throw exceptions if modification is
- * attempted.
- */
- protected final Map/* <String, ComponentBeanProperty> */getBeanProperties()
- {
- return Collections.unmodifiableMap(_beanPropertyManager
- .getBeanProperties());
- }
-
- /**
- * @author cbateman
- *
- */
- public static class ComponentInfoData extends ViewObjectData
- {
- /**
- *
- */
- private static final long serialVersionUID = 5052732412917986062L;
- /**
- * the component id
- */
- private final String _id;
- /**
- * the component's parent or null if none
- */
- private ComponentInfo _parent;
-
- /**
- * the type info for this component
- */
- protected final ComponentTypeInfo _componentTypeInfo;
- /**
- * the rendered flage
- */
- protected final boolean _isRendered;
-
- private List /* <ComponentInfo> */_children = new ArrayList(
- DEFAULT_ARRAY_SIZE);
-
- /**
- * @param id
- * @param parent
- * @param componentTypeInfo
- * @param isRendered
- */
- public ComponentInfoData(final String id, ComponentInfo parent,
- ComponentTypeInfo componentTypeInfo, boolean isRendered)
- {
- super(false);
- _id = id;
- _parent = parent;
- _componentTypeInfo = componentTypeInfo;
- _isRendered = isRendered;
- }
-
- /**
- * @param childComponent
- */
- protected void addChild(ComponentInfo childComponent)
- {
- enforceProtection();
-
- getChildren().add(childComponent);
- }
-
- /**
- * @return the modifiable list of children
- */
- protected final List/* <ComponentInfo> */getChildren()
- {
- return _children;
- }
-
- protected void doBeforeProtecting()
- {
- super.doBeforeProtecting();
- // compact the children array list
- if (_children.size() > 0)
- {
- _children = Collections.unmodifiableList(_children);
- }
- else
- {
- _children = Collections.EMPTY_LIST;
- }
- }
-
- /**
- * @return the isRendered flag
- */
- protected final boolean isRendered()
- {
- return _isRendered;
- }
-
- /**
- * @return the component type info flag
- */
- protected final ComponentTypeInfo getComponentTypeInfo()
- {
- return _componentTypeInfo;
- }
-
- /**
- * @return the parent or null if no parent
- */
- protected final ComponentInfo getParent()
- {
- return _parent;
- }
-
- /**
- * @param parent
- */
- protected final void setParent(ComponentInfo parent)
- {
- enforceProtection();
- _parent = parent;
- }
-
- /**
- * @return the component id
- */
- protected final String getId()
- {
- return _id;
- }
- }
-
- /**
- * This is similar to the runtime getAttributes().get(name) call. The reason
- * we don't implement a Map of all attribute values is that the implicit
- * property structure can change at any time due to add/removeAdapter. To
- * get all attributes known for a component, instead use:
- *
- * The synchronized block is advised to protect against concurrent
- * modification exceptions on the keySet iterator.
- *
- * @param name
- *
- * @return the value of the attribute or null if none.
- *
- */
- public synchronized ComponentBeanProperty getAttribute(final String name)
- {
- return (ComponentBeanProperty) getBeanProperties().get(name);
- }
-
- /**
- * @return the set of valid attribute names. The Set is not modifiable.
- */
- public synchronized Set/* <String> */getAttributeNames()
- {
- return getBeanProperties().keySet();
- }
-
- /**
- * Stores a bean property descriptor along information about which
- * implementation class declares it and what key to pass to getAdapter() in
- * order to get it.
- *
- */
- public final static class ComponentBeanProperty
- {
- private final PropertyDescriptor _propertyDescriptor;
- private final Object _declaringImplementation;
- private final Class _adapterKeyClass;
-
- // only instantiable locally
- private ComponentBeanProperty(Class adapterKeyClass,
- Object declaringImplementationClass,
- PropertyDescriptor propertyDescriptor)
- {
- super();
- _adapterKeyClass = adapterKeyClass;
- _declaringImplementation = declaringImplementationClass;
- _propertyDescriptor = propertyDescriptor;
- }
-
- /**
- * @return the value of property
- */
- public final Object getValue()
- {
- final Method method = _propertyDescriptor.getReadMethod();
- if (method != null)
- {
- try
- {
- method.setAccessible(true);
- return method.invoke(_declaringImplementation,
- new Object[0]);
- }
- catch (IllegalArgumentException e)
- {
- e.printStackTrace();
- }
- catch (IllegalAccessException e)
- {
- e.printStackTrace();
- }
- catch (InvocationTargetException e)
- {
- e.printStackTrace();
- }
- }
- // if any step fails, return null
- return null;
- }
-
- /**
- * @return the property descriptor
- */
- public final PropertyDescriptor getPropertyDescriptor()
- {
- return _propertyDescriptor;
- }
-
- /**
- * @return the implemenation
- */
- public final Object getDeclaringImplementationClass()
- {
- return _declaringImplementation;
- }
-
- /**
- * @return the adapter class for the interface that the declaring
- * implementation is providing the impl for
- */
- public final Class getAdapterKeyClass()
- {
- return _adapterKeyClass;
- }
- }
-
- /**
- * Manages bean property information for a component
- *
- * @author cbateman
- *
- */
- protected final static class BeanPropertyManager
- {
- /**
- * a map of the bean property names exposed by this component including
- * all those added by addAdapter().
- *
- * this is synthetic based the class definition and installed adapters
- * so as long that info is available, no need to serialize.
- */
- protected transient Map /*
- * <String,
- * ComponentBeanProperty>
- */_beanProperties; // lazily
- private final transient ComponentInfo _component;
- private final transient Set _excludeNames;
-
- /**
- * @param component
- * @param excludeNames
- */
- protected BeanPropertyManager(final ComponentInfo component,
- final Set excludeNames)
- {
- _component = component;
- _excludeNames = excludeNames;
- }
-
- /**
- * Will throw exception of the calling thread already holds the "this"
- * monitor lock. This is to ensure that caller always acquires locks in
- * appropriate order to prevent deadlock.
- *
- * @return the internal set of bean properties. This Set may be modified
- * internally.
- */
- public Map getBeanProperties()
- {
- if (Thread.holdsLock(this))
- {
- throw new IllegalStateException(
- "Must not already own this lock"); //$NON-NLS-1$
- }
-
- // must always acquire component lock first to prevent deadlock
- synchronized (_component)
- {
- synchronized (this)
- {
- if (_beanProperties == null)
- {
- _beanProperties = calculateAllBeanPropNames(ViewObject.class);
- }
-
- return _beanProperties;
- }
- }
- }
-
- /**
- * Will throw exception if the calling thread already holds the "this"
- * monitor lock. This is to ensure that caller always acquires locks in
- * appropriate order to prevent deadlock.
- *
- * Clears the internal map and sets to null. This will force it to be
- * completely new built on the next call to getBeanProperties
- */
- public void reset()
- {
- if (Thread.holdsLock(this))
- {
- throw new IllegalStateException(
- "Must not already own this lock"); //$NON-NLS-1$
- }
-
- // must always acquire component lock first to prevent deadlock
- synchronized (_component)
- {
- synchronized (this)
- {
- if (_beanProperties != null)
- {
- _beanProperties.clear();
- _beanProperties = null;
- }
- }
- }
- }
-
- /**
- * @param stopClass
- * @return a synchronized map of all bean property names on this class
- * up to stopClass, as well as all adapter property names (as
- * though this really implemented them).
- */
- private Map calculateAllBeanPropNames(final Class stopClass)
- {
- // use a set to prevents the duplicates
- final Map allProperties = new HashMap();
-
- {
- final Class myClass = _component.getClass();
- final List myProperties = getOrCreateBeanProperties(myClass,
- stopClass);
-
- addToMap(myProperties, _component, myClass, allProperties, _excludeNames);
- }
-
- {
- for (final Iterator it = _component.getAdapterMap().entrySet()
- .iterator(); it.hasNext();)
- {
- Map.Entry entry = (Entry) it.next();
-
- final Class adapterClass = (Class) entry.getKey();
- final Object declaringClass = entry.getValue();
- // get all props, excluding the ones on Object.
- final List props = getOrCreateBeanProperties(adapterClass,
- null);
- addToMap(props, declaringClass, adapterClass, allProperties,
- _excludeNames);
- }
- }
-
- return Collections.synchronizedMap(allProperties);
- }
-
- private static void addToMap(
- final List/* <ComponentBeanProperty> */addThese,
- final Object declaringObject, final Class declaringAdapter,
- final Map toMe,
- Set excludeNames)
- {
- for (final Iterator it = addThese.iterator(); it.hasNext();)
- {
- final PropertyDescriptor desc = (PropertyDescriptor) it.next();
-
- if (!toMe.containsKey(desc.getName())
- && !excludeNames.contains(desc.getName()))
- {
- toMe.put(desc.getName(), new ComponentBeanProperty(
- declaringAdapter, declaringObject, desc));
- }
- }
- }
-
- /**
- * lazily loaded with the local properties (those not defined using
- * adapters)
- *
- * MUST INITIALIZE early so can synchronize on it
- */
- private transient static Map /* <Class, List<PropertyDescriptor> */PROPERTY_MAP = new HashMap();
-
- /**
- * @param startClass
- * @param stopClass
- * @return a unmodifiable list of properties starting from startClass.
- * stopClass is only used if an entry doesn't already exist in
- * PROPERTY_MAP for startClass. The method is synchronized on
- * the PROPERTY_MAP it updates.
- */
- protected static List/* <PropertyDescriptor */getOrCreateBeanProperties(
- final Class startClass, final Class stopClass)
- {
- synchronized (PROPERTY_MAP)
- {
- List localBeanProps = (List) PROPERTY_MAP.get(startClass);
-
- if (localBeanProps == null)
- {
- localBeanProps = calculateBeanProperties(startClass,
- stopClass);
- PROPERTY_MAP.put(startClass, Collections
- .unmodifiableList(localBeanProps));
- }
-
- return localBeanProps;
- }
- }
-
- /**
- * @param startClass
- * @param stopClass
- * @return a List<String> containing all of the bean names between
- * startClass and stopClass. Start class must be a descendant
- * (sub-class, sub-sub-class etc.) of stopClass. The properties
- * on stopClass are excluded from analysis.
- */
- private static List/* <PropertyDescriptor> */calculateBeanProperties(
- final Class startClass, final Class stopClass)
- {
- BeanInfo beanInfo;
- List names = new ArrayList();
-
- try
- {
- beanInfo = Introspector.getBeanInfo(startClass, stopClass);
- final PropertyDescriptor[] descriptors = beanInfo
- .getPropertyDescriptors();
-
- if (descriptors != null)
- {
- names = Arrays.asList(descriptors);
- }
- }
- catch (final IntrospectionException e)
- {
- e.printStackTrace();
- }
- return names;
- }
-
- }
-
- /**
- * Visits this node and it's entire tree and makes all nodes protected.
- */
- public final void setSubtreeProtected()
- {
- // lock children first
- final ComponentTreeVisitor protectionVisitor = new ComponentTreeVisitor(VisitationPolicy.ChildrenFirstPolicy)
- {
- public void visit(ComponentInfo component)
- {
- component.setProtected();
- }
- };
-
- accept(protectionVisitor);
- }
-
- public void accept(AbstractVisitor visitor)
- {
- // check policy ordering
- if (visitor.getPolicy().getOrdering() == VisitationPolicy.VISIT_PARENT_FIRST)
- {
- visitor.visit(this);
- visitChildren(visitor);
- }
- else
- {
- visitChildren(visitor);
- visitor.visit(this);
- }
- }
-
- private void visitChildren(AbstractVisitor visitor)
- {
- for (final Iterator it = getVisitableChildren(); it.hasNext();)
- {
- visitor.visit(it.next());
- }
- }
-
- public Iterator getVisitableChildren()
- {
- return getChildren().iterator();
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTreeVisitor.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTreeVisitor.java
deleted file mode 100644
index 4bedc7c67..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTreeVisitor.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-/**
- * An abstract class sub-classed by objects that wish to apply a Visitor pattern
- * type visitation to a component tree.
- *
- * @author cbateman
- *
- */
-public abstract class ComponentTreeVisitor extends AbstractVisitor
-{
- /**
- * @param policy
- */
- public ComponentTreeVisitor(final VisitationPolicy policy)
- {
- super(policy);
- }
-
- /**
- * @param component
- */
- public abstract void visit(final ComponentInfo component);
-
- public final void visit(final Object object)
- {
- visit((ComponentInfo) object);
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTypeInfo.java
deleted file mode 100644
index 74c7c9bcb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/ComponentTypeInfo.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.types.ClassTypeInfo;
-
-/**
- * Type information about a UIComponent
- *
- * @author cbateman
- *
- */
-public class ComponentTypeInfo extends ClassTypeInfo
-{
- /**
- * serializable uid
- */
- private static final long serialVersionUID = -311156682935177206L;
- /**
- * the ComponentType (see JSF spec for definition)
- */
- protected final String _componentType; // may be null, since may not be
- // known at runtime
- /**
- * the component family (see JSF spec)
- */
- protected final String _componentFamily;
- /**
- * the render family (see JSF spec)
- */
- protected final String _renderFamily;
-
- /**
- * @param componentType
- * @param componentClass
- * @param componentFamily
- * @param renderFamily
- */
- public ComponentTypeInfo(final String componentType,
- final String componentClass, final String componentFamily,
- final String renderFamily)
- {
- super(componentClass, new String[0], new String[0]);
- _componentType = componentType;
- _componentFamily = componentFamily;
- _renderFamily = renderFamily;
- }
-
- /**
- * @param componentType
- * @param superClasses
- * @param interfaces
- * @param componentClass
- * @param componentFamily
- * @param renderFamily
- */
- public ComponentTypeInfo(final String componentType,
- final String componentClass,
- final String[] superClasses, final String[] interfaces,
- final String componentFamily,
- final String renderFamily)
- {
- super(componentClass, superClasses, interfaces);
- _componentType = componentType;
- _componentFamily = componentFamily;
- _renderFamily = renderFamily;
- }
-
- /**
- * @return the component type or null if unknown (may not be at runtime)
- */
- public final String getComponentType()
- {
- return _componentType;
- }
-
- /**
- * @return the component family
- */
- public final String getComponentFamily()
- {
- return _componentFamily;
- }
-
- /**
- * @return the render family
- */
- public final String getRenderFamily()
- {
- return _renderFamily;
- }
-
- public String toString()
- {
- return "Component Type Info: type = " + _componentType + " family=" + _componentFamily //$NON-NLS-1$ //$NON-NLS-2$
- + " renderer=" + _renderFamily + ", "+super.toString(); //$NON-NLS-1$ //$NON-NLS-2$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/IVisitable.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/IVisitable.java
deleted file mode 100644
index 6ddd83b34..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/IVisitable.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Iterator;
-
-/**
- * Implemented by a class that can accept visitors
- *
- */
-interface IVisitable
-{
- /**
- * Called on a visitable to accept a visitor
- *
- * @param visitor
- */
- void accept(AbstractVisitor visitor);
-
- /**
- * @return an iterator that returns IVisitable children.
- */
- Iterator getVisitableChildren();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UICommandInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UICommandInfo.java
deleted file mode 100644
index 9ff50f466..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UICommandInfo.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IActionSource2Info;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IActionSourceInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ActionListenerDecorator;
-
-/**
- * An design time analog of the standard UICommand.
- * @author cbateman
- *
- */
-public class UICommandInfo extends ComponentInfo implements IActionSource2Info {
- private final String _actionExpression;
- private final String _actionListener;
- private final boolean _isImmediate;
-
- /**
- * serialization id
- */
- private static final long serialVersionUID = -9025172832535840949L;
-
- /**
- * @param id
- * @param parent
- * @param componentTypeInfo
- * @param isRendered
- * @param actionSourceInfo
- */
- protected UICommandInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo,
- final boolean isRendered, final IActionSourceInfo actionSourceInfo) {
- super(id, parent, componentTypeInfo, isRendered);
-
- if (actionSourceInfo == null) {
- _actionExpression = null;
- _actionListener = null;
- _isImmediate = false;
- } else {
- // TODO: having action and actionExpression will come back to
- // to bite us.
- _actionExpression = actionSourceInfo.getAction();
- _actionListener = actionSourceInfo.getActionListener();
- _isImmediate = actionSourceInfo.isImmediate();
-
- for (final Iterator it = actionSourceInfo.getActionListeners()
- .iterator(); it.hasNext();) {
- final ActionListenerDecorator actionListener =
- (ActionListenerDecorator) it.next();
- addActionListener(actionListener);
- }
- }
- }
-
- /**
- * @param parent
- * @param componentTypeInfo
- * @param attributes
- */
- protected UICommandInfo(final ComponentInfo parent, final ComponentTypeInfo componentTypeInfo,
- Map attributes)
- {
- this(getStringProperty("id", attributes, true), //$NON-NLS-1$
- parent, componentTypeInfo,
- getBooleanProperty("rendered", attributes, false), //$NON-NLS-1$
- getActionSourceInfo("$actionSourceInfo", attributes) //$NON-NLS-1$
- );
- }
-
- private static IActionSourceInfo getActionSourceInfo(String key,
- Map attributes)
- {
- return (IActionSourceInfo) attributes.get(key);
- }
-
- public String getActionExpression() {
- return _actionExpression;
- }
-
- public final void addActionListener(final ActionListenerDecorator actionListener) {
- addDecorator(actionListener, ComponentFactory.ACTION_LISTENER);
- }
-
- public final String getAction() {
- return _actionExpression;
- }
-
- public final String getActionListener() {
- return _actionListener;
- }
-
- public final List getActionListeners() {
- return getDecorators(ComponentFactory.ACTION_LISTENER);
- }
-
- public final boolean isImmediate() {
- return _isImmediate;
- }
-
- protected String getMostSpecificComponentName()
- {
- return "UICommand"; //$NON-NLS-1$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIDataInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIDataInfo.java
deleted file mode 100644
index 56981af98..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIDataInfo.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.bean.DataModelInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.bean.SerializableObject;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.INamingContainerInfo;
-
-/**
- * Design time analog to UIData.
- *
- * @author cbateman
- *
- */
-public class UIDataInfo extends ComponentInfo implements INamingContainerInfo
-{
- /**
- * the standard name for the footer facet
- */
- public final static String FACET_NAME_FOOTER = "footer"; //$NON-NLS-1$
- /**
- * the standard name for the header facet.
- */
- public final static String FACET_NAME_HEADER = "header"; //$NON-NLS-1$
- /**
- * serialization id
- */
- private static final long serialVersionUID = 3473288390914978784L;
-
- private final DataModelInfo _dataModel;
- private final int _first;
- private final int _rowCount;
- private final boolean _rowAvailable;
- private final SerializableObject _rowData;
- private final int _rowIndex;
- private final int _rows;
- private final SerializableObject _value;
- private final String _var;
-
- /**
- * @param id
- * @param parent
- * @param componentTypeInfo
- * @param isRendered
- * @param dataModel
- * @param first
- * @param footer
- * @param header
- * @param rowCount
- * @param rowAvailable
- * @param rowData
- * @param rowIndex
- * @param rows
- * @param value
- * @param var
- */
- public UIDataInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo,
- final boolean isRendered, final DataModelInfo dataModel,
- final int first, final ComponentInfo footer,
- final ComponentInfo header, final int rowCount,
- final boolean rowAvailable, final Object rowData,
- final int rowIndex, final int rows, final Object value,
- final String var)
- {
- super(id, parent, componentTypeInfo, isRendered);
- _dataModel = dataModel;
- _first = first;
- _rowCount = rowCount;
- _rowAvailable = rowAvailable;
- _rowData = new SerializableObject(rowData);
- _rowIndex = rowIndex;
- _rows = rows;
- _value = new SerializableObject(value);
- _var = var;
-
- if (footer != null)
- {
- addFacet(FACET_NAME_FOOTER, footer);
- }
-
- if (header != null)
- {
- addFacet(FACET_NAME_HEADER, header);
- }
- }
-
- /**
- * @param parent
- * @param componentTypeInfo
- * @param attributes
- */
- public UIDataInfo(final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo, Map attributes)
- {
- this(getStringProperty("id", attributes, true), parent, //$NON-NLS-1$
- componentTypeInfo,
- getBooleanProperty("rendered", attributes, false), //$NON-NLS-1$
- getDataModelInfo("$dataModel", attributes), //$NON-NLS-1$
- getIntegerProperty("first", attributes), //$NON-NLS-1$
- getComponentProperty("footer", attributes), //$NON-NLS-1$
- getComponentProperty("header", attributes), //$NON-NLS-1$
- getIntegerProperty("rowCount", attributes), //$NON-NLS-1$
- getBooleanProperty("rowAvailable", attributes, false), //$NON-NLS-1$
- attributes.get("rowData"), //$NON-NLS-1$
- getIntegerProperty("rowIndex", attributes), //$NON-NLS-1$
- getIntegerProperty("rows", attributes), //$NON-NLS-1$
- attributes.get("value"), //$NON-NLS-1$
- getStringProperty("var", attributes, false)); //$NON-NLS-1$
- }
-
- private static DataModelInfo getDataModelInfo(String key, Map attributes)
- {
- return (DataModelInfo) attributes.get(key);
- }
-
- /**
- * @return the data model
- */
- public final DataModelInfo getDataModel()
- {
- return _dataModel;
- }
-
- /**
- * @return the first row
- */
- public final int getFirst()
- {
- return _first;
- }
-
- /**
- * @return the row count
- */
- public final int getRowCount()
- {
- return _rowCount;
- }
-
- /**
- * @return true if the row is available
- */
- public final boolean isRowAvailable()
- {
- return _rowAvailable;
- }
-
- /**
- * @return the row data (may be null if not serialiable)
- */
- public final Object getRowData()
- {
- return _rowData.getMaybeSerializable();
- }
-
- /**
- * @return the row index
- */
- public final int getRowIndex()
- {
- return _rowIndex;
- }
-
- /**
- * @return the rows
- */
- public final int getRows()
- {
- return _rows;
- }
-
- /**
- * @return the value of the model (may be null if not serialiable)
- */
- public final Object getValue()
- {
- return _value.getMaybeSerializable();
- }
-
- /**
- * @return the name used to define the EL row variable
- */
- public final String getVar()
- {
- return _var;
- }
-
- /**
- * @return the header facet or null.
- */
- public final ComponentInfo getHeader()
- {
- return getFacet(FACET_NAME_HEADER);
- }
-
- /**
- * @return the footer facet or null.
- */
- public final ComponentInfo getFooter()
- {
- return getFacet(FACET_NAME_FOOTER);
- }
-
- protected String getMostSpecificComponentName()
- {
- return "UIData"; //$NON-NLS-1$
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIFormInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIFormInfo.java
deleted file mode 100644
index 2b8233055..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIFormInfo.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.INamingContainerInfo;
-
-/**
- * A design-time analog for the UIForm.
- *
- * @author cbateman
- */
-public class UIFormInfo extends ComponentInfo implements INamingContainerInfo
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 6961034911873576644L;
-
- private final boolean _prependId;
- private final boolean _submitted;
-
- /**
- * @param id
- * @param parent
- * @param componentTypeInfo
- * @param isRendered
- * @param prependId
- * @param submitted
- */
- protected UIFormInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo componentTypeInfo, final boolean isRendered
- , final boolean prependId, final boolean submitted) {
- super(id, parent, componentTypeInfo, isRendered);
- _prependId = prependId;
- _submitted = submitted;
- }
-
- /**
- * @param parent
- * @param componentTypeInfo
- * @param attributes
- */
- protected UIFormInfo(final ComponentInfo parent, ComponentTypeInfo componentTypeInfo,
- Map attributes)
- {
- this(getStringProperty("id", attributes, true), //$NON-NLS-1$
- parent,
- componentTypeInfo,
- getBooleanProperty("rendered", attributes, false), //$NON-NLS-1$
- getBooleanProperty("prependId", attributes, false), //$NON-NLS-1$
- getBooleanProperty("submitted", attributes, false)); //$NON-NLS-1$
- }
-
- /**
- * JSF 1.2 only
- *
- * @return true if the form allows its id to be prepended to its
- * descendent's ids.
- */
- public final boolean isPrependId()
- {
- return _prependId;
- }
-
- /**
- * @return true if the form is submitted.
- */
- public final boolean isSubmitted() {
- return _submitted;
- }
-
- protected String getMostSpecificComponentName()
- {
- return "UIForm"; //$NON-NLS-1$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIInputInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIInputInfo.java
deleted file mode 100644
index 14a613192..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIInputInfo.java
+++ /dev/null
@@ -1,182 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IEditableValueHolderInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValueChangeListenerDecorator;
-
-/**
- * A design-time analog of the standard UIInput.
- *
- * @author cbateman
- *
- */
-public class UIInputInfo extends UIOutputInfo implements
- IEditableValueHolderInfo
-{
- /**
- * serializable uid
- */
- private static final long serialVersionUID = -6055473902554910848L;
- private final boolean _isValid;
- private final boolean _isImmediate;
- private final boolean _isRequired;
- private final Object _submittedValue;
- private final String _validator;
- private final String _valueChangeListener;
- private final boolean _localSetValue;
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param editableValueHolderInfo
- * @param isRendered
- */
- protected UIInputInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo typeInfo,
- final IEditableValueHolderInfo editableValueHolderInfo,
- final boolean isRendered)
- {
- super(id, parent, typeInfo, editableValueHolderInfo, isRendered);
-
- if (editableValueHolderInfo == null)
- {
- _isValid = true;
- _isImmediate = false;
- _isRequired = false;
- _localSetValue = false;
- _submittedValue = null;
- _validator = null;
- _valueChangeListener = null;
- }
- else
- {
- _isValid = editableValueHolderInfo.isValid();
- _isImmediate = editableValueHolderInfo.isImmediate();
- _isRequired = editableValueHolderInfo.isRequired();
- _localSetValue = editableValueHolderInfo.isLocalSetValue();
- _submittedValue = editableValueHolderInfo.getSubmittedValue();
- _validator = editableValueHolderInfo.getValidator();
- _valueChangeListener = editableValueHolderInfo
- .getValueChangeListener();
-
- for (final Iterator it = editableValueHolderInfo.getValidators()
- .iterator(); it.hasNext();)
- {
- final ValidatorDecorator validator = (ValidatorDecorator) it
- .next();
- addValidator(validator);
- }
-
- for (final Iterator it = editableValueHolderInfo
- .getValueChangeListeners().iterator(); it.hasNext();)
- {
- final ValueChangeListenerDecorator valueChangeListener = (ValueChangeListenerDecorator) it
- .next();
- addValueChangeListener(valueChangeListener);
- }
- }
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- */
- protected UIInputInfo(final ComponentInfo parent,
- final ComponentTypeInfo typeInfo, Map attributes)
- {
- this(getStringProperty("id", attributes, true), parent, typeInfo, //$NON-NLS-1$
- getEditableValueHolderInfo("$editableValueHolderInfo", //$NON-NLS-1$
- attributes), getBooleanProperty("rendered", attributes, false)); //$NON-NLS-1$
- }
-
- private static IEditableValueHolderInfo getEditableValueHolderInfo(
- String key, Map attributes)
- {
- return (IEditableValueHolderInfo) attributes.get(key);
- }
-
- // public String toString() {
- // final String toString = super.toString();
- // return toString + ", isValid=" + _isValid + ", isImmediate="
- // + _isImmediate + ", isRequired=" + _isRequired;
- // }
-
- // @Override
- protected String getMostSpecificComponentName()
- {
- return "UIInput"; //$NON-NLS-1$
- }
-
- public final boolean isValid()
- {
- return _isValid;
- }
-
- public final boolean isImmediate()
- {
- return _isImmediate;
- }
-
- public final boolean isRequired()
- {
- return _isRequired;
- }
-
- public final Object getSubmittedValue()
- {
- return _submittedValue;
- }
-
- public final String getValidator()
- {
- return _validator;
- }
-
- public final String getValueChangeListener()
- {
- return _valueChangeListener;
- }
-
- public final boolean isLocalSetValue()
- {
- return _localSetValue;
- }
-
- public final void addValidator(final ValidatorDecorator validator)
- {
- addDecorator(validator, ComponentFactory.VALIDATOR);
- }
-
- public final void addValueChangeListener(
- final ValueChangeListenerDecorator valueChangeListenerInfo)
- {
- addDecorator(valueChangeListenerInfo,
- ComponentFactory.VALUE_CHANGE_LISTENER);
- }
-
- public final List getValidators()
- {
- return getDecorators(ComponentFactory.VALIDATOR);
- }
-
- public final List getValueChangeListeners()
- {
- return getDecorators(ComponentFactory.VALUE_CHANGE_LISTENER);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIOutputInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIOutputInfo.java
deleted file mode 100644
index 990028a45..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/component/UIOutputInfo.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.component;
-
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.IValueHolderInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.behavioural.ValueHolderInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-
-/**
- * A design-time analog for the UIOutput
- *
- * @author cbateman
- *
- */
-public class UIOutputInfo extends ComponentInfo implements IValueHolderInfo {
- /**
- * serializable uid
- */
- private static final long serialVersionUID = 9096297578991706150L;
-
- /**
- * the value
- */
- protected final Object _value;
- /**
- * the value before any EL evaluation
- */
- protected final Object _localValue;
-
- /**
- * @param id
- * @param parent
- * @param typeInfo
- * @param valueHolderInfo
- * @param isRendered
- */
- protected UIOutputInfo(final String id, final ComponentInfo parent,
- final ComponentTypeInfo typeInfo,
- final IValueHolderInfo valueHolderInfo, final boolean isRendered) {
- super(id, parent, typeInfo, isRendered);
-
- if (valueHolderInfo == null) {
- _value = null;
- _localValue = null;
- } else {
- _value = valueHolderInfo.getValue();
- _localValue = valueHolderInfo.getLocalValue();
-
- final ConverterDecorator converter = valueHolderInfo.getConverter();
- if (converter != null) {
- addDecorator(converter, ComponentFactory.CONVERTER);
- }
- }
- }
-
- /**
- * @param parent
- * @param typeInfo
- * @param attributes
- */
- protected UIOutputInfo(final ComponentInfo parent, final ComponentTypeInfo typeInfo,
- final Map attributes)
- {
- this(getStringProperty("id", attributes, true), //$NON-NLS-1$
- parent,
- typeInfo,
- getValueHolderInfo("$valueHolderInfo", attributes), //$NON-NLS-1$
- getBooleanProperty("rendered", attributes, false)); //$NON-NLS-1$
- }
-
- /**
- * @param key
- * @param attributes
- * @return the non-standard value holder info that encapsulates the
- * ValueHolder properties. This is never mandatory.
- */
- protected static IValueHolderInfo getValueHolderInfo(String key, Map attributes)
- {
- IValueHolderInfo info = (IValueHolderInfo) attributes.get(key);
-
- if (info != null)
- {
- return info;
- }
- Object value = attributes.get("value"); //$NON-NLS-1$
- if (value != null)
- {
- Object converter = attributes.get("converter"); //$NON-NLS-1$
- Object localValue = attributes.get("localValue"); //$NON-NLS-1$
-
- return new ValueHolderInfo((ConverterDecorator) converter, localValue, value);
- }
- return null;
- }
-
- // @Override
- protected String getMostSpecificComponentName() {
- return "UIOutput"; //$NON-NLS-1$
- }
-
- public final ConverterDecorator getConverter() {
- // should only be a single converter decorator...
- // so on this interface we'll return the first one if present.
- // to do things like error checking, use the getDecorator
- final List converters = getDecorators(ComponentFactory.CONVERTER);
-
- if (converters.size() > 0) {
- return (ConverterDecorator) converters.get(0);
- }
-
- return null;
- }
-
- public final Object getLocalValue() {
- return _localValue;
- }
-
- public final Object getValue() {
- return _value;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/datatypes/ELExpression.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/datatypes/ELExpression.java
deleted file mode 100644
index b14f68d11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/datatypes/ELExpression.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.datatypes;
-
-/**
- * An abstraction for an EL expression.
- *
- * @author cbateman
- *
- */
-public abstract class ELExpression
-{
- /**
- * @return the original text of EL expression
- */
- public abstract String getText();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ActionListenerDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ActionListenerDecorator.java
deleted file mode 100644
index 6c7993e7e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ActionListenerDecorator.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * Design time ActionListener decorator
- *
- * @author cbateman
- *
- */
-public class ActionListenerDecorator extends ComponentDecorator {
-
- /**
- *
- */
- private static final long serialVersionUID = 3806862878381550874L;
-
- /**
- * @param decorates
- */
- public ActionListenerDecorator(final ComponentInfo decorates) {
- super(decorates);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ComponentDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ComponentDecorator.java
deleted file mode 100644
index b700073a4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ComponentDecorator.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * @author cbateman
- *
- */
-public abstract class ComponentDecorator extends Decorator
-{
- /**
- *
- */
- private static final long serialVersionUID = 4378142984217256364L;
-
- private final ComponentInfo _decorates;
-
- /**
- * @param decorates
- */
- public ComponentDecorator(final ComponentInfo decorates)
- {
- _decorates = decorates;
- }
-
- /**
- * @return the component that this decorator decorates.
- */
- public final ComponentInfo getDecorates() {
- return _decorates;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterDecorator.java
deleted file mode 100644
index 692ec3b3d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterDecorator.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * A converter decorator.
- *
- * @author cbateman
- *
- */
-public class ConverterDecorator extends ComponentDecorator {
-
- private final ConverterTypeInfo _typeInfo;
-
- /**
- * serializable id
- */
- private static final long serialVersionUID = 3838224353030247227L;
-
-
- /**
- * @param decorates
- * @param typeInfo
- */
- public ConverterDecorator(final ComponentInfo decorates, final ConverterTypeInfo typeInfo)
- {
- super(decorates);
- _typeInfo = typeInfo;
- }
-
- /**
- * @return the converter's type info.
- */
- public final ConverterTypeInfo getTypeInfo()
- {
- return _typeInfo;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterTypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterTypeInfo.java
deleted file mode 100644
index f013d3caf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ConverterTypeInfo.java
+++ /dev/null
@@ -1,146 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.types.ClassTypeInfo;
-
-/**
- * Type information about a converter.
- *
- * @author cbateman
- *
- */
-public class ConverterTypeInfo extends ClassTypeInfo
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = -7238952424045449907L;
- private static final String[] NO_FOR_CLASS = new String[0];
- private final String _converterId;
- private final String[] _forClasses;
-
- /**
- * For unknown converters, use the UNKNOWN constant.
- *
- * @param className
- * @param converterId
- * @throws java.lang.IllegalArgumentException
- * if both className and converterId are null.
- *
- */
- public ConverterTypeInfo(String className, String converterId)
- {
- super(className, new String[0], new String[0]);
- if (className == null && converterId == null)
- {
- throw new IllegalArgumentException(
- "converterClass and converterId must not both be null. For unknown validator use the UNKNOWN constant"); //$NON-NLS-1$
- }
-
- _converterId = converterId;
- _forClasses = NO_FOR_CLASS;
- }
-
- /**
- * For unknown converters, use the UNKNOWN constant.
- *
- * @param className
- * @param superClasses
- * @param interfaces
- * @param converterId
- * @param forClass
- * @throws java.lang.IllegalArgumentException
- * if both className and converterId are null.
- *
- */
- public ConverterTypeInfo(String className, String[] superClasses,
- String[] interfaces, String converterId, String[] forClass)
- {
- super(className, superClasses, interfaces);
- if (className == null && converterId == null)
- {
- throw new IllegalArgumentException(
- "converterClass and converterId must not both be null. For unknown validator use the UNKNOWN constant"); //$NON-NLS-1$
- }
-
- _converterId = converterId;
- if (forClass == null)
- {
- _forClasses = NO_FOR_CLASS;
- }
- else
- {
- _forClasses = forClass;
- }
- }
-
- /**
- * Use when the converter's information unknown such as occurs when using
- * the f:converter tag.
- */
- public static final ConverterTypeInfo UNKNOWN = new ConverterTypeInfo(
- (Object) null);
-
- /**
- * A private constructor used to create the UNRESOLVED constant. We use an
- * Object arg here (which is discarded) rather than using the zero-arg
- * constructor so as not mess up anything like Serializable that may depend
- * on how zero-arg constructors are defined.
- *
- * @param unresolved
- */
- private ConverterTypeInfo(Object unresolved)
- {
- super(null, new String[0], new String[0]);
- _converterId = null;
- _forClasses = NO_FOR_CLASS;
- }
-
- /**
- * @return the converter's id.
- */
- public final String getConverterId()
- {
- return _converterId;
- }
-
- /**
- * @return a copy of the listof classes that this type converters to. May
- * be empty. Never null.
- */
- public final String[] getForClass()
- {
- final String[] returnArray = new String[_forClasses.length];
- System.arraycopy(_forClasses, 0, returnArray, 0, _forClasses.length);
- return returnArray;
- }
-
- public String toString()
- {
- String toString = ""; //$NON-NLS-1$
-
- if (_forClasses.length > 0)
- {
- toString = "For-Classes: ["; //$NON-NLS-1$
- for (int i = 0; i < _forClasses.length; i++)
- {
- toString += _forClasses[i];
- if (i < _forClasses.length-1)
- {
- toString += ", "; //$NON-NLS-1$
- }
- }
- toString += "], "; //$NON-NLS-1$
- }
- return toString + "Converter Type Info: type = " + _converterId + ", "+super.toString(); //$NON-NLS-1$ //$NON-NLS-2$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/Decorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/Decorator.java
deleted file mode 100644
index ceaae4e4f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/Decorator.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import java.io.Serializable;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.ViewObject;
-
-/**
- * The abstract super-class of all view object decorators.
- *
- * @author cbateman
- *
- */
-public abstract class Decorator extends ViewObject implements Serializable
-{
-
- /**
- * serializable id
- */
- private static final long serialVersionUID = -3138829736243154022L;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/FacetDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/FacetDecorator.java
deleted file mode 100644
index 32e7f0dc5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/FacetDecorator.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * Component decorator for facets.
- *
- * @author cbateman
- *
- */
-public class FacetDecorator extends ComponentDecorator
-{
- /**
- *
- */
- private static final long serialVersionUID = 94806944978127012L;
-
- private final String _name;
-
- /**
- * @param name
- * @param component
- */
- public FacetDecorator(final String name, final ComponentInfo component) {
- super(component);
- _name = name;
- }
-
- /**
- * @return the name of the facet.
- */
- public final String getName() {
- return _name;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorDecorator.java
deleted file mode 100644
index b7e33d03c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorDecorator.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-
-/**
- * Validator decorator.
- *
- * @author cbateman
- *
- */
-public class ValidatorDecorator extends ComponentDecorator {
- /**
- *
- */
- private static final long serialVersionUID = -2898015711621314782L;
-
- private final ValidatorTypeInfo _typeInfo;
-
- /**
- * @param decorates
- * @param typeInfo
- */
- public ValidatorDecorator(final ComponentInfo decorates, final ValidatorTypeInfo typeInfo) {
- super(decorates);
- _typeInfo = typeInfo;
- }
-
- /**
- * @return the validator's type info
- */
- public final ValidatorTypeInfo getTypeInfo()
- {
- return _typeInfo;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorTypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorTypeInfo.java
deleted file mode 100644
index 7e4a6fcee..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValidatorTypeInfo.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.types.ClassTypeInfo;
-
-/**
- * Type information about validator decorator.
- * @author cbateman
- *
- */
-public class ValidatorTypeInfo extends ClassTypeInfo
-{
- /**
- *
- */
- private static final long serialVersionUID = 7512992316792276160L;
- private final String _validatorId;
-
- /**
- * For unknown validators, use the UNKNOWN constant.
- *
- * @param validatorClass
- * @param validatorId
- * @throws java.lang.IllegalArgumentException if both className and
- * converterId are null.
- *
- */
- public ValidatorTypeInfo(String validatorClass, String validatorId)
- {
- super(validatorClass, new String[0], new String[0]);
-
- if (validatorClass == null && validatorId == null)
- {
- throw new IllegalArgumentException("validatorClass and validatorId must not both be null. For unknown validator use the UNKNOWN constant"); //$NON-NLS-1$
- }
- _validatorId = validatorId;
- }
-
- /**
- * For unknown validators, use the UNKNOWN constant.
- *
- * @param validatorClass
- * @param superClasses
- * @param interfaces
- * @param validatorId
- * @throws java.lang.IllegalArgumentException if both className and
- * converterId are null.
- *
- */
- public ValidatorTypeInfo(String validatorClass, String[] superClasses, String[] interfaces, String validatorId)
- {
- super(validatorClass, superClasses, interfaces);
-
- if (validatorClass == null && validatorId == null)
- {
- throw new IllegalArgumentException("validatorClass and validatorId must not both be null. For unknown validator use the UNKNOWN constant"); //$NON-NLS-1$
- }
- _validatorId = validatorId;
- }
-
- /**
- * Use when a validator's type info information is unknown.
- */
- public static final ValidatorTypeInfo UNKNOWN =
- new ValidatorTypeInfo((Object)null);
-
- /**
- * A private constructor used to create the UNRESOLVED constant.
- * We use an Object arg here (which is discarded) rather than using
- * the zero-arg constructor so as not mess up anything like Serializable
- * that may depend on how zero-arg constructors are defined.
- *
- * @param unresolved
- */
- private ValidatorTypeInfo(Object unresolved)
- {
- super(null, new String[0], new String[0]);
- _validatorId = null;
- }
-
- /**
- * @return the validator id (may be null if unknown).
- */
- public final String getValidatorId()
- {
- return _validatorId;
- }
-
- public String toString()
- {
- return "Validator Type Info: type = " + _validatorId + ", "+super.toString(); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValueChangeListenerDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValueChangeListenerDecorator.java
deleted file mode 100644
index e344c1ec3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/decorator/ValueChangeListenerDecorator.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.decorator;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.event.IValueChangeListenerInfo;
-
-/**
- * ValueChangeListener component decorator.
- *
- * @author cbateman
- *
- */
-public class ValueChangeListenerDecorator extends ComponentDecorator implements
- IValueChangeListenerInfo
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = 9045831927898936727L;
-
- /**
- * @param decorates
- */
- public ValueChangeListenerDecorator(ComponentInfo decorates) {
- super(decorates);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IActionListenerInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IActionListenerInfo.java
deleted file mode 100644
index a26b3a1d2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IActionListenerInfo.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.event;
-
-/**
- * A design time analog for the ActionListener
- * @author cbateman
- *
- */
-public interface IActionListenerInfo extends IFacesListenerInfo
-{
- // TODO:
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IFacesListenerInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IFacesListenerInfo.java
deleted file mode 100644
index b8996d40a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IFacesListenerInfo.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.event;
-
-/**
- * A design-time analog for the runtime Faces Listener.
- * @author cbateman
- *
- */
-public interface IFacesListenerInfo
-{
- // no methods
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IValueChangeListenerInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IValueChangeListenerInfo.java
deleted file mode 100644
index 3d21a7a3d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/event/IValueChangeListenerInfo.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.event;
-
-/**
- * A design time analog for the runtime ValueChangeListener interface.
- *
- * @author cbateman
- *
- */
-public interface IValueChangeListenerInfo extends IFacesListenerInfo {
- // TODO:
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/ClassTypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/ClassTypeInfo.java
deleted file mode 100644
index 4a39bc0b3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/ClassTypeInfo.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.types;
-
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Set;
-
-/**
- * A type info that has class information.
- *
- * @author cbateman
- *
- */
-public abstract class ClassTypeInfo extends TypeInfo implements IClassTypeInfo
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = -5046230589012357680L;
-
- /**
- * the fully qualified class name of the implementation class for this
- * type.
- */
- protected final String _className;
-
- /**
- * known super classes of the component class
- */
- protected final String[] _superClasses;
-
- /**
- * known interfaces implemented by the component class
- */
- protected final String[] _interfaces;
-
- /**
- * used internally by isInstanceOf
- */
- private Set _superTypes; // may be lazily constructed
-
-
- /**
- * @param className
- * @param superClasses
- * @param interfaces
- */
- protected ClassTypeInfo(final String className, final String[] superClasses, final String[] interfaces)
- {
- _className = className;
- _superClasses = superClasses != null ? superClasses : new String[0];
- _interfaces = interfaces != null ? interfaces : new String[0];
-
- if (_superClasses.length + _interfaces.length == 0)
- {
- // there are no super-types known
- _superTypes = Collections.EMPTY_SET;
- }
- }
-
- public final String[] getInterfaces()
- {
- if (_interfaces.length > 0)
- {
- final String[] copy = new String[_interfaces.length];
- System.arraycopy(_interfaces, 0, copy, 0, _interfaces.length);
- return copy;
- }
- return new String[0];
- }
-
- public final String[] getSuperClasses()
- {
- if (_superClasses.length > 0)
- {
- final String[] copy = new String[_superClasses.length];
- System.arraycopy(_superClasses, 0, copy, 0, _superClasses.length);
- return copy;
- }
- return new String[0];
- }
-
- public final boolean isInstanceOf(String checkType)
- {
- if (_superTypes == null)
- {
- _superTypes = new HashSet();
- _superTypes.addAll(Arrays.asList(_superClasses));
- _superTypes.addAll(Arrays.asList(_interfaces));
- }
-
- return _superTypes.contains(checkType);
- }
-
- public final String getClassName()
- {
- return _className;
- }
-
- public String toString()
- {
- String supers = "["; //$NON-NLS-1$
-
- for (int i = 0; i < _superClasses.length; i++)
- {
- supers += _superClasses[i];
-
- if (i < _superClasses.length)
- {
- supers += ","; //$NON-NLS-1$
- }
- }
-
- for (int i = 0; i < _interfaces.length; i++)
- {
- supers += _interfaces[i];
-
- if (i < _interfaces.length-1)
- {
- supers += ","; //$NON-NLS-1$
- }
- }
- supers +="]"; //$NON-NLS-1$
-
- return "class= "+getClassName()+ ", supers="+ supers; //$NON-NLS-1$ //$NON-NLS-2$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IAttributeValueProxy.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IAttributeValueProxy.java
deleted file mode 100644
index 95b83db19..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IAttributeValueProxy.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.types;
-
-import java.io.Serializable;
-
-/**
- * Wraps
- * @author cbateman
- *
- */
-public interface IAttributeValueProxy extends Serializable
-{
-//
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IClassTypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IClassTypeInfo.java
deleted file mode 100644
index 7b432520c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/IClassTypeInfo.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.types;
-
-/**
- * A type info that has an associate Java class.
- * @author cbateman
- *
- */
-public interface IClassTypeInfo
-{
- /**
- * The fully qualified class name, i.e. java.lang.String
- *
- * @return the fully qualified class name in dot notation
- *
- */
- String getClassName();
-
- /**
- * Should never return null. Return empty array if none.
- *
- * @return the list of fully-qualified super class names. List is as
- * calculated at IClassTypeInfo construction and no guarantee is made
- * (although an implementer may do so) that it will be updated if the
- * definition of className changes.
- */
- String[] getSuperClasses();
-
- /**
- * Should never return null. Return empty array if none.
- *
- * @return the list of fully-qualified interface names. List is as
- * calculated at IClassTypeInfo construction and no guarantee is made
- * (although an implementer may do so) that it will be updated if the
- * definition of className changes.
- */
- String[] getInterfaces();
-
- /**
- * @param checkType
- * @return true if checkType is in the set comprised of getSuperClasses()+getInterfaces()
- */
- boolean isInstanceOf(final String checkType);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/TypeInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/TypeInfo.java
deleted file mode 100644
index 4061f4a9b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/model/types/TypeInfo.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.model.types;
-
-import java.io.Serializable;
-
-/**
- * Abstract super-class of all view object type information objects.
- *
- * @author cbateman
- *
- */
-public abstract class TypeInfo implements Serializable
-{
- /**
- * serializable id
- */
- private static final long serialVersionUID = -3653573923653759724L;
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ComponentPropertyHandler.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ComponentPropertyHandler.java
deleted file mode 100644
index aa505455b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ComponentPropertyHandler.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle Corporation.
- * 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:
- * Cameron Bateman - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-/**
- * Default implementation of IComponentPropertyHandler.
- *
- * @author cbateman
- *
- */
-public class ComponentPropertyHandler extends TagAttributeHandler implements
- IComponentPropertyHandler
-{
- /**
- *
- */
- private static final long serialVersionUID = 8614562842401106572L;
- private final String _propertyName;
-
- /**
- * @param customHandler
- * @param name
- * @param elAllowed
- * @param propertyName
- */
- public ComponentPropertyHandler(final String customHandler,
- final String name, final boolean elAllowed,
- final String propertyName)
- {
- super(customHandler, name, elAllowed);
- _propertyName = propertyName;
- }
-
- public String getPropertyName()
- {
- return _propertyName;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentPropertyHandler.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentPropertyHandler.java
deleted file mode 100644
index dfcaf79cc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentPropertyHandler.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) ${year} Oracle Corporation.
- * 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:
- * Cameron Bateman - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-/**
- * Maps tag attributes to component properties.
- *
- * @author cbateman
- *
- */
-public interface IComponentPropertyHandler extends ITagAttributeHandler
-{
- /**
- * @return the property name that this handler maps to.
- */
- String getPropertyName();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentTagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentTagElement.java
deleted file mode 100644
index d34cb2ff7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IComponentTagElement.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentTypeInfo;
-
-/**
- * A JSF tag element that maps one-to-one to a JSF UIComponent
- *
- * @author cbateman
- *
- */
-public interface IComponentTagElement extends IJSFTagElement
-{
- /**
- * @return the comopnent's type info.
- */
- ComponentTypeInfo getComponent();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IConverterTagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IConverterTagElement.java
deleted file mode 100644
index 63e43ada8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IConverterTagElement.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterTypeInfo;
-
-/**
- * A tag element that causes the construction registration of a converter on
- * a parent object.
- *
- * @author cbateman
- *
- */
-public interface IConverterTagElement extends IJSFTagElement
-{
- /**
- * @return the type info for the converter represented by this
- * element
- */
- ConverterTypeInfo getConverter();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IHandlerTagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IHandlerTagElement.java
deleted file mode 100644
index 43e68283d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IHandlerTagElement.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.io.Serializable;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.types.TypeInfo;
-
-/**
- * Generic tag handler that has effect when processed by the JSF ViewHandler.
- *
- * @author cbateman
- *
- */
-public interface IHandlerTagElement extends IJSFTagElement
-{
- /**
- * Enumerates known types of built-in tag handlers.
- *
- * @author cbateman
- *
- */
- static class TagHandlerType extends TypeInfo implements Serializable
- {
- /**
- * serializable id
- */
- private static final long serialVersionUID = 5062853948108253861L;
-
- private final static int HANDLER_TYPE_FACET = 0;
- private final static int HANDLER_TYPE_ACTIONLISTENER = 1;
- private final static int HANDLER_TYPE_VALUECHANGELISTENER = 2;
- private final static int HANDLER_TYPE_ATTRIBUTE = 3;
-
- private final static String[] strValues =
- {"facet", "actionListener", "valueChangeListener"}; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
-
- private final int _intValue;
-
- public TagHandlerType(int intValue)
- {
- _intValue = intValue;
- }
-
- public String toString()
- {
- return strValues[_intValue];
- }
-
- protected final int intValue()
- {
- return _intValue;
- }
-
- public final static TagHandlerType FACET =
- new TagHandlerType(HANDLER_TYPE_FACET);
- public final static TagHandlerType ACTIONLISTENER =
- new TagHandlerType(HANDLER_TYPE_ACTIONLISTENER);
- public final static TagHandlerType VALUECHANGELISTENER =
- new TagHandlerType(HANDLER_TYPE_VALUECHANGELISTENER);
- public final static TagHandlerType ATTRIBUTE =
- new TagHandlerType(HANDLER_TYPE_ATTRIBUTE);
-
- }
-
- /**
- * @return the tag handler type as defined by standard known types of
- * tags that do not (necessarily) translate into standard objects at
- * runtime but may modify the view in some way.
- */
- TagHandlerType getTagHandlerType();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IJSFTagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IJSFTagElement.java
deleted file mode 100644
index 435c08abd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IJSFTagElement.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.io.Serializable;
-
-/**
- * An abstraction of a tag element that maps to a JSF artifact (i.e. component, validator)
- *
- * @author cbateman
- *
- */
-public interface IJSFTagElement extends ITagElement
-{
- /**
- * An enumeration of different kinds of tags.
- *
- * @author cbateman
- *
- */
- static class TagType implements Serializable
- {
- /**
- * serializable id
- */
- private static final long serialVersionUID = -2845327764902349963L;
- private final static int TYPE_COMPONENT = 0;
- private final static int TYPE_CONVERTER = 1;
- private final static int TYPE_VALIDATOR = 2;
- private final static int TYPE_HANDLER = 3;
- //private final static int TYPE_UNKNOWN = 4;
-
- private final static String[] strValues =
- {"component", "converter", "validator", "handler"}; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
-
- private final int _intValue;
-
- public TagType(int intValue)
- {
- _intValue = intValue;
- }
-
- public String toString()
- {
- return strValues[_intValue];
- }
-
- protected final int intValue()
- {
- return _intValue;
- }
-
- public final static TagType COMPONENT =
- new TagType(TYPE_COMPONENT);
- public final static TagType CONVERTER =
- new TagType(TYPE_CONVERTER);
- public final static TagType VALIDATOR =
- new TagType(TYPE_VALIDATOR);
- public final static TagType HANDLER =
- new TagType(TYPE_HANDLER);
- }
-
- /**
- * @return the type of tag as distinguished by how it may affect the
- * view at runtime.
- */
- TagType getType();
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagAttributeHandler.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagAttributeHandler.java
deleted file mode 100644
index f6d15c9ab..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagAttributeHandler.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) ${year} Oracle Corporation.
- * 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:
- * Cameron Bateman - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.io.Serializable;
-
-/**
- * Basic information on attributes.
- * TODO C.B: some question exists in my mind as to how/whether this should merge
- * with meta-data enabled type descriptors.
- *
- * @author cbateman
- *
- */
-public interface ITagAttributeHandler extends Serializable
-{
- /**
- * @return the name of the attribute
- */
- String getName();
- /**
- * @return the name of an extension point used to perform custom handling
- * of the attribute.
- */
- String getCustomHandler();
-
- /**
- * @return true if the property allows EL expressions
- */
- boolean isELAllowed();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagElement.java
deleted file mode 100644
index 23a8098ea..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/ITagElement.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.io.Serializable;
-import java.util.Map;
-
-/**
- * Super-interface of all JSF tag elements.
- *
- * @author cbateman
- *
- */
-public interface ITagElement extends Serializable
-{
-
- /**
- * @return the name of the tag
- */
- public abstract String getName();
-
- /**
- * @return the namespace uri for this tag
- */
- public abstract String getUri();
-
- /**
- * @return the fully qualified class name in dot separated format
- * (i.e. javax.faces.webapp.ConverterTag)
- */
- public abstract String getTagHandlerClassName();
-
- /**
- * @return an unmodifiable map, indexed by name, of all the attribute
- * handlers available for this tag element. Each value in the Map
- * must be a ITagAttributeHandler.
- */
- public abstract Map getAttributeHandlers();
-
- /**
- * Signals that the tag element should make any mutable data immutable
- * and throw exceptions if attempts are made to implement. Flag must
- * latch and become irrevocable.
- */
-// public abstract void setLocked();
-
- /**
- * @return true if setLocked has been called.
- */
-// public abstract boolean isLocked();
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IValidatorTagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IValidatorTagElement.java
deleted file mode 100644
index 947490287..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/IValidatorTagElement.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorTypeInfo;
-
-/**
- * Represents a tag element for a JSF validator.
- *
- * @author cbateman
- *
- */
-public interface IValidatorTagElement extends IJSFTagElement
-{
- /**
- * @return the type info about the validator.
- */
- ValidatorTypeInfo getValidator();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/Namespace.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/Namespace.java
deleted file mode 100644
index aabf975f0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/Namespace.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.io.Serializable;
-import java.util.Collection;
-
-/**
- * Abstracts an xml namespace used to define a set of view tags
- *
- */
-public abstract class Namespace implements Serializable
-{
- /**
- *
- */
- private static final long serialVersionUID = 6386464282396970948L;
-
- /**
- * @return the namespace uri. MUST NOT BE NULL
- */
- public abstract String getNSUri();
-
- /**
- * This call may be long running. Call isInitialized to determine if all
- * information is already cached, or if calling this method is likely
- * to take a long time.
- *
- * @return the view elements in this namespace. May be empty but MUST NOT BE
- * NULL.
- */
- public abstract Collection getViewElements();
-
- /**
- * This method should be light weight if possible. Unlike calling
- * getViewElements().isEmpty, this call should not require that all
- * view element children of this namespace be analyzed and constructed in
- * order to succeed.
- *
- * @return true if this name space has view element children
- */
- public abstract boolean hasViewElements();
-
- /**
- * If calculating all view elements is expensive, a Namespace implementation
- * may defer calculation until a specific element is requested. A caller of
- * getViewElements (such as a UI that shows all tags), may wish to know if
- * the entire namespace has been initialized before calling it, since it may
- * be long running.
- *
- * @return true if the namespace's elements have been fully initialized. If this
- * method returns false, care should be taken in calling getViewElements() and
- * getViewElement() since they may be very long running.
- */
- public abstract boolean isInitialized();
-
- /**
- * @param name
- * @return the tag element called 'name' or null if none.
- */
- public abstract ITagElement getViewElement(final String name);
-
- /**
- * @return a user readable display name for this namespace or null if none.
- */
- public abstract String getDisplayName();
-
- public String toString()
- {
- return getNSUri();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagAttributeHandler.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagAttributeHandler.java
deleted file mode 100644
index b29349515..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagAttributeHandler.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************
- * Copyright (c) ${year} Oracle Corporation.
- * 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:
- * Cameron Bateman - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-/**
- * Default implementation of ITagAttributeHandler.
- *
- * @author cbateman
- *
- */
-public class TagAttributeHandler implements ITagAttributeHandler
-{
- /**
- *
- */
- private static final long serialVersionUID = 8153903018703133004L;
- private final String _customHandler;
- private final String _name;
- private final boolean _elAllowed;
-
- /**
- * @param customHandler
- * @param name
- * @param elAllowed
- */
- public TagAttributeHandler(final String customHandler, final String name,
- final boolean elAllowed)
- {
- super();
- _customHandler = customHandler;
- _elAllowed = elAllowed;
- _name = name;
- }
-
- public String getCustomHandler()
- {
- return _customHandler;
- }
-
- public String getName()
- {
- return _name;
- }
-
- public boolean isELAllowed()
- {
- return _elAllowed;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagElement.java b/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagElement.java
deleted file mode 100644
index fb04e6f77..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.runtime/src/org/eclipse/jst/jsf/common/runtime/internal/view/model/common/TagElement.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.runtime.internal.view.model.common;
-
-import java.util.Map;
-
-/**
- * Abstract a tag element used to construct a view element
- *
- * @author cbateman
- *
- */
-public abstract class TagElement implements ITagElement
-{
- /**
- *
- */
- private static final long serialVersionUID = 7885641652240047924L;
-
- /* (non-Javadoc)
- * @see viewhandlerprototype.model.ITagElement#getName()
- */
- public abstract String getName();
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.common.runtime.internal.view.model.common.ITagElement#getUri()
- */
- public abstract String getUri();
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.common.runtime.internal.view.model.common.ITagElement#getTagHandlerClassName()
- */
- public abstract String getTagHandlerClassName();
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.common.runtime.internal.view.model.common.ITagElement#getAttributeHandlers()
- */
- public abstract Map getAttributeHandlers();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.cvsignore
deleted file mode 100644
index 2a89e4b88..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.cvsignore
+++ /dev/null
@@ -1,4 +0,0 @@
-bin
-@dot
-build.xml
-javaCompiler...args
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.project b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.project
deleted file mode 100644
index 9615dd9c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.common.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/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 9334e139c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,82 +0,0 @@
-#Mon Jun 30 15:55:16 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-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.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=warning
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=ignore
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
-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=warning
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-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=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
-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=ignore
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=error
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.ui.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 82eb6c152..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Fri Apr 06 18:25:15 PDT 2007
-eclipse.preferences.version=1
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates/>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index d9b486b97..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 11:46:32 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.common.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index 37bfbaee5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,36 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jst.jsf.common.ui;singleton:=true
-Bundle-Version: 1.1.1.qualifier
-Bundle-Activator: org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.cheatsheets;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.help;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.core;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.resources;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.forms;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.ui.ide;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.draw2d;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jface.text;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jst.j2ee;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.common.emf;bundle-version="[1.1.103,2.0.0)",
- org.eclipse.wst.common.project.facet.core;bundle-version="[1.2.0,2.0.0)",
- org.eclipse.emf;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.emf.common;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.0.1,2.0.0)"
-Export-Package: org.eclipse.jst.jsf.common.ui;x-friends:="org.eclipse.jst.pagedesigner,org.eclipse.jst.pagedesigner.jsf.ui",
- org.eclipse.jst.jsf.common.ui.internal.actions;x-friends:="org.eclipse.jst.jsf.facesconfig.ui",
- org.eclipse.jst.jsf.common.ui.internal.dialogfield;x-friends:="org.eclipse.jst.pagedesigner,org.eclipse.jst.pagedesigner.jsf.ui",
- org.eclipse.jst.jsf.common.ui.internal.dialogs;x-friends:="org.eclipse.jst.pagedesigner",
- org.eclipse.jst.jsf.common.ui.internal.form;x-internal=true,
- org.eclipse.jst.jsf.common.ui.internal.guiutils;x-friends:="org.eclipse.jst.pagedesigner",
- org.eclipse.jst.jsf.common.ui.internal.logging;x-friends:="org.eclipse.jst.pagedesigner,org.eclipse.jst.pagedesigner.jsf.ui",
- org.eclipse.jst.jsf.common.ui.internal.preferences;x-internal=true,
- org.eclipse.jst.jsf.common.ui.internal.utils;x-friends:="org.eclipse.jst.pagedesigner,org.eclipse.jst.jsf.facesconfig.ui,org.eclipse.jst.pagedesigner.jsf.ui"
-Bundle-ActivationPolicy: lazy
-Bundle-Vendor: %pluginProvider
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.html b/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.html
deleted file mode 100644
index 3b20a3638..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.ini b/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.ini
deleted file mode 100644
index a21a3ecea..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.ini
+++ /dev/null
@@ -1,29 +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=eclipse32.gif
-
-# Property "aboutImage" contains path to product image (500x330 or 115x164)
-# needed for primary features only
-
-# Property "appName" contains name of the application (translated)
-# needed for primary features only
-
-# Property "welcomePage" contains path to welcome page (special XML-based format)
-# optional
-
-# Property "welcomePerspective" contains the id of the perspective in which the
-# welcome page is to be opened.
-# optional
-
-
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.mappings b/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.mappings
deleted file mode 100644
index 29ddddb7e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/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=200509071822 \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.properties
deleted file mode 100644
index d7849b83b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/about.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2004, 2005 Sybase, Inc. 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:
-# Sybase, Inc. - 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=JSF Faces Config Editor \n\
-\n\
-Version: {featureVersion}\n\
-Build id: {0}\n\
-\n\
-(c) Copyright Eclipse contributors and others. 2000, 2004. All rights reserved.\n\
-Visit http://www.eclipse.org/webtools/jsf
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties
deleted file mode 100644
index 252400474..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- about.html,\
- about.ini,\
- about.mappings,\
- about.properties,\
- bin/,\
- build.properties,\
- default.properties,\
- eclipse32.gif,\
- icons/,\
- plugin.properties,\
- schema/
-javacSource=1.5
-javacTarget=1.5 \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/default.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/default.properties
deleted file mode 100644
index 82c53586d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/default.properties
+++ /dev/null
@@ -1,52 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-# This file contains all the Default Preference Settings
-
-####################################################
-# Logging Preference Settings
-####################################################
-
-# Enable/Disable console logging.
-# Valid values: TRUE, FALSE
-console.logging.on=true
-
-# Maximum log level of console logging.
-# Valid values: DEBUG, INFO, WARN, ERROR, FATAL
-console.logging.max.level=INFO
-
-# Enable/Disable eclipse logging.
-# Valid values: TRUE, FALSE
-eclipse.logging.on=true
-
-# Maximum log level of eclipse logging.
-# Valid values: DEBUG, INFO, WARN, ERROR, FATAL
-eclipse.logging.max.level=INFO
-
-eclipse.pattern=%m
-
-# Enable/Disable file logging.
-# Valid values: TRUE, FALSE
-file.logging.on=true
-
-# Maximum log level of file logging.
-# Valid values: DEBUG, INFO, WARN, ERROR, FATAL
-file.logging.max.level=DEBUG
-
-# Clear log file when eclipse restarts.
-# Valid values: TRUE, FALSE
-file.logging.startup.clear=true
-
-# Location of log file
-file.logging.path=facesconfigeditor.log
-
-# Rollover frequency of log file.
-# Valid values: DAILY, WEEKLY, MONTHLY
-file.logging.rollover.frequency=DAILY
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/eclipse32.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/eclipse32.gif
deleted file mode 100644
index e6ad7ccd7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/eclipse32.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/Editor_Help.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/Editor_Help.gif
deleted file mode 100644
index 03f656f3e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/Editor_Help.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_GotoEditor.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_GotoEditor.gif
deleted file mode 100644
index 0e5bcf65a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_GotoEditor.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Introduction.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Introduction.gif
deleted file mode 100644
index 44cd0448b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Introduction.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Tutorial.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Tutorial.gif
deleted file mode 100644
index ad8e5b6b9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/FacesConfig_Tutorial.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/PD_Palette_Default.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/PD_Palette_Default.gif
deleted file mode 100644
index 5e7fb3339..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/PD_Palette_Default.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/back_nav_16.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/back_nav_16.gif
deleted file mode 100644
index 740419b4a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/back_nav_16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/configs.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/configs.gif
deleted file mode 100644
index c984fba70..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/configs.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/form_banner.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/form_banner.gif
deleted file mode 100644
index aebc0b2a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/form_banner.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/forward_nav_16.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/forward_nav_16.gif
deleted file mode 100644
index 7a1511dd8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/forward_nav_16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/help.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/help.gif
deleted file mode 100644
index 9d70301da..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/help.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_converter.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_converter.gif
deleted file mode 100644
index 16466edfd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_converter.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_validator.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_validator.gif
deleted file mode 100644
index 86196e996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_validator.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_view.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_view.gif
deleted file mode 100644
index c81630a08..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/jsf_view.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/object.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/object.gif
deleted file mode 100644
index 061161ae1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/object.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/overview_obj.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/overview_obj.gif
deleted file mode 100644
index 03f656f3e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/overview_obj.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/refresh_nav_16.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/refresh_nav_16.gif
deleted file mode 100644
index a063c230a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/refresh_nav_16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/reload_nav_16.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/reload_nav_16.gif
deleted file mode 100644
index d71dffff4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/reload_nav_16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/stop_nav_16.gif b/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/stop_nav_16.gif
deleted file mode 100644
index 4eb53ec41..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/icons/stop_nav_16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.properties
deleted file mode 100644
index 3549ea3bf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.properties
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-
-pluginName=JavaServer Faces Tools - Common UI
-pluginProvider=Eclipse.org
-
-extension-point.name.0 = Introduction Page
-extension-point.name.1 = OverviewPage
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.xml
deleted file mode 100644
index 435be3ad3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/plugin.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
- <extension-point id="introductionPage" name="%extension-point.name.0" schema="schema/introductionPage.exsd"/>
- <extension-point id="overviewPage" name="%extension-point.name.1" schema="schema/overviewPage.exsd"/>
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/introductionPage.exsd b/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/introductionPage.exsd
deleted file mode 100644
index d147b347a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/introductionPage.exsd
+++ /dev/null
@@ -1,213 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.jst.jsf.common.ui">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.jst.jsf.common.ui" id="introductionPage" name="Introduction Page"/>
- </appInfo>
- <documentation>
- The purpose of this extension point is to allow plug-ins to describe the contents and links on a introduction page of an editor.
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="introductionpage"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
- a fully qualified identifier of the target extension point.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string" use="required">
- <annotation>
- <documentation>
- identifier of the extension instance, this should be the same as the editor id.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
- an optional name of the extension instance. Normally this is the editor name.
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="introductionpage">
- <annotation>
- <documentation>
- The details for an introduction page for a specific plugins editor
- </documentation>
- </annotation>
- <complexType>
- <sequence>
- <element ref="introductionelement" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="name" type="string" use="required">
- <annotation>
- <documentation>
- The name of the page.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="description" type="string">
- <annotation>
- <documentation>
- A description for the page.
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="introductionelement">
- <annotation>
- <documentation>
- An element that make up a section of the page. Elements can contain Headers, Hyperlinks, Icons and text.
- </documentation>
- </annotation>
- <complexType>
- <attribute name="icon" type="string">
- <annotation>
- <documentation>
- An icon to display in the element. The icon should be 72x72 and will appear to the left of the headers, hyperlinks and text
- </documentation>
- <appInfo>
- <meta.attribute kind="resource"/>
- </appInfo>
- </annotation>
- </attribute>
- <attribute name="heading" type="string">
- <annotation>
- <documentation>
- A short heading for the element (optional)
- </documentation>
- </annotation>
- </attribute>
- <attribute name="text" type="string">
- <annotation>
- <documentation>
- The text description for the element
- </documentation>
- </annotation>
- </attribute>
- <attribute name="hyperlink" type="string">
- <annotation>
- <documentation>
- A hyperlink associated with the element. The hyperlink would normally execute the hyperlinkaction action
- </documentation>
- </annotation>
- </attribute>
- <attribute name="hyperlinkaction" type="string">
- <annotation>
- <documentation>
- The action associated with the hyperlink. This is an action that will be executed when the hyperlink is selected
- </documentation>
- <appInfo>
- <meta.attribute kind="java"/>
- </appInfo>
- </annotation>
- </attribute>
- <attribute name="actionparameters" type="string">
- <annotation>
- <documentation>
- Can be used to pass one or more parameters to the hyperlink action. Parameter must be space separated (optional)
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="since"/>
- </appInfo>
- <documentation>
- 1.0.0
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- &lt;extension
- id=&quot;org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor&quot;
- name=&quot;%pageflow.editor.intro.name&quot;
- point=&quot;org.eclipse.jst.jsf.facesconfig.ui.page.introductionPage&quot;&gt;
- &lt;introductionpage
- name=&quot;%pageflow.editor.intro.name&quot;
- description=&quot;%port.editor.intro.description&quot;&gt;
- &lt;introductionelement
- icon=&quot;icons/pageflow_72.gif&quot;
- heading=&quot;%pageflow.editor.intro.heading&quot;
- text=&quot;%pageflow.editor.intro.description&quot;&gt;
- &lt;/introductionelement&gt;
- &lt;introductionelement
- actionparameters=&quot;Pageflow.designerCheatSheet&quot;
- icon=&quot;icons/tutorials_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.LoadCheatSheetAction&quot;
- text=&quot;%pageflow.editor.intro.cheatsheets.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.cheatsheets.link&quot;&gt;
- &lt;/introductionelement&gt;
- &lt;introductionelement
- actionparameters=&quot;http://www.eclipse.org&quot;
- icon=&quot;icons/overview_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.LoadHelpAction&quot;
- text=&quot;%pageflow.editor.intro.help.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.help.link&quot;&gt;
- &lt;/introductionelement&gt;
- &lt;introductionelement
- actionparameters=&quot;overview&quot;
- icon=&quot;icons/gotoeditor_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.OpenPageAction&quot;
- text=&quot;%pageflow.editor.intro.start.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.start.link&quot;&gt;
- &lt;/introductionelement&gt;
- &lt;/introductionpage&gt;
- &lt;/extension&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
-
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
-
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
- Copyright (c) 2004, 2006 Sybase, Inc. and others. &lt;br&gt;
- All rights reserved. This program and the accompanying materials &lt;br&gt;
- are made available under the terms of the Eclipse Public License v1.0 &lt;br&gt;
- which accompanies this distribution, and is available at &lt;br&gt;
- http://www.eclipse.org/legal/epl-v10.html &lt;br&gt;
-
- Contributors: &lt;br&gt;
- Sybase, Inc. - initial API and implementation &lt;br&gt;
- </documentation>
- </annotation>
-
-</schema>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/overviewPage.exsd b/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/overviewPage.exsd
deleted file mode 100644
index c55436b40..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/schema/overviewPage.exsd
+++ /dev/null
@@ -1,213 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.jst.jsf.common.ui">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.jst.jsf.common.ui" id="overviewPage" name="Overview Page"/>
- </appInfo>
- <documentation>
- The purpose of this extension point is to allow plug-ins to describe the contents and links on a overview page of an editor.
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="overviewpage"/>
- </sequence>
- <attribute name="point" type="string" use="required">
- <annotation>
- <documentation>
- a fully qualified identifier of the target extension point.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="id" type="string" use="required">
- <annotation>
- <documentation>
- identifier of the extension instance, this should be the same as the editor id.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="name" type="string">
- <annotation>
- <documentation>
- an optional name of the extension instance. Normally this is the editor name.
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="overviewpage">
- <annotation>
- <documentation>
- The details for an overview page for a specific plugins editor
- </documentation>
- </annotation>
- <complexType>
- <sequence>
- <element ref="overviewelement" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="name" type="string" use="required">
- <annotation>
- <documentation>
- The name of the page.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="description" type="string">
- <annotation>
- <documentation>
- A description for the page.
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="overviewelement">
- <annotation>
- <documentation>
- An element that make up a section of the page. Elements can contain Headers, Hyperlinks, Icons and text.
- </documentation>
- </annotation>
- <complexType>
- <attribute name="icon" type="string">
- <annotation>
- <documentation>
- An icon to display in the element. The icon should be 72x72 and will appear to the left of the headers, hyperlinks and text
- </documentation>
- <appInfo>
- <meta.attribute kind="resource"/>
- </appInfo>
- </annotation>
- </attribute>
- <attribute name="heading" type="string">
- <annotation>
- <documentation>
- A short heading for the element (optional)
- </documentation>
- </annotation>
- </attribute>
- <attribute name="text" type="string">
- <annotation>
- <documentation>
- The text description for the element
- </documentation>
- </annotation>
- </attribute>
- <attribute name="hyperlink" type="string">
- <annotation>
- <documentation>
- A hyperlink associated with the element. The hyperlink would normally execute the hyperlinkaction action
- </documentation>
- </annotation>
- </attribute>
- <attribute name="hyperlinkaction" type="string">
- <annotation>
- <documentation>
- The action associated with the hyperlink. This is an action that will be executed when the hyperlink is selected
- </documentation>
- <appInfo>
- <meta.attribute kind="java"/>
- </appInfo>
- </annotation>
- </attribute>
- <attribute name="actionparameters" type="string">
- <annotation>
- <documentation>
- Can be used to pass one or more parameters to the hyperlink action. Parameter must be space separated (optional)
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <annotation>
- <appInfo>
- <meta.section type="since"/>
- </appInfo>
- <documentation>
- 1.0.0
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="examples"/>
- </appInfo>
- <documentation>
- &lt;extension
- id=&quot;org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor&quot;
- name=&quot;%pageflow.editor.intro.name&quot;
- point=&quot;org.eclipse.jst.jsf.facesconfig.ui.page.overviewPage&quot;&gt;
- &lt;overviewpage
- name=&quot;%pageflow.editor.intro.name&quot;
- description=&quot;%port.editor.intro.description&quot;&gt;
- &lt;overviewelement
- icon=&quot;icons/pageflow_72.gif&quot;
- heading=&quot;%pageflow.editor.intro.heading&quot;
- text=&quot;%pageflow.editor.intro.description&quot;&gt;
- &lt;/overviewelement&gt;
- &lt;overviewelement
- actionparameters=&quot;Pageflow.designerCheatSheet&quot;
- icon=&quot;icons/tutorials_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.LoadCheatSheetAction&quot;
- text=&quot;%pageflow.editor.intro.cheatsheets.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.cheatsheets.link&quot;&gt;
- &lt;/overviewelement&gt;
- &lt;overviewelement
- actionparameters=&quot;http://www.eclipse.org&quot;
- icon=&quot;icons/overview_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.LoadHelpAction&quot;
- text=&quot;%pageflow.editor.intro.help.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.help.link&quot;&gt;
- &lt;/overviewelement&gt;
- &lt;overviewelement
- actionparameters=&quot;overview&quot;
- icon=&quot;icons/gotoeditor_72.gif&quot;
- hyperlinkaction=&quot;org.eclipse.jst.jsf.common.ui.actions.OpenPageAction&quot;
- text=&quot;%pageflow.editor.intro.start.text&quot;
- hyperlink=&quot;%pageflow.editor.intro.start.link&quot;&gt;
- &lt;/overviewelement&gt;
- &lt;/overviewpage&gt;
- &lt;/extension&gt;
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="apiInfo"/>
- </appInfo>
- <documentation>
-
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="implementation"/>
- </appInfo>
- <documentation>
-
- </documentation>
- </annotation>
-
- <annotation>
- <appInfo>
- <meta.section type="copyright"/>
- </appInfo>
- <documentation>
- Copyright (c) 2004, 2006 Sybase, Inc. and others. &lt;br&gt;
- All rights reserved. This program and the accompanying materials &lt;br&gt;
- are made available under the terms of the Eclipse Public License v1.0 &lt;br&gt;
- which accompanies this distribution, and is available at &lt;br&gt;
- http://www.eclipse.org/legal/epl-v10.html &lt;br&gt;
-
- Contributors: &lt;br&gt;
- Sybase, Inc. - initial API and implementation &lt;br&gt;
- </documentation>
- </annotation>
-
-</schema>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/CommonResources.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/CommonResources.properties
deleted file mode 100644
index b9527d13f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/CommonResources.properties
+++ /dev/null
@@ -1,113 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-####################################################
-# Generic Strings for UI
-####################################################
-
-pluginName=Web Application Development Common
-button.save=&Save
-button.remove=&Remove
-
-####################################################
-# Resource message for Logging
-####################################################
-
-log.msg={0}
-
-log.ResourceUtils=Missing Resource Bundle "{0}".
-log.CommonPlugin=Web Application Development Common Plugin initialized on eclipse version {0}.
-log.FavoriteConfigurations.save.error=Failed to save {0} favorites. File={1}
-log.FavoriteConfigurations.read.error=Failed to read {0} favorites. File={1}
-log.CommonPlugin.image.error=Image {0} not found.
-
-log.IntroductionSection.action.error = Failed to launch the link {0}
-
-####################################################
-# Resource message for Alerts
-####################################################
-
-alert.msg={0}
-
-####################################################
-# Resource messages for FavoriteSection
-####################################################
-favorites.group.label=Favorite Configurations
-favorites.label=&Name:
-favorites.tooltip=Construct common setting favorites for this page.
-favorites.save.tooltip=Save the current options on this page as the favorites.
-favorites.remove.tooltip=Remove the current favorite.
-favorites.default=default
-
-####################################################
-# Resource messages for Preference Pages
-####################################################
-JMTPreferencePage.Description=Expand the tree to edit Web Application preferences.
-
-LoggingPreferencePage.Log.Level.label=Log Level:
-LoggingPreferencePage.Log.Level.tooltip=Select the logging level to output to the selected source.
-LoggingPreferencePage.Log.Level.debug=Debug
-LoggingPreferencePage.Log.Level.info=Info
-LoggingPreferencePage.Log.Level.warn=Warn
-LoggingPreferencePage.Log.Level.error=Error
-LoggingPreferencePage.Log.Level.fatal=Fatal
-LoggingPreferencePage.Console.Group.label=Console
-LoggingPreferencePage.Console.Logging.label=Enable &Console Logging
-LoggingPreferencePage.Console.Logging.tooltip=Receive log message in the Eclipse Console view.
-LoggingPreferencePage.Eclipse.Group.label=Eclipse
-LoggingPreferencePage.Eclipse.Logging.label=Enable &Eclipse Logging
-LoggingPreferencePage.Eclipse.Logging.tooltip=Receive log message in the Eclipse Error Log view.
-LoggingPreferencePage.File.Group.label=File
-LoggingPreferencePage.File.Logging.label=Enable &File Logging
-LoggingPreferencePage.File.Logging.tooltip=Write log message to an external file.
-LoggingPreferencePage.File.clearing.label=Clear log file on &startup
-LoggingPreferencePage.File.clearing.tooltip=Each time Eclipse starts, clear the log file.
-LoggingPreferencePage.File.path.label=&Log file:
-LoggingPreferencePage.File.path.tooltip=Where should the log file go? Partial paths are \n based from: /workspace/.metadata/.plugins/org.eclipse.jst.jsf.common.ui.internal/.
-LoggingPreferencePage.File.button.label=B&rowse
-LoggingPreferencePage.File.button.tooltip=Select a location and file name for file logging.
-LoggingPreferencePage.File.select.label=Select a log file
-LoggingPreferencePage.File.Rollover.Frequency.label=Rollover Fre&quency:
-LoggingPreferencePage.File.Rollover.Frequency.tooltip=Select the frequency of how often to generate a new log file. \n The original log file is appended with a timestamp.
-LoggingPreferencePage.File.Rollover.Frequency.daily=Daily
-LoggingPreferencePage.File.Rollover.Frequency.weekly=Weekly
-LoggingPreferencePage.File.Rollover.Frequency.monthly=Monthly
-
-####################################################
-# Resource messages for BrowserWindow
-####################################################
-BrowserWindow.back.tooltip=Navigate back in the browser
-BrowserWindow.forward.tooltip=Navigate forward in the browser
-BrowserWindow.stop.tooltip=Stop browser navigation
-BrowserWindow.refresh.tooltip=Refresh the browser
-BrowserWindow.reload.tooltip=Reload the browser
-
-####################################################
-# Resource messages for Commmon DialogField
-####################################################
-DialogField.JavaClassWizard.NewClass=New Java Class
-DialogField.ClassButton.SelectType=Select Type
-DialogField.Browse=Browse...
-DialogField.ResourceButton.SelectFile=Select File
-
-####################################################
-# Resource messages for Commmon Dialog
-####################################################
-Dialog.ResourceOnClasspathDialog.StatusMessage=Select a properties file
-Dialog.CommonResourceDialog.StatusMessage0=Select
-Dialog.TreeViewerSelectionDialog.DefaultTitle=Select a File
-
-Wizards.NewPage.Error.InvalidProject=Invalid Web project.
-Error.FileFilter.title=File selection
-Error.ImgFileFilter.error=File selection error:
-Error.ProjectFileDialogContentProvider=Project file dialog error: {0}
-Error.RefreshingLocal=Refreshing local
-
-Service.NoResourceError=Unable to determine Service Model file.
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/IFileFolderConstants.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/IFileFolderConstants.java
deleted file mode 100644
index e74e90a91..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/IFileFolderConstants.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface IFileFolderConstants {
-
- /**
- * the dot character
- */
- public static final String DOT = "."; //$NON-NLS-1$
-
- /**
- * the path separator
- */
- public static final String PATH_SEPARATOR = "/"; //$NON-NLS-1$
-
- /** file extensions */
- /**
- * class file extension
- */
- public static final String EXT_CLASS = "class"; //$NON-NLS-1$
-
- /**
- * jar file extension
- */
- public static final String EXT_JAR = "jar"; //$NON-NLS-1$
-
- /**
- * java file extension
- */
- public static final String EXT_JAVA = "java"; //$NON-NLS-1$
-
-
- /**
- * jsp file extension
- */
- public static final String EXT_JSP = "jsp"; //$NON-NLS-1$
-
- /**
- * properties file extension
- */
- public static final String EXT_PROPERTIES = "properties"; //$NON-NLS-1$
-
- /**
- * taglib file extension
- */
- public static final String EXT_TAGLIB = "tld"; //$NON-NLS-1$
-
- /**
- * standard web.xml file name
- */
- public static final String FILE_WEB_XML = "web.xml"; //$NON-NLS-1$
-
- /** folders */
-
- /**
- * classes folder name
- */
- public static final String FOLDER_CLASS = "classes"; //$NON-NLS-1$
-
- /**
- * icons folder name
- */
- public static final String FOLDER_ICONS = "icons"; //$NON-NLS-1$
-
- /**
- * the meta-inf folder name
- */
- public static final String FOLDER_METAINF = "META-INF"; //$NON-NLS-1$
-
- /**
- * the src folder name
- */
- public static final String FOLDER_SOURCE = "src"; //$NON-NLS-1$
-
- /**
- * the web-inf folder name
- */
- public static final String FOLDER_WEBINF = "WEB-INF"; //$NON-NLS-1$
-
- /** the webroot folder depth relative to the project */
- public static final int WEBROOT_FOLDER_DEPTH = 2;
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/JSFUICommonPlugin.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/JSFUICommonPlugin.java
deleted file mode 100644
index b4a1f0075..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/JSFUICommonPlugin.java
+++ /dev/null
@@ -1,418 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.MissingResourceException;
-import java.util.Properties;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.Alerts;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.Version;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class JSFUICommonPlugin extends AbstractUIPlugin {
- // Properties contains general properties and defaults to preferences.
- private static final String PROPERTIES = "default.properties"; //$NON-NLS-1$
- // preferences will
- // contain this string
- // in the key.
-
- private static final String P_CONSOLE_LOGGING = "console.logging.on"; //$NON-NLS-1$
-
- private static final String P_CONSOLE_LOG_LEVEL = "console.logging.max.level"; //$NON-NLS-1$
-
- private static final String P_ECLIPSE_LOGGING = "eclipse.logging.on"; //$NON-NLS-1$
-
- private static final String P_ECLIPSE_LOG_LEVEL = "eclipse.logging.max.level"; //$NON-NLS-1$
-
- private static final String P_FILE_LOGGING = "file.logging.on"; //$NON-NLS-1$
-
- private static final String P_FILE_LOG_LEVEL = "file.logging.max.level"; //$NON-NLS-1$
-
- private static final String P_FILE_PATH = "file.logging.path"; //$NON-NLS-1$
-
- private static final String P_FILE_CLEAR = "file.logging.startup.clear"; //$NON-NLS-1$
-
- private static final String P_FILE_ROLLOVER_FREQUENCY = "file.logging.rollover.frequency"; //$NON-NLS-1$
-
- private static final int DEBUG_LEVEL = 0;
-
- private static final int INFO_LEVEL = 1;
-
- private static final int WARN_LEVEL = 2;
-
- private static final int ERROR_LEVEL = 3;
-
- private static final int FATAL_LEVEL = 4;
-
- // What version of the platform are we on.
- private static boolean TWO_DOT_ONE;
-
- private static boolean THREE_DOT;
-
- private static String _version;
-
- // The shared instance.
- private static JSFUICommonPlugin _plugin;
-
- private Logger _log;
-
- private ResourceBundle _resourceBundle;
-
- private Properties _properties;
-
- private URL _pluginBase;
-
- private static Alerts _alerts;
-
- /**
- * The constructor.
- */
- public JSFUICommonPlugin() {
- super();
- _plugin = this;
- versionCheck();
- }
-
- private void versionCheck() {
- String version = (String) ResourcesPlugin.getPlugin().getBundle()
- .getHeaders().get(org.osgi.framework.Constants.BUNDLE_VERSION);
- Version identifier = new Version(version);
-
- TWO_DOT_ONE = ((identifier.getMajor() == 2) && (identifier
- .getMinor() == 1));
- THREE_DOT = (identifier.getMajor() == 3);
- _version = identifier.toString();
- }
-
- /**
- * This method is called upon plug-in activation
- */
- public void start(BundleContext context) throws Exception {
- super.start(context);
-
- // This plugin is for 3.0 only, do a version check.
- if (isThreeDot() == false) {
- throw new CoreException(new Status(IStatus.ERROR, getBundle()
- .getSymbolicName(), IStatus.OK,
- "Requires eclipse version 3.x", null)); //$NON-NLS-1$
- }
-
- try {
- // get resource bundle.
- _resourceBundle = ResourceBundle
- .getBundle("org.eclipse.jst.jsf.common.ui.CommonResources"); //$NON-NLS-1$
- _alerts = new Alerts(this, _resourceBundle);
-
- // get properties.
- _properties = new Properties();
- InputStream input = null;
- _pluginBase = getBundle().getEntry("/"); //$NON-NLS-1$
- try {
- input = (new URL(_pluginBase, PROPERTIES)).openStream();
- _properties.load(input);
- } finally {
- try {
- input.close();
- } catch (IOException ee)// NOPMD
- {
- // nothing to do when IOException throwed in closing files.
- }
- }
-
- // set up logging for this plugin and everthing under it.
- _log = new Logger(this.getBundle(), _resourceBundle);
-
- // NOTE: add in any other plugin code statup HERE!!!!
-
- // log.CommonPlugin=Web Application Development Common Plugin
- // initialized on eclipse version {0}.
-
- // log.info("log.CommonPlugin", version);
-
- } catch (Exception ee) {
- // only log if the logger was configured correctly.
- if (_log != null) {
- _log
- .error(
- "log.msg", //$NON-NLS-1$
- "Problems starting plug-in Web Application Development Common.", //$NON-NLS-1$
- ee);
- }
-
- throw new CoreException(
- new Status(
- IStatus.ERROR,
- getBundle().getSymbolicName(),
- IStatus.OK,
- "Problems starting plug-in Web Application Development Common", //$NON-NLS-1$
- ee));
- }
- }
-
- /**
- * Returns the shared instance.
- * @return the plugin instance
- */
- public static JSFUICommonPlugin getDefault() {
- return _plugin;
- }
-
- /**
- * get the alerts objects associated with this plugin for alerting the user.
- *
- * @return the alerts object
- */
- public static Alerts getAlerts() {
- return _alerts;
- }
-
- /**
- * Returns a logger for the new class using this plugin for reference.
- * @param theClass
- * @return the logger
- */
- // TODO: theClass is never used!!
- public static Logger getLogger(Class theClass) {
- return getDefault().getRootLogger();
- }
-
- /**
- * Returns the plugin's root logger
- * @return the root logger
- */
- public Logger getRootLogger() {
- return _log;
- }
-
- /**
- * Returns this plugin's unique identifier
- *
- * @return this plugin's unique identifier
- *
- */
- public static String getPluginId() {
- return getDefault().getBundle().getSymbolicName();
- }
-
- /**
- * Returns the plugin's resource bundle,
- * @return the resource bundle
- */
- public ResourceBundle getResourceBundle() {
- return _resourceBundle;
- }
-
- /**
- * Returns the string from the plugin's resource bundle, or 'key' if not
- * found.
- * @param key
- * @return the resource string
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = JSFUICommonPlugin.getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the plugin's descriptor's resource bundle,
- * @return the bundle
- */
- public ResourceBundle getPluginDecriptorBundle() {
- return Platform.getResourceBundle(getDefault().getBundle());
- }
-
- /**
- * Returns the plugin's default properties. These are normally used for
- * default preferences.
- * @return the properties
- */
- public Properties getProperties() {
- return _properties;
- }
-
- /**
- * Returns a shared image for the given name
- * <p>
- * Note: Images returned from this method will be automitically disposed of
- * when this plug-in shuts down. Callers must not dispose of these images
- * themselves.
- * </p>
- *
- * @param name
- * the image name found in /icons (with extension)
- * @return the image, null on error or not found.
- */
- public Image getImage(String name) {
- if (name == null) {
- return null;
- }
-
- ImageRegistry images = getImageRegistry();
- Image image = images.get(name);
- if (image == null) {
- try {
- ImageDescriptor id = ImageDescriptor.createFromURL(new URL(
- _pluginBase, "icons/" + name)); //$NON-NLS-1$
- images.put(name, id);
-
- image = images.get(name);
- } catch (MalformedURLException ee) {
- // log.CommonPlugin.image.error=Image {0} not found.
- _log.error("log.msg", "log.CommonPlugin.image.error", name, ee); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- return image;
- }
-
- /**
- * Returns a shared ImageDescriptor for the given name
- * <p>
- * Note: ImageDescriptor returned from this method will be automitically
- * disposed of when this plug-in shuts down. Callers must not dispose of
- * these ImageDescriptor themselves.
- * </p>
- *
- * @param name
- * the ImageDescriptor name found in /icons (with extension)
- * @return the ImageDescriptor, null on error or not found.
- */
- public ImageDescriptor getImageDescriptor(String name) {
- if (name == null) {
- return null;
- }
-
- ImageRegistry images = getImageRegistry();
- ImageDescriptor id = images.getDescriptor(name);
- if (id == null) {
- try {
- id = ImageDescriptor.createFromURL(new URL(_pluginBase,
- "icons/" + name)); //$NON-NLS-1$
- images.put(name, id);
- } catch (MalformedURLException ee) {
- // log.CommonPlugin.image.error=Image {0} not found.
- _log.error("log.msg", "log.CommonPlugin.image.error", name, ee); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- return id;
- }
-
- /**
- * Is this eclipse version 2.1
- *
- * @return true if version is 2.1
- */
- public static boolean isTwoDotOne() {
- return TWO_DOT_ONE;
- }
-
- /**
- * Is this eclipse version 3.x
- *
- * @return true if version is 3.x
- */
- public static boolean isThreeDot() {
- return THREE_DOT;
- }
-
- /**
- * get the eclipse version
- *
- * @return version string.
- */
- public static String getVersion() {
- return _version;
- }
-
-
-
- /**
- * Initializes the preference controls to the default values. These values
- * are used the first time the preference page is displayed or when the user
- * presses the Defaults button in the preferences page.
- */
- protected void initializeDefaultPreferences(IPreferenceStore store) {
- // NOTE: no logging can happen here since we haven't initialized logging
- // yet because it
- // depends on preferences!!!!
-
- store.setDefault(P_CONSOLE_LOGGING, _properties.getProperty(
- P_CONSOLE_LOGGING, Boolean.TRUE.toString()));
- store.setDefault(P_CONSOLE_LOG_LEVEL, strToIntLogLevel(_properties
- .getProperty(P_CONSOLE_LOG_LEVEL, "ERROR"))); //$NON-NLS-1$
-
- store.setDefault(P_ECLIPSE_LOGGING, _properties.getProperty(
- P_ECLIPSE_LOGGING, Boolean.TRUE.toString()));
- store.setDefault(P_ECLIPSE_LOG_LEVEL, strToIntLogLevel(_properties
- .getProperty(P_ECLIPSE_LOG_LEVEL, "ERROR"))); //$NON-NLS-1$
-
- store.setDefault(P_FILE_LOGGING, _properties.getProperty(
- P_FILE_LOGGING, Boolean.FALSE.toString()));
- store.setDefault(P_FILE_LOG_LEVEL, strToIntLogLevel(_properties
- .getProperty(P_FILE_LOG_LEVEL, "ERROR"))); //$NON-NLS-1$
- store.setDefault(P_FILE_PATH, _properties.getProperty(P_FILE_PATH, "")); //$NON-NLS-1$
- store.setDefault(P_FILE_CLEAR, _properties.getProperty(P_FILE_CLEAR,
- Boolean.TRUE.toString()));
- store.setDefault(P_FILE_ROLLOVER_FREQUENCY, _properties.getProperty(
- P_FILE_ROLLOVER_FREQUENCY, "DAILY")); //$NON-NLS-1$
- }
-
- /**
- * Converts the log level from string to int. The level defaults to
- * ERROR_LEVEL.
- *
- * @param str
- * String representation of log level
- * @return integer representation of log level
- */
- private int strToIntLogLevel(String str) {
- if (str == null) {
- return ERROR_LEVEL;
- }
- if (str.equalsIgnoreCase("DEBUG")) { //$NON-NLS-1$
- return DEBUG_LEVEL;
- }
- if (str.equalsIgnoreCase("INFO")) { //$NON-NLS-1$
- return INFO_LEVEL;
- }
- if (str.equalsIgnoreCase("WARN")) { //$NON-NLS-1$
- return WARN_LEVEL;
- }
- if (str.equalsIgnoreCase("FATAL")) { //$NON-NLS-1$
- return FATAL_LEVEL;
- }
- return ERROR_LEVEL;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/IOpenPage.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/IOpenPage.java
deleted file mode 100644
index 8456083ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/IOpenPage.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.actions;
-
-/**
- * Editors should implement this if they can handle reseting to a page based on
- * the class defined for that page.
- *
- * @author collinsc,jchoi
- */
-public interface IOpenPage {
- /**
- * Sets the currently active page from the id of the page.
- *
- * @param pageID
- */
- public void setActiveEditorPage(String pageID);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadCheatSheetAction.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadCheatSheetAction.java
deleted file mode 100644
index de7406f7c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadCheatSheetAction.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.actions;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IExecutableExtension;
-import org.eclipse.jface.action.Action;
-import org.eclipse.ui.cheatsheets.OpenCheatSheetAction;
-
-/**
- * This class is used to open the cheat sheet based on the configuration
- * parameter.
- *
- * @author mengbo
- */
-public class LoadCheatSheetAction extends Action implements
- IExecutableExtension {
- private String _cheatSheetName = null;
-
- /**
- *
- */
- public LoadCheatSheetAction() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.action.IAction#run()
- */
- public void run() {
- if (_cheatSheetName != null) {
- OpenCheatSheetAction action = new OpenCheatSheetAction(
- _cheatSheetName);
- action.run();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.runtime.IExecutableExtension#setInitializationData(org.eclipse.core.runtime.IConfigurationElement,
- * java.lang.String, java.lang.Object)
- */
- public void setInitializationData(IConfigurationElement config,
- String propertyName, Object data) throws CoreException {
- _cheatSheetName = config.getAttribute("actionparameters"); //$NON-NLS-1$
- }
-
- /**
- * set the cheatSheetName name to open.
- *
- * @param cheatSheetName
- */
- public void setCheatSheetName(String cheatSheetName) {
- _cheatSheetName = cheatSheetName;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadHelpAction.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadHelpAction.java
deleted file mode 100644
index 18b927d2b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/LoadHelpAction.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.actions;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IExecutableExtension;
-import org.eclipse.help.HelpSystem;
-import org.eclipse.help.IContext;
-import org.eclipse.help.IHelpResource;
-import org.eclipse.jface.action.Action;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * This class is used to open the help page for a configuration param.
- *
- * @author mengbo
- */
-public class LoadHelpAction extends Action implements IExecutableExtension {
- private String _helpContextId = null;
-
- /**
- *
- */
- public LoadHelpAction() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.action.IAction#run()
- */
- public void run() {
- IContext context = HelpSystem.getContext(_helpContextId);
- if (context != null) {
- IHelpResource[] topics = context.getRelatedTopics();
- if (topics != null && topics.length == 1) {
- PlatformUI.getWorkbench().getHelpSystem().displayHelpResource(
- topics[0].getHref());
- } else {
- PlatformUI.getWorkbench().getHelpSystem().displayHelp(
- _helpContextId);
- }
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.runtime.IExecutableExtension#setInitializationData(org.eclipse.core.runtime.IConfigurationElement,
- * java.lang.String, java.lang.Object)
- */
- public void setInitializationData(IConfigurationElement config,
- String propertyName, Object data) throws CoreException {
- _helpContextId = config.getAttribute("actionparameters"); //$NON-NLS-1$
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/OpenPageAction.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/OpenPageAction.java
deleted file mode 100644
index 252e44caf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/actions/OpenPageAction.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.actions;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IExecutableExtension;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.editor.FormEditor;
-
-/**
- * This class is used to open a page in the editor based on the configuration
- * parameter.
- *
- * @author collinsc,jchoi
- */
-public class OpenPageAction extends Action implements IExecutableExtension {
- private String pageID = null;
-
- private ISelection selection;
-
- /**
- *
- */
- public OpenPageAction() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.action.IAction#run()
- */
- public void run() {
- if (pageID != null) {
- // get the active editor
- IEditorPart editor = getActiveEditor();
- IOpenPage openPage = (IOpenPage)editor.getAdapter(IOpenPage.class);
- if(openPage != null){
- openPage.setActiveEditorPage(pageID);
- if (selection != null && editor instanceof FormEditor) {
- IEditorPart activePage = ((FormEditor) editor)
- .getActiveEditor();
- if (activePage instanceof ISelectionProvider) {
- ((ISelectionProvider) activePage)
- .setSelection(selection);
- }
- }
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.runtime.IExecutableExtension#setInitializationData(org.eclipse.core.runtime.IConfigurationElement,
- * java.lang.String, java.lang.Object)
- */
- public void setInitializationData(IConfigurationElement config,
- String propertyName, Object data) throws CoreException {
- pageID = config.getAttribute("actionparameters"); //$NON-NLS-1$
- }
-
- /**
- * set the class name to open.
- * @param className
- */
- public void setPageName(String className) {
- this.pageID = className;
- }
-
- /**
- * get the current active editor
- *
- * @return the active editor part
- */
- public static IEditorPart getActiveEditor() {
- IEditorPart editor = null;
- IWorkbenchWindow win = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow();
- if (win != null) {
- IWorkbenchPage page = win.getActivePage();
- if (page != null) {
- editor = page.getActiveEditor();
- }
- }
- return editor;
- }
-
- /**
- * @return stored selection
- */
- public ISelection getSelection() {
- return selection;
- }
-
- /**
- * @param selection
- */
- public void setSelection(ISelection selection) {
- this.selection = selection;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/AbstractClassButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/AbstractClassButtonDialogField.java
deleted file mode 100644
index 165846a6b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/AbstractClassButtonDialogField.java
+++ /dev/null
@@ -1,238 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jdt.ui.IJavaElementSearchConstants;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.Alerts;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-/*package*/ abstract class AbstractClassButtonDialogField extends
- StringButtonDialogField {
- private IProject _project;
-
- private String _superClass;
-
- private List _interfacesList;
-
- private IType _type;
-
- private int _typeFlag = IJavaElementSearchConstants.CONSIDER_ALL_TYPES;
-
- private boolean _autoOpenResource = true;
-
- /**
- * @param autoOpenResource
- */
- public void setAutoOpenResource(boolean autoOpenResource) {
- _autoOpenResource = autoOpenResource;
- }
-
- /**
- * @param project
- */
- public AbstractClassButtonDialogField(IProject project) {
- super(null);
- this._project = project;
-
- setHyperLink(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- activeLink();
- }
- });
-
- setStringButtonAdapter(new IStringButtonAdapter() {
- public void changeControlPressed(DialogField field) {
- browseButtonPressed();
- }
- });
- }
-
- private void activeLink() {
- String className = getText();
- className = trimNonAlphaChars(className);
- if (className.length() > 0
- && JavaUIHelper.doesClassExist(_project, className)) {
- JavaUIHelper.doOpenClass(_project, className);
- } else {
- try {
- if (_project == null || !_project.hasNature(JavaCore.NATURE_ID)) {
- ResourceBundle rb = ResourceBundle
- .getBundle("org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldResources"); //$NON-NLS-1$
- Alerts alerts = new Alerts(JSFUICommonPlugin.getDefault(), rb);
- alerts.error("ClassButtonDialogField.Alert.Title", //$NON-NLS-1$
- "ClassButtonDialogField.Alert.Msg"); //$NON-NLS-1$
- return;
- }
- } catch (CoreException e) {
- e.printStackTrace();
- return;
- }
- JavaClassWizard wizard = new JavaClassWizard(_project, className,
- _superClass, getImplementInterfaces());
- wizard.setAutoOpenResource(_autoOpenResource);
- WizardDialog dialog = new WizardDialog(getShell(), wizard);
- dialog.create();
-
- setDialogSize(dialog, 400, 500);
- if (dialog.open() == WizardDialog.OK) {
- String newValue = wizard.getClassNameWithArgs();
- if (!newValue.equals(className)) {
- setText(newValue);
- }
- }
- }
- }
-
- /**
- * @return the interfaces
- * TODO: the contract seems inconsistent
- * as whether to return null or empty list when none
- */
- protected abstract List getImplementInterfaces();
-
- /**
- * @return the java search scope to be used. Must not be null
- */
- protected abstract IJavaSearchScope getJavaSearchScope();
-
- private void browseButtonPressed() {
- Shell shell = getShell();
- SelectionDialog dialog = JavaUIHelper.openSelectionDialog(shell,
- getJavaSearchScope(), _typeFlag);
- dialog.setTitle(JSFUICommonPlugin
- .getResourceString("DialogField.ClassButton.SelectType"));//$NON-NLS-1$
-
- if (dialog.open() == SelectionDialog.OK) {
- String oldClassName = getText();
- if (dialog.getResult() != null) {
- _type = (IType) dialog.getResult()[0];
- String newClassName = _type.getFullyQualifiedName();
- if (!oldClassName.equals(newClassName)) {
- setText(newClassName);
- }
- }
- }
- }
-
- private void setDialogSize(Dialog dialog, int width, int height) {
- Point computedSize = dialog.getShell().computeSize(SWT.DEFAULT,
- SWT.DEFAULT);
- width = Math.max(computedSize.x, width);
- height = Math.max(computedSize.y, height);
- dialog.getShell().setSize(width, height);
- }
-
- private String trimNonAlphaChars(String className) {
- className = className.trim();
- while (className.length() > 0
- && !Character.isLetter(className.charAt(0))) {
- className = className.substring(1, className.length());
- }
- int loc = className.indexOf(":"); //$NON-NLS-1$
- if (loc != -1 && loc > 0) {
- className = className.substring(0, loc);
- } else if (loc == 0) {
- className = ""; //$NON-NLS-1$
- }
- return className;
- }
-
- /**
- * @return Returns the project.
- */
- public IProject getProject() {
- return _project;
- }
-
- /**
- * @param project
- * The project to set.
- */
- public void setProject(IProject project) {
- this._project = project;
- }
-
- /**
- * @return Returns the superClassName.
- */
- public String getSuperClassName() {
- return _superClass;
- }
-
- /**
- * @param superClassName
- * The superClassName to set.
- */
- public void setSuperClassName(String superClassName) {
- this._superClass = superClassName;
- }
-
- /**
- * @return Returns the interfacesList.
- */
- protected List getInterfacesList() {
- return _interfacesList;
- }
-
- /**
- * Sets (replaces) the interface list
- * TODO: this list can have at most one element
- * @param interfaceName
- */
- public void setInterface(String interfaceName) {
- _interfacesList = new ArrayList();
- _interfacesList.add(interfaceName);
- }
-
- /**
- * @return Returns the _type.
- */
- public IType getType() {
- return _type;
- }
-
- /**
- * @return Returns the typeFalg.
- */
- public int getTypeFlag() {
- return _typeFlag;
- }
-
- /**
- * @param typeFalg
- * The typeFalg to set.
- */
- public void setTypeFlag(int typeFalg) {
- this._typeFlag = typeFalg;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ClassButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ClassButtonDialogField.java
deleted file mode 100644
index baed42bb5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ClassButtonDialogField.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jdt.core.search.SearchEngine;
-
-/**
- * @author mengbo
- */
-public class ClassButtonDialogField extends AbstractClassButtonDialogField {
- /**
- * @param project
- */
- public ClassButtonDialogField(IProject project) {
- super(project);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.AbstractClassButtonDialogField#getImplementInterfaces()
- */
- protected List getImplementInterfaces() {
- return getInterfacesList();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.AbstractClassButtonDialogField#getJavaSearchScope()
- */
- protected IJavaSearchScope getJavaSearchScope() {
- IJavaSearchScope scope;
- String superType = getSuperClassName();
- List interfaceList = getInterfacesList();
- if (superType == null && interfaceList != null
- && interfaceList.size() > 0) {
- superType = interfaceList.get(0).toString();
- }
- if (getSuperClassName() != null && interfaceList != null
- && interfaceList.size() > 0) {
- superType = null;
- }
- if (superType == null) {
- scope = SearchEngine
- .createJavaSearchScope(new IJavaProject[] { JavaCore
- .create(getProject()) });
- } else {
- scope = JavaUIHelper.findSearchScope(getProject(), superType);
- }
- return scope;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorButtonDialogField.java
deleted file mode 100644
index 822841455..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorButtonDialogField.java
+++ /dev/null
@@ -1,339 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jst.jsf.common.ui.internal.utils.StyleCombo;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.ImageData;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.RGB;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.ColorDialog;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * This class provides a common color choice DialogFiled.
- *
- * @author mengbo
- */
-public class ColorButtonDialogField extends StyleComboDialogField {
- // color selection button
- private Button _button;
-
- // the button enable flag
- private boolean _buttonEnabled;
-
- // the current color
- private Color _color;
-
- // the current color RGB
- private RGB _colorValue;
-
- // the combo control
- private StyleCombo _combo;
-
- // when no color is set or selected, using the empty image
- private Image _emptyImage;
-
- // size of color image
- private Point _extent;
-
- // the color image
- private Image _image;
-
- private ColorPalette _colorPalette;
-
- /**
- * @param flags
- * @param colorPalette
- */
- public ColorButtonDialogField(int flags, ColorPalette colorPalette) {
- super(flags);
- _buttonEnabled = true;
- _colorPalette = colorPalette;
- }
-
- private void buttonPressed() {
- ColorDialog colorDialog = new ColorDialog(_button.getShell());
- colorDialog.setRGB(_colorValue);
- RGB newColor = colorDialog.open();
- if (newColor != null && !newColor.equals(_colorValue)) {
- _colorValue = newColor;
- setText(ColorPalette.getStringColor(newColor));
- updateColorImage();
- }
- }
-
- /**
- * Compute the size of the image to be displayed.
- *
- * @param window -
- * the window used to calculate
- * @return <code>Point</code>
- */
- private Point computeImageSize(Control window) {
- GC gc = new GC(window);
- Font f = _button.getFont();
- gc.setFont(f);
- int height = gc.getFontMetrics().getHeight();
-
- Point p = new Point(height * 3 - 6, height - 2);
- gc.dispose();
- return p;
- }
-
- private void disposeResources() {
- if (_image != null) {
- _image.dispose();
- _image = null;
- }
- if (_emptyImage != null) {
- _emptyImage.dispose();
- _emptyImage = null;
- }
- if (_color != null) {
- _color.dispose();
- _color = null;
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#doFillIntoGrid(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite, int)
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(toolkit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- StyleCombo combo = getComboControl(toolkit, parent);
- combo.setLayoutData(gridDataForCombo(nColumns - 3));
-
- _button = getChangeControl(toolkit, parent);
- _button.setLayoutData(gridDataForButton(1));
-
- return new Control[] { requiredLabel, label, combo, _button };
- }
-
- /**
- * Sets the enable state of the button.
- * @param enable
- */
- public void enableButton(boolean enable) {
- if (isOkToUse(_button)) {
- _button.setEnabled(isEnabled() && enable);
- }
- _buttonEnabled = enable;
- }
-
- /**
- * Creates or returns the created buttom widget.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> if the widget has
- * already been created.
- * @return the button widget
- */
- public Button getChangeControl(FormToolkit toolkit, Composite parent) {
- if (_button == null) {
- assertCompositeNotNull(parent);
- if (toolkit != null) {
- _button = toolkit.createButton(parent, "", SWT.PUSH); //$NON-NLS-1$
- } else {
- _button = new Button(parent, SWT.PUSH);
- }
- _button.setEnabled(isEnabled() && _buttonEnabled);
-
- _button.addSelectionListener(new SelectionListener() {
- public void widgetDefaultSelected(SelectionEvent e) {
- buttonPressed();
- }
-
- public void widgetSelected(SelectionEvent e) {
- buttonPressed();
- }
- });
-
- _button.addDisposeListener(new DisposeListener() {
- public void widgetDisposed(DisposeEvent event) {
- disposeResources();
- }
- });
-
- _extent = computeImageSize(parent);
- _image = new Image(parent.getDisplay(), _extent.x, _extent.y);
- _emptyImage = new Image(parent.getDisplay(), _extent.x, _extent.y);
- initEmptyImage(_button);
- updateColorImage();
- }
-
- return _button;
- }
-
- private String[] getColorList() {
- Map map = _colorPalette.getExtendedColorMap();
- List list = new ArrayList(map.keySet());
- Collections.sort(list);
- return (String[]) list.toArray(new String[list.size()]);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField#getTextControl(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public StyleCombo getComboControl(FormToolkit toolkit, Composite parent) {
-
- if (_combo == null) {
- _combo = super.getComboControl(toolkit, parent);
-
- _combo.addSelectionListener(new SelectionListener() {
-
- public void widgetDefaultSelected(SelectionEvent e) {
- updateImageAfterChanged();
- }
-
- public void widgetSelected(SelectionEvent e) {
- updateImageAfterChanged();
- }
- });
- _combo.addFocusListener(new FocusAdapter() {
- public void focusLost(FocusEvent e) {
- updateImageAfterChanged();
- }
- });
- _combo.setItems(getColorList());
- }
- return _combo;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#getNumberOfControls()
- */
- public int getNumberOfControls() {
- return 4;
- }
- private GridData gridDataForButton(int span) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- gd.widthHint = LayoutUtil.getButtonWidthHint(_button);
- gd.heightHint = _combo.computeSize(SWT.DEFAULT, SWT.DEFAULT).y;
- return gd;
- }
-
- private void initEmptyImage(Control parent) {
- Color transparentColor = parent.getForeground();
- ImageData imageData = _emptyImage.getImageData();
- imageData.transparentPixel = 0;
- GC gc = new GC(_emptyImage);
- gc.setBackground(transparentColor);
- gc.fillRectangle(0, 0, _emptyImage.getBounds().width, _emptyImage
- .getBounds().height);
- }
-
- /**
- * Set the current color value and update the control.
- *
- * @param rgb
- * The new color.
- */
- public void setColorValue(RGB rgb) {
- _colorValue = rgb;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.ComboDialogField#setTextWithoutUpdate(java.lang.String)
- */
- public void setTextWithoutUpdate(String text) {
- super.setTextWithoutUpdate(text);
- updateImageAfterChanged();
- }
-
- /**
- * Update the image being displayed on the button using the current color
- * setting.
- */
- protected void updateColorImage() {
- if (_button.isDisposed()) {
- return;
- }
-
- if (_colorValue == null) {
- _button.setImage(_emptyImage);
- return;
- }
-
- Display display = _button.getDisplay();
- GC gc = new GC(_image);
- gc.setForeground(display.getSystemColor(SWT.COLOR_BLACK));
- gc.drawRectangle(0, 0, _extent.x - 1, _extent.y - 1);
- if (_color != null) {
- _color.dispose();
- }
- _color = new Color(display, _colorValue);
- gc.setBackground(_color);
- gc.fillRectangle(1, 1, _extent.x - 2, _extent.y - 2);
- gc.dispose();
- _button.setImage(_image);
- }
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_button)) {
- _button.setEnabled(isEnabled() && _buttonEnabled);
- }
- }
-
- private void updateImageAfterChanged() {
- String newColor = getText().trim();
- setColorValue(_colorPalette.getExtendedColorRGB(newColor));
- updateColorImage();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorPalette.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorPalette.java
deleted file mode 100644
index 454a4c0a5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ColorPalette.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.RGB;
-
-/**
- * Defines a two sets: one of basic and one of extended colors. Clients extending
- * this class must provide the two maps
- *
- * @author cbateman
- *
- */
-public abstract class ColorPalette
-{
- /**
- * @param cssText
- * @return the basic color matching the cssText key or null if color doesn't exist
- */
- public final Color getBasicColor(String cssText) {
- return (Color) getBasicColorMap().get(cssText.toLowerCase());
- }
-
- /**
- * @param cssText
- * @return the extended color matching the cssText key or null if color doesn't exist
- */
- public final Color getExtendedColor(String cssText) {
- Set keys = getExtendedColorMap().keySet();
- for (Iterator iterator = keys.iterator(); iterator.hasNext();) {
- String key = (String) iterator.next();
- if (key.equalsIgnoreCase(cssText)) {
- return (Color) getExtendedColorMap().get(key);
- }
- }
- return null;
- }
-
- /**
- * @return the map of basic colors where the key is the color name (a string)
- * and the value is an RGB object
- */
- public abstract Map getBasicColorMap();
-
- /**
- * @return the map of extended colors where the key is the color name (a string)
- * and the value is an Color object
- */
- public abstract Map getExtendedColorMap();
-
- /**
- * @param textColor
- * @return same as getExtendedColor but returns value as an RGB object
- */
- public final RGB getExtendedColorRGB(String textColor) {
- if (textColor == null || textColor.length() == 0) {
- return null;
- }
-
- Color color = getExtendedColor(textColor);
- if (color != null) {
- return color.getRGB();
- }
-
- if (textColor.charAt(0) == '#' && textColor.length() == 4) {
- char[] rgbChars = textColor.toCharArray();
- char[] fullChars = { rgbChars[0], rgbChars[1], rgbChars[1],
- rgbChars[2], rgbChars[2], rgbChars[3], rgbChars[3] };
-
- textColor = String.valueOf(fullChars);
- }
-
- if (textColor.charAt(0) == '#' && textColor.length() == 7) {
- try {
- int intColor = Integer.decode(textColor).intValue();
-
- if (intColor > 0xFFFFFF || intColor < 0) {
- return null;
- }
- int r = intColor >> 16;
- int g = (intColor >> 8) & 0xFF;
- int b = intColor & 0xFF;
- return new RGB(r, g, b);
-
- } catch (NumberFormatException e) {
- return null;
- }
- }
- return null;
- }
-
- /**
- * @param rgb
- * @return the hex string for equivalent of the rgb color
- */
- public static String getStringColor(RGB rgb) {
- if (rgb == null) {
- return ""; //$NON-NLS-1$
- }
-
- StringBuffer buffer = new StringBuffer("#"); //$NON-NLS-1$
- int[] intRGBs = new int[] { rgb.red, rgb.green, rgb.blue };
- for (int i = 0; i < 3; i++) {
- if (intRGBs[i] < 16) {
- buffer.append("0"); //$NON-NLS-1$
- }
- buffer.append(Integer.toHexString(intRGBs[i]).toUpperCase());
- }
- return buffer.toString();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ComboDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ComboDialogField.java
deleted file mode 100644
index 582634e13..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ComboDialogField.java
+++ /dev/null
@@ -1,320 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.Map;
-import java.util.Map.Entry;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Dialog field containing a label and a combo control.
- *
- * If the combo control is editable, then when user type in the field, will only
- * fire dialogFieldChanged, without dialogFieldApplied just as text control. But
- * when user change selection using the drop down, will fire both
- * dialogFieldChanged and dialogFieldApplied
- *
- * @author mengbo
- */
-public class ComboDialogField extends DialogFieldBase implements
- ISupportTextValue {
- final static private int WIDTH_HINT = 10;
-
- private String _text;
-
- private int _selectionIndex;
-
- private String[] _items;
-
- private CCombo _comboControl;
-
- private ModifyListener _modifyListener;
-
- private int _flags;
-
- private boolean _pending = false;
-
- private Map _entryMap;
-
- /**
- * @param flags
- */
- public ComboDialogField(int flags) {
- super();
- _text = ""; //$NON-NLS-1$
- _items = new String[0];
- _flags = flags;
- _selectionIndex = -1;
- }
-
- // ------- layout helpers
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(toolkit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- CCombo combo = getComboControl(toolkit, parent);
- combo.setLayoutData(gridDataForCombo(nColumns - 2));
-
- return new Control[] { requiredLabel, label, combo };
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 3;
- }
-
- private static GridData gridDataForCombo(int span) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- gd.widthHint = WIDTH_HINT;
- return gd;
- }
-
- // ------- focus methods
-
- /*
- * @see DialogField#setFocus
- */
- public boolean setFocus() {
- if (isOkToUse(_comboControl)) {
- _comboControl.setFocus();
- }
- return true;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created combo control.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> when the widget
- * has already been created.
- * @return the custom combo control
- */
- public CCombo getComboControl(FormToolkit toolkit, Composite parent) {
- if (_comboControl == null || _comboControl.isDisposed()) {
- assertCompositeNotNull(parent);
- _modifyListener = new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- doModifyText(e);
- }
- };
- SelectionListener selectionListener = new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- doSelectionChanged(e);
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- handleDefaultSelection(e);
- }
- };
-
- if (toolkit != null) {
- _comboControl = new CCombo(parent, _flags);
- toolkit.adapt(_comboControl);
- } else {
- _comboControl = new CCombo(parent, _flags | SWT.BORDER);
- _comboControl.setBackground(Display.getCurrent()
- .getSystemColor(SWT.COLOR_LIST_BACKGROUND));
- }
-
- // moved up due to 1GEUNW2
- _comboControl.setItems(_items);
- if (_selectionIndex != -1) {
- _comboControl.select(_selectionIndex);
- } else {
- _comboControl.setText(_text);
- }
- _comboControl.setFont(parent.getFont());
- _comboControl.addModifyListener(_modifyListener);
- _comboControl.addSelectionListener(selectionListener);
- _comboControl.addFocusListener(new FocusAdapter() {
- public void focusLost(FocusEvent e) {
- doFocusLost(e);
- }
- });
- _comboControl.setEnabled(isEnabled());
- _comboControl.setToolTipText(getToolTip());
- }
- return _comboControl;
- }
-
- private void handleDefaultSelection(SelectionEvent e) {
- // commit value
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
-
- private void doFocusLost(FocusEvent e) {
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
-
- private void doModifyText(ModifyEvent e) {
- if (isOkToUse(_comboControl)) {
- _text = getEntryKey(_comboControl.getText());
- _selectionIndex = _comboControl.getSelectionIndex();
- }
- _pending = true;
- dialogFieldChanged();
- }
-
- private void doSelectionChanged(SelectionEvent e) {
- if (isOkToUse(_comboControl)) {
- _items = _comboControl.getItems();
- _text = getEntryKey(_comboControl.getText());
- _selectionIndex = _comboControl.getSelectionIndex();
- }
- _pending = false;
- dialogFieldChangedAndApplied();
- }
-
- // ------ enable / disable management
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_comboControl)) {
- _comboControl.setEnabled(isEnabled());
- }
- }
-
- // ------ text access
-
-
- /**
- * Sets the combo items. Triggers a dialog-changed event.
- * @param items
- */
- public void setItems(String[] items) {
- _items = items;
- if (isOkToUse(_comboControl)) {
- _comboControl.setItems(items);
- }
- _pending = false;
- // dialogFieldChangedAndApplied();
- }
-
- /**
- * Gets the text.
- */
- public String getText() {
- return _text;
- }
-
- /**
- * Sets the text. Triggers a dialog-changed event.
- */
- public void setText(String text) {
- setTextWithoutUpdate(text);
- _pending = false;
- dialogFieldChangedAndApplied();
- }
-
- /**
- * Selects an item.
- * @param index
- */
- public void selectItem(int index) {
- if (isOkToUse(_comboControl)) {
- _comboControl.select(index);
- } else {
- if (index >= 0 && index < _items.length) {
- _text = getEntryKey(_items[index]);
- _selectionIndex = index;
- }
- }
- dialogFieldChangedAndApplied();
- }
-
- /**
- * Sets the text without triggering a dialog-changed event.
- */
- public void setTextWithoutUpdate(String text) {
- _pending = false;
- if (text == null) {
- text = "";//$NON-NLS-1$
- }
- _text = text;
- if (isOkToUse(_comboControl)) {
- _comboControl.removeModifyListener(_modifyListener);
- _comboControl.setText(getEntryValue(text));
- _comboControl.addModifyListener(_modifyListener);
- }
- }
-
- private String getEntryValue(String key) {
- if (_entryMap == null || !_entryMap.containsKey(key)) {
- return key;
- }
- return _entryMap.get(key).toString();
- }
-
- private String getEntryKey(String value) {
- if (_entryMap == null || !_entryMap.containsValue(value)) {
- return value;
- }
-
- Entry[] entries = (Entry[]) _entryMap.entrySet().toArray(new Entry[0]);
- for (int i = 0; i < entries.length; i++) {
- if (entries[i].getValue() == value
- || (value != null && value.equals(entries[i].getValue()))) {
- return entries[i].getKey().toString();
- }
- }
- return value;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#handleGrabHorizontal()
- */
- public void handleGrabHorizontal() {
- LayoutUtil.setGrabHorizontal(_comboControl, true);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogField.java
deleted file mode 100644
index 0ff86f78c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogField.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.forms.events.IHyperlinkListener;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface DialogField {
- /**
- * this method must be called directly after constructor, in this case,
- * system will create a hyper link label, and when the hyper link is
- * clicked, the corresponding method on the listener will be called. A
- * RuntimeException will throw out if this method is called after the label
- * has been created.
- *
- * @param listener
- * can't be null
- */
- public abstract void setHyperLink(IHyperlinkListener listener);
-
- /**
- * Sets the label of the dialog field.
- * @param labeltext
- */
- public abstract void setLabelText(String labeltext);
-
- // ------ change listener
- /**
- * Listener that is notified on a field change
- * @param listener
- */
- public abstract void setDialogFieldChangeListener(
- IDialogFieldChangeListener listener);
-
- /**
- * Listener that is notified on a field apply
- * @param listener
- */
- public abstract void setDialogFieldApplyListener(
- IDialogFieldApplyListener listener);
-
- // ------- focus management
- /**
- * Tries to set the focus to the dialog field. Returns <code>true</code>
- * if the dialog field can take focus. To be re-implemented by dialog field
- * implementors.
- * @return true if dialog field can take focus
- */
- public abstract boolean setFocus();
-
- /**
- * Creates all controls of the dialog field and fills it to a composite. The
- * composite is assumed to have <code>MGridLayout</code> as layout. The
- * dialog field will adjust its controls' spans to the number of columns
- * given. To be reimplemented by dialog field implementors.
- * @param toolkit
- * @param parent
- * @param nColumns
- * @return the controls
- */
- public abstract Control[] doFillIntoGrid(FormToolkit toolkit,
- Composite parent, int nColumns);
-
- /**
- * Returns the number of columns of the dialog field. To be reimplemented by
- * dialog field implementors.
- * @return the number of columns
- */
- public abstract int getNumberOfControls();
-
- // ------- ui creation
- /**
- * @param _formToolkit
- * @param parent
- * @return the label control
- */
- public abstract Control getLabelControl(FormToolkit _formToolkit,
- Composite parent);
-
- // --------- enable / disable management
- /**
- * @param enabled
- */
- public abstract void setEnabled(boolean enabled);
-
- /**
- * Gets the enable state of the dialog field.
- * @return true if enabled is set
- */
- public abstract boolean isEnabled();
-
- /**
- * Get attached data by key.
- *
- * @param key
- * @return the attached data object for key
- */
- public abstract Object getAttachedData(Object key);
-
- /**
- * You can attach any data to the DialogField, and get it using the
- * <code>getAttachedData</code> method.
- *
- * @param key
- * @param value
- */
- public abstract void putAttachedData(Object key, Object value);
-
- /**
- * this method give the DialogField a chance to set the correct column to
- * grab horizontal space. In the implementation of this method, should only
- * change the GridData of control, should not do anything else.
- *
- * The caller is responsible to make sure the controls for the dialog field
- * has been created before calling this method.
- */
- public abstract void handleGrabHorizontal();
-
- /**
- * @return true if is required field
- */
- public abstract boolean isRequired();
-
- /**
- * @param toolTip
- */
- public abstract void setToolTip(String toolTip);
-
- /**
- * @return the field's enclosing shell or null if none
- */
- public Shell getShell();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldBase.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldBase.java
deleted file mode 100644
index 7d61f4983..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldBase.java
+++ /dev/null
@@ -1,559 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.MouseTrackAdapter;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.FontMetrics;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.forms.events.IHyperlinkListener;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Hyperlink;
-
-/**
- * Base class of all Dialog fields. Dialog fields manage controls together with
- * the model, independed from the creation time of the widgets. - support for
- * automated layouting. - enable / disable, set focus a concept of the base
- * class. DialogField have a label.
- *
- * DialogField may be used in two different context:
- * <ol>
- * <li> In side dialog. In this case, whenever there is anything change in the
- * dialog field, such as user type anything, the dialog should listen to the
- * dialogFieldChanged() events and do things like validation. When user press
- * the "OK" button, dialog should call getXXX to get the value from the dialog
- * field and apply them.
- * <li> In side form based editor or properties view. In this case, whenever
- * there is anything change in the dialog field, such as user type anything, the
- * editor/view should listen to the dialogFieldChanged() events and do things
- * like validation. When user press "Enter" or move the focus out of the control
- * (finish editing), the dialog field will fire out dialogFieldApplied() events,
- * and the editor/view should listen to this event and apply the value to the
- * underlying model.
- * </ol>
- *
- * The basic idea of the DialogField framework is comming from
- * <code>org.eclipse.jface.preference.FieldEditor</code> and
- * <code>org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField</code>
- *
- * @author mengbo
- */
-public class DialogFieldBase implements DialogField {
- private Label _label;
-
- private Label _requiredLabel;
-
- private String _labelText;
-
- private IDialogFieldChangeListener _dialogFieldChangeListener;
-
- private IDialogFieldApplyListener _dialogFieldApplyListener;
-
- private boolean _enabled;
-
- private FontMetrics _fontMetrics;
-
- private IHyperlinkListener _listener;
-
- private Hyperlink _hyperlink;
-
- private Map _attachedData;
-
- private boolean _isRequired;
-
- private String toolTip;
-
- /**
- * default constructor
- */
- public DialogFieldBase() {
- _enabled = true;
- _label = null;
- _requiredLabel = null;
- _hyperlink = null;
- _labelText = ""; //$NON-NLS-1$
- }
-
- /**
- * this method must be called directly after constructor, in this case,
- * system will create a hyper link label, and when the hyper link is
- * clicked, the corresponding method on the listene will be called. A
- * RuntimeException will throw out if this method is called after the label
- * has been created.
- *
- * @param listener
- * can't be null
- */
- public void setHyperLink(IHyperlinkListener listener) {
- if (_label != null) {
- throw new RuntimeException(
- "The Label instance does not support the listener"); //$NON-NLS-1$
- }
- this._listener = listener;
- }
-
- /**
- * Sets the label of the dialog field.
- */
- public void setLabelText(String labeltext) {
- _labelText = labeltext == null ? "" : labeltext; //$NON-NLS-1$
- // if (_isRequired)
- // {
- // _labelText = "* " + _labelText;
- // }
- // else
- // {
- // _labelText = " " + _labelText;
- // }
- if (_label != null && !_label.isDisposed()) {
- _label.setText(_labelText);
- } else if (_hyperlink != null && !_hyperlink.isDisposed()) {
- _hyperlink.setText(_labelText);
- }
- }
-
- /**
- * @return return the enclosing Shell or null if one cannot be determined
- */
- public Shell getShell() {
- if (_label != null && !_label.isDisposed()) {
- return _label.getShell();
- } else if (_hyperlink != null && !_hyperlink.isDisposed()) {
- return _hyperlink.getShell();
- }
- return null;
- }
-
- // ------ change listener
-
- /**
- * Defines the listener for this dialog field.
- */
- public final void setDialogFieldChangeListener(
- IDialogFieldChangeListener listener) {
- _dialogFieldChangeListener = listener;
- }
-
- public final void setDialogFieldApplyListener(
- IDialogFieldApplyListener listener) {
- _dialogFieldApplyListener = listener;
- }
-
- /**
- * fire both dialogFieldChanged and dialogFieldApplied events.
- */
- public void dialogFieldChangedAndApplied() {
- if (_dialogFieldChangeListener != null) {
- _dialogFieldChangeListener.dialogFieldChanged(this);
- }
- if (_dialogFieldApplyListener != null) {
- _dialogFieldApplyListener.dialogFieldApplied(this);
- }
- }
-
- /**
- * fire dialogFieldChanged event.
- *
- */
- public void dialogFieldChanged() {
- if (_dialogFieldChangeListener != null) {
- _dialogFieldChangeListener.dialogFieldChanged(this);
- }
- }
-
- /**
- * fire dialogFieldApplied event.
- *
- */
- public void dialogFieldApplied() {
- if (_dialogFieldApplyListener != null) {
- _dialogFieldApplyListener.dialogFieldApplied(this);
- }
- }
-
- // ------- focus management
-
-
- public boolean setFocus() {
- return false;
- }
-
- //
- // /**
- // * Posts <code>setFocus</code> to the display event queue.
- // */
- // public void postSetFocusOnDialogField(Display display)
- // {
- // if (display != null)
- // {
- // display.asyncExec(new Runnable()
- // {
- // public void run()
- // {
- // setFocus();
- // }
- // }
- // );
- // }
- // }
-
- // ------- layout helpers
-
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(nColumns));
-
- return new Control[] { label };
- }
-
- /**
- * Initializes the computation of horizontal and vertical dialog units based
- * on the size of current font.
- * <p>
- * This method must be called before any of the dialog unit based conversion
- * methods are called.
- * </p>
- *
- * @param control
- * a control from which to obtain the current font
- * @return the font metrics for control
- */
- protected FontMetrics getDialogUnits(Control control) {
- if (_fontMetrics == null) {
- // Compute and store a font metric
- GC gc = new GC(control);
- gc.setFont(control.getFont());
- _fontMetrics = gc.getFontMetrics();
- gc.dispose();
- }
- return _fontMetrics;
- }
-
- /**
- * Returns the number of columns of the dialog field. To be reimplemented by
- * dialog field implementors.
- */
- public int getNumberOfControls() {
- return 1;
- }
-
- /**
- * @param span
- * @return a new GridData for the horizontal 'span' value
- */
- protected static GridData gridDataForLabel(int span) {
- GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
- gd.horizontalSpan = span;
- return gd;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created label widget.
- *
- * @param parent
- * The parent composite or <code>null</code> if the widget has
- * already been created.
- */
- public Control getLabelControl(FormToolkit _formToolkit, Composite parent) {
- Control control = null;
- if ((_label == null || _label.isDisposed()) && (_hyperlink == null || _hyperlink.isDisposed())) {
- assertCompositeNotNull(parent);
-
- String label = null;
- if (_labelText != null && !"".equals(_labelText)) { //$NON-NLS-1$
- //$NON-NLS-1$
- label = _labelText;
- } else {
- label = "."; //$NON-NLS-1$
- }
-
- if (_listener == null) {
- control = createLabel(_formToolkit, parent, label);
- } else {
- control = createHyperlink(_formToolkit, parent, label);
- }
- /**
- * if(isRequired) { FontData[] fontData =
- * parent.getFont().getFontData(); FontData[] newFontData = new
- * FontData[fontData.length]; for(int i=0; i<fontData.length; i++) {
- * newFontData[i] = new FontData(fontData[i].getName(),
- * fontData[i].getHeight(), fontData[i].getStyle() | SWT.BOLD); }
- * final Font font = new Font(control.getDisplay(),newFontData);
- * control.setFont(font); control.addDisposeListener(new
- * DisposeListener() {
- *
- * public void widgetDisposed(DisposeEvent e) { font.dispose(); }
- * }); } else { control.setFont(parent.getFont()); }
- */
- control.setFont(parent.getFont());
- control.setEnabled(_enabled);
- } else {
- if (_label != null) {
- control = _label;
- } else {
- control = _hyperlink;
- }
- }
- return control;
- }
-
- /**
- * @param _formToolkit
- * @param parent
- * @return get the Label control for required
- */
- public Control getRequiredLabelControl(FormToolkit _formToolkit,
- Composite parent) {
- if (_requiredLabel == null || _requiredLabel.isDisposed()) {
- if (_formToolkit == null) {
- _requiredLabel = new Label(parent, SWT.LEFT | SWT.WRAP);
- } else {
- _requiredLabel = _formToolkit.createLabel(parent, "", SWT.LEFT //$NON-NLS-1$
- | SWT.WRAP);
- _requiredLabel.setForeground(getLabelColor());
- }
- if (_isRequired) {
- _requiredLabel.setText(DialogFieldResources.getInstance()
- .getString("DialogFieldBase.Label.RequiredSymbol")); //$NON-NLS-1$
- }
- }
- return _requiredLabel;
- }
-
- private Control createLabel(FormToolkit _formToolkit, Composite parent,
- String labelString) {
- if (_formToolkit == null) {
- _label = new Label(parent, SWT.LEFT | SWT.WRAP);
- _label.setText(labelString);
- } else {
- _label = _formToolkit.createLabel(parent, labelString, SWT.LEFT
- | SWT.WRAP);
- _label.setForeground(getLabelColor());
- }
- return _label;
- }
-
- /**
- * get color for label
- */
- private Color getLabelColor() {
- String osname = System.getProperty("os.name").toLowerCase(); //$NON-NLS-1$
- if (osname.startsWith("mac os")) { //$NON-NLS-1$
- return Display.getCurrent().getSystemColor(
- SWT.COLOR_LIST_FOREGROUND);
- }
- return Display.getCurrent()
- .getSystemColor(SWT.COLOR_LIST_SELECTION);
- }
-
- private Control createHyperlink(FormToolkit _formToolkit, Composite parent,
- String label) {
- if (_formToolkit == null) {
- _hyperlink = new Hyperlink(parent, SWT.LEFT | SWT.WRAP);
- _hyperlink.setForeground(getLabelColor());
- _hyperlink.setUnderlined(true);
- _hyperlink.addMouseTrackListener(new MouseTrackAdapter() {
-
- public void mouseEnter(MouseEvent e) {
- _hyperlink.setForeground(Display.getCurrent()
- .getSystemColor(SWT.COLOR_BLUE));
- }
-
- public void mouseExit(MouseEvent e) {
- _hyperlink.setForeground(getLabelColor());
- }
- });
- _hyperlink.setText(label);
- } else {
- _hyperlink = _formToolkit.createHyperlink(parent, label, SWT.LEFT
- | SWT.WRAP);
- }
- _hyperlink.addHyperlinkListener(_listener);
- return _hyperlink;
- }
-
- /**
- * Creates a spacer control.
- * @param toolkit
- *
- * @param parent
- * The parent composite
- * @return a spacer control
- */
- public Control createEmptySpace(FormToolkit toolkit, Composite parent) {
- return createEmptySpace(toolkit, parent, 1);
- }
-
- /**
- * Creates a spacer control with the given span. The composite is assumed to
- * have <code>MGridLayout</code> as layout.
- * @param toolkit
- *
- * @param parent
- * The parent composite
- * @param span
- * @return a label that creates empty space
- */
- public Control createEmptySpace(FormToolkit toolkit, Composite parent,
- int span) {
- Label label;
- if (toolkit != null) {
- label = toolkit.createLabel(parent, ""); //$NON-NLS-1$
- } else {
- label = new Label(parent, SWT.LEFT);
- }
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.BEGINNING;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- gd.horizontalIndent = 0;
- gd.widthHint = 0;
- gd.heightHint = 0;
- label.setLayoutData(gd);
- return label;
- }
-
- /**
- * Tests is the control is not <code>null</code> and not disposed.
- * @param control
- * @return true if the control is valid for use
- */
- protected final boolean isOkToUse(Control control) {
- return (control != null) && !(control.isDisposed());
- }
-
- // --------- enable / disable management
-
- /**
- * Sets the enable state of the dialog field.
- */
- public final void setEnabled(boolean enabled) {
- if (enabled != _enabled) {
- _enabled = enabled;
- updateEnableState();
- }
- }
-
- /**
- * Called when the enable state changed. To be extended by dialog field
- * implementors.
- */
- protected void updateEnableState() {
- if (_label != null && !_label.isDisposed()) {
- _label.setEnabled(_enabled);
- }
- if (_hyperlink != null && !_hyperlink.isDisposed()) {
- _hyperlink.setEnabled(_enabled);
- }
- }
-
- /**
- * Gets the enable state of the dialog field.
- */
- public final boolean isEnabled() {
- return _enabled;
- }
-
- /**
- * @param comp
- */
- protected final void assertCompositeNotNull(Composite comp) {
- Assert.isNotNull(comp,
- "uncreated control requested with composite null"); //$NON-NLS-1$
- }
-
- /**
- * @param nColumns
- */
- protected final void assertEnoughColumns(int nColumns) {
- Assert.isTrue(nColumns >= getNumberOfControls(),
- "given number of columns is too small"); //$NON-NLS-1$
- }
-
- /**
- * Get attached data by key.
- *
- * @param key
- * @return the attached data object for key
- */
- public Object getAttachedData(Object key) {
- if (_attachedData != null) {
- return _attachedData.get(key);
- }
- return null;
- }
-
- /**
- * You can attach any data to the DialogField, and get it using the
- * <code>getAttachedData</code> method.
- *
- * @param key
- * @param value
- */
- public void putAttachedData(Object key, Object value) {
- if (_attachedData == null) {
- _attachedData = new HashMap();
- }
- _attachedData.put(key, value);
- }
-
- /**
- * this method give the DialogField a chance to set the correct column to
- * grab horizontal space. In the implementation of this method, should only
- * change the GridData of control, should not do anything else.
- *
- * The caller is responsible to make sure the controls for the dialog field
- * has been created before calling this method.
- */
- public void handleGrabHorizontal() {
- // do nothing.
- }
-
- public boolean isRequired() {
- return _isRequired;
- }
-
- /**
- * @param isRequired
- */
- public void setRequired(boolean isRequired) {
- this._isRequired = isRequired;
- }
-
- /**
- * @return gthe tool tip text
- */
- protected String getToolTip() {
- return toolTip;
- }
-
- public void setToolTip(String toolTip) {
- this.toolTip = toolTip;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroup.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroup.java
deleted file mode 100644
index 0ed7b3a66..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroup.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * This class represents a group of dialog fields, following the normal dialog
- * field's lifecycle.
- *
- * The design of this class is to make a section could be reused in both dialog
- * environment and form based editor environment.
- *
- * @author mengbo
- */
-public abstract class DialogFieldGroup {
- private IDialogFieldChangeListener _defaultChangeListener;
-
- private IDialogFieldApplyListener _defaultApplyListener;
-
- /**
- * set default handler, should be called before <code>initialize()</code>
- * @param changelistener
- *
- */
- public void setDefaultChangeListener(
- IDialogFieldChangeListener changelistener) {
- _defaultChangeListener = changelistener;
- }
-
- /**
- * Normally, the client should call this method in <code>initialize()</code>
- * for those field that wants to use the default event handler.
- *
- * @return could be null
- */
- public IDialogFieldChangeListener getDefaultChangeListener() {
- return _defaultChangeListener;
- }
-
- /**
- * set default handler, should be called before <code>initialize()</code>
- *
- * @param applylistener
- */
- public void setDefaultApplyListener(IDialogFieldApplyListener applylistener) {
- _defaultApplyListener = applylistener;
- }
-
- /**
- * Normally, the client should call this method in <code>initialize()</code>
- * for those field that wants to use the default event handler.
- *
- * @return could be null
- */
- public IDialogFieldApplyListener getDefaultApplyListener() {
- return _defaultApplyListener;
- }
-
- /**
- * it is supposed to create all dialog fields and setup event listeners in
- * this method.
- *
- * Normally client will create DialogFieldSection first, then
- * setDefaultChangeListener()/setDefaultApplyListener(), then call
- * initialize().
- */
- public abstract void initialize();
-
- /**
- * reload data from underlying model and set them into the dialog fields.
- *
- */
- public abstract void refreshData();
-
- /**
- * layout the dialog fields.
- *
- * @param toolkit
- * could be null
- * @param parent
- *
- */
- public abstract void layoutDialogFields(FormToolkit toolkit,
- Composite parent);
-
- /**
- * validate whether the values in the dialog fields are valid. This method
- * should also enable/disable dialog fields based on their current value and
- * relationship
- *
- * @return could return null. or an array containing null elements.
- */
- public abstract IStatus[] validateDialogFields();
-
- /**
- * Intended to allow subclasses to recreate controls. Default implementation does nothing.
- */
- public void reset(){
- //do nothing by default
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroupPage.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroupPage.java
deleted file mode 100644
index 2e10f45e3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldGroupPage.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * @author mengbo
- */
-public class DialogFieldGroupPage extends WizardPage {
- private DialogFieldGroup _group;
-
- private IDialogFieldChangeListener _defaultChangeListener = new IDialogFieldChangeListener() {
- public void dialogFieldChanged(DialogField field) {
- validate();
- }
- };
-
- /**
- * @param pageName
- * @param section
- */
- public DialogFieldGroupPage(String pageName, DialogFieldGroup section) {
- super(pageName);
- _group = section;
- initializeGroup(_group);
- }
-
- /**
- * child class could override this method.
- *
- * @param group
- */
- protected void initializeGroup(DialogFieldGroup group) {
- group.setDefaultChangeListener(_defaultChangeListener);
- group.initialize();
- }
-
- public void createControl(Composite parent) {
- Composite container = new Composite(parent, SWT.NONE);
- _group.layoutDialogFields(null, container);
- _group.refreshData();
- validate();
- this.setControl(container);
- }
-
- /**
- * @return the dialog field group
- */
- public DialogFieldGroup getDialogFieldGroup() {
- return _group;
- }
-
- /**
- * validate all the dialog fields. Updates
- * status line and sets page completion if there are no errors
- */
- private void validate() {
- IStatus[] statuses = _group.validateDialogFields();
- IStatus status = StatusUtil.getMostSevere(statuses);
- StatusUtil.applyToStatusLine(this, status);
- setPageComplete(status == null || status.getSeverity() != IStatus.ERROR);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.java
deleted file mode 100644
index 30828e6b7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.common.ui.internal.utils.ResourceUtils;
-
-/**
- * Resource bundle class for datastore wizard and it's pages
- *
- * @author mengbo
- */
-/*package*/ class DialogFieldResources extends ResourceUtils {
- /** Create the logger for this class */
- private static Logger _log = JSFUICommonPlugin
- .getLogger(DialogFieldResources.class);
-
- private static DialogFieldResources _resource; // singleton
-
- private static final String BUNDLE = DialogFieldResources.class.getName();
-
- /**
- * Empty Constructor.
- *
- * @return WizardsResources
- */
-
- public static DialogFieldResources getInstance() {
- if (_resource == null) {
- _resource = new DialogFieldResources();
- }
- return _resource;
- }
-
- /**
- * The constructor create a resource bundle
- */
- protected DialogFieldResources() {
- try {
- _resources = ResourceBundle.getBundle(BUNDLE);
- // NOTE: this throws a runtime "MissingResourceException".
- } catch (MissingResourceException ee) {
- // Wizards.WizardResource.Error.ResourceNotFound = Unable to locate
- // resource.
- _log.error("Wizards.WizardResource.Error.ResourceNotFound", ee); //$NON-NLS-1$
- }
- setBundle(_resources, BUNDLE);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.properties
deleted file mode 100644
index ad34404dd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/DialogFieldResources.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-##################################################################
-# Resource message for SourceFolderButtonDialogField.
-##################################################################
-SourceFolderButtonDialogField.container.label = Source Folder:
-SourceFolderButtonDialogField.container.button = Browse...
-
-SourceFolderButtonDialogField.ChooseSourceContainerDialog.Title = Folder Selection
-SourceFolderButtonDialogField.ChooseSourceContainerDialog.Description = Choose a folder:
-
-SourceFolderButtonDialogField.error.EnterContainerName = Folder name is empty.
-SourceFolderButtonDialogField.error.NotSameProject = The project should be \''{0}\''.
-SourceFolderButtonDialogField.error.ContainerIsBinary=''{0}'' is a JAR archive.
-SourceFolderButtonDialogField.error.ContainerDoesNotExist=Folder ''{0}'' does not exist.
-SourceFolderButtonDialogField.error.NotAFolder=''{0}'' must be a project or folder.
-SourceFolderButtonDialogField.error.ProjectClosed=Project ''{0}'' must be accessible.
-SourceFolderButtonDialogField.warning.NotAJavaProject=Folder ''{0}'' is not a Java project.
-SourceFolderButtonDialogField.warning.NotInAJavaProject=Folder ''{0}'' is not in a Java project.
-SourceFolderButtonDialogField.warning.NotOnClassPath=Folder ''{0}'' is not on the Java build class path.
-
-
-##################################################################
-# Resource message for PackageButtonDialogField.
-##################################################################
-PackageButtonDialogField.package.label=Pac&kage:
-PackageButtonDialogField.package.button=Bro&wse...
-
-PackageButtonDialogField.error.InvalidPackageName=Package name ''{0}'' is not valid.
-PackageButtonDialogField.error.ClashOutputLocation=Package clashes with project output folder.
-PackageButtonDialogField.warning.DiscouragedPackageName=This package name ''{0}'' is discouraged.
-PackageButtonDialogField.warning.DefaultPackageDiscouraged=The use of the default package is discouraged.
-
-PackageButtonDialogField.ChoosePackageDialog.title=Package Selection
-PackageButtonDialogField.ChoosePackageDialog.description=&Choose a folder:
-PackageButtonDialogField.ChoosePackageDialog.empty=Cannot find packages to select.
-
-ClassButtonDialogField.Alert.Title=Error Open Type
-ClassButtonDialogField.Alert.Msg=The project does not have Java Nature.
-DialogFieldBase.Label.RequiredSymbol=* \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldApplyListener.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldApplyListener.java
deleted file mode 100644
index e8be7b8f8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldApplyListener.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-
-/**
- * @author mengbo
- */
-public interface IDialogFieldApplyListener {
- /**
- * when the DialogField believe it should apply its value in UI, will fire
- * this event.
- *
- * Normally, for text input, when user is typing, will only fire
- * dialogFieldChanged(), when lose focus will fire dialogFieldApplied().
- *
- * For other control, such as readonly combo box, whenever user change
- * selection, will fire both dialogFieldChanged() and dialogFieldApplied()
- *
- * @param field
- */
- void dialogFieldApplied(DialogField field);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldChangeListener.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldChangeListener.java
deleted file mode 100644
index b5ead67e0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IDialogFieldChangeListener.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-
-/**
- * Change listener used by <code>DialogField</code>
- *
- * @author mengbo
- */
-public interface IDialogFieldChangeListener {
-
- /**
- * The dialog field has changed.
- * @param field
- */
- void dialogFieldChanged(DialogField field);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IStringButtonAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IStringButtonAdapter.java
deleted file mode 100644
index 466e35578..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/IStringButtonAdapter.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-
-/**
- * Change listener used by <code>StringButtonDialogField</code>
- */
-public interface IStringButtonAdapter {
-
- /**
- * @param field
- */
- void changeControlPressed(DialogField field);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ISupportTextValue.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ISupportTextValue.java
deleted file mode 100644
index 014752d66..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ISupportTextValue.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-/**
- * DialogField can choose to also implement this interface. The purpose of this
- * interface is to make DialogFields to be more easily used to edit element
- * attributes, since attributes are all of string type.
- *
- * @author mengbo
- * @version 1.5
- */
-public interface ISupportTextValue {
- /**
- * @param value
- */
- public void setTextWithoutUpdate(String value);
-
- /**
- * @return the text
- */
- public String getText();
-
- /**
- * @param value
- */
- public void setText(String value);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizard.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizard.java
deleted file mode 100644
index 745874044..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizard.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.lang.reflect.InvocationTargetException;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.jface.operation.IRunnableWithProgress;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.wizards.newresource.BasicNewResourceWizard;
-
-/**
- * @author mengbo
- */
-/*package*/ class JavaClassWizard extends Wizard {
- private static String STORE_SECTION = "JavaClassWizard"; //$NON-NLS-1$
-
- private JavaClassWizardPage _mainPage;
-
- private String _className, _classArgs;
-
- private IProject _project;
-
- private String _superClass;
-
- private List _interfaceList;
-
- private boolean _autoOpenResource = true;
-
- /**
- * @param autoOpenResource
- */
- public void setAutoOpenResource(boolean autoOpenResource) {
- _autoOpenResource = autoOpenResource;
- }
-
- /**
- * @param project
- * @param className
- */
- public JavaClassWizard(IProject project, String className) {
- this(project, className, null, null);
- }
-
- /**
- * @param project
- * @param className
- * @param superClass
- * @param superInterfaces
- */
- public JavaClassWizard(IProject project, String className,
- String superClass, List superInterfaces) {
- this._project = project;
- this._className = className;
- this._superClass = superClass;
- this._interfaceList = superInterfaces;
- IDialogSettings masterSettings = JSFUICommonPlugin.getDefault()
- .getDialogSettings();
- setDialogSettings(getSettingsSection(masterSettings));
- setWindowTitle(JSFUICommonPlugin
- .getResourceString("DialogField.JavaClassWizard.NewClass"));//$NON-NLS-1$
- setNeedsProgressMonitor(true);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.wizard.IWizard#addPages()
- */
- public void addPages() {
- _mainPage = new JavaClassWizardPage(_project, _className, _superClass,
- _interfaceList);
- addPage(_mainPage);
- _mainPage.init();
- }
-
- private IDialogSettings getSettingsSection(IDialogSettings master) {
- IDialogSettings setting = master.getSection(STORE_SECTION);
- if (setting == null) {
- setting = master.addNewSection(STORE_SECTION);
- }
- return setting;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.wizard.IWizard#performFinish()
- */
- public boolean performFinish() {
- if (_mainPage.getPackageText() != null
- && _mainPage.getPackageText().length() > 0) {
- StringBuffer buffer = new StringBuffer(_mainPage.getPackageText());
- buffer.append(".");//$NON-NLS-1$
- buffer.append(_mainPage.getTypeName());
- _className = buffer.toString();
- } else {
- _className = _mainPage.getTypeName();
- }
- _classArgs = _mainPage.getClassArgs();
- IRunnableWithProgress op = new WorkspaceModifyOperation() {
- protected void execute(IProgressMonitor monitor)
- throws CoreException, InvocationTargetException,
- InterruptedException {
- _mainPage.createType(monitor);
- IResource resource = _mainPage.getModifiedResource();
- if (resource != null && _autoOpenResource) {
- selectAndReveal(resource);
- if (_project.hasNature(JavaCore.NATURE_ID)) {
- IJavaProject jProject = JavaCore.create(_project);
- IJavaElement jElement = jProject.findElement(resource
- .getProjectRelativePath()
- .removeFirstSegments(1));
- if (jElement != null) {
- JavaUI.openInEditor(jElement);
- }
- } else if (resource instanceof IFile) {
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
- IDE.openEditor(page, (IFile) resource, true);
- }
- }
- }
-
- };
- try {
- getContainer().run(false, true, op);
- } catch (InvocationTargetException e) {
- e.printStackTrace(); // PDEPlugin.logException(e);
- } catch (InterruptedException e) {
- e.printStackTrace();// PDEPlugin.logException(e);
- }
- return true;
- }
-
- private void selectAndReveal(IResource newResource) {
- BasicNewResourceWizard.selectAndReveal(newResource,
- getWorkbenchWindow());
- }
-
- private IWorkbenchWindow getWorkbenchWindow() {
- return PlatformUI.getWorkbench().getActiveWorkbenchWindow();
- }
-
- private String getClassName() {
- return _className;
- }
-
- /**
- * @return the class name including args
- */
- public String getClassNameWithArgs() {
- if (_classArgs != null && _classArgs.length() > 0) {
- StringBuffer buffer = new StringBuffer(_className);
- buffer.append(":");//$NON-NLS-1$
- buffer.append(_classArgs);
- return buffer.toString();
- }
- return getClassName();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizardPage.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizardPage.java
deleted file mode 100644
index b445c60c2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizardPage.java
+++ /dev/null
@@ -1,249 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.List;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.JavaConventions;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.ui.wizards.NewClassWizardPage;
-
-/**
- * @author mengbo
- */
-/*package*/ class JavaClassWizardPage extends NewClassWizardPage {
- private String _className;
-
- private final IProject _project;
-
- private final InitialClassProperties _initialValues;
-
- private IJavaProject _javaProject;
-
- private IStatus _fClassNameStatus, _fPackageNameStatus;
-
- private final static String SOURCE_COMPLIANCE_1_3 = JavaCore.VERSION_1_3;
-
- static class InitialClassProperties {
- // populate new wizard page
- private String superClassName;
-
- private List interfacesName;
-
- private String className;
-
- private String classArgs;
-
- private String packageName;
-
- private IPackageFragmentRoot packageFragmentRoot;
-
- private IPackageFragment packageFragment;
-
- InitialClassProperties() {
- this.superClassName = ""; //$NON-NLS-1$
- this.interfacesName = null;
- this.className = null;
- this.classArgs = null;
- this.packageName = null;
- this.packageFragment = null;
- this.packageFragmentRoot = null;
- }
- }
-
- /**
- * @param project
- * @param className
- * @param superClassName
- * @param interfacesName
- */
- public JavaClassWizardPage(IProject project, String className,
- String superClassName, List interfacesName) {
- super();
- this._className = className;
- this._project = project;
- try {
- if (project != null && project.hasNature(JavaCore.NATURE_ID)) {
- this._javaProject = JavaCore.create(project);
- } else {
- this._javaProject = null;
- }
- } catch (CoreException e) {
- e.printStackTrace();// PDEPlugin.logException(e);
- }
- _initialValues = new InitialClassProperties();
- _initialValues.className = className;
- _initialValues.superClassName = superClassName;
- _initialValues.interfacesName = interfacesName;
- }
-
- /**
- * @param project
- * @param className
- */
- public JavaClassWizardPage(IProject project, String className) {
- this(project, className, null, null);
- }
-
- /**
- * Call when page is added to wizard to initialize
- */
- public void init() {
- initializeExpectedValues();
- initializeWizardPage();
- }
-
- private void initializeExpectedValues() {
- // source folder name, package name, class name
- int loc = _className.indexOf(":"); //$NON-NLS-1$
- if (loc != -1) {
- if (loc < _className.length()) {
- _initialValues.classArgs = _className.substring(loc + 1,
- _className.length());
- _className = _className.substring(0, loc);
- }
- if (loc > 0) {
- _initialValues.className = _className.substring(0, loc);
- } else if (loc == 0) {
- _initialValues.className = ""; //$NON-NLS-1$
- }
- }
- _fClassNameStatus = JavaConventions
- .validateJavaTypeName(_initialValues.className, SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
-
- loc = _className.lastIndexOf('.');
- if (loc != -1) {
- _initialValues.packageName = _className.substring(0, loc);
- _initialValues.className = _className.substring(loc + 1);
- _fPackageNameStatus = JavaConventions
- .validateJavaTypeName(_initialValues.packageName, SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
- _fClassNameStatus = JavaConventions
- .validateJavaTypeName(_initialValues.className, SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
- }
- if (_javaProject == null) {
- return;
- }
- try {
- if (_initialValues.packageFragmentRoot == null) {
- IPackageFragmentRoot srcEntryDft = null;
- IPackageFragmentRoot[] roots = _javaProject
- .getPackageFragmentRoots();
- for (int i = 0; i < roots.length; i++) {
- if (roots[i].getKind() == IPackageFragmentRoot.K_SOURCE) {
- srcEntryDft = roots[i];
- break;
- }
- }
- if (srcEntryDft != null) {
- _initialValues.packageFragmentRoot = srcEntryDft;
- } else {
- _initialValues.packageFragmentRoot = _javaProject
- .getPackageFragmentRoot(_javaProject.getResource());
- }
- if (_initialValues.packageFragment == null
- && _initialValues.packageFragmentRoot != null
- && _initialValues.packageName != null
- && _initialValues.packageName.length() > 0) {
- IFolder packageFolder = _project
- .getFolder(_initialValues.packageName);
- _initialValues.packageFragment = _initialValues.packageFragmentRoot
- .getPackageFragment(packageFolder
- .getProjectRelativePath().toOSString());
- }
- }
- // superclass and interface
- if (_initialValues.superClassName == null) {
- _initialValues.superClassName = "java.lang.Object"; //$NON-NLS-1$
- }
-// _initialValues.superClassType = findTypeForName(_initialValues.superClassName);
- } catch (JavaModelException e) {
- e.printStackTrace();// PDEPlugin.logException(e);
- }
- }
-
- /**
- * initialize the wizard page
- */
- protected void initializeWizardPage() {
- setPackageFragmentRoot(_initialValues.packageFragmentRoot, true);
- setPackageFragment(_initialValues.packageFragment, true);
- setEnclosingType(null, true);
- setEnclosingTypeSelection(false, true);
- setTypeName(_initialValues.className, true);
- setSuperClass(_initialValues.superClassName, true);
- if (_initialValues.interfacesName != null) {
- setSuperInterfaces(_initialValues.interfacesName, true);
- }
- boolean hasSuperClass = _initialValues.superClassName != null
- && _initialValues.superClassName.length() > 0;
- boolean hasInterface = _initialValues.interfacesName != null
- && _initialValues.interfacesName.size() > 0;
- setMethodStubSelection(false, hasSuperClass, hasInterface
- || hasSuperClass, true);
- }
-
-// private IType findTypeForName(String typeName) throws JavaModelException {
-// if (typeName == null || typeName.length() == 0) {
-// return null;
-// }
-// IType type = null;
-// String fileName = typeName.replace('.', '/') + ".java"; //$NON-NLS-1$
-// IJavaElement element = _javaProject.findElement(new Path(fileName));
-// if (element == null) {
-// return null;
-// }
-// if (element instanceof IClassFile) {
-// type = ((IClassFile) element).getType();
-// } else if (element instanceof ICompilationUnit) {
-// IType[] types = ((ICompilationUnit) element).getTypes();
-// type = types[0];
-// }
-// return type;
-// }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.ui.wizards.NewClassWizardPage#setVisible(boolean)
- */
- public void setVisible(boolean visible) {
- super.setVisible(visible);
- // policy: wizards are not allowed to come up with an error message;
- // in this wizard, some fields may need initial validation and thus,
- // potentially start with an error message.
- if (_fClassNameStatus != null && !_fClassNameStatus.isOK()) {
- updateStatus(_fClassNameStatus);
- }
- if (_fPackageNameStatus != null && !_fPackageNameStatus.isOK()) {
- updateStatus(_fPackageNameStatus);
- }
- }
-
- /**
- * @return the class arguments or "" if not set
- */
- public String getClassArgs() {
- if (_initialValues.classArgs == null) {
- return ""; //$NON-NLS-1$
- }
- return _initialValues.classArgs;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScope.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScope.java
deleted file mode 100644
index 8ac58072d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScope.java
+++ /dev/null
@@ -1,221 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-
-/**
- * @author mengbo
- */
-/*package*/ class JavaSearchScope implements IJavaSearchScope {
- private final IProject _project;
-
- private final String _superType;
-
- private HashSet _allowedTypeSet;
-
- private IPath[] _enclosingProjectsAndJars;
-
- private IProject[] _relativeProjects;
-
- /**
- * @param project
- * @param superType
- */
- public JavaSearchScope(IProject project, String superType) {
- this._project = project;
- this._superType = superType;
- computeRelativeProjects();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#enclosingProjectsAndJars()
- */
- public IPath[] enclosingProjectsAndJars() {
- if (_enclosingProjectsAndJars == null) {
- ArrayList list = new ArrayList();
- for (int i = 0; i < _relativeProjects.length; i++) {
- try {
- if (_relativeProjects[i].hasNature(JavaCore.NATURE_ID)) {
- IJavaProject javaProject = JavaCore
- .create(_relativeProjects[i]);
- IClasspathEntry[] classpath = javaProject
- .getResolvedClasspath(true);
- for (int j = 0; j < classpath.length; j++) {
- list.add(classpath[j].getPath());
- }
- list.add(javaProject.getPath());
- }
- } catch (CoreException e)// NOPMD
- {
- // skip the project.
- }
- }
- _enclosingProjectsAndJars = (IPath[]) list.toArray(new IPath[(list
- .size())]);
- }
- return _enclosingProjectsAndJars;
- }
-
- private void computeRelativeProjects() {
- try {
- IProject[] referencedProjects = _project.getReferencedProjects();
- _relativeProjects = new IProject[referencedProjects.length + 1];
- System.arraycopy(referencedProjects, 0, _relativeProjects, 1,
- referencedProjects.length);
- _relativeProjects[0] = _project;
- } catch (CoreException e) {
- _relativeProjects = new IProject[] { _project };
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#encloses(java.lang.String)
- */
- public boolean encloses(String resourcePath) {
- if (_allowedTypeSet == null) {
- try {
- _allowedTypeSet = findAllowedTypes(_superType);
- } catch (CoreException e) {
- e.printStackTrace();
- }
- }
- if (_allowedTypeSet == null) {
- _allowedTypeSet = new HashSet();
- }
- int separatorIndex = resourcePath.indexOf(JAR_FILE_ENTRY_SEPARATOR);
- if (separatorIndex != -1) {
- String className = resourcePath.substring(separatorIndex + 1,
- resourcePath.length() - 6).replace('/', '.');
- if (_allowedTypeSet.contains(className)) {
- return true;
- }
- } else if (_allowedTypeSet.contains(resourcePath)) {
- return true;
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#encloses(org.eclipse.jdt.core.IJavaElement)
- */
- public boolean encloses(IJavaElement element) {
- return encloses(element.getPath().toString());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#includesBinaries()
- */
- public boolean includesBinaries() {
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#includesClasspaths()
- */
- public boolean includesClasspaths() {
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#setIncludesBinaries(boolean)
- */
- public void setIncludesBinaries(boolean includesBinaries) {
- // do nothing, includeBinaries always true
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#setIncludesClasspaths(boolean)
- */
- public void setIncludesClasspaths(boolean includesClasspaths) {
- // do nothing, includeClasspaths always trues
- }
-
- private HashSet findAllowedTypes(String superType) throws CoreException {
- HashSet set = new HashSet();
-
- IProject[] projects = _relativeProjects;
-
- for (int i = 0; i < projects.length; i++) {
- IType type = null;
- if (projects[i].hasNature(JavaCore.NATURE_ID)) {
- IJavaProject javaProject = JavaCore.create(projects[i]);
- if (superType != null) {
- try {
- type = javaProject.findType(superType);
- if (type != null) {
- ITypeHierarchy typeHierarchy = type
- .newTypeHierarchy(javaProject, null);
- IType[] subtypes = typeHierarchy
- .getAllSubtypes(type);
- for (int j = 0; j < subtypes.length; j++) {
- if (!subtypes[j].isBinary()) {
- set.add(subtypes[j].getPath().toString());
- } else {
- String path = subtypes[j].getPath()
- .toString();
- if (path != null
- && path
- .endsWith(IFileFolderConstants.DOT
- + IFileFolderConstants.EXT_JAR)) {
- set.add(subtypes[j]
- .getFullyQualifiedName());
- } else {
- set.add(path);
- }
- }
- }
- }
- } catch (JavaModelException e) {
- e.printStackTrace();
- }
- }
- }
- }
- return set;
- }
-
- /**
- * @return Returns the superType.
- */
- public String getSuperType() {
- return _superType;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScopeDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScopeDecorator.java
deleted file mode 100644
index 94cd55ca1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaSearchScopeDecorator.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-/*package*/ class JavaSearchScopeDecorator implements IJavaSearchScope {
- JavaSearchScope[] _scopes = new JavaSearchScope[0];
-
- /**
- * @param project
- * @param superTypes
- */
- public JavaSearchScopeDecorator(IProject project, List superTypes) {
- List scopeList = new ArrayList();
- if (superTypes != null) {
- for (int i = 0; i < superTypes.size(); i++) {
- scopeList.add(new JavaSearchScope(project, superTypes.get(i)
- .toString()));
- }
- }
- _scopes = (JavaSearchScope[]) scopeList
- .toArray(new JavaSearchScope[scopeList.size()]);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#encloses(java.lang.String)
- */
- public boolean encloses(String resourcePath) {
- for (int i = 0; i < _scopes.length; i++) {
- if (_scopes[i].encloses(resourcePath) == true) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#encloses(org.eclipse.jdt.core.IJavaElement)
- */
- public boolean encloses(IJavaElement element) {
- for (int i = 0; i < _scopes.length; i++) {
- if (_scopes[i].encloses(element) == true) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#enclosingProjectsAndJars()
- */
- public IPath[] enclosingProjectsAndJars() {
- Set set = new HashSet();
- for (int i = 0; i < _scopes.length; i++) {
- set.addAll(Arrays.asList(_scopes[i].enclosingProjectsAndJars()));
- }
- return (IPath[]) set.toArray(new IPath[set.size()]);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#includesBinaries()
- */
- public boolean includesBinaries() {
- for (int i = 0; i < _scopes.length; i++) {
- if (_scopes[i].includesBinaries() == true) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#includesClasspaths()
- */
- public boolean includesClasspaths() {
- for (int i = 0; i < _scopes.length; i++) {
- if (_scopes[i].includesClasspaths() == true) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#setIncludesBinaries(boolean)
- */
- public void setIncludesBinaries(boolean includesBinaries) {
- for (int i = 0; i < _scopes.length; i++) {
- _scopes[i].setIncludesBinaries(includesBinaries);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jdt.core.search.IJavaSearchScope#setIncludesClasspaths(boolean)
- */
- public void setIncludesClasspaths(boolean includesClasspaths) {
- for (int i = 0; i < _scopes.length; i++) {
- _scopes[i].setIncludesClasspaths(includesClasspaths);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaUIHelper.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaUIHelper.java
deleted file mode 100644
index 8bee86022..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaUIHelper.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jdt.core.search.SearchEngine;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.dialogs.ProgressMonitorDialog;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.ide.IDE;
-
-/**
- * @author mengbo
- */
-public final class JavaUIHelper {
- /**
- * @param project
- * @param className
- */
- static void doOpenClass(IProject project, String className) {
- String path = className.replace('.', '/') + ".java"; //$NON-NLS-1$
- try {
- if (project.hasNature(JavaCore.NATURE_ID)) {
- IJavaProject javaProject = JavaCore.create(project);
- IJavaElement result = javaProject.findElement(new Path(path));
- JavaUI.openInEditor(result);
- } else {
- IResource resource = project.findMember(new Path(path));
- if (resource instanceof IFile) {
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
- IDE.openEditor(page, (IFile) resource, true);
- }
- }
- } catch (PartInitException e) {
- e.printStackTrace();// PDEPlugin.logException(e);
- } catch (JavaModelException e) {
- e.printStackTrace();// Display.getCurrent().beep();
- } catch (CoreException e) {
- e.printStackTrace();// PDEPlugin.logException(e);
- }
- }
-
- /**
- * @param project
- * @param className
- * @return true if the class exists in project
- */
- static boolean doesClassExist(IProject project, String className) {
- String path = className.replace('.', '/') + ".java"; //$NON-NLS-1$
- try {
- if (project.hasNature(JavaCore.NATURE_ID)) {
- IJavaProject javaProject = JavaCore.create(project);
-
- IJavaElement result = javaProject.findElement(new Path(path));
- return result != null;
- }
- IResource resource = project.findMember(new Path(path));
- return resource != null;
- } catch (JavaModelException e) {
- return false;
- } catch (CoreException e) {
- return false;
- }
- }
-
- /**
- * @param shell
- * @param searchScope
- * @param typeFlag
- * @return the selection dialog
- */
- static SelectionDialog openSelectionDialog(Shell shell,
- IJavaSearchScope searchScope, int typeFlag) {
- try {
- return JavaUI.createTypeDialog(shell, new ProgressMonitorDialog(
- shell), searchScope, typeFlag, false);
- } catch (JavaModelException e) {
- JSFUICommonPlugin.getLogger(JavaUIHelper.class).error(e);
- return null;
- }
- }
-
- /**
- * @param shell
- * @param project
- * @param superType
- * @param typeFlag
- * @return the selection dialog
- */
- public static SelectionDialog openSelectionDialog(Shell shell,
- IProject project, String superType, int typeFlag) {
- IJavaSearchScope searchScope = findSearchScope(project, superType);
- return openSelectionDialog(shell, searchScope, typeFlag);
- }
-
- /**
- * @param project
- * @param superType
- * @return the search scope
- */
- static IJavaSearchScope findSearchScope(IProject project,
- String superType) {
- if (project != null) {
- if (superType == null || "".equals(superType)) { //$NON-NLS-1$
- superType = "java.lang.Object";//$NON-NLS-1$
- }
- return new JavaSearchScope(project, superType);
- }
- return SearchEngine.createWorkspaceScope();
- }
-
- private JavaUIHelper()
- {
- // static helper, no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/LayoutUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/LayoutUtil.java
deleted file mode 100644
index 2457cd153..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/LayoutUtil.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.FontMetrics;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * A layout utility class
- *
- */
-public final class LayoutUtil {
- // The Text control looks higher then Button control when they have the same
- // height,
- // Increasing the height of 5 pixels will make them looks the same height.
- private final static int BUTTON_HEIGHT_ADJUSTMENT = 5;
-
-
- /**
- * @param control
- * @param grab
- */
- public static void setGrabHorizontal(Control control, boolean grab) {
- Object ld = control.getLayoutData();
- if (ld instanceof GridData) {
- ((GridData) ld).grabExcessHorizontalSpace = grab;
- }
- }
-
- /**
- * Sets the width hint of a control. Assumes that GridData is used.
- * @param control
- * @param widthHint
- */
- public static void setWidthHint(Control control, int widthHint) {
- Object ld = control.getLayoutData();
- if (ld instanceof GridData) {
- ((GridData) ld).widthHint = widthHint;
- }
- }
-
-
- /**
- * Sets the horizontal indent of a control. Assumes that GridData is used.
- * @param control
- * @param horizontalIndent
- */
- static void setHorizontalIndent(Control control, int horizontalIndent) {
- Object ld = control.getLayoutData();
- if (ld instanceof GridData) {
- ((GridData) ld).horizontalIndent = horizontalIndent;
- }
- }
-
- /**
- * Sets the horizontal indent of a control. Assumes that GridData is used.
- * @param control
- */
- public static void setHorizontalGrabbing(Control control) {
- Object ld = control.getLayoutData();
- if (ld instanceof GridData) {
- ((GridData) ld).grabExcessHorizontalSpace = true;
- }
- }
-
- /**
- * Returns a width hint for a button control.
- * @param button
- * @return the hint value
- */
- static int getButtonWidthHint(Button button) {
- if (button.getFont().equals(JFaceResources.getDefaultFont()))
- button.setFont(JFaceResources.getDialogFont());
-
- GC gc = new GC(button);
- gc.setFont(button.getFont());
- FontMetrics fontMetrics = gc.getFontMetrics();
- gc.dispose();
-
- int length = button.getText().length();
- int widthHint = Dialog.convertWidthInCharsToPixels(fontMetrics,
- length < 2 ? 2 : length);
- return Math.max(widthHint, button.computeSize(SWT.DEFAULT, SWT.DEFAULT,
- true).x);
- }
-
- static int getButtonHeightHint(FormToolkit toolkit, Text text) {
- if (toolkit != null) {
- return text.computeSize(SWT.DEFAULT, SWT.DEFAULT, true).y
- + BUTTON_HEIGHT_ADJUSTMENT;
- }
- return text.computeSize(SWT.DEFAULT, SWT.DEFAULT, true).y;
- }
-
- private LayoutUtil()
- {
- // static utility class; no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/RadiosDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/RadiosDialogField.java
deleted file mode 100644
index 7db537b68..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/RadiosDialogField.java
+++ /dev/null
@@ -1,233 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * This will display a labal and a group of radio buttons. The group of radio
- * buttons will be layed out horizontally use a RowLayout, and them as a group
- * will use one cell in the GridLayout.
- *
- * Whenever the radios selection change will fire both dialogFieldChanged() and
- * dialogFieldApplied() event.
- *
- * @author mengbo
- */
-public class RadiosDialogField extends DialogFieldBase {
- final static private String INDEXKEY = "INDEX"; //$NON-NLS-1$
-
- private Composite _group;
-
- private String[] _items;
-
- private Button[] _button;
-
- private int _selectIndex = -1;
-
- private boolean _fireEvent = true;
-
- /**
- * Default constructor
- */
- public RadiosDialogField() {
- super();
- }
-
- /**
- * this method must be called before create control
- *
- * @param items
- */
- public void setItems(String[] items) {
- _items = items;
- _button = new Button[_items.length];
- }
-
- // ------- layout helpers
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(toolkit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- _group = getGroup(toolkit, parent);
- _group.setLayoutData(gridDataForGroup(nColumns - 2));
-
- return new Control[] { requiredLabel, label, _group };
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 3;
- }
-
- /**
- * @param span
- * @return the grid data
- */
- protected static GridData gridDataForGroup(int span) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- return gd;
- }
-
- // ------- focus methods
-
- /*
- * @see DialogField#setFocus
- */
- public boolean setFocus() {
- if (isOkToUse(_group)) {
- _group.setFocus();
- }
- return true;
- }
-
- // ------- ui creation
-
- /**
- * @param toolkit
- * @param parent
- * @return the group composite
- */
- public Composite getGroup(FormToolkit toolkit, Composite parent) {
- if (_group == null || _group.isDisposed()) {
- assertCompositeNotNull(parent);
- if (toolkit != null) {
- _group = toolkit.createComposite(parent);
- } else {
- _group = new Composite(parent, SWT.NONE);
- }
- RowLayout layout = new RowLayout();
- layout.marginBottom = 0;
- _group.setLayout(layout);
- for (int i = 0; i < _items.length; i++) {
- if (toolkit != null) {
- _button[i] = toolkit.createButton(_group, _items[i],
- SWT.RADIO);
- } else {
- _button[i] = new Button(_group, SWT.RADIO);
- _button[i].setText(_items[i]);
- }
- _button[i].setData(INDEXKEY, new Integer(i));
- _button[i].addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- if (_fireEvent) {
- _selectIndex = ((Integer) e.widget
- .getData(INDEXKEY)).intValue();
- // FIXME: seemed will fire widgetSelected twice, one
- // for the deselect one,
- // one for the newly selected one. Need investigate.
- if (((Button) e.widget).getSelection()) {
- dialogFieldChangedAndApplied();
- }
- }
- }
-
- });
- }
- }
- return _group;
- }
-
- // ------ enable / disable management
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_group)) {
- _group.setEnabled(isEnabled());
- }
- }
-
- // ------ text access
-
- /**
- * Sets the text. Triggers a dialog-changed event.
- * @param index
- */
- public void setSelectedIndex(int index) {
- _selectIndex = index;
- if (isOkToUse(_group)) {
- if (_selectIndex >= 0 && _selectIndex < _items.length) {
- _button[_selectIndex].setSelection(true);
- } else {
- for (int i = 0; i < _items.length; i++) {
- if (_button[i].getSelection()) {
- _button[i].setSelection(false);
- }
- }
- }
- }
- dialogFieldChangedAndApplied();
- }
-
- /**
- * Sets the text without triggering a dialog-changed event.
- * @param index
- */
- public void setSelectedIndexWithoutUpdate(int index) {
- _selectIndex = index;
- if (isOkToUse(_group)) {
- _fireEvent = false;
- if (_selectIndex >= 0 && _selectIndex < _items.length) {
- _button[_selectIndex].setSelection(true);
- } else {
- for (int i = 0; i < _items.length; i++) {
- if (_button[i].getSelection()) {
- _button[i].setSelection(false);
- }
- }
- }
- _fireEvent = true;
- }
- }
-
- /**
- * @return the index selected
- */
- public int getSelectedIndex() {
- return _selectIndex;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#handleGrabHorizontal()
- */
- public void handleGrabHorizontal() {
- LayoutUtil.setGrabHorizontal(this._group, true);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ResourceButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ResourceButtonDialogField.java
deleted file mode 100644
index 8ab30f002..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/ResourceButtonDialogField.java
+++ /dev/null
@@ -1,231 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.dialogs.CommonResourceDialog;
-import org.eclipse.jst.jsf.common.ui.internal.utils.PathUtil;
-import org.eclipse.jst.jsf.common.ui.internal.utils.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * This class provides a common resource choice DialogFiled. You must set a
- * no-null IProject instance to enable it working. You should give it a suffix
- * list if you want to choose files ended with specific file extensions. The
- * selection result will be a relative path based on the _referredFile's value
- * if it is set, or else based on the _project path.
- *
- * The usage: Shell shell = new Shell(); IProject project = getProject();
- * ResourceButtonDialogField localeField = new
- * ResourceButtonDialogField(project);
- * localeField.setResourceDescription("image"); localeField.setSuffixs(new
- * String[]{"bmp","jpg","gif"});
- * localeField.setReferredFile(StructuredModelUtil.getFileFor(_element.getModel()));
- *
- * @author mengbo
- */
-public class ResourceButtonDialogField extends StringButtonDialogField {
- private IProject _project;
-
- private String[] _suffixs;
-
- private String _resourceDescription;
-
- private IFile _referredFile;
-
- private boolean _isWebPath = false;
-
- private IFolder _folder;
-
- private String _separator = ""; //$NON-NLS-1$
-
- /**
- * @param project
- */
- public ResourceButtonDialogField(IProject project) {
- this(null, project);
- setStringButtonAdapter(new IStringButtonAdapter() {
- public void changeControlPressed(DialogField field) {
- String oldValue = getText();
- String newValue = browseButtonPressed();
- if (newValue != null && !newValue.equals(oldValue)) {
- setText(newValue);
- }
- }
- });
- }
-
- /**
- * @param adapter
- * @param project
- */
- public ResourceButtonDialogField(IStringButtonAdapter adapter,
- IProject project) {
- super(adapter);
- this._project = project;
- }
-
- /**
- * @return the string
- */
- protected String browseButtonPressed() {
- Shell shell = getShell();
- CommonResourceDialog dialog = null;
- int style = "".equals(_separator) ? SWT.NONE : SWT.MULTI | SWT.H_SCROLL //$NON-NLS-1$
- | SWT.V_SCROLL;
- if (_folder != null) {
- dialog = new CommonResourceDialog(shell, _folder.getProject(), style);
- } else {
- dialog = new CommonResourceDialog(shell, _project, style);
- }
- dialog.setTitle(JSFUICommonPlugin
- .getResourceString("DialogField.ResourceButton.SelectFile"));//$NON-NLS-1$
- dialog.setSuffixs(_suffixs);
- dialog.setResourceDescription(_resourceDescription);
-
- if (dialog.open() == Window.OK) {
- Object[] result = dialog.getResult();
- StringBuffer buffer = new StringBuffer();
- for (int i = 0; i < result.length; i++) {
- String newValue = null;
- IPath path = ((IFile) result[i]).getLocation();
-
- IPath referredPath = null;
- if (_referredFile != null) {
- referredPath = _referredFile.getLocation();
- } else {
- referredPath = _project.getLocation();
- }
- if (this._isWebPath) {
- IFile selectedFile = ((IFile) result[i]);
- newValue = WebrootUtil.getWebPath(selectedFile
- .getFullPath());
- } else {
- newValue = PathUtil.convertToRelativePath(path.toString(),
- referredPath.toString());
- }
- buffer.append(newValue);
- buffer.append(_separator);
- }
- if (buffer.length() > 0) {
- return buffer.substring(0, buffer.length()
- - _separator.length());
- }
-
- }
- return null;
- }
-
- /**
- * @return Returns the project.
- */
- public IProject getProject() {
- return _project;
- }
-
- /**
- * @param project
- * The project to set.
- */
- public void setProject(IProject project) {
- this._project = project;
- }
-
- /**
- * @return Returns the relative folder.
- */
- public IFolder getFolder() {
- return _folder;
- }
-
- /**
- * @param folder
- * The relative folder to set.
- */
- public void setFolder(IFolder folder) {
- this._folder = folder;
- }
-
- /**
- * @return Returns the referredFile.
- */
- public IFile getReferredFile() {
- return _referredFile;
- }
-
- /**
- * @param referredFile
- * The referredFile to set.
- */
- public void setReferredFile(IFile referredFile) {
- this._referredFile = referredFile;
- }
-
- /**
- * @return Returns the resourceDescription.
- */
- public String getResourceDescription() {
- return _resourceDescription;
- }
-
- /**
- * @param resourceDescription
- * The resourceDescription to set.
- */
- public void setResourceDescription(String resourceDescription) {
- this._resourceDescription = resourceDescription;
- }
-
- /**
- * @return Returns the suffixs.
- */
- public String[] getSuffixs() {
- return _suffixs;
- }
-
- /**
- * @param suffixs
- * The suffixs to set.
- */
- public void setSuffixs(String[] suffixs) {
- this._suffixs = suffixs;
- }
-
- /**
- * set some special path to web path instead of relative path
- *
- * @param isWebPath
- */
- public void setWebPath(boolean isWebPath) {
- this._isWebPath = isWebPath;
- }
-
- /**
- * @return the separator string
- */
- public String getSeparator() {
- return _separator;
- }
-
- /**
- * @param separator
- */
- public void setSeparator(String separator) {
- this._separator = separator;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/Separator.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/Separator.java
deleted file mode 100644
index f54722a77..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/Separator.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Dialog field describing a separator.
- */
-public class Separator extends DialogFieldBase {
-
- private Label _separator;
-
- private int _style;
-
- /**
- * Default constructor
- */
- public Separator() {
- this(SWT.NONE);
- }
-
- /**
- * @param style
- * of the separator. See <code>Label</code> for possible
- * styles.
- */
- public Separator(int style) {
- _style = style;
- }
-
- // ------- layout helpers
-
- /**
- * Creates the separator and fills it in a MGridLayout.
- * @param toolkit
- * @param parent
- * @param nColumns
- *
- * @param height
- * The heigth of the separator
- * @return the controls or empty array
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns, int height) {
- assertEnoughColumns(nColumns);
-
- Control separator = getSeparator(toolkit, parent);
- separator.setLayoutData(gridDataForSeperator(nColumns, height));
-
- return new Control[] { separator };
- }
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- return doFillIntoGrid(toolkit, parent, nColumns, 4);
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 1;
- }
-
- /**
- * @param span
- * @param height
- * @return the grid data
- */
- protected static GridData gridDataForSeperator(int span, int height) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.verticalAlignment = GridData.BEGINNING;
- gd.heightHint = height;
- gd.horizontalSpan = span;
- return gd;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created separator.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> if the widget has
- * already been created.
- * @return the separator
- */
- private Control getSeparator(FormToolkit toolkit, Composite parent) {
- if (_separator == null || _separator.isDisposed()) {
- assertCompositeNotNull(parent);
- if (toolkit != null) {
- _separator = toolkit.createSeparator(parent, _style);
- } else {
- _separator = new Label(parent, _style);
- }
- }
- return _separator;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#handleGrabHorizontal()
- */
- public void handleGrabHorizontal() {
- // do nothing.
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/SourceFolderButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/SourceFolderButtonDialogField.java
deleted file mode 100644
index 420a95093..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/SourceFolderButtonDialogField.java
+++ /dev/null
@@ -1,340 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-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.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaModel;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.ui.JavaElementComparator;
-import org.eclipse.jdt.ui.JavaElementLabelProvider;
-import org.eclipse.jdt.ui.StandardJavaElementContentProvider;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.ui.dialogs.ElementTreeSelectionDialog;
-
-/**
- * This class provides a source folder selection DialogFiled. There are two
- * conditions: 1. If you set the IProject instance, the source folder selection
- * will only be limited in the specified project 2. If you set null, the source
- * folder selection is allowed in all workspaces
- *
- *
- * @author mengbo
- * @version 1.5
- */
-public class SourceFolderButtonDialogField extends StringButtonDialogField {
- /** Create the logger for this class */
- private static Logger _log = JSFUICommonPlugin
- .getLogger(SourceFolderButtonDialogField.class);
-
- /**
- * package fragment root corresponding to the input type (can be null)
- */
- private IPackageFragmentRoot _fCurrRoot;
-
- private IProject _project;
-
- /**
- * @param project
- */
- public SourceFolderButtonDialogField(IProject project) {
- super(null);
-
- _project = project;
-
- setLabelText(DialogFieldResources.getInstance().getString(
- "SourceFolderButtonDialogField.container.label")); //$NON-NLS-1$
-
- setButtonLabel(DialogFieldResources.getInstance().getString(
- "SourceFolderButtonDialogField.container.button")); //$NON-NLS-1$
-
- setStringButtonAdapter(new IStringButtonAdapter() {
- public void changeControlPressed(DialogField field) {
- containerChangeControlPressed(field);
- }
-
- });
- }
-
- /**
- * @return Returns the project.
- */
- public IProject getProject() {
- return _project;
- }
-
- /**
- * @param project
- * The project to set.
- */
- public void setProject(IProject project) {
- this._project = project;
- }
-
- /**
- * @param field
- */
- protected void containerChangeControlPressed(DialogField field) {
- // take the current jproject as init element of the dialog
- IPackageFragmentRoot root = getPackageFragmentRoot();
- root = chooseSourceContainer(root);
- if (root != null) {
- setPackageFragmentRoot(root, true);
- }
- }
-
- /**
- * Sets the current source folder (model and text field) to the given
- * package fragment root.
- *
- * @param root
- * The new root.
- * @param canBeModified
- * if <code>false</code> the source folder field can not be
- * changed by the user. If <code>true</code> the field is
- * editable
- */
- public void setPackageFragmentRoot(IPackageFragmentRoot root,
- boolean canBeModified) {
- _fCurrRoot = root;
- String str = (root == null) ? "" : root.getPath().makeRelative().toString(); //$NON-NLS-1$
- setText(str);
- setEnabled(canBeModified);
- }
-
- /**
- * Returns the <code>IPackageFragmentRoot</code> that corresponds to the
- * current value of the source folder field.
- *
- * @return the IPackageFragmentRoot or <code>null</code> if the current
- * source folder value is not a valid package fragment root
- *
- */
- public IPackageFragmentRoot getPackageFragmentRoot() {
- return _fCurrRoot;
- }
-
- /**
- * Returns the current text of source folder text field.
- *
- * @return the text of the source folder text field
- */
- public String getPackageFragmentRootText() {
- return getText();
- }
-
- /**
- * choose source container dialog
- *
- * @param initElement
- * @return
- */
- private IPackageFragmentRoot chooseSourceContainer(IJavaElement initElement) {
- Class[] acceptedClasses = new Class[] { IPackageFragmentRoot.class,
- IJavaProject.class, };
-
- TypedElementSelectionValidator validator = new TypedElementSelectionValidator(
- acceptedClasses, false) {
- // TODO: never used
-// public boolean isSelectedValid(Object element) {
-// try {
-// if (element instanceof IJavaProject) {
-// IJavaProject jproject = (IJavaProject) element;
-// IPath path = jproject.getProject().getFullPath();
-// return (jproject.findPackageFragmentRoot(path) != null);
-// } else if (element instanceof IPackageFragmentRoot) {
-// return (((IPackageFragmentRoot) element).getKind() == IPackageFragmentRoot.K_SOURCE);
-// }
-// return true;
-// } catch (JavaModelException e) {
-// _log.error("JavaModelException"); // just log, no ui in
-// // validation
-// }
-// return false;
-// }
- };
-
- acceptedClasses = new Class[] { IJavaModel.class,
- IPackageFragmentRoot.class, IJavaProject.class, };
- ViewerFilter filter = new TypedViewerFilter(acceptedClasses) {
- public boolean select(Viewer viewer, Object parent, Object element) {
- if (element instanceof IPackageFragmentRoot) {
- try {
- return (((IPackageFragmentRoot) element).getKind() == IPackageFragmentRoot.K_SOURCE);
- } catch (JavaModelException e) {
- _log.error(e); // just log, no ui
- // in validation
- return false;
- }
- }
- return super.select(viewer, parent, element);
- }
- };
-
- StandardJavaElementContentProvider provider = new StandardJavaElementContentProvider();
- ILabelProvider labelProvider = new JavaElementLabelProvider(
- JavaElementLabelProvider.SHOW_DEFAULT);
- ElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog(
- getShell(), labelProvider, provider);
- dialog.setValidator(validator);
- dialog.setComparator(new JavaElementComparator());
- // HibernateWizardPage.ChooseSourceContainerDialog.Title = Folder
- // Selection
- dialog
- .setTitle(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.ChooseSourceContainerDialog.Title")); //$NON-NLS-1$
- // HibernateWizardPage.ChooseSourceContainerDialog.Description = Choose
- // a folder:
- dialog
- .setMessage(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.ChooseSourceContainerDialog.Description")); //$NON-NLS-1$
- dialog.addFilter(filter);
- if (_project != null) {
- dialog.setInput(JavaCore.create(_project));
- } else {
- dialog.setInput(JavaCore.create(ResourcesPlugin.getWorkspace()
- .getRoot()));
- }
- dialog.setInitialSelection(initElement);
-
- if (dialog.open() == Window.OK) {
- Object element = dialog.getFirstResult();
- if (element instanceof IJavaProject) {
- IJavaProject jproject = (IJavaProject) element;
- return jproject.getPackageFragmentRoot(jproject.getProject());
- } else if (element instanceof IPackageFragmentRoot) {
- return (IPackageFragmentRoot) element;
- }
- return null;
- }
- return null;
- }
-
- /**
- * This method updates the model and returns an error status. The underlying
- * model is only valid if the returned status is OK.
- *
- * @return the model's error status
- */
- public IStatus getChangedStatus() {
- StatusInfo status = new StatusInfo();
-
- _fCurrRoot = null;
- String str = getPackageFragmentRootText();
- if (str.length() == 0) {
- // SourceFolderButtonDialogField.error.EnterContainerName = Folder
- // name is empty.
- status.setError(DialogFieldResources.getInstance().getString(
- "SourceFolderButtonDialogField.error.EnterContainerName")); //$NON-NLS-1$
- return status;
- }
- IPath path = new Path(str);
- IResource res = ResourcesPlugin.getWorkspace().getRoot().findMember(
- path);
- if (res != null) {
- int resType = res.getType();
- if (resType == IResource.PROJECT || resType == IResource.FOLDER) {
- IProject proj = res.getProject();
- if (!proj.isOpen()) {
- status
- .setError(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.error.ProjectClosed", proj.getFullPath().toString())); //$NON-NLS-1$
- return status;
- }
- if (_project != null && proj != _project) {
- // HibernateWizardPage.error.NotSameProject = The project
- // should be \''{0}\''.
- status
- .setError(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.error.NotSameProject", _project.getName())); //$NON-NLS-1$
- return status;
- }
- IJavaProject jproject = JavaCore.create(proj);
- _fCurrRoot = jproject.getPackageFragmentRoot(res);
- if (res.exists()) {
- try {
- if (!proj.hasNature(JavaCore.NATURE_ID)) {
- if (resType == IResource.PROJECT) {
- status
- .setError(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.warning.NotAJavaProject", proj.getName())); //$NON-NLS-1$
- } else {
- status
- .setWarning(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.warning.NotInAJavaProject", proj.getName())); //$NON-NLS-1$
- }
- return status;
- }
- } catch (CoreException e) {
- status
- .setWarning(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.warning.NotAJavaProject", proj.getName())); //$NON-NLS-1$
- }
- if (!jproject.isOnClasspath(_fCurrRoot)) {
- status
- .setWarning(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.warning.NotOnClassPath", str)); //$NON-NLS-1$
- }
- if (_fCurrRoot.isArchive()) {
- status
- .setError(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.error.ContainerIsBinary", str)); //$NON-NLS-1$
- return status;
- }
- }
- return status;
- }
- status.setError(DialogFieldResources.getInstance().getString(
- "SourceFolderButtonDialogField.error.NotAFolder", str)); //$NON-NLS-1$
- return status;
- }
- status
- .setError(DialogFieldResources
- .getInstance()
- .getString(
- "SourceFolderButtonDialogField.error.ContainerDoesNotExist", str)); //$NON-NLS-1$
- return status;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusInfo.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusInfo.java
deleted file mode 100644
index 8a8c9b75b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusInfo.java
+++ /dev/null
@@ -1,198 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-
-/**
- * A settable IStatus. Can be an error, warning, info or ok. For error, info and
- * warning states, a message describes the problem.
- *
- * TODO: couldn't have sub-classed Status?
- *
- * @author mengbo
- * @version 1.5
- */
-/*package*/ class StatusInfo implements IStatus {
-
- /**
- * a default status info for IStatus.OK
- */
- public static final IStatus OK_STATUS = new StatusInfo();
-
- private String fStatusMessage;
-
- private int fSeverity;
-
- /**
- * Creates a status set to OK (no message)
- */
- public StatusInfo() {
- this(OK, null);
- }
-
- /**
- * Creates a status .
- *
- * @param severity
- * The status severity: ERROR, WARNING, INFO and OK.
- * @param message
- * The message of the status. Applies only for ERROR, WARNING and
- * INFO.
- */
- public StatusInfo(int severity, String message) {
- fStatusMessage = message;
- fSeverity = severity;
- }
-
- /**
- * Returns if the status' severity is OK.
- */
- public boolean isOK() {
- return fSeverity == IStatus.OK;
- }
-
- /**
- * Returns if the status' severity is WARNING.
- * @return true if severity is IStatus.WARNING
- */
- public boolean isWarning() {
- return fSeverity == IStatus.WARNING;
- }
-
- /**
- * Returns if the status' severity is INFO.
- * @return true if severity is INFO
- */
- public boolean isInfo() {
- return fSeverity == IStatus.INFO;
- }
-
- /**
- * Returns if the status' severity is ERROR.
- * @return true if severity is error
- */
- public boolean isError() {
- return fSeverity == IStatus.ERROR;
- }
-
- /**
- * @see IStatus#getMessage
- */
- public String getMessage() {
- return fStatusMessage;
- }
-
- /**
- * Sets the status to ERROR.
- *
- * @param errorMessage
- * The error message (can be empty, but not null)
- */
- public void setError(String errorMessage) {
- Assert.isNotNull(errorMessage);
- fStatusMessage = errorMessage;
- fSeverity = IStatus.ERROR;
- }
-
- /**
- * Sets the status to WARNING.
- *
- * @param warningMessage
- * The warning message (can be empty, but not null)
- */
- public void setWarning(String warningMessage) {
- Assert.isNotNull(warningMessage);
- fStatusMessage = warningMessage;
- fSeverity = IStatus.WARNING;
- }
-
- /**
- * Sets the status to INFO.
- *
- * @param infoMessage
- * The info message (can be empty, but not null)
- */
- public void setInfo(String infoMessage) {
- Assert.isNotNull(infoMessage);
- fStatusMessage = infoMessage;
- fSeverity = IStatus.INFO;
- }
-
- /**
- * Sets the status to OK.
- */
- public void setOK() {
- fStatusMessage = null;
- fSeverity = IStatus.OK;
- }
-
- /*
- * @see IStatus#matches(int)
- */
- public boolean matches(int severityMask) {
- return (fSeverity & severityMask) != 0;
- }
-
- /**
- * Returns always <code>false</code>.
- *
- * @see IStatus#isMultiStatus()
- */
- public boolean isMultiStatus() {
- return false;
- }
-
- /*
- * @see IStatus#getSeverity()
- */
- public int getSeverity() {
- return fSeverity;
- }
-
- /*
- * @see IStatus#getPlugin()
- */
- public String getPlugin() {
- return JSFUICommonPlugin.getPluginId();
- }
-
- /**
- * Returns always <code>null</code>.
- *
- * @see IStatus#getException()
- */
- public Throwable getException() {
- return null;
- }
-
- /**
- * Returns always the error severity.
- *
- * @see IStatus#getCode()
- */
- public int getCode() {
- return fSeverity;
- }
-
- /**
- * Returns always <code>null</code>.
- *
- * @see IStatus#getChildren()
- */
- public IStatus[] getChildren() {
- return new IStatus[0];
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusUtil.java
deleted file mode 100644
index 22fe6d866..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StatusUtil.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.dialogs.DialogPage;
-
-/**
- * copied from org.eclipse.jdt.internal.dialogs. Enhanced to support null status
- * as parameter
- *
- * A utility class to work with IStatus.
- */
-public class StatusUtil {
-
- /**
- * Compares two instances of <code>IStatus</code>. The more severe is
- * returned: An error is more severe than a warning, and a warning is more
- * severe than ok. If the two stati have the same severity, the second is
- * returned.
- * @param s1
- * @param s2
- *
- * @return Could be null.
- */
- public static IStatus getMoreSevere(IStatus s1, IStatus s2) {
- if (s1 == null && s2 == null) {
- return null;
- } else if (s1 == null) {
- return s2;
- } else if (s2 == null) {
- return s1;
- } else if (s1.getSeverity() > s2.getSeverity()) {
- return s1;
- } else {
- return s2;
- }
- }
-
- /**
- * Finds the most severe status from a array of stati. An error is more
- * severe than a warning, and a warning is more severe than ok.
- * @param status
- *
- * @return could be null
- */
- public static IStatus getMostSevere(IStatus[] status) {
- if (status == null)
- return null;
- IStatus max = null;
- for (int i = 0; i < status.length; i++) {
- IStatus curr = status[i];
- if (curr == null)
- continue;
-
- if (curr.matches(IStatus.ERROR)) {
- return curr;
- }
- if (max == null || curr.getSeverity() > max.getSeverity()) {
- max = curr;
- }
- }
- if (max != null)
- {
- return max;
- }
-
- return null;
- }
-
- /**
- * Applies the status to the status line of a dialog page.
- * @param page
- * @param status
- */
- public static void applyToStatusLine(DialogPage page, IStatus status) {
- if (status == null) {
- page.setMessage(null);
- page.setErrorMessage(null);
- } else {
- String message = status.getMessage();
- switch (status.getSeverity()) {
- case IStatus.OK:
- page.setMessage(message, DialogPage.NONE);
- page.setErrorMessage(null);
- break;
- case IStatus.WARNING:
- page.setMessage(message, DialogPage.WARNING);
- page.setErrorMessage(null);
- break;
- case IStatus.INFO:
- page.setMessage(message, DialogPage.INFORMATION);
- page.setErrorMessage(null);
- break;
- default:
- if (message.length() == 0) {
- message = null;
- }
- page.setMessage(null);
- page.setErrorMessage(message);
- break;
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringButtonDialogField.java
deleted file mode 100644
index eebc9e5c4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringButtonDialogField.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.layout.GridData;
-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.ui.forms.widgets.FormToolkit;
-
-/**
- * Dialog field containing a label, text control and a button control.
- */
-public class StringButtonDialogField extends StringDialogField {
- private Button _browseButton;
-
- private String _browseButtonLabel;
-
- private IStringButtonAdapter _stringButtonAdapter;
-
- private boolean _buttonEnabled;
-
- /**
- * @param adapter
- */
- public StringButtonDialogField(IStringButtonAdapter adapter) {
- _stringButtonAdapter = adapter;
- _browseButtonLabel = JSFUICommonPlugin
- .getResourceString("DialogField.Browse"); //$NON-NLS-1$
- _buttonEnabled = true;
- }
-
- /**
- * Sets the label of the button.
- * @param label
- */
- public void setButtonLabel(String label) {
- _browseButtonLabel = label;
- }
-
- // ------ adapter communication
-
- /**
- * Programmatical pressing of the button
- */
- public void changeControlPressed() {
- _stringButtonAdapter.changeControlPressed(this);
- }
-
- // ------- layout helpers
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(toolkit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- Text text = getTextControl(toolkit, parent);
- text.setLayoutData(gridDataForText(nColumns - 3));
- Button button = getChangeControl(toolkit, parent);
- button.setLayoutData(gridDataForButton(toolkit, button, text, 1));
-
- return new Control[] { requiredLabel, label, text, button };
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 4;
- }
-
- /**
- * @param toolkit
- * @param button
- * @param text
- * @param span
- * @return the grid data for the button
- */
- protected static GridData gridDataForButton(FormToolkit toolkit,
- Button button, Text text, int span) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- // gd.heightHint = SWTUtil.getButtonHeightHint(button);
- gd.widthHint = LayoutUtil.getButtonWidthHint(button);
- gd.heightHint = LayoutUtil.getButtonHeightHint(toolkit, text);
- return gd;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created buttom widget.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> if the widget has
- * already been created.
- * @return the button
- */
- public Button getChangeControl(FormToolkit toolkit, Composite parent) {
- if (_browseButton == null || _browseButton.isDisposed()) {
- assertCompositeNotNull(parent);
- if (toolkit != null) {
- _browseButton = toolkit.createButton(parent,
- _browseButtonLabel, SWT.PUSH);
- } else {
- _browseButton = new Button(parent, SWT.PUSH);
- _browseButton.setText(_browseButtonLabel);
- }
- _browseButton.setEnabled(isEnabled() && _buttonEnabled);
- _browseButton.addSelectionListener(new SelectionListener() {
- public void widgetDefaultSelected(SelectionEvent e) {
- changeControlPressed();
- }
-
- public void widgetSelected(SelectionEvent e) {
- changeControlPressed();
- }
- });
-
- }
- return _browseButton;
- }
-
- // ------ enable / disable management
-
- /**
- * Sets the enable state of the button.
- * @param enable
- */
- public void enableButton(boolean enable) {
- if (isOkToUse(_browseButton)) {
- _browseButton.setEnabled(isEnabled() && enable);
- }
- _buttonEnabled = enable;
- }
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_browseButton)) {
- _browseButton.setEnabled(isEnabled() && _buttonEnabled);
- }
- }
-
- /**
- * @return Returns the _stringButtonAdapter.
- */
- public IStringButtonAdapter getStringButtonAdapter() {
- return _stringButtonAdapter;
- }
-
- /**
- * @param buttonAdapter
- * The _stringButtonAdapter to set.
- */
- public void setStringButtonAdapter(IStringButtonAdapter buttonAdapter) {
- _stringButtonAdapter = buttonAdapter;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringDialogField.java
deleted file mode 100644
index bf334a54c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StringDialogField.java
+++ /dev/null
@@ -1,291 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Dialog field containing a label and a text control.
- */
-public class StringDialogField extends DialogFieldBase implements
- ISupportTextValue {
- final static private int TEXT_WIDTH_HINT = 10;
-
- private String _text;
-
- private Text _textControl;
-
- private ModifyListener _modifyListener;
-
- private int _numRows;
-
- /**
- * whether there is change in the UI but not fire applied event yet.
- */
- private boolean _pending = false;
-
- /**
- * default constructor
- * numRows == 1
- */
- public StringDialogField() {
- this(1);
- _text = ""; //$NON-NLS-1$
- }
-
- /**
- * @param numRows
- */
- public StringDialogField(int numRows) {
- super();
- _text = ""; //$NON-NLS-1$
- _numRows = numRows;
- }
-
- // ------- layout helpers
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit kit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(kit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(kit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- Text text = getTextControl(kit, parent);
- int heightHint = -1;
- if (_numRows > 1) {
- heightHint = getDialogUnits(parent).getHeight() * _numRows;
- }
- text.setLayoutData(gridDataForText(nColumns - 2, heightHint));
-
- return new Control[] { requiredLabel, label, text };
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 3;
- }
-
- protected static GridData gridDataForLabel(int span) {
- GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
- gd.horizontalSpan = span;
- return gd;
- }
-
- /**
- * @param span
- * @param heightHint
- * @return the grid data for text
- */
- protected static GridData gridDataForText(int span, int heightHint) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.heightHint = heightHint;
- gd.horizontalSpan = span;
- gd.widthHint = TEXT_WIDTH_HINT;
- return gd;
- }
-
- /**
- * @param span
- * @return the grid data for text
- */
- protected static GridData gridDataForText(int span) {
- GridData gd = gridDataForText(span, -1);
- return gd;
- }
-
- // ------- focus methods
-
- /*
- * @see DialogField#setFocus
- */
- public boolean setFocus() {
- if (isOkToUse(_textControl)) {
- _textControl.setFocus();
- _textControl.setSelection(0, _textControl.getText().length());
- }
- return true;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created text control.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> when the widget
- * has already been created.
- * @return the text control
- */
- public Text getTextControl(FormToolkit toolkit, Composite parent) {
- if (_textControl == null || _textControl.isDisposed()) {
- assertCompositeNotNull(parent);
- _modifyListener = new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- doModifyText(e);
- }
- };
-
- if (toolkit != null) {
- if (_numRows <= 1) {
- _textControl = toolkit.createText(parent, ""); //$NON-NLS-1$
- } else {
- _textControl = toolkit.createText(parent, "", SWT.V_SCROLL); //$NON-NLS-1$
- }
- } else {
- if (_numRows <= 1) {
-
- _textControl = new Text(parent, SWT.SINGLE | SWT.BORDER);
- } else {
- _textControl = new Text(parent, SWT.V_SCROLL | SWT.WRAP
- | SWT.BORDER);
- }
- }
-
- _textControl.setText(_text);
- _textControl.setFont(parent.getFont());
- _textControl.addModifyListener(_modifyListener);
- _textControl.addFocusListener(new FocusAdapter() {
-
- public void focusLost(FocusEvent e) {
- doFocusLost(e);
- }
-
- });
- _textControl.addKeyListener(new KeyAdapter() {
- public void keyReleased(KeyEvent e) {
- doKeyReleased(e);
- }
- });
-
- _textControl.setEnabled(isEnabled());
-
- _textControl.setToolTipText(getToolTip());
- }
- return _textControl;
- }
-
- /**
- * @param e
- */
- protected void doKeyReleased(KeyEvent e) {
- if (e.character == '\r') {
- // commit value
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
- }
-
- /**
- * @param e
- */
- protected void doFocusLost(FocusEvent e) {
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
-
- /**
- * some get changed in the Text. As in <code>setText</code> and
- * <code>setTextWithoutUpdate</code> we removed the listener, so this must
- * be user typing in the text field.
- *
- * @param e
- */
- private void doModifyText(ModifyEvent e) {
- if (isOkToUse(_textControl)) {
- _text = _textControl.getText();
- }
- _pending = true;
- dialogFieldChanged();
- }
-
- // ------ enable / disable management
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_textControl)) {
- _textControl.setEnabled(isEnabled());
- }
- }
-
- // ------ text access
-
- /**
- * Gets the text. Can not be <code>null</code>
- */
- public String getText() {
- return _text;
- }
-
- /**
- * Sets the text. Triggers a dialog-changed event.
- */
- public void setText(String text) {
- setTextWithoutUpdate(text);
- dialogFieldChangedAndApplied();
- }
-
- /**
- * Sets the text without triggering a dialog-changed event.
- */
- public void setTextWithoutUpdate(String text) {
- // reset _pending state.
- _pending = false;
-
- if (text == null)
- text = ""; //$NON-NLS-1$
- _text = text;
- if (isOkToUse(_textControl)) {
- _textControl.removeModifyListener(_modifyListener);
- _textControl.setText(text);
- _textControl.addModifyListener(_modifyListener);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#handleGrabHorizontal()
- */
- public void handleGrabHorizontal() {
- LayoutUtil.setGrabHorizontal(_textControl, true);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StyleComboDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StyleComboDialogField.java
deleted file mode 100644
index 93c93320b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/StyleComboDialogField.java
+++ /dev/null
@@ -1,398 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.Map;
-import java.util.TreeMap;
-import java.util.Map.Entry;
-
-import org.eclipse.jst.jsf.common.ui.internal.utils.StyleCombo;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.PaintEvent;
-import org.eclipse.swt.events.PaintListener;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.forms.FormColors;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * A dialog field for style combos
- *
- */
-public class StyleComboDialogField extends DialogFieldBase implements
- ISupportTextValue {
- final static private int WIDTH_HINT = 10;
-
- private String _text;
-
- private int _selectionIndex;
-
- private String[] _items;
-
- private StyleCombo _comboControl;
-
- private ModifyListener _modifyListener;
-
- private int _flags;
-
- private boolean _pending = false;
-
- private Map _entryMap;
-
- private String _defaultValue;
-
-
- /**
- * @param defaultValue
- */
- public void setDefaultValue(String defaultValue) {
- this._defaultValue = defaultValue;
- if (_comboControl != null && ! _comboControl.isDisposed())
- _comboControl.setDefaultValue(_defaultValue);
- }
-
- /**
- * @param flags
- */
- public StyleComboDialogField(int flags) {
- super();
- _text = ""; //$NON-NLS-1$
- _items = new String[0];
- _flags = flags;
- _selectionIndex = -1;
- }
-
- // ------- layout helpers
-
-
- /*
- * @see DialogField#doFillIntoGrid
- */
- public Control[] doFillIntoGrid(FormToolkit toolkit, Composite parent,
- int nColumns) {
- assertEnoughColumns(nColumns);
-
- Control requiredLabel = getRequiredLabelControl(toolkit, parent);
- requiredLabel.setLayoutData(gridDataForLabel(1));
-
- Control label = getLabelControl(toolkit, parent);
- label.setLayoutData(gridDataForLabel(1));
-
- StyleCombo combo = getComboControl(toolkit, parent);
- combo.setLayoutData(gridDataForCombo(nColumns - 2));
-
- return new Control[] { requiredLabel, label, combo };
- }
-
- /*
- * @see DialogField#getNumberOfControls
- */
- public int getNumberOfControls() {
- return 3;
- }
-
- /**
- * @param span
- * @return the grid data for the combo
- */
- protected static GridData gridDataForCombo(int span) {
- GridData gd = new GridData();
- gd.horizontalAlignment = GridData.FILL;
- gd.grabExcessHorizontalSpace = false;
- gd.horizontalSpan = span;
- gd.widthHint = WIDTH_HINT;
- return gd;
- }
-
- // ------- focus methods
-
- /*
- * @see DialogField#setFocus
- */
- public boolean setFocus() {
- if (isOkToUse(_comboControl)) {
- _comboControl.setFocus();
- }
- return true;
- }
-
- // ------- ui creation
-
- /**
- * Creates or returns the created combo control.
- * @param toolkit
- *
- * @param parent
- * The parent composite or <code>null</code> when the widget
- * has already been created.
- * @return the combo control
- */
- public StyleCombo getComboControl(FormToolkit toolkit,
- final Composite parent) {
- if (_comboControl == null || _comboControl.isDisposed()) {
- assertCompositeNotNull(parent);
- _modifyListener = new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- doModifyText(e);
- }
- };
- SelectionListener selectionListener = new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- doSelectionChanged(e);
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- handleDefaultSelection(e);
- }
- };
-
- if (toolkit != null) {
- _comboControl = new StyleCombo(parent, _flags);
- final FormColors colors = new FormColors(parent.getDisplay());
- parent.addPaintListener(new PaintListener() {
-
- public void paintControl(PaintEvent event) {
- Composite composite = (Composite) event.widget;
- Control[] children = composite.getChildren();
- for (int i = 0; i < children.length; i++) {
- Control c = children[i];
- if (!(c instanceof StyleCombo) || !c.isVisible()) {
- continue;
- }
- Rectangle b = c.getBounds();
- GC gc = event.gc;
- gc.setForeground(colors.getBorderColor());
- gc.drawRectangle(b.x - 1, b.y - 1, b.width + 1,
- b.height + 1);
- }
- }
- });
-
- // when the parent is disposed, the colors should no
- // no longer be needed.
- parent.addDisposeListener(new DisposeListener()
- {
- public void widgetDisposed(DisposeEvent e) {
- colors.dispose();
- }
- }
- );
- toolkit.adapt(_comboControl);
- } else {
- _comboControl = new StyleCombo(parent, _flags | SWT.BORDER);
- _comboControl.setBackground(Display.getCurrent()
- .getSystemColor(SWT.COLOR_LIST_BACKGROUND));
- }
-
- // moved up due to 1GEUNW2
- _comboControl.setItems(_items);
- _comboControl.setDefaultValue(_defaultValue);
- if (_selectionIndex != -1) {
- _comboControl.select(_selectionIndex);
- } else {
- _comboControl.setText(_text);
- }
- _comboControl.setFont(parent.getFont());
- _comboControl.addModifyListener(_modifyListener);
- _comboControl.addSelectionListener(selectionListener);
- _comboControl.addFocusListener(new FocusAdapter() {
- public void focusLost(FocusEvent e) {
- doFocusLost(e);
- }
- });
- _comboControl.setEnabled(isEnabled());
- _comboControl.setToolTipText(getToolTip());
- }
- return _comboControl;
- }
-
- /**
- * @param e
- */
- protected void handleDefaultSelection(SelectionEvent e) {
- // commit value
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
-
- /**
- * @param e
- */
- protected void doFocusLost(FocusEvent e) {
- if (_pending) {
- _pending = false;
- dialogFieldApplied();
- }
- }
-
- private void doModifyText(ModifyEvent e) {
- if (isOkToUse(_comboControl)) {
- _text = getEntryKey(_comboControl.getText());
- _selectionIndex = _comboControl.getSelectionIndex();
- }
- _pending = true;
- dialogFieldChanged();
- }
-
- private void doSelectionChanged(SelectionEvent e) {
- if (isOkToUse(_comboControl)) {
- _items = _comboControl.getItems();
- _text = getEntryKey(_comboControl.getText());
- _selectionIndex = _comboControl.getSelectionIndex();
- }
- _pending = false;
- dialogFieldChangedAndApplied();
- }
-
- // ------ enable / disable management
-
- /*
- * @see DialogField#updateEnableState
- */
- protected void updateEnableState() {
- super.updateEnableState();
- if (isOkToUse(_comboControl)) {
- _comboControl.setEnabled(isEnabled());
- }
- }
-
- // ------ text access
-
- /**
- * Sets the combo items. Triggers a dialog-changed event.
- * @param items
- */
- public void setItems(String[] items) {
- _items = items;
- if (isOkToUse(_comboControl)) {
- _comboControl.setItems(items);
- }
- _pending = false;
- // dialogFieldChangedAndApplied();
- }
-
- /**
- * @param map
- */
- public void setEntryMap(Map map) {
- this._entryMap = map;
- if (_entryMap == null) {
- _entryMap = new TreeMap();
- }
- Entry[] entries = (Entry[]) _entryMap.entrySet().toArray(new Entry[0]);
- String[] items = new String[entries.length];
- for (int i = 0; i < entries.length; i++) {
- items[i] = entries[i].getValue().toString();
- }
- setItems(items);
- }
-
- /**
- * Gets the text.
- */
- public String getText() {
- return _text;
- }
-
- /**
- * Sets the text. Triggers a dialog-changed event.
- */
- public void setText(String text) {
- setTextWithoutUpdate(text);
- _pending = false;
- dialogFieldChangedAndApplied();
- }
-
- /**
- * Selects an item.
- * @param index
- */
- public void selectItem(int index) {
- if (isOkToUse(_comboControl)) {
- _comboControl.select(index);
- } else {
- if (index >= 0 && index < _items.length) {
- _text = getEntryKey(_items[index]);
- _selectionIndex = index;
- }
- }
- dialogFieldChangedAndApplied();
- }
-
- /**
- * @return the selection index
- */
- public int getSelectionIndex() {
- return _selectionIndex;
- }
-
- /**
- * Sets the text without triggering a dialog-changed event.
- */
- public void setTextWithoutUpdate(String text) {
- _pending = false;
- if (text == null) {
- text = "";//$NON-NLS-1$
- }
- _text = text;
- if (isOkToUse(_comboControl)) {
- _comboControl.removeModifyListener(_modifyListener);
- _comboControl.setText(getEntryValue(text));
- _comboControl.addModifyListener(_modifyListener);
- }
- }
-
- private String getEntryValue(String key) {
- if (_entryMap == null || !_entryMap.containsKey(key)) {
- return key;
- }
- return _entryMap.get(key).toString();
- }
-
- private String getEntryKey(String value) {
- if (_entryMap == null || !_entryMap.containsValue(value)) {
- return value;
- }
-
- Entry[] entries = (Entry[]) _entryMap.entrySet().toArray(new Entry[0]);
- for (int i = 0; i < entries.length; i++) {
- if (entries[i].getValue() == value
- || (value != null && value.equals(entries[i].getValue()))) {
- return entries[i].getKey().toString();
- }
- }
- return value;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField#handleGrabHorizontal()
- */
- public void handleGrabHorizontal() {
- LayoutUtil.setGrabHorizontal(_comboControl, true);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedElementSelectionValidator.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedElementSelectionValidator.java
deleted file mode 100644
index 8d0e09101..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedElementSelectionValidator.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-import java.util.Collection;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.ui.dialogs.ISelectionStatusValidator;
-
-/**
- * Implementation of a <code>ISelectionValidator</code> to validate the type
- * of an element. Empty selections are not accepted.
- *
- * @author mengbo
- * @version 1.5
- */
-/*package*/ class TypedElementSelectionValidator implements
- ISelectionStatusValidator {
-
- private IStatus _fgErrorStatus = new StatusInfo(IStatus.ERROR, ""); //$NON-NLS-1$
-
- private IStatus _fgOKStatus = new StatusInfo();
-
- private Class[] _fAcceptedTypes;
-
- private boolean _fAllowMultipleSelection;
-
- private Collection _fRejectedElements;
-
- /**
- * @param acceptedTypes
- * The types accepted by the validator
- * @param allowMultipleSelection
- * If set to <code>true</code>, the validator allows multiple
- * selection.
- */
- public TypedElementSelectionValidator(Class[] acceptedTypes,
- boolean allowMultipleSelection) {
- this(acceptedTypes, allowMultipleSelection, null);
- }
-
- /**
- * @param acceptedTypes
- * The types accepted by the validator
- * @param allowMultipleSelection
- * If set to <code>true</code>, the validator allows multiple
- * selection.
- * @param rejectedElements
- * A list of elements that are not accepted
- */
- public TypedElementSelectionValidator(Class[] acceptedTypes,
- boolean allowMultipleSelection, Collection rejectedElements) {
- Assert.isNotNull(acceptedTypes);
- _fAcceptedTypes = acceptedTypes;
- _fAllowMultipleSelection = allowMultipleSelection;
- _fRejectedElements = rejectedElements;
- }
-
- /*
- * @see org.eclipse.ui.dialogs.ISelectionValidator#isValid(java.lang.Object)
- */
- public IStatus validate(Object[] elements) {
- if (isValid(elements)) {
- return _fgOKStatus;
- }
- return _fgErrorStatus;
- }
-
- private boolean isOfAcceptedType(Object o) {
- for (int i = 0; i < _fAcceptedTypes.length; i++) {
- if (_fAcceptedTypes[i].isInstance(o)) {
- return true;
- }
- }
- return false;
- }
-
- private boolean isRejectedElement(Object elem) {
- return (_fRejectedElements != null)
- && _fRejectedElements.contains(elem);
- }
-
- private boolean isValid(Object[] selection) {
- if (selection.length == 0) {
- return false;
- }
-
- if (!_fAllowMultipleSelection && selection.length != 1) {
- return false;
- }
-
- for (int i = 0; i < selection.length; i++) {
- Object o = selection[i];
- if (!isOfAcceptedType(o) || isRejectedElement(o)) {
- return false;
- }
- }
- return true;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedViewerFilter.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedViewerFilter.java
deleted file mode 100644
index 52ecb6a2a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/TypedViewerFilter.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogfield;
-
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-
-/**
- * Viewer filter used in selection dialogs.
- *
- * @author mengbo
- * @version 1.5
- */
-/*package*/ class TypedViewerFilter extends ViewerFilter {
-
- private Class[] _fAcceptedTypes;
-
- private Object[] _fRejectedElements;
-
- /**
- * Creates a filter that only allows elements of gives types.
- *
- * @param acceptedTypes
- * The types of accepted elements
- */
- public TypedViewerFilter(Class[] acceptedTypes) {
- this(acceptedTypes, null);
- }
-
- /**
- * Creates a filter that only allows elements of gives types, but not from a
- * list of rejected elements.
- *
- * @param acceptedTypes
- * Accepted elements must be of this types
- * @param rejectedElements
- * Element equals to the rejected elements are filtered out
- */
- public TypedViewerFilter(Class[] acceptedTypes, Object[] rejectedElements) {
- Assert.isNotNull(acceptedTypes);
- _fAcceptedTypes = acceptedTypes;
- _fRejectedElements = rejectedElements;
- }
-
- /**
- * @see ViewerFilter#select(org.eclipse.jface.viewers.Viewer,
- * java.lang.Object, java.lang.Object)
- */
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (_fRejectedElements != null) {
- for (int i = 0; i < _fRejectedElements.length; i++) {
- if (element.equals(_fRejectedElements[i])) {
- return false;
- }
- }
- }
- for (int i = 0; i < _fAcceptedTypes.length; i++) {
- if (_fAcceptedTypes[i].isInstance(element)) {
- return true;
- }
- }
- return false;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonResourceDialog.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonResourceDialog.java
deleted file mode 100644
index debc2f996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonResourceDialog.java
+++ /dev/null
@@ -1,368 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogs;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.common.ui.internal.utils.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.model.WorkbenchLabelProvider;
-import org.eclipse.ui.views.navigator.ResourceComparator;
-
-/**
- * This dialog shows IFile type resources within a IProject domain for
- * selection. The client can prvide the suffixs of files to filter when
- * candidates are shown on the tree.
- *
- * The usage: Shell shell = new Shell(); IProject project = getProject();
- * CommonResourceDialog dlg = new CommonResourceDialog(shell, project);
- * dlg.setResourceDescription("image"); dlg.setSuffixs(new
- * String[]{"bmp","jpg","gif"}); if(dlg.open() == Window.OK) { IFile
- * selectedFile = (IFile)dlg.getResult()[0]; }
- *
- * Note: In code above, what you get is an absolute resource path. You can use
- * <code>org.eclipse.wst.sse.core.util.PathHelper.convertToRelative(String input, String base)</code>
- * to convert a absolute resource path to a relative path based on one path.
- *
- * @author mengbo
- */
-public class CommonResourceDialog extends TreeViewerSelectionDialog {
- private static Logger _log = JSFUICommonPlugin
- .getLogger(CommonResourceDialog.class);
-
- // private static final String STATUS_MESSAGE_0 = CommonPlugin
- // .getResourceString("Dialog.CommonResourceDialog.StatusMessage0");
- // //$NON-NLS-1$
-
- private IProject _project = null;
-
- private String _suffixs[] = null;
-
- private CommonResourceFilter _filter = null;
-
- // The resource type resourceDescription, such as "image", "jsp", "java
- // class" etc.
- private String _resourceDescription = null;
-
- private IFolder _folder;
-
- // The content provider
- class ProjectFileDialogContentProvider implements ITreeContentProvider {
- /**
- * The visual part that is using this content provider is about to be
- * disposed. Deallocate all allocated SWT resources.
- */
- public void dispose() {
- // nothing to dispose
- }
-
- /**
- * @see ITreeContentProvider#getChildren
- */
- public Object[] getChildren(Object element) {
- if (element instanceof Object[]) {
- return (Object[]) element;
- } else if (element instanceof IContainer) {
- IContainer container = (IContainer) element;
- if (container.isAccessible()) {
- try {
- return container.members();
- } catch (CoreException e) {
- _log.error(
- "Error.ProjectFileDialogContentProvider.0", e); //$NON-NLS-1$
- }
- }
-
- }
- return new Object[0];
- }
-
- /**
- * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(Object)
- */
- public Object[] getElements(Object element) {
- return getChildren(element);
- }
-
- /**
- * @see ITreeContentProvider#getParent
- */
- public Object getParent(Object element) {
- if (element instanceof IResource) {
- return ((IResource) element).getParent();
- }
- return null;
- }
-
- /**
- * @see ITreeContentProvider#hasChildren
- */
- public boolean hasChildren(Object element) {
- return getChildren(element).length > 0;
- }
-
- /**
- * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(Viewer, Object, Object)
- */
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- // no viewer change support required
- }
-
- }
-
- // The default resource filter
- class CommonResourceFilter extends ViewerFilter {
- private String _filterSuffixs[] = null;
-
- /**
- * @return Returns the _suffixs.
- */
- public String[] getSuffixs() {
- return _filterSuffixs;
- }
-
- /**
- * @param _suffixs
- * The _suffixs to set.
- */
- public void setSuffixs(String[] _suffixs) {
- this._filterSuffixs = _suffixs;
- }
-
- /*
- * (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) {
- if (element instanceof IFile) {
- IFile file = (IFile) element;
- if (!WebrootUtil.isUnderWebContentFolder(file)) {
- return false;
- }
- if (isSuffixBlank()) {
- return true;
- }
- if (file.getFileExtension() != null) {
- if (Arrays.asList(_filterSuffixs).contains(
- file.getFileExtension().toLowerCase())) {
- return true;
- }
- }
- } else if (element instanceof IContainer) {
- if (!((IContainer) element).isAccessible()) {
- return false;
- }
- if (element instanceof IProject) {
- return true;
- } else if (element instanceof IFolder) {
- IContainer container = (IContainer) element;
- try {
- IResource[] members = container.members();
- for (int i = 0; i < members.length; i++) {
- if (select(viewer, members[i].getParent(),
- members[i])) {
- return true;
- }
- }
- } catch (CoreException e) {
- _log.error(
- "Error.ProjectFileDialogContentProvider.0", e); //$NON-NLS-1$
- return false;
- }
- }
- }
- return false;
- }
-
- }
-
- /**
- * This is a dialog for common resource selection, the resouce supported
- * include IFolder, IProject, IFile, user can provide
- *
- * @param parentShell
- * @param project
- * @param style
- */
- public CommonResourceDialog(Shell parentShell, IProject project, int style) {
- super(parentShell, "", style); //$NON-NLS-1$
- if (project == null) {
- throw new IllegalArgumentException(
- "Argument(project) cannot be null"); //$NON-NLS-1$
- }
- _project = project;
- setContentProvider(new ProjectFileDialogContentProvider());
- setLabelProvider(WorkbenchLabelProvider
- .getDecoratingWorkbenchLabelProvider());
- _filter = new CommonResourceFilter();
- setFilter(_filter);
- setViewerComparator(new ResourceComparator(ResourceComparator.TYPE));
- _project = project;
- setStatusMessage(getStatusMessage());
- }
-
- /**
- * Same as CommonResourceDialog(parentShell, project, SWT.NONE)
- *
- * @param parentShell
- * @param project
- */
- public CommonResourceDialog(Shell parentShell, IProject project) {
- this(parentShell, project, SWT.NONE);
- }
-
- private String getStatusMessage() {
- if (_resourceDescription == null) {
- return ""; //$NON-NLS-1$
- }
- return _resourceDescription;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.ui.common.SelectionTreeViewerDialog#findInputElement()
- */
- protected Object findInputElement() {
- if (_folder != null) {
- return new Object[] { _folder, };
- }
- return new Object[] { _project, };
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.ui.common.SelectionTreeViewerDialog#isValidSelection(java.lang.Object)
- */
- protected boolean isValidSelection(Object selection) {
- if (selection instanceof Object[]) {
- for (int i = 0, n = ((Object[]) selection).length; i < n; i++) {
- if (isValidElement(((Object[]) selection)[i]) == true) {
- return true;
- }
- }
- return false;
- }
- return isValidElement(selection);
- }
-
- private boolean isValidElement(Object selection) {
- if ((selection instanceof IFile)) {
- // Null means no filter is set
- if (isSuffixBlank()) {
- return true;
- }
- // The extension is supported?
- else if (_suffixs != null
- && Arrays.asList(_suffixs).contains(
- ((IFile) selection).getFileExtension()
- .toLowerCase())) {
- return true;
- }
- }
- // None of above conditions, invalid.
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.dialogs.SelectionDialog#getResult()
- */
- public Object[] getResult() {
- Object[] objects = super.getResult();
- if (objects == null || objects.length == 0) {
- return null;
- }
- List list = new ArrayList();
- for (int i = 0; i < objects.length; i++) {
- if (objects[i] instanceof IFile) {
- list.add(objects[i]);
- }
- }
- return list.toArray();
- }
-
- /**
- * @param suffixs
- * The suffixs to set.
- */
- public void setSuffixs(String[] suffixs) {
- this._suffixs = convertTolowercase(suffixs);
- _filter.setSuffixs(_suffixs);
- setStatusMessage(getStatusMessage());
- }
-
- private String[] convertTolowercase(String[] suffixs) {
- if (suffixs != null) {
- String[] newSuffixs = new String[suffixs.length];
- for (int i = 0; i < suffixs.length; i++) {
- newSuffixs[i] = suffixs[i].toLowerCase();
- }
- return newSuffixs;
- }
- return null;
- }
-
- /**
- * @return Returns the sourceDescription.
- */
- public String getResourceDescription() {
- return _resourceDescription;
- }
-
- /**
- * @param sourceDescription
- * The sourceDescription to set.
- */
- public void setResourceDescription(String sourceDescription) {
- this._resourceDescription = sourceDescription;
- setStatusMessage(getStatusMessage());
- }
-
- private boolean isSuffixBlank() {
- boolean isSuffixBlank = false;
- if (_suffixs == null) {
- isSuffixBlank = true;
- } else {
- int count = 0;
- for (int i = 0, size = _suffixs.length; i < size; i++) {
- if (_suffixs[i] != null && !"".equals(_suffixs[i])) { //$NON-NLS-1$
- count++;
- break;
- }
- }
- if (count == 0) {
- isSuffixBlank = true;
- }
- }
- return isSuffixBlank;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonWizardDialog.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonWizardDialog.java
deleted file mode 100644
index 3fd719c77..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/CommonWizardDialog.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogs;
-
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.wizard.IWizard;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * Wizard Dialog with a Finish set to OK if no previous
- * or next buttons are needed
- *
- */
-public class CommonWizardDialog extends WizardDialog {
-
- /**
- * @param parentShell
- * @param newWizard
- */
- public CommonWizardDialog(Shell parentShell, IWizard newWizard) {
- super(parentShell, newWizard);
- }
-
- protected void createButtonsForButtonBar(Composite parent) {
- super.createButtonsForButtonBar(parent);
-
- IWizard wizard = getWizard();
- if (!wizard.needsPreviousAndNextButtons()) {
- getButton(IDialogConstants.FINISH_ID).setText(
- IDialogConstants.OK_LABEL);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/ResourceOnClasspathDialog.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/ResourceOnClasspathDialog.java
deleted file mode 100644
index 934957d96..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/ResourceOnClasspathDialog.java
+++ /dev/null
@@ -1,254 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogs;
-
-import java.io.File;
-import java.util.Arrays;
-
-import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspace;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jdt.core.IJarEntryResource;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.ui.JavaElementLabelProvider;
-import org.eclipse.jdt.ui.StandardJavaElementContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.utils.PathUtil;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * This dialog will let client to select resources that located on a
- * IJavaProject classpath, the client can provide a list of files suffixs to
- * filter.
- *
- * @author mengbo
- */
-// TODO: Since many jar files might do nothing to do with client's selection, we
-// may need to provides more filter choice
-// to clients to exclude unnecessary jar files, such as that are located in JDK
-// dir.
-public class ResourceOnClasspathDialog extends TreeViewerSelectionDialog {
- // ResourcesOnClasspathDialog.statusMessage = Please select a property file
- private static final String STATUS_MESSAGE = JSFUICommonPlugin
- .getResourceString("Dialog.ResourceOnClasspathDialog.StatusMessage"); //$NON-NLS-1$
-
- private IJavaProject _javaProject;
-
- // the suffixs of files that can be selected
- private String _suffixs[];
-
- // IJMTConstants.DEFAULT_SUFFIX;
-
- private ResourceOnClasspathFilter _filter;
-
- // Client doesn't need to know it.
- class ResourceOnClasspathFilter extends ViewerFilter {
- StandardJavaElementContentProvider _javaContentProvider;
-
- /**
- * @param contentProvider
- */
- public ResourceOnClasspathFilter(
- StandardJavaElementContentProvider contentProvider) {
- _javaContentProvider = contentProvider;
- }
-
- /**
- * Set the suffixs of files need to be selected.
- *
- * @param suffixs
- */
- public void setSuffixs(String suffixs[]) {
- _suffixs = suffixs;
- }
-
- /**
- * @param contentProvider
- * The _javaContentProvider to set.
- */
- public void setJavaContentProvider(
- StandardJavaElementContentProvider contentProvider) {
- _javaContentProvider = contentProvider;
- }
-
- /**
- * @param project
- * The _javaProject to set.
- */
- public void setJavaProject(IJavaProject project) {
- _javaProject = project;
- }
-
- /*
- * (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) {
- // TODO: This logic can be improved by add caching mechanism
- if (element instanceof IJavaProject) {
- String currentProjectName = ((IJavaProject) element)
- .getProject().getFullPath().toString().trim();
- String projectName = _javaProject.getProject().getFullPath()
- .toString().trim();
- if (projectName.equalsIgnoreCase(currentProjectName)) {
- return true;
- }
- return false;
- } else if (element instanceof IResource) {
- if (((_javaProject != null) && !_javaProject
- .isOnClasspath((IResource) element))) {
- return false;
- }
- if (element instanceof IFile) {
- if (Arrays.asList(_suffixs).contains(
- ((IFile) element).getFileExtension())) {
- return true;
- }
- }
- return false;
- }
-
- if (element instanceof IJarEntryResource) {
- String ext = ((IJarEntryResource) element).getFullPath()
- .getFileExtension();
- if (ext != null && Arrays.asList(_suffixs).contains(ext)) {
- return true;
- }
- return false;
- }
- if (!(element instanceof IJavaElement)) {
- return false;
- }
- if (((_javaProject != null) && !_javaProject
- .isOnClasspath((IJavaElement) element))) {
- return false;
- }
- IJavaElement javaElement = (IJavaElement) element;
- Object[] children = null;
- switch (javaElement.getElementType()) {
- case IJavaElement.PACKAGE_FRAGMENT_ROOT:
- children = _javaContentProvider.getChildren(javaElement);
- break;
- case IJavaElement.IMPORT_CONTAINER:
- return true;
- case IJavaElement.PACKAGE_FRAGMENT:
- children = _javaContentProvider.getChildren(javaElement);
- break;
- case IJavaElement.CLASS_FILE:
- if (Arrays.asList(_suffixs).contains(
- IFileFolderConstants.EXT_CLASS)) {
- return true;
- }
- return false;
- case IJavaElement.COMPILATION_UNIT:
- String ext = javaElement.getPath().getFileExtension();
- if (ext != null && Arrays.asList(_suffixs).contains(ext)) {
- return true;
- }
- return false;
- default:
- return false;
- }
-
- for (int i = 0; i < children.length; i++) {
- if (select(viewer, javaElement, children[i])) {
- return true;
- }
- }
- // Either the resouce or its children are not for displaying.
- return false;
- }
- }
-
- /**
- * Set the suffixs of files need to be selected.
- *
- * @param suffixs
- */
- public void setSuffixs(String suffixs[]) {
- _suffixs = suffixs;
- _filter.setSuffixs(suffixs);
- }
-
- /**
- * @param parentShell
- * @param project
- */
- public ResourceOnClasspathDialog(Shell parentShell, IJavaProject project) {
- super(parentShell, STATUS_MESSAGE);
- // set provider and filter
- StandardJavaElementContentProvider contentProvider = new StandardJavaElementContentProvider();
- setContentProvider(contentProvider);
- setLabelProvider(new JavaElementLabelProvider());
- _filter = new ResourceOnClasspathFilter(contentProvider);
- setFilter(_filter);
- // store the project
- _javaProject = project;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.dialogs.SelectionDialog#getResult()
- */
- public Object[] getResult() {
- Object[] objects = super.getResult();
- if (objects == null || objects.length == 0) {
- return null;
- }
- IPath path = PathUtil.getPathOnClasspath(_javaProject, objects[0]);
- String result = null;
- if (path.segmentCount() == 0) {
- return new Object[] { "" }; //$NON-NLS-1$
- }
- path = path.removeFileExtension();
- result = path.toOSString();
- result = result.replace(File.separatorChar, '.');
- return new Object[] { result };
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.ui.common.SelectionTreeViewerDialog#isValidSelection()
- */
- protected boolean isValidSelection(Object selection) {
- String extension = PathUtil.getPathOnClasspath(_javaProject, selection)
- .getFileExtension();
- return (extension != null && Arrays.asList(_suffixs).contains(extension));
- }
-
- protected Object findInputElement() {
- Object input = ResourcesPlugin.getWorkspace();
- if (input instanceof IWorkspace) {
- return JavaCore.create(((IWorkspace) input).getRoot());
- } else if (input instanceof IContainer) {
- IJavaElement element = JavaCore.create((IContainer) input);
- if (element != null && element.exists()) {
- return element;
- }
- return input;
- }
- return JavaCore.create(ResourcesPlugin.getWorkspace().getRoot());
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/TreeViewerSelectionDialog.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/TreeViewerSelectionDialog.java
deleted file mode 100644
index 3214dbd7e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogs/TreeViewerSelectionDialog.java
+++ /dev/null
@@ -1,393 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.dialogs;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.ViewerComparator;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.part.DrillDownComposite;
-
-/**
- * This is a base dialog that uses TreeViewer to show selections, subclass needs
- * to provide IContentProvider, ILabelProvider and ViewerFilter for the
- * TreeViewer. Subclass needs to implement isValidSelection(), which valids the
- * selection, and findInputElement() which provides the root element of the
- * tree. Besides, subclass might need to implement getResult() to return a
- * customized result.
- *
- * @author mengbo
- *
- */
-public abstract class TreeViewerSelectionDialog extends SelectionDialog {
- private static final String DEFAULT_TITLE = JSFUICommonPlugin
- .getResourceString("Dialog.TreeViewerSelectionDialog.DefaultTitle"); //$NON-NLS-1$
-
- /** Used to tag the image type */
- public static final int STYLE_NONE = 0;
-
- private static final int STYLE_INFORMATION = 1;
-
- private static final int STYLE_ERROR = 2;
-
- private static final int STYLE_WARNING = 3;
-
- /** Sizi of the TreeViewer composite */
- private static final int SIZING_SELECTION_PANE_HEIGHT = 300;
-
- private static final int SIZING_SELECTION_PANE_WIDTH = 320;
-
- private String _title = DEFAULT_TITLE;
-
- // the seleciton on the treeviewer.
- private static Object[] _selection;
-
- // providers
- private ITreeContentProvider _contentProvider;
-
- private ILabelProvider _labelProvider;
-
- private ViewerFilter _filter;
-
- /** The validation image */
- private Label _statusImage;
-
- /** The validation message */
- private Label _statusLabel;
-
- private String _statusMessage;
-
- /** The selection tree */
- private TreeViewer _treeViewer;
-
- private int _style;
-
- private ViewerSorter _viewerSorter = null;
- private ViewerComparator _viewerComparator = null;
- /**
- * @param parentShell
- * @param statusMessage
- * @param style
- */
- public TreeViewerSelectionDialog(Shell parentShell, String statusMessage,
- int style) {
- super(parentShell);
- _statusMessage = statusMessage;
- _style = style;
- setShellStyle(SWT.CLOSE | SWT.TITLE | SWT.BORDER
- | SWT.APPLICATION_MODAL | SWT.RESIZE);
- }
-
- /**
- * Convenience for TreeViewerSelectionDialog(parentShell, statusMessage, SWT.NONE)
- *
- * @param parentShell
- * @param statusMessage
- */
- public TreeViewerSelectionDialog(Shell parentShell, String statusMessage) {
- this(parentShell, statusMessage, SWT.NONE);
- }
-
- public void setTitle(String title) {
- super.setTitle(title);
- _title = title;
- }
-
- /**
- * Returns a new drill down viewer for this dialog.
- * @param parent
- */
- protected void createTreeViewer(Composite parent) {
- // Create drill down
- DrillDownComposite drillDown = new DrillDownComposite(parent,
- SWT.BORDER);
- GridData spec = new GridData(GridData.FILL_BOTH);
- spec.widthHint = SIZING_SELECTION_PANE_WIDTH;
- spec.heightHint = SIZING_SELECTION_PANE_HEIGHT;
- drillDown.setLayoutData(spec);
- _treeViewer = new TreeViewer(drillDown, _style);
- drillDown.setChildTree(_treeViewer);
- }
-
- private void setTreeViewerProviders() {
- _treeViewer.setContentProvider(_contentProvider);
- _treeViewer.setLabelProvider(_labelProvider);
- if (_viewerSorter == null) {
- _viewerSorter = new ViewerSorter();
- }
- _treeViewer.setSorter(_viewerSorter);
-
- // override if not null.. setSorter is discouraged.
- if (_viewerComparator != null)
- {
- _treeViewer.setComparator(_viewerComparator);
- }
- _treeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
- public void selectionChanged(SelectionChangedEvent event) {
- _selection = getSelectedElements((IStructuredSelection) event
- .getSelection());
- updateStatus();
- }
- });
- _treeViewer.addDoubleClickListener(new IDoubleClickListener() {
- public void doubleClick(DoubleClickEvent event) {
- ISelection selection = event.getSelection();
- if (selection instanceof IStructuredSelection) {
- Object item = ((IStructuredSelection) selection)
- .getFirstElement();
- if (item instanceof IFile) {
- okPressed();
- } else if (_treeViewer.getExpandedState(item)) {
- _treeViewer.collapseToLevel(item, 1);
- } else {
- _treeViewer.expandToLevel(item, 1);
- }
- }
- }
- });
- _treeViewer.setInput(findInputElement());
-
- if (_filter != null) {
- _treeViewer.addFilter(_filter);
- }
- }
-
- /**
- * Creates the contents of the composite.
- * @param parent
- */
- protected void createTreeViewerComposite(Composite parent) {
- Composite treeViewerComposite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.marginWidth = 0;
- treeViewerComposite.setLayout(layout);
-
- GridData gridData = new GridData(GridData.FILL_HORIZONTAL);
- gridData.horizontalSpan = 2;
- treeViewerComposite.setLayoutData(gridData);
- Label label = new Label(treeViewerComposite, SWT.WRAP);
- label.setText(_title);
- label.setFont(treeViewerComposite.getFont());
- createTreeViewer(treeViewerComposite);
- Dialog.applyDialogFont(treeViewerComposite);
- }
-
- /**
- * Sets the selected existing container.
- * @param selection
- */
- public void setSelectedElement(Object[] selection) {
- // Expand to and select the specified container
- if (selection == null) {
- return;
- }
-
- for (int i = 0; i < selection.length; i++) {
- if (_selection[i] != null) {
- _treeViewer.expandToLevel(_selection[i], 1);
-
- }
- }
- _treeViewer.setSelection(new StructuredSelection(selection), true);
- }
-
- /*
- * (non-Javadoc) Method declared on Dialog.
- */
- protected Control createDialogArea(Composite parent) {
- Composite area = (Composite) super.createDialogArea(parent);
- GridLayout gridLayout = new GridLayout();
- gridLayout.numColumns = 2;
- area.setLayout(gridLayout);
-
- // Container treeviewer composite
- createTreeViewerComposite(area);
-
- _statusImage = createLabel(area);
- _statusImage.setImage(getMessageImage(STYLE_ERROR));
- _statusLabel = createLabel(area);
- // Link to model
- setTreeViewerProviders();
-
- return dialogArea;
- }
-
- private Label createLabel(Composite parent) {
- Label label = new Label(parent, SWT.LEFT);
- GridData data = new GridData();
- data.horizontalSpan = 1;
- data.horizontalAlignment = GridData.FILL;
- label.setLayoutData(data);
- label.setText(_statusMessage == null ? "" : _statusMessage); //$NON-NLS-1$
- return label;
- }
-
- private Object[] getSelectedElements(IStructuredSelection selection) {
- return selection.toArray();
- }
-
- /**
- * @param provider
- * The _contentProvider to set.
- */
- public void setContentProvider(ITreeContentProvider provider) {
- _contentProvider = provider;
- }
-
- /**
- * @param provider
- * The _labelProvider to set.
- */
- public void setLabelProvider(ILabelProvider provider) {
- _labelProvider = provider;
- }
-
- /**
- * @param filter
- * The _filter to set.
- */
- public void setFilter(ViewerFilter filter) {
- this._filter = filter;
- }
-
- /**
- * @param sorter
- * The _viewerSorter to set.
- */
- public void setViewerSorter(ViewerSorter sorter) {
- _viewerSorter = sorter;
- }
-
- /**
- * Set the viewer comparator. If not null, it's set after after the
- * viewer sorter and thus overrides it.
- *
- * @param viewerComparator
- */
- public void setViewerComparator(ViewerComparator viewerComparator)
- {
- _viewerComparator = viewerComparator;
- }
-
- /**
- * @param message
- */
- public void setStatusMessage(String message) {
- _statusMessage = message;
- }
-
- /**
- * Update the status message
- */
- private void updateStatus() {
- Object selection = _selection;
- if (_selection != null && _selection.length == 1) {
- selection = _selection[0];
- }
- if (isValidSelection(selection)) {
- _statusImage.setVisible(false);
- _statusLabel.setText(""); //$NON-NLS-1$
- getOkButton().setEnabled(true);
- } else {
- _statusImage.setVisible(true);
- _statusImage.setImage(getMessageImage(STYLE_ERROR));
- _statusImage.redraw();
- _statusLabel.setText(_statusMessage);
- getOkButton().setEnabled(false);
- }
-
- }
-
- /**
- * Get the different message according the message type.
- * @param imageType
- *
- * @return Image - the message image
- */
- protected Image getMessageImage(int imageType) {
- switch (imageType) {
- case STYLE_ERROR:
- return JFaceResources.getImage(Dialog.DLG_IMG_MESSAGE_ERROR);
- case STYLE_WARNING:
- return JFaceResources.getImage(Dialog.DLG_IMG_MESSAGE_WARNING);
- case STYLE_INFORMATION:
- return JFaceResources.getImage(Dialog.DLG_IMG_MESSAGE_INFO);
- default:
- return null;
- }
- }
-
- /**
- * The <code>ContainerSelectionDialog</code> implementation of this
- * <code>Dialog</code> method builds a list of the selected resource
- * containers for later retrieval by the client and closes this dialog.
- */
- protected void okPressed() {
- List chosenContainerPathList = new ArrayList();
- if (_selection != null) {
- chosenContainerPathList.addAll(Arrays.asList(_selection));
- }
- setResult(chosenContainerPathList);
- super.okPressed();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.window.Window#createContents(org.eclipse.swt.widgets.Composite)
- */
- protected Control createContents(Composite parent) {
- Control control = super.createContents(parent);
- if (_selection != null) {
- this.setSelectedElement(_selection);
- }
- return control;
- }
-
- /**
- * @param selection
- * @return true if selection is valid
- */
- protected abstract boolean isValidSelection(Object selection);
-
- /**
- * Used to set the input element on the tree viewer
- * @return the input element
- */
- protected abstract Object findInputElement();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractDetailsForm.java
deleted file mode 100644
index 887d57f9b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractDetailsForm.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.form;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * The parent of all detail forms.
- *
- * @author cbateman
- *
- */
-public abstract class AbstractDetailsForm
-{
- private FormToolkit _toolkit;
-
- /**
- *
- */
- protected AbstractDetailsForm()
- {
- super();
- }
-
- /**
- * Called to refresh model if stale
- */
- public void refresh()
- {
- // do nothing by default
- }
-
- /**
- * Called before createContents.
- *
- * @param toolkit
- */
- public final void initialize(final FormToolkit toolkit)
- {
- _toolkit = toolkit;
- doInitialize();
- }
-
- /**
- * Override to customize initialization. getToolkit() is safe to call
- * from this method. You should not make other state assumptions.
- */
- protected void doInitialize()
- {
- // do nothing by default;
- }
-
- /**
- * Callled by MasterDetailBlock during it's dispose
- */
- public abstract void dispose();
-
- /**
- * @param onSave
- */
- public abstract void commit(boolean onSave);
-
- /**
- * Called on this details form before it is shown, when it becomes active
- * due to a matching selection change in the master form. Implementer
- * should use newSelection as the new instance of their model and
- * reinitialize UI as appropriate.
- * @param newSelection
- */
- protected abstract void doUpdateSelection(final Object newSelection);
-
- /**
- * @return the contents control. Must not be called before createContents.
- */
- public abstract Control getControl();
-
- /**
- * Fired to indicate that this detail form is now selected based on the
- * master form selected.
- *
- * @param selection
- */
- public void selectionChanged(final ISelection selection)
- {
- // by default, get the first element of the selection if there is
- // one and call doUpdateSelection on it. Sub-classes may change
- // this behaviour
- if (selection instanceof IStructuredSelection)
- {
- final Object selectionObj = ((IStructuredSelection) selection)
- .getFirstElement();
- doUpdateSelection(selectionObj);
- }
- }
-
- /**
- * Create the contents of the detail form using 'parent'. Should not be
- * called before initialize.
- *
- * @param parent
- */
- public abstract void createContents(Composite parent);
-
- /**
- * @return the form toolkit in use. Should not be called before
- * initialize.
- */
- protected final FormToolkit getToolkit()
- {
- return _toolkit;
- }
-
- /**
- * @return true if the form is dirty
- */
- public boolean isDirty()
- {
- // never dirty by default
- return false;
- }
-
- /**
- * @return true if form is stale
- */
- public boolean isStale()
- {
- // always stale by default
- return true;
- }
-
- /**
- * Called to set focus on the detail form's control
- */
- public abstract void setFocus();
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterDetailBlock.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterDetailBlock.java
deleted file mode 100644
index 7141dcb88..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterDetailBlock.java
+++ /dev/null
@@ -1,206 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.form;
-
-import java.util.List;
-
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.BusyIndicator;
-import org.eclipse.swt.custom.SashForm;
-import org.eclipse.swt.custom.StackLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.widgets.Form;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * An alternative to MasterDetailBlock that doesn't use the ScrolledForm
- * that causes problems as described here:
- *
- * http://dev.eclipse.org/newslists/news.eclipse.platform/msg73145.html
-
- * @author cbateman
- *
- */
-public abstract class AbstractMasterDetailBlock implements
- ISelectionChangedListener
-{
- private AbstractMasterForm _masterForm;
- private Composite _detailsPanel;
- private AbstractDetailsForm _curPage;
- private FormToolkit _toolkit;
- private StackLayout _detailLayout;
- private List<AbstractDetailsForm> _detailForms;
- private BlankDetailsForm _blankDetails;
-
- /**
- *
- */
- protected AbstractMasterDetailBlock()
- {
- super();
- }
-
- /**
- * Disposes the master detail form
- */
- public final void dispose()
- {
- _masterForm.dispose();
-
- for (final AbstractDetailsForm detailsForm : _detailForms)
- {
- detailsForm.dispose();
- }
-
- doDispose();
- }
-
- /**
- * Override to get custom dispose logic. Do not use this to dispose of
- * master or details forms. This is done automatically for you before
- * doDispose is called.
- */
- protected void doDispose()
- {
- // do nothing by default
- }
-
- /**
- * @param toolkit
- * @param form
- */
- public final void createContent(final FormToolkit toolkit, final Form form)
- {
- _toolkit = toolkit;
-
- final GridLayout layout = new GridLayout();
- layout.marginWidth = 5;
- layout.marginHeight = 5;
- form.getBody().setLayout(layout);
- final SashForm sashForm = new SashForm(form.getBody(), SWT.NULL);
- // sashForm.setData("form", managedForm); //$NON-NLS-1$
- _toolkit.adapt(sashForm, false, false);
- sashForm.setMenu(form.getBody().getMenu());
- sashForm.setLayoutData(new GridData(GridData.FILL_BOTH));
- initializeMasterPart(_toolkit, sashForm);
- createDetailsPart(sashForm);
-
- _masterForm.createHead(form);
- createToolBarActions(form);
- form.updateToolBar();
- }
-
- /**
- * @param toolkit
- * @return the master form.
- */
- protected abstract AbstractMasterForm createMasterPart(
- final FormToolkit toolkit);
-
- private void initializeMasterPart(final FormToolkit toolkit,
- final Composite parent)
- {
- _masterForm = createMasterPart(toolkit);
- _masterForm.initialize(this);
- _masterForm.createClientArea(parent);
- }
-
- private void createToolBarActions(final Form form)
- {
- _masterForm.contributeActions(form.getToolBarManager());
- }
-
- private void createDetailsPart(final Composite parent)
- {
- _detailsPanel = new Composite(parent, SWT.NONE);
- _detailLayout = new StackLayout();
- _detailsPanel.setLayout(_detailLayout);
-
- _detailForms = createDetailPages();
-
- for (final AbstractDetailsForm detailForm : _detailForms)
- {
- detailForm.initialize(_toolkit);
- detailForm.createContents(_detailsPanel);
- }
-
- // create default blank page
- _blankDetails = new BlankDetailsForm();
- _blankDetails.initialize(_toolkit);
- _blankDetails.createContents(_detailsPanel);
-
- _curPage = _blankDetails;
- _detailLayout.topControl = _curPage.getControl();
- _detailsPanel.layout();
- }
-
- public final void selectionChanged(final SelectionChangedEvent event)
- {
- final Object selectedObj = ((IStructuredSelection) event.getSelection())
- .getFirstElement();
- final AbstractDetailsForm page = selectPage(selectedObj);
- if (page != null)
- {
- final AbstractDetailsForm fpage = page;
- BusyIndicator.showWhile(_detailsPanel.getDisplay(), new Runnable()
- {
- public void run()
- {
- final AbstractDetailsForm oldPage = _curPage;
- _curPage = fpage;
- // commit the current page
- if (oldPage != null && oldPage.isDirty())
- {
- oldPage.commit(false);
- }
- // refresh the new page
- if (fpage.isStale())
- {
- fpage.refresh();
- }
- _curPage.selectionChanged(event.getSelection());
- // _pageBook.showPage(_curPage.getTextSection().getControl());
- _detailLayout.topControl = _curPage.getControl();
- _detailsPanel.layout();
- }
- });
- }
- }
-
- /**
- * @return a list of detail forms
- */
- protected abstract List<AbstractDetailsForm> createDetailPages();
-
- /**
- * @param forModel
- * @return the details form for 'forModel'. If implementer returns null,
- * then a blank page will be provided
- */
- protected abstract AbstractDetailsForm doSelectPage(final Object forModel);
-
- private AbstractDetailsForm selectPage(final Object forModel)
- {
- final AbstractDetailsForm clientForm = doSelectPage(forModel);
-
- if (clientForm != null)
- {
- return clientForm;
- }
- return _blankDetails;
- }
-
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterForm.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterForm.java
deleted file mode 100644
index 46ec8646e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractMasterForm.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.form;
-
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.ToolBarManager;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.ToolBar;
-import org.eclipse.ui.forms.widgets.Form;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- *
- * @author cbateman
- *
- */
-public abstract class AbstractMasterForm
-{
-
- private final FormToolkit _toolkit;
- private ISelectionChangedListener _listener;
- private ToolBarManager _toolBarManager;
-
- /**
- * @param toolkit
- */
- protected AbstractMasterForm(FormToolkit toolkit)
- {
- super();
- _toolkit = toolkit;
- }
-
- /**
- * @param listener
- * the selection listener that is signalled to indicate the
- * selection in the master has changed and the detail should be
- * updated.
- */
- public final void initialize(final ISelectionChangedListener listener)
- {
- _listener = listener;
- doInitialize();
- }
-
- /**
- * It is safe to call getListener() and get getToolkit() in this method. All
- * other methods should be considered unavailable.
- */
- protected void doInitialize()
- {
- // do nothing by default; override to do customize init
- }
-
- /**
- * @param parent
- * @return the client area for the master form, using parent is the parent
- * control.
- */
- public abstract Control createClientArea(final Composite parent);
-
- /**
- * @param form
- */
- public final void createHead(final Form form)
- {
- final Composite head = form.getHead();
- final Composite container = getToolkit().createComposite(head);
- container.setLayout(new RowLayout());
-
- // sub-class contribution
- contributeToHeadArea(getToolkit(), container);
-
- _toolBarManager = new ToolBarManager(SWT.FLAT);
- ToolBar toolbar = _toolBarManager.createControl(container);
- // _toolkit.adapt(toolbar, false, false);
-
- toolbar.setBackground(form.getHead().getBackground());
- toolbar.setForeground(form.getHead().getForeground());
- //toolbar.setCursor(FormsResources.getHandCursor());
- container.addDisposeListener(new DisposeListener()
- {
- public void widgetDisposed(DisposeEvent e)
- {
- if (_toolBarManager != null)
- {
- _toolBarManager.dispose();
- _toolBarManager = null;
- }
- }
- });
-
- form.setHeadClient(container);
-
- }
-
- /**
- * Override to add client area before the toolbar.
- *
- * @param toolkit
- * @param container
- */
- protected void contributeToHeadArea(FormToolkit toolkit, Composite container)
- {
- // do nothing by default
- }
-
- /**
- * @param formManager
- */
- public final void contributeActions(final IToolBarManager formManager)
- {
- contributeActions(formManager, _toolBarManager);
- }
-
- /**
- * @param formManager
- * adds to the toolkit's toolbar
- * @param localManager
- * adds to AbstractMasterForm's toolbar.
- */
- protected void contributeActions(final IToolBarManager formManager,
- final IToolBarManager localManager)
- {
- // do nothing by default. Override to add actions.
- }
-
- /**
- * Should be called at any time after initialize and createContents when the
- * owner is finished with the master-detail form block.
- */
- public void dispose()
- {
- // do nothing by default;
- }
-
- /**
- * @return the tool kit in use.
- */
- protected final FormToolkit getToolkit()
- {
- return _toolkit;
- }
-
- /**
- * @return the selection listener
- */
- protected final ISelectionChangedListener getListener()
- {
- return _listener;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractXMLSectionsDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractXMLSectionsDetailsForm.java
deleted file mode 100644
index 902ec7e94..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/AbstractXMLSectionsDetailsForm.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.form;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.RowData;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-/**
- * A detail form that uses XML text sections.
- *
- * @author cbateman
- *
- */
-public abstract class AbstractXMLSectionsDetailsForm extends
- AbstractDetailsForm
-{
- private Map<Object, XMLTextSection> _textSections;
- private Composite _detailFormComposite;
-
- /**
- * @param parent
- */
- @Override
- public final void createContents(final Composite parent)
- {
- _detailFormComposite = getToolkit().createComposite(parent, SWT.NONE);
- final RowLayout rowLayout = new RowLayout(SWT.VERTICAL);
- rowLayout.fill = true;
- _detailFormComposite.setLayout(rowLayout);
- // take a copy of what's returned so the sub-class can't control
- // the map reference
- _textSections = Collections
- .unmodifiableMap(new HashMap<Object, XMLTextSection>(
- createXMLTextSections(_detailFormComposite)));
-
- final Set<XMLTextSection> expandedSections = getInitiallyExpanded(_textSections);
- for (final Map.Entry<? extends Object, XMLTextSection> entry : _textSections
- .entrySet())
- {
- final XMLTextSection section = entry.getValue();
- if (expandedSections.contains(section))
- {
- section._section.setExpanded(true);
- }
- }
- }
-
- /**
- * @param parent
- * the parent that should be used for all XMLTextSections
- * @return a map keyed by an object type understood by the sub-class
- * containing as values the XMLTextSections
- */
- protected abstract Map<? extends Object, XMLTextSection> createXMLTextSections(
- final Composite parent);
-
- /**
- * @param sections
- * @return the subset of XMLTextSections in the provided map that are to be
- * expanded. NOTE: all elements in the returned set must be in
- * sections.getValues.
- */
- protected abstract Set<XMLTextSection> getInitiallyExpanded(
- final Map<Object, XMLTextSection> sections);
-
- /**
- * @return the control for this form
- */
- @Override
- public Control getControl()
- {
- return _detailFormComposite;
- }
-
- /**
- * @param selection
- */
- public final void selectionChanged(final ISelection selection)
- {
- if (selection instanceof IStructuredSelection)
- {
- final Object selectionObj = ((IStructuredSelection) selection)
- .getFirstElement();
- doUpdateSelection(selectionObj);
- }
- }
-
- @Override
- public void commit(final boolean onSave)
- {
- // do nothing
- }
-
- @Override
- public void dispose()
- {
- // do nothing
- }
-
- @Override
- public void setFocus()
- {
- // do nothing; sub-classes should override to pick an XMLTextSection
- // where they want focus.
- }
-
- /**
- * An XML text section
- *
- */
- protected final static class XMLTextSection
- {
- private final Section _section;
- private FormText _formText;
-
- /**
- * @param toolkit
- * @param parent
- * @param title
- */
- public XMLTextSection(final FormToolkit toolkit,
- final Composite parent, final String title)
- {
- _section = toolkit.createSection(parent,
- ExpandableComposite.TREE_NODE
- | ExpandableComposite.CLIENT_INDENT);
- _section.setLayoutData(new RowData());
- _section.setText(title);
-
- _formText = toolkit.createFormText(_section, true);
- _formText.setText("", false, false); //$NON-NLS-1$
-
- _section.setClient(_formText);
- }
-
- /**
- * @param text
- * @param parseTags
- * @param expandURLs
- */
- public void setText(final String text, final boolean parseTags,
- final boolean expandURLs)
- {
- _formText.setText(text, parseTags, expandURLs);
- }
-
- /**
- * @return the parent control.
- */
- public Control getControl()
- {
- return _section;
- }
-
- /**
- * Force a visual relayout and update.
- */
- public void refresh()
- {
- _section.getParent().layout(true, true);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/BlankDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/BlankDetailsForm.java
deleted file mode 100644
index 7678b0394..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/form/BlankDetailsForm.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.form;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * A blank details form.
- *
- * @author cbateman
- *
- */
-public final class BlankDetailsForm extends AbstractDetailsForm
-{
- private Composite _emptyPanel;
-
- @Override
- public void createContents(Composite parent)
- {
- _emptyPanel = getToolkit().createComposite(parent);
- }
-
- @Override
- public Control getControl()
- {
- return _emptyPanel;
- }
-
- @Override
- protected void doUpdateSelection(Object newSelection)
- {
- // do nothing
- }
-
- @Override
- public void commit(boolean onSave)
- {
- // nothing to commit
- }
-
- @Override
- public void dispose()
- {
- // nothing to dispose
- }
-
- @Override
- public void setFocus()
- {
- // don't bother changing focus
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Alerts.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Alerts.java
deleted file mode 100644
index 54c3a27a7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Alerts.java
+++ /dev/null
@@ -1,837 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import java.lang.reflect.InvocationTargetException;
-import java.text.MessageFormat;
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.MultiStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.dialogs.IInputValidator;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-
-/**
- * This class will provide UI alert dialogs to the user. These will
- * automatically get the message from the plugin's resource bundle.
- *
- * NOTE: there are some generic exception methods included in this file. They
- * need resource bundles also, and they make the alerts bettern when the
- * exception is caught at a later stage.
- *
- * @author mengbo
- */
-public class Alerts {
- // this is used for junit testing to turn off all alerts and return the
- // default on yes/no dialogs.
- private static boolean _noAlerts = false;
-
- private ResourceBundle _rb;
-
- private String _pluginId;
-
- /**
- * Construct a alerts with the provided attributes. This constructor should
- * be used from the root plugin that has access to the resource bundle for
- * this plugin.
- *
- * @param plugin
- * @param rb
- * the resource bundle to use.
- */
- public Alerts(AbstractUIPlugin plugin, ResourceBundle rb) {
- _rb = rb;
- if (_rb == null) {
- throw new NullPointerException(
- "No resource bundle was provided to the Alerts."); //$NON-NLS-1$
- }
- if (plugin == null) {
- throw new NullPointerException(
- "No plugin was provided to the Alerts."); //$NON-NLS-1$
- }
- _pluginId = plugin.getBundle().getSymbolicName();
- }
-
- /**
- * Returns the text entered by a user in a simple request dialog.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param initialValue -
- * initial value in the text area.
- * @param validator -
- * something that checks for validity on the name.
- * @return null is returned if the user hits cancel, otherwise it is the
- * text they entered.
- */
- public String getInput(String titleKey, String msgKey, String initialValue,
- IInputValidator validator) {
- if (_noAlerts) {
- return null;
- }
-
- InputDialog inDialog = new InputDialog(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey),
- initialValue, validator);
- inDialog.open();
- return inDialog.getValue();
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- */
- public void error(String titleKey, String msgKey) {
- if (_noAlerts) {
- return;
- }
-
- MessageDialog.openError(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey));
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- */
- public void error(String titleKey, String msgKey, Object arg0) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openError(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- */
- public void error(String titleKey, String msgKey, Object arg0, Object arg1) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[2];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openError(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- * @param arg2 -
- * arg to place into the resource bundle message.
- */
- public void error(String titleKey, String msgKey, Object arg0, Object arg1,
- Object arg2) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[3];
- args[0] = arg0;
- args[1] = arg1;
- args[2] = arg2;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openError(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- * @param arg2 -
- * arg to place into the resource bundle message.
- * @param arg3 -
- * arg to place into the resource bundle message.
- */
- public void error(String titleKey, String msgKey, Object arg0, Object arg1,
- Object arg2, Object arg3) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[4];
- args[0] = arg0;
- args[1] = arg1;
- args[2] = arg2;
- args[3] = arg3;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openError(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an Error message to the user.
- *
- * @param shell -
- * the shell for the error dialog
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- */
- public void error(Shell shell, String titleKey, String msgKey) {
- if (_noAlerts) {
- return;
- }
-
- MessageDialog.openError(shell, getResourceString(titleKey),
- getResourceString(msgKey));
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- */
- public void detailError(String titleKey, String msgKey) {
- if (_noAlerts) {
- return;
- }
-
- final IStatus fstatus = new Status(IStatus.ERROR, _pluginId,
- IStatus.OK, getResourceString(msgKey), null);
- final String ftitle = getResourceString(titleKey);
-
- Display display = getStandardDisplay();
- display.asyncExec(new Runnable() {
- public void run() {
- ErrorDialog.openError(null, ftitle, null, fstatus);
- }
- });
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread. This will give the details button.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param tt -
- * exception to place in the details.
- */
- public void detailError(String titleKey, String msgKey, Throwable tt) {
- if (_noAlerts) {
- return;
- }
-
- internalDetailError(getResourceString(titleKey),
- getResourceString(msgKey), tt);
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread. This will give the details button.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param tt -
- * exception to place in the details.
- */
- public void detailError(String titleKey, String msgKey, Object arg0,
- Throwable tt) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- internalDetailError(getResourceString(titleKey),
- formatter.format(args), tt);
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread. This will give the details button.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- * @param tt -
- * exception to place in the details.
- */
- public void detailError(String titleKey, String msgKey, Object arg0,
- Object arg1, Throwable tt) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- internalDetailError(getResourceString(titleKey),
- formatter.format(args), tt);
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread. This will give the details button.
- *
- * @param title -
- * the title message
- * @param message -
- * message displayed to the user
- */
- private void internalDetailError(String title, String msg, Throwable tt) {
- if (_noAlerts) {
- return;
- }
-
- if (tt instanceof InvocationTargetException) {
- tt = ((InvocationTargetException) tt).getTargetException();
- }
-
- IStatus status = null;
- if (tt instanceof CoreException) {
- status = ((CoreException) tt).getStatus();
-
- if ((status instanceof MultiStatus) == false) {
- // convert to a multistatus to show the exception details.
-
- Throwable th = status.getException();
- if (th == null) {
- th = tt;
- }
-
- status = buildStackTraceStatus(IStatus.ERROR, status
- .getPlugin(), status.getMessage(), th);
- }
- } else {
- status = buildStackTraceStatus(IStatus.ERROR, _pluginId, tt
- .getMessage(), tt);
- }
-
- final String ftitle = title;
- final IStatus fstatus = status;
- final String fmsg = msg;
- Display display = getStandardDisplay();
- display.asyncExec(new Runnable() {
- public void run() {
- ErrorDialog.openError(null, ftitle, fmsg, fstatus);
- }
- });
- }
-
- /**
- * Builds a multistatus, so that the stack trace shows up in the alery
- * message for detailed alerts.
- *
- * @param code
- * @param pluginId
- * @param message
- * @param tt
- * @return the result of the operation
- */
- public IStatus buildStackTraceStatus(int code, String pluginId,
- String message, Throwable tt) {
- if (tt == null) {
- return new Status(code, pluginId, IStatus.OK, message, tt);
- }
-
- MultiStatus mstat = new MultiStatus(pluginId, code, message, tt);
-
- StackTraceElement[] trace = tt.getStackTrace();
-
- mstat.add(new Status(code, pluginId, IStatus.OK, tt.toString(), null));
- for (int ii = 0; ii < trace.length; ii++) {
- mstat.add(new Status(code, pluginId, IStatus.OK, trace[ii]
- .toString(), null));
- }
- return mstat;
- }
-
- /**
- * Displays an Error message to the user with a status using the Display
- * background thread. This will give the details button.
- *
- * @param status -
- * the status
- * @param title -
- * the title of the message
- */
- public void detailError(String title, IStatus status) {
- if (_noAlerts) {
- return;
- }
-
- final IStatus fstatus = status;
- final String ftitle = title;
- Display display = getStandardDisplay();
- display.asyncExec(new Runnable() {
- public void run() {
- ErrorDialog.openError(null, ftitle, null, fstatus);
- }
- });
- }
-
- /**
- * Displays an information message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- */
- public void info(String titleKey, String msgKey) {
- if (_noAlerts) {
- return;
- }
-
- MessageDialog.openInformation(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey));
- }
-
- /**
- * Displays an information message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- */
- public void info(String titleKey, String msgKey, Object arg0) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openInformation(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an confirmation message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @return true if the user presses the OK button, false otherwise
- */
- public boolean confirm(String titleKey, String msgKey) {
- if (_noAlerts) {
- return true;
- }
-
- return MessageDialog.openConfirm(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey));
- }
-
- /**
- * Displays an confirmation message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @return true if the user presses the OK button, false otherwise
- */
- public boolean confirm(String titleKey, String msgKey, Object arg0) {
- if (_noAlerts) {
- return true;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- return MessageDialog.openConfirm(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an question message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @return true if the user presses the "yes" button, false otherwise
- */
- public boolean question(String titleKey, String msgKey) {
- if (_noAlerts) {
- return true;
- }
-
- return MessageDialog.openQuestion(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey));
- }
-
- /**
- * Displays an question message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @return true if the user presses the "yes" button, false otherwise
- */
- public boolean question(String titleKey, String msgKey, Object arg0) {
- if (_noAlerts) {
- return true;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- return MessageDialog.openQuestion(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Displays an warning message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- */
- public void warning(String titleKey, String msgKey) {
- if (_noAlerts) {
- return;
- }
-
- MessageDialog.openWarning(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), getResourceString(msgKey));
- }
-
- /**
- * Displays an warning message to the user.
- *
- * @param titleKey -
- * the title resource bundle key for the message
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- */
- public void warning(String titleKey, String msgKey, Object arg0) {
- if (_noAlerts) {
- return;
- }
-
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- MessageDialog.openWarning(PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell(),
- getResourceString(titleKey), formatter.format(args));
- }
-
- /**
- * Returns the standard display to be used. The method first checks, if the
- * thread calling this method has an associated dispaly. If so, this display
- * is returned. Otherwise the method returns the default display.
- *
- * TODO: should probably use the workbench display
- */
- private Display getStandardDisplay() {
- Display display = Display.getCurrent();
- if (display == null) {
- display = Display.getDefault();
- }
- return display;
- }
-
- /**
- * Returns the string from the resource bundle, or 'key' if not found.
- */
- private String getResourceString(String key) {
- if (key == null) {
- return null;
- }
-
- try {
- return _rb.getString(key);
- } catch (MissingResourceException ee) {
- return key;
- }
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @throws CoreException
- */
- public void throwCoreException(String msgKey) throws CoreException {
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- getResourceString(msgKey), null);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param ee -
- * the real exception.
- * @throws CoreException
- */
- public void throwCoreException(Throwable ee) throws CoreException {
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK, ee
- .getMessage(), ee);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param ee -
- * the real exception.
- * @throws CoreException
- */
- public void throwCoreException(String msgKey, Throwable ee)
- throws CoreException {
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- getResourceString(msgKey), ee);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @throws CoreException
- */
- public void throwCoreException(String msgKey, Object arg0)
- throws CoreException {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- formatter.format(args), null);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param ee -
- * the real exception.
- * @throws CoreException
- */
- public void throwCoreException(String msgKey, Object arg0, Throwable ee)
- throws CoreException {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- formatter.format(args), ee);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- * @throws CoreException
- */
- public void throwCoreException(String msgKey, Object arg0, Object arg1)
- throws CoreException {
- Object[] args = new Object[2];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- formatter.format(args), null);
- throw new CoreException(status);
- }
-
- /**
- * Throw a core exception built around the message with the correct plugin
- * id and resource bundle string.
- *
- * @param msgKey -
- * message resource bundle key for the message displayed to the
- * user
- * @param arg0 -
- * arg to place into the resource bundle message.
- * @param arg1 -
- * arg to place into the resource bundle message.
- * @param ee -
- * the real exception.
- * @throws CoreException
- */
- public void throwCoreException(String msgKey, Object arg0, Object arg1,
- Throwable ee) throws CoreException {
- Object[] args = new Object[2];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getResourceString(msgKey));
-
- IStatus status = new Status(IStatus.ERROR, _pluginId, IStatus.OK,
- formatter.format(args), ee);
- throw new CoreException(status);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/BrowserWindow.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/BrowserWindow.java
deleted file mode 100644
index 33ce9faf4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/BrowserWindow.java
+++ /dev/null
@@ -1,391 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.jface.window.ApplicationWindow;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.browser.Browser;
-import org.eclipse.swt.browser.LocationAdapter;
-import org.eclipse.swt.browser.LocationEvent;
-import org.eclipse.swt.browser.OpenWindowListener;
-import org.eclipse.swt.browser.StatusTextEvent;
-import org.eclipse.swt.browser.StatusTextListener;
-import org.eclipse.swt.browser.WindowEvent;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.ToolBar;
-import org.eclipse.swt.widgets.ToolItem;
-
-/**
- * Brings up a browser into a separate window.
- *
- * @author mengbo.
- *
- * Unused???
- */
-public class BrowserWindow extends ApplicationWindow {
-
- private static final String RELOAD_ITEM_IMAGE_FILE = "reload_nav_16.gif"; //$NON-NLS-1$
-
- private static final String REFRESH_ITEM_IMAGE_FILE = "refresh_nav_16.gif"; //$NON-NLS-1$
-
- private static final String STOP_ITEM_IMAGE_FILE = "stop_nav_16.gif"; //$NON-NLS-1$
-
- private static final String FORWARD_ITEM_IMAGE_FILE = "forward_nav_16.gif"; //$NON-NLS-1$
-
- private static final String BACK_ITEM_IMAGE_FILE = "back_nav_16.gif"; //$NON-NLS-1$
-
-
- /**
- * Command to send to the browser.
- */
- private static final int BROWSER_CMD_BACK = 1;
-
- private static final int BROWSER_CMD_FORWARD = 2;
-
- private static final int BROWSER_CMD_STOP = 3;
-
- private static final int BROWSER_CMD_REFRESH = 4;
-
- private static final int BROWSER_CMD_RELOAD = 5;
-
- private boolean _bIncludeToolbar;
-
- private boolean _bPopups;
-
- private String _title;
-
- private ScrolledComposite _scomp;
-
- private Composite _browserComposite;
-
- private Browser _browser;
-
- private String _startLocation;
-
- private String _startContent;
-
- // these items are browser context sensitive.
- private ToolItem _backItem;
-
- private ToolItem _forwardItem;
-
- /**
- * @param parentShell
- * owner of this window.
- */
- public BrowserWindow(Shell parentShell) {
- this(parentShell, false, null, false);
- }
-
- /**
- * @param parentShell
- * owner of this window.
- * @param bPopups
- * allow popup windows?
- * @param title
- * Tittle on window.
- */
- public BrowserWindow(Shell parentShell, boolean bPopups, String title) {
- this(parentShell, bPopups, title, false);
- }
-
- /**
- * @param parentShell
- * owner of this window.
- * @param bPopups
- * allow popup windows?
- * @param title
- * Tittle on window.
- * @param bModal
- * pretend to a be a dialog?
- */
- public BrowserWindow(Shell parentShell, boolean bPopups, String title,
- boolean bModal) {
- super(parentShell);
- addStatusLine();
- _bPopups = bPopups;
- _title = title;
- includeToolbar(true);
-
- if (bModal && (parentShell != null)) {
- // APPLICATION_MODAL, MODELESS, PRIMARY_MODAL, SYSTEM_MODAL
- setShellStyle(getShellStyle() | SWT.APPLICATION_MODAL);
- setBlockOnOpen(true);
- }
- }
-
- /**
- * Default is true, set whether to include the toolbar at the top. This must
- * be called before the window is opened.
- *
- * @param bIncludeToolbar
- */
- public void includeToolbar(boolean bIncludeToolbar) {
- _bIncludeToolbar = bIncludeToolbar;
- }
-
- /**
- * @param title
- */
- public void setTitle(String title) {
- if ((title != null) && (super.getShell() != null)) {
- super.getShell().setText(title);
- }
- }
-
- /**
- * @param startLocation
- */
- /**
- * @param startLocation
- */
- public void setStartLocation(String startLocation) {
- _startLocation = startLocation;
- }
-
- /**
- * @param startContent
- */
- public void setStartContent(String startContent) {
- _startContent = startContent;
- }
-
- /**
- * @return the browser object
- */
- public Browser getBrowser() {
- return _browser;
- }
-
- protected Control createContents(Composite parent) {
- // Create the scroll composite as the one inside the parent.
- _scomp = new ScrolledComposite(parent, SWT.V_SCROLL | SWT.H_SCROLL);
-
- // Create the composite that goes inside the scroller. We will use this
- // for
- // everything else from here.
- Composite innerComposite = SWTUtils.createComposite(_scomp, 1, 10, -1);
- _scomp.setContent(innerComposite);
- ControlListener listener = new ControlAdapter() {
- // this will handle resizing the browser when the window is resized.
- public void controlResized(ControlEvent e) {
- Point pt = _scomp.getParent().getSize();
- Rectangle rect = _browserComposite.getBounds();
-
- pt.x -= rect.x;
- pt.y -= rect.y;
-
- // spacing offsets in the composites.
- pt.x -= 10;
- pt.y -= 60; // need status bar at bottom...30 more than normal.
-
- // do the sanity check here since it prevents further checks.
- if ((pt.x <= 0) || (pt.y <= 0)) {
- return;
- }
-
- Rectangle innerRect = _scomp.getContent().getBounds();
- Rectangle outerRect = _scomp.getBounds();
-
- // substract if the scroll bars are visible.
- if (innerRect.width > outerRect.width) {
- pt.y -= _scomp.getHorizontalBar().getSize().y;
- }
- if (innerRect.height > outerRect.height) {
- pt.x -= _scomp.getVerticalBar().getSize().x;
- }
-
- _browserComposite.setSize(pt);
- _browserComposite.getParent().layout(true);
- }
- };
- _scomp.addControlListener(listener);
-
- if (_bIncludeToolbar) {
- // ////////////////////////////////////////
- // toobar
- // ////////////////////////////////////////
- ToolBar tb = new ToolBar(innerComposite, SWT.HORIZONTAL | SWT.FLAT);
- fillToolbar(tb);
- }
-
- // ////////////////////////////////////////
- // browser
- // ////////////////////////////////////////
- _browserComposite = new Composite(innerComposite, SWT.NULL);
- _browserComposite.setLayout(new FillLayout());
-
- _browser = new Browser(_browserComposite, SWT.NULL);
-
- if (_startLocation != null) {
- _browser.setUrl(_startLocation);
- } else if (_startContent != null) {
- _browser.setText(_startContent);
- } else {
- _browser.setText(Messages.BrowserWindow_loading);
- }
-
- // send the browser status messages to eclipse.
- _browser.addStatusTextListener(new StatusTextListener() {
- public void changed(StatusTextEvent event) {
- setStatus(event.text);
- }
- });
-
- if (_bIncludeToolbar) {
- // check for change in location so we can enable the back/forward
- // buttons.
- _browser.addLocationListener(new LocationAdapter() {
- public void changed(LocationEvent event) {
- // check if there is something in the forward or back queue.
- _backItem.setEnabled(_browser.isBackEnabled());
- _forwardItem.setEnabled(_browser.isForwardEnabled());
- }
- });
- }
-
- // check is we need to open a new window.
- _browser.addOpenWindowListener(new OpenWindowListener() {
- public void open(WindowEvent event) {
- if (_bPopups) {
- BrowserWindow window = new BrowserWindow(getShell());
- window.open();
- event.browser = window.getBrowser();
- } else {
- event.browser = getBrowser();
- }
- }
- });
-
- setTitle(_title);
- SWTUtils.computeScrollArea(_scomp, innerComposite);
- return _scomp;
- }
-
- /**
- * Fill the toolbar for this window. This method can be overwritten to place
- * other toolbar controls in the bar.
- *
- * @param tb
- */
- protected void fillToolbar(ToolBar tb) {
- // Back browser
- _backItem = new ToolItem(tb, SWT.PUSH);
- _backItem.setImage(JSFUICommonPlugin.getDefault()
- .getImage(BACK_ITEM_IMAGE_FILE));
- _backItem.setToolTipText(JSFUICommonPlugin
- .getResourceString("BrowserWindow.back.tooltip")); //$NON-NLS-1$
- SelectionListener backSelectionListener = new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- browserCmd(BROWSER_CMD_BACK);
- }
- };
- _backItem.addSelectionListener(backSelectionListener);
-
- // Forward Browser
- _forwardItem = new ToolItem(tb, SWT.PUSH);
- _forwardItem.setImage(JSFUICommonPlugin.getDefault().getImage(
- FORWARD_ITEM_IMAGE_FILE));
- _forwardItem.setToolTipText(JSFUICommonPlugin
- .getResourceString("BrowserWindow.forward.tooltip")); //$NON-NLS-1$
- SelectionListener forwardSelectionListener = new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- browserCmd(BROWSER_CMD_FORWARD);
- }
- };
- _forwardItem.addSelectionListener(forwardSelectionListener);
-
- // Stop Browser
- ToolItem stopItem = new ToolItem(tb, SWT.PUSH);
- stopItem
- .setImage(JSFUICommonPlugin.getDefault().getImage(STOP_ITEM_IMAGE_FILE));
- stopItem.setToolTipText(JSFUICommonPlugin
- .getResourceString("BrowserWindow.stop.tooltip")); //$NON-NLS-1$
- SelectionListener stopSelectionListener = new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- browserCmd(BROWSER_CMD_STOP);
- }
- };
- stopItem.addSelectionListener(stopSelectionListener);
-
- // Refresh Browser
- ToolItem refreshItem = new ToolItem(tb, SWT.PUSH);
- refreshItem.setImage(JSFUICommonPlugin.getDefault().getImage(
- REFRESH_ITEM_IMAGE_FILE));
- refreshItem.setToolTipText(JSFUICommonPlugin
- .getResourceString("BrowserWindow.refresh.tooltip")); //$NON-NLS-1$
- SelectionListener refreshServiceSelectionListener = new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- browserCmd(BROWSER_CMD_REFRESH);
- }
- };
- refreshItem.addSelectionListener(refreshServiceSelectionListener);
-
- if ((_startLocation != null) || (_startContent != null)) {
- // Reload Browser.
- ToolItem reloadItem = new ToolItem(tb, SWT.PUSH);
- reloadItem.setImage(JSFUICommonPlugin.getDefault().getImage(
- RELOAD_ITEM_IMAGE_FILE));
- reloadItem.setToolTipText(JSFUICommonPlugin
- .getResourceString("BrowserWindow.reload.tooltip")); //$NON-NLS-1$
- SelectionListener reloadSelectionListener = new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- browserCmd(BROWSER_CMD_RELOAD);
- }
- };
- reloadItem.addSelectionListener(reloadSelectionListener);
- }
- }
-
- /**
- * send the browser widget a command as defined by the cmd constant defines.
- * @param cmd
- *
- * @return true if the command was successful.
- */
- public boolean browserCmd(int cmd) {
- switch (cmd) {
- case BROWSER_CMD_BACK:
- return _browser.back();
- case BROWSER_CMD_FORWARD:
- return _browser.forward();
- case BROWSER_CMD_STOP:
- _browser.stop();
- return true;
- case BROWSER_CMD_REFRESH:
- _browser.refresh();
- return true;
- case BROWSER_CMD_RELOAD:
- if (_startLocation != null) {
- _browser.setUrl(_startLocation);
- } else if (_startContent != null) {
- _browser.setText(_startContent);
- }
- return true;
-
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/CollapsableSection.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/CollapsableSection.java
deleted file mode 100644
index f787c2240..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/CollapsableSection.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.forms.events.ExpansionAdapter;
-import org.eclipse.ui.forms.events.ExpansionEvent;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Section;
-
-/**
- * Creates a class to be used to build a control for a collapseable area inside
- * a scrollable composite. This will take care of scrollbar resize.
- *
- * Example use:
- *
- * CollapsableSection cs = new CollapsableSection(toolkit, scomp, "General",
- * true) { public void setCollapsableContent(Composite composite) { // place
- * your content on this composite.... } }); cs.createControl(composite,
- * horizontalSpan);
- *
- * @author mengbo
- *
- */
-public abstract class CollapsableSection {
- // internal fields needed for doing the section and computing the scrollbar
- // on a collapse.
- private FormToolkit _toolkit;
-
- private Section _section;
-
- private ScrolledComposite _scomp;
-
- private String _title;
-
- private int _expansionStyle;
-
- /**
- * Creates a class to be used to build the control for a collapseable area.
- *
- * @param toolkit
- *
- * @param scomp
- * the scrollable composite used inside the container. This is
- * used to force resizing of the bars on dinking the control.
- * @param title
- * the string to place next to the collapsable icon.
- * @param bCollapsed
- * should this area start collapsed?
- */
- public CollapsableSection(FormToolkit toolkit, ScrolledComposite scomp,
- String title, boolean bCollapsed) {
- _toolkit = toolkit;
- _scomp = scomp;
- _title = title;
- _expansionStyle = ExpandableComposite.TWISTIE
- | ExpandableComposite.FOCUS_TITLE;
- if (bCollapsed) {
- _expansionStyle |= ExpandableComposite.COMPACT;
- } else {
- _expansionStyle |= ExpandableComposite.EXPANDED;
- }
- }
-
- /**
- * Build the GUI parts of the Collapsable area into the given composite.
- * NOTE: you must set the layout on this composite before adding swt
- * widgets.
- *
- * @param composite
- */
- abstract public void setCollapsableContent(Composite composite);
-
- /**
- * A convient way to build the widget into a control and place it on the
- * page. NOTE: this method will build the Section and call
- * setCollapsableContent with a composite to fill in the inner area.
- *
- * @param parent
- * @param horizontalSpan
- * how many columns should this control span.
- * @return Control that was added to the composite.
- */
- public Control createControl(Composite parent, int horizontalSpan) {
- _section = _toolkit.createSection(parent, _expansionStyle);
- _section.clientVerticalSpacing = 5; // space between the dink and the
- // controls in when opened.
- // _section.marginHeight = 5; // indents the entire section.
- // _section.marginWidth = 5; // indents the entire section.
- _section.setText(_title);
- _toolkit.createCompositeSeparator(_section);
- _section.addExpansionListener(new ExpansionAdapter() {
- public void expansionStateChanged(ExpansionEvent event) {
- SWTUtils.computeScrollArea(_scomp, (Composite) _scomp
- .getContent());
- }
- });
-
- Composite content = new Composite(_section, SWT.NULL);
- setCollapsableContent(content);
-
- _section.setClient(content);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = horizontalSpan;
- _section.setLayoutData(gd);
-
- return _section;
- }
-
- /**
- * Programmatically changes expanded state.
- *
- * @param expanded
- * the new expanded state
- */
- public void setExpanded(boolean expanded) {
- if (_section != null) {
- _section.setExpanded(expanded);
-
- // NOTE: internal calling of expanding doesn't fire
- // the event to resize. We do it here.
- SWTUtils.computeScrollArea(_scomp, (Composite) _scomp.getContent());
- }
- }
-
- /**
- * Return the internal Section control for more advanced things.
- *
- * @return Section
- */
- public Section getSection() {
- return _section;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/FavoriteSection.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/FavoriteSection.java
deleted file mode 100644
index be9882cb7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/FavoriteSection.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import java.util.Properties;
-
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.utils.FavoriteConfigurations;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-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.ui.plugin.AbstractUIPlugin;
-
-/**
- * Builds a favorites with the given name in the plugins resources. This build a
- * generic looking favorites section.
- *
- * @author mengbo
- */
-public abstract class FavoriteSection {
- private FavoriteConfigurations _favorites;
-
- private Combo _favoriteCombo;
-
- /**
- * @param plugin
- * @param favoriteName
- */
- public FavoriteSection(AbstractUIPlugin plugin, String favoriteName) {
- _favorites = new FavoriteConfigurations(plugin, favoriteName);
- }
-
- /**
- * @param parent
- * @param horizontalSpan
- * @param comboMinWidth
- * @return the combo
- */
- public Combo createFavoriteGroup(Composite parent, int horizontalSpan,
- int comboMinWidth) {
- Group favGroup = SWTUtils.createGroup(parent, JSFUICommonPlugin
- .getResourceString("favorites.group.label"), 4, horizontalSpan, //$NON-NLS-1$
- GridData.BEGINNING | GridData.CENTER);
-
- // Add favorite text field
- SWTUtils.createLabel(favGroup, JSFUICommonPlugin
- .getResourceString("favorites.label"), 1); //$NON-NLS-1$
- _favoriteCombo = SWTUtils.createCombo(favGroup, _favorites
- .getFavoritesList(), 1, comboMinWidth, true);
- _favoriteCombo.setToolTipText(JSFUICommonPlugin
- .getResourceString("favorites.tooltip")); //$NON-NLS-1$
- _favoriteCombo.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- String favName = _favoriteCombo.getText().trim();
- if (favName.length() > 0) {
- Properties favProp = _favorites.getFavorite(_favoriteCombo
- .getText().trim());
- if (favProp != null) {
- setFavorites(favProp);
- }
- }
- }
- });
-
- // Add Save button
- Button saveButton = SWTUtils.createPushButton(favGroup, JSFUICommonPlugin
- .getResourceString("button.save")); //$NON-NLS-1$
- saveButton.setToolTipText(JSFUICommonPlugin
- .getResourceString("favorites.save.tooltip")); //$NON-NLS-1$
- saveButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- String favName = _favoriteCombo.getText().trim();
- if (favName.length() == 0) {
- favName = JSFUICommonPlugin
- .getResourceString("favorites.default"); //$NON-NLS-1$
- }
- Properties favProp = new Properties();
- saveFavorites(favProp);
-
- _favorites.addFavorite(favName, favProp);
- _favorites.saveFavorites();
-
- _favoriteCombo.removeAll();
- String[] names = _favorites.getFavoritesList();
-
- _favoriteCombo.setItems(names);
- _favoriteCombo.setText(favName);
- }
- });
-
- // Add Remove button
- Button removeButton = SWTUtils.createPushButton(favGroup, JSFUICommonPlugin
- .getResourceString("button.remove")); //$NON-NLS-1$
- removeButton.setToolTipText(JSFUICommonPlugin
- .getResourceString("favorites.remove.tooltip")); //$NON-NLS-1$
- removeButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent event) {
- String favName = _favoriteCombo.getText().trim();
- if (favName.length() > 0) {
- _favorites.removeFavorite(favName);
- _favorites.saveFavorites();
-
- removeFavorites();
-
- _favoriteCombo.removeAll();
- String[] names = _favorites.getFavoritesList();
- _favoriteCombo.setItems(names);
- }
- }
- });
-
- return _favoriteCombo;
- }
-
- /**
- * This method will be called when a new favorite is set. This allows the
- * caller to set their values from the properties supplied.
- *
- * @param prop
- */
- public abstract void setFavorites(Properties prop);
-
- /**
- * This method will be called when a new favorite is saved. This allows the
- * caller to save their values into the properties supplied.
- *
- * @param prop
- */
- public abstract void saveFavorites(Properties prop);
-
- /**
- * This method will be called when the active favorite is removed. It allows
- * for clearing fields.
- */
- public void removeFavorites() {
- // do nothing.
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/ImageContainer.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/ImageContainer.java
deleted file mode 100644
index 8f697d164..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/ImageContainer.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ControlAdapter;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.DisposeEvent;
-import org.eclipse.swt.events.DisposeListener;
-import org.eclipse.swt.events.PaintEvent;
-import org.eclipse.swt.events.PaintListener;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * A general purpose class for displying an image in a composite. There is no
- * eclipse tool for doing this other than CLabl which is bulkly.
- *
- * This was original written by Karl Reti.
- *
- * @author mengbo
- */
-public class ImageContainer extends Composite {
- private Image _image = null;
-
- private boolean _bCleanupImage;
-
- /**
- * @param parent
- */
- public ImageContainer(Composite parent) {
- super(parent, SWT.NONE);// SWT.NO_BACKGROUND );//|
- // SWT.NO_REDRAW_RESIZE);
- setBackground(ColorConstants.white);
- // paint the image
- addPaintListener(new PaintListener() {
- public void paintControl(PaintEvent e) {
- if (_image != null) {
- e.gc.drawImage(_image, 0, 0);
- }
- }
-
- });
-
- addControlListener(new ControlAdapter() {
- public void controlResized(ControlEvent e) {
- setSize(_image.getBounds().width, _image.getBounds().height);
- }
- });
-
- // tidy up
- addDisposeListener(new DisposeListener() {
- public void widgetDisposed(DisposeEvent e) {
- if (_bCleanupImage && _image != null && !_image.isDisposed()) {
- _image.dispose();
- }
- }
- });
- }
-
- /**
- * @return Returns the image.
- */
- public Image getImage() {
- return _image;
- }
-
- /**
- * @return should the image be disposed of on cleanup. Set false if the
- * image is cached.
- */
- public boolean isCleanupImage() {
- return _bCleanupImage;
- }
-
- /**
- * @param image
- * The image to set.
- */
- public void setImage(Image image) {
- setImage(image, false);
- }
-
- /**
- * @param image
- * The image to set.
- * @param bCleanupImage
- */
- public void setImage(Image image, boolean bCleanupImage) {
- _image = image;
- _bCleanupImage = bCleanupImage;
- setSize(image.getBounds().width, image.getBounds().height);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/IntroductionSection.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/IntroductionSection.java
deleted file mode 100644
index a022c1b63..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/IntroductionSection.java
+++ /dev/null
@@ -1,351 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.help.HelpSystem;
-import org.eclipse.help.IContext;
-import org.eclipse.help.IHelpResource;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.SectionPart;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Hyperlink;
-import org.eclipse.ui.forms.widgets.ImageHyperlink;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-
-/**
- * Provides a standard looking introduction section for a intro page for the
- * editors. This was taken and is suppose to look like the standard Sybase
- * workspace service editors intro page.
- *
- * this was original written by Collinsc
- *
- * TODO: Should this be moved into the facesconfig ui plugin since it is only
- * really used there?
- *
- * @author collinsc,jchoi
- */
-public class IntroductionSection extends SectionPart {
-
- private static final String HELP_IMAGE_FILE = "help.gif"; //$NON-NLS-1$
-
- private static Logger _log = JSFUICommonPlugin
- .getLogger(IntroductionSection.class);
-
- private String _editorId;
-
- private FormToolkit _toolkit;
-
- // private ImageHyperlink _helpImage;
- private Composite _textClient;
-
- private String _helpContextId;
-
- private String _helpTooltip;
-
- /**
- * Basic constructor - no help with this one.
- *
- * @param editorId
- * id of the editor this page is for.
- * @param managedForm
- * @param toolkit
- */
- public IntroductionSection(String editorId, IManagedForm managedForm,
- FormToolkit toolkit) {
- this(editorId, managedForm, toolkit, null, null);
- }
-
- /**
- * Constructor with help option.
- *
- * @param editorId
- * id of the editor this page is for.
- * @param managedForm
- * @param toolkit
- * @param contextId
- * @param helpTooltip
- */
- public IntroductionSection(String editorId, IManagedForm managedForm,
- FormToolkit toolkit, final String contextId, String helpTooltip) {
- super(managedForm.getForm().getBody(), toolkit,
- ExpandableComposite.TITLE_BAR | Section.DESCRIPTION);
- super.initialize(managedForm);
- this._editorId = editorId;
- this._toolkit = toolkit;
- this._helpContextId = contextId;
- this._helpTooltip = helpTooltip;
-
- this._textClient = this._toolkit.createComposite(getSection(), SWT.NONE);
- this._textClient.setSize(32, 16);
-
- RowLayout rowLayout = new RowLayout();
- rowLayout.wrap = false;
- rowLayout.pack = false;
- rowLayout.justify = true;
- rowLayout.type = SWT.HORIZONTAL;
- rowLayout.marginLeft = 0;
- rowLayout.marginTop = 0;
- rowLayout.marginRight = 0;
- rowLayout.marginBottom = 0;
- rowLayout.spacing = 0;
- this._textClient.setLayout(rowLayout);
-
- this._toolkit.adapt(this._textClient, true, true);
- getSection().setTextClient(this._textClient);
-
- if (this._helpContextId != null) {
- // setup the help image.
- ImageHyperlink helpImage = new ImageHyperlink(this._textClient,
- SWT.NONE);
- this._toolkit.adapt(helpImage, true, true);
- helpImage.setImage(JSFUICommonPlugin.getDefault().getImage(HELP_IMAGE_FILE));
- if (this._helpTooltip != null) {
- helpImage.setToolTipText(this._helpTooltip);
- }
- helpImage.setBackground(getSection()
- .getTitleBarGradientBackground());
- helpImage.addHyperlinkListener(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- IContext context = HelpSystem.getContext(_helpContextId);
- if (context != null) {
- IHelpResource[] topics = context.getRelatedTopics();
- if (topics != null && topics.length == 1) {
- PlatformUI.getWorkbench().getHelpSystem().displayHelpResource(topics[0]
- .getHref());
- } else {
- PlatformUI.getWorkbench().getHelpSystem().displayHelp(_helpContextId);
- }
- }
- }
- });
- }
-
- Composite client = this._toolkit.createComposite(getSection());
- createClient(client, this._toolkit);
- getSection().setClient(client);
- }
-
- private Composite createClient(Composite container, FormToolkit factory) {
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 2;
- layout.makeColumnsEqualWidth = false;
- layout.horizontalSpacing = 20;
- layout.verticalSpacing = 20;
- container.setLayout(layout);
-
- IConfigurationElement element = getExtensions();
-
- if (element != null) {
- setPageDetails(element);
-
- IConfigurationElement[] children = element.getChildren();
- for (int ii = 0; ii < children.length; ii++) {
- processItems(container, factory, children[ii]);
- }
- } else {
- setText(Messages.IntroductionSection_noIntroTitle);
-
- setDescription(Messages.IntroductionSection_noIntroDescription);
- }
-
- factory.paintBordersFor(container);
- PlatformUI.getWorkbench().getHelpSystem().setHelp(container, _helpContextId);
- return container;
- }
-
- /**
- * set the page details from the extensionpoint
- *
- * @param element
- */
- private void setPageDetails(IConfigurationElement element) {
- setText(element.getAttribute("name")); //$NON-NLS-1$
- setDescription(element.getAttribute("description")); //$NON-NLS-1$
- }
-
- /**
- * add the extension elements to the page
- *
- * @param parent
- * @param toolkit_
- * @param element
- */
- private void processItems(Composite parent, FormToolkit toolkit_,
- IConfigurationElement element) {
- String hyperlink = element.getAttribute("hyperlink"); //$NON-NLS-1$
- String iconPath = element.getAttribute("icon"); //$NON-NLS-1$
- String text = element.getAttribute("text"); //$NON-NLS-1$
- String heading = element.getAttribute("heading"); //$NON-NLS-1$
- String action = element.getAttribute("hyperlinkaction"); //$NON-NLS-1$
- //String actionparameters = element.getAttribute("actionparameters"); //$NON-NLS-1$
-
- if (iconPath != null && iconPath.length() > 0) {
- // add an icon to the page
- String iconName;
- if (iconPath.indexOf(IPath.SEPARATOR) != -1) {
- iconName = new Path(iconPath).lastSegment();
- } else {
- iconName = iconPath;
- }
-
- ImageDescriptor imageDescriptor = AbstractUIPlugin
- .imageDescriptorFromPlugin(
- element.getDeclaringExtension()
- .getContributor().getName(), iconPath);
-
- if (imageDescriptor != null)
- {
- ImageRegistry imageRegistry =
- JSFUICommonPlugin.getDefault().getImageRegistry();
-
-
- Image image = imageRegistry.get(iconName);
-
- if (image == null)
- {
- image = imageDescriptor.createImage();
-
- if (image != null)
- {
- imageRegistry.put(iconName, image);
- }
- else
- {
- image = ImageDescriptor.getMissingImageDescriptor().createImage();
- }
- }
-
- if (image != null)
- {
- ImageContainer img = new ImageContainer(parent);
- img.setImage(image);
- TableWrapData td = new TableWrapData();
- td.rowspan = 2;
- img.setLayoutData(td);
- }
- else
- {
- JSFUICommonPlugin.getLogger(this.getClass()).error(new Throwable("Image not created for "+element)); //$NON-NLS-1$
- }
- }
- else
- {
- JSFUICommonPlugin.getLogger(this.getClass()).error(new Throwable("Image Descriptor not found for "+element)); //$NON-NLS-1$
- }
- }
-
- if (heading != null && heading.length() > 0) {
- // add a header
- Label lbl = toolkit_.createLabel(parent, heading);
- lbl.setFont(JFaceResources.getHeaderFont());
- }
-
- if (hyperlink != null && hyperlink.length() > 0) {
- Hyperlink hypr = toolkit_.createHyperlink(parent, hyperlink,
- SWT.NONE);
- if (action != null && action.length() > 0) {
- try {
- final IAction thisAction = (IAction) element
- .createExecutableExtension("hyperlinkaction"); //$NON-NLS-1$
- hypr.addHyperlinkListener(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- thisAction.run();
- }
- });
- } catch (Exception ee) {
- // log.IntroductionSection.action.error=Failed to launch the
- // link {0}.
- _log.error("log.IntroductionSection.action.error", //$NON-NLS-1$
- hyperlink, ee);
- JSFUICommonPlugin.getAlerts().detailError(hyperlink,
- "log.IntroductionSection.action.error", hyperlink, //$NON-NLS-1$
- ee);
- }
- }
- }
-
- if (text != null && text.length() > 0) {
- FormText form = toolkit_.createFormText(parent, false);
- form.setText(text, false, false);
- }
- }
-
- /**
- * Get the extension elements for the Introduction pages
- */
- private IConfigurationElement getExtensions() {
- // find all service editor page extensions
- IConfigurationElement element = null;
-
- // find all service editor parameter dialog extensions
- IConfigurationElement[] elements = Platform
- .getExtensionRegistry()
- .getConfigurationElementsFor(
- "org.eclipse.jst.jsf.common.ui.introductionPage"); //$NON-NLS-1$
- if (elements.length > 0) {
- for (int ii = 0; ii < elements.length; ii++) {
- // get extensions for this dialog
- // String extPluginId =
- // elements[ii].getDeclaringExtension().getNamespace();
- String editorId1 = elements[ii].getDeclaringExtension()
- .getSimpleIdentifier();
-
- // see if we have any contributuins of dialogs
- if (this._editorId.equals(editorId1)) {
- element = elements[ii];
- break;
- }
- }
- }
- return element;
- }
-
- private void setText(String text) {
- getSection().setText(text);
- }
-
- private void setDescription(String text) {
- getSection().setDescription(text);
- }
-
- /**
- * Set this section's layout data
- * @param layoutData
- */
- public void setLayoutData(Object layoutData) {
- getSection().setLayoutData(layoutData);
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Messages.java
deleted file mode 100644
index b8772361b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/Messages.java
+++ /dev/null
@@ -1,35 +0,0 @@
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler.
- *
- * @author Debajit Adhikary - Oracle
- */
-
-public class Messages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.common.ui.internal.guiutils.messages"; //$NON-NLS-1$
-
- /**
- * See messages.properties.
- */
- public static String IntroductionSection_noIntroDescription;
-
- /**
- * See messages.properties.
- */
- public static String IntroductionSection_noIntroTitle;
-
- /**
- * See messages.properties.
- */
- public static String BrowserWindow_loading;
-
-
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/OverviewSection.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/OverviewSection.java
deleted file mode 100644
index 4654c40f3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/OverviewSection.java
+++ /dev/null
@@ -1,287 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.help.HelpSystem;
-import org.eclipse.help.IContext;
-import org.eclipse.help.IHelpResource;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.SectionPart;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormText;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.Hyperlink;
-import org.eclipse.ui.forms.widgets.ImageHyperlink;
-import org.eclipse.ui.forms.widgets.Section;
-
-
-/**
- * @author jchoi
- * @version
- */
-public class OverviewSection extends SectionPart {
-
- private static final String HELP_IMAGE_FILE = "help.gif"; //$NON-NLS-1$
-
- private static Logger log = JSFUICommonPlugin.getLogger(OverviewSection.class);
-
- private String editorId;
-
- private FormToolkit toolkit;
-
- private ImageHyperlink helpImage;
-
- private Composite textClient;
-
- private String helpContextId;
-
- private String helpTooltip;
-
- /**
- * @param editorId
- * @param managedForm
- * @param toolkit
- */
- public OverviewSection(String editorId, IManagedForm managedForm,
- FormToolkit toolkit) {
- this(editorId, managedForm, toolkit, null, null);
-
- }
-
- /**
- * Constructor with help option.
- *
- * @param editorId
- * id of the editor this page is for.
- * @param managedForm
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public OverviewSection(String editorId, IManagedForm managedForm,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(managedForm.getForm().getBody(), toolkit,
- ExpandableComposite.TITLE_BAR | Section.DESCRIPTION);
- super.initialize(managedForm);
- this.editorId = editorId;
- this.toolkit = toolkit;
- this.helpContextId = helpContextId;
- this.helpTooltip = helpTooltip;
-
- this.textClient = this.toolkit.createComposite(getSection(), SWT.NONE);
- this.textClient.setSize(32, 16);
-
- init();
-
- Composite client = this.toolkit.createComposite(getSection());
- //createClient(client, this.toolkit);
- getSection().setClient(client);
- }
-
- /**
- * @param editor
- * @param managedForm
- * @param toolkit
- * @param style
- */
- public OverviewSection(FormEditor editor, IManagedForm managedForm,
- FormToolkit toolkit, int style) {
- super(managedForm.getForm().getBody(), toolkit,
- ExpandableComposite.TITLE_BAR | style);
- super.initialize(managedForm);
- this.toolkit = toolkit;
-
- this.textClient = this.toolkit.createComposite(getSection(), SWT.NONE);
- this.textClient.setSize(32, 16);
-
- init();
- }
-
- /**
- * @param editor
- * @param managedForm
- * @param toolkit
- * @param style
- * @param helpContextId
- * @param helpTooltip
- */
- public OverviewSection(FormEditor editor, IManagedForm managedForm,
- FormToolkit toolkit, int style, String helpContextId,
- String helpTooltip) {
- super(managedForm.getForm().getBody(), toolkit,
- ExpandableComposite.TITLE_BAR | style);
- super.initialize(managedForm);
- this.toolkit = toolkit;
-
- this.textClient = toolkit.createComposite(getSection(), SWT.NONE);
- this.textClient.setSize(32, 16);
- this.helpContextId = helpContextId;
- this.helpTooltip = helpTooltip;
- init();
- }
-
- /**
- *
- */
- public void initialize() {
- Composite client = toolkit.createComposite(getSection());
- //createClient(client, toolkit);
- getSection().setClient(client);
- }
-
- private void init() {
- RowLayout rowLayout = new RowLayout();
- rowLayout.wrap = false;
- rowLayout.pack = false;
- rowLayout.justify = true;
- rowLayout.type = SWT.HORIZONTAL;
- rowLayout.marginLeft = 0;
- rowLayout.marginTop = 0;
- rowLayout.marginRight = 0;
- rowLayout.marginBottom = 0;
- rowLayout.spacing = 0;
- textClient.setLayout(rowLayout);
-
- helpImage = new ImageHyperlink(textClient, SWT.NONE);
- toolkit.adapt(helpImage, true, true);
- toolkit.adapt(textClient, true, true);
- helpImage.setImage(JSFUICommonPlugin.getDefault().getImage(HELP_IMAGE_FILE));
- getSection().setTextClient(textClient);
- if (helpTooltip != null) {
- helpImage.setToolTipText(helpTooltip);
- }
- helpImage.setBackground(getSection().getTitleBarGradientBackground());
- helpImage.addHyperlinkListener(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- IContext context = HelpSystem.getContext(helpContextId);
- if (context != null) {
- IHelpResource[] topics = context.getRelatedTopics();
- if (topics != null && topics.length == 1) {
- PlatformUI.getWorkbench().getHelpSystem().displayHelpResource(topics[0].getHref());
- } else {
- PlatformUI.getWorkbench().getHelpSystem().displayHelp(helpContextId);
- }
- }
- }
- });
-
- /*
- * Composite client = _toolkit.createComposite(getSection());
- * createClient(client, _toolkit); getSection().setClient(client);
- */
- }
-
- /**
- * set the page details from the extensionpoint
- *
- * @param element
- */
- protected void setPageDetails(IConfigurationElement element) {
- setText(element.getAttribute("name")); //$NON-NLS-1$
- setDescription(element.getAttribute("description")); //$NON-NLS-1$
- }
-
- /**
- * add the extension elements to the page
- *
- * @param parent
- * @param toolkit_
- * @param element
- */
- public void processItems(Composite parent, FormToolkit toolkit_,
- IConfigurationElement element) {
- String hyperlink = element.getAttribute("hyperlink"); //$NON-NLS-1$
- String text = element.getAttribute("text"); //$NON-NLS-1$
- String action = element.getAttribute("hyperlinkaction"); //$NON-NLS-1$
- //String actionparameters = element.getAttribute("actionparameters"); //$NON-NLS-1$
-
- if (hyperlink != null && hyperlink.length() > 0) {
- Hyperlink hypr = toolkit_.createHyperlink(parent, hyperlink,
- SWT.NONE);
- if (action != null && action.length() > 0) {
- try {
- final IAction thisAction = (IAction) element
- .createExecutableExtension("hyperlinkaction"); //$NON-NLS-1$
- hypr.addHyperlinkListener(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- thisAction.run();
- }
- });
- } catch (Exception ee) {
- // log.IntroductionSection.action.error=Failed to launch the
- // link {0}.
- log
- .error("log.OverviewSection.action.error", //$NON-NLS-1$
- hyperlink, ee);
- JSFUICommonPlugin.getAlerts().detailError(hyperlink,
- "log.OverviewSection.action.error", hyperlink, ee); //$NON-NLS-1$
- }
- }
- }
-
- if (text != null && text.length() > 0) {
- FormText form = toolkit_.createFormText(parent, false);
- form.setText(text, false, false);
- }
- }
-
- /**
- * Get the extension elements for the Introduction pages
- * @param extensionPoint
- * @return the configuration element
- */
- public IConfigurationElement getExtensions(String extensionPoint) {
- // find all service editor page extensions
- IConfigurationElement element = null;
-
- // find all service editor parameter dialog extensions
- IConfigurationElement[] elements = Platform.getExtensionRegistry()
- .getConfigurationElementsFor(extensionPoint);
- if (elements.length > 0) {
- for (int ii = 0; ii < elements.length; ii++) {
- // get extensions for this dialog
- // String extPluginId =
- // elements[ii].getDeclaringExtension().getNamespace();
- String anEditorId = elements[ii].getDeclaringExtension()
- .getSimpleIdentifier();
-
- // see if we have any contributuins of dialogs
- if (this.editorId.equals(anEditorId)) {
- element = elements[ii];
- break;
- }
- }
- }
- return element;
- }
-
- private void setText(String text) {
- getSection().setText(text);
- }
-
- private void setDescription(String text) {
- getSection().setDescription(text);
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/SWTUtils.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/SWTUtils.java
deleted file mode 100644
index 862b26bc2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/SWTUtils.java
+++ /dev/null
@@ -1,1032 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.events.ControlEvent;
-import org.eclipse.swt.events.ControlListener;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Point;
-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.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.List;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * This utility class provides convenience methods in creating controls on
- * preference pages.
- *
- * @author mengbo
- */
-public class SWTUtils {
- // Defaults of controls
- private static final int DEFAULT_BUTTON_WIDTH = 70;
-
- private static final int DEFAULT_COMBO_WIDTH = 100;
-
- private static final int DEFAULT_TEXTBOX_WIDTH = 100;
-
- private static final int DEFAULT_RADIO_FILL = GridData.HORIZONTAL_ALIGN_BEGINNING
- | GridData.VERTICAL_ALIGN_CENTER;
-
- /**
- * Creates a new checkbox and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the checkbox
- * @return the new checkbox
- */
- public static Button createCheckBox(Composite parent) {
- return createCheckBox(parent, null, 1, 0);
- }
-
- /**
- * Creates a new checkbox and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the checkbox
- * @param label
- * the string to set into the checkbox
- * @param numColumns
- * the number of columns the new checkbox is to occupy
- * @return the new checkbox
- */
- public static Button createCheckBox(Composite parent, String label,
- int numColumns) {
- return createCheckBox(parent, label, numColumns, 0);
- }
-
- /**
- * Creates a new checkbox and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the checkbox
- * @param label
- * the string to set into the checkbox
- * @param numColumns
- * the number of columns the new checkbox is to occupy
- * @param indent
- * the number of pixels to indent from the left
- * @return the new checkbox
- */
- public static Button createCheckBox(Composite parent, String label,
- int numColumns, int indent) {
- Button button = new Button(parent, SWT.CHECK | SWT.LEFT);
- if (label == null) {
- button.setAlignment(SWT.CENTER);
- }
- GridData data = new GridData(GridData.FILL);
- data.horizontalSpan = numColumns;
- data.horizontalIndent = indent;
- button.setLayoutData(data);
- if (label != null) {
- button.setText(label);
- }
- return button;
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param items
- * the items in the combo
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String[] items,
- int numColumns) {
- return createCombo(parent, items, numColumns, DEFAULT_COMBO_WIDTH);
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param tokenString
- * a tokenized string that will be split into the fields.
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String tokenString,
- int numColumns) {
- return createCombo(parent, getTokenNames(tokenString), numColumns,
- DEFAULT_COMBO_WIDTH);
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param tokenString
- * a tokenized string that will be split into the fields.
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @param minWidth
- * minimum width of combo box in pixels
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String tokenString,
- int numColumns, int minWidth) {
- return createCombo(parent, getTokenNames(tokenString), numColumns,
- minWidth);
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param items
- * the items in the combo
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @param minWidth
- * minimum width of combo box in pixels
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String[] items,
- int numColumns, int minWidth) {
- return createCombo(parent, items, numColumns, minWidth, false);
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param tokenString
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @param minWidth
- * minimum width of combo box in pixels
- * @param editable
- * whether the items in the combo is editable
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String tokenString,
- int numColumns, int minWidth, boolean editable) {
- return createCombo(parent, getTokenNames(tokenString), numColumns,
- minWidth, editable);
- }
-
- /**
- * Creates a combo box and sets the default layout data.
- *
- * @param parent
- * the composite in which to create the combo
- * @param items
- * the items in the combo
- * @param numColumns
- * the number of columns the new combo is to occupy
- * @param minWidth
- * minimum width of combo box in pixels
- * @param editable
- * whether the items in the combo is editable
- * @return the new combo box
- */
- public static Combo createCombo(Composite parent, String[] items,
- int numColumns, int minWidth, boolean editable) {
- Combo combo;
- GridData data;
- if (editable) {
- combo = new Combo(parent, SWT.DROP_DOWN);
- data = new GridData(GridData.FILL_HORIZONTAL);
- } else {
- combo = new Combo(parent, SWT.DROP_DOWN | SWT.READ_ONLY);
- data = new GridData(GridData.FILL);
- }
- data.horizontalSpan = numColumns;
- data.widthHint = minWidth;
- combo.setLayoutData(data);
- combo.setItems(items);
- return combo;
- }
-
- /**
- * Creates composite control and sets the default layout data.
- *
- * @param parent
- * the parent of the new composite
- * @param numColumns
- * the number of columns for the new composite
- * @return the newly-created coposite
- */
- public static Composite createComposite(Composite parent, int numColumns) {
- return createComposite(parent, numColumns, -1, -1,
- GridData.FILL_HORIZONTAL, -1, -1, -1);
- }
-
- /**
- * Creates composite control and sets the default layout data.
- *
- * @param parent
- * the parent of the new composite
- * @param numColumns
- * the number of columns for the new composite
- * @param verticalSpacing
- * the spacing between rows.
- * @param horizontalSpan
- * the span for this new composite over the original composite.
- * @return the newly-created coposite
- */
- public static Composite createComposite(Composite parent, int numColumns,
- int verticalSpacing, int horizontalSpan) {
- return createComposite(parent, numColumns, verticalSpacing,
- horizontalSpan, GridData.FILL_HORIZONTAL, -1, -1, -1);
- }
-
- /**
- * Creates composite control and sets the default layout data.
- *
- * @param parent
- * the parent of the new composite
- * @param numColumns
- * the number of columns for the new composite
- * @param verticalSpacing
- * the spacing between rows.
- * @param horizontalSpan
- * the span for this new composite over the original composite.
- * @param gridDataFill
- * the fill to use for this composite.
- * @return the newly-created coposite
- */
- public static Composite createComposite(Composite parent, int numColumns,
- int verticalSpacing, int horizontalSpan, int gridDataFill) {
- return createComposite(parent, numColumns, verticalSpacing,
- horizontalSpan, gridDataFill, -1, -1, -1);
- }
-
- /**
- * Creates composite control and sets the default layout data.
- *
- * @param parent
- * the parent of the new composite
- * @param numColumns
- * the number of columns for the new composite
- * @param verticalSpacing
- * the spacing between rows.
- * @param horizontalSpan
- * the span for this new composite over the original composite.
- * @param gridDataFill
- * the fill to use for this composite.
- * @param horizontalSpacing
- * the spacing between objects.
- * @param marginWidth
- * the spacing at start and end of composite.
- * @param marginHeight
- * the spacing above and below composite.
- * @return the newly-created coposite
- */
- public static Composite createComposite(Composite parent, int numColumns,
- int verticalSpacing, int horizontalSpan, int gridDataFill,
- int horizontalSpacing, int marginWidth, int marginHeight) {
- Composite composite = new Composite(parent, SWT.NULL);
- GridLayout layout = new GridLayout();
- layout.numColumns = numColumns;
- if (verticalSpacing >= 0) {
- layout.verticalSpacing = verticalSpacing;
- }
- if (horizontalSpacing >= 0) {
- layout.horizontalSpacing = horizontalSpacing;
- }
- if (marginWidth >= 0) {
- layout.marginWidth = marginWidth;
- }
- if (marginHeight >= 0) {
- layout.marginHeight = marginHeight;
- }
- composite.setLayout(layout);
- GridData gd = new GridData(gridDataFill);
- if (horizontalSpan > 0) {
- gd.horizontalSpan = horizontalSpan;
- }
- composite.setLayoutData(gd);
-
- return composite;
- }
-
- /**
- * Utility method that creates a group and sets the default layout data.
- *
- * @param parent
- * the parent for the new group
- * @param title
- * the label for the new group
- * @param numColumns
- * the number of columns for the new group
- * @return the newly created group
- */
- public static Group createGroup(Composite parent, String title,
- int numColumns) {
- return createGroup(parent, title, numColumns, -1,
- GridData.FILL_HORIZONTAL);
- }
-
- /**
- * Utility method that creates a group and sets the default layout data.
- *
- * @param parent
- * the parent for the new group
- * @param title
- * the label for the new group
- * @param numColumns
- * the number of columns for the new group
- * @param horizontalSpan
- * the number of columns this group should span on the parent
- * composite.
- * @param gridDataFill
- * the fill style of the new group -- set to for filling just
- * around the object: GridData.BEGINNING | GridData.CENTER
- * @return the newly created group
- */
- public static Group createGroup(Composite parent, String title,
- int numColumns, int horizontalSpan, int gridDataFill) {
- Group group = new Group(parent, SWT.SHADOW_ETCHED_IN);
- GridLayout layout = new GridLayout();
- layout.numColumns = numColumns;
- group.setLayout(layout);
- GridData data = new GridData(gridDataFill);
-
- if (horizontalSpan > 0) {
- data.horizontalSpan = horizontalSpan;
- }
- group.setLayoutData(data);
- group.setText(title);
- return group;
- }
-
- /**
- * Utility method that creates a label instance and sets the default layout
- * data.
- *
- * @param parent
- * the parent for the new label
- * @param text
- * the text for the new label
- * @param numColumns
- * the number of columns for the new composite
- * @return the new label
- */
- public static Label createLabel(Composite parent, String text,
- int numColumns) {
- return createLabel(parent, text, numColumns, 0);
- }
-
- /**
- * Utility method that creates a label instance and sets the default layout
- * data.
- *
- * @param parent
- * the parent for the new label
- * @param text
- * the text for the new label
- * @param numColumns
- * the number of columns for the new composite
- * @param indent
- * number of pixels to indent from the left
- * @return the new label
- */
- public static Label createLabel(Composite parent, String text,
- int numColumns, int indent) {
- Label label = new Label(parent, SWT.LEFT);
- GridData data = new GridData();
- data.horizontalSpan = numColumns;
- data.horizontalAlignment = GridData.FILL;
- data.horizontalIndent = indent;
- label.setLayoutData(data);
- label.setText(text);
- return label;
- }
-
- /**
- * Create a image label for sticking in a composite. The backgroud color is
- * optional. Because images can have "transparent" natures, you might want
- * to say the background is something other than the defaults composites
- * background.
- *
- * NOTE: the caller is responsible for cleanup of the image and color
- * objects.
- *
- * @param parent
- * the parent for the new label
- * @param theImage
- * the image for the new label
- * @param numColumns
- * the number of columns for the new composite
- * @param background
- * pass null to use the composites background.
- * @return the new label
- */
- public static Label createLabelImage(Composite parent, Image theImage,
- int numColumns, Color background) {
- Label label = new Label(parent, SWT.LEFT);
- GridData data = new GridData();
- data.horizontalSpan = numColumns;
- data.horizontalAlignment = GridData.FILL;
- label.setLayoutData(data);
- if (background != null) {
- label.setBackground(background);
- }
- label.setImage(theImage);
- return label;
- }
-
- /**
- * Utility method that creates a push button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param label
- * the label for the new button
- * @return the newly-created button
- */
- public static Button createPushButton(Composite parent, String label) {
- return createPushButton(parent, label, DEFAULT_BUTTON_WIDTH);
- }
-
- /**
- * Utility method that creates a push button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param label
- * the label for the new button
- * @param widthHint
- * use this width for the button.
- * @return the newly-created button
- */
- public static Button createPushButton(Composite parent, String label,
- int widthHint) {
- Button button = new Button(parent, SWT.PUSH);
- GridData data = new GridData();
- data.horizontalAlignment = GridData.FILL_HORIZONTAL;
- data.widthHint = widthHint;
- button.setLayoutData(data);
- button.setText(label);
- return button;
- }
-
- /**
- * Utility method that creates a push button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param theImage
- * the label for the new button
- * @param widthHint
- * use this width for the button.
- * @return the newly-created button
- */
- public static Button createPushButton(Composite parent, Image theImage,
- int widthHint) {
- Button button = new Button(parent, SWT.PUSH);
- GridData data = new GridData();
- data.horizontalAlignment = GridData.FILL_HORIZONTAL;
- data.widthHint = widthHint;
- button.setLayoutData(data);
- button.setImage(theImage);
- button.setAlignment(SWT.CENTER);
- return button;
- }
-
- /**
- * Utility method that creates a radio button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param label
- * the label for the new button
- * @return the newly-created button
- */
- public static Button createRadioButton(Composite parent, String label) {
- return createRadioButton(parent, label, DEFAULT_RADIO_FILL);
- }
-
- /**
- * Utility method that creates a radio button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param label
- * the label for the new button
- * @param gridDataFill
- * @return the newly-created button
- */
- public static Button createRadioButton(Composite parent, String label,
- int gridDataFill) {
- return createRadioButton(parent, label, gridDataFill, 1);
- }
-
- /**
- * Utility method that creates a radio button instance and sets the default
- * layout data.
- *
- * @param parent
- * the parent for the new button
- * @param label
- * the label for the new button
- * @param gridDataFill
- * @param horizontalSpan
- * number of columns occupied by button
- * @return the newly-created button
- */
- public static Button createRadioButton(Composite parent, String label,
- int gridDataFill, int horizontalSpan) {
- Button button = new Button(parent, SWT.RADIO | SWT.LEFT);
- GridData data = new GridData(gridDataFill);
- data.horizontalSpan = horizontalSpan;
- button.setLayoutData(data);
- button.setText(label);
- return button;
- }
-
- /**
- * Utility method that creates an empty line
- *
- * @param parent
- * the parent for the new label
- * @param numColumns
- * the number of columns for the new composite
- */
- public static void createSpacer(Composite parent, int numColumns) {
- createSpacer(parent, numColumns, 0);
- }
-
- /**
- * Utility method that creates an empty line
- *
- * @param parent
- * the parent for the new label
- * @param numColumns
- * the number of columns for the new composite
- * @param minWidth
- * minimum width of spacer
- */
- public static void createSpacer(Composite parent, int numColumns,
- int minWidth) {
- Label label = new Label(parent, SWT.NONE);
- GridData data = new GridData();
- data.horizontalSpan = numColumns;
- data.widthHint = minWidth;
- label.setLayoutData(data);
- }
-
- /**
- * Create a separator that goes across the entire page
- *
- * @param parent
- * the parent for the new label
- * @param numColumns
- * the number of columns for the new composite
- */
- public static void createSeparator(Composite parent, int numColumns) {
- Label separator = new Label(parent, SWT.SEPARATOR | SWT.HORIZONTAL);
- GridData data = new GridData();
- data.horizontalSpan = numColumns;
- data.horizontalAlignment = GridData.FILL;
- data.grabExcessHorizontalSpace = true;
- separator.setLayoutData(data);
- }
-
- /**
- * Create a table from a Composite object
- *
- * @param composite
- * the Composite this table is to be created from
- * @param tokenString
- * A string containing names of the columns in the order that
- * they should be displayed in the table with each column
- * separated by a comma(',') or null if no columns need to be
- * created.
- * @param tablewidth
- * the minimum width for the table
- * @param tableHeight
- * @return the new table
- */
- public static Table createTable(Composite composite, String tokenString,
- int tablewidth, int tableHeight) {
- // SINGLE, MULTI, CHECK, FULL_SELECTION, HIDE_SELECTION
- int style = SWT.V_SCROLL | SWT.H_SCROLL | SWT.SINGLE | SWT.BORDER
- | SWT.FULL_SELECTION;
- Table table = new Table(composite, style);
- GridData gridData = new GridData(GridData.FILL_BOTH);
- if (tablewidth > 0) {
- gridData.widthHint = tablewidth;
- }
- if (tableHeight > 0) {
- gridData.heightHint = tableHeight;
- }
- table.setLayoutData(gridData);
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
-
- if (tokenString != null) {
- String[] columns = getTokenNames(tokenString);
-
- int columnSize = 50;
- if (tablewidth > 0) {
- columnSize = tablewidth / columns.length;
- }
- for (int ii = 0; ii < columns.length; ii++) {
- /*(void)*/ createTableColumn(table, columns[ii], ii,
- columnSize);
- }
- }
-
- return table;
- }
-
- /**
- * Create a table from a Composite object
- *
- * @param composite
- * the Composite this table is to be created from
- * @param columns
- * A string array containing names of the columns in the order
- * that they should be displayed in the table, or null if no
- * columns need to be created.
- * @param tablewidth
- * the minimum width for the table
- * @return the new table
- */
- public static Table createTable(Composite composite, String[] columns,
- int tablewidth) {
- int style = SWT.BORDER | SWT.FULL_SELECTION;
- Table table = new Table(composite, style);
- GridData gridData = new GridData(GridData.FILL_BOTH);
- gridData.widthHint = tablewidth;
- table.setLayoutData(gridData);
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
-
- if (columns != null) {
- for (int i = 0; i < columns.length; i++) {
- /*(void)*/ createTableColumn(table, columns[i], i);
- }
- }
-
- return table;
- }
-
- /**
- * Create a table column
- *
- * @param parent
- * the table that contains this column
- * @param name
- * name of this column
- * @param index
- * the column within the parent composite
- * @return the new table column
- */
- public static TableColumn createTableColumn(Table parent, String name,
- int index) {
- TableColumn column = new TableColumn(parent, SWT.LEFT, index);
- column.setText(name);
- return column;
- }
-
- /**
- * Create a table column with the image and the width of the column is set
- * to the image width.
- *
- * @param parent
- * the table that contains this column
- * @param image
- * iamge for this column
- * @param index
- * @return the new table column
- */
- public static TableColumn createTableColumn(Table parent, Image image,
- int index) {
- TableColumn column = new TableColumn(parent, SWT.LEFT, index);
- column.setImage(image);
- column.setWidth(image.getBounds().width);
- column.setResizable(false);
- return column;
- }
-
- /**
- * Create a table column
- *
- * @param parent
- * the table that contains this column
- * @param name
- * name of this column
- * @param index
- * the column within the parent composite
- * @param tablewidth
- * the width for the column
- * @return the new table column
- */
- public static TableColumn createTableColumn(Table parent, String name,
- int index, int tablewidth) {
- TableColumn column = new TableColumn(parent, SWT.LEFT, index);
- column.setText(name);
- column.setWidth(tablewidth);
- return column;
- }
-
- /**
- * Create a text field
- *
- * @param parent
- * the parent of the new text field
- * @return the new text field
- */
- public static Text createTextBox(Composite parent) {
- return createTextBox(parent, 1, DEFAULT_TEXTBOX_WIDTH);
- }
-
- /**
- * Create a text field
- *
- * @param parent
- * the parent of the new text field
- * @param text
- * @return the new text field
- */
- public static Text createTextBox(Composite parent, String text) {
- Text textbox = createTextBox(parent, 1);
- textbox.setText(text);
- return textbox;
- }
-
- /**
- * Create a text field
- *
- * @param parent
- * the parent of the new text field
- * @param numColumns
- * number of columns the text box is to occupy
- * @return the new text field
- */
- public static Text createTextBox(Composite parent, int numColumns) {
- return createTextBox(parent, numColumns, DEFAULT_TEXTBOX_WIDTH);
- }
-
- /**
- * Create a text field
- *
- * @param parent
- * the parent of the new text field
- * @param numColumns
- * number of columns the text box is to occupy
- * @param minWidth
- * minimum width of text field
- * @return the new text field
- */
- public static Text createTextBox(Composite parent, int numColumns,
- int minWidth) {
- return createTextBox(parent, numColumns, minWidth, SWT.DEFAULT);
- }
-
- /**
- * Create a text field
- *
- * @param parent
- * the parent of the new text field
- * @param numColumns
- * number of columns the text box is to occupy
- * @param minWidth
- * minimum width of text field
- * @param minHeight
- * @return the new text field
- */
- public static Text createTextBox(Composite parent, int numColumns,
- int minWidth, int minHeight) {
- Text text = new Text(parent, SWT.SINGLE | SWT.BORDER);
- GridData data = new GridData(GridData.FILL);
- data.horizontalSpan = numColumns;
- data.widthHint = minWidth;
- data.heightHint = minHeight;
- text.setLayoutData(data);
- return text;
- }
-
- /**
- * Create a text field that is scrollable.
- *
- * @param parent
- * the parent of the new text field
- * @param numColumns
- * number of columns the text box is to occupy
- * @param minWidth
- * minimum width of text field
- * @param minHeight
- * minimum height of text field
- * @return the new text field
- */
- public static Text createTextBoxScrollable(Composite parent,
- int numColumns, int minWidth, int minHeight) {
- Text text = new Text(parent, SWT.BORDER | SWT.V_SCROLL | SWT.WRAP);
- GridData data = new GridData((minWidth > 0) ? GridData.FILL
- : GridData.FILL_HORIZONTAL);
- data.horizontalSpan = numColumns;
- if (minWidth > 0) {
- data.widthHint = minWidth;
- }
- data.heightHint = minHeight;
-
- text.setLayoutData(data);
- return text;
- }
-
- /**
- * Create a list with the items listed in it.
- *
- * @param parent
- * the parent of the new text field
- * @param numColumns
- * number of columns the text box is to occupy
- * @param minWidth
- * minimum width of text field
- * @param minHeight
- * minimum height of text field
- * @param items
- * the items in the list
- * @return the new list
- */
- public static List createList(Composite parent, int numColumns,
- int minWidth, int minHeight, String[] items) {
- return createList(parent, numColumns, minWidth, minHeight, items, true);
- }
-
- /**
- * Create a list with the items listed in it.
- *
- * @param parent
- * the parent of the new list box
- * @param numColumns
- * number of columns the list box is to occupy
- * @param minWidth
- * minimum width of list box
- * @param minHeight
- * minimum height of list box
- * @param items
- * the items in the list
- * @param bmulti
- * whether multiple item selection is allowed
- * @return the new list
- */
- public static List createList(Composite parent, int numColumns,
- int minWidth, int minHeight, String[] items, boolean bmulti) {
- return createList(parent, numColumns, minWidth, minHeight, items,
- bmulti, 1);
- }
-
- /**
- * Create a list with the items listed in it.
- *
- * @param parent
- * the parent of the new list box
- * @param numColumns
- * number of columns the list box is to occupy
- * @param minWidth
- * minimum width of list box
- * @param minHeight
- * minimum height of list box
- * @param items
- * the items in the list
- * @param bmulti
- * whether multiple item selection is allowed
- * @param verticalSpan
- * the number of rows the list box is to occupy
- * @return the new list
- */
- public static List createList(Composite parent, int numColumns,
- int minWidth, int minHeight, String[] items, boolean bmulti,
- int verticalSpan) {
- List theList;
- if (bmulti)
- theList = new List(parent, SWT.V_SCROLL | SWT.H_SCROLL | SWT.MULTI
- | SWT.BORDER);
- else
- theList = new List(parent, SWT.V_SCROLL | SWT.H_SCROLL | SWT.SINGLE
- | SWT.BORDER);
- GridData data = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING | GridData.FILL_VERTICAL);
- data.horizontalSpan = numColumns;
- data.widthHint = minWidth;
- data.heightHint = minHeight;
- data.verticalSpan = verticalSpan;
- theList.setLayoutData(data);
- if (items != null) {
- theList.setItems(items);
- }
-
- return theList;
- }
-
- /**
- * Computes the size of the composite inside the scroll area so that scroll
- * bars show up correctly.
- *
- * @param parentComposite
- * @param childComposite
- */
- public static void computeScrollArea(ScrolledComposite parentComposite,
- Composite childComposite) {
- // Point pt = childComposite.computeSize(SWT.DEFAULT, SWT.DEFAULT);
- // childComposite.setSize(pt);
-
- Point pt = childComposite.computeSize(SWT.DEFAULT, SWT.DEFAULT);
- parentComposite.setExpandHorizontal(true);
- parentComposite.setExpandVertical(true);
- parentComposite.setMinWidth(pt.x);
- parentComposite.setMinHeight(pt.y);
- }
-
- /**
- * Builds an array of strings from a token list string. The token separator
- * is a comma (',').
- *
- * @param tokenString
- * @return String[]
- */
- public static String[] getTokenNames(String tokenString) {
- if (tokenString == null) {
- return new String[0];
- }
-
- return tokenString.split(","); //$NON-NLS-1$
- }
-
- /**
- * Enable/Disable the widget and all its children.
- *
- * @param widget
- * The widget to be enabled/disabled.
- * @param state
- * Enable widget if true. Disable otherwise.
- */
- public static void setWidgetState(Control widget, boolean state) {
- if (widget instanceof Composite) {
- Control widgets[] = ((Composite) widget).getChildren();
- for (int i = 0; i < widgets.length; i++) {
- setWidgetState(widgets[i], state);
- }
- }
- widget.setEnabled(state);
- }
-
- // ---------------------------------------------------------------------------
- // following is for workaround eclipse problem
- // https://bugs.eclipse.org/bugs/show_bug.cgi?id=40281
- static ControlListener _listener = new ControlListener() {
- public void controlResized(ControlEvent e) {
- final Composite c = (Composite) e.widget;
- c.getDisplay().asyncExec(new Runnable() {
- public void run() {
- if (!c.isDisposed()) {
- // XXX: in 3.0, should use c.layout(true)
- // in 3.1, should use c.layout(true, true)
- c.layout(true);
- c.redraw();
- }
- }
- });
- }
-
- public void controlMoved(ControlEvent e) {
- // nothing for move
- }
- };
-
- /**
- * @param composite
- */
- public static void workaroundResize(Composite composite) {
- composite.addControlListener(_listener);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/TextWindow.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/TextWindow.java
deleted file mode 100644
index b829cd289..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/TextWindow.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.guiutils;
-
-import org.eclipse.jface.text.Document;
-import org.eclipse.jface.text.TextViewer;
-import org.eclipse.jface.window.ApplicationWindow;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * Brings up a simple text window.
- *
- * @author mengbo
- */
-public class TextWindow extends ApplicationWindow {
- private String _content;
-
- private Point _size = new Point(600, 600);
-
- /**
- * empty for passing from events.
- * @param parentShell
- * @param content
- */
- public TextWindow(Shell parentShell, String content) {
- super(parentShell);
- // addStatusLine();
- _content = content;
- // addCoolBar(SWT.BORDER);
- // addMenuBar();
- // addToolBar(SWT.BORDER);
- }
-
- protected Control createContents(Composite parent) {
- // _text = new Text(parent, SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL);
- // _text.setText(_content);
- // return _text;
-
- TextViewer tview = new TextViewer(parent, SWT.BORDER | SWT.V_SCROLL
- | SWT.H_SCROLL);
- tview.setDocument(new Document(_content));
-
- return tview.getControl();
- }
-
-
- protected Point getInitialSize() {
- return _size;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/messages.properties
deleted file mode 100644
index 6291ec040..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/guiutils/messages.properties
+++ /dev/null
@@ -1,3 +0,0 @@
-IntroductionSection_noIntroDescription=No Introduction page configuration found in the plugin.xml
-IntroductionSection_noIntroTitle=No Introduction
-BrowserWindow_loading=<b>Loading...</b>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/logging/Logger.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/logging/Logger.java
deleted file mode 100644
index 3b71b83bc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/logging/Logger.java
+++ /dev/null
@@ -1,215 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.logging;
-
-import java.text.MessageFormat;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.ILog;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.Status;
-import org.osgi.framework.Bundle;
-
-/**
- * A resource bundle driven logger
- *
- */
-public class Logger {
- private ResourceBundle resourceBundle;
-
- private ILog log;
-
- private String bundleId;
-
- /**
- * @param bundle
- * @param resourceBundle
- */
- public Logger(Bundle bundle, ResourceBundle resourceBundle) {
- log = Platform.getLog(bundle);
- this.resourceBundle = resourceBundle;
- bundleId = bundle.getSymbolicName();
- if (resourceBundle == null) {
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- "The resource Bundle for logger could not be null!", null); //$NON-NLS-1$
- log.log(status);
- }
- }
- /**
- * @param key
- * @param arg0
- */
- public void info(String key, String arg0) {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.INFO, bundleId, IStatus.OK,
- message, null);
- log.log(status);
- }
-
- /**
- * @param message
- */
- public void info(String message) {
- IStatus status = new Status(IStatus.INFO, bundleId, IStatus.OK,
- message, null);
- log.log(status);
- }
-
- /**
- * @param key
- * @param e
- */
- public void info(String key, Throwable e) {
- String message = getString(key);
- IStatus status = new Status(IStatus.INFO, bundleId, IStatus.OK,
- message, e);
- log.log(status);
- }
-
- /**
- * @param key
- * @param arg0
- * @param e
- */
- public void info(String key, String arg0, Throwable e) {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.INFO, bundleId, IStatus.OK,
- message, null);
- log.log(status);
- }
-
- /**
- * @param key
- * @param arg0
- * @param arg1
- * @param e
- */
- public void info(String key, String arg0, String arg1, Throwable e) {
- Object[] args = new Object[1];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.INFO, bundleId, IStatus.OK,
- message, e);
- log.log(status);
- }
-
- /**
- * @param key
- */
- public void error(String key) {
-
- String message = getString(key);
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- message, null);
- log.log(status);
- }
-
- /**
- * @param e
- */
- public void error(Throwable e) {
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK, "", e); //$NON-NLS-1$
- log.log(status);
- }
-
- /**
- * @param key
- * @param e
- */
- public void error(String key, Throwable e) {
- String message = getString(key);
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- message, e);
- log.log(status);
- }
-
- /**
- * @param key
- * @param arg0
- */
- public void error(String key, String arg0) {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- message, null);
- log.log(status);
- }
-
- /**
- * @param key
- * @param arg
- * @param e
- */
- public void error(String key, String arg, Throwable e) {
- Object[] args = new Object[1];
- args[0] = arg;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- message, e);
- log.log(status);
- }
-
- /**
- * @param key
- * @param arg0
- * @param arg1
- * @param e
- */
- public void error(String key, String arg0, String arg1, Throwable e) {
- Object[] args = new Object[1];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- String message = formatter.format(args);
- IStatus status = new Status(IStatus.ERROR, bundleId, IStatus.OK,
- message, e);
- log.log(status);
- }
-
- /**
- * @param key
- * @return the resource for the key, or an error message if
- * resourceBundle.getString(key) throws an Exception
- */
- private String getString(String key)
- {
- try
- {
- return resourceBundle.getString(key);
- }
- // suppress non-error exceptions so that the logging operation
- // itself (usually called in response to an exception) does not
- // throw a new exception
- catch(Exception e)
- {
- return "!!missing resource: " + key + "!!"; //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.java
deleted file mode 100644
index 820224538..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.preferences;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * @author cbateman
- *
- */
-public class OrderingMessages extends NLS
-{
- private static final String BUNDLE_NAME= "org.eclipse.jst.jsf.common.ui.internal.preferences.OrderingMessages";//$NON-NLS-1$
-
- private OrderingMessages() {
- // Do not instantiate
- }
-
- /**
- * see OrderMessages.properties
- */
- public static String Ordering_Up;
- /**
- * see OrderMessages.properties
- */
- public static String Ordering_Down;
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, OrderingMessages.class);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.properties
deleted file mode 100644
index 282ee2320..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/OrderingMessages.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-Ordering_Up=Up
-Ordering_Down=Down \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/StrategyOrderingPanel.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/StrategyOrderingPanel.java
deleted file mode 100644
index c438b960d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/preferences/StrategyOrderingPanel.java
+++ /dev/null
@@ -1,322 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.preferences;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTableViewer;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.common.internal.policy.OrderedListProvider;
-import org.eclipse.jst.jsf.common.internal.policy.OrderedListProvider.OrderableObject;
-import org.eclipse.jst.jsf.common.ui.internal.utils.PixelConverter;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.GC;
-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.Label;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-
-/**
- * Creates a composite with a checked table viewer and up/down buttons that
- * allow ordering and enablement of a list of items in the table.
- *
- * Largely derived from
- * org.eclipse.jdt.internal.ui.preferences.CodeAssistAdvancedConfigurationBlock
- *
- * @author cbateman
- *
- */
-public class StrategyOrderingPanel
-{
- private CheckboxTableViewer _viewer;
- private Button fUpButton;
- private Button fDownButton;
-
- private final OrderedListProvider _provider;
- private final ITableLabelProvider _labelProvider;
- private final String _title;
-
- /**
- * @param provider
- * @param labelProvider
- * @param title
- */
- public StrategyOrderingPanel(final OrderedListProvider provider,
- final ITableLabelProvider labelProvider, final String title)
- {
- _provider = provider;
- _labelProvider = labelProvider;
- _title = title;
- }
-
- /**
- * @param parent
- * @return the control
- */
- public Control createContents(final Composite parent)
- {
- final Composite panel = new Composite(parent, SWT.NONE);
- final GridLayout layout = new GridLayout(2, false);
- layout.marginWidth = 0;
- layout.marginHeight = 0;
- panel.setLayout(layout);
-
- final Label titleLabel = new Label(panel, SWT.NONE);
- titleLabel.setText(_title);
- final GridData gridData = new GridData(GridData.FILL,
- GridData.BEGINNING, true, false, 2, 1);
- titleLabel.setLayoutData(gridData);
-
- createTableViewer(panel);
- createButtonList(panel);
-
- return panel;
- }
-
- /**
- * Refresh the UI from model. Must not be called before createContents
- */
- public void refresh()
- {
- _provider.resetOrderedObjects();
- _viewer.refresh();
- for (final OrderableObject object : _provider.getOrderedObjects())
- {
- _viewer.setChecked(object, object.isEnabled());
- }
- }
-
- private void createTableViewer(final Composite parent)
- {
- _viewer = CheckboxTableViewer.newCheckList(parent, SWT.SINGLE
- | SWT.BORDER);
- final Table table = _viewer.getTable();
- table.setHeaderVisible(false);
- table.setLinesVisible(false);
- table.setLayoutData(new GridData(GridData.FILL, GridData.BEGINNING,
- true, false, 1, 1));
-
- final TableColumn nameColumn = new TableColumn(table, SWT.NONE);
- // nameColumn
- // .setText(PreferencesMessages.CodeAssistAdvancedConfigurationBlock_separate_table_category_column_title);
- nameColumn.setResizable(false);
-
- _viewer.setContentProvider(new ContentProvider());
-
- _viewer.setLabelProvider(_labelProvider);
- _viewer.setInput(_provider);
-
- final int ICON_AND_CHECKBOX_WITH = 50;
- final int HEADER_MARGIN = 20;
- int minNameWidth = computeWidth(table, nameColumn.getText())
- + HEADER_MARGIN;
- for (int i = 0; i < _provider.getOrderedObjects().size(); i++)
- {
- minNameWidth = Math.max(minNameWidth, computeWidth(table,
- _labelProvider.getColumnText(_provider.getOrderedObjects()
- .get(i), 0))
- + ICON_AND_CHECKBOX_WITH);
- }
-
- nameColumn.setWidth(minNameWidth);
-
- _viewer.addCheckStateListener(new ICheckStateListener()
- {
- public void checkStateChanged(final CheckStateChangedEvent event)
- {
- final boolean checked = event.getChecked();
- final OrderableObject element = (OrderableObject) event
- .getElement();
- element.setEnabled(checked);
- }
- });
-
- table.addSelectionListener(new SelectionAdapter()
- {
- @Override
- public void widgetSelected(final SelectionEvent e)
- {
- handleTableSelection();
- }
- });
-
- }
-
- private void createButtonList(final Composite parent)
- {
- final Composite composite = new Composite(parent, SWT.NONE);
- composite.setLayoutData(new GridData(SWT.BEGINNING, SWT.BEGINNING,
- false, false));
-
- final GridLayout layout = new GridLayout();
- layout.marginWidth = 0;
- layout.marginHeight = 0;
- composite.setLayout(layout);
-
- fUpButton = new Button(composite, SWT.PUSH | SWT.CENTER);
- fUpButton.setText(OrderingMessages.Ordering_Up);
- fUpButton.addSelectionListener(new SelectionAdapter()
- {
- @Override
- public void widgetSelected(final SelectionEvent e)
- {
- final int index = getSelectionIndex();
- if (index != -1)
- {
- final OrderableObject object = _provider
- .getOrderedObjects().get(index);
- _provider.moveUp(object);
- _viewer.refresh();
- handleTableSelection();
- }
- }
- });
- fUpButton.setLayoutData(new GridData());
- setButtonDimensionHint(fUpButton);
-
- fDownButton = new Button(composite, SWT.PUSH | SWT.CENTER);
- fDownButton.setText(OrderingMessages.Ordering_Down);
- fDownButton.addSelectionListener(new SelectionAdapter()
- {
- @Override
- public void widgetSelected(final SelectionEvent e)
- {
- final int index = getSelectionIndex();
- if (index != -1)
- {
- final OrderableObject object = _provider
- .getOrderedObjects().get(index);
- _provider.moveDown(object);
- _viewer.refresh();
- handleTableSelection();
- }
- }
- });
- fDownButton.setLayoutData(new GridData());
- setButtonDimensionHint(fDownButton);
- }
-
- private int computeWidth(final Control control, final String name)
- {
- if (name == null)
- {
- return 0;
- }
- final GC gc = new GC(control);
- try
- {
- gc.setFont(JFaceResources.getDialogFont());
- return gc.stringExtent(name).x + 10;
- }
- finally
- {
- gc.dispose();
- }
- }
-
- private void handleTableSelection()
- {
- final OrderableObject item = getSelectedItem();
- if (item != null)
- {
- final int index = getSelectionIndex();
- fUpButton.setEnabled(index > 0);
- fDownButton
- .setEnabled(index < _provider.getOrderedObjects().size() - 1);
- }
- else
- {
- fUpButton.setEnabled(false);
- fDownButton.setEnabled(false);
- }
- }
-
- private OrderableObject getSelectedItem()
- {
- return (OrderableObject) ((IStructuredSelection) _viewer.getSelection())
- .getFirstElement();
- }
-
- private int getSelectionIndex()
- {
- return _viewer.getTable().getSelectionIndex();
- }
-
- /**
- * Returns a width hint for a button control.
- */
- private static int getButtonWidthHint(final Button button)
- {
- button.setFont(JFaceResources.getDialogFont());
- PixelConverter converter = new PixelConverter(button);
- final int widthHint = converter
- .convertHorizontalDLUsToPixels(IDialogConstants.BUTTON_WIDTH);
- return Math.max(widthHint, button.computeSize(SWT.DEFAULT, SWT.DEFAULT,
- true).x);
- }
-
- /**
- * Sets width and height hint for the button control. <b>Note:</b> This is
- * a NOP if the button's layout data is not an instance of
- * <code>GridData</code>.
- *
- * @param button
- * the button for which to set the dimension hint
- */
- private static void setButtonDimensionHint(final Button button)
- {
- Assert.isNotNull(button);
- final Object gd = button.getLayoutData();
- if (gd instanceof GridData)
- {
- ((GridData) gd).widthHint = getButtonWidthHint(button);
- ((GridData) gd).horizontalAlignment = GridData.FILL;
- }
- }
-
- private static class ContentProvider implements IStructuredContentProvider
- {
-
- public Object[] getElements(final Object inputElement)
- {
- if (inputElement instanceof OrderedListProvider)
- {
- return ((OrderedListProvider) inputElement).getOrderedObjects()
- .toArray();
- }
- return new Object[0];
- }
-
- public void dispose()
- {
- // do nothing
- }
-
- public void inputChanged(final Viewer viewer, final Object oldInput,
- final Object newInput)
- {
- // do nothing
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/FavoriteConfigurations.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/FavoriteConfigurations.java
deleted file mode 100644
index aa7744b1c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/FavoriteConfigurations.java
+++ /dev/null
@@ -1,257 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.io.FileNotFoundException;
-import java.io.FileReader;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Properties;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.ui.IMemento;
-import org.eclipse.ui.XMLMemento;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-
-/**
- * This provides a means to store common properties for pages.
- *
- * Holds a <code>List</code> of <code>Properties</code> which can be
- * manipulated by the user.
- *
- * @author mengbo
- */
-public class FavoriteConfigurations {
- private static Logger _log = JSFUICommonPlugin
- .getLogger(FavoriteConfigurations.class);
-
- private final static String FAV_EXTENSIONS = ".xml"; //$NON-NLS-1$
-
- private final static String ELEMENT_ROOT = "favorite"; //$NON-NLS-1$
-
- private final static String ELEMENT_CONFIG = "config"; //$NON-NLS-1$
-
- private final static String ELEMENT_NAME = "name"; //$NON-NLS-1$
-
- private final static String ELEMENT_PROPERTY = "property"; //$NON-NLS-1$
-
- private final static String ELEMENT_VALUE = "value"; //$NON-NLS-1$
-
- private Map _favorites;
-
- private IPath _favoriteFile;
-
- private String _favoriteName;
-
- /**
- * Constructor
- *
- * @param plugin
- * used for location of favorite file.
- * @param favoriteName
- * used for name of file and for mapping the properties of this
- * favorite.
- */
- public FavoriteConfigurations(AbstractUIPlugin plugin, String favoriteName) {
- super();
- _favoriteFile = plugin.getStateLocation().append(
- scanFileName(favoriteName) + FAV_EXTENSIONS);
- readFavorites();
- }
-
- /**
- * Returns the favorite entry that is mapped under the given name.
- *
- * @param name
- * the favorite
- * @return <code>Properties</code> config entry for the favorite.
- */
- public Properties getFavorite(String name) {
- return (Properties) _favorites.get(name);
- }
-
- /**
- * Stores the Favorites into the plugin directory.
- */
- public void saveFavorites() {
- FileWriter fw = null;
- try {
- XMLMemento memento = XMLMemento.createWriteRoot(ELEMENT_ROOT);
- for (Iterator it = _favorites.keySet().iterator(); it.hasNext();) {
- String favName = (String) it.next();
- Map props = new HashMap((Properties) _favorites.get(favName));
-
- IMemento config = memento.createChild(ELEMENT_CONFIG);
- config.putString(ELEMENT_NAME, favName);
-
- for (Iterator it1 = props.keySet().iterator(); it1.hasNext();) {
- IMemento entry = config.createChild(ELEMENT_PROPERTY);
- String name = (String) it1.next();
- entry.putString(ELEMENT_NAME, name);
- entry.putString(ELEMENT_VALUE, (String) props.get(name));
- }
- }
- fw = new FileWriter(_favoriteFile.toFile());
- memento.save(fw);
- } catch (Exception ee) {
- // log.FavoriteConfigurations.save.error=Failed to save {0}
- // favorites. File={1}
- _log.info("log.FavoriteConfigurations.save.error", _favoriteName, //$NON-NLS-1$
- _favoriteFile.toOSString(), ee);
- } finally {
- if (fw != null) {
- try {
- fw.close();
- } catch (IOException ee)// NOPMD
- {
- // nothing to do when IOException throwed in closing files.
- }
- }
- }
- }
-
- /**
- * Add the favorite into the internal structure but don't save until
- * saveFavorites() is called.
- *
- * @param name
- * @param config
- */
- public void addFavorite(String name, Properties config) {
- _favorites.put(name, config);
- }
-
- /**
- * Removes the Favorite that is mapped under the given name.
- *
- * @param name
- * the name of the configuration
- */
- public void removeFavorite(String name) {
- _favorites.remove(name);
- }
-
- /**
- * Read the favorites from the disk into the memory structure.
- */
- protected void readFavorites() {
- _favorites = new HashMap();
- FileReader fr = null;
- try {
- try {
- fr = new FileReader(_favoriteFile.toFile());
- } catch (FileNotFoundException ee)// NOPMD
- {
- // no error here since they don't have to have a favorites...
- }
- if (fr != null) {
- XMLMemento memento = XMLMemento.createReadRoot(fr);
- IMemento[] children = memento.getChildren(ELEMENT_CONFIG);
- for (int ii = 0; ii < children.length; ii++) {
- Properties props = new Properties();
- IMemento config = children[ii];
- String name = config.getString(ELEMENT_NAME);
-
- IMemento[] configProperties = config
- .getChildren(ELEMENT_PROPERTY);
- for (int jj = 0; jj < configProperties.length; jj++) {
- IMemento entry = configProperties[jj];
- setProperty(props, entry.getString(ELEMENT_NAME), entry
- .getString(ELEMENT_VALUE));
- }
- _favorites.put(name, props);
- }
- }
- } catch (Exception ee) {
- // log.FavoriteConfigurations.read.error=Failed to save {0}
- // favorites. File={1}
- _log.error("log.FavoriteConfigurations.read.error", _favoriteName, //$NON-NLS-1$
- _favoriteFile.toOSString(), ee);
- } finally {
- if (fr != null) {
- try {
- fr.close();
- } catch (IOException ee)// NOPMD
- {
- // nothing to do when IOException throwed in closing files.
- }
- }
- }
- }
-
- /**
- * Set the value in the properties object.
- *
- * @param props
- * @param name
- * @param value
- */
- private void setProperty(Properties props, String name, String value) {
- if (name != null && value != null) {
- props.setProperty(name, value);
- }
- }
-
- /**
- * Get a list of all the favorites stored in this file.
- *
- * @return list of favorites
- */
- public String[] getFavoritesList() {
- Object[] objs = _favorites.keySet().toArray();
- String[] names = new String[objs.length];
-
- for (int ii = 0; ii < objs.length; ii++) {
- names[ii] = (String) objs[ii];
- }
- Arrays.sort(names);
-
- return names;
- }
-
- /**
- * scan the file name for any bad character that would fail when trying to
- * create the file. We replace bad characters with '_'
- */
- private static String scanFileName(String filename) {
- StringBuffer strBuf = new StringBuffer();
- char[] chars = filename.toCharArray();
-
- for (int ii = 0; ii < chars.length; ii++) {
- switch (chars[ii]) {
- case '&':
- case '\\':
- case '/':
- case ' ':
- case '\t':
- case ':':
- case '.':
- case '\"':
- case '\'':
- case '@':
- strBuf.append('_');
- break;
- default:
- strBuf.append(chars[ii]);
- break;
- }
- }
-
- return strBuf.toString();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JSFSharedImages.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JSFSharedImages.java
deleted file mode 100644
index 2b67a671e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JSFSharedImages.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-/**
- * Constants that can be passed to JSFUICommonPlugin.getImageDescriptor and
- * getImage to obtain common images.
- *
- * @author cbateman
- *
- */
-public interface JSFSharedImages
-{
- /**
- * The icon use for default/unknown tags. Consists of blue open/close
- * angled braces on a neutral background.
- *
- * Size: 16x16
- */
- public final static String DEFAULT_PALETTE_TAG_IMG = "PD_Palette_Default.gif"; //$NON-NLS-1$
-
- /**
- * A yellow cube on a white background. Suitable for representing
- * generic objects and components.
- *
- * Size: 16x16
- */
- public final static String GENERIC_OBJECT_IMG = "object.gif"; //$NON-NLS-1$
-
- /**
- * A generic image suitable for representing JSF validators. Consists of
- * a white box with a blue check mark.
- *
- * Size: 16x16
- */
- public final static String GENERIC_VALIDATOR_IMG = "jsf_validator.gif"; //$NON-NLS-1$
-
- /**
- * A generic image suitable for representing JSF converter. Consists of
- * yellow blob being "converted".
- *
- * Size: 16x16
- */
- public final static String GENERIC_CONVERTER_IMG = "jsf_converter.gif"; //$NON-NLS-1$
-
- /**
- * A generic image suitable for representing a view root. Same as the
- * default image generally associated with f:view.
- *
- * Size: 16x16.
- */
- public static final String GENERIC_VIEWROOT_IMG = "jsf_view.gif"; //$NON-NLS-1$
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JavaModelUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JavaModelUtil.java
deleted file mode 100644
index c4086ed7f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/JavaModelUtil.java
+++ /dev/null
@@ -1,1032 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.ClasspathContainerInitializer;
-import org.eclipse.jdt.core.Flags;
-import org.eclipse.jdt.core.IClasspathContainer;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IField;
-import org.eclipse.jdt.core.IImportDeclaration;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IMember;
-import org.eclipse.jdt.core.IMethod;
-import org.eclipse.jdt.core.IPackageFragment;
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.Signature;
-import org.eclipse.jdt.core.compiler.CharOperation;
-
-/**
- * Original code is from JDT Utility methods for the Java Model.
- */
-public final class JavaModelUtil {
-
- /**
- * Finds a type by its qualified type name (dot separated).
- *
- * @param jproject
- * The java project to search in
- * @param fullyQualifiedName
- * The fully qualified name (type name with enclosing type names
- * and package (all separated by dots))
- * @return The type found, or null if not existing
- * @throws JavaModelException
- */
- public static IType findType(IJavaProject jproject,
- String fullyQualifiedName) throws JavaModelException {
- // workaround for bug 22883
- IType type = jproject.findType(fullyQualifiedName);
- if (type != null) {
- return type;
- }
- IPackageFragmentRoot[] roots = jproject.getPackageFragmentRoots();
- for (int i = 0; i < roots.length; i++) {
- IPackageFragmentRoot root = roots[i];
- type = findType(root, fullyQualifiedName);
- if (type != null && type.exists()) {
- return type;
- }
- }
- return null;
- }
-
- /**
- * Returns <code>true</code> if the given package fragment root is
- * referenced. This means it is own by a different project but is referenced
- * by the root's parent. Returns <code>false</code> if the given root
- * doesn't have an underlying resource.
- * @param root
- * @return true if root is referenced
- */
- public static boolean isReferenced(IPackageFragmentRoot root) {
- IResource resource = root.getResource();
- if (resource != null) {
- IProject jarProject = resource.getProject();
- IProject container = root.getJavaProject().getProject();
- return !container.equals(jarProject);
- }
- return false;
- }
-
- private static IType findType(IPackageFragmentRoot root,
- String fullyQualifiedName) throws JavaModelException {
- IJavaElement[] children = root.getChildren();
- for (int i = 0; i < children.length; i++) {
- IJavaElement element = children[i];
- if (element.getElementType() == IJavaElement.PACKAGE_FRAGMENT) {
- IPackageFragment pack = (IPackageFragment) element;
- if (!fullyQualifiedName.startsWith(pack.getElementName())) {
- continue;
- }
- IType type = findType(pack, fullyQualifiedName);
- if (type != null && type.exists()) {
- return type;
- }
- }
- }
- return null;
- }
-
- private static IType findType(IPackageFragment pack,
- String fullyQualifiedName) throws JavaModelException {
- ICompilationUnit[] cus = pack.getCompilationUnits();
- for (int i = 0; i < cus.length; i++) {
- ICompilationUnit unit = cus[i];
- IType type = findType(unit, fullyQualifiedName);
- if (type != null && type.exists()) {
- return type;
- }
- }
- return null;
- }
-
- private static IType findType(ICompilationUnit cu, String fullyQualifiedName)
- throws JavaModelException {
- IType[] types = cu.getAllTypes();
- for (int i = 0; i < types.length; i++) {
- IType type = types[i];
- if (getFullyQualifiedName(type).equals(fullyQualifiedName)) {
- return type;
- }
- }
- return null;
- }
-
- /**
- * Finds a type by package and type name.
- *
- * @param jproject
- * the java project to search in
- * @param pack
- * The package name
- * @param typeQualifiedName
- * the type qualified name (type name with enclosing type names
- * (separated by dots))
- * @return the type found, or null if not existing
- * @throws JavaModelException
- * @deprecated Use IJavaProject.findType(String, String) instead
- */
- public static IType findType(IJavaProject jproject, String pack,
- String typeQualifiedName) throws JavaModelException {
- return jproject.findType(pack, typeQualifiedName);
- }
-
- /**
- * Finds a type container by container name. The returned element will be of
- * type <code>IType</code> or a <code>IPackageFragment</code>.
- * <code>null</code> is returned if the type container could not be found.
- *
- * @param jproject
- * The Java project defining the context to search
- * @param typeContainerName
- * A dot separarted name of the type container
- * @return the java element
- * @throws JavaModelException
- * @see #getTypeContainerName(IType)
- */
- public static IJavaElement findTypeContainer(IJavaProject jproject,
- String typeContainerName) throws JavaModelException {
- // try to find it as type
- IJavaElement result = jproject.findType(typeContainerName);
- if (result == null) {
- // find it as package
- IPath path = new Path(typeContainerName.replace('.', '/'));
- result = jproject.findElement(path);
- if (!(result instanceof IPackageFragment)) {
- result = null;
- }
-
- }
- return result;
- }
-
- /**
- * Finds a type in a compilation unit. Typical usage is to find the
- * corresponding type in a working copy.
- *
- * @param cu
- * the compilation unit to search in
- * @param typeQualifiedName
- * the type qualified name (type name with enclosing type names
- * (separated by dots))
- * @return the type found, or null if not existing
- * @throws JavaModelException
- */
- public static IType findTypeInCompilationUnit(ICompilationUnit cu,
- String typeQualifiedName) throws JavaModelException {
- IType[] types = cu.getAllTypes();
- for (int i = 0; i < types.length; i++) {
- String currName = getTypeQualifiedName(types[i]);
- if (typeQualifiedName.equals(currName)) {
- return types[i];
- }
- }
- return null;
- }
-
- /**
- * Finds a a member in a compilation unit. Typical usage is to find the
- * corresponding member in a working copy.
- *
- * @param cu
- * the compilation unit (eg. working copy) to search in
- * @param member
- * the member (eg. from the original)
- * @return the member found, or null if not existing
- */
- public static IMember findMemberInCompilationUnit(ICompilationUnit cu,
- IMember member) {
- IJavaElement[] elements = cu.findElements(member);
- if (elements != null && elements.length > 0) {
- return (IMember) elements[0];
- }
- return null;
- }
-
- /**
- * Returns the element of the given compilation unit which is "equal" to the
- * given element. Note that the given element usually has a parent different
- * from the given compilation unit.
- *
- * @param cu
- * the cu to search in
- * @param element
- * the element to look for
- * @return an element of the given cu "equal" to the given element
- */
- public static IJavaElement findInCompilationUnit(ICompilationUnit cu,
- IJavaElement element) {
- IJavaElement[] elements = cu.findElements(element);
- if (elements != null && elements.length > 0) {
- return elements[0];
- }
- return null;
- }
-
- /**
- * Returns the qualified type name of the given type using '.' as
- * separators. This is a replace for IType.getTypeQualifiedName() which uses
- * '$' as separators. As '$' is also a valid character in an id this is
- * ambiguous. JavaCore PR: 1GCFUNT
- * @param type
- * @return the type qualified name
- */
- public static String getTypeQualifiedName(IType type) {
- return type.getTypeQualifiedName('.');
- }
-
- /**
- * Returns the fully qualified name of the given type using '.' as
- * separators. This is a replace for IType.getFullyQualifiedTypeName which
- * uses '$' as separators. As '$' is also a valid character in an id this is
- * ambiguous. JavaCore PR: 1GCFUNT
- * @param type
- * @return the fully qualified name using . as the separator
- */
- public static String getFullyQualifiedName(IType type) {
- return type.getFullyQualifiedName('.');
- }
-
- /**
- * Returns the fully qualified name of a type's container. (package name or
- * enclosing type name)
- * @param type
- * @return the container name
- */
- public static String getTypeContainerName(IType type) {
- IType outerType = type.getDeclaringType();
- if (outerType != null) {
- return outerType.getFullyQualifiedName('.');
- }
- return type.getPackageFragment().getElementName();
- }
-
- /**
- * Concatenates two names. Uses a dot for separation. Both strings can be
- * empty or <code>null</code>.
- * @param name1
- * @param name2
- * @return name1 + name2
- */
- public static String concatenateName(String name1, String name2) {
- StringBuffer buf = new StringBuffer();
- if (name1 != null && name1.length() > 0) {
- buf.append(name1);
- }
- if (name2 != null && name2.length() > 0) {
- if (buf.length() > 0) {
- buf.append('.');
- }
- buf.append(name2);
- }
- return buf.toString();
- }
-
- /**
- * Concatenates two names. Uses a dot for separation. Both strings can be
- * empty or <code>null</code>.
- * @param name1
- * @param name2
- * @return name1 + name2
- */
- public static String concatenateName(char[] name1, char[] name2) {
- StringBuffer buf = new StringBuffer();
- if (name1 != null && name1.length > 0) {
- buf.append(name1);
- }
- if (name2 != null && name2.length > 0) {
- if (buf.length() > 0) {
- buf.append('.');
- }
- buf.append(name2);
- }
- return buf.toString();
- }
-
- /**
- * Evaluates if a member (possible from another package) is visible from
- * elements in a package.
- *
- * @param member
- * The member to test the visibility for
- * @param pack
- * The package in focus
- * @return true if visible
- * @throws JavaModelException
- */
- public static boolean isVisible(IMember member, IPackageFragment pack)
- throws JavaModelException {
-
- int type = member.getElementType();
- if (type == IJavaElement.INITIALIZER
- || (type == IJavaElement.METHOD && member.getElementName()
- .startsWith("<"))) { //$NON-NLS-1$
- //$NON-NLS-1$
- return false;
- }
-
- int otherflags = member.getFlags();
- IType declaringType = member.getDeclaringType();
- if (Flags.isPublic(otherflags)
- || (declaringType != null && declaringType.isInterface())) {
- return true;
- } else if (Flags.isPrivate(otherflags)) {
- return false;
- }
-
- IPackageFragment otherpack = (IPackageFragment) findParentOfKind(
- member, IJavaElement.PACKAGE_FRAGMENT);
- return (pack != null && otherpack != null && isSamePackage(pack,
- otherpack));
- }
-
- /**
- * Evaluates if a member in the focus' element hierarchy is visible from
- * elements in a package.
- *
- * @param member
- * The member to test the visibility for
- * @param pack
- * The package of the focus element focus
- * @return true if is visible in hiearchy
- * @throws JavaModelException
- */
- public static boolean isVisibleInHierarchy(IMember member,
- IPackageFragment pack) throws JavaModelException {
- int type = member.getElementType();
- if (type == IJavaElement.INITIALIZER
- || (type == IJavaElement.METHOD && member.getElementName()
- .startsWith("<"))) { //$NON-NLS-1$
- //$NON-NLS-1$
- return false;
- }
-
- int otherflags = member.getFlags();
-
- IType declaringType = member.getDeclaringType();
- if (Flags.isPublic(otherflags) || Flags.isProtected(otherflags)
- || (declaringType != null && declaringType.isInterface())) {
- return true;
- } else if (Flags.isPrivate(otherflags)) {
- return false;
- }
-
- IPackageFragment otherpack = (IPackageFragment) findParentOfKind(
- member, IJavaElement.PACKAGE_FRAGMENT);
- return (pack != null && pack.equals(otherpack));
- }
-
- /**
- * Returns the package fragment root of <code>IJavaElement</code>. If the
- * given element is already a package fragment root, the element itself is
- * returned.
- * @param element
- * @return the package fragment root
- */
- public static IPackageFragmentRoot getPackageFragmentRoot(
- IJavaElement element) {
- return (IPackageFragmentRoot) element
- .getAncestor(IJavaElement.PACKAGE_FRAGMENT_ROOT);
- }
-
- /**
- * Returns the parent of the supplied java element that conforms to the
- * given parent type or <code>null</code>, if such a parent doesn't exit.
- *
- * @deprecated Use element.getParent().getAncestor(kind);
- */
- private static IJavaElement findParentOfKind(IJavaElement element, int kind) {
- if (element != null && element.getParent() != null) {
- return element.getParent().getAncestor(kind);
- }
- return null;
- }
-
- /**
- * Finds a method in a type. This searches for a method with the same name
- * and signature. Parameter types are only compared by the simple name, no
- * resolving for the fully qualified type name is done. Constructors are
- * only compared by parameters, not the name.
- *
- * @param name
- * The name of the method to find
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param isConstructor
- * If the method is a constructor
- * @param type
- * @return The first found method or <code>null</code>, if nothing found
- * @throws JavaModelException
- */
- public static IMethod findMethod(String name, String[] paramTypes,
- boolean isConstructor, IType type) throws JavaModelException {
- return findMethod(name, paramTypes, isConstructor, type.getMethods());
- }
-
- /**
- * Finds a method by name. This searches for a method with a name and
- * signature. Parameter types are only compared by the simple name, no
- * resolving for the fully qualified type name is done. Constructors are
- * only compared by parameters, not the name.
- *
- * @param name
- * The name of the method to find
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param isConstructor
- * If the method is a constructor
- * @param methods
- * The methods to search in
- * @return The found method or <code>null</code>, if nothing found
- * @throws JavaModelException
- */
- public static IMethod findMethod(String name, String[] paramTypes,
- boolean isConstructor, IMethod[] methods) throws JavaModelException {
- for (int i = methods.length - 1; i >= 0; i--) {
- if (isSameMethodSignature(name, paramTypes, isConstructor,
- methods[i])) {
- return methods[i];
- }
- }
- return null;
- }
-
- /**
- * Finds a method declararion in a type's hierarchy. The search is top down,
- * so this returns the first declaration of the method in the hierarchy.
- * This searches for a method with a name and signature. Parameter types are
- * only compared by the simple name, no resolving for the fully qualified
- * type name is done. Constructors are only compared by parameters, not the
- * name.
- * @param hierarchy
- *
- * @param type
- * Searches in this type's supertypes.
- * @param name
- * The name of the method to find
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param isConstructor
- * If the method is a constructor
- * @return The first method found or null, if nothing found
- * @throws JavaModelException
- */
- public static IMethod findMethodDeclarationInHierarchy(
- ITypeHierarchy hierarchy, IType type, String name,
- String[] paramTypes, boolean isConstructor)
- throws JavaModelException {
- IType[] superTypes = hierarchy.getAllSupertypes(type);
- for (int i = superTypes.length - 1; i >= 0; i--) {
- IMethod first = findMethod(name, paramTypes, isConstructor,
- superTypes[i]);
- if (first != null && !Flags.isPrivate(first.getFlags())) {
- // the order getAllSupertypes does make assumptions of the order
- // of inner elements -> search recursivly
- IMethod res = findMethodDeclarationInHierarchy(hierarchy, first
- .getDeclaringType(), name, paramTypes, isConstructor);
- if (res != null) {
- return res;
- }
- return first;
- }
- }
- return null;
- }
-
- /**
- * Finds a method implementation in a type's classhierarchy. The search is
- * bottom-up, so this returns the nearest overridden method. Does not find
- * methods in interfaces or abstract methods. This searches for a method
- * with a name and signature. Parameter types are only compared by the
- * simple name, no resolving for the fully qualified type name is done.
- * Constructors are only compared by parameters, not the name.
- * @param hierarchy
- *
- * @param type
- * Type to search the superclasses
- * @param name
- * The name of the method to find
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param isConstructor
- * If the method is a constructor
- * @return The first method found or null, if nothing found
- * @throws JavaModelException
- */
- public static IMethod findMethodImplementationInHierarchy(
- ITypeHierarchy hierarchy, IType type, String name,
- String[] paramTypes, boolean isConstructor)
- throws JavaModelException {
- IType[] superTypes = hierarchy.getAllSuperclasses(type);
- for (int i = 0; i < superTypes.length; i++) {
- IMethod found = findMethod(name, paramTypes, isConstructor,
- superTypes[i]);
- if (found != null) {
- if (Flags.isAbstract(found.getFlags())) {
- return null;
- }
- return found;
- }
- }
- return null;
- }
-
- private static IMethod findMethodInHierarchy(ITypeHierarchy hierarchy,
- IType type, String name, String[] paramTypes, boolean isConstructor)
- throws JavaModelException {
- IMethod method = findMethod(name, paramTypes, isConstructor, type);
- if (method != null) {
- return method;
- }
- IType superClass = hierarchy.getSuperclass(type);
- if (superClass != null) {
- IMethod res = findMethodInHierarchy(hierarchy, superClass, name,
- paramTypes, isConstructor);
- if (res != null) {
- return res;
- }
- }
- if (!isConstructor) {
- IType[] superInterfaces = hierarchy.getSuperInterfaces(type);
- for (int i = 0; i < superInterfaces.length; i++) {
- IMethod res = findMethodInHierarchy(hierarchy,
- superInterfaces[i], name, paramTypes, false);
- if (res != null) {
- return res;
- }
- }
- }
- return method;
- }
-
- /**
- * Finds the method that is defines/declares the given method. The search is
- * bottom-up, so this returns the nearest defining/declaring method.
- * @param typeHierarchy
- * @param type
- * @param methodName
- * @param paramTypes
- * @param isConstructor
- *
- * @param testVisibility
- * If true the result is tested on visibility. Null is returned
- * if the method is not visible.
- * @return the method or null
- * @throws JavaModelException
- */
- public static IMethod findMethodDefininition(ITypeHierarchy typeHierarchy,
- IType type, String methodName, String[] paramTypes,
- boolean isConstructor, boolean testVisibility)
- throws JavaModelException {
- IType superClass = typeHierarchy.getSuperclass(type);
- if (superClass != null) {
- IMethod res = findMethodInHierarchy(typeHierarchy, superClass,
- methodName, paramTypes, isConstructor);
- if (res != null && !Flags.isPrivate(res.getFlags())) {
- if (!testVisibility
- || isVisibleInHierarchy(res, type.getPackageFragment())) {
- return res;
- }
- }
- }
- if (!isConstructor) {
- IType[] interfaces = typeHierarchy.getSuperInterfaces(type);
- for (int i = 0; i < interfaces.length; i++) {
- IMethod res = findMethodInHierarchy(typeHierarchy,
- interfaces[i], methodName, paramTypes, false);
- if (res != null) {
- return res; // methods from interfaces are always public and
- // therefore visible
- }
- }
- }
- return null;
- }
-
- /**
- * Tests if a method equals to the given signature. Parameter types are only
- * compared by the simple name, no resolving for the fully qualified type
- * name is done. Constructors are only compared by parameters, not the name.
- *
- * @param name
- * Name of the method
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param isConstructor
- * Specifies if the method is a constructor
- * @param curr
- * @return Returns <code>true</code> if the method has the given name and
- * parameter types and constructor state.
- * @throws JavaModelException
- */
- public static boolean isSameMethodSignature(String name,
- String[] paramTypes, boolean isConstructor, IMethod curr)
- throws JavaModelException {
- if (isConstructor || name.equals(curr.getElementName())) {
- if (isConstructor == curr.isConstructor()) {
- String[] currParamTypes = curr.getParameterTypes();
- if (paramTypes.length == currParamTypes.length) {
- for (int i = 0; i < paramTypes.length; i++) {
- String t1 = Signature.getSimpleName(Signature
- .toString(paramTypes[i]));
- String t2 = Signature.getSimpleName(Signature
- .toString(currParamTypes[i]));
- if (!t1.equals(t2)) {
- return false;
- }
- }
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * Tests if two <code>IPackageFragment</code>s represent the same logical
- * java package.
- * @param pack1
- * @param pack2
- *
- * @return <code>true</code> if the package fragments' names are equal.
- */
- public static boolean isSamePackage(IPackageFragment pack1,
- IPackageFragment pack2) {
- return pack1.getElementName().equals(pack2.getElementName());
- }
-
- /**
- * Checks whether the given type has a valid main method or not.
- * @param type
- * @return true if type has a main method
- * @throws JavaModelException
- */
- public static boolean hasMainMethod(IType type) throws JavaModelException {
- IMethod[] methods = type.getMethods();
- for (int i = 0; i < methods.length; i++) {
- if (methods[i].isMainMethod()) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Checks if the field is boolean.
- * @param field
- * @return true if the file is of primitive boolean type
- * @throws JavaModelException
- */
- public static boolean isBoolean(IField field) throws JavaModelException {
- return field.getTypeSignature().equals(Signature.SIG_BOOLEAN);
- }
-
- /**
- * Tests if the given element is on the class path of its containing
- * project. Handles the case that the containing project isn't a Java
- * project.
- * @param element
- * @return true if element in on the class path?
- */
- public static boolean isOnClasspath(IJavaElement element) {
- IJavaProject project = element.getJavaProject();
- if (!project.exists())
- return false;
- return project.isOnClasspath(element);
- }
-
- /**
- * Resolves a type name in the context of the declaring type.
- *
- * @param refTypeSig
- * the type name in signature notation (for example 'QVector')
- * this can also be an array type, but dimensions will be
- * ignored.
- * @param declaringType
- * the context for resolving (type where the reference was made
- * in)
- * @return returns the fully qualified type name or build-in-type name. if a
- * unresoved type couldn't be resolved null is returned
- * @throws JavaModelException
- */
- public static String getResolvedTypeName(String refTypeSig,
- IType declaringType) throws JavaModelException {
- int arrayCount = Signature.getArrayCount(refTypeSig);
- char type = refTypeSig.charAt(arrayCount);
- if (type == Signature.C_UNRESOLVED) {
- int semi = refTypeSig
- .indexOf(Signature.C_SEMICOLON, arrayCount + 1);
- if (semi == -1) {
- throw new IllegalArgumentException();
- }
- String name = refTypeSig.substring(arrayCount + 1, semi);
-
- String[][] resolvedNames = declaringType.resolveType(name);
- if (resolvedNames != null && resolvedNames.length > 0) {
- return JavaModelUtil.concatenateName(resolvedNames[0][0],
- resolvedNames[0][1]);
- }
- return null;
- }
- return Signature.toString(refTypeSig.substring(arrayCount));
- }
-
- /**
- * Returns if a CU can be edited.
- * @param cu
- * @return true if cu is editable
- */
- public static boolean isEditable(ICompilationUnit cu) {
- IResource resource = toOriginal(cu).getResource();
- return (resource.exists() && !resource.getResourceAttributes()
- .isReadOnly());
- }
-
- /**
- * Finds a qualified import for a type name.
- * @param cu
- * @param simpleName
- * @return the import declaration or null
- * @throws JavaModelException
- */
- public static IImportDeclaration findImport(ICompilationUnit cu,
- String simpleName) throws JavaModelException {
- IImportDeclaration[] existing = cu.getImports();
- for (int i = 0; i < existing.length; i++) {
- String curr = existing[i].getElementName();
- if (curr.endsWith(simpleName)) {
- int dotPos = curr.length() - simpleName.length() - 1;
- if ((dotPos == -1)
- || (dotPos > 0 && curr.charAt(dotPos) == '.')) {
- return existing[i];
- }
- }
- }
- return null;
- }
-
- /**
- * Returns the original if the given member. If the member is already an
- * original the input is returned. The returned member might not exist
- * @param member
- * @return the original IMember
- */
- public static IMember toOriginal(IMember member) {
- if (member instanceof IMethod) {
- return toOriginalMethod((IMethod) member);
- }
-
- return (IMember) member.getPrimaryElement();
- /*
- * ICompilationUnit cu= member.getCompilationUnit(); if (cu != null &&
- * cu.isWorkingCopy()) return (IMember)cu.getOriginal(member); return
- * member;
- */
- }
-
- /*
- * XXX workaround for bug 18568
- * http://bugs.eclipse.org/bugs/show_bug.cgi?id=18568 to be removed once the
- * bug is fixed
- */
- private static IMethod toOriginalMethod(IMethod method) {
- ICompilationUnit cu = method.getCompilationUnit();
- if (cu == null || isPrimary(cu)) {
- return method;
- }
- try {
- // use the workaround only if needed
- if (!method.getElementName().equals(
- method.getDeclaringType().getElementName()))
- return (IMethod) method.getPrimaryElement();
-
- IType originalType = (IType) toOriginal(method.getDeclaringType());
- IMethod[] methods = originalType.findMethods(method);
- boolean isConstructor = method.isConstructor();
- for (int i = 0; i < methods.length; i++) {
- if (methods[i].isConstructor() == isConstructor)
- return methods[i];
- }
- return null;
- } catch (JavaModelException e) {
- return null;
- }
- }
-
- // private static boolean PRIMARY_ONLY = false;
-
- /**
- * Returns the original cu if the given cu is a working copy. If the cu is
- * already an original the input cu is returned. The returned cu might not
- * exist
- * @param cu
- * @return the original compiliation unit
- */
- public static ICompilationUnit toOriginal(ICompilationUnit cu) {
- // To stay compatible with old version returned null
- // if cu is null
- if (cu == null)
- return cu;
- return cu.getPrimary();
- }
-
- /**
- * Returns the original element if the given element is a working copy. If
- * the cu is already an original the input element is returned. The returned
- * element might not exist
- * @param element
- * @return element's primary element
- */
- public static IJavaElement toOriginal(IJavaElement element) {
- return element.getPrimaryElement();
- }
-
- /**
- * Returns true if a cu is a primary cu (original or shared working copy)
- * @param cu
- * @return true if cu is primary
- */
- public static boolean isPrimary(ICompilationUnit cu) {
- return cu.getOwner() == null;
- }
-
- /**
- * http://bugs.eclipse.org/bugs/show_bug.cgi?id=19253
- *
- * Reconciling happens in a separate thread. This can cause a situation
- * where the Java element gets disposed after an exists test has been done.
- * So we should not log not present exceptions when they happen in working
- * copies.
- * @param exception
- * @return true if filter not present
- */
- public static boolean filterNotPresentException(CoreException exception) {
- if (!(exception instanceof JavaModelException)) {
- return true;
- }
- JavaModelException je = (JavaModelException) exception;
- if (!je.isDoesNotExist()) {
- return true;
- }
- IJavaElement[] elements = je.getJavaModelStatus().getElements();
- for (int i = 0; i < elements.length; i++) {
- IJavaElement element = elements[i];
- ICompilationUnit unit = (ICompilationUnit) element
- .getAncestor(IJavaElement.COMPILATION_UNIT);
- if (unit == null) {
- return true;
- }
- if (!unit.isWorkingCopy()) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * @param type
- * @param pm
- * @return all supertypes of type
- * @throws JavaModelException
- */
- public static IType[] getAllSuperTypes(IType type, IProgressMonitor pm)
- throws JavaModelException {
- // workaround for 23656
- Set types = new HashSet(Arrays.asList(type.newSupertypeHierarchy(pm)
- .getAllSupertypes(type)));
- IType objekt = type.getJavaProject().findType("java.lang.Object");//$NON-NLS-1$
- if (objekt != null) {
- types.add(objekt);
- }
- return (IType[]) types.toArray(new IType[types.size()]);
- }
-
- /**
- * @param resourcePath
- * @param exclusionPatterns
- * @return true if resourcePath is excluded by exclusion patterns
- */
- public static boolean isExcludedPath(IPath resourcePath,
- IPath[] exclusionPatterns) {
- char[] path = resourcePath.toString().toCharArray();
- for (int i = 0, length = exclusionPatterns.length; i < length; i++) {
- char[] pattern = exclusionPatterns[i].toString().toCharArray();
- if (CharOperation.pathMatch(pattern, path, true, '/')) {
- return true;
- }
- }
- return false;
- }
-
- /*
-
- * @see IClasspathEntry#getExclusionPatterns
- */
- /**
- * Returns whether the given resource path matches one of the exclusion
- * patterns.
- *
- * @param resourcePath
- * @param exclusionPatterns
- * @return true if resourcePath is excluded
- */
- public static boolean isExcluded(IPath resourcePath,
- char[][] exclusionPatterns) {
- if (exclusionPatterns == null) {
- return false;
- }
- char[] path = resourcePath.toString().toCharArray();
- for (int i = 0, length = exclusionPatterns.length; i < length; i++) {
- if (CharOperation.pathMatch(exclusionPatterns[i], path, true, '/')) {
- return true;
- }
- }
- return false;
- }
-
- private static Boolean fgIsJDTCore_1_5 = null;
-
- /**
- * @return true if JRE 1.5 in enabled.
- */
- public static boolean isJDTCore_1_5() {
- if (fgIsJDTCore_1_5 == null) {
- fgIsJDTCore_1_5 = JavaCore
- .getDefaultOptions()
- .containsKey(
- "org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation") ? Boolean.TRUE //$NON-NLS-1$
- : Boolean.FALSE;
- }
- return fgIsJDTCore_1_5.booleanValue();
- }
-
- /**
- * Helper method that tests if an classpath entry can be found in a
- * container. <code>null</code> is returned if the entry can not be found
- * or if the container does not allows the configuration of source
- * attachments
- *
- * @param jproject
- * The container's parent project
- * @param containerPath
- * The path of the container
- * @param libPath
- * The path of the library to be found
- * @return IClasspathEntry A classpath entry from the container of
- * <code>null</code> if the container can not be modified.
- * @throws JavaModelException
- */
- public static IClasspathEntry getClasspathEntryToEdit(
- IJavaProject jproject, IPath containerPath, IPath libPath)
- throws JavaModelException {
- IClasspathContainer container = JavaCore.getClasspathContainer(
- containerPath, jproject);
- ClasspathContainerInitializer initializer = JavaCore
- .getClasspathContainerInitializer(containerPath.segment(0));
- if (container != null
- && initializer != null
- && initializer.canUpdateClasspathContainer(containerPath,
- jproject)) {
- IClasspathEntry[] entries = container.getClasspathEntries();
- for (int i = 0; i < entries.length; i++) {
- IClasspathEntry curr = entries[i];
- IClasspathEntry resolved = JavaCore
- .getResolvedClasspathEntry(curr);
- if (resolved != null && libPath.equals(resolved.getPath())) {
- return curr; // return the real entry
- }
- }
- }
- return null; // attachment not possible
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PathUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PathUtil.java
deleted file mode 100644
index 8eebe903d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PathUtil.java
+++ /dev/null
@@ -1,307 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.io.File;
-import java.util.StringTokenizer;
-
-import org.eclipse.core.resources.IContainer;
-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.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJarEntryResource;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Collection of helper methods to manage and convert links Originally part of
- * the LinksManager (com.ibm.iwt.parser.util)
- */
-public final class PathUtil {
- private static final String FORWARD_SLASH = "/"; //$NON-NLS-1$
-
- private static final String RELATIVE_PATH_SIGNAL = IFileFolderConstants.DOT
- + IFileFolderConstants.DOT + IFileFolderConstants.PATH_SEPARATOR;
-
- /**
- * adjust relative path isside the absolute path
- * @param path
- * @return the adjusted path
- */
- public static String adjustPath(String path) {
- int i = 0;
- while ((i = path.indexOf(RELATIVE_PATH_SIGNAL)) > 0) {
- // split the string into two
- String part1 = path.substring(0, i - 1);
- String part2 = path
- .substring(i + RELATIVE_PATH_SIGNAL.length() - 1);
- // strip one path seg from part1
- int j = part1.lastIndexOf(FORWARD_SLASH);
- if (j == -1) {
- return "";//$NON-NLS-1$
- }
- part1 = part1.substring(0, j);
- path = part1 + part2;
- }
- return path;
- }
-
- /**
- * Append trailing url slash if needed
- * @param input
- * @return the string
- */
- public static String appendTrailingURLSlash(String input) {
- // check to see already a slash
- if (!input.endsWith(FORWARD_SLASH)) {
- input += FORWARD_SLASH;
- }
- return input;
- }
-
- /**
- * Convert to relative url based on base
- * @param input
- * @param base
- * @return the string
- */
- public static String convertToRelativePath(String input, String base) {
- // tokenize the strings
- StringTokenizer inputTokenizer = new StringTokenizer(input,
- FORWARD_SLASH);
- StringTokenizer baseTokenizer = new StringTokenizer(base, FORWARD_SLASH);
- String token1 = "", token2 = "";//$NON-NLS-2$//$NON-NLS-1$
- //
- // Go through until equls
- while (true) {
- if (!inputTokenizer.hasMoreTokens()
- || !baseTokenizer.hasMoreTokens()) {
- break;
- }
- token1 = baseTokenizer.nextToken();
- token2 = inputTokenizer.nextToken();
- if (!token1.equals(token2)) {
- break;
- }
- }
- // now generate the backs
- String output = "";//$NON-NLS-1$
- while (baseTokenizer.hasMoreTokens()) {
- baseTokenizer.nextToken();
- output += RELATIVE_PATH_SIGNAL;
- }
- output += token2;
- // generate the rest
- while (inputTokenizer.hasMoreTokens()) {
- output = output + FORWARD_SLASH + inputTokenizer.nextToken();
- }
- return output;
- }
-
- /**
- * @param projectName
- * @param path
- * @return the path in the project converted to a path relative to the
- * web folder
- */
- public static String convertToWebPath(String projectName, String path) {
- String name = ""; //$NON-NLS-1$
- IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(
- projectName);
- String webrootName = WebrootUtil.getWebContentFolder(project).getName();
-
- if (path.indexOf(webrootName) != -1) {
- name = projectName + IFileFolderConstants.PATH_SEPARATOR
- + webrootName;
- } else {
- name = projectName;
- }
- int index = path.indexOf(projectName);
-
- return path.substring(index + name.length());
- }
-
- /**
- * convert path relative to current active file to absolute path in
- * filesystem
- *
- * @param uri
- * the relative path
- * @param curFile
- * @return absolute path in file system
- */
- public static String convertToAbsolutePath(String uri, IFile curFile) {
- if (uri == null || uri.trim().equals("")) { //$NON-NLS-1$
- return uri;
- }
- String webroot = ""; //$NON-NLS-1$
- IFile jsp = curFile;
- try {
- if (jsp == null) {
- jsp = ((IFileEditorInput) getActivePage()
- .getActiveEditor().getEditorInput()).getFile();
- }
- if (jsp != null) {
- String webrootName = WebrootUtil.getWebContentFolder(
- jsp.getProject()).getName();
- webroot = jsp.getProject().getFolder(webrootName).getLocation()
- .toString();
- }
- } catch (NullPointerException e) {
- return uri;
- }
- if (uri.startsWith(IFileFolderConstants.PATH_SEPARATOR))
- {
- return webroot + uri;
- }
- if (jsp != null) {
- IContainer con = jsp.getParent();
- if (con != null) {
- IPath path = con.getLocation();
- if (path != null) {
- String aPath = path.toString() + File.separator + uri;
- aPath = aPath.replace('/', File.separatorChar);
- aPath = aPath.replace('\\', File.separatorChar);
- if (aPath.endsWith(File.separator)) {
- aPath += IFileFolderConstants.PATH_SEPARATOR;
- }
- File file = new File(aPath);
- if (file.exists() && file.isFile()) {
- return file.getAbsolutePath();
- }
- return uri;
- }
- }
- }
- return uri;
- }
-
- /**
- * Returns the active workbench window.
- *
- * @return the active workbench window. this can be null but I've never seen
- * it.
- */
- private static IWorkbenchWindow getActiveWorkbenchWindow() {
- if (PlatformUI.getWorkbench() == null) {
- return null;
- }
- return PlatformUI.getWorkbench().getActiveWorkbenchWindow();
- }
-
- /**
- * Returns the active workbench page. Note that the active page may not be
- * the one that the user perceives as active in some situations so this
- * method of obtaining the activate page should only be used if no other
- * method is available.
- *
- * @return the active workbench page
- */
- private static IWorkbenchPage getActivePage() {
- IWorkbenchWindow window = getActiveWorkbenchWindow();
- if (window == null) {
- return null;
- }
- return window.getActivePage();
- }
- /**
- * @param javaProject
- * @param parent
- * @return the IPath for a a classpath object (?)
- */
- public static IPath getPathOnClasspath(IJavaProject javaProject,
- Object parent) {
- IPath result = null;
- if (javaProject == null || parent == null) {
- return new Path(""); //$NON-NLS-1$
- }
- IClasspathEntry[] entries = javaProject.readRawClasspath();
- IPath classPath = null;
- if (parent instanceof IResource) {
- if (((javaProject != null) && !javaProject
- .isOnClasspath((IResource) parent))) {
- return new Path(""); //$NON-NLS-1$
- }
- if (parent instanceof IFile) {
- IPath elementPath = ((IFile) parent).getFullPath();
- if (((IFile) parent).getFileExtension().equalsIgnoreCase(
- IFileFolderConstants.EXT_PROPERTIES)) {
- int machings = 0;
- try {
- for (int i = 0; i < entries.length; i++) {
- // Determine whether on this classentry's path
- int n = entries[i].getPath().matchingFirstSegments(
- elementPath);
- if (n > machings) {
- // Get package name
- machings = n;
- classPath = elementPath.removeFirstSegments(
- machings).removeLastSegments(1);
- }
- }
-
- // Not on the classpath?
- if (classPath == null) {
- return null;
- } else if (classPath.segmentCount() > 0) {
- IJavaElement element = javaProject
- .findElement(classPath);
- if (element != null) {
- IPath path = element.getPath();
- if (path != null) {
- IPath path1 = path
- .removeFirstSegments(machings);
-
- String fileName = ((IFile) parent)
- .getName();
- if (fileName != null) {
- result = path1.append(fileName);
- }
- }
- }
-
- } else {
- result = ((IFile) parent).getFullPath()
- .removeFirstSegments(machings);
- }
- } catch (Exception e) {
- return null;
- }
- }
- }
- } else if (parent instanceof IJarEntryResource) {
- IPath elementPath = ((IJarEntryResource) parent).getFullPath();
- if (elementPath.getFileExtension().equalsIgnoreCase(
- IFileFolderConstants.EXT_PROPERTIES)) {
- result = elementPath;
- }
- }
- if (result != null) {
- return result;
- }
- return new Path(""); //$NON-NLS-1$
- }
-
- private PathUtil()
- {
- // utility class, no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PixelConverter.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PixelConverter.java
deleted file mode 100644
index 48d5b3749..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PixelConverter.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 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
- * Oracle -- copied into common ui codebase for JSF use
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontMetrics;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.widgets.Control;
-
-import org.eclipse.jface.dialogs.Dialog;
-
-/**
- * @author cbateman
- *
- */
-public class PixelConverter {
-
- private final FontMetrics fFontMetrics;
-
- /**
- * @param control
- */
- public PixelConverter(Control control) {
- this(control.getFont());
- }
-
- /**
- * @param font
- */
- public PixelConverter(Font font) {
- GC gc = new GC(font.getDevice());
- gc.setFont(font);
- fFontMetrics= gc.getFontMetrics();
- gc.dispose();
- }
-
-
- /**
- * @param chars
- * @return the convert height in pixels
- */
- public int convertHeightInCharsToPixels(int chars) {
- return Dialog.convertHeightInCharsToPixels(fFontMetrics, chars);
- }
-
- /**
- * @param dlus
- * @return the pixel
- */
- public int convertHorizontalDLUsToPixels(int dlus) {
- return Dialog.convertHorizontalDLUsToPixels(fFontMetrics, dlus);
- }
-
- /**
- * @param dlus
- * @return the vertical pixels
- */
- public int convertVerticalDLUsToPixels(int dlus) {
- return Dialog.convertVerticalDLUsToPixels(fFontMetrics, dlus);
- }
-
-
- /**
- * @param chars
- * @return the pixel value
- */
- public int convertWidthInCharsToPixels(int chars) {
- return Dialog.convertWidthInCharsToPixels(fFontMetrics, chars);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PluginImageHelper.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PluginImageHelper.java
deleted file mode 100644
index 8ebcd0354..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PluginImageHelper.java
+++ /dev/null
@@ -1,213 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.util.HashMap;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-
-/**
- * @author mengbo
- */
-public class PluginImageHelper {
- private static PluginImageHelper _instance = null;
-
- /**
- * Gets the instance.
- *
- * @return Returns a TaglibPluginImageHelper
- */
- public synchronized static PluginImageHelper getInstance() {
- if (_instance == null) {
- _instance = new PluginImageHelper();
- }
- return _instance;
- }
-
- // save a descriptor for each image
- private HashMap _imageDescRegistry = null;
-
- private final String PLUGIN_SEPARATOR = "^"; //$NON-NLS-1$
-
- /**
- * Creates an image from the given resource and adds the image to the image
- * registry.
- *
- * @param resource
- * @param pluginId
- * @return Image
- */
- private Image createImage(String resource, String pluginId) {
- ImageDescriptor desc = getImageDescriptor(resource, pluginId);
- Image image = null;
-
- if (desc != null) {
- image = desc.createImage();
-
- // dont add the missing image descriptor image to the image
- // registry
- if (!desc.equals(ImageDescriptor.getMissingImageDescriptor())) {
- String thePluginId = pluginId;
- if (thePluginId == null) {
- return null;
- }
- String key = thePluginId + PLUGIN_SEPARATOR + resource;
- getImageRegistry().put(key, image);
- }
- }
- return image;
- }
-
- /**
- * Creates an image descriptor from the given imageFilePath in the given
- * pluginId and adds the image descriptor to the image descriptor registry.
- * If an image descriptor could not be created, the default "missing" image
- * descriptor is returned but not added to the image descriptor registry.
- *
- * @param imageFilePath
- * @param pluginId
- * if null, look in this plugin
- * @return ImageDescriptor image descriptor for imageFilePath or default
- * "missing" image descriptor if resource could not be found
- */
- private ImageDescriptor createImageDescriptor(String imageFilePath,
- String pluginId) {
- String thePluginId = pluginId;
- if (thePluginId == null) {
- return null;
- }
-
- ImageDescriptor imageDescriptor = AbstractUIPlugin
- .imageDescriptorFromPlugin(thePluginId, imageFilePath);
- if (imageDescriptor != null) {
- String key = thePluginId + PLUGIN_SEPARATOR + imageFilePath;
- getImageDescriptorRegistry().put(key, imageDescriptor);
- } else {
- imageDescriptor = ImageDescriptor.getMissingImageDescriptor();
- }
-
- return imageDescriptor;
- }
-
- /**
- * Retrieves the image associated with resource from the image registry. If
- * the image cannot be retrieved, attempt to find and load the image at the
- * location specified in resource.
- *
- * @param resource
- * the image to retrieve
- * @return Image the image associated with resource or null if one could not
- * be found
- */
- public Image getImage(String resource) {
- return getImage(resource, null);
- }
-
- /**
- * Retrieves the image associated with resource from the image registry. If
- * the image cannot be retrieved, attempt to find and load the image at the
- * location specified in resource.
- *
- * @param resource
- * the image to retrieve
- * @param pluginId
- * @return Image the image associated with resource or null if one could not
- * be found
- */
- public Image getImage(String resource, String pluginId) {
- String thePluginId = pluginId;
- if (thePluginId == null) {
- return null;
- }
-
- String key = thePluginId + PLUGIN_SEPARATOR + resource;
-
- Image image = getImageRegistry().get(key);
- if (image == null) {
- // create an image
- image = createImage(resource, pluginId);
- }
- return image;
- }
-
- /**
- * Retrieves the image descriptor associated with resource from the image
- * descriptor registry. If the image descriptor cannot be retrieved, attempt
- * to find and load the image descriptor at the location specified in
- * resource.
- *
- * @param resource
- * the image descriptor to retrieve
- * @return ImageDescriptor the image descriptor assocated with resource or
- * the default "missing" image descriptor if one could not be found
- */
- public ImageDescriptor getImageDescriptor(String resource) {
- return getImageDescriptor(resource, null);
- }
-
- /**
- * Retrieves the image descriptor associated with resource in pluginId from
- * the image descriptor registry. If the image descriptor cannot be
- * retrieved, attempt to find and load the image descriptor at the location
- * specified in resource in pluginId.
- *
- * @param resource
- * the image descriptor to retrieve
- * @param pluginId
- * the plugin the resource is located. if null, use look in this
- * plugin
- * @return ImageDescriptor the image descriptor assocated with resource or
- * the default "missing" image descriptor if one could not be found
- */
- public ImageDescriptor getImageDescriptor(String resource, String pluginId) {
- ImageDescriptor imageDescriptor = null;
- String thePluginId = pluginId;
- if (thePluginId == null) {
- return null;
- }
-
- String key = thePluginId + PLUGIN_SEPARATOR + resource;
- Object o = getImageDescriptorRegistry().get(key);
- if (o == null) {
- // create a descriptor
- imageDescriptor = createImageDescriptor(resource, pluginId);
- } else {
- imageDescriptor = (ImageDescriptor) o;
- }
- return imageDescriptor;
- }
-
- /**
- * Returns the image descriptor registry for this plugin.
- *
- * @return HashMap - image descriptor registry for this plugin
- */
- private HashMap getImageDescriptorRegistry() {
- if (_imageDescRegistry == null) {
- _imageDescRegistry = new HashMap();
- }
- return _imageDescRegistry;
- }
-
- /**
- * Returns the image registry for this plugin.
- *
- * @return ImageRegistry - image registry for this plugin
- */
- private ImageRegistry getImageRegistry() {
- return JFaceResources.getImageRegistry();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PropertyUtils.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PropertyUtils.java
deleted file mode 100644
index 47bded01a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PropertyUtils.java
+++ /dev/null
@@ -1,789 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.awt.Component;
-import java.awt.Dimension;
-import java.awt.Point;
-import java.awt.Rectangle;
-import java.awt.Toolkit;
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.MissingResourceException;
-import java.util.Properties;
-import java.util.ResourceBundle;
-import java.util.StringTokenizer;
-
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-
-/**
- * The main purpose of this class is to give better access methods for property
- * and resource bundle access.
- *
- * @author mengbo
- */
-public final class PropertyUtils {
-
- private static final String ENCODED_CHAR_PERCENT = "%25"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_CARRIAGE_RETURN = "%0d"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_TAB = "%09"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_NEWLINE = "%0a"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_SPACE = "%20"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_COLON = "%3a"; //$NON-NLS-1$
- private static final String ENCODED_CHAR_EQUALS = "%3d"; //$NON-NLS-1$
-
-
- // WARNING: There can be NO static logging line here since the logger uses
- // this class to figure out the preferences
- // for the logging system. "Logging" an error here would be useless since
- // you might be setting up the logging system
- // via a call to PropertyUtils.getServerProperty() instead it uses
- // "System.err.println".
-
- // This is the name for the properties file.
- // The prop-name will be prepended to this string....
- private static final String NAME_PROPERTIES = ".props"; //$NON-NLS-1$
-
- private static final String STR_BOUNDS_END = ".bounds"; // assumes the //$NON-NLS-1$
-
- // window name or
- // name list is
- // prepended
-
- // //////////////////////////////////////////////////////////////////////////
- // Property get methods.
- // //////////////////////////////////////////////////////////////////////////
- /**
- * @param props
- * @param key
- * @param theDefault
- * @return the property
- */
- public static String getProperty(Properties props, String key,
- String theDefault) {
- try {
- String value = props.getProperty(key, theDefault);
- if ((value != null) && (value.length() == 0)) {
- value = null;
- }
- // check again for null, since some versions of the jdk ignore the
- // default
- // if an empty property exists.
- if (value == null) {
- value = theDefault;
- }
- return value;
- } catch (Exception ee) {
- return theDefault;
- }
- }
-
- /**
- * @param props
- * @param key
- * @return the value for key in props, may return null
- */
- public static String getProperty(Properties props, String key) {
- try {
- String value = props.getProperty(key);
- if ((value != null) && (value.length() == 0)) {
- value = null;
- }
- return value;
- } catch (Exception ee) {
- return null;
- }
- }
-
- /**
- * @param props
- * @param key
- * @param defaultValue
- * @param minimumValue
- * @return the integer property value for key, or defaultValue
- * if none. Enforces minimumValue in all cases
- */
- public static int getPropertyValue(Properties props, String key,
- int defaultValue, int minimumValue) {
- int theValue = getPropertyValue(props, key, defaultValue);
-
- if (theValue < minimumValue) {
- theValue = minimumValue;
- }
- return theValue;
- }
-
- /**
- * @param props
- * @param key
- * @param defaultValue
- * @return the integer value for key in props or defaultValue if none
- */
- public static int getPropertyValue(Properties props, String key,
- int defaultValue) {
- String stringValue = getProperty(props, key);
- if (stringValue != null) {
- try {
- return Integer.parseInt(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * @param props
- * @param key
- * @param defaultValue
- * @return the long value for key props or defaultValue if none
- */
- public static long getPropertyLongValue(Properties props, String key,
- long defaultValue) {
- String stringValue = getProperty(props, key);
- if (stringValue != null) {
- try {
- return Long.parseLong(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * @param props
- * @param key
- * @param bDefault
- * @return true if props has a value for key
- */
- public static boolean isProperty(Properties props, String key,
- boolean bDefault) {
- return getProperty(props, key, "" + bDefault).equals("" + true); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- /**
- * @param props
- * @param key
- * @return the string values in props for key tokenized from
- * a comma-separated string
- */
- public static String[] getPropertyStrings(Properties props, String key) {
- String tokenString = getProperty(props, key);
-
- if (tokenString == null) {
- return new String[0];
- }
- StringTokenizer tokenizer = new StringTokenizer(tokenString, ","); //$NON-NLS-1$
- String[] pNames = new String[tokenizer.countTokens()];
-
- for (int ii = 0; ii < pNames.length; ii++) {
- pNames[ii] = ((String) tokenizer.nextElement()).trim();
- }
- return pNames;
- }
-
- // //////////////////////////////////////////////////////////////////////////
- // Resource bundle get methods.
- // //////////////////////////////////////////////////////////////////////////
- /**
- * @param bundle
- * @param key
- * @param theDefault
- * @return the string value from bundle for key or default if none
- */
- public static String getResourceProperty(ResourceBundle bundle, String key,
- String theDefault) {
- try {
- String value = bundle.getString(key);
- if ((value == null) || (value.length() == 0)) {
- value = theDefault;
- }
- return value;
- }
- catch(NullPointerException npe)
- {
- return theDefault;
- }
- catch (MissingResourceException mre)
- {
- return theDefault;
- }
- catch (ClassCastException cce)
- {
- return theDefault;
- }
- }
-
- /**
- * @param bundle
- * @param key
- * @return the value for key in bundle or null if none
- */
- public static String getResourceProperty(ResourceBundle bundle, String key) {
- try
- {
- String value = bundle.getString(key);
- if ((value != null) && (value.length() == 0))
- {
- value = null;
- }
- return value;
- }
- catch(NullPointerException npe)
- {
- return null;
- }
- catch (MissingResourceException mre)
- {
- return null;
- }
- catch (ClassCastException cce)
- {
- return null;
- }
- }
-
- /**
- * @param bundle
- * @param key
- * @param defaultValue
- * @param minimumValue
- * @return the integer value for key in bundle or defaultValue if none
- * Enforces minimum value in all cases
- */
- public static int getResourcePropertyValue(ResourceBundle bundle,
- String key, int defaultValue, int minimumValue) {
- int theValue = getResourcePropertyValue(bundle, key, defaultValue);
-
- if (theValue < minimumValue) {
- theValue = minimumValue;
- }
- return theValue;
- }
-
- /**
- * @param bundle
- * @param key
- * @param defaultValue
- * @return the integer value for key in bundle or defaultValue if none
- */
- public static int getResourcePropertyValue(ResourceBundle bundle,
- String key, int defaultValue) {
- String stringValue = getResourceProperty(bundle, key);
- if (stringValue != null) {
- try {
- return Integer.parseInt(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * @param bundle
- * @param key
- * @param defaultValue
- * @return the long value for key in bundle or default value if none
- */
- public static long getResourcePropertyLongValue(ResourceBundle bundle,
- String key, long defaultValue) {
- String stringValue = getResourceProperty(bundle, key);
- if (stringValue != null) {
- try {
- return Long.parseLong(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * @param bundle
- * @param key
- * @param bDefault
- * @return true if bundle has a value for key
- */
- public static boolean isResourceProperty(ResourceBundle bundle, String key,
- boolean bDefault) {
- return getResourceProperty(bundle, key, "" + bDefault) //$NON-NLS-1$
- .equals("" + true); //$NON-NLS-1$
- }
-
- // ///////////////////////////////////////////////////////////////////////
- // Property misc routines
- // ///////////////////////////////////////////////////////////////////////
- /**
- * @param theName
- * @return the encoded name
- */
- public static String encodeName(String theName) {
- int theSize = theName.length();
- StringBuffer encoded = new StringBuffer(theSize);
- char ch;
-
- for (int ii = 0; ii < theSize; ii++) {
- ch = theName.charAt(ii);
- switch (ch) {
- // these are the set of illegal characters in a Property name
- case '=': // %3d
- encoded.append(ENCODED_CHAR_EQUALS);
- break;
- case ':': // %3a
- encoded.append(ENCODED_CHAR_COLON);
- break;
- case ' ': // %20
- encoded.append(ENCODED_CHAR_SPACE);
- break;
- case '\n': // %0a
- encoded.append(ENCODED_CHAR_NEWLINE);
- break;
- case '\t': // %09
- encoded.append(ENCODED_CHAR_TAB);
- break;
- case '\r': // %0d
- encoded.append(ENCODED_CHAR_CARRIAGE_RETURN);
- break;
- case '%': // %25
- // added because its our encoding flag
- encoded.append(ENCODED_CHAR_PERCENT);
- break;
- default:
- encoded.append(ch);
- break;
- }
- }
-
- return encoded.toString();
- }
-
- /**
- * @param theName
- * @return the decoded name
- */
- public static String decodeName(String theName) {
- int theSize = theName.length();
- int kk;
- StringBuffer decoded = new StringBuffer(theSize);
- char ch;
-
- for (int ii = 0; ii < theSize; ii++) {
- ch = theName.charAt(ii);
- if (ch == '%') {
- ch = theName.charAt(++ii);
- kk = Character.digit(ch, 16);
- kk *= 16;
- ch = theName.charAt(++ii);
- kk += Character.digit(ch, 16);
- decoded.append((char) kk);
- } else {
- decoded.append(ch);
- }
- }
-
- return decoded.toString();
- }
-
- /**
- * @param propName
- * @return the properties
- * @throws IOException
- * @throws FileNotFoundException
- */
- public static Properties openProperties(String propName)
- throws IOException, FileNotFoundException {
- return openProperties(propName, null, true);
- }
-
- /**
- * @param propName
- * @param propDefaults
- * @return the properties
- * @throws IOException
- * @throws FileNotFoundException
- */
- public static Properties openProperties(String propName,
- Properties propDefaults) throws IOException, FileNotFoundException {
- return openProperties(propName, propDefaults, true);
- }
-
- /**
- * @param propName
- * @param propDefaults
- * @param bCreatePropertiesPathname
- * @return the properties
- * @throws IOException
- * @throws FileNotFoundException
- */
- public static Properties openProperties(String propName,
- Properties propDefaults, boolean bCreatePropertiesPathname)
- throws IOException, FileNotFoundException {
- Properties theProperties = new Properties(propDefaults);
-
- try {
- String propertiesFilename = bCreatePropertiesPathname ? getPropertiesPathname(propName)
- : propName;
- InputStream theStream = new FileInputStream(propertiesFilename);
- theProperties.load(theStream);
- theStream.close();
- } catch (FileNotFoundException ee) {
- if (propDefaults == null) {
- throw ee;
- }
- } catch (IOException ee) {
- if (propDefaults == null) {
- throw ee;
- }
- }
-
- return theProperties;
- }
-
- /**
- * Combines two properties objects, with the second one as the default
- * properties
- *
- * @param localProperties
- * @param defaultProperties
- * @return the combined properties
- * @throws IOException
- */
- public static Properties combineProperties(Properties localProperties,
- Properties defaultProperties) throws IOException {
- Properties theNewProperties = new Properties();
-
- ByteArrayOutputStream os = new ByteArrayOutputStream();
- defaultProperties.store(os, ""); //$NON-NLS-1$
- localProperties.store(os, ""); //$NON-NLS-1$
- byte[] theData = os.toByteArray();
- ByteArrayInputStream is = new ByteArrayInputStream(theData);
- theNewProperties.load(is);
-
- return theNewProperties;
- }
-
- /**
- * @param theFilename
- * @return the encoded file name
- */
- public static String encodeFilename(String theFilename) {
- // make theFilename legal on the local system....
- String theSeparator = System.getProperty("file.separator"); //$NON-NLS-1$
- // replace all occurrances of the file separator with a ' '
- for (int ii = 0; ii < theSeparator.length(); ii++) {
- char theChar = theSeparator.charAt(ii);
- theFilename = theFilename.replace(theChar, ' ');
- }
-
- return theFilename;
- }
-
- /**
- * @param baseName
- * @return the properties path
- */
- public static String getPropertiesPathname(String baseName) {
- if (baseName.endsWith(NAME_PROPERTIES)) {
- return System.getProperty("user.dir") //$NON-NLS-1$
- + System.getProperty("file.separator") //$NON-NLS-1$
- + encodeFilename(baseName);
- }
- return System.getProperty("user.dir") //$NON-NLS-1$
- + System.getProperty("file.separator") //$NON-NLS-1$
- + encodeFilename(baseName) + NAME_PROPERTIES;
- }
-
- // /////////////////////////////////////////////////////////////////////////
- // These are generic routines that are used to get/set/save window bounds
-
- private static final int INSET = 40;
-
- /**
- * Set the initial bounds (size & location) of a component. This will get
- * the location from the preferences file based on the values of the "names"
- * parameter. These values will be encoded to make a legal properties name,
- * joined togther with ".", and the value STR_BOUNDS_END will be appended.
- * The resulting name will be used to obtain the intial bounds value from
- * the properties file, which will be decoded and the specified component
- * will then be set to that value.
- * @param props
- * @param theComponent
- * @param names
- * @param defaultValue
- */
- public static void setComponentBounds(Properties props,
- Component theComponent, String names[], String defaultValue) {
- setComponentBounds(props, theComponent, names, defaultValue, false);
- }
-
- /**
- * @param props
- * @param theComponent
- * @param names
- * @param defaultValue
- * @param bEnsureDesktopVisibility
- */
- public static void setComponentBounds(Properties props,
- Component theComponent, String names[], String defaultValue,
- boolean bEnsureDesktopVisibility) {
- String tmpString = getComponentPropertyName(names, STR_BOUNDS_END);
- setComponentBounds(props, theComponent, tmpString, defaultValue,
- bEnsureDesktopVisibility);
- }
-
- /**
- * @param props
- * @param theComponent
- * @param thePropertyName
- * @param defaultValue
- */
- public static void setComponentBounds(Properties props,
- Component theComponent, String thePropertyName, String defaultValue) {
- setComponentBounds(props, theComponent, thePropertyName, defaultValue,
- false);
- }
-
- /**
- * @param props
- * @param theComponent
- * @param thePropertyName
- * @param defaultValue
- * @param bEnsureDesktopVisibility
- */
- public static void setComponentBounds(Properties props,
- Component theComponent, String thePropertyName,
- String defaultValue, boolean bEnsureDesktopVisibility) {
- String tmpString = props.getProperty(thePropertyName, defaultValue);
- Rectangle theValue = decodeBounds(tmpString);
- theComponent.setBounds(theValue);
- if (bEnsureDesktopVisibility) {
- // make sure that this component is visible on the desktop...
- // verify that this window is visible...
- Point theLoc = theComponent.getLocation();
- // get width/height of desktop....
- Dimension portSize = new Dimension(Toolkit.getDefaultToolkit()
- .getScreenSize());
- if (theLoc.x > portSize.width) // move it to top
- theLoc.x = INSET;
- if (theLoc.y > portSize.height) // move it to left
- theLoc.y = INSET;
- theComponent.setLocation(theLoc);
- }
- }
-
- /**
- * @param props
- * @param theComponent
- * @param names
- */
- public static void saveComponentBounds(Properties props,
- Component theComponent, String names[]) {
- String tmpString = getComponentPropertyName(names, STR_BOUNDS_END);
- saveComponentBounds(props, theComponent, tmpString);
- }
-
- /**
- * @param props
- * @param theComponent
- * @param thePropertyName
- */
- public static void saveComponentBounds(Properties props,
- Component theComponent, String thePropertyName) {
- Rectangle theBounds = theComponent.getBounds();
- String theValue = encodeBounds(theBounds);
- props.put(thePropertyName, theValue);
- }
-
- /**
- * @param names
- * @param subsystemName
- * @return the component property name or ""
- */
- public static String getComponentPropertyName(String names[],
- String subsystemName) {
- String tmpString = ""; //$NON-NLS-1$
-
- for (int ii = 0; ii < names.length; ii++) {
- tmpString = tmpString + (ii > 0 ? "." : "") //$NON-NLS-1$ //$NON-NLS-2$
- + PropertyUtils.encodeName(names[ii]);
- }
- if (subsystemName.startsWith(".") == false) //$NON-NLS-1$
- tmpString += "."; //$NON-NLS-1$
- tmpString = tmpString + subsystemName;
- return tmpString;
- }
-
- /**
- * Decode the comma separated values stored in sBounds. This method is
- * normally called to decode the location/size of a component which has been
- * saved into a Properties object. See encodeBounds(); Order of items in the
- * string is (x, y, w, h)
- * @param sBounds
- * @return the rectangle
- */
- public static Rectangle decodeBounds(String sBounds) {
- int index;
- int ii;
- int theValue[] = new int[4];
- String tmpString;
- String restString = sBounds;
-
- for (ii = 0; ii < 4; ii++) {
- theValue[ii] = 0;
- }
- try {
- for (ii = 0; ii < 4; ii++) {
- index = restString.indexOf(","); //$NON-NLS-1$
- if (index > 0) {
- tmpString = restString.substring(0, index);
- restString = restString.substring(index + 1);
- } else {
- tmpString = restString; // should only happen on the last
- // one....
- restString = null; // will cause an exception if not last
- // one...
- }
- theValue[ii] = Integer.valueOf(tmpString).intValue();
- }
- } catch (Exception ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should show
- // these to user.
- }
-
- return new Rectangle(theValue[0], theValue[1], theValue[2], theValue[3]);
- }
-
- /**
- * * Encode the bounds of a component into a comma separated list * that is
- * appropriate for storing in a Properties object. * See decodeBounds();
- * @param rBounds
- * @return the encoded bounds
- */
- public static String encodeBounds(Rectangle rBounds) {
- return "" + rBounds.x + "," + rBounds.y + "," + rBounds.width + "," //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
- + rBounds.height;
- }
-
- /**
- * Methods for creating Properties objects from strings.
- *
- * Then "Encoded" versions are used on values that are stored into a
- * properties file (think of them as sub-properties). They do the encoding
- * necessary to turn a properties object into a string that has legal
- * "value" syntax (they actually do more than they need to, but its all
- * non-destructive).
- * @param thePropertyString
- * @return the properties from the string
- * @throws IOException
- */
- public static Properties getPropertiesFromString(String thePropertyString)
- throws IOException {
- if (thePropertyString == null)
- return null;
- ByteArrayInputStream in = new ByteArrayInputStream(thePropertyString
- .getBytes());
-
- Properties props = new Properties();
- props.load(in); // throws IOException
- in = null;
- return props;
- }
-
- /**
- * @param theEncodedPropertyString
- * @return the properties
- * @throws IOException
- */
- public static Properties getPropertiesFromEncodedString(
- String theEncodedPropertyString) throws IOException {
- if (theEncodedPropertyString == null)
- return null;
- return (getPropertiesFromString(decodeName(theEncodedPropertyString)));
- }
-
- /**
- * @param theEncodedPropertyString
- * @return the properties
- */
- public static Properties encodedStringToProperties(
- String theEncodedPropertyString) {
- try {
- return getPropertiesFromEncodedString(theEncodedPropertyString);
- } catch (IOException ee) {
- return null;
- }
- }
-
- /**
- * @param props
- * @param comment
- * @return the string
- * @throws IOException
- */
- public static String savePropertiesToString(Properties props, String comment)
- throws IOException {
- if (props == null)
- return null;
- ByteArrayOutputStream out = new ByteArrayOutputStream();
- props.store(out, comment);
- String tmpString = out.toString();
- out = null;
- return tmpString;
- }
-
- /**
- * @param props
- * @param comment
- * @return the encoded string
- * @throws IOException
- */
- public static String savePropertiesToEncodedString(Properties props,
- String comment) throws IOException {
- if (props == null)
- return null;
- return encodeName(savePropertiesToString(props, comment));
- }
-
- /**
- * @param props
- * @return the encoded string
- */
- public static String propertiesToEncodedString(Properties props) {
- try {
- return savePropertiesToEncodedString(props, ""); //$NON-NLS-1$
- } catch (IOException ee)// NOPMD
- {
- JSFUICommonPlugin.getLogger(PropertyUtils.class).error("saving properties", ee); //$NON-NLS-1$
- }
- return null;
- }
-
- private PropertyUtils()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/ResourceUtils.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/ResourceUtils.java
deleted file mode 100644
index e35ee83ab..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/ResourceUtils.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.text.MessageFormat;
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-
-/**
- * Give easy access to a resource bundle.
- *
- * @author mengbo
- */
-public abstract class ResourceUtils {
- private static final String LOG_RESOURCE_UTILS_MSG_KEY = "log.ResourceUtils"; //$NON-NLS-1$
- private static Logger _log = JSFUICommonPlugin.getLogger(ResourceUtils.class);
- /**
- * the resource bundle accessible by all children
- */
- protected ResourceBundle _resources;
-
- /**
- * Empty Constructor.
- */
- protected ResourceUtils() {
- // restrict instantiation
- }
-
- /**
- * Easy way to set the bundle and get a fatal log messages and an alert if
- * the resource bundle is not found.
- *
- * @param resource
- * @param bundleLocation
- */
- protected void setBundle(ResourceBundle resource, String bundleLocation) {
- _resources = resource;
- if (_resources == null) {
- // log.ResourceUtils=Missing Resource Bundle "{0}".
- _log.error(LOG_RESOURCE_UTILS_MSG_KEY, bundleLocation);
- // pluginName=Web Application Development Common
- JSFUICommonPlugin.getAlerts().error("pluginName", LOG_RESOURCE_UTILS_MSG_KEY, //$NON-NLS-1$
- bundleLocation);
- }
- }
-
- /**
- * Get the property defined in the resource bundle for the given key. This
- * property should be an integer. If none is defined
- * (MissingResourceException), return the default.
- *
- * @param key
- * the key in the resource bundle.
- * @param defaultValue
- * default int to return if no value is found for the key.
- * @return the integer value for key or defaultValue if none
- */
- public int getValue(String key, int defaultValue) {
- String stringValue = getString(key);
- if (stringValue != null) {
- try {
- return Integer.parseInt(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * Get the property defined in the resource bundle for the given key. This
- * property should be an long. If none is defined
- * (MissingResourceException), return the default.
- *
- * @param key
- * the key in the resource bundle.
- * @param defaultValue
- * default long to return if no value is found for the key.
- * @return the long value for key or defaultValue if none
- */
- public long getValue(String key, long defaultValue) {
- String stringValue = getString(key);
- if (stringValue != null) {
- try {
- return Long.parseLong(stringValue);
- } catch (NumberFormatException ee)// NOPMD
- {
- // the property value maybe an invalid value, the editor should
- // show these to user.
- }
- }
- return defaultValue;
- }
-
- /**
- * Get the property defined in the resource bundle for the given key. This
- * property should be boolean ("true" of "false"). If none is defined
- * (MissingResourceException), return the default.
- *
- * @param key
- * the key in the resource bundle.
- * @return true if there is a resource corresponding to key
- */
- public boolean isResource(String key) {
- return getString(key).equals("" + true); //$NON-NLS-1$
- }
-
- /**
- * Get the property defined in the resource bundle for the given key. If
- * none is defined (MissingResourceException), return null.
- *
- * @param key
- * the key in the resource bundle.
- * @return the string value for key or key if not found
- */
- public String getString(String key) {
- try {
- return _resources.getString(key);
- } catch (MissingResourceException ee) {
- return key;
- }
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param arg0
- * the first argument.
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object arg0) {
- Object[] args = new Object[1];
- args[0] = arg0;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param arg0
- * the first argument.
- * @param arg1
- * the second argument.
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object arg0, Object arg1) {
- Object[] args = new Object[2];
- args[0] = arg0;
- args[1] = arg1;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param arg0
- * the first argument.
- * @param arg1
- * the second argument.
- * @param arg2
- * the third argument.
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object arg0, Object arg1, Object arg2) {
- Object[] args = new Object[3];
- args[0] = arg0;
- args[1] = arg1;
- args[2] = arg2;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param arg0
- * the first argument.
- * @param arg1
- * the second argument.
- * @param arg2
- * the third argument.
- * @param arg3
- * the forth argument.
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object arg0, Object arg1, Object arg2,
- Object arg3) {
- Object[] args = new Object[4];
- args[0] = arg0;
- args[1] = arg1;
- args[2] = arg2;
- args[3] = arg3;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param arg0
- * the first argument.
- * @param arg1
- * the second argument.
- * @param arg2
- * the third argument.
- * @param arg3
- * the forth argument.
- * @param arg4
- * the forth argument.
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object arg0, Object arg1, Object arg2,
- Object arg3, Object arg4) {
- Object[] args = new Object[5];
- args[0] = arg0;
- args[1] = arg1;
- args[2] = arg2;
- args[3] = arg3;
- args[4] = arg4;
-
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Build a formated string from the resource bundle.
- *
- * @param key
- * the key into the resource bundle that has the formated string.
- * @param args
- * an array of arguments
- * @return the formated string with the argument inline.
- */
- public String getString(String key, Object[] args) {
- MessageFormat formatter = new MessageFormat(getString(key));
- return formatter.format(args);
- }
-
- /**
- * Use in the try-finally idiom for inputStream to ensure close
- * and suppress exceptions on close
- * @param inputStream
- */
- public static void ensureClosed(InputStream inputStream) {
- if (inputStream != null) {
- try {
- inputStream.close();
- } catch (IOException e) {
- // Ignore
- }
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StringUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StringUtil.java
deleted file mode 100644
index e914b600c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StringUtil.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.util.regex.Pattern;
-
-/**
- * This is tool class for String processing.
- *
- * @author mengbo
- */
-public class StringUtil {
-
- // pattern to find all end-of-paragraph and end-of-line html tags
- // so they can be converted to newlines
- final private static Pattern htmlToNewline = Pattern.compile("</p>|<br>"); //$NON-NLS-1$
-
- // pattern to strip all <x> and </x> HTML tags
- final private static Pattern removeHTMLTags = Pattern.compile("<[/?\\w\\s=\"\\.\\#]+>"); //$NON-NLS-1$
-
- // pattern to find all runs of spaces longer than one
- final private static Pattern trimInteriorWhitespace = Pattern.compile("[ ]+"); //$NON-NLS-1$
-
- /**
- * Split a java variable name into words For example, "_aJavaVariable" will
- * split to "A Java Variable", "_aWTPPackageImplementation" will be "A WTP
- * Package Implementation"
- *
- * @param variable
- * @return String
- */
- public static String splitVariable(String variable) {
- StringBuffer output = new StringBuffer(""); //$NON-NLS-1$
- boolean isCapitalLeading = false;
- boolean isLastSpace = false;
-
- for (int i = 0, n = variable.length(); i < n; i++) {
- char letter = variable.charAt(i);
-
- if (letter == '_' || letter == '$') {
- output.append(" "); //$NON-NLS-1$
- isCapitalLeading = false;
- isLastSpace = true;
- continue;
- }
-
- if (Character.isLowerCase(letter)) {
- int nextIndex = i + 1;
- if (nextIndex < n) {
- char nextLetter = variable.charAt(nextIndex);
- if (Character.isUpperCase(nextLetter)) {
- if (isCapitalLeading) {
- output.append(letter);
- isLastSpace = false;
- } else {
- output.append(Character.toUpperCase(letter));
- isLastSpace = false;
- }
- if (!isLastSpace) {
- output.append(' ');
- isLastSpace = true;
- }
- isCapitalLeading = false;
- continue;
- }
- }
- }
- if (Character.isUpperCase(letter)) {
- int nextIndex = i + 1;
- if (nextIndex < n) {
- char nextLetter = variable.charAt(nextIndex);
- if (Character.isLowerCase(nextLetter)) {
- if (!isLastSpace) {
- output.append(' ');
- isLastSpace = true;
- }
- output.append(letter);
- isCapitalLeading = true;
- isLastSpace = false;
- continue;
- }
- }
- }
- if (isCapitalLeading) {
- output.append(letter);
- isLastSpace = false;
- } else {
- output.append(Character.toUpperCase(letter));
- isCapitalLeading = true;
- isLastSpace = false;
- }
- }
-
- return output.toString().trim();
- }
-
- /**
- * @param str1
- * @param str2
- * @return boolean
- *
- * Check if two strings match or not if str1=null and str2=null, it will
- * return true
- */
- public static boolean isSameString(String str1, String str2) {
- if (str1 == null) {
- return str2 == null;
- }
- return str1.equals(str2);
- }
-
- /**
- *
- * @param text
- * @return String Filter and convert a string, or normalize a string For
- * example,
- * <p>
- * test
- * </p>
- * test1<a/> will be converted to: test\ntest1
- *
- */
- public static String filterConvertString(String text) {
- if (text == null) {
- return ""; //$NON-NLS-1$
- }
-
- String result = htmlToNewline.matcher(text).replaceAll("\n"); //$NON-NLS-1$
- result = removeHTMLTags.matcher(result).replaceAll(""); //$NON-NLS-1$
- result = trimInteriorWhitespace.matcher(result).replaceAll(" "); //$NON-NLS-1$
-
- return result;
- }
-
- /**
- * Determine whether a string is empty or not Example: null string -> return
- * true; Example: "" string -> return true; Otherwise, will return false;
- * @param str
- *
- * @return true if str is null or empty
- */
- public static boolean isEmptyString(String str) {
- if (str == null || str.length() == 0) {
- return true;
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StyleCombo.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StyleCombo.java
deleted file mode 100644
index 4eccfa6d8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/StyleCombo.java
+++ /dev/null
@@ -1,1877 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.util.Arrays;
-
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.accessibility.ACC;
-import org.eclipse.swt.accessibility.AccessibleAdapter;
-import org.eclipse.swt.accessibility.AccessibleControlAdapter;
-import org.eclipse.swt.accessibility.AccessibleControlEvent;
-import org.eclipse.swt.accessibility.AccessibleEvent;
-import org.eclipse.swt.accessibility.AccessibleTextAdapter;
-import org.eclipse.swt.accessibility.AccessibleTextEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Layout;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.TypedListener;
-
-/**
- * The CCombo class represents a selectable user interface object that combines
- * a text field and a list and issues notification when an item is selected from
- * the list.
- * <p>
- * Note that although this class is a subclass of <code>Composite</code>, it
- * does not make sense to add children to it, or set a layout on it.
- * </p>
- * <dl>
- * <dt><b>Styles:</b>
- * <dd>BORDER, READ_ONLY, FLAT</dd>
- * <dt><b>Events:</b>
- * <dd>Selection</dd>
- * </dl>
- */
-public final class StyleCombo extends Composite {
-
- Text text;
-
- Table table;
-
- int visibleItemCount = 4;
-
- Shell popup;
-
- Button arrow;
-
- boolean hasFocus;
-
- Listener listener, filter;
-
- Color foreground, background;
-
- Font font;
-
- String defaultValue;
-
- /**
- * Constructs a new instance of this class given its parent and a style
- * value describing its behavior and appearance.
- * <p>
- * The style value is either one of the style constants defined in class
- * <code>SWT</code> which is applicable to instances of this class, or
- * must be built by <em>bitwise OR</em>'ing together (that is, using the
- * <code>int</code> "|" operator) two or more of those <code>SWT</code>
- * style constants. The class description lists the style constants that are
- * applicable to the class. Style bits are also inherited from superclasses.
- * </p>
- *
- * @param parent
- * a widget which will be the parent of the new instance (cannot
- * be null)
- * @param style
- * the style of widget to construct
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the parent is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the parent</li>
- * </ul>
- *
- * @see SWT#BORDER
- * @see SWT#READ_ONLY
- * @see SWT#FLAT
- */
- public StyleCombo(Composite parent, int style) {
- super(parent, style = checkStyle(style));
-
- listener = new Listener() {
- public void handleEvent(Event event) {
- if (popup == event.widget) {
- popupEvent(event);
- return;
- }
- if (text == event.widget) {
- textEvent(event);
- return;
- }
- if (table == event.widget) {
- tableEvent(event);
- return;
- }
- if (arrow == event.widget) {
- arrowEvent(event);
- return;
- }
- if (StyleCombo.this == event.widget) {
- comboEvent(event);
- return;
- }
- if (getShell() == event.widget) {
- handleFocus(SWT.FocusOut);
- }
- }
- };
-
- filter = new Listener() {
- public void handleEvent(Event event) {
- Shell shell = ((Control) event.widget).getShell();
- if (shell == StyleCombo.this.getShell()) {
- handleFocus(SWT.FocusOut);
- }
- }
- };
-
- int[] comboEvents = { SWT.Dispose, SWT.Move, SWT.Resize };
- for (int i = 0; i < comboEvents.length; i++)
- this.addListener(comboEvents[i], listener);
-
- createText(style);
- createArrow(style);
-
- createPopup(null, -1);
- initAccessible();
- }
-
- /**
- * @param style
- */
- private void createArrow(int style) {
- int arrowStyle = SWT.ARROW | SWT.DOWN;
- if ((style & SWT.FLAT) != 0) {
- arrowStyle |= SWT.FLAT;
- }
- arrow = new Button(this, arrowStyle);
- int[] arrowEvents = { SWT.Selection, SWT.FocusIn };
- for (int i = 0; i < arrowEvents.length; i++) {
- arrow.addListener(arrowEvents[i], listener);
- }
- }
-
- /**
- * @param style
- */
- private void createText(int style) {
- int textStyle = SWT.SINGLE;
- if ((style & SWT.READ_ONLY) != 0) {
- textStyle |= SWT.READ_ONLY;
- }
- if ((style & SWT.FLAT) != 0) {
- textStyle |= SWT.FLAT;
- }
- text = new Text(this, textStyle);
- int[] textEvents = { SWT.KeyDown, SWT.KeyUp, SWT.Modify, SWT.MouseDown,
- SWT.MouseUp, SWT.Traverse, SWT.FocusIn };
- for (int i = 0; i < textEvents.length; i++) {
- text.addListener(textEvents[i], listener);
- }
- }
-
- static int checkStyle(int style) {
- int mask = SWT.BORDER | SWT.READ_ONLY | SWT.FLAT | SWT.LEFT_TO_RIGHT
- | SWT.RIGHT_TO_LEFT;
- return style & mask;
- }
-
- /**
- * Adds the argument to the end of the receiver's list.
- *
- * @param string
- * the new item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see #add(String,int)
- */
- public void add(String string) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- TableItem item = new TableItem(table, SWT.NONE);
- item.setText(0, string);
- }
-
- /**
- * Adds the argument to the receiver's list at the given zero-relative
- * index.
- * <p>
- * Note: To add an item at the end of the list, use the result of calling
- * <code>getItemCount()</code> as the index or use
- * <code>add(String)</code>.
- * </p>
- *
- * @param string
- * the new item
- * @param index
- * the index for the item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * <li>ERROR_INVALID_RANGE - if the index is not between 0
- * and the number of elements in the list (inclusive)</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see #add(String)
- */
- public void add(String string, int index) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- TableItem item = new TableItem(table, SWT.NONE, index);
- item.setText(0, string);
- }
-
- /**
- * Adds the listener to the collection of listeners who will be notified
- * when the receiver's text is modified, by sending it one of the messages
- * defined in the <code>ModifyListener</code> interface.
- *
- * @param listener1
- * the listener which should be notified
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the listener is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see ModifyListener
- * @see #removeModifyListener
- */
- public void addModifyListener(ModifyListener listener1) {
- checkWidget();
- if (listener1 == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- TypedListener typedListener = new TypedListener(listener1);
- addListener(SWT.Modify, typedListener);
- }
-
- /**
- * Adds the listener to the collection of listeners who will be notified
- * when the receiver's selection changes, by sending it one of the messages
- * defined in the <code>SelectionListener</code> interface.
- * <p>
- * <code>widgetSelected</code> is called when the combo's list selection
- * changes. <code>widgetDefaultSelected</code> is typically called when
- * ENTER is pressed the combo's text area.
- * </p>
- *
- * @param listener1
- * the listener which should be notified
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the listener is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see SelectionListener
- * @see #removeSelectionListener
- */
- public void addSelectionListener(SelectionListener listener1) {
- checkWidget();
- if (listener1 == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- TypedListener typedListener = new TypedListener(listener1);
- addListener(SWT.Selection, typedListener);
- addListener(SWT.DefaultSelection, typedListener);
- }
-
- void arrowEvent(Event event) {
- switch (event.type) {
- case SWT.FocusIn: {
- handleFocus(SWT.FocusIn);
- break;
- }
- case SWT.Selection: {
- dropDown(!isDropped());
- break;
- }
- }
- }
-
- /**
- * Sets the selection in the receiver's text field to an empty selection
- * starting just before the first character. If the text field is editable,
- * this has the effect of placing the i-beam at the start of the text.
- * <p>
- * Note: To clear the selected items in the receiver's list, use
- * <code>deselectAll()</code>.
- * </p>
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see #deselectAll
- */
- public void clearSelection() {
- checkWidget();
- text.clearSelection();
- table.deselectAll();
- }
-
- void comboEvent(Event event) {
- switch (event.type) {
- case SWT.Dispose:
- if (popup != null && !popup.isDisposed()) {
- table.removeListener(SWT.Dispose, listener);
- popup.dispose();
- }
- Shell shell = getShell();
- shell.removeListener(SWT.Deactivate, listener);
- Display display = getDisplay();
- display.removeFilter(SWT.FocusIn, filter);
- popup = null;
- text = null;
- table = null;
- arrow = null;
- break;
- case SWT.Move:
- dropDown(false);
- break;
- case SWT.Resize:
- internalLayout(false);
- break;
- }
- }
-
- private String[] getTableItems() {
- TableItem[] items = table.getItems();
- String[] values = new String[items.length];
- for (int i = 0; i < items.length; i++) {
- values[i] = items[i].getText(0);
- }
- return values;
- }
-
- public Point computeSize(int wHint, int hHint, boolean changed) {
- checkWidget();
- int width = 0, height = 0;
- String[] items = getTableItems();
- int textWidth = 0;
- GC gc = new GC(text);
- int spacer = gc.stringExtent(" ").x; //$NON-NLS-1$
- for (int i = 0; i < items.length; i++) {
- textWidth = Math.max(gc.stringExtent(items[i]).x, textWidth);
- }
- gc.dispose();
- Point textSize = text.computeSize(SWT.DEFAULT, SWT.DEFAULT, changed);
- Point arrowSize = arrow.computeSize(SWT.DEFAULT, SWT.DEFAULT, changed);
- Point listSize = table.computeSize(wHint, SWT.DEFAULT, changed);
- int borderWidth = getBorderWidth();
-
- height = Math.max(hHint, Math.max(textSize.y, arrowSize.y) + 2
- * borderWidth);
- width = Math.max(wHint, Math.max(textWidth + 2 * spacer + arrowSize.x
- + 2 * borderWidth, listSize.x));
- return new Point(width, height);
- }
-
- void createPopup(String[] items, int selectionIndex) {
- // create shell and list
- popup = new Shell(getShell(), SWT.NO_TRIM | SWT.ON_TOP);
- table = new Table(popup, SWT.SINGLE | SWT.V_SCROLL | SWT.FULL_SELECTION);
- new TableColumn(table, SWT.LEFT);
- if (font != null) {
- table.setFont(font);
- }
- if (foreground != null) {
- table.setForeground(foreground);
- }
- if (background != null) {
- table.setBackground(background);
- }
-
- int[] popupEvents = { SWT.Close, SWT.Paint, SWT.Deactivate };
- for (int i = 0; i < popupEvents.length; i++) {
- popup.addListener(popupEvents[i], listener);
- }
- int[] listEvents = { SWT.MouseUp, SWT.Selection, SWT.Traverse,
- SWT.KeyDown, SWT.KeyUp, SWT.FocusIn, SWT.FocusOut, SWT.Dispose };
- for (int i = 0; i < listEvents.length; i++) {
- table.addListener(listEvents[i], listener);
- }
- if (items != null) {
- setItems(items);
- }
- if (selectionIndex != -1) {
- select(selectionIndex);
- }
- }
-
- /**
- * Deselects the item at the given zero-relative index in the receiver's
- * list. If the item at the index was already deselected, it remains
- * deselected. Indices that are out of range are ignored.
- *
- * @param index
- * the index of the item to deselect
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void deselect(int index) {
- checkWidget();
- table.deselect(index);
- }
-
- /**
- * Deselects all selected items in the receiver's list.
- * <p>
- * Note: To clear the selection in the receiver's text field, use
- * <code>clearSelection()</code>.
- * </p>
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see #clearSelection
- */
- public void deselectAll() {
- checkWidget();
- table.deselectAll();
- }
-
- void dropDown(boolean drop) {
- if (drop == isDropped()) {
- return;
- }
- if (!drop) {
- popup.setVisible(false);
- table.getColumns()[0].setWidth(0);
- if (!isDisposed() && arrow.isFocusControl()) {
- text.setFocus();
- }
- return;
- }
-
- if (getShell() != popup.getParent()) {
- String[] items = getTableItems();
- int selectionIndex = table.getSelectionIndex();
- table.removeListener(SWT.Dispose, listener);
- popup.dispose();
- popup = null;
- table = null;
- createPopup(items, selectionIndex);
- }
-
- Point size = getSize();
- int itemCount = table.getItemCount();
- itemCount = (itemCount == 0) ? visibleItemCount : Math.min(
- visibleItemCount, itemCount);
- int itemHeight = table.getItemHeight() * itemCount;
- Point tableSize = table.computeSize(SWT.DEFAULT, itemHeight, false);
- // int tableWidth = this.getClientArea()
- table.setBounds(1, 1, Math.max(size.x - 2, tableSize.x), tableSize.y
- - table.getHorizontalBar().getSize().y + 2);
-
- int index = table.getSelectionIndex();
- if (index != -1) {
- table.setTopIndex(index);
- }
- Display display = getDisplay();
- Rectangle tableRect = table.getBounds();
- Rectangle parentRect = display.map(getParent(), null, getBounds());
- Point comboSize = getSize();
- Rectangle displayRect = getMonitor().getClientArea();
- int width = Math.max(comboSize.x, tableRect.width + 2);
- int height = tableRect.height + 2;
- int x = parentRect.x;
- int y = parentRect.y + comboSize.y;
- if (y + height > displayRect.y + displayRect.height) {
- y = parentRect.y - height;
- }
- popup.setBounds(x, y, width, height);
- popup.setVisible(true);
-
- if (table.getItemCount() > visibleItemCount) {
- table.getColumns()[0].setWidth(text.getSize().x - 2);
- } else {
- table.getColumns()[0].setWidth(table.getClientArea().width);
- }
- table.setFocus();
- }
-
- /*
- * Return the Label immediately preceding the receiver in the z-order, or
- * null if none.
- */
- Label getAssociatedLabel() {
- Control[] siblings = getParent().getChildren();
- for (int i = 0; i < siblings.length; i++) {
- if (siblings[i] == StyleCombo.this) {
- if (i > 0 && siblings[i - 1] instanceof Label) {
- return (Label) siblings[i - 1];
- }
- }
- }
- return null;
- }
-
- public Control[] getChildren() {
- checkWidget();
- return new Control[0];
- }
-
- /**
- * Gets the editable state.
- *
- * @return whether or not the reciever is editable
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @since 3.0
- */
- public boolean getEditable() {
- checkWidget();
- return text.getEditable();
- }
-
- /**
- * Returns the item at the given, zero-relative index in the receiver's
- * list. Throws an exception if the index is out of range.
- *
- * @param index
- * the index of the item to return
- * @return the item at the given index
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_INVALID_RANGE - if the index is not between 0
- * and the number of elements in the list minus 1 (inclusive)</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public String getItem(int index) {
- checkWidget();
- return table.getItem(index).getText(0);
- }
-
- /**
- * Returns the number of items contained in the receiver's list.
- *
- * @return the number of items
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int getItemCount() {
- checkWidget();
- return table.getItemCount();
- }
-
- /**
- * Returns the height of the area which would be used to display
- * <em>one</em> of the items in the receiver's list.
- *
- * @return the height of one item
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int getItemHeight() {
- checkWidget();
- return table.getItemHeight();
- }
-
- /**
- * Returns an array of <code>String</code>s which are the items in the
- * receiver's list.
- * <p>
- * Note: This is not the actual structure used by the receiver to maintain
- * its list of items, so modifying the array will not affect the receiver.
- * </p>
- *
- * @return the items in the receiver's list
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public String[] getItems() {
- checkWidget();
- return getTableItems();
- }
-
- char getMnemonic(String string) {
- int index = 0;
- int length = string.length();
- do {
- while ((index < length) && (string.charAt(index) != '&')) {
- index++;
- }
- if (++index >= length) {
- return '\0';
- }
- if (string.charAt(index) != '&') {
- return string.charAt(index);
- }
- index++;
- } while (index < length);
- return '\0';
- }
-
- /**
- * Returns a <code>Point</code> whose x coordinate is the start of the
- * selection in the receiver's text field, and whose y coordinate is the end
- * of the selection. The returned values are zero-relative. An "empty"
- * selection as indicated by the the x and y coordinates having the same
- * value.
- *
- * @return a point representing the selection start and end
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public Point getSelection() {
- checkWidget();
- return text.getSelection();
- }
-
- /**
- * Returns the zero-relative index of the item which is currently selected
- * in the receiver's list, or -1 if no item is selected.
- *
- * @return the index of the selected item
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int getSelectionIndex() {
- checkWidget();
- return table.getSelectionIndex();
- }
-
- public int getStyle() {
- int style = super.getStyle();
- style &= ~SWT.READ_ONLY;
- if (!text.getEditable()) {
- style |= SWT.READ_ONLY;
- }
- return style;
- }
-
- /**
- * Returns a string containing a copy of the contents of the receiver's text
- * field.
- *
- * @return the receiver's text
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public String getText() {
- checkWidget();
- return text.getText();
- }
-
- /**
- * Returns the height of the receivers's text field.
- *
- * @return the text height
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int getTextHeight() {
- checkWidget();
- return text.getLineHeight();
- }
-
- /**
- * Returns the maximum number of characters that the receiver's text field
- * is capable of holding. If this has not been changed by
- * <code>setTextLimit()</code>, it will be the constant
- * <code>Combo.LIMIT</code>.
- *
- * @return the text limit
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int getTextLimit() {
- checkWidget();
- return text.getTextLimit();
- }
-
- /**
- * Gets the number of items that are visible in the drop down portion of the
- * receiver's list.
- *
- * @return the number of items that are visible
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @since 3.0
- */
- public int getVisibleItemCount() {
- checkWidget();
- return visibleItemCount;
- }
-
- void handleFocus(int type) {
- if (isDisposed()) {
- return;
- }
- switch (type) {
- case SWT.FocusIn: {
- if (hasFocus) {
- return;
- }
- if (getEditable()) {
- text.selectAll();
- }
- hasFocus = true;
- Shell shell = getShell();
- shell.removeListener(SWT.Deactivate, listener);
- shell.addListener(SWT.Deactivate, listener);
- Display display = getDisplay();
- display.removeFilter(SWT.FocusIn, filter);
- display.addFilter(SWT.FocusIn, filter);
- Event e = new Event();
- notifyListeners(SWT.FocusIn, e);
- break;
- }
- case SWT.FocusOut: {
- if (!hasFocus) {
- return;
- }
- Control focusControl = getDisplay().getFocusControl();
- if (focusControl == arrow || focusControl == table
- || focusControl == text) {
- return;
- }
- hasFocus = false;
- Shell shell = getShell();
- shell.removeListener(SWT.Deactivate, listener);
- Display display = getDisplay();
- display.removeFilter(SWT.FocusIn, filter);
- Event e = new Event();
- notifyListeners(SWT.FocusOut, e);
- break;
- }
- }
- }
-
- /**
- * Searches the receiver's list starting at the first item (index 0) until
- * an item is found that is equal to the argument, and returns the index of
- * that item. If no item is found, returns -1.
- *
- * @param string
- * the search item
- * @return the index of the item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int indexOf(String string) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- return Arrays.asList(getTableItems()).indexOf(string);
- }
-
- /**
- * Searches the receiver's list starting at the given, zero-relative index
- * until an item is found that is equal to the argument, and returns the
- * index of that item. If no item is found or the starting index is out of
- * range, returns -1.
- *
- * @param string
- * the search item
- * @param start
- * the zero-relative index at which to begin the search
- * @return the index of the item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public int indexOf(String string, int start) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- String[] items = getTableItems();
- for (int i = start; i < items.length; i++) {
- if (items[i].equals(string)) {
- return i;
- }
- }
- return -1;
- }
-
- void initAccessible() {
- AccessibleAdapter accessibleAdapter = new AccessibleAdapter() {
- public void getName(AccessibleEvent e) {
- String name = null;
- Label label = getAssociatedLabel();
- if (label != null) {
- name = stripMnemonic(label.getText());
- }
- e.result = name;
- }
-
- public void getKeyboardShortcut(AccessibleEvent e) {
- String shortcut = null;
- Label label = getAssociatedLabel();
- if (label != null) {
- String text1 = label.getText();
- if (text1 != null) {
- char mnemonic = getMnemonic(text1);
- if (mnemonic != '\0') {
- shortcut = "Alt+" + mnemonic; //$NON-NLS-1$
- }
- }
- }
- e.result = shortcut;
- }
-
- public void getHelp(AccessibleEvent e) {
- e.result = getToolTipText();
- }
- };
- getAccessible().addAccessibleListener(accessibleAdapter);
- text.getAccessible().addAccessibleListener(accessibleAdapter);
- table.getAccessible().addAccessibleListener(accessibleAdapter);
-
- arrow.getAccessible().addAccessibleListener(new AccessibleAdapter() {
- public void getName(AccessibleEvent e) {
- e.result = isDropped() ? SWT.getMessage("SWT_Close") : SWT.getMessage("SWT_Open"); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- public void getKeyboardShortcut(AccessibleEvent e) {
- e.result = "Alt+Down Arrow"; //$NON-NLS-1$
- }
-
- public void getHelp(AccessibleEvent e) {
- e.result = getToolTipText();
- }
- });
-
- getAccessible().addAccessibleTextListener(new AccessibleTextAdapter() {
- public void getCaretOffset(AccessibleTextEvent e) {
- e.offset = text.getCaretPosition();
- }
- });
-
- getAccessible().addAccessibleControlListener(
- new AccessibleControlAdapter() {
- public void getChildAtPoint(AccessibleControlEvent e) {
- Point testPoint = toControl(e.x, e.y);
- if (getBounds().contains(testPoint)) {
- e.childID = ACC.CHILDID_SELF;
- }
- }
-
- public void getLocation(AccessibleControlEvent e) {
- Rectangle location = getBounds();
- Point pt = toDisplay(location.x, location.y);
- e.x = pt.x;
- e.y = pt.y;
- e.width = location.width;
- e.height = location.height;
- }
-
- public void getChildCount(AccessibleControlEvent e) {
- e.detail = 0;
- }
-
- public void getRole(AccessibleControlEvent e) {
- e.detail = ACC.ROLE_COMBOBOX;
- }
-
- public void getState(AccessibleControlEvent e) {
- e.detail = ACC.STATE_NORMAL;
- }
-
- public void getValue(AccessibleControlEvent e) {
- e.result = getText();
- }
- });
-
- text.getAccessible().addAccessibleControlListener(
- new AccessibleControlAdapter() {
- public void getRole(AccessibleControlEvent e) {
- e.detail = text.getEditable() ? ACC.ROLE_TEXT
- : ACC.ROLE_LABEL;
- }
- });
-
- arrow.getAccessible().addAccessibleControlListener(
- new AccessibleControlAdapter() {
- public void getDefaultAction(AccessibleControlEvent e) {
- e.result = isDropped() ? SWT.getMessage("SWT_Close") : SWT.getMessage("SWT_Open"); //$NON-NLS-1$ //$NON-NLS-2$
- }
- });
- }
-
- boolean isDropped() {
- return popup.getVisible();
- }
-
- public boolean isFocusControl() {
- checkWidget();
- if (text.isFocusControl() || arrow.isFocusControl()
- || table.isFocusControl() || popup.isFocusControl()) {
- return true;
- }
- return super.isFocusControl();
- }
-
- void internalLayout(boolean changed) {
- if (isDropped()) {
- dropDown(false);
- }
- Rectangle rect = getClientArea();
- int width = rect.width;
- int height = rect.height;
- Point arrowSize = arrow.computeSize(SWT.DEFAULT, height, changed);
- text.setBounds(0, 0, width - arrowSize.x, height);
- arrow.setBounds(width - arrowSize.x, 0, arrowSize.x, arrowSize.y);
- }
-
- void tableEvent(Event event) {
- switch (event.type) {
- case SWT.Dispose:
- if (getShell() != popup.getParent()) {
- String[] items = getTableItems();
- int selectionIndex = table.getSelectionIndex();
- popup = null;
- table = null;
- createPopup(items, selectionIndex);
- }
- break;
- case SWT.FocusIn: {
- handleFocus(SWT.FocusIn);
- break;
- }
- case SWT.MouseUp: {
- if (event.button != 1) {
- return;
- }
- dropDown(false);
- break;
- }
- case SWT.Selection: {
- int index = table.getSelectionIndex();
- if (index == -1)
- return;
- text.setText(table.getItem(index).getText());
- text.selectAll();
- table.setSelection(index);
- Event e = new Event();
- e.time = event.time;
- e.stateMask = event.stateMask;
- e.doit = event.doit;
- notifyListeners(SWT.Selection, e);
- event.doit = e.doit;
- break;
- }
- case SWT.Traverse: {
- switch (event.detail) {
- case SWT.TRAVERSE_RETURN:
- case SWT.TRAVERSE_ESCAPE:
- case SWT.TRAVERSE_ARROW_PREVIOUS:
- case SWT.TRAVERSE_ARROW_NEXT:
- event.doit = false;
- break;
- }
- Event e = new Event();
- e.time = event.time;
- e.detail = event.detail;
- e.doit = event.doit;
- e.character = event.character;
- e.keyCode = event.keyCode;
- notifyListeners(SWT.Traverse, e);
- event.doit = e.doit;
- event.detail = e.detail;
- break;
- }
- case SWT.KeyUp: {
- Event e = new Event();
- e.time = event.time;
- e.character = event.character;
- e.keyCode = event.keyCode;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.KeyUp, e);
- break;
- }
- case SWT.KeyDown: {
- if (event.character == SWT.ESC) {
- // Escape key cancels popup list
- dropDown(false);
- }
- if ((event.stateMask & SWT.ALT) != 0
- && (event.keyCode == SWT.ARROW_UP || event.keyCode == SWT.ARROW_DOWN)) {
- dropDown(false);
- }
- if (event.character == SWT.CR) {
- // Enter causes default selection
- dropDown(false);
- Event e = new Event();
- e.time = event.time;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.DefaultSelection, e);
- }
- // At this point the widget may have been disposed.
- // If so, do not continue.
- if (isDisposed()) {
- break;
- }
- Event e = new Event();
- e.time = event.time;
- e.character = event.character;
- e.keyCode = event.keyCode;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.KeyDown, e);
- break;
-
- }
- }
- }
-
- void popupEvent(Event event) {
- switch (event.type) {
- case SWT.Paint:
- // draw black rectangle around list
- Rectangle listRect = table.getBounds();
- Color black = getDisplay().getSystemColor(SWT.COLOR_BLACK);
- event.gc.setForeground(black);
- event.gc.drawRectangle(0, 0, listRect.width + 1,
- listRect.height + 1);
- break;
- case SWT.Close:
- event.doit = false;
- dropDown(false);
- break;
- case SWT.Deactivate:
- dropDown(false);
- break;
- }
- }
-
- public void redraw() {
- super.redraw();
- text.redraw();
- arrow.redraw();
- if (popup.isVisible()) {
- table.redraw();
- }
- }
-
- public void redraw(int x, int y, int width, int height, boolean all) {
- super.redraw(x, y, width, height, true);
- }
-
- /**
- * Removes the item from the receiver's list at the given zero-relative
- * index.
- *
- * @param index
- * the index for the item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_INVALID_RANGE - if the index is not between 0
- * and the number of elements in the list minus 1 (inclusive)</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void remove(int index) {
- checkWidget();
- table.remove(index);
- }
-
- /**
- * Removes the items from the receiver's list which are between the given
- * zero-relative start and end indices (inclusive).
- *
- * @param start
- * the start of the range
- * @param end
- * the end of the range
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_INVALID_RANGE - if either the start or end are
- * not between 0 and the number of elements in the list minus
- * 1 (inclusive)</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void remove(int start, int end) {
- checkWidget();
- table.remove(start, end);
- }
-
- /**
- * Searches the receiver's list starting at the first item until an item is
- * found that is equal to the argument, and removes that item from the list.
- *
- * @param string
- * the item to remove
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * <li>ERROR_INVALID_ARGUMENT - if the string is not found
- * in the list</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void remove(String string) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- int index = Arrays.asList(getTableItems()).indexOf(string);
- table.remove(index);
- }
-
- /**
- * Removes all of the items from the receiver's list and clear the contents
- * of receiver's text field.
- * <p>
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void removeAll() {
- checkWidget();
- text.setText(""); //$NON-NLS-1$
- table.removeAll();
- }
-
- /**
- * Removes the listener from the collection of listeners who will be
- * notified when the receiver's text is modified.
- *
- * @param listener1
- * the listener which should no longer be notified
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the listener is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see ModifyListener
- * @see #addModifyListener
- */
- public void removeModifyListener(ModifyListener listener1) {
- checkWidget();
- if (listener1 == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- removeListener(SWT.Modify, listener1);
- }
-
- /**
- * Removes the listener from the collection of listeners who will be
- * notified when the receiver's selection changes.
- *
- * @param listener1
- * the listener which should no longer be notified
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the listener is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @see SelectionListener
- * @see #addSelectionListener
- */
- public void removeSelectionListener(SelectionListener listener1) {
- checkWidget();
- if (listener1 == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- removeListener(SWT.Selection, listener1);
- removeListener(SWT.DefaultSelection, listener1);
- }
-
- /**
- * Selects the item at the given zero-relative index in the receiver's list.
- * If the item at the index was already selected, it remains selected.
- * Indices that are out of range are ignored.
- *
- * @param index
- * the index of the item to select
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void select(int index) {
- checkWidget();
- if (index == -1) {
- table.deselectAll();
- text.setText(""); //$NON-NLS-1$
- return;
- }
- if (0 <= index && index < table.getItemCount()) {
- if (index != getSelectionIndex()) {
- text.setText(table.getItem(index).getText());
- text.selectAll();
- table.select(index);
- table.showSelection();
- }
- }
- }
-
- public void setBackground(Color color) {
- super.setBackground(color);
- background = color;
- if (text != null) {
- text.setBackground(color);
- }
- if (table != null) {
- table.setBackground(color);
- }
- if (arrow != null) {
- arrow.setBackground(color);
- }
- }
-
- /**
- * Sets the editable state.
- *
- * @param editable
- * the new editable state
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @since 3.0
- */
- public void setEditable(boolean editable) {
- checkWidget();
- text.setEditable(editable);
- }
-
- public void setEnabled(boolean enabled) {
- super.setEnabled(enabled);
- if (popup != null) {
- popup.setVisible(false);
- }
- if (text != null) {
- text.setEnabled(enabled);
- }
- if (arrow != null) {
- arrow.setEnabled(enabled);
- }
- }
-
- public boolean setFocus() {
- checkWidget();
- return text.setFocus();
- }
-
- public void setFont(Font font) {
- super.setFont(font);
- this.font = font;
- text.setFont(font);
- table.setFont(font);
- internalLayout(true);
- }
-
- public void setForeground(Color color) {
- super.setForeground(color);
- foreground = color;
- if (text != null) {
- text.setForeground(color);
- }
- if (table != null) {
- table.setForeground(color);
- }
- if (arrow != null) {
- arrow.setForeground(color);
- }
- }
-
- /**
- * Sets the text of the item in the receiver's list at the given
- * zero-relative index to the string argument. This is equivalent to
- * <code>remove</code>'ing the old item at the index, and then
- * <code>add</code>'ing the new item at that index.
- *
- * @param index
- * the index for the item
- * @param string
- * the new text for the item
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_INVALID_RANGE - if the index is not between 0
- * and the number of elements in the list minus 1 (inclusive)</li>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setItem(int index, String string) {
- checkWidget();
- table.getItem(index).setText(0, string);
- }
-
- /**
- * Sets the receiver's list to be the given array of items.
- *
- * @param items
- * the array of items
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the items array is null</li>
- * <li>ERROR_INVALID_ARGUMENT - if an item in the items
- * array is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setItems(String[] items) {
- checkWidget();
- if (items == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
-
- for (int i = 0; i < items.length; i++) {
- TableItem item = new TableItem(table, SWT.NONE);
- if (items[i].equals(defaultValue)) {
- item.setFont(JFaceResources.getFontRegistry().getBold(
- JFaceResources.DEFAULT_FONT));
- }
- item.setText(0, items[i]);
- }
- }
-
- /**
- * Sets the layout which is associated with the receiver to be the argument
- * which may be null.
- * <p>
- * Note : No Layout can be set on this Control because it already manages
- * the size and position of its children.
- * </p>
- *
- * @param layout
- * the receiver's new layout or null
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setLayout(Layout layout) {
- checkWidget();
- return;
- }
-
- /**
- * Sets the selection in the receiver's text field to the range specified by
- * the argument whose x coordinate is the start of the selection and whose y
- * coordinate is the end of the selection.
- *
- * @param selection
- * a point representing the new selection start and end
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the point is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setSelection(Point selection) {
- checkWidget();
- if (selection == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- text.setSelection(selection.x, selection.y);
- }
-
- /**
- * Sets the contents of the receiver's text field to the given string.
- * <p>
- * Note: The text field in a <code>Combo</code> is typically only capable
- * of displaying a single line of text. Thus, setting the text to a string
- * containing line breaks or other special characters will probably cause it
- * to display incorrectly.
- * </p>
- *
- * @param string
- * the new text
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_NULL_ARGUMENT - if the string is null</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setText(String string) {
- checkWidget();
- if (string == null) {
- SWT.error(SWT.ERROR_NULL_ARGUMENT);
- }
- int index = Arrays.asList(getTableItems()).indexOf(string);
- if (index == -1) {
- table.deselectAll();
- text.setText(string);
- return;
- }
- text.setText(string);
- text.selectAll();
- table.setSelection(index);
- table.showSelection();
- }
-
- /**
- * Sets the maximum number of characters that the receiver's text field is
- * capable of holding to be the argument.
- *
- * @param limit
- * new text limit
- *
- * @exception IllegalArgumentException
- * <ul>
- * <li>ERROR_CANNOT_BE_ZERO - if the limit is zero</li>
- * </ul>
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- */
- public void setTextLimit(int limit) {
- checkWidget();
- text.setTextLimit(limit);
- }
-
- public void setToolTipText(String string) {
- checkWidget();
- super.setToolTipText(string);
- arrow.setToolTipText(string);
- text.setToolTipText(string);
- }
-
- public void setVisible(boolean visible) {
- super.setVisible(visible);
- if (!visible) {
- popup.setVisible(false);
- }
- }
-
- /**
- * Sets the number of items that are visible in the drop down portion of the
- * receiver's list.
- *
- * @param count
- * the new number of items to be visible
- *
- * @exception org.eclipse.swt.SWTException
- * <ul>
- * <li>ERROR_WIDGET_DISPOSED - if the receiver has been
- * disposed</li>
- * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the
- * thread that created the receiver</li>
- * </ul>
- *
- * @since 3.0
- */
- public void setVisibleItemCount(int count) {
- checkWidget();
- if (count < 0) {
- return;
- }
- visibleItemCount = count;
- }
-
- String stripMnemonic(String string) {
- int index = 0;
- int length = string.length();
- do {
- while ((index < length) && (string.charAt(index) != '&')) {
- index++;
- }
- if (++index >= length) {
- return string;
- }
- if (string.charAt(index) != '&') {
- return string.substring(0, index - 1)
- + string.substring(index, length);
- }
- index++;
- } while (index < length);
- return string;
- }
-
- void textEvent(Event event) {
- switch (event.type) {
- case SWT.FocusIn: {
- handleFocus(SWT.FocusIn);
- break;
- }
- case SWT.KeyDown: {
- if (event.character == SWT.CR) {
- dropDown(false);
- Event e = new Event();
- e.time = event.time;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.DefaultSelection, e);
- }
- // At this point the widget may have been disposed.
- // If so, do not continue.
- if (isDisposed()) {
- break;
- }
-
- if (event.keyCode == SWT.ARROW_UP
- || event.keyCode == SWT.ARROW_DOWN) {
- event.doit = false;
- if ((event.stateMask & SWT.ALT) != 0) {
- boolean dropped = isDropped();
- text.selectAll();
- if (!dropped) {
- setFocus();
- }
- dropDown(!dropped);
- break;
- }
-
- int oldIndex = getSelectionIndex();
- if (event.keyCode == SWT.ARROW_UP) {
- select(Math.max(oldIndex - 1, 0));
- } else {
- select(Math.min(oldIndex + 1, getItemCount() - 1));
- }
- if (oldIndex != getSelectionIndex()) {
- Event e = new Event();
- e.time = event.time;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.Selection, e);
- }
- // At this point the widget may have been disposed.
- // If so, do not continue.
- if (isDisposed()) {
- break;
- }
- }
-
- // Further work : Need to add support for incremental search in
- // pop up list as characters typed in text widget
-
- Event e = new Event();
- e.time = event.time;
- e.character = event.character;
- e.keyCode = event.keyCode;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.KeyDown, e);
- break;
- }
- case SWT.KeyUp: {
- Event e = new Event();
- e.time = event.time;
- e.character = event.character;
- e.keyCode = event.keyCode;
- e.stateMask = event.stateMask;
- notifyListeners(SWT.KeyUp, e);
- break;
- }
- case SWT.Modify: {
- table.deselectAll();
- Event e = new Event();
- e.time = event.time;
- notifyListeners(SWT.Modify, e);
- break;
- }
- case SWT.MouseDown: {
- if (event.button != 1) {
- return;
- }
- if (text.getEditable()) {
- return;
- }
- boolean dropped = isDropped();
- text.selectAll();
- if (!dropped) {
- setFocus();
- }
- dropDown(!dropped);
- break;
- }
- case SWT.MouseUp: {
- if (event.button != 1) {
- return;
- }
- if (text.getEditable()) {
- return;
- }
- text.selectAll();
- break;
- }
- case SWT.Traverse: {
- switch (event.detail) {
- case SWT.TRAVERSE_RETURN:
- case SWT.TRAVERSE_ARROW_PREVIOUS:
- case SWT.TRAVERSE_ARROW_NEXT:
- // The enter causes default selection and
- // the arrow keys are used to manipulate the list contents so
- // do not use them for traversal.
- event.doit = false;
- break;
- }
-
- Event e = new Event();
- e.time = event.time;
- e.detail = event.detail;
- e.doit = event.doit;
- e.character = event.character;
- e.keyCode = event.keyCode;
- notifyListeners(SWT.Traverse, e);
- event.doit = e.doit;
- event.detail = e.detail;
- break;
- }
- }
- }
-
- /**
- * @param defaultValue
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- int index = Arrays.asList(getTableItems()).indexOf(defaultValue);
- if (index != -1) {
- table.getItem(index).setFont(
- JFaceResources.getFontRegistry().getBold(
- JFaceResources.DEFAULT_FONT));
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/UTF8Util.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/UTF8Util.java
deleted file mode 100644
index 31aac196b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/UTF8Util.java
+++ /dev/null
@@ -1,89 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-/**
- * TODO: this class doesn't seem to be in use
- * @author mengbo
- * @version 1.5
- */
-public final class UTF8Util {
- private static final char[] HEX_DIGITS = { '0', '1', '2', '3', '4', '5',
- '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' };
-
- /**
- * @param s
- * @return the unwound string
- */
- public static String unwindEscapeChars(String s) {
- StringBuffer sb = new StringBuffer(s.length());
- int length = s.length();
- for (int i = 0; i < length; i++) {
- char c = s.charAt(i);
- sb.append(getUnwoundString(c));
- }
- return sb.toString();
- }
-
- private static String getUnwoundString(char c) {
- switch (c) {
- case '\b':
- return "\\b";//$NON-NLS-1$
- case '\t':
- return "\\t";//$NON-NLS-1$
- case '\n':
- return "\\n";//$NON-NLS-1$
- case '\f':
- return "\\f";//$NON-NLS-1$
- case '\r':
- return "\\r";//$NON-NLS-1$
-
- // These can be used unescaped in properties file:
- case '\"':
- return "\\\"";//$NON-NLS-1$
- case '\'':
- return "\\\'";//$NON-NLS-1$
-
- case '\\':
- return "\\\\";//$NON-NLS-1$
-
- case '=':
- return "\\=";//$NON-NLS-1$
-
- // This is only done when writing to the .properties file in
- // #unwindValue(String)
- // case '!':
- // return "\\!";//$NON-NLS-1$
- // case '#':
- // return "\\#";//$NON-NLS-1$
-
- default:
- if (((c < 0x0020) || (c > 0x007e))) {
- return new StringBuffer().append('\\').append('u').append(
- toHex((c >> 12) & 0xF)).append(toHex((c >> 8) & 0xF))
- .append(toHex((c >> 4) & 0xF)).append(toHex(c & 0xF))
- .toString();
-
- }
- return String.valueOf(c);
- }
- }
-
- private static char toHex(int halfByte) {
- return HEX_DIGITS[(halfByte & 0xF)];
- }
-
- private UTF8Util()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WebrootUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WebrootUtil.java
deleted file mode 100644
index ff65eeba7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WebrootUtil.java
+++ /dev/null
@@ -1,256 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.Set;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.content.IContentType;
-import org.eclipse.core.runtime.content.IContentTypeManager;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.wst.common.componentcore.ComponentCore;
-import org.eclipse.wst.common.project.facet.core.IFacetedProject;
-import org.eclipse.wst.common.project.facet.core.IProjectFacet;
-import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
-import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
-
-/**
- * Web app utility methods
- */
-public class WebrootUtil {
-
- /**
- * get the webpath for the project path. The project path is something like
- * "/projectname/webroot/filename.jsp", or "/projectname/webroot/folder".
- * The project information should be removed from project path, e.g,
- * "/filename.jsp" or "/folder/*";
- *
- * @param path
- * @return the web path
- */
- public static String getWebPath(IPath path) {
- String strWebrootPath = ""; //$NON-NLS-1$
- IProject project = WorkspaceUtil.getProjectFor(path);
- IPath webContentPath = getWebContentPath(project);
- if (webContentPath != null && webContentPath.isPrefixOf(path)) {
- int start = path.matchingFirstSegments(webContentPath);
- String[] segments = path.segments();
- for (int i = start, n = path.segmentCount(); i < n; i++) {
- strWebrootPath = strWebrootPath
- + IFileFolderConstants.PATH_SEPARATOR + segments[i];
- }
- }
- return strWebrootPath;
- }
-
- /**
- * To see if a resource is under the webcontent folder.
- *
- * @param resource
- * @return true if resource is within the web content folder hierarchy
- */
- public static boolean isUnderWebContentFolder(IResource resource) {
- IPath webContentPath = getWebContentPath(resource.getProject());
- if (webContentPath != null) {
- return webContentPath.isPrefixOf(resource.getFullPath());
- }
- return true;
- }
-
- /**
- * @param project
- * @return full path to web content folder
- */
- public static IPath getWebContentPath(IProject project) {
- if (project != null) {
- return ComponentCore.createComponent(project).getRootFolder().getUnderlyingFolder().getFullPath();
- }
- return null;
- }
-
- /**
- * Return the name of the web content folder. i.e, "WebContent"
- *
- * @param project
- * @return the web content folder name
- */
- public static String getWebContentFolderName(IProject project) {
- IPath webContentPath = getWebContentPath(project);
- if (webContentPath != null)
- return webContentPath.lastSegment();
- return null;
- }
-
- /**
- * @param project
- * @return folder where for web content
- */
- public static IFolder getWebContentFolder(IProject project) {
- IPath webContentPath = getWebContentPath(project);
- IFolder folder = null;
- if (webContentPath != null) {
- folder = project.getFolder(webContentPath.removeFirstSegments(1));
- }
- return folder;
- }
-
- /**
- * return the depth of webcontent folder. For example, if the webcontent
- * folder path is /projectname/webContent, then return 2, if it's
- * /projectname/a/webContent, then return 3.
- *
- * @param project
- * @return the depth of webcontent folder
- */
- public static int getWebContentFolderDepth(IProject project) {
- if (project != null) {
- IPath webContentPath = getWebContentPath(project);
- if (webContentPath != null) {
- return webContentPath.segmentCount();
- }
- }
- // default to 2
- return 2;
- }
-
- /**
- * determine the path of web file is valid or not
- *
- * @param path -
- * the path of web file
- * @return - true - valid web file
- */
- public static boolean isValidWebFile(IPath path) {
- String[] jspExtensions = getJSPFileExtensions();
-
- String extension = path.getFileExtension();
- if (extension != null
- && Arrays.asList(jspExtensions).contains(extension))
- {
- return true;
- }
-
- return false;
- }
-
- /**
- * get the webpath for the project path. The project path is something like
- * "/projectname/webroot/filename.jsp", or "/projectname/webroot/folder".
- * The project information should be removed from project path, e.g,
- * "/filename.jsp" or "/folder/*";
- *
- * @param strPath -
- * the project path
- * @return - web path remove from "/projectname/webroot"
- * @deprecated use getWebPath(IPath path) instead.
- */
- public static String getWebPath(String strPath) {
- String strWebrootPath = ""; //$NON-NLS-1$
- if (strPath != null) {
- IPath path = new Path(strPath);
- return getWebPath(path);
- }
- return strWebrootPath;
- }
-
- /**
- * @param strWebPath
- * @return the page name
- */
- public static String getPageNameFromWebPath(String strWebPath) {
- String pageName = strWebPath;
-
- if (pageName.startsWith(IFileFolderConstants.PATH_SEPARATOR)) {
- pageName = pageName.substring(1);
- }
-
- String[] jspExtensions = getJSPFileExtensions();
- for (int i = 0, n = jspExtensions.length; i < n; i++) {
- String extension = IFileFolderConstants.DOT + jspExtensions[i];
- if (pageName.endsWith(extension)) {
- pageName = pageName.substring(0, pageName.length()
- - extension.length());
- break;
- }
- }
-
- return pageName;
- }
- /**
- * Get the JSP file extension from Eclipse preference
- * Windows->Preferences->General->Content Types
- *
- * @return String Array for JSP file extensions
- */
- public static String[] getJSPFileExtensions() {
- IContentTypeManager typeManager = Platform.getContentTypeManager();
- IContentType jspContentType = typeManager
- .getContentType("org.eclipse.jst.jsp.core.jspsource"); //$NON-NLS-1$
- if (jspContentType != null) {
- return jspContentType
- .getFileSpecs(IContentType.FILE_EXTENSION_SPEC);
- }
- return null;
- }
-
- /**
- * Tests if the passed IProject instance is a valid JSF project in the
- * following ways:
- * <ul>
- * <li>project is not null and is accessible, </li>
- * <li>project has the "jst.web" facet set on it.</li>
- * </ul>
- *
- * @param project
- * IProject instance to be tested.
- * @return true if the IProject instance is a valid JSF project, else false.
- */
- public static boolean isValidWebProject(IProject project) {
- boolean isValid = false;
- // check for null or inaccessible project
- if (project != null && project.isAccessible()) {
- // TODO: this was jst.jsf before, but we are checking for jst.web
- // the javadoc seems out of sync with the method name
- // check for "jst.web" facet on project
- try {
- IFacetedProject facetedProject = ProjectFacetsManager
- .create(project);
- if (facetedProject != null) {
- Set projectFacets = facetedProject.getProjectFacets();
- Iterator itProjectFacets = projectFacets.iterator();
- while (itProjectFacets.hasNext()) {
- IProjectFacetVersion projectFacetVersion = (IProjectFacetVersion) itProjectFacets
- .next();
- IProjectFacet projectFacet = projectFacetVersion
- .getProjectFacet();
- if ("jst.web".equals(projectFacet.getId())) { //$NON-NLS-1$
- isValid = true;
- break;
- }
- }
- }
- } catch (CoreException ce) {
- JSFUICommonPlugin.getLogger(WebrootUtil.class).error("checking web project", ce); //$NON-NLS-1$
- }
- }
- return isValid;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WorkspaceUtil.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WorkspaceUtil.java
deleted file mode 100644
index 6c5dcba5d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/WorkspaceUtil.java
+++ /dev/null
@@ -1,283 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.common.ui.internal.utils;
-
-import java.io.ByteArrayInputStream;
-import java.io.File;
-import java.io.InputStream;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRunnable;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-
-/**
- * TODO: This class should be abstract to common utility.
- *
- * This class implements management of resource in a workspace.
- */
-public final class WorkspaceUtil {
- /** log instance */
- private static final Logger log = JSFUICommonPlugin
- .getLogger(WorkspaceUtil.class);
-
- private WorkspaceUtil() {
- // no external instantiation
- }
-
- /**
- * Create the given file in the workspace resource info tree.
- * @param resource
- * @param contents
- */
- public static void ensureExistsInWorkspace(final IFile resource,
- final InputStream contents) {
- if (resource == null) {
- return;
- }
- IWorkspaceRunnable body = new IWorkspaceRunnable() {
- public void run(IProgressMonitor monitor) throws CoreException {
- if (resource.exists()) {
- resource.setContents(contents, true, false, null);
- } else {
- ensureExistsInWorkspace(resource.getParent(), true);
- resource.create(contents, true, null);
- }
- }
- };
- try {
- ResourcesPlugin.getWorkspace().run(body, null);
- } catch (CoreException e) {
- // Test.EclipseWorkspaceTest.Error.FileCreationInWorkspace = Fail in
- // creating file:{0} in the workspace resource info tree.
- log
- .error(
- "Test.EclipseWorkspaceTest.Error.FileCreationInWorkspace", resource.getName(), e);//$NON-NLS-1$
- }
- }
-
- /**
- * Create the given file in the workspace resource info tree.
- * @param resource
- * @param contents
- */
- public static void ensureExistsInWorkspace(IFile resource, String contents) {
- // FIXME: We'll need some way for handing file encoding.
- ensureExistsInWorkspace(resource, new ByteArrayInputStream(contents
- .getBytes()));
- }
-
- /**
- * Create the given resource in the workspace resource info tree.
- * @param resource
- * @param local
- */
- public static void ensureExistsInWorkspace(final IResource resource,
- final boolean local) {
- IWorkspaceRunnable body = new IWorkspaceRunnable() {
- public void run(IProgressMonitor monitor) throws CoreException {
- create(resource, local);
- }
- };
- try {
- ResourcesPlugin.getWorkspace().run(body, null);
- } catch (CoreException e) {
- // Test.EclipseWorkspaceTest.Error.ResourceCreationInWorkspace =
- // Fail in creating resource:{0} in the workspace resource info
- // tree.
- log
- .error(
- "Test.EclipseWorkspaceTest.Error.ResourceCreationInWorkspace", resource.getName(), e);//$NON-NLS-1$
- }
- }
-
- /**
- * crate the resource if the resource is not existed, create a new one.
- *
- * @param resource -
- * resource instance
- * @param local -
- * a flag controlling whether or not the folder will be local
- * after the creation
- * @throws CoreException
- */
- protected static void create(final IResource resource, boolean local)
- throws CoreException {
- if (resource == null || resource.exists()) {
- return;
- }
- if (!resource.getParent().exists()) {
- create(resource.getParent(), local);
- }
- switch (resource.getType()) {
- case IResource.FILE:
- ((IFile) resource).create(local ? new ByteArrayInputStream(
- new byte[0]) : null, true, getMonitor());
- break;
- case IResource.FOLDER:
- ((IFolder) resource).create(true, local, getMonitor());
- break;
- case IResource.PROJECT:
- ((IProject) resource).create(getMonitor());
- ((IProject) resource).open(getMonitor());
- break;
- }
- }
-
- /**
- * create and return a NullProgressMonitor
- *
- * @return - NullProgressMonitor
- */
- public static IProgressMonitor getMonitor() {
- return new NullProgressMonitor();
- }
-
- /**
- * Get the project reference for a given path
- *
- * @param path -
- * the path
- * @return IProject - the project reference
- */
- public static IProject getProjectFor(IPath path) {
- String[] segs = path.segments();
- String projectPath = new String();
- IProject[] projects = ResourcesPlugin.getWorkspace().getRoot()
- .getProjects();
- IProject project = null;
- for (int p = 0; p < projects.length; p++) {
- if (projects[p].isOpen()) {
- for (int s = 0; s < segs.length; s++) {
- if (segs[s].equalsIgnoreCase(projects[p].getName())) {
- // Once we have a match on the project name, then
- // the remainder of the segments equals the project path
- for (int s2 = s + 1; s2 < segs.length; s2++) {
- projectPath = projectPath
- + IFileFolderConstants.PATH_SEPARATOR
- + segs[s2];
- }
- project = projects[p];
- break;
- }
- }
- }
- }
- if (project == null) {
- return null;
- }
-
- // TODO: still don't understand why this refreshLocal is necessary
- // for now, going to only allow it if this method is called
- // when the tree isn't locked. This shouldn't cause a regression, since
- // when the call fails currently things keep on going due to the catch
- if (!project.getWorkspace().isTreeLocked())
- {
- try {
- project.refreshLocal(IResource.DEPTH_INFINITE, null);
- } catch (CoreException e) {
- // TODO C.B.:pushing this down to a warning because it creates really
- // spurious output. Don't know why we are calling refreshLocal at all.
- JSFUICommonPlugin.getLogger(WorkspaceUtil.class).info("Error.RefreshingLocal", e); //$NON-NLS-1$
- }
- }
-
- IResource res = project.findMember(new Path(projectPath));
- if ((res != null) && (res.exists())) {
- return project;
- }
- return null;
- }
-
- /**
- * Get the project reference for a given file
- *
- * @param file -
- * the IFile file reference
- * @return IProject - the project reference
- */
- public static IProject getProjectFor(IFile file) {
- IPath testPath = new Path(file.getFullPath().toOSString());
- return getProjectFor(testPath);
- }
-
- /**
- * Get the project reference for a given file
- *
- * @param file -
- * the File file reference
- * @return IProject - the project reference
- */
- public static IProject getProjectFor(File file) {
- IPath testPath = new Path(file.getAbsolutePath());
- return getProjectFor(testPath);
- }
-
- /**
- * Get the project-relative resource reference for a given path
- *
- * @param path -
- * the path
- * @return IResource - the project-relative resource
- */
- public static IResource getProjectRelativeResource(IPath path) {
- String[] segs = path.segments();
- String projectPath = new String();
- IProject[] projects = ResourcesPlugin.getWorkspace().getRoot()
- .getProjects();
- IProject project = null;
- for (int p = 0; p < projects.length; p++) {
- if (projects[p].isOpen()) {
- for (int s = 0; s < segs.length; s++) {
- if (segs[s].equalsIgnoreCase(projects[p].getName())) {
- // Once we have a match on the project name, then
- // the remainder of the segments equals the project path
- for (int s2 = s + 1; s2 < segs.length; s2++) {
- projectPath = projectPath
- + IFileFolderConstants.PATH_SEPARATOR
- + segs[s2];
- }
- project = projects[p];
- break;
- }
- }
- }
- }
- if (project == null) {
- return null;
- }
-
- return project.getFile(projectPath);
- }
-
- /**
- * Get the project-relative resource reference for a given file
- *
- * @param file -
- * the File file reference
- * @return IResource - the project-relative resource
- */
- public static IResource getProjectRelativeResource(File file) {
- IPath testPath = new Path(file.getAbsolutePath());
- return getProjectRelativeResource(testPath);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.classpath b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.cvsignore
deleted file mode 100644
index 40e79ad80..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-build.xml
-javaCompiler...args
-@dot
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.project b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.project
deleted file mode 100644
index ca987a4db..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.facesconfig.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/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.core.resources.prefs b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index c9896cd05..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Sun May 27 16:03:23 EDT 2007
-eclipse.preferences.version=1
-encoding/<project>=ISO-8859-1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 9d11d524e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,82 +0,0 @@
-#Mon Jun 30 15:56:09 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-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.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=warning
-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=ignore
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
-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=warning
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-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=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
-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=ignore
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=error
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.ui.prefs b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 82eb6c152..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Fri Apr 06 18:25:15 PDT 2007
-eclipse.preferences.version=1
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates/>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index cd8bbb33e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 11:55:44 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.wst.validation.prefs b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.wst.validation.prefs
deleted file mode 100644
index 97e2fd230..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/.settings/org.eclipse.wst.validation.prefs
+++ /dev/null
@@ -1,6 +0,0 @@
-#Tue Apr 25 16:26:29 CST 2006
-DELEGATES_PREFERENCE=delegateValidatorListorg.eclipse.wst.wsdl.validation.internal.eclipse.WSDLDelegatingValidator\=org.eclipse.wst.wsdl.validation.internal.eclipse.Validator;org.eclipse.wst.xsd.core.internal.validation.eclipse.XSDDelegatingValidator\=org.eclipse.wst.xsd.core.internal.validation.eclipse.Validator;
-USER_BUILD_PREFERENCE=enabledBuildValidatorListorg.eclipse.wst.dtd.core.internal.validation.eclipse.Validator;org.eclipse.jst.jsp.core.internal.validation.JSPELValidator;org.eclipse.wst.wsdl.validation.internal.eclipse.WSDLDelegatingValidator;org.eclipse.jst.jsp.core.internal.validation.JSPJavaValidator;org.eclipse.wst.xml.core.internal.validation.eclipse.Validator;org.eclipse.wst.html.internal.validation.HTMLValidator;org.eclipse.wst.wsi.ui.internal.WSIMessageValidator;org.eclipse.jst.jsp.core.internal.validation.JSPDirectiveValidator;org.eclipse.wst.xsd.core.internal.validation.eclipse.XSDDelegatingValidator;
-USER_MANUAL_PREFERENCE=enabledManualValidatorListorg.eclipse.wst.dtd.core.internal.validation.eclipse.Validator;org.eclipse.jst.jsp.core.internal.validation.JSPELValidator;org.eclipse.wst.wsdl.validation.internal.eclipse.WSDLDelegatingValidator;org.eclipse.jst.jsp.core.internal.validation.JSPJavaValidator;org.eclipse.wst.xml.core.internal.validation.eclipse.Validator;org.eclipse.wst.html.internal.validation.HTMLValidator;org.eclipse.wst.wsi.ui.internal.WSIMessageValidator;org.eclipse.jst.jsp.core.internal.validation.JSPDirectiveValidator;org.eclipse.wst.xsd.core.internal.validation.eclipse.XSDDelegatingValidator;
-USER_PREFERENCE=overrideGlobalPreferencesfalse
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index b3547838f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,57 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %plugin.name
-Bundle-SymbolicName: org.eclipse.jst.jsf.facesconfig.ui;singleton:=true
-Bundle-Version: 1.1.3.qualifier
-Bundle-Activator: org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin
-Bundle-Vendor: %plugin.provider
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jdt.core;bundle-version="[3.2.0,4.0.0)",
- 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.help;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.gef;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.xml.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.sse.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.xml.ui;bundle-version="[1.0.100,1.2.0)",
- org.eclipse.emf.ecore.xmi;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.jst.jsp.core;bundle-version="[1.1.0,1.3.0)",
- org.eclipse.wst.sse.ui;bundle-version="[1.0.101,1.2.0)",
- org.eclipse.jface.text;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.common.emf;bundle-version="[1.1.103,2.0.0)",
- org.eclipse.jst.jsf.facesconfig;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.wst.common.project.facet.core;bundle-version="[1.2.0,2.0.0)",
- org.eclipse.emf.edit.ui;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.jst.jsf.common.ui;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.jdt.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jst.jsf.core;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.ui.ide;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.common.modulecore;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.ui.views.properties.tabbed;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.0.0,2.0.0)"
-Bundle-ActivationPolicy: lazy
-Export-Package: org.eclipse.jst.jsf.facesconfig.ui;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.dialog;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.page;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.page.detail;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.action;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.icons;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.layout;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.preference;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.provider;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.section;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.util;x-internal:=true,
- org.eclipse.jst.jsf.facesconfig.ui.wizard;x-internal:=true
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/about.html b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/about.html
deleted file mode 100644
index 8e5605900..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/build.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/build.properties
deleted file mode 100644
index e34e43f5a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/build.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- icons/,\
- plugin.xml,\
- plugin.properties,\
- cheatsheets/,\
- about.html
-javacSource=1.5
-javacTarget=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/cheatsheets/facesconfigeditor.xml b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/cheatsheets/facesconfigeditor.xml
deleted file mode 100644
index aed958f96..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/cheatsheets/facesconfigeditor.xml
+++ /dev/null
@@ -1,276 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<cheatsheet title="Faces Configuration Editor">
-
- <intro
- href="/org.eclipse.platform.doc.user/reference/ref-cheatsheets.htm">
- <description>
- This cheat sheet will demonstrate how to edit a JSF
- configuration file with Faces Config Editor.
- <br />
- <br />
- To learn more about using cheat sheets, click the help
- button in the top right corner (?).
- </description>
- </intro>
-
- <!-- Item -->
-
- <item title="Open the J2EE perspective"
- href="/org.eclipse.jst.j2ee.doc.user/topics/cjpers.html"
- dialog="false" skip="true">
- <description>
- To open the J2EE perspective, select
- <b>Window-&gt;Open Perspective-&gt;Other...</b>
- and choose
- <b>J2EE</b>
- .
- <br />
- <br />
- Alternatively, click the following button to perform the
- task.
- </description>
- <command
- serialization="org.eclipse.ui.perspectives.showPerspective(org.eclipse.ui.perspectives.showPerspective.perspectiveId=org.eclipse.jst.j2ee.J2EEPerspective)" />
- </item>
-
- <!-- Item -->
-
- <item title="Create the JSF web project"
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/create_jsf_app.html"
- dialog="true" skip="false">
- <description>
- To create the JSF web application perform the following
- steps
- </description>
- <subitem
- label="Select &quot;File-&gt;New-&gt;Project...&quot; from the main menu and choose &quot;Dynamic Web Project&quot; from the resulting &quot;New Project&quot; dialog box"
- skip="false">
- <command
- serialization="org.eclipse.ui.newWizard(newWizardId=org.eclipse.jst.servlet.ui.project.facet.WebProjectWizard)" />
- </subitem>
- <subitem
- label="Input &quot;JSFApplication&quot; into the &quot;Project Name&quot; text box"
- skip="false" />
- <subitem
- label="Select &quot;JavaServer Faces v1.1 Project&quot; in the &quot;Configurations&quot; dropdown box"
- skip="false" />
- <subitem
- label="Accept the rest of the default preloaded values on the &quot;Dynamic Web Project&quot; page and click &quot;Next&quot;"
- skip="false" />
- <subitem
- label="Accept the rest of the default preloaded values on the &quot;Project Facets&quot; page and click &quot;Next&quot;"
- skip="false" />
- <subitem
- label="Accept the rest of the default preloaded values on the &quot;Web Module&quot; page and click &quot;Next&quot;"
- skip="false" />
- <subitem
- label="Specify JSF Facet Settings on the &quot;JSF Capabilities&quot; page and click &quot;Finish&quot;"
- skip="false" />
- </item>
-
- <item title="Open the JSF configuration file"
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/use_facesconfig_editor.html"
- dialog="true" skip="false">
- <description>
- To open the JSF configuration file, Expand the
- WebContent/WEB-INF/ folder in the &quot;Project
- Explorer&quot; view; Double click on the
- &quot;faces-config.xml&quot; file to open it. Or right click
- on it then select &quot;Open With&quot; -> &quot;FacesConfig
- Editor&quot;
- </description>
- <subitem
- label="Expand the /JSFApplication/WebContent/WEB-INF/ folder in the &quot;Project Explorer&quot; view; "
- skip="true">
- </subitem>
- <subitem
- label="Double click on the &quot;faces-config.xml&quot; file to open it.
- Or right click on it then select &quot;Open With&quot; -> &quot;FacesConfig Editor&quot;"
- skip="false">
- <command
- serialization="org.eclipse.ui.navigate.openResource(filePath=JSFApplication/WebContent/WEB-INF/faces-config.xml)" />
- </subitem>
- </item>
-
-
- <item href=" " title="Get an introduction on the FacesConfig Editor"
- dialog="false" skip="true">
- <description>
- On the &quot;Introduction &quot; page, there are some
- introductions about the FacesConfig Editor, and some links
- to start work with it, or show user the tutorial and help
- documentation.
- </description>
- </item>
-
-
- <item href=" " title="Get an overview of the content" dialog="false"
- skip="true">
- <description>
- On the &quot;Overview &quot; page, there are several tables
- that list the main elements defined in the current faces
- config file. By double-clicking on an element, user could be
- guided to the corresponding page to edit it.
- </description>
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/define_navigations.html"
- title="Create a Navigation Rule">
- <description>
- To create a navigation rule perform the following steps
- </description>
- <subitem
- label="Use the JSP Page wizard to create a page called &quot; login.jsp &quot; in the Web Content folder of the new application.
- In the Select Templates page of the wizard, select the &quot;New JSP(html) &quot; template. Click Finish."
- skip="false">
- <command
- serialization="org.eclipse.ui.newWizard(newWizardId=org.eclipse.jst.jsp.ui.internal.wizard.NewJSPWizard)" />
- </subitem>
- <subitem
- label="In the same way, create a page called &quot;welcome.jsp &quot; ."
- skip="false">
- <command
- serialization="org.eclipse.ui.newWizard(newWizardId=org.eclipse.jst.jsp.ui.internal.wizard.NewJSPWizard)" />
- </subitem>
- <subitem
- label="Select the &quot;Page&quot; control from the &quot;Palette&quot; and drop it on the &quot;Navigation&quot; tab.
- Choose the page in the resulting &quot;Select JSP File&quot; dialog. "
- skip="false" />
- <subitem
- label="Connect the two pages. Click on the &quot;Link&quot; control in the &quot;Palette&quot;, select the &quot;login&quot; page and draw a line to the &quot;welcome&quot; page.
- Select the line in the &quot;Navigation&quot; tab and in the property view, set the value of the &quot;from-outcome&quot; to &quot;login&quot; . "
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a navigation-rule element created."
- skip="false" />
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/create_managedbean.html"
- title="Create a Managed Bean">
- <description>
- To create a managed bean perform the following steps
- </description>
- <subitem
- label="Switch to the &quot;ManagedBean&quot; page; click the &quot;New&quot; button, the new managed bean wizard pops up."
- skip="false" />
- <subitem
- label="On the &quot;Java Class Selection&quot; page, choose &quot;Create a new Java class&quot;, then click &quot;Next&quot;."
- skip="false" />
- <subitem
- label="On the &quot;Java Class&quot; page, input &quot;com.tutorial&quot; into the &quot;Package&quot; field and input &quot;LoginBean&quot; into the &quot;Name&quot; field,
- then click &quot;Next&quot; to the next page."
- skip="false" />
- <subitem
- label="On the &quot;Managed Bean Configuration&quot; page, accept the default values and click &quot;Finish&quot; to finish this wizard."
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a managed-bean element created."
- skip="true" />
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/facesconfig_ui/add_component.html"
- title="Create a Component">
- <description>
- To create a component perform the following steps
- </description>
- <subitem
- label="Switch to the &quot;Component&quot; page; expand the &quot;Components&quot; section; "
- skip="false" />
- <subitem
- label="Click the &quot;New&quot; button, a new empty component element is created."
- skip="false" />
- <subitem
- label="On the right part, fill in the essential fields for this component, for example &quot;Component Type&quot;, &quot;Component Class&quot;."
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a component element created."
- skip="false" />
- </item>
-
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/facesconfig_ui/add_converter.html"
- title="Create a Converter">
- <description>
- To create a converter perform the following steps
- </description>
- <subitem
- label="Switch to the &quot;Component&quot; page; expand the &quot;Converters&quot; section; "
- skip="false" />
- <subitem
- label="Click the &quot;New&quot; button, a new empty converter element is created."
- skip="false" />
- <subitem
- label="On the right part, fill in the essential fields for this converter, for example &quot;Converter ID&quot;, &quot;Converter Class&quot;."
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a converter element created."
- skip="false" />
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/facesconfig_ui/add_renderkit.html"
- title="Create a Render Kit">
- <description>
- To create a render-kit perform the following steps
- </description>
- <subitem
- label="Switch to the &quot;Component&quot; page; expand the &quot;RenderKits&quot; section; "
- skip="false" />
- <subitem
- label="Click the &quot;New&quot; button, a new empty render-kit element is created."
- skip="false" />
- <subitem
- label="On the right part, fill in the essential fields for this converter, for example &quot;Renderkit ID&quot;, &quot;Renderkit Class&quot;."
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a render-kit element created."
- skip="false" />
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/facesconfig_ui/add_validator.html"
- title="Create a Validator">
- <description>
- To create a validator perform the following steps
- </description>
- <subitem
- label="Switch to the &quot;Component&quot; page; expand the &quot;Validators&quot; section; "
- skip="false" />
- <subitem
- label="Click the &quot;New&quot; button, a new empty validator element is created."
- skip="false" />
- <subitem
- label="On the right part, fill in the essential fields for this converter, for example &quot;Validator ID&quot;, &quot;Validator Class&quot;."
- skip="false" />
- <subitem
- label="Swith to the &quot;Source&quot; page, will find that there is a validator element created."
- skip="false" />
- </item>
-
- <item
- href="/org.eclipse.jst.jsf.doc.user/html/tasks/use_facesconfig_editor.html"
- title="Editing other elements on the Others Page">
- <description>
- On the &quot;Others&quot; page, there are several sections
- for editing the elements such as
- &quot;action-listener&quot;, &quot;locale-config&quot;, and
- so on.
- </description>
- </item>
-
- <item title="Source Page">
- <description>
- The &quot;Source&quot; page is a embeded XML editor, user can edit the xml source of faces config directly here.
- </description>
- </item>
-
- <item title="Completion">
- <description>
- Congratulations, you should now be able to use this editor fluently.
- </description>
- </item>
-</cheatsheet> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_GotoEditor.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_GotoEditor.gif
deleted file mode 100644
index 0e5bcf65a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_GotoEditor.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Introduction.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Introduction.gif
deleted file mode 100644
index 44cd0448b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Introduction.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Tutorial.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Tutorial.gif
deleted file mode 100644
index ad8e5b6b9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/FacesConfig_Tutorial.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope.gif
deleted file mode 100644
index d49078b11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Application.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Application.gif
deleted file mode 100644
index 591ceb204..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Application.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_None.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_None.gif
deleted file mode 100644
index 0a96aaa28..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_None.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Request.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Request.gif
deleted file mode 100644
index e875d0115..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Request.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Session.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Session.gif
deleted file mode 100644
index cbe011bec..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/Scope_Session.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_ManagedBean.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_ManagedBean.gif
deleted file mode 100644
index 6cdef7bd6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_ManagedBean.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Pageflow16.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Pageflow16.gif
deleted file mode 100644
index 5ea67da7a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Pageflow16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Plugin.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Plugin.gif
deleted file mode 100644
index 5ea67da7a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/FacesConfig_Plugin.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Action16.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Action16.gif
deleted file mode 100644
index c241f5f7e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Action16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_BooleanValue.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_BooleanValue.gif
deleted file mode 100644
index 5002791a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_BooleanValue.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_GenericValue.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_GenericValue.gif
deleted file mode 100644
index 7ef81e587..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_GenericValue.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_IntegralValue.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_IntegralValue.gif
deleted file mode 100644
index fea95ce77..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_IntegralValue.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link.gif
deleted file mode 100644
index 6c10cea7a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link24.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link24.gif
deleted file mode 100644
index 8004b1961..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Link24.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline.gif
deleted file mode 100644
index f302d8c88..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline_Overview.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline_Overview.gif
deleted file mode 100644
index 852dc81ba..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Outline_Overview.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page.gif
deleted file mode 100644
index 97cafa9a8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page16.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page16.gif
deleted file mode 100644
index 5b56ee385..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page16.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page24.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page24.gif
deleted file mode 100644
index 2fc426f43..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Page24.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Quickfix_Error.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Quickfix_Error.gif
deleted file mode 100644
index 1f0002b37..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_Quickfix_Error.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_TextValue.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_TextValue.gif
deleted file mode 100644
index d483f4861..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/facesconfig/Pageflow_TextValue.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/form_banner.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/form_banner.gif
deleted file mode 100644
index aebc0b2a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/form_banner.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/help.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/help.gif
deleted file mode 100644
index 9d70301da..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/help.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/overview_obj.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/overview_obj.gif
deleted file mode 100644
index 03f656f3e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/icons/overview_obj.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties
deleted file mode 100644
index f8d99a513..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.properties
+++ /dev/null
@@ -1,60 +0,0 @@
-############################################################################
-# Copyright (c) 2004, 2005 Sybase, Inc. 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:
-# Sybase, Inc. - initial API and implementation
-############################################################################
-plugin.name=JavaServer Faces Tools - FacesConfig Editor
-plugin.provider=Eclipse.org
-
-# Editors
-facesConfigEditor=Faces Config Editor
-facesConfigEditorIcon=icons/facesconfig/FacesConfig_Plugin.gif
-
-# Introduction
-pageflow.editor.intro.name = Introduction
-pageflow.editor.intro.description =
-pageflow.editor.intro.section.heading = The Faces Configuration Editor
-pageflow.editor.intro.section.description = The faces configuration editor helps you to complete the JSF web application development process by allowing you to edit faces configuration. Use the pages in this editor to define and edit page navigations, managed beans, component, converter, validator, renderkit and other element configurations.
-pageflow.editor.intro.cheatsheets.link = Tutorial
-pageflow.editor.intro.cheatsheets.text = Launch the cheat sheet for guidance in working with the editor.
-pageflow.editor.intro.help.link = Help
-pageflow.editor.intro.help.text = Launch the help system and review topics about working with faces configuration descriptor.
-pageflow.editor.intro.start.link = Start
-pageflow.editor.intro.start.text = Start working with the editor by selecting PageFlow and defining page navigations.
-
-#overview Section
-pageflow.editor.overview.name = Editor Information
-pageflow.editor.overview.description = This page summaries the editors information.
-pageflow.editor.overview.pageflow.link = PageFlow Editor
-pageflow.editor.overview.pageflow.text = Editor to create or modify Navigation Rules.
-
-pageflow.editor.intro.overview.mbean.text = Editor to create or modify Managed Beans.
-pageflow.editor.overview.mbean.link = ManagedBeans Editor
-pageflow.editor.intro.overview.components.text = Editor to create or modify component elements.
-pageflow.editor.overview.components.link = Components Editor
-pageflow.editor.intro.overview.others.text = Editor to create or modify other elements.
-pageflow.editor.overview.others.link = Others Editor
-pageflow.editor.intro.overview.source.text = Text Editor source.
-pageflow.editor.overview.source.link = Source Editor
-
-contentType.defaultFacesConfig.name = Default FacesConfig File
-contentType.webdotxmlfile.name = Web Application Description File
-
-#property tab's name
-propertyTab.general=Attributes
-propertyTab.attribute=Quick Edit
-
-# Cheatsheets
-cheatsheet.pagefloweditor.name = Pageflow Editor Cheat Sheet
-cheatsheet.pagefloweditor.description = Cheat Sheet for using the Pageflow Editor
-cheatsheet.jsf.title=JSF Development
-cheatsheet.jsf.facesconfig.title=Faces Configuration Editor
-
-#preference page
-preferencepage.jsffacesconfigui.name=FacesConfig Editor
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml
deleted file mode 100644
index be992240f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/plugin.xml
+++ /dev/null
@@ -1,109 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin>
- <extension
- point="org.eclipse.ui.preferencePages">
- <page
- category="org.eclipse.jst.jsf.ui.JSFRootPage"
- class="org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences"
- id="org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences"
- name="%preferencepage.jsffacesconfigui.name"/>
- </extension>
- <extension point="org.eclipse.ui.editors">
-
- <editor
- class="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"
- contributorClass="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigActionBarContributor"
- default="false"
- icon="icons/facesconfig/FacesConfig_Plugin.gif"
- id="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"
- name="%facesConfigEditor">
- <contentTypeBinding
- contentTypeId="org.eclipse.jst.jsf.facesconfig.facesConfigFile" />
- </editor>
- </extension>
-
- <!-- ********** Introduction Page of PageFlow editor************** -->
- <extension id="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"
- name="%pageflow.editor.intro.name"
- point="org.eclipse.jst.jsf.common.ui.introductionPage">
- <introductionpage name="%pageflow.editor.intro.name"
- description="%pageflow.editor.intro.description">
- <introductionelement icon="icons/FacesConfig_Introduction.gif"
- heading="%pageflow.editor.intro.section.heading"
- text="%pageflow.editor.intro.section.description"/>
- <introductionelement
- actionparameters="org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor"
- icon="icons/FacesConfig_GotoEditor.gif"
- hyperlinkaction="org.eclipse.jst.jsf.common.ui.internal.actions.OpenPageAction"
- text="%pageflow.editor.intro.start.text"
- hyperlink="%pageflow.editor.intro.start.link"/>
- <introductionelement
- actionparameters="FacesConfigEditor.CheatSheet"
- icon="icons/FacesConfig_Tutorial.gif"
- hyperlinkaction="org.eclipse.jst.jsf.common.ui.internal.actions.LoadCheatSheetAction"
- text="%pageflow.editor.intro.cheatsheets.text"
- hyperlink="%pageflow.editor.intro.cheatsheets.link"/>
- <introductionelement actionparameters="org.eclipse.jst.jsf.facesconfig.ui.use_facesconfig_editor"
- icon="icons/overview_obj.gif"
- hyperlinkaction="org.eclipse.jst.jsf.common.ui.internal.actions.LoadHelpAction"
- text="%pageflow.editor.intro.help.text"
- hyperlink="%pageflow.editor.intro.help.link"/>
- </introductionpage>
- </extension>
- <!-- ********** End Introduction Page ************** -->
- <!-- ************* properties view ************** -->
- <extension point="org.eclipse.ui.views.properties.tabbed.propertyTabs">
- <propertyTabs
- contributorId="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor">
- <propertyTab label="%propertyTab.attribute" category="attribute"
- id="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.attribute"/>
- <propertyTab label="%propertyTab.general" category="general"
- id="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.general"/>
- </propertyTabs>
- </extension>
- <extension point="org.eclipse.ui.views.properties.tabbed.propertyContributor">
- <propertyContributor
- sectionDescriptorProvider="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowSectionDescriptorProvider"
- contributorId="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"
- labelProvider="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowSectionLabelProvider">
- <propertyCategory category="attribute" />
- <propertyCategory category="general"/>
- </propertyContributor>
- </extension>
- <extension
- point="org.eclipse.ui.cheatsheets.cheatSheetContent">
- <cheatsheet
- category="org.eclipse.jst.jsf"
- composite="false"
- contentFile="$nl$/cheatsheets/facesconfigeditor.xml"
- id="FacesConfigEditor.CheatSheet"
- name="%cheatsheet.jsf.facesconfig.title"/>
- <category
- id="org.eclipse.jst.jsf"
- name="%cheatsheet.jsf.title">
- </category>
- </extension>
- <!--<extension
- point="org.eclipse.ui.views.properties.tabbed.propertyContributor">
- <propertyContributor
- contributorId="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"
- labelProvider="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowSectionLabelProvider">
- <propertyCategory category="attribute"/>
- <propertyCategory category="general"/>
- </propertyContributor>
- </extension>
- <extension
- point="org.eclipse.ui.views.properties.tabbed.propertyTabs">
- <propertyTabs contributorId="org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor">
- <propertyTab
- category="attribute"
- id="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.attribute"
- label="%propertyTab.attribute"/>
- <propertyTab
- category="general"
- id="org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.general"
- label="%propertyTab.general"/>
- </propertyTabs>
- </extension>-->
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.java
deleted file mode 100644
index 274c5d852..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.java
+++ /dev/null
@@ -1,1567 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Provides localized messages from EditorMessages.properties.
- */
-public final class EditorMessages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.facesconfig.ui.EditorMessages"; //$NON-NLS-1$
-
- private EditorMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, EditorMessages.class);
- }
-
- /**
- * see EditorMessages.properties
- */
- public static String AddEditManagedPropertyDialog_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String AddEditManagedPropertyDialog_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String AddEditMapEntryDialog_NullValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_ErrorHandlingUndoConflicts_DialogMessage;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_ErrorHandlingUndoConflicts_DialogTitle;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_WaitForLoad_EditorTabTitle;
-
- /**
- * see EditorMessages.properties
- */
- public static String UI_Button_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String UI_Button_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String UI_Button_Remove;
-
- /**
- * see EditorMessages.properties
- */
- public static String UI_Button_Add_more;
-
- /**
- * see EditorMessages.properties
- */
- public static String UI_Button_Edit_more;
-
- /**
- * see EditorMessages.properties
- */
- public static String Remove_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String Remove_Msg;
-
- /**
- * see EditorMessages.properties
- */
- public static String FindType;
-
- /**
- * see EditorMessages.properties
- */
- public static String FindType_Filter;
-
- /**
- * see EditorMessages.properties
- */
- public static String FindType_Error_CannotFindType;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Introduction_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Overview_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Pageflow_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_ManagedBeans_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Components_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Others_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Source_TabName;
-
- /**
- * see EditorMessages.properties
- */
- public static String editor_pageflow_page_intro_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String editor_pageflow_page_intro_title;
-
- /**
- * see EditorMessages.properties
- */
- public static String editor_pageflow_page_intro_help_HelpContextID;
-
- /**
- * see EditorMessages.properties
- */
- public static String editor_pageflow_page_intro_help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanMasterSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanMasterSection_Description;
-
-// public static String ManagedBeanMasterSection_HelpContextID;
-//
-// public static String ManagedBeanMasterSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanGeneralSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanGeneralSection_Desc;
-
-// public static String ManagedBeanGeneralSection_HelpContextID;
-//
-// public static String ManagedBeanGeneralSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanGeneralSection_ManagedBeanName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanGeneralSection_ManagedBeanClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanGeneralSection_ManagedBeanScope;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_Description;
-
-// public static String InitializationSection_HelpContextID;
-//
-// public static String InitializationSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Title_NewPropertyEntry;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Title_ExistingPropertyEntry;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_PropertyName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_PropertyClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_PropertyClass_Browse;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_ValueType;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanProeprtyEditPage_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Value;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditWizard_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanProeprtyEditPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Value_Change;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_FindType;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_FindType_Filter;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ClassType;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ClassType_General;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ClassType_Map;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ClassType_List;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_PropertyTable_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_PropertyTable_Class;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_PropertyTable_Value;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_MapType_KeyClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_MapType_ValueClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_MapTable_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_MapTable_Key;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_MapTable_Value;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ListType_ValueClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ListTable_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String InitializationSection_ListTable_Value;
-
- /**
- * see EditorMessages.properties
- */
- public static String ListEntriesEditPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ListEntriesWizard_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ListEntriesEditPage_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_page_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_page_id;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_page_title;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_PageflowOverview_summary;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_EditorSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_EditorSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_EditorSection_noplugin;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_EditorSection_nooverview;
-
-// public static String OverviewPage_EditorSection_Help_HelpContextID;
-//
-// public static String OverviewPage_EditorSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_GeneralSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_GeneralSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_GeneralSection_label_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_GeneralSection_label_version;
-
-// public static String OverviewPage_GeneralSection_Help_HelpContextID;
-//
-// public static String OverviewPage_GeneralSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_table_col1;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_table_col2;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_table_col3;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_NavigationSection_pageflowPageID;
-
-// public static String OverviewPage_NavigationSection_Help_HelpContextID;
-//
-// public static String OverviewPage_NavigationSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_table_namecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_table_scopecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_table_classcol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ManagedBeanSection_managedbeanPageID;
-
-// public static String OverviewPage_ManagedBeanSection_Help_HelpContextID;
-//
-// public static String OverviewPage_ManagedBeanSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ComponentsSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ComponentsSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ComponentsSection_table_typecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ComponentsSection_table_namecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_ComponentsSection_componentsPageID;
-
-// public static String OverviewPage_ComponentsSection_Help_HelpContextID;
-//
-// public static String OverviewPage_ComponentsSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_name;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_description;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_table_typecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_table_namecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_table_valuecol;
-
- /**
- * see EditorMessages.properties
- */
- public static String OverviewPage_OthersSection_othersPageID;
-
-// public static String OverviewPage_OthersSection_Help_HelpContextID;
-//
-// public static String OverviewPage_OthersSection_Help_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyGroup_error_EmptyName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ManagedBeanPropertyGroup_error_EmptyClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntriesEditGroup_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntriesEditPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntriesWizard_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditGroup_Key;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditGroup_error_EmptyKey;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditGroup_error_DuplicateKey;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditWizard_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntriesEditPage_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String MapEntryEditPage_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValueEditDialog_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValueEditWizard_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValueEditPage_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValueEditGroup_Value;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValueEditPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentsPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentMasterSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentMasterSection_Description;
-
-// public static String ComponentMasterSection_HelpContextID;
-//
-// public static String ComponentMasterSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Description;
-
-// public static String ComponentGeneralSection_HelpContextID;
-//
-// public static String ComponentGeneralSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Label_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Label_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Label_ComponentType;
-
- /**
- * see EditorMessages.properties
- */
- public static String ComponentGeneralSection_Label_ComponentClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitMasterSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitMasterSection_Description;
-
-// public static String RenderKitMasterSection_HelpContextID;
-//
-// public static String RenderKitMasterSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Description;
-
-// public static String RenderKitGeneralSection_HelpContextID;
-//
-// public static String RenderKitGeneralSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Label_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Label_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Label_RenderKitID;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitGeneralSection_Label_RenderKitClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Description;
-
-// public static String RendererSection_HelpContextID;
-//
-// public static String RendererSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Table_NameColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Table_ComponentFamilyColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Table_TypeColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Table_ClassColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Title_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Title_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Tab_General;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_ComponentFamilyValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_TypeValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_RendererClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Error_ComponentFamilyEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Error_RendererTypeEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_Error_RendererClassEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_SelectComponentFamilyDialog_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_ComponentFamilyCaption;
-
- /**
- * see EditorMessages.properties
- */
- public static String RendererSection_Dialog_ComponentFamilyLabel;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterMasterSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterMasterSection_Description;
-
-// public static String ConverterMasterSection_HelpContextID;
-//
-// public static String ConverterMasterSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Description;
-
-// public static String ConverterGeneralSection_HelpContextID;
-//
-// public static String ConverterGeneralSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Label_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Label_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Label_ConverterID;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Label_ConverterForClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String ConverterGeneralSection_Label_ConverterClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorMasterSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorMasterSection_Description;
-
-// public static String ValidatorMasterSection_HelpContextID;
-//
-// public static String ValidatorMasterSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Description;
-
-// public static String ValidatorGeneralSection_HelpContextID;
-//
-// public static String ValidatorGeneralSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Label_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Label_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Label_ValidatorID;
-
- /**
- * see EditorMessages.properties
- */
- public static String ValidatorGeneralSection_Label_ValidatorClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Description;
-
-// public static String AttributeSection_HelpContextID;
-//
-// public static String AttributeSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Table_NameColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Table_ClassColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Table_DefaultValueColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Table_SuggestedValueColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_Title_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_Title_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_Tab_General;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_AttributeName;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_AttributeClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_DefaultValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_SuggestedValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_Error_NameEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String AttributeSection_Dialog_Error_ClassEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Description;
-
-// public static String PropertySection_HelpContextID;
-//
-// public static String PropertySection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Table_NameColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Table_ClassColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Table_DefaultValueColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Table_SuggestedValueColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_Title_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_Title_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_Tab_General;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_PropertyName;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_PropertyClass;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_DefaultValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_SuggestedValue;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_Error_NameEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertySection_Dialog_Error_ClassEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Description;
-
-// public static String FacetSection_HelpContextID;
-//
-// public static String FacetsSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Table_DisplayNameColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Table_FacetNameColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Table_DescriptionColumn;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_Title_Add;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_Title_Edit;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_Tab_General;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_FacetName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_DisplayName;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacetSection_Dialog_Error_NameEmpty;
-
- /**
- * see EditorMessages.properties
- */
- public static String OthersPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ActionListenerSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ActionListenerSection_Description;
-
-// public static String ActionListenerSection_HelpContextID;
-//
-// public static String ActionListenerSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String MessageBundleSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String MessageBundleSection_Description;
-
-// public static String MessageBundleSection_HelpContextID;
-//
-// public static String MessageBundleSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String MessageBundleSection_Dialog_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String MessageBundleSection_Dialog_Message_SelectPropertyFile;
-
- /**
- * see EditorMessages.properties
- */
- public static String MessageBundleSection_Dialog_Message_AlreadyExists;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Description;
-
-// public static String LocaleConfigSection_HelpContextID;
-//
-// public static String LocaleConfigSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_WindowTitle;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_Page_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_Page_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_Page_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_Page_LabelText;
-
- /**
- * see EditorMessages.properties
- */
- public static String LocaleConfigSection_Wizard_Page_AlreadyExistsError;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Description;
-
-// public static String DefaultRenderKitIDSection_HelpContextID;
-//
-// public static String DefaultRenderKitIDSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_WindowTitle;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_Page_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_Page_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_Page_Description;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_Page_LabelText;
-
- /**
- * see EditorMessages.properties
- */
- public static String DefaultRenderKitIDSection_Wizard_Page_AlreadyExistsError;
-
- /**
- * see EditorMessages.properties
- */
- public static String NavigationHandlerSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String NavigationHandlerSection_Description;
-
-// public static String NavigationHandlerSection_HelpContextID;
-//
-// public static String NavigationHandlerSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ViewHandlerSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ViewHandlerSection_Description;
-
-// public static String ViewHandlerSection_HelpContextID;
-//
-// public static String ViewHandlerSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String StateManagerSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String StateManagerSection_Description;
-
-// public static String StateManagerSection_HelpContextID;
-//
-// public static String StateManagerSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertyResolverSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String PropertyResolverSection_Description;
-
-// public static String PropertyResolverSection_HelpContextID;
-//
-// public static String PropertyResolverSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String VariableResolverSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String VariableResolverSection_Description;
-
-// public static String VariableResolverSection_HelpContextID;
-//
-// public static String VariableResolverSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String ApplicationFactorySection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String ApplicationFactorySection_Description;
-
-// public static String ApplicationFactorySection_HelpContextID;
-//
-// public static String ApplicationFactorySection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesContextFactorySection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesContextFactorySection_Description;
-
-// public static String FacesContextFactorySection_HelpContextID;
-//
-// public static String FacesContextFactorySection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String LifecycleFactorySection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String LifecycleFactorySection_Description;
-
-// public static String LifecycleFactorySection_HelpContextID;
-//
-// public static String LifecycleFactorySection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitFactorySection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String RenderKitFactorySection_Description;
-
-// public static String RenderKitFactorySection_HelpContextID;
-//
-// public static String RenderKitFactorySection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String PhaseListenerSection_Name;
-
- /**
- * see EditorMessages.properties
- */
- public static String PhaseListenerSection_Description;
-
-// public static String PhaseListenerSection_HelpContextID;
-//
-// public static String PhaseListenerSection_HelpToolTip;
-
- /**
- * see EditorMessages.properties
- */
- public static String MultiPageEditorOutlinePage_noOutline;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Error_OpenModel_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_Error_OpenModel;
-
- /**
- * see EditorMessages.properties
- */
- public static String FacesConfigEditor_WaitForLoadPage_Title;
-
- /**
- * see EditorMessages.properties
- */
- public static String ModelLoader_LoadingModelJobName;
-
- /**
- * Align bottom action label.
- */
- public static String AlignmentAction_AlignBottomAction_Label;
-
- /**
- * Align bottom action tooltip.
- */
- public static String AlignmentAction_AlignBottomAction_Tooltip;
-
- /**
- * Align center action label.
- */
- public static String AlignmentAction_AlignCenterAction_Label;
-
- /**
- * Align center action tooltip.
- */
- public static String AlignmentAction_AlignCenterAction_Tooltip;
-
- /**
- * Align left action label.
- */
- public static String AlignmentAction_AlignLeftAction_Label;
-
- /**
- * Align left action tooltip.
- */
- public static String AlignmentAction_AlignLeftAction_Tooltip;
-
- /**
- * Align middle action label.
- */
- public static String AlignmentAction_AlignMiddleAction_Label;
-
- /**
- * Align middle action tooltip.
- */
- public static String AlignmentAction_AlignMiddleAction_Tooltip;
-
- /**
- * Align right action label.
- */
- public static String AlignmentAction_AlignRightAction_Label;
-
- /**
- * Align right action tooltip.
- */
- public static String AlignmentAction_AlignRightAction_Tooltip;
-
- /**
- * Align top action label.
- */
- public static String AlignmentAction_AlignTopAction_Label;
-
- /**
- * Align top action tooltip.
- */
- public static String AlignmentAction_AlignTopAction_Tooltip;
-
- /**
- * see EditorMessages.properties
- */
- public static String EditListEntriesDialog_EditingListEntries;
-
- /**
- * see EditorMessages.properties
- */
- public static String EditMapEntriesDialog_EditingMapEntries;
-
- /**
- * User can turn off intro page in faces-config editor
- */
- public static String editor_pageflow_page_intro_NoIntroPage;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.properties
deleted file mode 100644
index 889132378..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorMessages.properties
+++ /dev/null
@@ -1,453 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-####################################################
-# Common UI resources
-####################################################
-UI_Button_Add = Add
-UI_Button_Edit = Edit
-UI_Button_Remove = Remove
-UI_Button_Add_more = Add...
-UI_Button_Edit_more = Edit...
-
-##Message for remove confirm alerter.
-Remove_Title = Confirm Remove
-Remove_Msg = Are you sure you want to remove {0}?
-
-FindType = Find Type
-FindType_Filter = Choose a type (?=any character, *=any string):
-FindType_Error_CannotFindType = Can not find java class
-
-FacesConfigEditor_Error_OpenModel_Title = Error
-FacesConfigEditor_ErrorHandlingUndoConflicts_DialogTitle=File Conflict
-FacesConfigEditor_ErrorHandlingUndoConflicts_DialogMessage=There are unsaved changes that conflict with changes made outside the editor. Do you wish to discard this editor's changes?
-FacesConfigEditor_Error_OpenModel = Cannot open the faces-config file, this project is not a web project.
-####################################################
-# Tab's name for multipageeditor of faces-config
-####################################################
-FacesConfigEditor_Introduction_TabName = Introduction
-FacesConfigEditor_Overview_TabName = Overview
-FacesConfigEditor_Pageflow_TabName = Navigation Rule
-FacesConfigEditor_ManagedBeans_TabName = ManagedBean
-FacesConfigEditor_Components_TabName = Component
-FacesConfigEditor_Others_TabName = Others
-FacesConfigEditor_Source_TabName = Source
-
-
-####################################################
-#Introduction page
-####################################################
-editor_pageflow_page_intro_name = Introduction
-editor_pageflow_page_intro_title = Faces Configuration Introduction
-editor_pageflow_page_intro_help_HelpContextID = com.sybase.stf.jmt.faces_config_editor_introduction
-editor_pageflow_page_intro_help_HelpToolTip = Introduction
-editor_pageflow_page_intro_NoIntroPage=Don't show this page next time.
-
-####################################################
-#ManagedBean page
-####################################################
-ManagedBeanPage_Title = Faces Configuration Managed Bean
-
-##managed bean section
-ManagedBeanMasterSection_Name = Managed Bean Elements
-ManagedBeanMasterSection_Description = The following managed beans are defined
-
-
-##managed bean general section
-ManagedBeanGeneralSection_Name = Managed Bean
-
-ManagedBeanGeneralSection_Desc = This section describes general configuration of this managed bean
-
-ManagedBeanGeneralSection_ManagedBeanName = Managed Bean name*:
-ManagedBeanGeneralSection_ManagedBeanClass = Managed Bean class*:
-ManagedBeanGeneralSection_ManagedBeanScope = Managed Bean scope*:
-
-##managed bean initialization section
-InitializationSection_Name = Initialization
-InitializationSection_Description = You can initialize the managed bean's properties or itself if it is a subclass of java.util.Map or java.util.List
-
-ManagedBeanPropertyEditDialog_Title_NewPropertyEntry = Create New Property
-ManagedBeanPropertyEditDialog_Title_ExistingPropertyEntry = Edit Existing Property
-ManagedBeanPropertyEditDialog_PropertyName = Property name*:
-ManagedBeanPropertyEditDialog_PropertyClass = Property class*:
-ManagedBeanPropertyEditDialog_PropertyClass_Browse = Browse...
-ManagedBeanPropertyEditDialog_ValueType = Value type:
-ManagedBeanProeprtyEditPage_Description = Editing managed bean property.
-ManagedBeanPropertyEditDialog_Value = Value:
-ManagedBeanPropertyEditWizard_Title = Editing Managed Bean Property
-ManagedBeanProeprtyEditPage_Title = Edit Property
-ManagedBeanPropertyEditDialog_Value_Change = Edit...
-
-ManagedBeanPropertyEditDialog_FindType = Find Type
-ManagedBeanPropertyEditDialog_FindType_Filter = Choose a type (?=any character, *=any string):
-
-InitializationSection_ClassType = Managed Bean class type:
-
-InitializationSection_ClassType_General = General class
-InitializationSection_ClassType_Map = Map
-InitializationSection_ClassType_List = List
-
-InitializationSection_PropertyTable_Name = Name
-InitializationSection_PropertyTable_Class = Class
-InitializationSection_PropertyTable_Value = Value
-
-InitializationSection_MapType_KeyClass = Key class:
-InitializationSection_MapType_ValueClass = Value class:
-
-InitializationSection_MapTable_Title = Values:
-InitializationSection_MapTable_Key = Key
-
-InitializationSection_MapTable_Value = Value
-
-InitializationSection_ListType_ValueClass = Value class:
-InitializationSection_ListTable_Title = Values:
-InitializationSection_ListTable_Value = Value
-
-
-##ListEntriesEditGroup
-ListEntriesEditPage_Title = Editing list-entries
-ListEntriesWizard_Title = Editing list-entries
-ListEntriesEditPage_Description = Editing list-entries of managed bean property.
-
-
-
-####################################################
-#Overview Page
-####################################################
-#OverviewPage.help = Help
-OverviewPage_page_name = Overview
-OverviewPage_page_id = PageflowOverview
-OverviewPage_page_title = PageFlow Overview
-OverviewPage_PageflowOverview_summary = Faces Configuration Overview
-
-# editor section
-OverviewPage_EditorSection_name = Editors Information
-OverviewPage_EditorSection_description = This section information about editors
-OverviewPage_EditorSection_noplugin = No plugin.xml file
-OverviewPage_EditorSection_nooverview = No Overview section found in plugin.xml file
-
-# general section
-OverviewPage_GeneralSection_name = General information of faces-config.xml
-OverviewPage_GeneralSection_description = This section describes general information
-OverviewPage_GeneralSection_label_name = Faces Config Name:
-OverviewPage_GeneralSection_label_version = Version:
-
-#navigation section
-OverviewPage_NavigationSection_name = Navigation Information
-OverviewPage_NavigationSection_description = This section describes the navigation rules
-OverviewPage_NavigationSection_table_col1 = From View ID
-OverviewPage_NavigationSection_table_col2 = From Outcome
-OverviewPage_NavigationSection_table_col3 = To View ID
-OverviewPage_NavigationSection_pageflowPageID = org.eclipse.wtp.jsf.facesconfig.editor.pageflow.PageflowEditor
-
-
-# managed bean section
-OverviewPage_ManagedBeanSection_name = ManagedBean Information
-OverviewPage_ManagedBeanSection_description = This section describes the managed beans
-OverviewPage_ManagedBeanSection_table_namecol = Name
-OverviewPage_ManagedBeanSection_table_scopecol = Scope
-OverviewPage_ManagedBeanSection_table_classcol = Class
-OverviewPage_ManagedBeanSection_managedbeanPageID = com.sybase.stf.jmt.editors.pageflow.managedbean.DataBindingPage
-
-#components section
-OverviewPage_ComponentsSection_name = Component Information
-OverviewPage_ComponentsSection_description = This section describes component, render-kit, converter and validator elements
-OverviewPage_ComponentsSection_table_typecol = Element Type
-OverviewPage_ComponentsSection_table_namecol = Element Name
-OverviewPage_ComponentsSection_componentsPageID = com.sybase.stf.jmt.editors.pageflow.components.ComponentsPage
-
-#other section
-OverviewPage_OthersSection_name = Others Information
-OverviewPage_OthersSection_description = This section describes application, factory and lifecycle elements
-OverviewPage_OthersSection_table_typecol = Element Type
-OverviewPage_OthersSection_table_namecol = Element Name
-OverviewPage_OthersSection_table_valuecol = Element Value
-OverviewPage_OthersSection_othersPageID = com.sybase.stf.jmt.editors.pageflow.OthersPage
-
-ManagedBeanPropertyGroup_error_EmptyName = The property name should be selected.
-ManagedBeanPropertyGroup_error_EmptyClass = The property class should be selected or input.
-MapEntriesEditGroup_Edit = Edit...
-MapEntriesEditPage_Title = Editing map-entries
-MapEntriesWizard_Title = Editing map-entries
-MapEntryEditGroup_Key = Key*:
-MapEntryEditGroup_error_EmptyKey = The key is empty.
-MapEntryEditGroup_error_DuplicateKey = The key ''{0}'' is duplicated.
-
-
-MapEntryEditPage_Title = Edit map-entry
-MapEntryEditWizard_Title = Edit Map Entry
-MapEntriesEditPage_Description = Editing map-entries of managed bean property.
-MapEntryEditPage_Description = Editing map-entry of managed bean property.
-ValueEditDialog_Title = Edit Value
-ValueEditWizard_Title = Edit Value
-ValueEditPage_Description = Editing value of managed bean property.
-ValueEditGroup_Value = Value:
-ValueEditPage_Title = Edit Value
-
-####################################################
-#Components page
-####################################################
-ComponentsPage_Title = Faces Configuration Components
-
-##Component Master Section
-ComponentMasterSection_Name = Components
-ComponentMasterSection_Description = The following components are defined:
-
-
-##Components General Section
-ComponentGeneralSection_Name = General
-ComponentGeneralSection_Description = This section describes the general information of this component.
-ComponentGeneralSection_Label_DisplayName = Display Name:
-ComponentGeneralSection_Label_Description = Description:
-ComponentGeneralSection_Label_ComponentType = Component Type*:
-ComponentGeneralSection_Label_ComponentClass = Component Class*:
-
-##RenderKit Master Section
-RenderKitMasterSection_Name = Render Kits
-RenderKitMasterSection_Description = The following render-kits are defined:
-
-
-##RenderKits General Section
-RenderKitGeneralSection_Name = General
-RenderKitGeneralSection_Description = This section describes the general information of this render-kit.
-RenderKitGeneralSection_Label_DisplayName = Display Name:
-RenderKitGeneralSection_Label_Description = Description:
-RenderKitGeneralSection_Label_RenderKitID = Renderkit ID:
-RenderKitGeneralSection_Label_RenderKitClass = Renderkit Class:
-
-##Renderer Section
-RendererSection_Name = Renderers
-RendererSection_Description = This section lists all the renderers of this render-kit.
-RendererSection_Table_NameColumn = Name
-RendererSection_Table_ComponentFamilyColumn = Component Family
-RendererSection_Table_TypeColumn = Type
-RendererSection_Table_ClassColumn = Class
-
-##Add/Edit Renderer Dialog
-RendererSection_Dialog_Title_Add = Add Renderer
-RendererSection_Dialog_Title_Edit = Edit Renderer
-RendererSection_Dialog_Tab_General = General
-RendererSection_Dialog_DisplayName = Display Name:
-RendererSection_Dialog_ComponentFamilyValue = Component Family*:
-RendererSection_Dialog_TypeValue = Renderer Type*:
-RendererSection_Dialog_RendererClass = Renderer Class*:
-RendererSection_Dialog_Error_ComponentFamilyEmpty = The component family is empty.
-RendererSection_Dialog_Error_RendererTypeEmpty = The renderer type is empty.
-RendererSection_Dialog_Error_RendererClassEmpty = The renderer class is empty.
-
-RendererSection_Dialog_SelectComponentFamilyDialog_Title = Select Component Family
-#RendererSection.Dialog.Page.SelectComponentFamilyDialogPage.Title = Select Component Family
-#RendererSection.Dialog.Page.SelectComponentFamilyDialogPage.Description = Enter or select a component family.
-#RendererSection.Dialog.Page.SelectComponentFamilyDialogPage.LabelText = Enter or select a component family:
-RendererSection_Dialog_ComponentFamilyCaption = Select Component Family
-RendererSection_Dialog_ComponentFamilyLabel = Enter or select a component family:
-##Converter Master Section
-ConverterMasterSection_Name = Converters
-ConverterMasterSection_Description = The following Converters are defined:
-
-
-##Converter General Section
-ConverterGeneralSection_Name = General
-ConverterGeneralSection_Description = This section describes the general information of this converter.
-ConverterGeneralSection_Label_DisplayName = Display Name:
-ConverterGeneralSection_Label_Description = Description:
-ConverterGeneralSection_Label_ConverterID = Converter ID:
-ConverterGeneralSection_Label_ConverterForClass = or Converter For Class:
-ConverterGeneralSection_Label_ConverterClass = Converter Class*:
-
-##Validator Section
-ValidatorMasterSection_Name = Validators
-ValidatorMasterSection_Description = The following Validators are defined:
-
-
-##Validator General Section
-ValidatorGeneralSection_Name = General
-ValidatorGeneralSection_Description = This section describes general information of this Validator
-ValidatorGeneralSection_Label_DisplayName = Display Name:
-ValidatorGeneralSection_Label_Description = Description:
-ValidatorGeneralSection_Label_ValidatorID = Validator ID*:
-ValidatorGeneralSection_Label_ValidatorClass = Validator Class*:
-
-##Attribute Section
-AttributeSection_Name = Attributes
-AttributeSection_Description = This section lists all the attributes.
-
-AttributeSection_Table_NameColumn = Name
-AttributeSection_Table_ClassColumn = Class
-AttributeSection_Table_DefaultValueColumn = Default Value
-AttributeSection_Table_SuggestedValueColumn = Suggested Value
-
-##Add/Edit Attribute Dialog
-AttributeSection_Dialog_Title_Add = Add Attribute
-AttributeSection_Dialog_Title_Edit = Edit Attribute
-AttributeSection_Dialog_Tab_General = General
-AttributeSection_Dialog_AttributeName = Attribute Name*:
-AttributeSection_Dialog_AttributeClass = Attribute Class*:
-AttributeSection_Dialog_DefaultValue = Default value:
-AttributeSection_Dialog_SuggestedValue = Suggested value:
-AttributeSection_Dialog_Error_NameEmpty = The attribute name is empty.
-AttributeSection_Dialog_Error_ClassEmpty = The attribute class is empty.
-
-##Property Section
-PropertySection_Name = Properties
-PropertySection_Description = This section lists all the properties.
-
-PropertySection_Table_NameColumn = Name
-PropertySection_Table_ClassColumn = Class
-PropertySection_Table_DefaultValueColumn = Default Value
-PropertySection_Table_SuggestedValueColumn = Suggested Value
-
-
-##Add/Edit Property Dialog
-PropertySection_Dialog_Title_Add = Add Property
-PropertySection_Dialog_Title_Edit = Edit Property
-PropertySection_Dialog_Tab_General = General
-PropertySection_Dialog_PropertyName = Property Name*:
-PropertySection_Dialog_PropertyClass = Property Class*:
-PropertySection_Dialog_DefaultValue = Default value:
-PropertySection_Dialog_SuggestedValue = Suggested value:
-PropertySection_Dialog_Error_NameEmpty = The property name is empty.
-PropertySection_Dialog_Error_ClassEmpty = The property class is empty.
-
-##Facet Section
-FacetSection_Name = Facets
-FacetSection_Description = This section lists all the facets.
-
-FacetSection_Table_DisplayNameColumn = Display Name
-FacetSection_Table_FacetNameColumn = Facet Name
-FacetSection_Table_DescriptionColumn = Description
-
-FacetSection_Dialog_Title_Add = Add Facet
-FacetSection_Dialog_Title_Edit = Edit Facet
-FacetSection_Dialog_Tab_General = General
-FacetSection_Dialog_FacetName = Facet Name*:
-FacetSection_Dialog_DisplayName = Display Name:
-FacetSection_Dialog_Description = Description:
-FacetSection_Dialog_Error_NameEmpty = The facet name is empty.
-
-####################################################
-#Others page
-####################################################
-OthersPage_Title = Faces Configuration Others
-
-##Application ActionListener Section
-ActionListenerSection_Name = Action Listener
-ActionListenerSection_Description =
-
-
-##Application Message Bundle Section
-MessageBundleSection_Name = Message Bundle
-MessageBundleSection_Description =
-
-
-MessageBundleSection_Dialog_Title = Select Message Bundle
-MessageBundleSection_Dialog_Message_SelectPropertyFile = Please select a message bundle file.
-MessageBundleSection_Dialog_Message_AlreadyExists = This message bundle already exists.
-
-##Application Locale Config Section
-LocaleConfigSection_Name = Locale Config
-LocaleConfigSection_Description =
-
-LocaleConfigSection_Wizard_WindowTitle = Add New Locale
-LocaleConfigSection_Wizard_Page_Name = addLocalePage
-LocaleConfigSection_Wizard_Page_Title = Add Supported Locale
-LocaleConfigSection_Wizard_Page_Description =
-LocaleConfigSection_Wizard_Page_LabelText = Enter or select a locale:
-LocaleConfigSection_Wizard_Page_AlreadyExistsError = This locale already exists.
-
-##Application Default RenderKit ID Section
-DefaultRenderKitIDSection_Name = Default RenderKit ID
-DefaultRenderKitIDSection_Description =
-
-
-DefaultRenderKitIDSection_Wizard_WindowTitle = Add Default Render Kit ID
-DefaultRenderKitIDSection_Wizard_Page_Name = addDefaultRenderKitIDPage
-DefaultRenderKitIDSection_Wizard_Page_Title = Add Default Render Kit ID
-DefaultRenderKitIDSection_Wizard_Page_Description =
-DefaultRenderKitIDSection_Wizard_Page_LabelText = Enter or select a render kit id:
-DefaultRenderKitIDSection_Wizard_Page_AlreadyExistsError = This render kit ID already exists.
-
-##Application Navigation Handler Section
-NavigationHandlerSection_Name = Navigation Handler
-NavigationHandlerSection_Description =
-
-
-##Application View Handler Section
-ViewHandlerSection_Name = View Handler
-ViewHandlerSection_Description =
-
-
-##Application State Manager Section
-StateManagerSection_Name = State Manager
-StateManagerSection_Description =
-
-
-##Application Property Resolver Section
-PropertyResolverSection_Name = Property Resolver
-PropertyResolverSection_Description =
-
-##Application Variable Resolver Section
-VariableResolverSection_Name = Variable Resolver
-VariableResolverSection_Description =
-
-
-##Factory Application Factory Section
-ApplicationFactorySection_Name = Application Factory
-ApplicationFactorySection_Description =
-
-
-##Factory Faces Context Factory Section
-FacesContextFactorySection_Name = Faces Context Factory
-FacesContextFactorySection_Description =
-
-
-##Factory Lifecycle Factory Section
-LifecycleFactorySection_Name = Lifecycle Factory
-LifecycleFactorySection_Description =
-
-
-##Factory Render Kit Factory Section
-RenderKitFactorySection_Name = Render Kit Factory
-RenderKitFactorySection_Description =
-
-##LifeCycle Phase Listener Section
-PhaseListenerSection_Name = Phase Listener
-PhaseListenerSection_Description =
-
-####################################################
-#Resource for MultiPageEditorOutlinePage
-####################################################
-MultiPageEditorOutlinePage_noOutline = An outline is not available.
-
-
-FacesConfigEditor_WaitForLoadPage_Title= Please wait while the editor finishes loading...
-FacesConfigEditor_WaitForLoad_EditorTabTitle=Wait for Load
-ModelLoader_LoadingModelJobName="Loading faces-config model"
-
-###########################
-# AlignmentAction messages
-###########################
-AlignmentAction_AlignLeftAction_Tooltip=Align Left
-AlignmentAction_AlignLeftAction_Label=Align &Left
-AlignmentAction_AlignRightAction_Tooltip=Align Right
-AlignmentAction_AlignRightAction_Label=Align &Right
-AlignmentAction_AlignTopAction_Tooltip=Align Top
-AlignmentAction_AlignTopAction_Label=Align &Top
-AlignmentAction_AlignBottomAction_Tooltip=Align Bottom
-AlignmentAction_AlignBottomAction_Label=Align &Bottom
-AlignmentAction_AlignCenterAction_Tooltip=Align Center
-AlignmentAction_AlignCenterAction_Label=Align &Center
-AlignmentAction_AlignMiddleAction_Tooltip=Align Middle
-AlignmentAction_AlignMiddleAction_Label=Align &Middle
-AddEditManagedPropertyDialog_Add=Add Managed Property
-AddEditManagedPropertyDialog_Edit=Edit Managed Property
-AddEditMapEntryDialog_NullValue=Null Value
-EditListEntriesDialog_EditingListEntries=Editing list-entries
-EditMapEntriesDialog_EditingMapEntries=Editing map-entries
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPlugin.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPlugin.java
deleted file mode 100644
index 589dc01fc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPlugin.java
+++ /dev/null
@@ -1,268 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.Alerts;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class EditorPlugin extends AbstractUIPlugin {//implements IStartup {
-
- // The shared instance.
- private static EditorPlugin plugin;
-
- private Logger log;
-
- private ResourceBundle resourceBundle;
-
- private static Alerts alerts;
-
- private URL pluginBase;
-
- /**
- * The constructor.
- */
- public EditorPlugin() {
- super();
- plugin = this;
- }
-
-
- /**
- * This method is called upon plug-in activation
- */
- public void start(BundleContext context) throws Exception {
- super.start(context);
- try {
- // get resource bundle.
- resourceBundle = ResourceBundle
- .getBundle("org.eclipse.jst.jsf.facesconfig.ui.EditorPluginResources"); //$NON-NLS-1$
- alerts = new Alerts(this, resourceBundle);
- pluginBase = getBundle().getEntry("/"); //$NON-NLS-1$
-
- // set up logging for this plugin and everthing under it.
- log = new Logger(this.getBundle(), resourceBundle);
-
- // log.info("log.StartMessage", CommonPlugin.getVersion());
- } catch (Exception ee) {
- // only log if the logger was configured correctly.
- if (log != null) {
- log.error("log.msg", //$NON-NLS-1$
- "Problems starting plug-in Faces Config Editor.", ee); //$NON-NLS-1$
- }
-
- throw new CoreException(new Status(IStatus.ERROR, getBundle()
- .getSymbolicName(), IStatus.OK,
- "Problems starting plug-in Faces Config Editor", ee)); //$NON-NLS-1$
- }
-
- }
-
- /**
- * This method is called when the plug-in is stopped
- */
- public void stop(BundleContext context) throws Exception {
- super.stop(context);
- plugin = null;
- }
-
- /**
- * @return the shared instance.
- */
- public static EditorPlugin getDefault() {
- return plugin;
- }
-
- /**
- * @return the alerts objects associated with this plugin for alerting the user.
- */
- public static Alerts getAlerts() {
- return alerts;
- }
-
- /**
- * Returns a logger for the new class using this plugin for reference.
- * @param theClass
- * @return the default root logger
- */
- public static Logger getLogger(Class theClass) {
- return getDefault().getRootLogger(); // .getLogger(theClass);
- }
-
- /**
- * Returns the plugin's root logger
- * @return the root logger
- */
- public Logger getRootLogger() {
- return log;
- }
-
- /**
- * Returns the plugin's resource bundle,
- * @return the resource bundle
- */
- public ResourceBundle getResourceBundle() {
- return resourceBundle;
- }
-
- /**
- * Returns the string from the plugin's resource bundle, or 'key' if not
- * found.
- * @param key
- * @return the resource bundle string for key
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the standard display to be used. The method first checks, if the
- * thread calling this method has an associated dispaly. If so, this display
- * is returned. Otherwise the method returns the default display.
- * @return the standard display
- */
- public static Display getStandardDisplay() {
- Display display;
- display = Display.getCurrent();
- if (display == null) {
- display = Display.getDefault();
- }
- return display;
- }
-
- /**
- * Returns the active workbench window.
- *
- * @return the active workbench window. this can be null but I've never seen
- * it.
- */
- public static IWorkbenchWindow getActiveWorkbenchWindow() {
- if (getDefault().getWorkbench() == null) {
- return null;
- }
- return getDefault().getWorkbench().getActiveWorkbenchWindow();
- }
-
- /**
- * @return the active shell
- */
- public static Shell getActiveShell() {
- Shell shell = null;
- IWorkbenchWindow workbenchWindow = getActiveWorkbenchWindow();
- if (workbenchWindow.getShell() != null) {
- shell = workbenchWindow.getShell();
- } else {
- shell = new Shell();
- }
- return shell;
- }
-
- /**
- * Returns a shared image for the given name
- * <p>
- * Note: Images returned from this method will be automitically disposed of
- * when this plug-in shuts down. Callers must not dispose of these images
- * themselves.
- * </p>
- *
- * @param name
- * the image name found in /icons (with extension)
- * @return the image, null on error or not found.
- */
- public Image getImage(String name) {
- if (name == null) {
- return null;
- }
-
- ImageRegistry images = getImageRegistry();
- Image image = images.get(name);
- if (image == null) {
- try {
- ImageDescriptor id = ImageDescriptor.createFromURL(new URL(
- pluginBase, "icons/" + name)); //$NON-NLS-1$
- images.put(name, id);
-
- image = images.get(name);
- } catch (MalformedURLException ee) {
- // log.EditorPlugin.image.error=Image {0} not found.
- log.error("log.msg", "log.EditorPlugin.image.error", name, ee); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- return image;
- }
-
- /**
- * Returns an image descriptor for the image file at the given plug-in
- * relative path.
- *
- * @param path
- * the path
- * @return the image descriptor
- */
- public ImageDescriptor getImageDescriptor(String path) {
- if (path == null) {
- return null;
- }
-
- ImageRegistry images = getImageRegistry();
- ImageDescriptor id = images.getDescriptor(path);
- if (id == null) {
- try {
- id = ImageDescriptor.createFromURL(new URL(pluginBase, "icons/" //$NON-NLS-1$
- + path));
- images.put(path, id);
- } catch (MalformedURLException ee) {
- // log.EditorPlugin.image.error=Image {0} not found.
- log.error("log.msg", "log.EditorPlugin.image.error", path, ee); //$NON-NLS-1$ //$NON-NLS-2$
- }
- }
- return id;
- }
-
- /**
- * Returns this plugin's unique identifier
- *
- * @return this plugin's unique identifier
- *
- */
- public static String getPluginId() {
- return getDefault().getBundle().getSymbolicName();
- }
-
- protected void initializeDefaultPluginPreferences() {
- new GEMPreferences();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPluginResources.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPluginResources.properties
deleted file mode 100644
index a8dd34c0c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/EditorPluginResources.properties
+++ /dev/null
@@ -1,85 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-common.error=Error
-common.warning=Warning
-log.StartMessage=Faces Config Editor initialized on eclipse version {0}.
-####################################################
-# Resource message for Logging
-####################################################
-
-log.msg={0}
-
-log.EditorPlugin=Faces Config Editor Plugin initialized on eclipse version {0}.
-log.EditorPlugin.image.error=Image ''{0}'' not found.
-
-####################################################
-# Resource message for Alert
-####################################################
-
-Pageflow.PageflowEditor.Alert.errorOpenEditorTitle = Open Pageflow Error
-Pageflow.PageflowEditor.Alert.errorOpenEditorInfo = An error occured during opening the editor.
-Pageflow.PageflowEditor.Alert.errorSaveFileTitle = Save Pageflow Error
-Pageflow.PageflowEditor.Alert.errorSaveFileInfo = The current pageflow model could not be saved.
-Pageflow.PageflowEditor.Alert.nullModelManager = No model manager found for saving the file.
-Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle = Open JSF File Error
-Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFInfo = The JSF file ''{0}'' does not exist.
-Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFFolderInfo = Cannot open the page in the page editor.
-
-Pageflow.PageflowEditor.Alert.confirmCreateNewJSFFileTitle = Confirm
-Pageflow.PageflowEditor.Alert.confirmCreateNewJSFFile = No jsp file is related with this page.
-
-Pageflow.PageflowEditor.Alert.syncWithFacesConfigTitle = Confirm
-Pageflow.PageflowEditor.Alert.syncWithFacesConfigInfo = Synchronizing with faces-config will update the current pageflow model! \nThis command CAN NOT undo. Are you sure?
-Pageflow.PageflowEditor.Alert.errorSyncPageflowModel = The current pageflow model could not be synchronized with the specified faces-config file.
-
-Pageflow.PageflowEditor.Alert.updateFacesConfigTitle = Confirm
-Pageflow.PageflowEditor.Alert.updateFacesConfigInfo = Update the related faces config file. Are you sure?
-Pageflow.PageflowEditor.Alert.errorUpdateFacesConfig = The related faces-config file could not be updated.
-
-Pageflow.Transform.Alert.ResourceTitle = Resource Error
-Pageflow.Transform.Alert.LoadResourceError = Error loading resource
-Pageflow.Transform.Alert.SaveResourceError = Error saving resource
-
-Pageflow.PageflowEditor.Alert.DNDResourceTitle = Pageflow Creation Error
-Pageflow.PageflowEditor.Alert.ExistingPage = The web page ''{0}'' already exists in current PageFlow.
-Pageflow.PageflowEditor.Alert.ExistingAction = The action ''{0}'' already exists in current PageFlow.
-Pageflow.PageflowEditor.Alert.PageFromOtherProject = The web page ''{0}'' does not belong to current project.
-
-Pageflow.FacesConfig.Alert.ResourceTitle = Faces Configuration File Warning
-Pageflow.FacesConfig.Alert.LoadFileError = Invalid content in faces configuration file ''{0}''.
-Pageflow.FacesConfig.Alert.ErrorUpdateFacesConfigFromPageflow = Invalid content in faces configuration file. \nThe pageflow diagram can not be transformed.
-Pageflow.FacesConfig.Alert.SaveFileError = Failed to save faces configuration file ''{0}''.
-
-ManagedBeanInitializationSection.Remove.Title = Confirm Remove
-ManagedBeanInitializationSection.RemoveManagedProperty = Are you sure you want to remove all the managed-properties?
-ManagedBeanInitializationSection.RemoveMapEntries = Are you sure you want to remove map-entries?
-ManagedBeanInitializationSection.RemoveListEntries = Are you sure you want to remove list-entries?
-
-Alert.Error.CompletionProcessor.HTML.AttributeCompletionProp=No completions found
-Alert.Info.JSPPageEditorContributor.CreateAction.Message=Sample Action Executed
-
-Pageflow.PageflowEditor.Error.invalidPageflowFile = The specified input is not a valid pageflow.
-Pageflow.PageflowEditor.Error.invalidPageflowModel = The model in the pageflow file is not a valid pageflow model.
-Pageflow.PageflowEditor.Error.canNotOpenEditor4JSF = The jsf file can not be opened in the editor.
-Pageflow.PageflowEditor.Error.ResourceChange = Failed in the resource change.
-Pageflow.PageflowEditor.Error.canNotShowPropertyView = Failed to show property sheet view.
-Pageflow.PageflowEditor.Error.canNotShowPaletteView = Failed to show palette sheet view.
-
-Pageflow.PageflowResources.Error.invalidResourceBundle = The specified resource file is not a valid resourece bundle file.
-Pageflow.Transform.Resource.LoadError = Error loading resource ''{0}''
-
-Pageflow.PageflowEditor.Error.UnableRemoveAllMarkers = Unable to remove all markers
-Pageflow.PageflowEditor.Error.UnableAddMarker = Unable to add a marker
-Pageflow.PageflowEditor.Error.UnableRemoveMarker = Unable to remove a marker
-Pageflow.PageflowEditor.Error.invalidMarkerAttribute = Unable to get marker's attribute
-
-PageflowEditor.Encoding.Unsupported = Unsupported Encoding.
-PageflowEditor.Transform.Error.GetPageflowFromFacesConfig = Failed to get pageflow model from faces-config'a navigation rule.
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigActionBarContributor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigActionBarContributor.java
deleted file mode 100644
index 7171e35cb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigActionBarContributor.java
+++ /dev/null
@@ -1,179 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor;
-import org.eclipse.jface.action.ICoolBarManager;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IStatusLineManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowActionBarContributor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.part.EditorActionBarContributor;
-import org.eclipse.ui.part.MultiPageEditorActionBarContributor;
-import org.eclipse.wst.sse.ui.StructuredTextEditor;
-import org.eclipse.wst.xml.ui.internal.tabletree.SourcePageActionContributor;
-
-/**
- * The faces-config editor itself is composed by a set of pages. Each page has
- * its own action contributor. This FacesConfigActionBarContributor will work as
- * a proxy to delegate the action contributing to target nested action
- * contributor.
- *
- * @author hmeng
- */
-
-public class FacesConfigActionBarContributor extends
- MultiPageEditorActionBarContributor {
- private SourcePageActionContributor sourceActionContributor = null;
-
- private PageflowActionBarContributor pageflowActionContributor = null;
-
- private EditingDomainActionBarContributor formbasedPageActionContributor = null;
-
- private IEditorPart activeNestedEditor;
-
- /**
- * Default constructor
- */
- public FacesConfigActionBarContributor() {
- super();
- }
-
- public void setActivePage(IEditorPart activeEditor) {
- if (activeEditor != activeNestedEditor) {
- if (getActionContributor(activeNestedEditor) != null) {
- getActionContributor(activeNestedEditor).setActiveEditor(
- activeEditor);
- }
- activeNestedEditor = activeEditor;
- EditorActionBarContributor activeContributor = getActionContributor(activeEditor);
- if (activeContributor != null)
- activeContributor.setActiveEditor(activeEditor);
- else
- super.setActiveEditor(activeEditor);
- updateActionBars();
- }
- }
-
- public void contributeToCoolBar(ICoolBarManager coolBarManager) {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor != null)
- activeContributor.contributeToCoolBar(coolBarManager);
- }
-
- public void contributeToMenu(IMenuManager menuManager) {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor != null) {
- activeContributor.contributeToMenu(menuManager);
- }
- }
-
- public void contributeToStatusLine(IStatusLineManager statusLineManager) {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor != null) {
- activeContributor.contributeToStatusLine(statusLineManager);
- }
- }
-
- public void contributeToToolBar(IToolBarManager toolBarManager) {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor != null) {
- activeContributor.contributeToToolBar(toolBarManager);
- }
- }
-
- public void dispose() {
- getFormbasedPageActionContributor().dispose();
- getPageflowActionContributor().dispose();
- getSourceActionContributor().dispose();
- }
-
- public IActionBars getActionBars() {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor != null) {
- return activeContributor.getActionBars();
- }
- return super.getActionBars();
- }
-
- public IWorkbenchPage getPage() {
- return super.getPage();
- }
-
- public void init(IActionBars bars, IWorkbenchPage page) {
- getPageflowActionContributor().init(bars, page);
- getSourceActionContributor().init(bars, page);
- getFormbasedPageActionContributor().init(bars, page);
- super.init(bars, page);
- }
-
-// private IEditorPart getActiveNestedEditor(IEditorPart targetEditor) {
-// IEditorPart activeNestedEditor_;
-// if (targetEditor instanceof FormEditor) {
-// activeNestedEditor_ = ((FormEditor) targetEditor).getActiveEditor();
-// } else {
-// activeNestedEditor_ = targetEditor;
-// }
-// return activeNestedEditor_;
-// }
-
- private EditorActionBarContributor getActionContributor(
- IEditorPart activeNestedEditor_) {
- EditorActionBarContributor activeContributor = null;
- if (activeNestedEditor_ instanceof PageflowEditor) {
- activeContributor = getPageflowActionContributor();
- } else if (activeNestedEditor_ instanceof StructuredTextEditor) {
- activeContributor = getSourceActionContributor();
- } else if (activeNestedEditor_ != null) {
- activeContributor = getFormbasedPageActionContributor();
- }
- return activeContributor;
- }
-
- private SourcePageActionContributor getSourceActionContributor() {
- if (sourceActionContributor == null) {
- sourceActionContributor = new SourcePageActionContributor();
- }
- return sourceActionContributor;
- }
-
- private EditingDomainActionBarContributor getFormbasedPageActionContributor() {
- if (formbasedPageActionContributor == null) {
- formbasedPageActionContributor = new MyEditingDomainActionContributor();
- }
- return formbasedPageActionContributor;
- }
-
- private PageflowActionBarContributor getPageflowActionContributor() {
- if (pageflowActionContributor == null) {
- pageflowActionContributor = new PageflowActionBarContributor();
- }
- return pageflowActionContributor;
-
- }
-
- /**
- * update the action bars
- */
- public void updateActionBars() {
- EditorActionBarContributor activeContributor = getActionContributor(activeNestedEditor);
- if (activeContributor instanceof INestedActionContributor)
- ((INestedActionContributor) activeContributor).update();
- // getActionBars().getMenuManager().removeAll();
- // activeContributor.contributeToMenu(getActionBars().getMenuManager());
- getActionBars().updateActionBars();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java
deleted file mode 100644
index de8314e3d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/FacesConfigEditor.java
+++ /dev/null
@@ -1,1392 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.EventObject;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import java.util.concurrent.atomic.AtomicBoolean;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceChangeEvent;
-import org.eclipse.core.resources.IResourceChangeListener;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.emf.common.command.BasicCommandStack;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.resource.Resource;
-import org.eclipse.emf.ecore.resource.ResourceSet;
-import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.domain.IEditingDomainProvider;
-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.gef.commands.CommandStack;
-import org.eclipse.gef.commands.CommandStackListener;
-import org.eclipse.gef.editparts.ZoomManager;
-import org.eclipse.gef.ui.actions.ActionRegistry;
-import org.eclipse.gef.ui.actions.EditorPartAction;
-import org.eclipse.gef.ui.actions.SaveAction;
-import org.eclipse.gef.ui.actions.UpdateAction;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.common.ui.internal.actions.IOpenPage;
-import org.eclipse.jst.jsf.core.IJSFCoreConstants;
-import org.eclipse.jst.jsf.facesconfig.edit.provider.FacesConfigItemProviderAdapterFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.ui.page.ComponentsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IntroductionPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.ManagedBeanPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OverviewPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.WaitForLoadPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.DelegatingZoomManager;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.DelegatingCommandStack;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.EMFCommandStackGEFAdapter;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.layout.PageflowLayoutManager;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.jst.jsf.facesconfig.util.FacesConfigArtifactEdit;
-import org.eclipse.swt.custom.CTabFolder;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorActionBarContributor;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IFileEditorInput;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.actions.WorkspaceModifyOperation;
-import org.eclipse.ui.dialogs.SaveAsDialog;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.editor.IFormPage;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.ide.IGotoMarker;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-import org.eclipse.ui.views.properties.tabbed.ITabbedPropertySheetPageContributor;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-import org.eclipse.wst.common.project.facet.core.IFacetedProject;
-import org.eclipse.wst.common.project.facet.core.IProjectFacet;
-import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
-import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.sse.ui.StructuredTextEditor;
-
-/**
- * This is the main editor for the faces-config file. Note that the model
- * load can involve long-running socket operations (shouldn't but can),
- * so the editor UI is load asynchronously. This is means that any
- * operations that need to be executed on editor open should be run
- * using AddPagesTask.pageSafeExecute() to ensure that they occur
- * after all editor pages have finished loading.
- *
- * @author sfshi
- *
- */
-public class FacesConfigEditor extends FormEditor implements
- IEditingDomainProvider, ISelectionProvider {
-
- /**
- * This editor's ID. TODO: this should prob be in plugin.properties?
- */
- public static final String EDITOR_ID = "org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor"; //$NON-NLS-1$
-
-
- /**
- * Page id for Source page. Used for testing only.
- */
- public static final String SOURCE_PAGE_ID = "SourcePageId"; //$NON-NLS-1$
- /**
- * editing domain that is used to track all changes to the model
- */
- private AdapterFactoryEditingDomain editingDomain;
-
- /**
- * adapter factory used for providing views of the model
- */
- private ComposedAdapterFactory adapterFactory;
-
- /** id of the pageflowPage */
- private int pageflowPageID;
-
- private int managedBeanPageID;
-
- private int componentsPageID;
-
- private int othersPageID;
-
- private int sourcePageId;
-
- private PageflowEditor pageflowPage;
-
- /** The source text editor. */
- private StructuredTextEditor sourcePage;
-
- private Collection selectionChangedListeners = new ArrayList();
-
- private ISelection editorSelection = StructuredSelection.EMPTY;
-
- private IContentOutlinePage outlinePage;
-
- private IProject currentProject;
-
- private boolean isWebProject;
-
- private ModelLoader _modelLoader;
-
- /**
- * only true once dispose() has been called
- * used to signal that the editor was disposed.
- */
- private boolean _isDisposed; // = false;
-
- /**
- * Used to load editor pages when the model is loaded
- */
- private final AddPagesTask _addPagesTask = new AddPagesTask();
-
- /**
- * Default constructor
- */
- public FacesConfigEditor() {
- initializeEMF();
- }
-
- /**
- * This listens for workspace changes. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- protected IResourceChangeListener resourceChangeListener = new IResourceChangeListener() {
- public void resourceChanged(IResourceChangeEvent event) {
- // Only listening to these.
- // if (event.getType() == IResourceDelta.POST_CHANGE)
- {
- IResourceDelta delta = event.getDelta();
- try {
- class ResourceDeltaVisitor implements IResourceDeltaVisitor {
- protected ResourceSet resourceSet = editingDomain
- .getResourceSet();
-
- @SuppressWarnings("hiding")
- protected Collection changedResources = new ArrayList();
-
- @SuppressWarnings("hiding")
- protected Collection removedResources = new ArrayList();
-
- public boolean visit(IResourceDelta delta_) {
- if (delta_.getFlags() != IResourceDelta.MARKERS
- && delta_.getResource().getType() == IResource.FILE) {
- if ((delta_.getKind() & (IResourceDelta.CHANGED | IResourceDelta.REMOVED)) != 0) {
- Resource resource = resourceSet
- .getResource(URI.createURI(delta_
- .getFullPath().toString()),
- false);
- if (resource != null) {
- if ((delta_.getKind() & IResourceDelta.REMOVED) != 0) {
- removedResources.add(resource);
- } else {
- changedResources.add(resource);
- }
- }
- }
- }
-
- return true;
- }
-
- public Collection getChangedResources() {
- return changedResources;
- }
-
- public Collection getRemovedResources() {
- return removedResources;
- }
- }
-
- ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
- delta.accept(visitor);
-
- if (!visitor.getRemovedResources().isEmpty()) {
- removedResources.addAll(visitor.getRemovedResources());
- if (!isDirty()) {
- getSite().getShell().getDisplay().asyncExec(
- new Runnable() {
- public void run() {
- getSite().getPage().closeEditor(
- FacesConfigEditor.this,
- false);
- FacesConfigEditor.this.dispose();
- }
- });
- }
- }
-
- if (!visitor.getChangedResources().isEmpty()) {
- changedResources.addAll(visitor.getChangedResources());
- }
- } catch (CoreException exception) {
- // log it.
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin
- .getPluginId(), IStatus.OK, exception
- .getMessage() == null ? "" : exception //$NON-NLS-1$
- .getMessage(), exception));
- }
- }
- }
- };
-
- /**
- * Resources that have been removed since last activation.
- *
- * @generated
- */
- Collection removedResources = new ArrayList();
-
- /**
- * Resources that have been changed since last activation.
- *
- * @generated
- */
- Collection changedResources = new ArrayList();
-
- /**
- * Resources that have been saved.
- *
- * @generated
- */
- Collection savedResources = new ArrayList();
-
- /**
- * Initializes the EMF support.
- */
- private void initializeEMF() {
- // create an adapter factory that yields item providers
- List factories = new ArrayList();
- factories.add(new ResourceItemProviderAdapterFactory());
- factories.add(new FacesConfigItemProviderAdapterFactory());
- factories.add(new ReflectiveItemProviderAdapterFactory());
- adapterFactory = new ComposedAdapterFactory(factories);
-
- // create the command stack that will notify this editor as commands are
- // executed
- BasicCommandStack commandStack = new BasicCommandStack();
- commandStack
- .addCommandStackListener(new org.eclipse.emf.common.command.CommandStackListener() {
- public void commandStackChanged(final EventObject event) {
- getContainer().getShell().getDisplay().asyncExec(
- new Runnable() {
- public void run() {
- editorDirtyStateChanged();
- getActionBarContributor()
- .updateActionBars();
- }
- });
- }
- });
- // commandStack.addCommandStackListener(this);
- // create the editing domain with a special command stack
- editingDomain = new AdapterFactoryEditingDomain(adapterFactory,
- commandStack, new HashMap());
- }
-
- /*
- * @see org.eclipse.ui.IEditorPart#init(org.eclipse.ui.IEditorSite,
- * org.eclipse.ui.IEditorInput)
- */
- public void init(IEditorSite site, IEditorInput input)
- throws PartInitException {
- try {
- super.init(site, input);
- } catch (Exception e) {
- MessageDialog.openError(null,
- EditorMessages.FacesConfigEditor_Error_OpenModel_Title,
- EditorMessages.FacesConfigEditor_Error_OpenModel);
- throw new PartInitException(
- EditorMessages.FacesConfigEditor_Error_OpenModel);
- }
-
- setPartName(input.getName());
- if (!isValidInput(input)) {
- PlatformUI.getWorkbench().getActiveWorkbenchWindow()
- .getActivePage().openEditor(input,
- "org.eclipse.ui.DefaultTextEditor"); //$NON-NLS-1$
-
- close(false);
- return;
- }
-
- createActions();
-
- ResourcesPlugin.getWorkspace().addResourceChangeListener(
- resourceChangeListener, IResourceChangeEvent.POST_CHANGE);
- }
-
- /*
- * @see org.eclipse.ui.part.EditorPart#setInput(org.eclipse.ui.IEditorInput)
- */
- protected void setInput(IEditorInput input)
- {
- isWebProject = matches(input);
- super.setInput(input);
-
- IFile inputFile = (IFile) input.getAdapter(IFile.class);
- if (inputFile != null)
- {
- final IProject project = inputFile.getProject();
- final IPath inputPath = inputFile.getFullPath();
-
- _modelLoader = new ModelLoader();
- _modelLoader.load(project, inputPath, isWebProject, _addPagesTask);
- }
- }
-
-
- protected void addPages()
- {
- // try loading wait page
- // if we get to here before model load completes,
- // then wait page will give the user the indication
- // that something is happening in the background before
- // the editor full loads.
- // if the model is already loaded, this call should do nothing
- _addPagesTask.maybeAddWaitPage();
- }
-
- /**
- * This runnable is used to used to manage the loading of the
- * editor pages for editor in a deferred fashion. Because the model
- * loading for this editor can be noticably long and (unfortunately)
- * may involve socket calls that block, loadModel(), runs this on a
- * separate thread. This class is intended to be used in two ways:
- *
- * 1) by the model loading code to signal it is finished by executing
- * the run() via a display.asyncExec().
- *
- * 2) by the addPages() call back on the the main editor as a way to
- * load a "Please wait for loading" page if the loading is still running
- * by the time the editor is ready to visualize itself.
- *
- * Note that in both cases methods of this class *must* be running on the
- * main display thread.
- *
- * @author cbateman
- *
- */
- private class AddPagesTask extends ModelLoader.ModelLoaderComplete
- {
- private final AtomicBoolean _arePagesLoaded = new AtomicBoolean(false); // set to true when the regular editor pages are loaded
- private FormPage _waitPage;
- private List<Runnable> _deferredRunnables = new ArrayList<Runnable>();
-
- /**
- * If the editor pages are loaded, runnable.run() is invoked immediately
- * If the editor pages are not loaded yet, runnable is queued and will be
- * executed in the order they are added immediately after the pages are loaded
- *
- * @param runnable
- */
- public synchronized void pageSafeExecute(Runnable runnable)
- {
- if (!_isDisposed)
- {
- if (!_arePagesLoaded.get())
- {
- _deferredRunnables.add(runnable);
- }
- else
- {
- runnable.run();
- }
- }
- }
-
- /**
- * @return true if the pages are loaded
- */
- public synchronized boolean getArePagesLoaded()
- {
- return _arePagesLoaded.get();
- }
-
- /**
- * Remove the wait page if present.
- */
- public synchronized void removeWaitPage()
- {
- if (_waitPage != null
- && !_waitPage.getPartControl().isDisposed())
- {
- int index = _waitPage.getIndex();
-
- if (index >= 0)
- {
- removePage(index);
- }
- }
- }
-
- /**
- * Add the wait page if the main pages aren't already loaded
- */
- public synchronized void maybeAddWaitPage()
- {
- // only load the wait page if the other pages haven't been loaded
- if (!getArePagesLoaded())
- {
- _waitPage = new WaitForLoadPage(FacesConfigEditor.this, "WaitForLoad", EditorMessages.FacesConfigEditor_WaitForLoad_EditorTabTitle); //$NON-NLS-1$
-
- try
- {
- addPage(0,_waitPage);
- }
- catch(PartInitException pie)
- {
- _waitPage =null;
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin.getPluginId(),
- IStatus.OK, pie.getMessage() == null ? "" : pie //$NON-NLS-1$
- .getMessage(), pie));
- }
- }
- }
-
- /**
- * Must be run on the UI thread
- */
- public void doRun(FacesConfigArtifactEdit edit)
- {
- synchronized(this)
- {
- // ensure wait page gets removed
- removeWaitPage();
-
- if (!getArePagesLoaded()
- && !_isDisposed) // NOTE: we assume that access to variable does not need to
- // to be synchronous since this method must
- // be run on the UI thread. The only way
- // that isDisposed should be true is if model loading took a long
- // time and the user closed the editor before it completed (trigger dispose to be called)
- {
- try
- {
- if (isWebProject && edit != null && edit.getFacesConfig() != null)
- {
- // only add the intro editor if the preference
- // is set to do so.
- if (GEMPreferences.getShowIntroEditor())
- {
- IntroductionPage page1 = new IntroductionPage(FacesConfigEditor.this);
- addPage(page1, null);
- }
-
- IFormPage overviewPage = new OverviewPage(FacesConfigEditor.this);
- addPage(overviewPage, null);
-
- // Page flow
- createAndAddPageflowPage();
-
- // pages
- IFormPage managedBeanPage = new ManagedBeanPage(FacesConfigEditor.this);
- managedBeanPageID = addPage(managedBeanPage, null);
- IFormPage componentsPage = new ComponentsPage(FacesConfigEditor.this);
- componentsPageID = addPage(componentsPage, null);
- IFormPage othersPage = new OthersPage(FacesConfigEditor.this);
- othersPageID = addPage(othersPage, null);
- }
-
- sourcePage = new StructuredTextEditor();
-
- sourcePage.setEditorPart(FacesConfigEditor.this);
-
- sourcePageId = addPage(sourcePage, FacesConfigEditor.this.getEditorInput());
- setPageText(sourcePageId,
- EditorMessages.FacesConfigEditor_Source_TabName);
- sourcePage.update();
-
- // default active page to 0
- setActivePage(0);
-
- // execute deferred runnables
- for (Runnable runnable : _deferredRunnables)
- {
- runnable.run();
- }
-
- // flag the fact that the regular editor pages have been added
- _arePagesLoaded.set(true);
- } catch (PartInitException e) {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin.getPluginId(),
- IStatus.OK, e.getMessage() == null ? "" : e //$NON-NLS-1$
- .getMessage(), e));
- }
- }
- }
- }
- }
-
- /**
- * Creates the pageflow page of the multi-page editor.
- * @throws PartInitException
- */
- protected void createAndAddPageflowPage() throws PartInitException {
- pageflowPage = new PageflowEditor(this);
- pageflowPageID = addPage(pageflowPage, getEditorInput());
- setPageText(pageflowPageID,
- EditorMessages.FacesConfigEditor_Pageflow_TabName);
- addPageActionRegistry(pageflowPage);
- pageflowPage.getModelsTransform().setFacesConfig(getFacesConfig());
- pageflowPage.getModelsTransform().setPageflow(
- pageflowPage.getPageflow());
- boolean fornew = pageflowPage.getModelsTransform()
- .updatePageflowModelFromEMF();
- pageflowPage.setGraphicalViewerContents(pageflowPage.getPageflow());
- if (fornew) {
- PageflowLayoutManager.getInstance().layoutPageflow(
- pageflowPage.getPageflow());
- }
- pageflowPage.getModelsTransform().setListenToNotify(true);
- }
-
- /**
- * TODO: this is used only for testing
- * @return the page flow editor
- */
- public PageflowEditor getPageflowPage() {
- return pageflowPage;
- }
-
- /**
- * get the action's registry of sub pages.
- * @param page
- *
- */
- protected void addPageActionRegistry(IEditorPart page) {
- if (page != null) {
- ActionRegistry pageActionRegisty = (ActionRegistry) page
- .getAdapter(ActionRegistry.class);
- if (pageActionRegisty != null) {
- for (Iterator iter = pageActionRegisty.getActions(); iter
- .hasNext();) {
- getActionRegistry().registerAction((IAction) iter.next());
- }
- }
- }
- }
-
- /** the editor's action registry */
- private ActionRegistry actionRegistry = null;
-
- /**
- * Returns the action registry of this editor.
- *
- * @return - the action registry
- */
- protected ActionRegistry getActionRegistry() {
- if (null == actionRegistry)
- actionRegistry = new ActionRegistry();
-
- return actionRegistry;
- }
-
- /**
- * Returns the root object of the configuration model.
- *
- * @return the root object. Should not, but may return null.
- */
- public FacesConfigType getFacesConfig()
- {
- FacesConfigArtifactEdit edit = _modelLoader.getEdit();
- if (edit != null)
- {
- return edit.getFacesConfig();
- }
- return null;
- }
-
- /*
- * @see org.eclipse.ui.ISaveablePart#isDirty()
- */
- public boolean isDirty() {
- return ((BasicCommandStack) editingDomain.getCommandStack())
- .isSaveNeeded()
- || super.isDirty();
- }
-
- /**
- * This class listens for command stack changes of the pages contained in
- * this editor and decides if the editor is dirty or not.
- */
- private class MultiPageCommandStackListener implements CommandStackListener {
-
- /** the observed command stacks */
- private List commandStacks = new ArrayList(2);
-
- /** to get the editorpart from command stack */
- private HashMap mapEditorCommandStack = new HashMap();
-
- private boolean saveLocation = false;
-
- /**
- * Adds a <code>CommandStack</code> to observe.
- *
- * @param commandStack
- * @param editor
- */
- public void addCommandStack(CommandStack commandStack,
- IEditorPart editor) {
- if (commandStack == null)
- return;
-
- if (mapEditorCommandStack.get(commandStack) == editor)
- return;
-
- commandStacks.add(commandStack);
- commandStack.addCommandStackListener(this);
- mapEditorCommandStack.put(commandStack, editor);
- }
-
- /**
- * set the dirty status for the models of different editor
- *
- * @param editor -
- * editor, e.g., pageflow or databinding page.
- * @param dirty -
- * true or false
- */
- private void setEditorDirty(IEditorPart editor, boolean dirty) {
- // do nothing
- }
-
- /** the list of action ids that are to CommandStack actions */
- private List stackActionIDs = new ArrayList();
-
- /**
- * Updates the specified actions.
- *
- * @param actionIds -
- * the list of ids of actions to update
- */
- private void updateActions(List actionIds) {
- for (Iterator ids = actionIds.iterator(); ids.hasNext();) {
- IAction action = getActionRegistry().getAction(ids.next());
- if (null != action && action instanceof UpdateAction) {
- ((UpdateAction) action).update();
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStackListener#commandStackChanged(java.util.EventObject)
- */
- public void commandStackChanged(EventObject event) {
- // enable or disable the actions
- updateActions(stackActionIDs);
- if (((CommandStack) event.getSource()).isDirty()) {
- // set the editor's model dirty status
- setEditorDirty((IEditorPart) mapEditorCommandStack
- .get(event.getSource()), true);
- // at least one command stack is dirty,
- // so the multi page editor is dirty too
- setDirty(true);
- } else {
- // set the editor's model dirty status, if it is from not save
- // location.
- if (!saveLocation) {
- setEditorDirty((IEditorPart) mapEditorCommandStack
- .get(event.getSource()), true);
- setDirty(true);
- } else {
- setDirty(false);
- }
- }
- }
-
- /** the pageflow page editor's dirty state */
- private boolean isDirty = false;
-
- /**
- * Changes the dirty state.
- *
- * @param dirty -
- * dirty state
- */
- public void setDirty(boolean dirty) {
- if (isDirty != dirty) {
- isDirty = dirty;
- firePropertyChange(IEditorPart.PROP_DIRTY);
- }
- }
-
- /**
- * Disposed the listener
- */
- public void dispose() {
- for (Iterator stacks = commandStacks.iterator(); stacks.hasNext();) {
- ((CommandStack) stacks.next()).removeCommandStackListener(this);
- }
- commandStacks.clear();
- }
-
- /**
- * Marks every observed command stack beeing saved. This method should
- * be called whenever the editor/model was saved.
- */
- public void markSaveLocations() {
- saveLocation = true;
- for (Iterator stacks = commandStacks.iterator(); stacks.hasNext();) {
- CommandStack stack = (CommandStack) stacks.next();
- stack.markSaveLocation();
- }
- saveLocation = false;
- }
-
- /**
- * Flushes every observed command stack and resets the save location to
- * zero.
- */
- public void flush() {
- for (Iterator stacks = commandStacks.iterator(); stacks.hasNext();) {
- CommandStack stack = (CommandStack) stacks.next();
- stack.flush();
- }
- }
- }
-
- /** the <code>CommandStackListener</code> */
- private MultiPageCommandStackListener multiPageCommandStackListener = null;
-
- /**
- * Returns the global command stack listener.
- *
- * @return the <code>CommandStackListener</code>
- */
- protected MultiPageCommandStackListener getMultiPageCommandStackListener() {
- if (null == multiPageCommandStackListener)
- multiPageCommandStackListener = new MultiPageCommandStackListener();
-
- return multiPageCommandStackListener;
- }
-
- /*
- * @see org.eclipse.ui.ISaveablePart#doSave(org.eclipse.core.runtime.IProgressMonitor)
- */
- public void doSave(IProgressMonitor monitor) {
- // do the work within an operation because this is a long running
- // activity that modifies the workbench
- WorkspaceModifyOperation operation = new WorkspaceModifyOperation() {
- public void execute(IProgressMonitor monitor_) {
- try {
- if (isWebProject &&
- _modelLoader.getEdit() != null) {
- // modelResource.save(Collections.EMPTY_MAP);
- _modelLoader.getEdit()
- .getDeploymentDescriptorResource().save(
- Collections.EMPTY_MAP);
- IFile file = ((IFileEditorInput) getEditorInput())
- .getFile();
- pageflowPage.doSave(file, monitor_);
- }
- sourcePage.doSave(monitor_);
- getMultiPageCommandStackListener().markSaveLocations();
- } catch (Exception e) {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin
- .getPluginId(), IStatus.OK,
- e.getMessage() == null ? "" : e //$NON-NLS-1$
- .getMessage(), e));
- }
- }
- };
- try {
- // commit all pending changes in form pages
- for (Iterator iter = pages.iterator(); iter.hasNext();) {
- Object obj = iter.next();
- if (obj instanceof FormPage) {
- ((FormPage) obj).doSave(monitor);
- }
- // else if (obj instanceof PageflowEditor) {
- // ((PageflowEditor) obj).doSave(monitor);
- // }
-
- }
- operation.run(null);// .run(true, false,
- // operation;
- // runs the operation, and shows progress
- // new ProgressMonitorDialog();
-
- // refresh the necessary state
- ((BasicCommandStack) editingDomain.getCommandStack()).saveIsDone();
-
- editorDirtyStateChanged();
- } catch (Exception e) {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin.getPluginId(),
- IStatus.OK, e.getMessage(), e));
- }
- }
-
- public void doSaveAs() {
- SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell());
- saveAsDialog.open();
- IPath path = saveAsDialog.getResult();
- if (path != null) {
- IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path);
- if (file != null) {
- doSaveAs(URI.createPlatformResourceURI(file.getFullPath()
- .toString(), false), new FileEditorInput(file));
- }
- }
- }
-
- /**
- * @param uri
- * @param editorInput
- */
- protected void doSaveAs(URI uri, IEditorInput editorInput) {
- editingDomain.getResourceSet().getResources().get(0)
- .setURI(uri);
- setInputWithNotify(editorInput);
- setPartName(editorInput.getName());
- IProgressMonitor progressMonitor = getActionBars()
- .getStatusLineManager() != null ? getActionBars()
- .getStatusLineManager().getProgressMonitor()
- : new NullProgressMonitor();
- doSave(progressMonitor);
- }
-
- public boolean isSaveAsAllowed() {
- return true;
- }
-
- /**
- * Returns the <code>TabbedPropertySheetPage</code> for this editor.
- *
- * @return - the <code>TabbedPropertySheetPage</code>
- */
- protected IPropertySheetPage getPropertySheetPage() {
- return new TabbedPropertySheetPage(
- new ITabbedPropertySheetPageContributor() {
-
- public String getContributorId() {
- return EDITOR_ID;
- }
- });
- }
-
- /** the delegating ZoomManager */
- private DelegatingZoomManager delegatingZoomManager = null;
-
- /**
- * check whether the input is related with IFile.
- *
- * @param input
- * @return
- */
- private boolean isValidInput(IEditorInput input) {
- if (input != null) {
- IFile file = (IFile) input.getAdapter(IResource.class);
- if (file != null) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Returns the <code>DelegatingZoomManager</code> for this editor.
- *
- * @return - the <code>DelegatingZoomManager</code>
- */
- protected DelegatingZoomManager getDelegatingZoomManager() {
- if (!isValidInput(getEditorInput()) || !isWebProject || !_addPagesTask.getArePagesLoaded()) {
- return null;
- }
- if (null == delegatingZoomManager) {
- delegatingZoomManager = new DelegatingZoomManager();
- delegatingZoomManager
- .setCurrentZoomManager((ZoomManager) pageflowPage
- .getAdapter(ZoomManager.class));
- }
- return delegatingZoomManager;
- }
-
- /** the delegating CommandStack */
- private DelegatingCommandStack delegatingCommandStack = null;
-
- /**
- * Returns the <code>CommandStack</code> for this editor.
- *
- * @return - the <code>CommandStack</code>
- */
- public DelegatingCommandStack getDelegatingCommandStack() {
- if (null == delegatingCommandStack) {
- delegatingCommandStack = new DelegatingCommandStack();
- }
- return delegatingCommandStack;
- }
-
- /*
- * @see org.eclipse.core.runtime.IAdaptable#getAdapter(java.lang.Class)
- */
- public Object getAdapter(Class adapter) {
- if (adapter == IEditingDomainProvider.class) {
- return new IEditingDomainProvider() {
- public EditingDomain getEditingDomain() {
- return editingDomain;
- }
- };
- }
- if (adapter == EditingDomain.class) {
- return editingDomain;
- }
- if (adapter == AdapterFactory.class) {
- return adapterFactory;
- }
- if (adapter == IEditorPart.class) {
- return getActiveEditor();
- }
-
- if (adapter == CommandStack.class) {
- return getDelegatingCommandStack();
- }
- if (adapter == ZoomManager.class) {
- return getDelegatingZoomManager();
- }
-
- if (adapter == ActionRegistry.class) {
- return getActionRegistry();
- }
- if (adapter == IGotoMarker.class) {
- return new IGotoMarker() {
- public void gotoMarker(final IMarker marker) {
- // this may be called on an editor open (i.e. double-click the Problems view)
- // so ensure it runs safely with respect to the page load
- _addPagesTask.pageSafeExecute(new Runnable()
- {
- public void run()
- {
- FacesConfigEditor.this.gotoMarker(marker);
- }
- });
- }
- };
- }
- if (adapter == StructuredTextEditor.class) {
- return sourcePage;
- }
-
- if (adapter == IContentOutlinePage.class) {
- return getOutlinePage();
- }
-
- if (adapter == IPropertySheetPage.class) {
- return getPropertySheetPage();
- }
-
- if (adapter == IProject.class) {
- return getProject();
- }
-
- if (adapter == CTabFolder.class) {
- return getContainer();
- }
-
- if (adapter == IOpenPage.class) {
- return new IOpenPage() {
-
- public void setActiveEditorPage(String pageID) {
- FacesConfigEditor.this.setActiveEditorPage(pageID);
-
- }
- };
- }
-
- return super.getAdapter(adapter);
- }
-
- private EMFCommandStackGEFAdapter sourceCommandStack;
-
- /**
- * get or create the source page's GEF command stack based on its EMF
- * command stack.
- *
- * @return
- */
- private CommandStack getSourcePageCommandStack() {
- if (sourceCommandStack == null) {
- IDocument doc = sourcePage.getDocumentProvider().getDocument(getEditorInput());
- if (doc instanceof IStructuredDocument) {
- sourceCommandStack = new EMFCommandStackGEFAdapter(doc);
- }
- else
- {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin.getPluginId(), 0,
- "Error getting undo stack for Faces Config editor. Undo may be disabled", //$NON-NLS-1$
- new Throwable()));
- }
- }
- return sourceCommandStack;
- }
-
- /** the list of action ids that are to CommandStack actions */
- // private List stackActionIDs = new ArrayList();
- /** the list of action ids that are editor actions */
- private List editorActionIDs = new ArrayList();
-
- /**
- * Adds an editor action to this editor.
- * <p>
- * Editor actions are actions that depend and work on the editor.
- *
- * @param action -
- * the editor action
- */
- protected void addEditorAction(EditorPartAction action) {
- getActionRegistry().registerAction(action);
- editorActionIDs.add(action.getId());
- }
-
- /**
- * Creates different kinds of actions and registers them to the
- * ActionRegistry.
- */
- protected void createActions() {
- // register save action
- addEditorAction(new SaveAction(this));
- }
-
- /**
- * Indicates that the current page has changed.
- * <p>
- * We update the DelegatingCommandStack, OutlineViewer and other things
- * here. //
- */
- protected void currentPageChanged() {
- IEditorPart activeEditor = getActiveEditor();
- if (activeEditor == null) {
- return;
- }
-
- // update command stack
- CommandStack cmdStack = null;
-
- if (activeEditor == pageflowPage) {
- cmdStack = (CommandStack) activeEditor
- .getAdapter(CommandStack.class);
- } else if (activeEditor == sourcePage)// other page will delegate the
- // GEF command stack to source
- // page's.
- {
- cmdStack = this.getSourcePageCommandStack();
- }
-
- // Add command stacks
- getMultiPageCommandStackListener().addCommandStack(cmdStack,
- activeEditor);
- getDelegatingCommandStack().setCurrentCommandStack(cmdStack);
-
- // enable or disable the actions
- // updateActions(stackActionIDs);
-
- // update zoom actions
- ZoomManager zoomManager = null;
- zoomManager = (ZoomManager) activeEditor.getAdapter(ZoomManager.class);
-
- if (zoomManager != null) {
- getDelegatingZoomManager().setCurrentZoomManager(zoomManager);
- }
-
- IEditorActionBarContributor contributor = getEditorSite()
- .getActionBarContributor();
- if (contributor != null
- && contributor instanceof FacesConfigActionBarContributor) {
- ((FacesConfigActionBarContributor) contributor)
- .setActivePage(activeEditor);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see MultiPageEditorPart#pageChange(int)
- */
- protected void pageChange(int newPageIndex) {
- super.pageChange(newPageIndex);
- // getActionBarContributor().setActivePage(getActiveEditor());
- // refresh content depending on current page
- currentPageChanged();
- }
-
- public void dispose()
- {
- // signal that we have been disposed
- // do this before anything else
- _isDisposed = true;
- _modelLoader.dispose();
-
- ResourcesPlugin.getWorkspace().removeResourceChangeListener(
- resourceChangeListener);
-
- adapterFactory.dispose();
-
- if (this.outlinePage != null)
- outlinePage.dispose();
-
- if (sourcePage != null)
- sourcePage.dispose();
-
- if (sourceCommandStack != null)
- sourceCommandStack.dispose();
-
- if (pageflowPage != null)
- pageflowPage.dispose();
-
- if (multiPageCommandStackListener != null)
- multiPageCommandStackListener.dispose();
-
- //do not call dispose on delegatingCommandStack. source and multiPage are already disposed
-
- super.dispose();
- }
-
- /**
- * get the project of the faces config file that the editor is working on.
- *
- * @return IProject
- */
- public IProject getProject() {
- if (currentProject == null) {
- if (_modelLoader.getEdit() != null) {
- IFile file = _modelLoader.getEdit().getFile();
- if (file != null)
- currentProject = file.getProject();
- }
- }
- return currentProject;
- }
-
- public EditingDomain getEditingDomain() {
- return editingDomain;
- }
-
- /**
- * Returns the <code>IContentOutlinePage</code> for this editor.
- *
- * @return - the <code>IContentOutlinePage</code>
- */
- protected IContentOutlinePage getOutlinePage() {
- if (null == outlinePage) {
- outlinePage = new MultiPageEditorOutlinePage();
- }
- return outlinePage;
- }
-
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- public ISelection getSelection() {
- return editorSelection;
- }
-
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- public void setSelection(ISelection selection) {
- editorSelection = selection;
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener
- .selectionChanged(new SelectionChangedEvent(this, selection));
- }
- }
-
- private void gotoMarker(IMarker marker) {
- setActivePage(sourcePageId);
- IDE.gotoMarker(this.sourcePage, marker);
- }
-
- /**
- * FIXME: this is used only for testing. Should isolate better
- * @return the action bar
- */
- public FacesConfigActionBarContributor getActionBarContributor() {
- return (FacesConfigActionBarContributor) getEditorSite()
- .getActionBarContributor();
- }
-
- private IActionBars getActionBars() {
- return getActionBarContributor().getActionBars();
- }
-
- public Object getSelectedPage() {
- IFormPage page = getActivePageInstance();
- if (page != null)
- return page;
-
- if (getActiveEditor() instanceof PageflowEditor)
- return getActiveEditor();
-
- return null;
- }
-
- /**
- * Shows a dialog that asks if conflicting changes should be discarded.
- * @return the user's response.
- */
- protected boolean handleDirtyConflict() {
- return MessageDialog
- .openQuestion(
- getSite().getShell(),
- EditorMessages.FacesConfigEditor_ErrorHandlingUndoConflicts_DialogTitle,
- EditorMessages.FacesConfigEditor_ErrorHandlingUndoConflicts_DialogMessage);
- }
-
- /**
- * Handles what to do with changed resources on activation.
- *
- * @generated
- */
- protected void handleChangedResources() {
- if (!changedResources.isEmpty()
- && (!isDirty() || handleDirtyConflict())) {
- editingDomain.getCommandStack().flush();
-
- for (Iterator i = changedResources.iterator(); i.hasNext();) {
- Resource resource = (Resource) i.next();
- if (resource.isLoaded()) {
- resource.unload();
- try {
- resource.load(Collections.EMPTY_MAP);
- } catch (IOException exception) {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin
- .getPluginId(), IStatus.OK, exception
- .getMessage() == null ? "" : exception //$NON-NLS-1$
- .getMessage(), exception));
- }
- }
- }
- }
- }
-
- /**
- * TODO this is used only for testing. Should be able to remove if we
- * go to true automated UI testing
- * @param pageID
- */
- public void setActiveEditorPage(String pageID) {
- if (pageID.equals(PageflowEditor.PAGE_ID)) {
- setActivePage(pageflowPageID);
- } else if (pageID.equals(ManagedBeanPage.PAGE_ID)) {
- setActivePage(managedBeanPageID);
- } else if (pageID.equals(ComponentsPage.PAGE_ID)) {
- setActivePage(componentsPageID);
- } else if (pageID.equals(OthersPage.PAGE_ID)) {
- setActivePage(othersPageID);
- } else if (pageID.equals(SOURCE_PAGE_ID)) {
- setActivePage(sourcePageId);
- }
- }
-
- private boolean matches(IEditorInput input) {
- final IResource file = (IResource) input.getAdapter(IResource.class);
- boolean hasWebFacet = false;
- boolean hasJSFFacet = false;
-
- if (file != null) {
- final IProject project = file.getProject();
-
- if (project != null) {
- try {
- final IFacetedProject facetedProject = ProjectFacetsManager
- .create(project);
-
- if (facetedProject != null) {
- final Set facets = facetedProject.getProjectFacets();
-
- for (final Iterator it = facets.iterator(); it
- .hasNext();) {
- final IProjectFacetVersion version = (IProjectFacetVersion) it
- .next();
-
- IProjectFacet facet = version.getProjectFacet();
- if (IJSFCoreConstants.JSF_CORE_FACET_ID.equals(facet.getId())) {
- hasJSFFacet = true;
- } else if ("jst.web".equals(facet.getId())) { //$NON-NLS-1$
- hasWebFacet = true;
- }
- }
- }
- } catch (CoreException ex) {
- EditorPlugin.getDefault().getLog().log(
- new Status(IStatus.ERROR, EditorPlugin
- .getPluginId(), IStatus.OK,
- ex.getMessage() == null ? "" : ex //$NON-NLS-1$
- .getMessage(), ex));
- }
- }
- }
-
- return hasWebFacet && hasJSFFacet;
- }
-
- /**
- * DANGER! This call is for testing only! Should not be used,
- * even internally, by production code.
- * @param timeoutMs the time to wait in milliseconds
- * @throws InterruptedException
- */
- public void doPageLoad(long timeoutMs) throws InterruptedException
- {
- _modelLoader.waitForLoad(timeoutMs);
- _addPagesTask.doRun(_modelLoader.getEdit());
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/IFacesConfigConstants.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/IFacesConfigConstants.java
deleted file mode 100644
index c13cff1c3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/IFacesConfigConstants.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-/**
- * @author jchoi
- * @version
- */
-public interface IFacesConfigConstants {
-
- /**
- *
- */
- public static final String FACES_CONFIG = "faces-config"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MANAGED_PROPERTY = "managed-property"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String VALUE = "value"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String NULL_VALUE = "null-value"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MAP_ENTRIES = "map-entries"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MAP_ENTRY = "map-entry"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String LIST_ENTRIES = "list-entries"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String NAVIGATION_RULE = "navigation-rule"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String COMPONENT_SUPER_CLASS = "javax.faces.component.UIComponent"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String RENDER_KIT_SUPER_CLASS = "javax.faces.render.RenderKit"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String CONVERTER_INTERFACE = "javax.faces.convert.Converter"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String VALIDATOR_INTERFACE = "javax.faces.validator.Validator"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String RENDERER_SUPER_CLASS = "javax.faces.render.Renderer"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String ACTION_LISTENER_INTERFACE = "javax.faces.event.ActionListener"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String NAVIGATION_HANDLE_SUPER_CLASS = "javax.faces.application.NavigationHandler"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String PROPERTY_RESOLVER_SUPER_CLASS = "javax.faces.el.PropertyResolver"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String STATE_MANAGER_SUPER_CLASS = "javax.faces.application.StateManager"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String VARIABLE_RESOLVER_SUPER_CLASS = "javax.faces.el.VariableResolver"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String VIEW_HANDLER_SUPER_CLASS = "javax.faces.application.ViewHandler"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String APPLICATION_FACTORY_SUPER_CLASS = "javax.faces.application.ApplicationFactory"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String FACES_CONTEXT_FACTORY_SUPER_CLASS = "javax.faces.context.FacesContextFactory"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String LIFECYCLE_FACTORY_SUPER_CLASS = "javax.faces.lifecycle.LifecycleFactory"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String RENDER_KIT_FACTORY_SUPER_CLASS = "javax.faces.render.RenderKitFactory"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String PHASE_LISTENER_INTERFACE = "javax.faces.event.PhaseListener"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MANAGED_BEAN_SCOPE_APPLICATION = "application"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MANAGED_BEAN_SCOPE_SESSION = "session"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MANAGED_BEAN_SCOPE_REQUEST = "request"; //$NON-NLS-1$
-
- /**
- *
- */
- public static final String MANAGED_BEAN_SCOPE_NONE = "none"; //$NON-NLS-1$
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/INestedActionContributor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/INestedActionContributor.java
deleted file mode 100644
index a36a2f4c2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/INestedActionContributor.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-/**
- * The nested action contributor should be able to update its actions as
- * required.
- */
-public interface INestedActionContributor {
- /**
- * Updated nested actions
- */
- void update();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/ModelLoader.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/ModelLoader.java
deleted file mode 100644
index 417b949b3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/ModelLoader.java
+++ /dev/null
@@ -1,215 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.TimeUnit;
-
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.jst.jsf.facesconfig.util.FacesConfigArtifactEdit;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Centralizes logic to load the faces config model off of the UI thread for
- * the FacesConfig Editor.
- *
- * Also encapsulates the lifecycle for the instance of the faces artifact
- * created for its editor. All creation, access and destruction of the artifact
- * should be centralized through this class
- *
- * @author cbateman
- *
- */
-class ModelLoader
-{
- private FacesConfigArtifactEdit _edit;
- private Job _loadModelJob;
- private CountDownLatch _modelLoaded = new CountDownLatch(1);
-
- /**
- * @return the artifact edit or null if not loaded. Should only be called
- * after load() is called and has executed its callback
- */
- public synchronized FacesConfigArtifactEdit getEdit() {
- return _edit;
- }
-
- private synchronized void setEdit(FacesConfigArtifactEdit edit)
- {
- _edit = edit;
- }
-
- void waitForLoad(long timeoutMs) throws InterruptedException
- {
- _modelLoaded.await(timeoutMs, TimeUnit.MILLISECONDS);
- }
-
- /**
- * Dispose of the model and any unfinished loading operations
- *
- * Must be run on the UI thread.
- */
- public synchronized void dispose()
- {
- assertOnDisplayThread();
-
- // if the load model job has not completed, cancel it
- if (_loadModelJob != null
- && _loadModelJob.getResult() == null)
- {
- _loadModelJob.cancel();
- }
-
- if (_edit != null)
- {
- _edit.dispose();
- //System.out.println("FacesConfigEditor.dispose(): isDisposed == "+_edit.isDisposed());
- }
- }
-
- /**
- * Load the model file located by path in project. Must be called from the UI thread.
- *
- * Method does not block.
- *
- * @param project
- * @param path
- * @param isWebProject
- * @param signalComplete to be asyncExec'd on the UI thread when the model is loaded
- */
- public void load(final IProject project, final IPath path, final boolean isWebProject, final ModelLoaderComplete signalComplete)
- {
- assertOnDisplayThread();
- _loadModelJob = new ModelLoaderJob(project, path, isWebProject, signalComplete);
- _loadModelJob.schedule();
- }
-
- private class ModelLoaderJob extends Job
- {
- private final IProject _project;
- private final IPath _path;
- private final ModelLoaderComplete _runnable;
- private final boolean _isWebProject;
-
- ModelLoaderJob(final IProject project, final IPath path, final boolean isWebProject, final ModelLoaderComplete signalComplete)
- {
- super(EditorMessages.ModelLoader_LoadingModelJobName);
- _project = project;
- _path = path;
- _runnable = signalComplete;
- _isWebProject = isWebProject;
- }
-
- @Override
- protected IStatus run(IProgressMonitor monitor)
- {
- FacesConfigArtifactEdit artifactEdit = loadModel(_project, _path);
-
- // synchrnoize on the ModelLoader. Ensure that any call to dispose()
- // that occurs before we set the edit is done atomically.
- synchronized(ModelLoader.this)
- {
- // only bother with this if the task hasn't been signalled for cancel
- if (!monitor.isCanceled())
- {
- setEdit(artifactEdit);
-
- _runnable.setFacesConfigArtifactEdit(artifactEdit);
-
- // finish as quickly possible; we are holding the ModelLoader
- // lock so we must ensure that we don't block.
- // NEVER USE syncExec here.
- PlatformUI.getWorkbench().getDisplay().asyncExec(_runnable);
- }
- // if we were cancelled, then dispose of the artifact edit
- else
- {
- if (artifactEdit != null)
- {
- artifactEdit.dispose();
- }
- }
- }
-
- // signal that we are done loading
- _modelLoaded.countDown();
- return Status.OK_STATUS;
- }
-
- /**
- * Loads the configuration model from the given path.
- *
- */
- private FacesConfigArtifactEdit loadModel(IProject project, IPath modelPath)
- {
- if (_isWebProject)
- {
- IFolder webContentFolder = WebrootUtil.getWebContentFolder(project);
- Assert
- .isTrue(webContentFolder != null
- && webContentFolder.exists());
-
- IPath relativePath = modelPath;
- if (webContentFolder.getFullPath().isPrefixOf(modelPath)) {
- relativePath = modelPath.removeFirstSegments(webContentFolder
- .getFullPath().segmentCount());
- }
-
-
- return FacesConfigArtifactEdit
- .getFacesConfigArtifactEditForWrite(project, relativePath
- .toString());
- }
-
- return null;
- }
- }
-
- abstract static class ModelLoaderComplete implements Runnable
- {
- private FacesConfigArtifactEdit _edit;
-
- private void setFacesConfigArtifactEdit(FacesConfigArtifactEdit edit)
- {
- _edit = edit;
- }
-
- public final void run()
- {
- assertOnDisplayThread();
- doRun(_edit);
- }
-
- /**
- * Called by the runnable. Implementer should _not_ cache the edit variable
- * edit may be null
- *
- * @param edit
- */
- protected abstract void doRun(FacesConfigArtifactEdit edit);
- }
-
- private static void assertOnDisplayThread()
- {
- if (Thread.currentThread() != PlatformUI.getWorkbench().getDisplay().getThread())
- {
- throw new IllegalStateException("ModelLoaderComplete must be called on the UI thread"); //$NON-NLS-1$
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MultiPageEditorOutlinePage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MultiPageEditorOutlinePage.java
deleted file mode 100644
index d9110dd3e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MultiPageEditorOutlinePage.java
+++ /dev/null
@@ -1,706 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.core.runtime.ListenerList;
-import org.eclipse.core.runtime.SafeRunner;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.util.SafeRunnable;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CTabFolder;
-import org.eclipse.swt.custom.CTabItem;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.SubActionBars;
-import org.eclipse.ui.part.EditorPart;
-import org.eclipse.ui.part.IPage;
-import org.eclipse.ui.part.IPageBookViewPage;
-import org.eclipse.ui.part.IPageSite;
-import org.eclipse.ui.part.MessagePage;
-import org.eclipse.ui.part.MultiPageEditorPart;
-import org.eclipse.ui.part.Page;
-import org.eclipse.ui.part.PageBook;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * @author Xiao-guang Zhang
- *
- * The outline page class for mulitPage Editorpart.
- */
-public class MultiPageEditorOutlinePage extends Page implements
- IContentOutlinePage, SelectionListener {
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(MultiPageEditorOutlinePage.class);
-
- /**
- * Selection change listeners.
- */
- private ListenerList selectionChangedListeners = new ListenerList(ListenerList.IDENTITY);
-
- /** the pagebook */
- private PageBook pageBook = null;
-
- /**
- * Selection change listener to listen for page selection changes
- */
- private ISelectionChangedListener selectionChangedListener = new ISelectionChangedListener() {
- public void selectionChanged(SelectionChangedEvent event) {
- pageSelectionChanged(event);
- }
- };
-
- /**
- * A data structure used to store the information about a single page within
- * a MultiPageEditorOutlinePage
- */
- protected static class PageRec {
-
- /**
- * The part including editorpart, or Control
- */
- public IWorkbenchPart part;
-
- /**
- * The page.
- */
- public IPage page;
-
- /**
- * The page's action bars
- */
- public SubActionBars subActionBars;
-
- /**
- * Creates a new page record initialized to the given part and page.
- *
- * @param part
- * @param page
- */
- public PageRec(IWorkbenchPart part, IPage page) {
- this.part = part;
- this.page = page;
- }
-
- /**
- * Disposes of this page record by <code>null</code>ing its fields.
- */
- public void dispose() {
- part = null;
- page = null;
- }
- }
-
- /**
- * The page record for the default page.
- */
- private PageRec defaultPageRec;
-
- /**
- * Map from parts to part records (key type: <code>IWorkbenchPart</code>;
- * value type: <code>PartRec</code>).
- */
- private Map mapPartToRec = new HashMap();
-
- /**
- * Map from pages to view sites Note that view sites were not added to page
- * recs to avoid breaking binary compatibility with previous builds
- */
- private Map mapPageToSite = new HashMap();
-
- /**
- * The page rec which provided the current page or <code>null</code>
- */
- private PageRec activeRec;
-
- /**
- * the container composite control of MutliPageEditorPart
- */
- private CTabFolder tabFolder;
-
- /**
- * Creates a new MultiPageEditorOutlinePage instance.
- *
- *
- */
- public MultiPageEditorOutlinePage() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.part.Page#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- // pagebook
- pageBook = new PageBook(parent, SWT.NONE);
-
- // Create the default page rec.
- IPage defaultPage = createDefaultPage(pageBook);
- defaultPageRec = new PageRec(null, defaultPage);
- preparePage(defaultPageRec);
-
- // Show the default page
- showPageRec(defaultPageRec);
-
- // get the tab control and add the page selection listener.
- if (getContainerForMultiPageEditorPart() != null) {
- getContainerForMultiPageEditorPart().addSelectionListener(this);
- }
-
- // show the activate part page.
- showBootstrapPart();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Page#dispose()
- */
- public void dispose() {
- // Deref all of the pages.
- activeRec = null;
- if (defaultPageRec != null) {
- // check for null since the default page may not have
- // been created (ex. perspective never visible)
- defaultPageRec.page.dispose();
- defaultPageRec = null;
- }
- Map clone = (Map) ((HashMap) mapPartToRec).clone();
- Iterator iterator = clone.values().iterator();
- while (iterator.hasNext()) {
- PageRec rec = (PageRec) iterator.next();
- removePage(rec);
- }
-
- // important: always call super implementation of dispose
- super.dispose();
- }
-
- /**
- * Creates and returns the default page for this view.
- *
- * @param book -
- * the pagebook control
- * @return - the default page
- */
- protected IPage createDefaultPage(PageBook book) {
- // Message to show on the default page
- String defaultText = EditorMessages.MultiPageEditorOutlinePage_noOutline;
-
- MessagePage page = new MessagePage();
- initPage(page);
- page.createControl(book);
- page.setMessage(defaultText);
- return page;
- }
-
- /**
- * Prepares the page in the given page rec for use in this view.
- *
- * @param rec -
- * the page rec
- */
- private void preparePage(PageRec rec) {
- IPageSite site = null;
-
- if (!doesPageExist(rec.page)) {
- if (rec.page instanceof IPageBookViewPage) {
- site = ((IPageBookViewPage) rec.page).getSite();
- }
- if (site == null) {
- // We will create a site for our use
- site = new SubPageSite(getSite());
- }
- mapPageToSite.put(rec.page, site);
-
- rec.subActionBars = (SubActionBars) site.getActionBars();
- // rec.subActionBars.addPropertyChangeListener(actionBarPropListener);
- // for backward compability with IPage
- rec.page.setActionBars(rec.subActionBars);
-
- } else {
- site = (IPageSite) mapPageToSite.get(rec.page);
- rec.subActionBars = (SubActionBars) site.getActionBars();
- }
- }
-
- /**
- * Returns the currently visible page for this view or <code>null</code>
- * if no page is currently visible.
- *
- * @return the currently visible page
- */
- public IPage getCurrentPage() {
- if (activeRec == null)
- return null;
- return activeRec.page;
- }
-
- /**
- * Returns the view site for the given page of this view.
- *
- * @param page
- * the page
- * @return the corresponding site, or <code>null</code> if not found
- */
- protected SubPageSite getPageSite(IPage page) {
- return (SubPageSite) mapPageToSite.get(page);
- }
-
- /**
- * Shows page contained in the given page record in this view. The page
- * record must be one from this pagebook view.
- * <p>
- * The <code>PageBookView</code> implementation of this method asks the
- * pagebook control to show the given page's control, and records that the
- * given page is now current. Subclasses may extend.
- * </p>
- *
- * @param pageRec
- * the page record containing the page to show
- */
- protected void showPageRec(PageRec pageRec) {
- IPageSite pageSite = getPageSite(pageRec.page);
- ISelectionProvider provider = pageSite.getSelectionProvider();
- if (provider == null && (pageRec.page instanceof IContentOutlinePage)) {
- // This means that the page did not set a provider during its
- // initialization
- // so for backward compatibility we will set the page itself as the
- // provider.
- pageSite.setSelectionProvider((IContentOutlinePage) pageRec.page);
- }
-
- // If already showing do nothing
- if (activeRec == pageRec) {
- return;
- }
- // If the page is the same, just set activeRec to pageRec
- if (activeRec != null && pageRec != null
- && activeRec.page == pageRec.page) {
- activeRec = pageRec;
- return;
- }
-
- // Hide old page.
- if (activeRec != null) {
- activeRec.subActionBars.deactivate();
- // remove our selection listener
- provider = ((SubPageSite) mapPageToSite.get(activeRec.page))
- .getSelectionProvider();
- if (provider != null) {
- provider
- .removeSelectionChangedListener(selectionChangedListener);
- }
- }
- // Show new page.
- activeRec = pageRec;
- Control pageControl = activeRec.page.getControl();
- if (pageControl != null && !pageControl.isDisposed()) {
- // Verify that the page control is not disposed
- // If we are closing, it may have already been disposed
- pageBook.showPage(pageControl);
- activeRec.subActionBars.activate();
- refreshGlobalActionHandlers();
- // add our selection listener
- provider = ((SubPageSite) mapPageToSite.get(activeRec.page))
- .getSelectionProvider();
- if (provider != null) {
- provider.addSelectionChangedListener(selectionChangedListener);
- }
- // Update action bars.
- getSite().getActionBars().updateActionBars();
- }
- }
-
- /**
- * Refreshes the global actions for the active page.
- */
- private void refreshGlobalActionHandlers() {
- // Clear old actions.
- IActionBars bars = getSite().getActionBars();
- bars.clearGlobalActionHandlers();
-
- // Set new actions.
- Map newActionHandlers = activeRec.subActionBars
- .getGlobalActionHandlers();
- if (newActionHandlers != null) {
- Set keys = newActionHandlers.entrySet();
- Iterator iter = keys.iterator();
- while (iter.hasNext()) {
- Map.Entry entry = (Map.Entry) iter.next();
- bars.setGlobalActionHandler((String) entry.getKey(),
- (IAction) entry.getValue());
- }
- }
- }
-
- /**
- * Creates a page for a given part. Adds it to the pagebook but does not
- * show it.
- *
- * @param part
- * The part we are making a page for.
- * @return IWorkbenchPart
- */
- private PageRec createPage(IWorkbenchPart part) {
- PageRec rec = doCreatePage(part);
- if (rec != null) {
- mapPartToRec.put(part, rec);
- preparePage(rec);
- }
- return rec;
- }
-
- /*
- * (non-Javadoc) Method declared on PageBookView.
- */
- private PageRec doCreatePage(IWorkbenchPart part) {
- // Try to get an outline page.
- Object obj = part.getAdapter(IContentOutlinePage.class);
- if (obj instanceof IContentOutlinePage) {
- IContentOutlinePage page = (IContentOutlinePage) obj;
- if (page instanceof IPageBookViewPage) {
- initPage((IPageBookViewPage) page);
- }
- page.createControl(getPageBook());
- return new PageRec(part, page);
- }
- // There is no content outline
- return null;
- }
-
- /**
- * Returns the pagebook control for this view.
- *
- * @return the pagebook control, or <code>null</code> if not initialized
- */
- protected PageBook getPageBook() {
- return pageBook;
- }
-
- /**
- * Returns the page record for the given part.
- *
- * @param part
- * the part
- * @return the corresponding page record, or <code>null</code> if not
- * found
- */
- protected PageRec getPageRec(Object part) {
- return (PageRec) mapPartToRec.get(part);
- }
-
- /**
- * Initializes the given page with a page site.
- * <p>
- * Subclasses should call this method after the page is created but before
- * creating its controls.
- * </p>
- * <p>
- * Subclasses may override
- * </p>
- *
- * @param page
- * The page to initialize
- */
- protected void initPage(IPageBookViewPage page) {
- try {
- page.init(new SubPageSite(getSite()));
- } catch (PartInitException e) {
- log.error(e.getMessage());
- }
- }
-
- /**
- * Shows a page for the active workbench part.
- */
- private void showBootstrapPart() {
- IWorkbenchPart part = getBootstrapPart();
- if (part != null) {
- partActivated(part);
- }
- }
-
- /**
- * Returns the active, important workbench part for this view.
- *
- * @return the active important part, or <code>null</code> if none
- */
- private IWorkbenchPart getBootstrapPart() {
- IWorkbenchPage page = getSite().getPage();
- if (page != null
- && page.getActiveEditor() instanceof MultiPageEditorPart) {
- // get active editor of mutli-page editor.
- return (IWorkbenchPart) page.getActiveEditor().getAdapter(
- IEditorPart.class);
- }
- return null;
- }
-
- /**
- * This method shows the page when the given part is activated. Subclasses
- * may extend.
- */
- private void partActivated(IWorkbenchPart part) {
- // Is this an important part? If not just return.
- if (!isImportant(part)) {
- return;
- }
-
- // Create a page for the part.
- PageRec rec = getPageRec(part);
- if (rec == null) {
- rec = createPage(part);
- }
-
- // Show the page.
- if (rec != null) {
- showPageRec(rec);
- } else {
- showPageRec(defaultPageRec);
- }
- }
-
- /**
- * Returns true if the page has already been created.
- *
- * @param page
- * the page to test
- * @return true if this page has already been created.
- */
- private boolean doesPageExist(IPage page) {
- return mapPageToSite.containsKey(page);
- }
-
- /**
- * Returns whether the given part should be added to this view.
- *
- * @param part
- * the input part
- * @return <code>true</code> if the part is relevant, and
- * <code>false</code> otherwise
- */
- protected boolean isImportant(IWorkbenchPart part) {
- // We only care about editors
- return (part instanceof IEditorPart);
- }
-
- /**
- * get the composite control (Container) of source MultiPageEditorPart
- *
- * @return - the composite control (Container)
- */
- private CTabFolder getContainerForMultiPageEditorPart() {
- if (null == tabFolder) {
- tabFolder = ((CTabFolder) (getSite().getPage().getActiveEditor()
- .getAdapter(CTabFolder.class)));
- }
- return tabFolder;
- }
-
- /**
- * Removes a page record. If it is the last reference to the page dispose of
- * it - otherwise just decrement the reference count.
- *
- * @param rec
- */
- private void removePage(PageRec rec) {
- mapPartToRec.remove(rec.part);
- IPageSite site = (IPageSite) mapPageToSite.remove(rec.page);
-
- if (rec.subActionBars != null) {
- rec.subActionBars.dispose();
- }
-
- Control control = rec.page.getControl();
- if (control != null && !control.isDisposed()) {
- // Dispose the page's control so pages don't have to do this in
- // their
- // dispose method.
- // The page's control is a child of this view's control so if this
- // view
- // is closed, the page's control will already be disposed.
- control.dispose();
- }
-
- if (site instanceof SubPageSite) {
- ((SubPageSite) site).dispose();
- }
-
- // free the page
- doDestroyPage(rec.part, rec);
- }
-
- /**
- * Destroys a page in the pagebook for a particular part.
- *
- * @param part
- * the input part
- * @param rec
- * a page record for the part
- */
- protected void doDestroyPage(IWorkbenchPart part, PageRec rec) {
- IContentOutlinePage page = (IContentOutlinePage) rec.page;
- page.dispose();
- rec.dispose();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.part.Page#getControl()
- */
- public Control getControl() {
- return pageBook;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.part.Page#setFocus()
- */
- public void setFocus() {
- if (getControl() != null) {
- getControl().setFocus();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- // get the selection provider from the current page
- IPage currentPage = getCurrentPage();
- // during workbench startup we may be in a state when
- // there is no current page
- if (currentPage == null) {
- return StructuredSelection.EMPTY;
- }
- IPageSite site = getPageSite(currentPage);
- if (site == null) {
- return StructuredSelection.EMPTY;
- }
- ISelectionProvider selProvider = site.getSelectionProvider();
- if (selProvider != null) {
- return selProvider.getSelection();
- }
- return StructuredSelection.EMPTY;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // get the selection provider from the current page
- IPage currentPage = getCurrentPage();
- // during workbench startup we may be in a state when
- // there is no current page
- if (currentPage == null) {
- return;
- }
- IPageSite site = getPageSite(currentPage);
- if (site == null) {
- return;
- }
- ISelectionProvider selProvider = site.getSelectionProvider();
- // and set its selection
- if (selProvider != null) {
- selProvider.setSelection(selection);
- }
- }
-
- /**
- * The selection has changed. Process the event.
- *
- * @param event
- */
- public void pageSelectionChanged(final SelectionChangedEvent event) {
- // pass on the notification to listeners
- Object[] listeners = selectionChangedListeners.getListeners();
- for (int i = 0; i < listeners.length; ++i) {
- final ISelectionChangedListener l = (ISelectionChangedListener) listeners[i];
- SafeRunner.run(new SafeRunnable() {
- public void run() {
- l.selectionChanged(event);
- }
- });
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see SelectionListener#widgetSelected(SelectionEvent)
- */
- public void widgetSelected(SelectionEvent e) {
- EditorPart part = (EditorPart) ((CTabItem) e.item).getData();
-
- if (part != null) {
- partActivated(part);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see SelectionListener#widgetDefaultSelected(SelectionEvent)
- */
- public void widgetDefaultSelected(SelectionEvent e) {
- // do nothing: no handling of default selected event
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MyEditingDomainActionContributor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MyEditingDomainActionContributor.java
deleted file mode 100644
index 6c2559afa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/MyEditingDomainActionContributor.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import org.eclipse.emf.edit.domain.IEditingDomainProvider;
-import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.actions.ActionFactory;
-
-/**
- * The action contributor for form based page.
- *
- * @author hmeng
- *
- */
-public class MyEditingDomainActionContributor extends
- EditingDomainActionBarContributor implements INestedActionContributor {
- /**
- * Default constructor
- */
- public MyEditingDomainActionContributor() {
- super();
- }
-
- public void setActiveEditor(IEditorPart part) {
- if (getActiveEditor() != null) {
- deactivate();
- }
- super.setActiveEditor(part);
- IActionBars actionBars = getActionBars();
- actionBars.clearGlobalActionHandlers();
- if (part instanceof IEditingDomainProvider) {
- actionBars.setGlobalActionHandler(ActionFactory.DELETE.getId(),
- deleteAction);
- actionBars.setGlobalActionHandler(ActionFactory.UNDO.getId(),
- undoAction);
- actionBars.setGlobalActionHandler(ActionFactory.REDO.getId(),
- redoAction);
- // actionBars.setGlobalActionHandler(ActionFactory.CUT.getId(),
- // cutAction);
- // actionBars.setGlobalActionHandler(ActionFactory.COPY.getId(),
- // copyAction);
- // actionBars.setGlobalActionHandler(ActionFactory.PASTE.getId(),
- // pasteAction);
- activate();
- }
- }
-
- public void update() {
- if (getActiveEditor() instanceof IEditingDomainProvider) {
- super.update();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/SubPageSite.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/SubPageSite.java
deleted file mode 100644
index 9b459e85e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/SubPageSite.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.SubActionBars;
-import org.eclipse.ui.part.IPageSite;
-
-/**
- *
- * This implementation of <code>IPageSite</code> provides a site for a sub
- * page within a <code>Page</code>. Most methods are forwarded to the parent
- * page's site.
- *
- * @author Xiao-guang Zhang
- */
-public class SubPageSite implements IPageSite {
-
- /**
- * The "parent" Page site
- */
- private IPageSite parentSite;
-
- /**
- * A selection provider set by the page. Value is <code>null</code> until
- * set.
- */
- private ISelectionProvider selectionProvider;
-
- /**
- * The action bars for this site
- */
- private SubActionBars subActionBars;
-
- /**
- * The list of menu extender for each registered menu.
- */
-// private ArrayList menuExtenders;
-
- /**
- * Creates a new sub page site of the given parent page site.
- *
- * @param parentSite
- * the parent view site
- */
- public SubPageSite(IPageSite parentSite) {
- Assert.isNotNull(parentSite);
- this.parentSite = parentSite;
- subActionBars = new SubActionBars(this.parentSite.getActionBars());
- }
-
- /**
- * Disposes of the menu extender contributions.
- */
- protected void dispose() {
- // if (menuExtenders != null) {
- // for (int i = 0; i < menuExtenders.size(); i++) {
- // ((PopupMenuExtender) menuExtenders.get(i)).dispose();
- // }
- // menuExtenders = null;
- // }
- subActionBars.dispose();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.part.IPageSite#registerContextMenu(java.lang.String,
- * org.eclipse.jface.action.MenuManager,
- * org.eclipse.jface.viewers.ISelectionProvider)
- */
- public void registerContextMenu(String menuId, MenuManager menuManager,
- ISelectionProvider selectionProvider1) {
-
- parentSite.registerContextMenu(menuId, menuManager, selectionProvider1);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.part.IPageSite#getActionBars()
- */
- public IActionBars getActionBars() {
- return subActionBars;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchSite#getPage()
- */
- public IWorkbenchPage getPage() {
- return parentSite.getPage();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchSite#getSelectionProvider()
- */
- public ISelectionProvider getSelectionProvider() {
- return selectionProvider;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchSite#getShell()
- */
- public Shell getShell() {
- return parentSite.getShell();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchSite#getWorkbenchWindow()
- */
- public IWorkbenchWindow getWorkbenchWindow() {
- return parentSite.getWorkbenchWindow();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchSite#setSelectionProvider(org.eclipse.jface.viewers.ISelectionProvider)
- */
- public void setSelectionProvider(ISelectionProvider provider) {
- selectionProvider = provider;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.runtime.IAdaptable#getAdapter(java.lang.Class)
- */
- public Object getAdapter(Class adapter) {
- return parentSite.getAdapter(adapter);
- }
-
- public Object getService(Class api) {
- // TODO Auto-generated method stub
- return null;
- }
-
- public boolean hasService(Class api) {
- // TODO Auto-generated method stub
- return false;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditAttributeDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditAttributeDialog.java
deleted file mode 100644
index 5017085c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditAttributeDialog.java
+++ /dev/null
@@ -1,269 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-
-/**
- * The dialog is for adding and editing attribute.
- *
- * @author sfshi
- *
- */
-public class AddEditAttributeDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private StringDialogField attributeNameField;
-
- private ClassButtonDialogField attributeClassField;
-
- private StringDialogField defaultValueField;
-
- private StringDialogField suggestedValueField;
-
- private IProject project;
-
- private String attributeName;
-
- private String attributeClass;
-
- private String defaultValue;
-
- private String suggestedValue;
-
- private boolean isNew;
-
- /**
- * @param parentShell
- * @param isNew
- */
- public AddEditAttributeDialog(Shell parentShell, boolean isNew) {
- super(parentShell);
- this.isNew = isNew;
- }
-
- /**
- *
- * @param parentShell
- * @param attributeName
- * @param attributeClass
- * @param defaultValue
- * @param suggestedValue
- */
- public AddEditAttributeDialog(Shell parentShell, String attributeName,
- String attributeClass, String defaultValue, String suggestedValue) {
- super(parentShell);
- this.attributeName = attributeName;
- this.attributeClass = attributeClass;
- this.defaultValue = defaultValue;
- this.suggestedValue = suggestedValue;
- this.isNew = false;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- newShell.setText(EditorMessages.AttributeSection_Dialog_Title_Add);
- else
- newShell
- .setText(EditorMessages.AttributeSection_Dialog_Title_Edit);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- TabFolder tabFolder = new TabFolder(container, SWT.FILL);
- tabFolder.setLayoutData(gd);
- TabItem generalTabItem = new TabItem(tabFolder, SWT.NONE);
- generalTabItem
- .setText(EditorMessages.AttributeSection_Dialog_Tab_General);
- Control control = createGeneralTabControl(generalTabItem.getParent());
- generalTabItem.setControl(control);
- return container;
- }
-
- /**
- * @param parent
- * @return
- */
- private Control createGeneralTabControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.numColumns = 5;
- composite.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(gd);
- composite.setFont(parent.getFont());
-
- attributeNameField = new StringDialogField();
-// attributeNameField.setRequired(true);
- attributeNameField
- .setLabelText(EditorMessages.AttributeSection_Dialog_AttributeName);
-
- attributeClassField = new ClassButtonDialogField(getProject());
-// attributeClassField.setRequired(true);
- attributeClassField
- .setLabelText(EditorMessages.AttributeSection_Dialog_AttributeClass);
-
- attributeClassField.setAutoOpenResource(false);
-
- defaultValueField = new StringDialogField();
- defaultValueField
- .setLabelText(EditorMessages.AttributeSection_Dialog_DefaultValue);
-
- suggestedValueField = new StringDialogField();
- suggestedValueField
- .setLabelText(EditorMessages.AttributeSection_Dialog_SuggestedValue);
-
- GridData data = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(data);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- composite.setLayout(gl);
-
- attributeNameField.doFillIntoGrid(null, composite, numberOfColumns);
-
- attributeClassField.doFillIntoGrid(null, composite, numberOfColumns);
-
- defaultValueField.doFillIntoGrid(null, composite, numberOfColumns);
-
- suggestedValueField.doFillIntoGrid(null, composite, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(attributeClassField.getTextControl(
- null, composite));
-
- // set the initial value for these fields.
- attributeNameField.setText(attributeName);
- attributeClassField.setText(attributeClass);
- defaultValueField.setText(defaultValue);
- suggestedValueField.setText(suggestedValue);
-
- return composite;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- private IProject getProject() {
- return project;
- }
-
- /**
- *
- */
- protected void okPressed() {
- attributeName = attributeNameField.getText();
- attributeClass = attributeClassField.getText();
- defaultValue = defaultValueField.getText();
- suggestedValue = suggestedValueField.getText();
-
- super.okPressed();
- }
-
- /**
- * @return the attribute class
- */
- public String getAttributeClass() {
- return attributeClass;
- }
-
- /**
- * @param attributeClass
- */
- public void setAttributeClass(String attributeClass) {
- this.attributeClass = attributeClass;
- }
-
- /**
- * @return the attribute name
- */
- public String getAttributeName() {
- return attributeName;
- }
-
- /**
- * @param attributeName
- */
- public void setAttributeName(String attributeName) {
- this.attributeName = attributeName;
- }
-
- /**
- * @return the default value
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the suggested value
- */
- public String getSuggestedValue() {
- return suggestedValue;
- }
-
- /**
- * @param suggestedValue
- */
- public void setSuggestedValue(String suggestedValue) {
- this.suggestedValue = suggestedValue;
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditFacetDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditFacetDialog.java
deleted file mode 100644
index d0df52de2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditFacetDialog.java
+++ /dev/null
@@ -1,226 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-
-/**
- * The dialog is for adding and editing a facet.
- *
- * @author sfshi
- *
- */
-public class AddEditFacetDialog extends Dialog {
-
- private StringDialogField facetNameField;
-
- private StringDialogField displayNameField;
-
- private StringDialogField descriptionField;
-
- private boolean isNew;
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private String facetName;
-
- private String displayName;
-
- private String description;
-
- /**
- * Constructor of this dialog, could be used for adding and editing, usually
- * it is used for adding;
- *
- * @param parentShell
- * @param isNew
- * whether this dialog is used for create a new facet or not;
- */
- public AddEditFacetDialog(Shell parentShell, boolean isNew) {
- super(parentShell);
- this.isNew = isNew;
- }
-
- /**
- * Usually this contructor is used for editing a facet, passing the original
- * values of facet here.
- *
- * @param parentShell
- * @param facetName
- * the original text value of facet-name element;
- * @param displayName
- * the original text value of display-name element;
- * @param description
- * the original text value of description element;
- */
- public AddEditFacetDialog(Shell parentShell, String facetName,
- String displayName, String description) {
- super(parentShell);
- this.facetName = facetName;
- this.displayName = displayName;
- this.description = description;
- this.isNew = false;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- newShell.setText(EditorMessages.FacetSection_Dialog_Title_Add);
- else
- newShell.setText(EditorMessages.FacetSection_Dialog_Title_Edit);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- TabFolder tabFolder = new TabFolder(container, SWT.FILL);
- tabFolder.setLayoutData(gd);
- TabItem generalTabItem = new TabItem(tabFolder, SWT.NONE);
- generalTabItem.setText(EditorMessages.FacetSection_Dialog_Tab_General);
- Control control = createGeneralTabControl(generalTabItem.getParent());
- generalTabItem.setControl(control);
- return container;
- }
-
- /**
- * @param parent
- * @return
- */
- private Control createGeneralTabControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.numColumns = 5;
- composite.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(gd);
- composite.setFont(parent.getFont());
-
- facetNameField = new StringDialogField();
-// facetNameField.setRequired(true);
- facetNameField
- .setLabelText(EditorMessages.FacetSection_Dialog_FacetName);
-
- displayNameField = new StringDialogField();
- displayNameField
- .setLabelText(EditorMessages.FacetSection_Dialog_DisplayName);
-
- descriptionField = new StringDialogField();
- descriptionField
- .setLabelText(EditorMessages.FacetSection_Dialog_Description);
-
- GridData data = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(data);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- composite.setLayout(gl);
-
- facetNameField.doFillIntoGrid(null, composite, numberOfColumns);
- displayNameField.doFillIntoGrid(null, composite, numberOfColumns);
-
- descriptionField.doFillIntoGrid(null, composite, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(facetNameField.getTextControl(null,
- composite));
-
- // set the initial value for these fields.
- facetNameField.setText(facetName);
- displayNameField.setText(displayName);
- descriptionField.setText(description);
-
- return composite;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- protected void okPressed() {
- facetName = facetNameField.getText();
- displayName = displayNameField.getText();
- description = descriptionField.getText();
- super.okPressed();
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @return the display name
- */
- public String getDisplayName() {
- return displayName;
- }
-
- /**
- * @return the facet name
- */
- public String getFacetName() {
- return facetName;
- }
-
- /**
- * @param description
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- * @param displayName
- */
- public void setDisplayName(String displayName) {
- this.displayName = displayName;
- }
-
- /**
- * @param facetName
- */
- public void setFacetName(String facetName) {
- this.facetName = facetName;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditManagedPropertyDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditManagedPropertyDialog.java
deleted file mode 100644
index 60550172e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditManagedPropertyDialog.java
+++ /dev/null
@@ -1,529 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ComboDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IStringButtonAdapter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringButtonDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.ListEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedPropertyType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntriesType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.util.JavaBeanProperty;
-import org.eclipse.jst.jsf.facesconfig.ui.util.JavaBeanUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.util.JavaClassUtils;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * The dialog is for adding and editing managed property.
- *
- * @author sfshi
- *
- */
-public class AddEditManagedPropertyDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private static final int DEFAULT_CONTROL_WIDTH = 200;
-
- private ComboDialogField nameField;
-
- private ClassButtonDialogField classField;
-
- private ComboDialogField valueTypeField;
-
- private StringButtonDialogField valueField;
-
- private IProject project;
-
- private String propertyName;
-
- private String propertyClass;
-
- private String valueType;
-
- /**
- * the value could be a string, or instance of <code>NullValueType</code>,
- * <code>MapEntriesType</code> and <code>ListEntriesType</code>.
- */
- private Object valueObject;
-
- private ManagedBeanType managedBean;
-
- /**
- * the list of this bean properties.
- */
- private List beanPropertyList;
-
- /**
- * the managed-property object that is editing, but it will be read-only.
- */
- private ManagedPropertyType managedProperty;
-
- // private FormToolkit toolkit;
-
- private Composite parent;
-
- private static final String[] valueTypes = { IFacesConfigConstants.VALUE,
- IFacesConfigConstants.NULL_VALUE,
- IFacesConfigConstants.MAP_ENTRIES,
- IFacesConfigConstants.LIST_ENTRIES };
-
- private boolean isNew;
-
- private AbstractFacesConfigSection section;
-
- /**
- * constructor for adding a managed property.
- *
- * @param parentShell
- * @param managedBean
- * @param section
- */
- public AddEditManagedPropertyDialog(Shell parentShell,
- ManagedBeanType managedBean, AbstractFacesConfigSection section) {
- super(parentShell);
- this.isNew = true;
- this.managedBean = managedBean;
- this.section = section;
- }
-
- /**
- *
- * @param parentShell
- * @param managedProperty
- * @param section
- */
- public AddEditManagedPropertyDialog(Shell parentShell,
- ManagedPropertyType managedProperty, AbstractFacesConfigSection section) {
- super(parentShell);
- this.isNew = false;
- this.managedProperty = managedProperty;
- this.managedBean = (ManagedBeanType) managedProperty.eContainer();
- this.section = section;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- newShell.setText(EditorMessages.AddEditManagedPropertyDialog_Add);
- else
- newShell.setText(EditorMessages.AddEditManagedPropertyDialog_Edit);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent_) {
- Composite container = new Composite(parent_, SWT.FILL);
- this.parent = container;
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- nameField = new ComboDialogField(SWT.DROP_DOWN | SWT.READ_ONLY
- | SWT.BORDER);
- nameField.setLabelText(EditorMessages.ManagedBeanPropertyEditDialog_PropertyName);
-
- int propertyCount = 0;
- beanPropertyList = getBeanPropertyList(managedBean);
- if (beanPropertyList != null)
- propertyCount = beanPropertyList.size();
-
- if (propertyCount > 0) {
- String[] propertyNames = new String[propertyCount];
-
- for (int i = 0; i < propertyCount; i++) {
- JavaBeanProperty property = (JavaBeanProperty) beanPropertyList
- .get(i);
- propertyNames[i] = property.getName();
- }
- nameField.setItems(propertyNames);
- }
-
- nameField.setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- handleNameSelection(((ComboDialogField) field).getText());
- }
- });
-
- classField = new ClassButtonDialogField(null);
- classField.setProject(getProject());
- classField.setLabelText(EditorMessages.ManagedBeanPropertyEditDialog_PropertyClass);
-
- valueTypeField = new ComboDialogField(SWT.DROP_DOWN | SWT.READ_ONLY
- | SWT.BORDER);
- valueTypeField.setLabelText(EditorMessages.ManagedBeanPropertyEditDialog_ValueType);
-
- valueTypeField.setItems(valueTypes);
- valueTypeField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- updateValueStatus();
- }
- });
-
- valueField = new StringButtonDialogField(new IStringButtonAdapter() {
- public void changeControlPressed(DialogField field) {
- handleChangeValue(valueTypeField.getText(),
- ((StringButtonDialogField) field).getText());
- }
-
- });
-
- valueField.setLabelText(EditorMessages.ManagedBeanPropertyEditDialog_Value);
- valueField.setButtonLabel(EditorMessages.UI_Button_Edit_more);
-
- valueField.setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- valueObject = ((StringButtonDialogField) field).getText();
-
- }
- });
-
- GridData data = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(data);
-
- int numberOfColumns = 5;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- container.setLayout(gl);
-
- nameField.doFillIntoGrid(null, container, numberOfColumns);
- LayoutUtil.setWidthHint(nameField.getComboControl(null, container),
- DEFAULT_CONTROL_WIDTH);
-
- classField.doFillIntoGrid(null, container, numberOfColumns - 1);
- data = new GridData(SWT.FILL, SWT.CENTER, false, false);
- data.horizontalSpan = 2;
- classField.getChangeControl(null, container).setLayoutData(data);
- LayoutUtil.setWidthHint(classField.getTextControl(null, container),
- DEFAULT_CONTROL_WIDTH);
-
- valueTypeField.doFillIntoGrid(null, container, numberOfColumns);
-
- valueField.doFillIntoGrid(null, container, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(classField.getTextControl(null,
- container));
-
- valueTypeField.selectItem(0);
-
- if (!isNew && managedProperty != null) {
- initFields();
- }
-
- return container;
- }
-
- private void initFields() {
-
- if (managedProperty.getPropertyName() != null)
- nameField.setText(managedProperty.getPropertyName()
- .getTextContent());
-
- if (managedProperty.getPropertyClass() != null)
- classField.setText(managedProperty.getPropertyClass()
- .getTextContent());
-
- if (managedProperty.getValue() != null) {
- valueTypeField.setText(valueTypes[0]);
- valueField.setText(managedProperty.getValue().getTextContent());
- } else if (managedProperty.getNullValue() != null)
- valueTypeField.setText(valueTypes[1]);
- else if (managedProperty.getMapEntries() != null)
- valueTypeField.setText(valueTypes[2]);
- else if (managedProperty.getListEntries() != null)
- valueTypeField.setText(valueTypes[3]);
- else
- valueTypeField.setText(valueTypes[0]);
- updateValueStatus();
- }
-
- /**
- * @param text
- */
- protected void handleNameSelection(String text) {
- int propertyCount = 0;
- if (beanPropertyList != null)
- propertyCount = beanPropertyList.size();
-
- if (propertyCount > 0) {
- for (int i = 0; i < propertyCount; i++) {
- JavaBeanProperty property = (JavaBeanProperty) beanPropertyList
- .get(i);
-
- if (property.getName().equals(text.trim())) {
- classField.setText(property.getQualifiedType());
- break;
- }
- }
- }
-
- }
-
- private void updateValueStatus() {
- if (valueField == null) {
- return;
- }
- valueObject = null;
- if (valueTypeField.getText().equalsIgnoreCase(
- IFacesConfigConstants.NULL_VALUE)) {
- valueField.setEnabled(false);
- valueObject = FacesConfigFactory.eINSTANCE.createNullValueType();
- } else if (valueTypeField.getText().equalsIgnoreCase(
- IFacesConfigConstants.MAP_ENTRIES)
- || valueTypeField.getText().equalsIgnoreCase(
- IFacesConfigConstants.LIST_ENTRIES)) {
- valueField.getTextControl(null, parent).setEditable(false);
- valueField.setEnabled(true);
- } else {
- valueObject = ""; //$NON-NLS-1$
- valueField.getTextControl(null, parent).setEditable(true);
- valueField.setEnabled(true);
- }
- }
-
- /**
- * @param valueType_
- * @param value
- */
- protected void handleChangeValue(String valueType_, String value) {
- if (valueType_.equalsIgnoreCase(IFacesConfigConstants.VALUE)) {
- handleChangeLongStringValue(value);
- } else if (valueType_
- .equalsIgnoreCase(IFacesConfigConstants.MAP_ENTRIES)) {
- handleChangeMapEntries();
- } else if (valueType_
- .equalsIgnoreCase(IFacesConfigConstants.LIST_ENTRIES)) {
- handleChangeListEntries();
- }
- }
-
- /**
- * @param textControl
- */
- private void handleChangeLongStringValue(String value) {
- EditValueDialog valueDialog = new EditValueDialog(EditorPlugin
- .getActiveShell(), value);
- if (valueDialog.open() == Window.OK) {
- valueField.setText((String) valueDialog.getResultData());
- valueObject = valueDialog.getResultData();
- }
- }
-
- /**
- *
- */
- private void handleChangeMapEntries() {
-
- MapEntriesType mapEntries;
-
- if (valueObject instanceof MapEntriesType)
- mapEntries = (MapEntriesType) valueObject;
- else if (isNew || managedProperty.getMapEntries() == null) {
- mapEntries = FacesConfigFactory.eINSTANCE.createMapEntriesType();
- } else {
- mapEntries = (MapEntriesType) EcoreUtil.copy(managedProperty
- .getMapEntries());
- }
-
- EditMapEntriesDialog dialog = new EditMapEntriesDialog(EditorPlugin
- .getActiveShell(), mapEntries, section);
- if (dialog.open() == Dialog.OK) {
- valueObject = dialog.getMapEntries();
- } else {
- //user cancel the dialog, then restore.
- if (!isNew && managedProperty.getMapEntries() != null)
- valueObject = EcoreUtil.copy(managedProperty
- .getMapEntries());
- // else
- // valueObject = null;
- }
- }
-
- private void handleChangeListEntries() {
- ListEntriesType listEntries;
-
- if (valueObject instanceof ListEntriesType)
- listEntries = (ListEntriesType) valueObject;
- else if (isNew || managedProperty.getListEntries() == null) {
- listEntries = FacesConfigFactory.eINSTANCE.createListEntriesType();
- } else {
- listEntries = (ListEntriesType) EcoreUtil.copy(managedProperty
- .getListEntries());
- }
-
- EditListEntriesDialog dialog = new EditListEntriesDialog(EditorPlugin
- .getActiveShell(), listEntries, section);
- if (dialog.open() == Dialog.OK) {
- valueObject = dialog.getListEntries();
- } else {
- //user cancel the dialog, then restore.
- if (!isNew && managedProperty.getListEntries() != null)
- valueObject = EcoreUtil.copy(managedProperty
- .getListEntries());
- // else
- // valueObject = null;
- }
- }
-
- /**
- * Get a list of JavaBeanProperty that from the managed bean class.
- *
- * @return
- */
- private List getBeanPropertyList(ManagedBeanType managedBean_) {
- if (managedBean_.getManagedBeanClass() == null)
- return null;
- String beanClassName = managedBean_.getManagedBeanClass()
- .getTextContent();
- IType classType = JavaClassUtils.getType(getProject(), beanClassName);
- if (classType == null) {
- return null;
- }
- List list = new ArrayList();
- JavaBeanProperty[] properties = JavaBeanUtils
- .getBeanProperties(classType);
- if (properties != null) {
- for (int i = 0; i < properties.length; i++) {
- list.add(properties[i]);
- }
- }
- return list;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /**
- * @return the project
- */
- public IProject getProject() {
- if (project == null) {
- project = (IProject) section.getPage().getEditor().getAdapter(
- IProject.class);
- }
- return project;
- }
-
- /**
- *
- */
- protected void okPressed() {
- propertyName = nameField.getText();
- propertyClass = classField.getText();
- valueType = valueTypeField.getText();
-
- super.okPressed();
- }
-
- /**
- * @return the property class
- */
- public String getPropertyClass() {
- return propertyClass;
- }
-
- /**
- * @param attributeClass
- */
- public void setAttributeClass(String attributeClass) {
- this.propertyClass = attributeClass;
- }
-
- /**
- * @return the property name
- */
- public String getPropertyName() {
- return propertyName;
- }
-
- /**
- * @param attributeName
- */
- public void setAttributeName(String attributeName) {
- this.propertyName = attributeName;
- }
-
- /**
- * @return the value type
- */
- public String getValueType() {
- return valueType;
- }
-
- /**
- * @param defaultValue
- */
- public void setValueType(String defaultValue) {
- this.valueType = defaultValue;
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-
- /**
- * @return the value object
- */
- public Object getValueObject() {
- return valueObject;
- }
-
- /**
- * @param valueObject
- */
- public void setValueObject(Object valueObject) {
- this.valueObject = valueObject;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditMapEntryDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditMapEntryDialog.java
deleted file mode 100644
index fb254fb74..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditMapEntryDialog.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-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.Shell;
-
-/**
- * The dialog is for adding and editing map-entry.
- *
- * @author sfshi
- *
- */
-public class AddEditMapEntryDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private static final int VALUE_DEFAULT_LINENUMS = 10;
-
- private boolean isNew;
-
- private StringDialogField keyField;
-
- private Button nullValueTypeButton;
-
- private StringDialogField valueField;
-
- private String key;
-
- private String value;
-
- private boolean isNullValue;
-
- /**
- * @param parentShell
- * @param isNew
- */
- public AddEditMapEntryDialog(Shell parentShell, boolean isNew) {
- super(parentShell);
- this.isNew = isNew;
- }
-
- /**
- *
- * @param parentShell
- * @param attributeName
- * @param attributeClass
- * @param defaultValue
- * @param suggestedValue
- */
- public AddEditMapEntryDialog(Shell parentShell, String attributeName,
- String attributeClass, String defaultValue, String suggestedValue) {
- super(parentShell);
- this.isNew = false;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- // TODO change it to "add"
- newShell.setText(EditorMessages.MapEntryEditPage_Title);
- else
- newShell.setText(EditorMessages.MapEntryEditPage_Title);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- gl.numColumns = 1;
- container.setLayout(gl);
-
- layoutKeySection(container);
- layoutValueSection(container);
- if (!isNew) {
- initFields();
- }
- return container;
- }
-
- private void initFields() {
- keyField.setText(key);
- if (this.isNullValue) {
- nullValueTypeButton.setSelection(true);
- valueField.setText(""); //$NON-NLS-1$
- valueField.setEnabled(false);
- } else {
- nullValueTypeButton.setSelection(false);
- valueField.setEnabled(true);
- valueField.setText(value);
- }
- }
-
- /**
- * @param parent
- */
- public void layoutKeySection(Composite parent) {
- keyField = new StringDialogField();
- keyField.setLabelText(EditorMessages.MapEntryEditGroup_Key);
- Composite
-
- keySection = SWTUtils.createComposite(parent, SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- keySection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- keySection.setLayout(gl);
-
- keyField.doFillIntoGrid(null, keySection, numberOfColumns);
-
- LayoutUtil.setGrabHorizontal(keyField.getTextControl(null, keySection),
- true);
-
- }
-
- /**
- * @param parent
- */
- public void layoutValueSection(Composite parent) {
- Composite valueSection = SWTUtils.createComposite(parent, SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- valueSection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- gl.verticalSpacing = 10;
- gl.marginHeight = 10;
- valueSection.setLayout(gl);
-
- nullValueTypeButton = SWTUtils.createCheckBox(valueSection,
- EditorMessages.AddEditMapEntryDialog_NullValue, 2);
-
- nullValueTypeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- valueField.setEnabled(!nullValueTypeButton.getSelection());
-
- }
-
- });
- valueField = new StringDialogField(VALUE_DEFAULT_LINENUMS);
-
- valueField.setLabelText(EditorMessages.ValueEditGroup_Value);
- valueField.doFillIntoGrid(null, valueSection, numberOfColumns);
-
- gd = (GridData) valueField.getLabelControl(null, valueSection)
- .getLayoutData();
- gd.verticalAlignment = gd.verticalAlignment | GridData.GRAB_VERTICAL;
- LayoutUtil.setHorizontalGrabbing(valueField.getTextControl(null,
- valueSection));
-
- gd = (GridData) valueField.getTextControl(null, valueSection)
- .getLayoutData();
- gd.verticalAlignment = gd.verticalAlignment | GridData.FILL_VERTICAL;
-
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /**
- *
- */
- protected void okPressed() {
-
- key = this.keyField.getText().trim();
- value = this.valueField.getText().trim();
- isNullValue = nullValueTypeButton.getSelection();
- super.okPressed();
- }
-
- /**
- * @return true if is null
- */
- public boolean isNullValue() {
- return isNullValue;
- }
-
- /**
- * @param isNullValue
- */
- public void setNullValue(boolean isNullValue) {
- this.isNullValue = isNullValue;
- }
-
- /**
- * @return the key
- */
- public String getKey() {
- return key;
- }
-
- /**
- * @param key
- */
- public void setKey(String key) {
- this.key = key;
- }
-
- /**
- * @return the value
- */
- public String getValue() {
- return value;
- }
-
- /**
- * @param value
- */
- public void setValue(String value) {
- this.value = value;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditPropertyDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditPropertyDialog.java
deleted file mode 100644
index 432d064b8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditPropertyDialog.java
+++ /dev/null
@@ -1,270 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-
-/**
- * The dialog is for adding and editing property.
- *
- * @author sfshi
- *
- */
-public class AddEditPropertyDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private StringDialogField propertyNameField;
-
- private ClassButtonDialogField propertyClassField;
-
- private StringDialogField defaultValueField;
-
- private StringDialogField suggestedValueField;
-
- private IProject project;
-
- private boolean isNew;
-
- private String propertyName;
-
- private String propertyClass;
-
- private String defaultValue;
-
- private String suggestedValue;
-
- /**
- *
- * @param parentShell
- * @param isNew
- */
- public AddEditPropertyDialog(Shell parentShell, boolean isNew) {
- super(parentShell);
- this.isNew = isNew;
- }
-
- /**
- *
- * @param parentShell
- * @param propertyName
- * @param propertyClass
- * @param defaultValue
- * @param suggestedValue
- */
- public AddEditPropertyDialog(Shell parentShell, String propertyName,
- String propertyClass, String defaultValue, String suggestedValue) {
- super(parentShell);
- this.propertyName = propertyName;
- this.propertyClass = propertyClass;
- this.defaultValue = defaultValue;
- this.suggestedValue = suggestedValue;
- this.isNew = false;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- newShell
- .setText(EditorMessages.PropertySection_Dialog_Title_Add);
- else
-
- newShell
- .setText(EditorMessages.PropertySection_Dialog_Title_Edit);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- TabFolder tabFolder = new TabFolder(container, SWT.FILL);
- tabFolder.setLayoutData(gd);
- TabItem generalTabItem = new TabItem(tabFolder, SWT.NONE);
- generalTabItem
- .setText(EditorMessages.PropertySection_Dialog_Tab_General);
- Control control = createGeneralTabControl(generalTabItem.getParent());
- generalTabItem.setControl(control);
- return container;
- }
-
- /**
- * @param parent
- * @return
- */
- private Control createGeneralTabControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.numColumns = 5;
- composite.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(gd);
- composite.setFont(parent.getFont());
-
- propertyNameField = new StringDialogField();
- // propertyNameField.setRequired(true);
- propertyNameField
- .setLabelText(EditorMessages.PropertySection_Dialog_PropertyName);
-
- propertyClassField = new ClassButtonDialogField(getProject());
- // propertyClassField.setRequired(true);
- propertyClassField
- .setLabelText(EditorMessages.PropertySection_Dialog_PropertyClass);
-
- propertyClassField.setAutoOpenResource(false);
-
- defaultValueField = new StringDialogField();
- defaultValueField
- .setLabelText(EditorMessages.PropertySection_Dialog_DefaultValue);
-
- suggestedValueField = new StringDialogField();
- suggestedValueField
- .setLabelText(EditorMessages.PropertySection_Dialog_SuggestedValue);
-
- GridData data = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(data);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- composite.setLayout(gl);
-
- propertyNameField.doFillIntoGrid(null, composite, numberOfColumns);
-
- propertyClassField.doFillIntoGrid(null, composite, numberOfColumns);
-
- defaultValueField.doFillIntoGrid(null, composite, numberOfColumns);
-
- suggestedValueField.doFillIntoGrid(null, composite, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(propertyClassField.getTextControl(
- null, composite));
-
- // set the initial value for these fields.
- propertyNameField.setText(propertyName);
- propertyClassField.setText(propertyClass);
- defaultValueField.setText(defaultValue);
- suggestedValueField.setText(suggestedValue);
-
- return composite;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- private IProject getProject() {
- return project;
- }
-
- protected void okPressed() {
- propertyName = propertyNameField.getText();
- propertyClass = propertyClassField.getText();
- defaultValue = defaultValueField.getText();
- suggestedValue = suggestedValueField.getText();
-
- super.okPressed();
- }
-
- /**
- * @return the default value
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the property class
- */
- public String getPropertyClass() {
- return propertyClass;
- }
-
- /**
- * @param propertyClass
- */
- public void setPropertyClass(String propertyClass) {
- this.propertyClass = propertyClass;
- }
-
- /**
- * @return the property name
- */
- public String getPropertyName() {
- return propertyName;
- }
-
- /**
- * @param propertyName
- */
- public void setPropertyName(String propertyName) {
- this.propertyName = propertyName;
- }
-
- /**
- * @return the suggested value
- */
- public String getSuggestedValue() {
- return suggestedValue;
- }
-
- /**
- * @param suggestedValue
- */
- public void setSuggestedValue(String suggestedValue) {
- this.suggestedValue = suggestedValue;
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditRendererDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditRendererDialog.java
deleted file mode 100644
index 8e40eeffe..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/AddEditRendererDialog.java
+++ /dev/null
@@ -1,297 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IStringButtonAdapter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.TabFolder;
-import org.eclipse.swt.widgets.TabItem;
-
-/**
- * @author Bryan Yang
- *
- */
-public class AddEditRendererDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private StringDialogField rendererNameField;
-
- private ClassButtonDialogField rendererClassField;
-
- private StringButtonDialogField componentFamilyField;
-
- private StringDialogField renderTypeField;
-
- private IProject project;
-
- private String rendererName;
-
- private String rendererClass;
-
- private String componentFamily;
-
- private String rendererType;
-
- private boolean isNew;
-
- private IFacesConfigPage page;
-
- /**
- * @param parentShell
- * @param page
- * @param isNew
- */
- public AddEditRendererDialog(Shell parentShell, IFacesConfigPage page,
- boolean isNew) {
- super(parentShell);
- this.page = page;
- this.isNew = isNew;
- }
-
- /**
- *
- * @param parentShell
- * @param rendererName
- * @param rendererClass
- * @param componentFamily
- * @param renderType
- */
- public AddEditRendererDialog(Shell parentShell, String rendererName,
- String rendererClass, String componentFamily, String renderType) {
- super(parentShell);
- this.rendererName = rendererName;
- this.rendererClass = rendererClass;
- this.componentFamily = componentFamily;
- this.rendererType = renderType;
- this.isNew = false;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- if (isNew)
- newShell.setText(EditorMessages.RendererSection_Dialog_Title_Add);
- else
- newShell.setText(EditorMessages.RendererSection_Dialog_Title_Edit);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- TabFolder tabFolder = new TabFolder(container, SWT.FILL);
- tabFolder.setLayoutData(gd);
- TabItem generalTabItem = new TabItem(tabFolder, SWT.NONE);
- generalTabItem
- .setText(EditorMessages.RendererSection_Dialog_Tab_General);
- Control control = createGeneralTabControl(generalTabItem.getParent());
- generalTabItem.setControl(control);
- return container;
- }
-
- /**
- * @param parent
- * @return
- */
- private Control createGeneralTabControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE);
- GridLayout layout = new GridLayout();
- layout.numColumns = 5;
- composite.setLayout(layout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(gd);
- composite.setFont(parent.getFont());
-
- rendererNameField = new StringDialogField();
- rendererNameField
- .setLabelText(EditorMessages.RendererSection_Dialog_DisplayName);
-
- rendererClassField = new ClassButtonDialogField(getProject());
-// rendererClassField.setRequired(true);
- rendererClassField
- .setLabelText(EditorMessages.RendererSection_Dialog_RendererClass);
- rendererClassField.setProject(getProject());
- rendererClassField.setSuperClassName(IFacesConfigConstants.RENDERER_SUPER_CLASS);
- rendererClassField.setAutoOpenResource(false);
-
- componentFamilyField = new StringButtonDialogField(
- new IStringButtonAdapter() {
- public void changeControlPressed(DialogField field) {
- Shell shell = EditorPlugin.getActiveShell();
- ComponentListDialog dialog = new ComponentListDialog(
- shell,
- page,
- page.getInput(),
- EditorMessages.RendererSection_Dialog_ComponentFamilyCaption,
- EditorMessages.RendererSection_Dialog_ComponentFamilyLabel);
- if (dialog.open() == Dialog.OK) {
- componentFamilyField.setText(dialog.getValue());
- }
- }
- });
- componentFamilyField
- .setLabelText(EditorMessages.RendererSection_Dialog_ComponentFamilyValue);
-// componentFamilyField.setRequired(true);
-
- renderTypeField = new StringDialogField();
-// renderTypeField.setRequired(true);
- renderTypeField
- .setLabelText(EditorMessages.RendererSection_Dialog_TypeValue);
-
- GridData data = new GridData(GridData.FILL_BOTH);
- composite.setLayoutData(data);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- composite.setLayout(gl);
-
- rendererNameField.doFillIntoGrid(null, composite, numberOfColumns);
-
- componentFamilyField.doFillIntoGrid(null, composite, numberOfColumns);
-
- renderTypeField.doFillIntoGrid(null, composite, numberOfColumns);
-
- rendererClassField.doFillIntoGrid(null, composite, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(rendererClassField.getTextControl(
- null, composite));
-
- // set the initial value for these fields.
- rendererNameField.setText(rendererName);
- rendererClassField.setText(rendererClass);
- componentFamilyField.setText(componentFamily);
- renderTypeField.setText(rendererType);
-
- return composite;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /**
- * @return the associated project
- */
- public IProject getProject() {
- return project;
- }
-
- /**
- *
- */
- protected void okPressed() {
- rendererName = rendererNameField.getText();
- rendererClass = rendererClassField.getText();
- componentFamily = componentFamilyField.getText();
- rendererType = renderTypeField.getText();
-
- super.okPressed();
- }
-
- /**
- * @return the renderer clas
- */
- public String getRendererClass() {
- return rendererClass;
- }
-
- /**
- * @param rendererClass
- */
- public void setRendererClass(String rendererClass) {
- this.rendererClass = rendererClass;
- }
-
- /**
- * @return the renderer name
- */
- public String getRendererName() {
- return rendererName;
- }
-
- /**
- * @param rendererName
- */
- public void setRendererName(String rendererName) {
- this.rendererName = rendererName;
- }
-
- /**
- * @return the component family
- */
- public String getComponentFamily() {
- return componentFamily;
- }
-
- /**
- * @param componentFamily
- */
- public void setComponentFamily(String componentFamily) {
- this.componentFamily = componentFamily;
- }
-
- /**
- * @return the renderer type
- */
- public String getRendererType() {
- return rendererType;
- }
-
- /**
- * @param rendererType
- */
- public void setRendererType(String rendererType) {
- this.rendererType = rendererType;
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/CommonListDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/CommonListDialog.java
deleted file mode 100644
index 5cae0b169..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/CommonListDialog.java
+++ /dev/null
@@ -1,245 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * @author Bryan Yang
- *
- */
-public class CommonListDialog extends Dialog implements
- ISelectionChangedListener, ISelectionProvider {
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private Text inputText;
-
- private StructuredViewer structuredViewer;
-
- private String value;
-
- private IFacesConfigPage page;
-
- private Object input;
-
- private String label;
-
- private String caption;
-
- /** The mini width for the text control */
- private static final int TEXT_MINI_WIDTH = 100;
-
- /**
- * @param parentShell
- * @param page
- * @param input
- * @param caption
- * @param label
- */
- protected CommonListDialog(Shell parentShell, IFacesConfigPage page,
- Object input, String caption, String label) {
- super(parentShell);
- this.page = page;
- this.input = input;
- this.label = label;
- this.caption = caption;
- parentShell.setText(caption);
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- newShell.setText(caption);
- }
-
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite composite = SWTUtils.createComposite(parent, 1);
-
- SWTUtils.createLabel(composite, label, 1);
-
- inputText = SWTUtils.createTextBox(composite, 1);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.widthHint = TEXT_MINI_WIDTH;
- inputText.setLayoutData(gd);
-
- structuredViewer = createViewer(composite);
- structuredViewer.addSelectionChangedListener(this);
-
- return composite;
- }
-
- /**
- * Create the structured viewer, set up content & label provider for it.
- * Defaultly create a tableviewer.
- *
- * @param parent
- * @return the structured viewer
- */
- protected StructuredViewer createViewer(Composite parent) {
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.heightHint = 200;
- gd.widthHint = 150;
- parent.setLayoutData(gd);
- GridLayout layout = new GridLayout();
- parent.setLayout(layout);
-
- TableViewer tableViewer = new TableViewer(parent, SWT.SINGLE
- | SWT.H_SCROLL | SWT.V_SCROLL);
- gd = new GridData(GridData.FILL_BOTH);
- tableViewer.getControl().setLayoutData(gd);
-
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
- configViewer(tableViewer);
- tableViewer.setInput(input);
-
- return tableViewer;
- }
-
- /**
- * set the structuredViewer's input
- *
- * @param input
- */
- private void setViewerInput(Object input) {
- structuredViewer.setInput(input);
- this.input = input;
- }
-
- /**
- * get the input object of this section.
- * @return the input
- */
- public Object getInput() {
- return input;
- }
-
- /**
- * set input object for this section.
- * @param newInput
- */
- public void setInput(Object newInput) {
- input = newInput;
- setViewerInput(input);
- }
-
- /**
- * Config the viewer, such as set a filter and so on. Sub classes should
- * override this method to add filter.
- *
- * @param structuredViewer_
- */
- protected void configViewer(StructuredViewer structuredViewer_) {
- // do nothing; sub-classes should override
- }
-
- //TODO: why bother with this interface?
- public void selectionChanged(SelectionChangedEvent event) {
- // selectionChanged not handled
-
- }
-
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- // do nothing; not handling setSelection
- }
-
- public ISelection getSelection() {
- return structuredViewer.getSelection();
- }
-
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- // do nothing; not handling setSelection
- }
-
- public void setSelection(ISelection selection) {
- // do nothing; not handling change in selection
- }
-
- /**
- * the convenient method to get the AdapterFactory instance of the editor;
- *
- * @return the AdapterFactory instance.
- */
- public AdapterFactory getAdapterFactory() {
- return (AdapterFactory) page.getEditor().getAdapter(
- AdapterFactory.class);
- }
-
- /**
- * the convenient method to get the EditingDomain instance of the editor;
- *
- * @return the EditingDomain instance.
- */
- public EditingDomain getEditingDomain() {
- return (EditingDomain) page.getEditor().getAdapter(EditingDomain.class);
- }
-
- /**
- * @return the value
- */
- public String getValue() {
- return value;
- }
- /**
- * @param value
- */
- public void setValue(String value) {
- this.value = value;
- refresh();
- }
-
- private void refresh()
- {
- inputText.setText(value) ;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ComponentListDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ComponentListDialog.java
deleted file mode 100644
index 8c83c0490..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ComponentListDialog.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.util.Iterator;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ComponentListDialog extends CommonListDialog {
-
- public void selectionChanged(SelectionChangedEvent event) {
- IStructuredSelection ssel = StructuredSelection.EMPTY;
- ISelection selection = getSelection();
- if (selection instanceof IStructuredSelection) {
- ssel = (IStructuredSelection) selection;
- }
-
- if (!ssel.isEmpty()) {
- for (Iterator iter = ssel.iterator(); iter.hasNext();) {
- ComponentType element = (ComponentType) iter.next();
- if (element.getComponentType() != null)
- setValue(element.getComponentType().getTextContent());
- else
- setValue(""); //$NON-NLS-1$
- }
-
- }
- }
-
- /**
- * @param parentShell
- * @param page
- * @param input
- * @param caption
- * @param label
- */
- protected ComponentListDialog(Shell parentShell, IFacesConfigPage page,
- Object input, String caption, String label) {
- super(parentShell, page, input, caption, label);
- }
-
- protected void configViewer(StructuredViewer structuredViewer) {
- super.configViewer(structuredViewer);
- structuredViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getComponentType()
- .isInstance(element);
- }
- });
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/DialogUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/DialogUtil.java
deleted file mode 100644
index 7ced39020..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/DialogUtil.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.JavaUIHelper;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.dialogs.SelectionDialog;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-public final class DialogUtil {
-
- /**
- * @param shell
- * @param project
- * @param superType
- * @param tyle
- * @return fully qualified class name or null
- */
- public static String openClassDialog(Shell shell, IProject project,
- String superType, int tyle) {
- SelectionDialog dialog = JavaUIHelper
- .openSelectionDialog(shell, project, superType, tyle);
-
- // dialog could be null
- if (dialog != null)
- {
- dialog.setTitle(EditorMessages.FindType);
- dialog.setMessage(EditorMessages.FindType_Filter);
- if (dialog.open() == SelectionDialog.OK) {
- Object[] result = dialog.getResult();
- IType searchedType = (IType) result[0];
- return searchedType.getFullyQualifiedName();
- }
- }
- return null;
- }
-
- /**
- * @param shell
- * @param facesConfig
- * @return the name of the renderkit or null
- */
- public static String openRenderKitDialog(Shell shell,
- FacesConfigType facesConfig) {
- if (facesConfig != null) {
- EList list = facesConfig.getRenderKit();
- ArrayList ids = new ArrayList();
- for (int i = 0, n = list.size(); i < n; i++) {
- RenderKitIdType renderKitId = ((RenderKitType) list.get(i))
- .getRenderKitId();
- if (renderKitId != null) {
- if (!"".equals(renderKitId.getTextContent())) { //$NON-NLS-1$
- ids.add(renderKitId.getTextContent());
- }
- }
- }
- String[] idArray = (String[]) ids.toArray(new String[ids.size()]);
- Arrays.sort(idArray);
- ListChoiceDialog dialog = new ListChoiceDialog(
- shell,
- idArray,
- EditorMessages.DefaultRenderKitIDSection_Wizard_Page_LabelText);
- if (dialog.open() == SelectionDialog.OK) {
- String result = dialog.getResult();
- if (!"".equals(result)) { //$NON-NLS-1$
- return result;
- }
- }
- }
- return null;
- }
-
- /**
- * @param shell
- * @param existedLocaleList
- * @return the locale or null
- */
- public static String openLocaleDialog(Shell shell, List existedLocaleList) {
- LocaleDialog dialog = new LocaleDialog(shell, existedLocaleList);
- if (dialog.open() == Window.OK) {
- String result = dialog.getResult();
- if (!"".equals(result)) { //$NON-NLS-1$
- return result;
- }
- }
- return null;
- }
-
- /**
- * @param shell
- * @param project
- * @param existedBundleList
- * @return the message bundle or null
- */
- public static String openMessageBundleDialog(Shell shell, IProject project,
- List existedBundleList) {
- IJavaProject javaProject = null;
-
- try {
- if (project != null && project.hasNature(JavaCore.NATURE_ID)) {
- javaProject = JavaCore.create(project);
- } else {
- return null;
- }
- } catch (CoreException e) {
- // Ignore
- }
- MessageBundleSelectionDialog dialog = new MessageBundleSelectionDialog(
- shell, javaProject, existedBundleList);
-
- if (dialog.open() == SelectionDialog.OK) {
- String newValue = (String) dialog.getResult()[0];
- if (!"".equalsIgnoreCase(newValue)) { //$NON-NLS-1$
- return newValue;
- }
- }
- return null;
- }
-
- private DialogUtil()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditListEntriesDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditListEntriesDialog.java
deleted file mode 100644
index 89b6da90a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditListEntriesDialog.java
+++ /dev/null
@@ -1,414 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldBase;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ListEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.NullValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-
-/**
- *
- * @author sfshi
- *
- */
-public class EditListEntriesDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private ClassButtonDialogField valueClassField;
-
- private IProject project;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- private ListEntriesType listEntries;
-
- private AbstractFacesConfigSection section;
-
- /**
- *
- * @param parentShell
- * @param listEntries
- * the list-entries element that working on.
- * @param section
- */
- public EditListEntriesDialog(Shell parentShell,
- ListEntriesType listEntries, AbstractFacesConfigSection section) {
- super(parentShell);
- this.listEntries = listEntries;
- this.section = section;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- newShell.setText(EditorMessages.EditListEntriesDialog_EditingListEntries);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridData data = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(data);
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- // gl.marginHeight = 0;
- container.setLayout(gl);
- createKeyValueSection(container);
- createTableSection(container);
-
- initFields();
- return container;
- }
-
- private void initFields() {
-
- if (listEntries.getValueClass() != null)
- valueClassField.setText(listEntries.getValueClass()
- .getTextContent());
-
- tableViewer.setInput(listEntries);
- }
-
- private void createKeyValueSection(Composite parent) {
- valueClassField = new ClassButtonDialogField(getProject());
-
- valueClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_ValueClass);
- Composite typeSelectionSection = SWTUtils.createComposite(parent,
- SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- typeSelectionSection.setLayoutData(gd);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- typeSelectionSection.setLayout(gl);
-
- valueClassField.doFillIntoGrid(null, typeSelectionSection,
- numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(valueClassField.getTextControl(null,
- parent));
- }
-
- /**
- *
- * @param parent
- */
- private void createTableSection(Composite parent) {
- Composite mapValueSection = SWTUtils.createComposite(parent, SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- mapValueSection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- mapValueSection.setLayout(gl);
-
- DialogField valuesTitle = new DialogFieldBase();
- valuesTitle
- .setLabelText(EditorMessages.InitializationSection_MapTable_Title);
-
- valuesTitle.doFillIntoGrid(null, mapValueSection, numberOfColumns);
-
- Table mapTable = new Table(mapValueSection, SWT.FULL_SELECTION
- | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
-
- mapTable.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- updateButtonsStatus();
-
- }
-
- });
- mapTable.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected(null);
- }
- });
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- mapTable.setLayoutData(gd);
- mapTable.setHeaderVisible(true);
- mapTable.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- layout.addColumnData(new ColumnWeightData(1, true));
- mapTable.setLayout(layout);
-
- TableColumn keyCol = new TableColumn(mapTable, SWT.NONE);
- keyCol
- .setText(EditorMessages.InitializationSection_MapTable_Value);
- layout.addColumnData(new ColumnWeightData(1, true));
- keyCol.setResizable(true);
-
- tableViewer = new TableViewer(mapTable);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getValueType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE.getNullValueType()
- .isInstance(element);
- }
- });
-
- Composite operationContainer = null;
-
- operationContainer = SWTUtils
- .createComposite(mapValueSection, SWT.NONE);
-
- gd = new GridData(GridData.FILL_VERTICAL);
- operationContainer.setLayoutData(gd);
- gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Add_more);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
- addButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected(e);
- }
- });
-
- editButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Edit_more);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
- editButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected(e);
- }
-
- });
- removeButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Remove);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
-
- });
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
-
- private AdapterFactory getAdapterFactory() {
- return section.getAdapterFactory();
- }
-
- private void addButtonSelected(SelectionEvent e) {
-
- EditValueDialog dialog = new EditValueDialog(EditorPlugin
- .getActiveShell(), true, false, null);
- if (dialog.open() == Dialog.OK) {
- if (dialog.isNullValue()) {
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- listEntries.getNullValue().add(nullValue);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) dialog.getResultData());
- listEntries.getValue().add(value);
- }
- }
-
- }
-
- private void editButtonSelected(SelectionEvent e) {
- Object select = ((IStructuredSelection) tableViewer.getSelection())
- .getFirstElement();
- boolean isNullValue;
- String valueText = null;
- if (select instanceof NullValueType)
- isNullValue = true;
- else {
- isNullValue = false;
- valueText = ((ValueType) select).getTextContent();
- }
-
- EditValueDialog dialog = new EditValueDialog(EditorPlugin
- .getActiveShell(), true, isNullValue, valueText);
- if (dialog.open() == Dialog.OK) {
- if (isNullValue && !dialog.isNullValue()) {
- listEntries.getNullValue().remove(select);
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) dialog.getResultData());
- listEntries.getValue().add(value);
- } else if (!isNullValue && dialog.isNullValue()) {
- listEntries.getValue().remove(select);
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- listEntries.getNullValue().add(nullValue);
- } else if (!isNullValue && !dialog.isNullValue()) {
- ((ValueType) select).setTextContent((String) dialog
- .getResultData());
- }
- }
- }
-
- private void removeButtonSelected() {
- Object select = ((IStructuredSelection) tableViewer.getSelection())
- .getFirstElement();
- if (select instanceof NullValueType)
- listEntries.getNullValue().remove(select);
- else
- listEntries.getValue().remove(select);
- tableViewer.refresh();
- updateButtonsStatus();
- }
-
- /**
- * update the status buttons
- */
- public void updateButtonsStatus() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- *
- */
- protected void okPressed() {
-
- String valueClass = valueClassField.getText();
- if (listEntries.getValueClass() != null) {
- listEntries.getValueClass().setTextContent(valueClass);
- } else {
- ValueClassType valueClassType = FacesConfigFactory.eINSTANCE
- .createValueClassType();
- valueClassType.setTextContent(valueClass);
- listEntries.setValueClass(valueClassType);
- }
- super.okPressed();
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /**
- * @return the current project
- */
- public IProject getProject() {
- if (project == null) {
- project = (IProject) section.getPage().getEditor().getAdapter(
- IProject.class);
- }
- return project;
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-
- /**
- * @return the list entries
- */
- public ListEntriesType getListEntries() {
- return listEntries;
- }
-
- /**
- * @param listEntries
- */
- public void setListEntries(ListEntriesType listEntries) {
- this.listEntries = listEntries;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditMapEntriesDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditMapEntriesDialog.java
deleted file mode 100644
index ee914628f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditMapEntriesDialog.java
+++ /dev/null
@@ -1,449 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldBase;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.KeyClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.KeyType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntryType;
-import org.eclipse.jst.jsf.facesconfig.emf.NullValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-
-/**
- *
- * @author sfshi
- *
- */
-public class EditMapEntriesDialog extends Dialog {
-
- private static final int MIN_DIALOG_WIDTH = 300;
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private ClassButtonDialogField keyClassField;
-
- private ClassButtonDialogField valueClassField;
-
- private IProject project;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- private MapEntriesType mapEntries;
-
- private AbstractFacesConfigSection section;
-
- /**
- *
- * @param parentShell
- * @param mapEntries
- * the map-entries element that working on.
- * @param section
- */
- public EditMapEntriesDialog(Shell parentShell, MapEntriesType mapEntries,
- AbstractFacesConfigSection section) {
- super(parentShell);
- this.mapEntries = mapEntries;
- this.section = section;
- }
-
- /*
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- newShell.setText(EditorMessages.EditMapEntriesDialog_EditingMapEntries);
- }
-
- /*
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite container = new Composite(parent, SWT.FILL);
- GridData data = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(data);
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- // gl.marginHeight = 0;
- container.setLayout(gl);
- createKeyValueSection(container);
- createTableSection(container);
-
- initFields();
- return container;
- }
-
- private void initFields() {
-
- if (mapEntries.getKeyClass() != null)
- keyClassField.setText(mapEntries.getKeyClass().getTextContent());
-
- if (mapEntries.getValueClass() != null)
- valueClassField
- .setText(mapEntries.getValueClass().getTextContent());
-
- tableViewer.setInput(mapEntries);
- }
-
- private void createKeyValueSection(Composite parent) {
- keyClassField = new ClassButtonDialogField(getProject());
- keyClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_KeyClass);
-
- valueClassField = new ClassButtonDialogField(getProject());
-
- valueClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_ValueClass);
-
- Composite typeSelectionSection = SWTUtils.createComposite(parent,
- SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- typeSelectionSection.setLayoutData(gd);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- typeSelectionSection.setLayout(gl);
-
- keyClassField.doFillIntoGrid(null, typeSelectionSection,
- numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(keyClassField.getTextControl(null,
- parent));
-
- valueClassField.doFillIntoGrid(null, typeSelectionSection,
- numberOfColumns);
- }
-
- /**
- *
- * @param parent
- */
- private void createTableSection(Composite parent) {
- Composite mapValueSection = SWTUtils.createComposite(parent, SWT.NONE);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- mapValueSection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- mapValueSection.setLayout(gl);
-
- DialogField valuesTitle = new DialogFieldBase();
- valuesTitle
- .setLabelText(EditorMessages.InitializationSection_MapTable_Title);
-
- valuesTitle.doFillIntoGrid(null, mapValueSection, numberOfColumns);
-
- Table mapTable = new Table(mapValueSection, SWT.FULL_SELECTION
- | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
-
- mapTable.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- updateButtonsStatus();
-
- }
-
- });
- mapTable.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected(null);
- }
- });
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- mapTable.setLayoutData(gd);
- mapTable.setHeaderVisible(true);
- mapTable.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- mapTable.setLayout(layout);
-
- TableColumn keyCol = new TableColumn(mapTable, SWT.NONE);
- keyCol
- .setText(EditorMessages.InitializationSection_MapTable_Key);
- layout.addColumnData(new ColumnWeightData(1, true));
- keyCol.setResizable(true);
-
- TableColumn valueCol = new TableColumn(mapTable, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
-
- valueCol
- .setText(EditorMessages.InitializationSection_MapTable_Value);
- valueCol.setResizable(true);
-
- tableViewer = new TableViewer(mapTable);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getMapEntryType()
- .isInstance(element);
- }
- });
-
- // map's operation buttons
- Composite operationContainer = null;
-
- operationContainer = SWTUtils
- .createComposite(mapValueSection, SWT.NONE);
-
- gd = new GridData(GridData.FILL_VERTICAL);
- operationContainer.setLayoutData(gd);
- gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Add_more);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
- addButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected(e);
- }
- });
-
- editButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Edit_more);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
- editButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected(e);
- }
-
- });
- removeButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Remove);
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
-
- });
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
-
- /**
- * @return the current project
- */
- public IProject getProject() {
- if (project == null) {
- project = (IProject) section.getPage().getEditor().getAdapter(
- IProject.class);
- }
- return project;
- }
- private AdapterFactory getAdapterFactory() {
- return section.getAdapterFactory();
- }
-
- private void addButtonSelected(SelectionEvent e) {
- AddEditMapEntryDialog dialog = new AddEditMapEntryDialog(EditorPlugin
- .getActiveShell(), true);
- if (dialog.open() == Dialog.OK) {
- MapEntryType mapEntry = FacesConfigFactory.eINSTANCE
- .createMapEntryType();
- if (dialog.getKey() != null) {
- KeyType key = FacesConfigFactory.eINSTANCE.createKeyType();
- key.setTextContent(dialog.getKey());
- mapEntry.setKey(key);
- }
- if (dialog.isNullValue()) {
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- mapEntry.setNullValue(nullValue);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent(dialog.getValue());
- mapEntry.setValue(value);
- }
-
- mapEntries.getMapEntry().add(mapEntry);
- }
-
- }
-
- private void editButtonSelected(SelectionEvent e) {
- MapEntryType mapEntry = (MapEntryType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- AddEditMapEntryDialog dialog = new AddEditMapEntryDialog(EditorPlugin
- .getActiveShell(), false);
- if (mapEntry.getKey() != null)
- dialog.setKey(mapEntry.getKey().getTextContent());
- if (mapEntry.getNullValue() != null)
- dialog.setNullValue(true);
- else if (mapEntry.getValue() != null)
- dialog.setValue(mapEntry.getValue().getTextContent());
-
- if (dialog.open() == Dialog.OK) {
- if (mapEntry.getKey() != null)
- mapEntry.getKey().setTextContent(dialog.getKey());
- else {
- KeyType keyType = FacesConfigFactory.eINSTANCE.createKeyType();
- keyType.setTextContent(dialog.getKey());
- mapEntry.setKey(keyType);
- }
- if (dialog.isNullValue()) {
- if (mapEntry.getValue() != null)
- EcoreUtil.remove(mapEntry.getValue());
- // mapEntry.eUnset(FacesConfigPackage.eINSTANCE.getMapEntryType_Value());
- mapEntry.setNullValue(FacesConfigFactory.eINSTANCE
- .createNullValueType());
-
- } else {
- if (mapEntry.getNullValue() != null)
- EcoreUtil.remove(mapEntry.getNullValue());
- if (mapEntry.getValue() != null)
- mapEntry.getValue().setTextContent(dialog.getValue());
- else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent(dialog.getValue());
- mapEntry.setValue(value);
- }
-
- }
- tableViewer.refresh(mapEntry);
- }
-
- }
-
- private void removeButtonSelected() {
- MapEntryType mapEntry = (MapEntryType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- mapEntries.getMapEntry().remove(mapEntry);
- tableViewer.refresh();
- updateButtonsStatus();
- }
-
- /**
- * update the button status
- */
- public void updateButtonsStatus() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- *
- */
- protected void okPressed() {
- KeyClassType keyClass = FacesConfigFactory.eINSTANCE
- .createKeyClassType();
- keyClass.setTextContent(this.keyClassField.getText().trim());
- mapEntries.setKeyClass(keyClass);
- ValueClassType valueClass = FacesConfigFactory.eINSTANCE
- .createValueClassType();
- valueClass.setTextContent(this.valueClassField.getText().trim());
- mapEntries.setValueClass(valueClass);
- super.okPressed();
- }
-
- /*
- * @see org.eclipse.jface.window.Window#getInitialSize()
- */
- protected Point getInitialSize() {
- Point shellSize = super.getInitialSize();
- return new Point(Math.max(
- convertHorizontalDLUsToPixels(MIN_DIALOG_WIDTH), shellSize.x),
- shellSize.y);
- }
-
- /**
- * @param project
- */
- public void setProject(IProject project) {
- this.project = project;
- }
-
- /**
- * @return the map entries
- */
- public MapEntriesType getMapEntries() {
- return mapEntries;
- }
-
- /**
- * @param mapEntries
- */
- public void setMapEntries(MapEntriesType mapEntries) {
- this.mapEntries = mapEntries;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditValueDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditValueDialog.java
deleted file mode 100644
index d69d66daf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/EditValueDialog.java
+++ /dev/null
@@ -1,226 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldBase;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.swt.SWT;
-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.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * This dialog is used to edit managed bean's property. if the
- * bDefinitionEditable is true, the property's name, class type, and initial
- * value can be edit and changed. otherwise, only initial value can be changed.
- *
- * @author Xiao-guang Zhang, sfshi
- */
-public class EditValueDialog extends Dialog {
-
- /** default dialog width and height */
- private static final int VALUE_WIDTH = 380;
-
- private static final int VALUE_HEIGHT = 220;
-
- private String value;
-
- /** property's initla value text control */
- private Text valueText;
-
- private Button nullValueTypeButton;
-
- private boolean isNullButtonShown;
-
- private boolean isNullValue;
-
- /**
- * Equivilent to EditValueDialog(parentShell, false, false, value)
- *
- * @param parentShell
- * @param value
- */
- public EditValueDialog(Shell parentShell, String value) {
- this(parentShell, false, false, value);
- this.value = value;
- this.isNullButtonShown = false;
- }
-
- /**
- * @param parentShell
- * @param isNullButtonShown
- * @param isNullValue
- * @param value
- */
- public EditValueDialog(Shell parentShell, boolean isNullButtonShown,
- boolean isNullValue, String value) {
- super(parentShell);
- this.isNullValue = isNullValue;
- this.value = value;
- this.isNullButtonShown = isNullButtonShown;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#createDialogArea(Composite)
- */
- protected Control createDialogArea(Composite parent) {
- GridLayout gridLayout;
- Composite container = (Composite) super.createDialogArea(parent);
- gridLayout = new GridLayout();
- gridLayout.numColumns = 1;
- gridLayout.marginHeight = 10;
- gridLayout.marginWidth = 10;
- container.setLayout(gridLayout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gd);
-
- if (this.isNullButtonShown) {
- nullValueTypeButton = SWTUtils.createCheckBox(container,
- IFacesConfigConstants.NULL_VALUE, 2);
- nullValueTypeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- valueText.setEnabled(!nullValueTypeButton.getSelection());
- isNullValue = nullValueTypeButton.getSelection();
- }
-
- });
- }
-
- DialogField valueTitle = new DialogFieldBase();
- // ManagedBeansPage.ManagedBeanInitializationSection.MapTable.Title =
- // Values:
- valueTitle
- .setLabelText(EditorMessages.ManagedBeanPropertyEditDialog_Value);
- valueTitle.doFillIntoGrid(null, container, 1);
-
- gd = new GridData(GridData.FILL_BOTH);
- gd.widthHint = VALUE_WIDTH;
- gd.heightHint = VALUE_HEIGHT;
- valueText = new Text(container, SWT.MULTI | SWT.BORDER);
- valueText.setLayoutData(gd);
-
- initFields();
- return container;
- }
-
- private void initFields() {
-
- if (isNullButtonShown && isNullValue) {
- nullValueTypeButton.setSelection(true);
- valueText.setEnabled(false);
- } else if (value != null) {
- valueText.setText(value);
- }
- }
-
- /**
- * create a inital value group
- *
- * @param container -
- * parent composite control
- */
- protected void createValueSection(Composite container) {
- Composite valueSection = new Composite(container, SWT.NONE);
- GridLayout gl = new GridLayout();
- // gl.marginHeight = 20;
- gl.numColumns = 2;
- valueSection.setLayout(gl);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- valueSection.setLayoutData(gd);
-
- Label lblValue = new Label(valueSection, SWT.LEFT);
- gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
- gd.widthHint = 100;
- lblValue.setLayoutData(gd);
-
- // ManagedBeanPropertyEditDialog.Value = Value:
- lblValue
- .setText(EditorMessages.ManagedBeanPropertyEditDialog_Value);
-
- gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL
- | GridData.FILL_HORIZONTAL);
- gd.widthHint = 200;
- valueText = new Text(valueSection, SWT.BORDER);
- valueText.setLayoutData(gd);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#createButtonsForButtonBar(Composite)
- */
- protected void createButtonsForButtonBar(Composite parent) {
- createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL,
- true);
- createButton(parent, IDialogConstants.CANCEL_ID,
- IDialogConstants.CANCEL_LABEL, false);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#configureShell(Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- newShell.setText(EditorMessages.ValueEditDialog_Title);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#buttonPressed(int)
- */
- protected void buttonPressed(int buttonId) {
- if (buttonId == IDialogConstants.CANCEL_ID) {
- setReturnCode(CANCEL);
- close();
- return;
- } else if (buttonId == IDialogConstants.OK_ID) {
- value = valueText.getText();
- setReturnCode(OK);
- close();
- return;
- }
- super.buttonPressed(buttonId);
- }
-
- /**
- * @return the result data
- */
- public Object getResultData() {
- return value;
- }
-
- /**
- * @return tru if isNullButtonShown and isNullValue are both true
- */
- public boolean isNullValue() {
- return this.isNullButtonShown && isNullValue;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ListChoiceDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ListChoiceDialog.java
deleted file mode 100644
index 9538b115a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/ListChoiceDialog.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-public class ListChoiceDialog extends Dialog {
- /** The mini width for the text control */
- private static final int TEXT_MINI_WIDTH = 350;
-
- /** The mini width for the table viewer control */
- private static final int TABLEVIEWER_MINI_WIDTH = 200;
-
- private Text inputText;
-
- private TableViewer tableViewer;
-
- private String[] items;
-
- private String result;
-
- private String labelString;
-
- /**
- * @param parentShell
- * @param items
- * @param labelString
- */
- public ListChoiceDialog(Shell parentShell, String[] items, String labelString) {
- super(parentShell);
- // if passed null for items, make it an empty array of strings
- this.items = items == null ? new String[0] : items;
- this.labelString = labelString;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite composite = SWTUtils.createComposite(parent, 1);
-
- SWTUtils.createLabel(composite, labelString, 1);
-
- inputText = SWTUtils.createTextBox(composite, 1);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.widthHint = TEXT_MINI_WIDTH;
- inputText.setLayoutData(gd);
-
- inputText.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- result = inputText.getText();
- }
- });
-
- createTableViewer(composite);
- return composite;
- }
-
- /**
- * @param composite
- */
- private void createTableViewer(Composite composite) {
- tableViewer = new TableViewer(composite, SWT.BORDER | SWT.H_SCROLL
- | SWT.V_SCROLL);
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.heightHint = TABLEVIEWER_MINI_WIDTH;
- tableViewer.getControl().setLayoutData(gd);
- tableViewer.add(items);
- tableViewer
- .addSelectionChangedListener(new ISelectionChangedListener() {
- public void selectionChanged(SelectionChangedEvent event) {
- IStructuredSelection selection = (IStructuredSelection) event
- .getSelection();
- if (selection != null) {
- String text = (String) selection.getFirstElement();
- if (text != null && text.length() > 0) {
- result = text;
- inputText.setText(text);
- }
- }
- }
- });
- }
-
- /**
- * @return the result
- */
- public String getResult()
- {
- return result;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/LocaleDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/LocaleDialog.java
deleted file mode 100644
index 21e51695b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/LocaleDialog.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Locale;
-
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-public class LocaleDialog extends StatusDialog {
- private Text inputText;
-
- private TableViewer tableViewer;
-
- private String newLocale;
-
- private List existedLocaleList;
-
- private List itemsList;
-
- /** The mini width for the text control */
- private static final int TEXT_MINI_WIDTH = 350;
-
- /** The mini width for the table viewer control */
- private static final int TABLEVIEWER_MINI_WIDTH = 200;
-
- class LocaleViewerFilter extends ViewerFilter {
- private String locale;
-
- LocaleViewerFilter(String locale) {
- super();
- this.locale = locale;
- }
-
- public boolean select(Viewer v, Object parent, Object object) {
- if (object instanceof String) {
- if (null == locale || locale.length() == 0) {
- return true;
- }
- String aLocale = (String) object;
- return aLocale.startsWith(this.locale);
- }
- return false;
- }
- }
-
- /**
- *
- * @param parentShell
- * @param existedLocaleList
- */
- public LocaleDialog(Shell parentShell, List existedLocaleList) {
- super(parentShell);
- this.existedLocaleList = existedLocaleList;
- Locale[] locales = Locale.getAvailableLocales();
- itemsList = new ArrayList(locales.length);
-
- for (int i = 0, n = locales.length; i < n; i++) {
- itemsList.add(locales[i].toString());
- }
-
- setStatusMessage(EditorMessages.LocaleConfigSection_Wizard_Page_AlreadyExistsError);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets.Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
- newShell.setText(EditorMessages.LocaleConfigSection_Wizard_WindowTitle);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jst.jsf.facesconfig.ui.dialog.StatusDialog#createDialogContents(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogContents(Composite parent) {
- GridLayout layout = new GridLayout();
- layout.marginWidth = 0;
- layout.marginHeight = 0;
- parent.setLayout(layout);
-
- SWTUtils
- .createLabel(
- parent,
- EditorMessages.LocaleConfigSection_Wizard_Page_LabelText,
- 1);
-
- inputText = SWTUtils.createTextBox(parent, 1);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.widthHint = TEXT_MINI_WIDTH;
- inputText.setLayoutData(gd);
-
- inputText.addKeyListener(new KeyAdapter() {
- public void keyReleased(KeyEvent e) {
- newLocale = inputText.getText();
- tableViewer.resetFilters();
- tableViewer.addFilter(new LocaleViewerFilter(newLocale));
- tableViewer.add(itemsList.toArray());
- updateStatus();
- }
- });
-
- createTableViewer(parent);
- return parent;
- }
-
- /**
- * @param composite
- */
- private void createTableViewer(Composite composite) {
- tableViewer = new TableViewer(composite, SWT.BORDER | SWT.H_SCROLL
- | SWT.V_SCROLL);
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.heightHint = TABLEVIEWER_MINI_WIDTH;
- tableViewer.getControl().setLayoutData(gd);
- tableViewer.add(itemsList.toArray());
-
- tableViewer
- .addSelectionChangedListener(new ISelectionChangedListener() {
- public void selectionChanged(SelectionChangedEvent event) {
-
- IStructuredSelection selection = (IStructuredSelection) event
- .getSelection();
- if (selection != null) {
- String text = (String) selection.getFirstElement();
- if (text != null && text.length() > 0) {
- newLocale = text;
- inputText.setText(text);
- updateStatus();
- }
- }
- }
- });
-
- }
-
- protected boolean isValid()
- {
- if (existedLocaleList != null && existedLocaleList.contains(newLocale)) {
- return false;
- }
- return true;
- }
-
- /**
- * @return the result
- */
- public String getResult()
- {
- return newLocale;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleSelectionDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleSelectionDialog.java
deleted file mode 100644
index d4e34d862..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleSelectionDialog.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.jst.jsf.common.ui.internal.dialogs.ResourceOnClasspathDialog;
-import org.eclipse.jst.jsf.facesconfig.emf.MessageBundleType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * @author sfshi
- * @version
- */
-public class MessageBundleSelectionDialog extends ResourceOnClasspathDialog {
- /** A list contains the resoursebundles existing in faces config */
- private List resourceBundles;
-
- private String selectPropertyFileMessage = EditorMessages.MessageBundleSection_Dialog_Message_SelectPropertyFile;
-
- private String alreadyExistStatusMessage = EditorMessages.MessageBundleSection_Dialog_Message_AlreadyExists;
-
- private static final String[] PROPERTIES_FILES_SUFFIXS = new String[] { IFileFolderConstants.EXT_PROPERTIES };
-
- /**
- * @param parentShell
- * @param project
- * @param resourceBundles
- */
- public MessageBundleSelectionDialog(Shell parentShell,
- IJavaProject project, List resourceBundles) {
- super(parentShell, project);
- this.resourceBundles = resourceBundles;
- setSuffixs(PROPERTIES_FILES_SUFFIXS);
-
- setTitle(EditorMessages.MessageBundleSection_Dialog_Title);
- setViewerSorter(new MessageBundleViewerSorter());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogs.TreeViewerSelectionDialog#isValidSelection(java.lang.Object)
- */
- protected boolean isValidSelection(Object selection) {
- if (!(super.isValidSelection(selection))) {
- setStatusMessage(selectPropertyFileMessage);
- return false;
- }
-
- List selectionList = new ArrayList();
- selectionList.add(selection);
- this.setResult(selectionList);
- Object result = super.getResult()[0];
- if (null == result) {
- setStatusMessage(selectPropertyFileMessage);
- return false;
- }
-
- String newResourceBundle = (String) result;
-
- if (isAlreadyExist(newResourceBundle)) {
- this.setStatusMessage(alreadyExistStatusMessage);
- return false;
- }
-
- return true;
- }
-
- /**
- * Determine whether this resource bundle file has already been defined in
- * faces config.
- *
- * @return boolean
- */
- private boolean isAlreadyExist(String resourceBundleString) {
- if (null == resourceBundleString || resourceBundleString.length() == 0) {
- return true;
- }
-
- if (null == resourceBundles) {
- return false;
- }
-
- for (int i = 0; i < resourceBundles.size(); i++) {
- MessageBundleType node = (MessageBundleType) resourceBundles.get(i);
- String rbName = node.getTextContent();
- if (rbName != null && rbName.equalsIgnoreCase(resourceBundleString)) {
- return true;
- }
- }
-
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleViewerSorter.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleViewerSorter.java
deleted file mode 100644
index 18a81296b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/MessageBundleViewerSorter.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import java.text.Collator;
-
-import org.eclipse.jdt.core.IPackageFragmentRoot;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-
-/**
- * @author sfshi
- * @version
- */
-public class MessageBundleViewerSorter extends ViewerSorter {
-
- /**
- *
- */
- public MessageBundleViewerSorter() {
- super();
- }
-
- /**
- * @param collator
- */
- public MessageBundleViewerSorter(Collator collator) {
- super(collator);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ViewerSorter#category(java.lang.Object)
- */
- public int category(Object element) {
- if (element instanceof IPackageFragmentRoot
- && !((IPackageFragmentRoot)element).isArchive()) {
- IPackageFragmentRoot root = (IPackageFragmentRoot) element;
- if (IFileFolderConstants.FOLDER_SOURCE
- .equals(root.getElementName())) {
- return 0;
- }
- return 1;
- }
-
- return 2;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/StatusDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/StatusDialog.java
deleted file mode 100644
index 22485d9c0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/dialog/StatusDialog.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.dialog;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.resource.JFaceResources;
-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.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-
-/**
- * A common Dialog with validation information.
- */
-public abstract class StatusDialog extends Dialog {
- /** The validation image */
- private Label statusImage;
-
- /** The validation message */
- private Label statusLabel;
-
- /** The validation message content */
- private String statusMessage;
-
- /**
- *
- * @param parentShell
- */
- protected StatusDialog(Shell parentShell) {
- super(parentShell);
- }
-
- /**
- * Creates and returns the contents of the upper part of this dialog (above
- * the validation widgets). User should create Layout for the parent parameter.
- *
- * @param parent
- * the parent composite to contain the dialog area
- * @return the dialog area control
- */
- protected abstract Control createDialogContents(Composite parent);
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets.Composite)
- */
- protected Control createDialogArea(Composite parent) {
- Composite area = (Composite) super.createDialogArea(parent);
- area.setLayout(new GridLayout(2,false));
-
- Composite contents = new Composite(area, SWT.NONE);
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 2;
- contents.setLayoutData(gd);
- createDialogContents(contents);
-
- statusImage = createLabel(area);
- statusImage.setImage(JFaceResources
- .getImage(Dialog.DLG_IMG_MESSAGE_ERROR));
- statusLabel = createLabel(area);
- statusImage.setVisible(false);
- return area;
- }
-
- private Label createLabel(Composite parent) {
- Label label = new Label(parent, SWT.LEFT);
- GridData data = new GridData();
- data.horizontalSpan = 1;
- data.horizontalAlignment = GridData.FILL;
- label.setLayoutData(data);
- return label;
- }
-
- /**
- * @return true if is status is valid
- */
- protected abstract boolean isValid();
-
- /**
- * update the status information
- */
- protected void updateStatus() {
- if (isValid()) {
- statusImage.setVisible(false);
- statusLabel.setText(""); //$NON-NLS-1$
- getButton(IDialogConstants.OK_ID).setEnabled(true);
- } else {
- statusImage.setVisible(true);
- statusLabel.setText(statusMessage == null ? "" : statusMessage);//$NON-NLS-1$
- getButton(IDialogConstants.OK_ID).setEnabled(false);
- }
- }
-
- /**
- * @return the current status message
- */
- public String getStatusMessage() {
- return statusMessage;
- }
-
- /**
- * @param statusMessage
- */
- public void setStatusMessage(String statusMessage) {
- this.statusMessage = statusMessage;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ComponentsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ComponentsPage.java
deleted file mode 100644
index 7fb266e8c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ComponentsPage.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.facesconfig.emf.AttributeType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacetType;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyType;
-import org.eclipse.jst.jsf.facesconfig.emf.RendererType;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.ComponentDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.ConverterDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.RenderkitDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.ValidatorDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ComponentMasterSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ConverterMasterSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.FacesConfigMasterSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.RenderkitMasterSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ValidatorMasterSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.views.contentoutline.ContentOutlinePage;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * The "Components" page of faces config editor.
- *
- * @author sfshi
- *
- */
-public class ComponentsPage extends FacesConfigMasterDetailPage {
-
- /**
- * The id of this page in the faces-config editor.
- */
- public static final String PAGE_ID = "org.eclipse.jst.jsf.facesconfig.ui.page.ComponentsPage"; //$NON-NLS-1$
-
- private IContentOutlinePage contentOutlinePage;
-
- /**
- * Constructor of ComponentsPage;
- *
- * @param editor
- * the facesconfig editor;
- */
- public ComponentsPage(FacesConfigEditor editor) {
- super(editor, "ComponentsPage", //$NON-NLS-1$
- EditorMessages.FacesConfigEditor_Components_TabName);
- }
-
- /**
- * Create the master sections;
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage#createMasterSections(Composite,
- * IManagedForm, FormToolkit, FacesConfigMasterDetailPage)
- */
- protected FacesConfigMasterSection[] createMasterSections(
- Composite composite, IManagedForm managedForm, FormToolkit toolkit,
- FacesConfigMasterDetailPage page) {
- FacesConfigMasterSection componentMaster = new ComponentMasterSection(
- composite, managedForm, toolkit, page);
- componentMaster.getSection().setExpanded(true);
- GridData gd = new GridData(GridData.FILL_BOTH);
- componentMaster.getSection().setLayoutData(gd);
-
- FacesConfigMasterSection converterMaster = new ConverterMasterSection(
- composite, managedForm, toolkit, page);
- converterMaster.getSection().setExpanded(false);
- GridData convertergd = new GridData(GridData.FILL_HORIZONTAL);
- converterMaster.getSection().setLayoutData(convertergd);
-
- FacesConfigMasterSection renderkitMaster = new RenderkitMasterSection(
- composite, managedForm, toolkit, page);
- renderkitMaster.getSection().setExpanded(false);
- GridData renderkitgd = new GridData(GridData.FILL_HORIZONTAL);
- renderkitMaster.getSection().setLayoutData(renderkitgd);
-
- FacesConfigMasterSection validatorMaster = new ValidatorMasterSection(
- composite, managedForm, toolkit, page);
- validatorMaster.getSection().setExpanded(false);
- GridData valicatorgd = new GridData(GridData.FILL_HORIZONTAL);
- validatorMaster.getSection().setLayoutData(valicatorgd);
-
- return new FacesConfigMasterSection[] { componentMaster,
- converterMaster, renderkitMaster, validatorMaster };
- }
-
- /**
- * get the details page;
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage#getPageKey(Object
- * object)
- * @param key
- * the eClass object of a component.
- */
- public IDetailsPage getPage(Object key) {
- IDetailsPage detailsPage = null;
- if (key instanceof EClass) {
- EClass eClass = (EClass) key;
- if (eClass.getClassifierID() == FacesConfigPackage.COMPONENT_TYPE) {
- detailsPage = new ComponentDetailsPage(this);
- } else if (eClass.getClassifierID() == FacesConfigPackage.RENDER_KIT_TYPE) {
- detailsPage = new RenderkitDetailsPage(this);
- } else if (eClass.getClassifierID() == FacesConfigPackage.CONVERTER_TYPE) {
- detailsPage = new ConverterDetailsPage(this);
- } else if (eClass.getClassifierID() == FacesConfigPackage.VALIDATOR_TYPE) {
- detailsPage = new ValidatorDetailsPage(this);
- }
-
- if (detailsPage instanceof ISelectionProvider) {
- ((ISelectionProvider) detailsPage)
- .addSelectionChangedListener(this);
- }
- }
- return detailsPage;
- }
-
- public Object getAdapter(Class adapter) {
-
- if (adapter == IContentOutlinePage.class) {
- return getOutlinePage();
- }
-
- return super.getAdapter(adapter);
- }
-
- private IContentOutlinePage getOutlinePage() {
-
- if (contentOutlinePage == null) {
- // The content outline is just a tree.
- //
- class ComponentsContentOutlinePage extends ContentOutlinePage {
- public void createControl(Composite parent) {
- super.createControl(parent);
- TreeViewer contentOutlineViewer = getTreeViewer();
- contentOutlineViewer.addSelectionChangedListener(this);
-
- AdapterFactory adapterFactory = (AdapterFactory) getEditor()
- .getAdapter(AdapterFactory.class);
- // Set up the tree viewer.
- contentOutlineViewer
- .setContentProvider(new AdapterFactoryContentProvider(
- adapterFactory));
- contentOutlineViewer
- .setLabelProvider(new AdapterFactoryLabelProvider(
- adapterFactory));
- contentOutlineViewer.addFilter(new ViewerFilter() {
-
- public boolean select(Viewer viewer,
- Object parentElement, Object element) {
- return FacesConfigPackage.eINSTANCE
- .getComponentType().isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getConverterType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getRenderKitType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getValidatorType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getAttributeType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getPropertyType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getFacetType().isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getRendererType().isInstance(
- element);
- }
- });
-
- contentOutlineViewer.setSorter(new ViewerSorter());
- contentOutlineViewer.setInput(getInput());
- }
-
- }
-
- contentOutlinePage = new ComponentsContentOutlinePage();
-
- // Listen to selection so that we can handle it is a special
- // way.
- //
- contentOutlinePage
- .addSelectionChangedListener(new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- public void selectionChanged(SelectionChangedEvent event) {
- setSelection(event.getSelection());
- }
- });
-
- addSelectionChangedListener((ContentOutlinePage) contentOutlinePage);
- }
-
- return contentOutlinePage;
-
- }
-
- /**
- * handle the selection changed event from outline page.
- *
- * @param selection
- */
- public void setSelection(ISelection selection) {
-
- if (selection instanceof IStructuredSelection) {
- IStructuredSelection ss = (IStructuredSelection) selection;
- IStructuredSelection currentSelection = (IStructuredSelection) this
- .getSelection();
- if ((!ss.isEmpty())
- && (!currentSelection.isEmpty())
- && (ss.getFirstElement() == currentSelection
- .getFirstElement())) {
- return;
- }
- EObject component = null;
- if (ss.getFirstElement() instanceof AttributeType
- || ss.getFirstElement() instanceof PropertyType
- || ss.getFirstElement() instanceof FacetType
- || ss.getFirstElement() instanceof RendererType) {
- component = ((EObject) ss.getFirstElement()).eContainer();
- } else if (ss.getFirstElement() instanceof EObject) {
- component = (EObject) ss.getFirstElement();
- }
-
- if (component != null) {
- FacesConfigMasterSection section = null;
- if (FacesConfigPackage.eINSTANCE.getComponentType().isInstance(
- component)) {
- section = getFacesConfigMasterSections()[0];
- } else if (FacesConfigPackage.eINSTANCE.getConverterType()
- .isInstance(component)) {
- section = getFacesConfigMasterSections()[1];
- } else if (FacesConfigPackage.eINSTANCE.getRenderKitType()
- .isInstance(component)) {
- section = getFacesConfigMasterSections()[2];
- } else if (FacesConfigPackage.eINSTANCE.getValidatorType()
- .isInstance(component)) {
- section = getFacesConfigMasterSections()[3];
- }
-
- if (!section.getSection().isExpanded()) {
- this.closeOtherSections(section);
- GridData gd = new GridData(GridData.FILL_BOTH);
- section.getSection().setLayoutData(gd);
- section.getSection().setExpanded(true);
- }
- IStructuredSelection newselection = new StructuredSelection(
- component);
- section.getStructuredViewer().setSelection(newselection);
- }
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/FacesConfigMasterDetailPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/FacesConfigMasterDetailPage.java
deleted file mode 100644
index c9ff0ee13..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/FacesConfigMasterDetailPage.java
+++ /dev/null
@@ -1,396 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.domain.IEditingDomainProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.FacesConfigDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.FacesConfigMasterSection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.SashForm;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.forms.DetailsPart;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IDetailsPageProvider;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-
-/**
- * In some cases the page is a master-detail style, the content of the right
- * side will change according user's selection on the left side. This is an
- * abstract implementation of IFacesConfigPage, with a FacesConfigMasterSection
- * array and a DetailsPart.
- *
- * @author sfshi
- *
- */
-public abstract class FacesConfigMasterDetailPage extends FormPage implements
- IFacesConfigPage, IDetailsPageProvider, ISelectionChangedListener,
- ISelectionProvider, IEditingDomainProvider {
-
- private static final String BANNER_IMAGE_FILE = "form_banner.gif"; //$NON-NLS-1$
-
- private final static Image BANNER_IMAGE = EditorPlugin.getDefault()
- .getImage(BANNER_IMAGE_FILE);
-
- private FacesConfigMasterSection[] facesConfigMasterSections;
-
- private DetailsPart detailsPart;
-
- private Object input;
-
- private List selectionChangedListeners = new ArrayList();
-
- private IPropertySheetPage propertySheetPage;
-
- private ISelection currentSelection = null;
-
- /**
- *
- * @param editor
- * the editor part that this page belongs to;
- * @param id
- * page id;
- * @param title
- * page title;
- */
- public FacesConfigMasterDetailPage(FacesConfigEditor editor, String id,
- String title) {
- super(editor, id, title);
- }
-
- public void dispose() {
- for(int i=0; i < facesConfigMasterSections.length;i++) {
- FacesConfigMasterSection master = facesConfigMasterSections[i];
- if (master != null)
- master.dispose();
- }
-
- selectionChangedListeners.clear();
-
- super.dispose();
- }
- public EditingDomain getEditingDomain() {
- return ((FacesConfigEditor) getEditor()).getEditingDomain();
- }
-
- /**
- *
- * @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm)
- */
- protected void createFormContent(IManagedForm managedForm) {
-
- ScrolledForm form = managedForm.getForm();
- form.setText(this.getTitle());
- form.setBackgroundImage(BANNER_IMAGE);
- fillBody(managedForm, managedForm.getToolkit());
- managedForm.refresh();
- }
-
- /**
- * set input for this page when the it got activated at the first time; if
- * it's not the first time, then refresh the page.
- *
- * @see org.eclipse.ui.forms.editor.FormPage#setActive(boolean)
- */
- public void setActive(boolean active) {
- super.setActive(active);
- if (active) {
- if (getInput() != ((FacesConfigEditor) getEditor())
- .getFacesConfig()) {
- setInput(((FacesConfigEditor) getEditor()).getFacesConfig());
- } else {
- this.refresh();
- }
- }
- }
-
- public boolean isEditor() {
- return true;
- }
-
- /**
- *
- * @param managedForm
- * @param toolkit
- */
- private void fillBody(IManagedForm managedForm, FormToolkit toolkit) {
- Composite body = managedForm.getForm().getBody();
-
- GridLayout gridLayout = new GridLayout();
- gridLayout.horizontalSpacing = 0;
- gridLayout.verticalSpacing = 0;
- gridLayout.numColumns = 2;
- gridLayout.marginHeight = 0;
- gridLayout.marginWidth = 0;
- body.setLayout(gridLayout);
-
- SashForm sashForm = new SashForm(body, SWT.NULL);
- managedForm.getToolkit().adapt(sashForm, false, false);
- sashForm.setMenu(body.getMenu());
- sashForm.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- Composite leftContainer = toolkit.createComposite(sashForm);
- GridLayout gl = new GridLayout();
- gl.marginHeight = 0;
- leftContainer.setLayout(gl);
-
- // create master sections here
- facesConfigMasterSections = createMasterSections(leftContainer,
- managedForm, toolkit, this);
-
- if (facesConfigMasterSections != null) {
- for (int i = 0, n = facesConfigMasterSections.length; i < n; i++) {
- FacesConfigMasterSection aSection = facesConfigMasterSections[i];
- aSection.initialize();
- aSection.addSelectionChangedListener(this);
-
- }
- }
-
- detailsPart = new DetailsPart(managedForm, sashForm, SWT.NULL);
- managedForm.addPart(detailsPart);
-
- detailsPart.setPageLimit(4);
- detailsPart.setPageProvider(this);
-
- detailsPart.initialize(managedForm);
-
- sashForm.setWeights(new int[] { 40, 60 });
-
- getSite().setSelectionProvider(this);
- }
-
- /**
- * Create the detail sections, and set layout data and initial expand state
- * for them.
- *
- * @param composite
- * @param managedForm
- * @param toolkit
- * @param page
- * @return the detail sections
- */
- abstract protected FacesConfigMasterSection[] createMasterSections(
- Composite composite, IManagedForm managedForm, FormToolkit toolkit,
- FacesConfigMasterDetailPage page);
-
- /**
- * set input object; also set into all the master sections.
- */
- public void setInput(Object input) {
- if (facesConfigMasterSections != null) {
- for (int i = 0, n = facesConfigMasterSections.length; i < n; i++) {
- facesConfigMasterSections[i].setInput(input);
- }
- }
- this.input = input;
- }
-
- /**
- * get the input object.
- */
- public Object getInput() {
- return input;
- }
-
- /**
- * Defaultly use the EClass object of the selected object as page key. Sub
- * classes can override this method if there has other ways.
- *
- * @param object
- */
- public Object getPageKey(Object object) {
- if (object instanceof EObject) {
- EObject eObject = (EObject) object;
- return eObject.eClass();
- }
- return null;
- }
-
- /**
- * Subclasses should create and return an IDetailsPage instance according
- * what the key is. Defaultly the EClass object of the selected object in
- * the structured viewer will be taken as the page key.
- *
- * @see #getPageKey
- *
- */
- abstract public IDetailsPage getPage(Object key);
-
- /**
- * transfer the selection changed event to detail part.
- */
- public void selectionChanged(SelectionChangedEvent event) {
-
- currentSelection = event.getSelection();
- if (event.getSource() instanceof FacesConfigMasterSection) {
- FacesConfigMasterSection source = (FacesConfigMasterSection) event
- .getSource();
-
- detailsPart.selectionChanged(source, event.getSelection());
-
- if (source.getSection().isExpanded()) {
- for (int i = 0, n = selectionChangedListeners.size(); i < n; i++) {
- ((ISelectionChangedListener) selectionChangedListeners
- .get(i)).selectionChanged(event);
- }
- }
- } else if (event.getSource() instanceof FacesConfigDetailsPage) {
- for (int i = 0, n = selectionChangedListeners.size(); i < n; i++) {
- ((ISelectionChangedListener) selectionChangedListeners.get(i))
- .selectionChanged(event);
- }
- }
- }
-
- /**
- * set other sections' expand state to false, except this section;
- *
- * @param section
- * the section that be expanded.
- */
- public void closeOtherSections(FacesConfigMasterSection section) {
-
- for (int i = 0, n = facesConfigMasterSections.length; i < n; i++) {
- FacesConfigMasterSection aSection = facesConfigMasterSections[i];
- if (aSection != section && aSection.getSection().isExpanded()) {
- aSection.getSection().setExpanded(false);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- aSection.getSection().setLayoutData(gd);
- }
- }
- }
-
- /**
- * refresh this page, the expanded section and the detail page will got
- * refreshed.
- */
- public void refresh() {
-
- // only refresh the expanded section;
- for (int i = 0, n = facesConfigMasterSections.length; i < n; i++) {
- if (facesConfigMasterSections[i].getSection().isExpanded()) {
- facesConfigMasterSections[i].refresh();
- }
- }
-
- // refresh the detail page, it will call detail sections
- // to got refreshed.
- if (detailsPart.getCurrentPage() != null) {
- detailsPart.getCurrentPage().refresh();
- }
- }
-
- /**
- * get the section that is expanded.
- *
- * @return the master section
- */
- protected FacesConfigMasterSection getActiveSection() {
- for (int i = 0, n = facesConfigMasterSections.length; i < n; i++) {
-
- if (facesConfigMasterSections[i].getSection().isExpanded()) {
- return facesConfigMasterSections[i];
- }
- }
- return null;
-
- }
-
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- public ISelection getSelection() {
- if(currentSelection != null)
- return currentSelection;
- return StructuredSelection.EMPTY;
-
- }
-
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- public void setSelection(ISelection selection) {
- // no selection setting
- }
-
- public Object getAdapter(Class adapter) {
-
- if (adapter == IPropertySheetPage.class) {
- return getPropertySheetPage();
- }
- return super.getAdapter(adapter);
- }
-
- private IPropertySheetPage getPropertySheetPage() {
-
- AdapterFactoryEditingDomain editingDomain = (AdapterFactoryEditingDomain) getEditor()
- .getAdapter(EditingDomain.class);
- AdapterFactory adapterFactory = (AdapterFactory) getEditor()
- .getAdapter(AdapterFactory.class);
- if (propertySheetPage == null) {
- propertySheetPage = new ExtendedPropertySheetPage(editingDomain) {
- public void setSelectionToViewer(List selection) {
- // FacesConfigEditor.this.setSelectionToViewer(selection);
- // FacesConfigEditor.this.setFocus();
- }
-
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- // getActionBarContributor().shareGlobalActions(this,
- // actionBars);
- }
- };
- ((ExtendedPropertySheetPage) propertySheetPage)
- .setPropertySourceProvider(new AdapterFactoryContentProvider(
- adapterFactory));
- // this.addSelectionChangedListener((ExtendedPropertySheetPage)
- // propertySheetPage);
- }
-
- return propertySheetPage;
-
- }
-
- /**
- * @return the facesConfigMasterSections
- */
- public FacesConfigMasterSection[] getFacesConfigMasterSections() {
- return facesConfigMasterSections;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IFacesConfigPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IFacesConfigPage.java
deleted file mode 100644
index 42afa4ff8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IFacesConfigPage.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.ui.forms.editor.IFormPage;
-
-/**
- * Implemented by IFormPage's that want to support EditorInput-like
- * model set/get/refresh
- *
- * @author sfshi
- *
- */
-public interface IFacesConfigPage extends IFormPage {
-
- /**
- * Set the input. Implementer may choose to ignore
- *
- * @param input
- */
- void setInput(Object input);
-
- /**
- * @return the input or null if none set
- */
- Object getInput();
-
- /**
- * signal to a form page that the data in its input has changed
- * and it should refresh its view.
- */
- void refresh();
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IntroductionPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IntroductionPage.java
deleted file mode 100644
index f3e1354d7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/IntroductionPage.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.util.IPropertyChangeListener;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.IntroductionSection;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-
-/**
- * Handle the Introduction page for the pageflow editor.
- *
- * @author jchoi
- */
-public class IntroductionPage extends FormPage implements IFacesConfigPage, ISelectionProvider, IPropertyChangeListener{
-
- private static final String FORM_BANNER_IMAGE_FILE = "form_banner.gif"; //$NON-NLS-1$
-
- private Button noIntroPageButton = null;
-
- /**
- * @param facesConfigEditor
- */
- public IntroductionPage(FacesConfigEditor facesConfigEditor) {
- super(facesConfigEditor, IntroductionPage.class.getName(),
- EditorMessages.editor_pageflow_page_intro_name);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm)
- */
- protected void createFormContent(IManagedForm managedForm) {
- // get the form
- ScrolledForm form = managedForm.getForm();
- FormToolkit toolkit = getEditor().getToolkit();
- form.setText(EditorMessages.editor_pageflow_page_intro_title);
-
- form.setBackgroundImage(EditorPlugin.getDefault().getImage(FORM_BANNER_IMAGE_FILE));
-
- // create a layout
- TableWrapLayout layout = new TableWrapLayout();
- layout.numColumns = 1;
- layout.makeColumnsEqualWidth = true;
- layout.verticalSpacing = 20;
- form.getBody().setLayout(layout);
-
- IntroductionSection introPart = new IntroductionSection(
- FacesConfigEditor.EDITOR_ID, managedForm, toolkit,
- EditorMessages.editor_pageflow_page_intro_help_HelpContextID,
- EditorMessages.editor_pageflow_page_intro_help_HelpToolTip);
-
- noIntroPageButton = toolkit.createButton(form.getBody(), EditorMessages.editor_pageflow_page_intro_NoIntroPage, SWT.CHECK);
- noIntroPageButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- boolean selection = ((Button) e.widget).getSelection();
- EditorPlugin.getDefault().getPreferenceStore().setValue(GEMPreferences.SHOW_INTRO_EDITOR, !selection);
- }
- });
- TableWrapData td = new TableWrapData(TableWrapData.FILL_GRAB);
- td.colspan = 1;
- introPart.setLayoutData(td);
-
- getSite().setSelectionProvider(this);
-
- IPreferenceStore preferenceStore = EditorPlugin.getDefault().getPreferenceStore();
- preferenceStore.addPropertyChangeListener(this);
- updatePrefenceControls(preferenceStore);
- }
-
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- // TODO Auto-generated method stub
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.forms.editor.IFormPage#isEditor()
- */
- public boolean isEditor() {
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return StructuredSelection.EMPTY;
- }
-
- public void removeSelectionChangedListener(ISelectionChangedListener listener) {
- // TODO Auto-generated method stub
-
- }
-
- public void setSelection(ISelection selection) {
- // TODO Auto-generated method stub
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage#getInput()
- */
- public Object getInput() {
- // TODO Auto-generated method stub
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage#refresh()
- */
- public void refresh() {
- // TODO Auto-generated method stub
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage#setInput(java.lang.Object)
- */
- public void setInput(Object input) {
- // TODO Auto-generated method stub
-
- }
-
- public void propertyChange(PropertyChangeEvent event) {
- if (event != null) {
- String property = event.getProperty();
- if (property == null || property.equals(GEMPreferences.SHOW_INTRO_EDITOR)) {
- //assume that we are in an ui thread, as other listeners assume this too:
- updatePrefenceControls(EditorPlugin.getDefault().getPreferenceStore());
- }
- }
- }
-
- private void updatePrefenceControls(IPreferenceStore preferenceStore) {
- boolean noIntroPage = !GEMPreferences.getShowIntroEditor();
- noIntroPageButton.setSelection(noIntroPage);
- }
-
- public void dispose() {
- EditorPlugin.getDefault().getPreferenceStore().removePropertyChangeListener(this);
- super.dispose();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ManagedBeanPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ManagedBeanPage.java
deleted file mode 100644
index ad6ef9adc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/ManagedBeanPage.java
+++ /dev/null
@@ -1,205 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedPropertyType;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.detail.ManagedBeanDetailsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.FacesConfigMasterSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ManagedBeanMasterSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.views.contentoutline.ContentOutlinePage;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ManagedBeanPage extends FacesConfigMasterDetailPage {
-
- /**
- * The id of this page in the faces-config editor.
- */
- public static final String PAGE_ID = "org.eclipse.jst.jsf.facesconfig.ui.page.ManagedBeanPage"; //$NON-NLS-1$
-
- private IContentOutlinePage contentOutlinePage;
-
- /**
- * @param editor
- */
- public ManagedBeanPage(FacesConfigEditor editor) {
- super(editor, "ManagedBeanPage", //$NON-NLS-1$
- EditorMessages.FacesConfigEditor_ManagedBeans_TabName);
- }
-
- public void dispose() {
- if (contentOutlinePage != null) {
- contentOutlinePage.dispose();
- contentOutlinePage = null;
- }
- super.dispose();
- }
- protected FacesConfigMasterSection[] createMasterSections(
- Composite composite, IManagedForm managedForm, FormToolkit toolkit,
- FacesConfigMasterDetailPage page) {
- FacesConfigMasterSection managedBeanMaster = new ManagedBeanMasterSection(
- composite, managedForm, toolkit, page);
- managedBeanMaster.getSection().setExpanded(true);
- GridData gd = new GridData(GridData.FILL_BOTH);
- managedBeanMaster.getSection().setLayoutData(gd);
- return new FacesConfigMasterSection[] { managedBeanMaster };
- }
-
- public IDetailsPage getPage(Object key) {
- IDetailsPage detailsPage = null;
- if (key instanceof EClass) {
- EClass eClass = (EClass) key;
- if (eClass.getClassifierID() == FacesConfigPackage.MANAGED_BEAN_TYPE) {
- detailsPage = new ManagedBeanDetailsPage(this);
- }
-
- if (detailsPage instanceof ISelectionProvider) {
- ((ISelectionProvider) detailsPage)
- .addSelectionChangedListener(this);
- }
- }
- return detailsPage;
- }
-
- public Object getAdapter(Class adapter) {
-
- if (adapter == IContentOutlinePage.class) {
- return getOutlinePage();
- }
-
- return super.getAdapter(adapter);
- }
-
- private IContentOutlinePage getOutlinePage() {
-
- if (contentOutlinePage == null) {
- // The content outline is just a tree.
- //
- class ManagedBeanContentOutlinePage extends ContentOutlinePage {
- public void createControl(Composite parent) {
- super.createControl(parent);
- TreeViewer contentOutlineViewer = getTreeViewer();
- contentOutlineViewer.addSelectionChangedListener(this);
-
- AdapterFactory adapterFactory = (AdapterFactory) getEditor()
- .getAdapter(AdapterFactory.class);
- // Set up the tree viewer.
- contentOutlineViewer
- .setContentProvider(new AdapterFactoryContentProvider(
- adapterFactory));
- contentOutlineViewer
- .setLabelProvider(new AdapterFactoryLabelProvider(
- adapterFactory));
- contentOutlineViewer.addFilter(new ViewerFilter() {
-
- public boolean select(Viewer viewer,
- Object parentElement, Object element) {
- return FacesConfigPackage.eINSTANCE
- .getManagedBeanType().isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getManagedPropertyType()
- .isInstance(element);
- }
- });
-
- contentOutlineViewer.setSorter(new ViewerSorter());
- contentOutlineViewer.setInput(getInput());
- }
-
- }
-
- contentOutlinePage = new ManagedBeanContentOutlinePage();
-
- // Listen to selection so that we can handle it is a special
- // way.
- //
- contentOutlinePage
- .addSelectionChangedListener(new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- public void selectionChanged(SelectionChangedEvent event) {
- setSelection(event.getSelection());
- }
- });
-
- // this.addSelectionChangedListener((ContentOutlinePage)
- // contentOutlinePage);
- }
-
- return contentOutlinePage;
-
- }
-
- /**
- * handle the selection changed event from outline page.
- *
- * @param selection
- */
- public void setSelection(ISelection selection) {
-
- if (selection instanceof IStructuredSelection) {
- IStructuredSelection ss = (IStructuredSelection) selection;
- ManagedBeanType bean = null;
- if (ss.getFirstElement() instanceof ManagedBeanType) {
- bean = (ManagedBeanType) ss.getFirstElement();
- } else if (ss.getFirstElement() instanceof ManagedPropertyType) {
- bean = (ManagedBeanType) ((ManagedPropertyType) ss
- .getFirstElement()).eContainer();
- }
-
- if (bean != null) {
- if (!getManagedBeanMasterSection().getSection().isExpanded()) {
- GridData gd = new GridData(GridData.FILL_BOTH);
- getManagedBeanMasterSection().getSection()
- .setLayoutData(gd);
- getManagedBeanMasterSection().getSection()
- .setExpanded(true);
- }
- IStructuredSelection newselection = new StructuredSelection(
- bean);
- getManagedBeanMasterSection().getStructuredViewer()
- .setSelection(newselection);
- }
- }
-
- }
-
- private ManagedBeanMasterSection getManagedBeanMasterSection() {
- return (ManagedBeanMasterSection) getFacesConfigMasterSections()[0];
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OthersPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OthersPage.java
deleted file mode 100644
index 021e7b6df..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OthersPage.java
+++ /dev/null
@@ -1,836 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.domain.IEditingDomainProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.FactoryType;
-import org.eclipse.jst.jsf.facesconfig.emf.LifecycleType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ApplicationSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.FactorySection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.LifecycleSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.LocaleConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OthersPageBaseSection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.SashForm;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-import org.eclipse.ui.views.contentoutline.ContentOutlinePage;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-
-/**
- * @author Zhi-peng Zhang, sfshi
- * @version
- */
-
-/**
- * This class is the "Others" page.
- */
-public class OthersPage extends FormPage implements IFacesConfigPage,
- ISelectionProvider, ISelectionChangedListener, IEditingDomainProvider {
-
- private static final String BANNER_IMAGE_FILE = "form_banner.gif"; //$NON-NLS-1$
-
- /**
- * The id of this page in the faces-config editor.
- */
- public static final String PAGE_ID = "org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage"; //$NON-NLS-1$
-
- private final static Image BANNER_IMAGE = EditorPlugin.getDefault()
- .getImage(BANNER_IMAGE_FILE);
-
- private List leftSections;
-
- private List rightSections;
-
- private Object input;
-
- private List selectionChangedListeners = new ArrayList();
-
- private IPropertySheetPage propertySheetPage;
-
- private IContentOutlinePage contentOutlinePage;
-
- private ISelection currentSelection;
-
- private FacesConfigOthersAdapter _facesConfigOthersAdapter;
-
- /**
- * Constructor of OthersPage;
- *
- * @param editor
- * the facesconfig editor;
- */
- public OthersPage(FacesConfigEditor editor) {
- super(editor, "OthersPage", //$NON-NLS-1$
- EditorMessages.FacesConfigEditor_Others_TabName);
- }
-
- protected void createFormContent(IManagedForm managedForm) {
- super.createFormContent(managedForm);
- ScrolledForm form = managedForm.getForm();
- form.setText(EditorMessages.OthersPage_Title);
- form.setBackgroundImage(BANNER_IMAGE);
- fillBody(managedForm, managedForm.getToolkit());
- managedForm.refresh();
- }
-
- private void initSection(OthersPageBaseSection section, String name,
- String description, ArrayList list) {
- section.getSection().setText(name);
- section.getSection().setDescription(description);
- section.initialize();
- section.addSelectionChangedListener(this);
- section.getSection().setExpanded(false);
- section.getSection().setLayoutData(
- new GridData(GridData.FILL_HORIZONTAL));
- list.add(section);
- }
-
- public void dispose() {
- disposeFormSections(rightSections);
- disposeFormSections(leftSections);
- removeAdapterFromInput(getInput());
- getSite().setSelectionProvider(null);
- super.dispose();
- }
-
- private void disposeFormSections(List sections) {
- for (int i=0; i < sections.size();i++) {
- OthersPageBaseSection section = (OthersPageBaseSection) sections.get(i);
- section.removeSelectionChangedListener(this);
- section.dispose();
- }
- }
-
- private void fillBody(IManagedForm managedForm, FormToolkit toolkit) {
- Composite body = managedForm.getForm().getBody();
-
- body.setLayout(new GridLayout());
-
- SashForm sashForm = new SashForm(body, SWT.NONE);
- managedForm.getToolkit().adapt(sashForm, false, false);
- sashForm.setMenu(body.getMenu());
- sashForm.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- Composite leftContainer = toolkit.createComposite(sashForm);
- leftContainer.setLayout(new GridLayout());
-
- ArrayList sectionList = new ArrayList();
-
- OthersPageBaseSection section = new ApplicationSection(
- FacesConfigPackage.eINSTANCE.getActionListenerType(),
- leftContainer, managedForm, this, toolkit);
- initSection(section, EditorMessages.ActionListenerSection_Name,
- EditorMessages.ActionListenerSection_Description,
- sectionList);
- section.getSection().setLayoutData(new GridData(GridData.FILL_BOTH));
- section.getSection().setExpanded(true);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getDefaultRenderKitIdType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.DefaultRenderKitIDSection_Name,
- EditorMessages.DefaultRenderKitIDSection_Description,
- sectionList);
-
- section = new LocaleConfigSection(FacesConfigPackage.eINSTANCE
- .getSupportedLocaleType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section, EditorMessages.LocaleConfigSection_Name,
- EditorMessages.LocaleConfigSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getMessageBundleType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section, EditorMessages.MessageBundleSection_Name,
- EditorMessages.MessageBundleSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getNavigationHandlerType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.NavigationHandlerSection_Name,
- EditorMessages.NavigationHandlerSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getPropertyResolverType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.PropertyResolverSection_Name,
- EditorMessages.PropertyResolverSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getStateManagerType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section, EditorMessages.StateManagerSection_Name,
- EditorMessages.StateManagerSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getVariableResolverType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.VariableResolverSection_Name,
- EditorMessages.VariableResolverSection_Description,
- sectionList);
-
- section = new ApplicationSection(FacesConfigPackage.eINSTANCE
- .getViewHandlerType(), leftContainer, managedForm, this,
- toolkit);
- initSection(section, EditorMessages.ViewHandlerSection_Name,
- EditorMessages.ViewHandlerSection_Description,
- sectionList);
-
- leftSections = sectionList;
-
- sectionList = new ArrayList();
-
- Composite rightContainer = toolkit.createComposite(sashForm);
- rightContainer.setLayout(new GridLayout());
- rightContainer.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- section = new FactorySection(FacesConfigPackage.eINSTANCE
- .getApplicationFactoryType(), rightContainer, managedForm,
- this, toolkit);
- initSection(section,
- EditorMessages.ApplicationFactorySection_Name,
- EditorMessages.ApplicationFactorySection_Description,
- sectionList);
- section.getSection().setLayoutData(new GridData(GridData.FILL_BOTH));
- section.getSection().setExpanded(true);
-
- section = new FactorySection(FacesConfigPackage.eINSTANCE
- .getFacesContextFactoryType(), rightContainer, managedForm,
- this, toolkit);
- initSection(section,
- EditorMessages.FacesContextFactorySection_Name,
- EditorMessages.FacesContextFactorySection_Description,
- sectionList);
-
- section = new FactorySection(FacesConfigPackage.eINSTANCE
- .getLifecycleFactoryType(), rightContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.LifecycleFactorySection_Name,
- EditorMessages.LifecycleFactorySection_Description,
- sectionList);
-
- section = new FactorySection(FacesConfigPackage.eINSTANCE
- .getRenderKitFactoryType(), rightContainer, managedForm, this,
- toolkit);
- initSection(section,
- EditorMessages.RenderKitFactorySection_Name,
- EditorMessages.RenderKitFactorySection_Description,
- sectionList);
-
- section = new LifecycleSection(FacesConfigPackage.eINSTANCE
- .getPhaseListenerType(), rightContainer, managedForm, this,
- toolkit);
- initSection(section, EditorMessages.PhaseListenerSection_Name,
- EditorMessages.PhaseListenerSection_Description,
- sectionList);
-
- rightSections = sectionList;
-
- getSite().setSelectionProvider(this);
- }
-
- /**
- * set input for this page when the it got activated at the first time; if
- * it's not the first time, then refresh the page.
- *
- * @see org.eclipse.ui.forms.editor.FormPage#setActive(boolean)
- */
- public void setActive(boolean active) {
- super.setActive(active);
- if (active) {
- if (getInput() != ((FacesConfigEditor) getEditor())
- .getFacesConfig()) {
- setInput(((FacesConfigEditor) getEditor()).getFacesConfig());
- } else {
- this.refresh();
- }
- }
- }
-
- /**
- *
- */
- public void setInput(Object input) {
- if (input instanceof FacesConfigType) {
- this.input = input;
- FacesConfigType facesConfig = (FacesConfigType) input;
- facesConfig.eAdapters().add(getFacesConfigAdapter());
- setInputForApplicationSections(facesConfig);
- setInputForFactorySections(facesConfig);
- setInputForLifecycleSections(facesConfig);
- }
- }
-
- private void removeAdapterFromInput(Object input_) {
- if (_facesConfigOthersAdapter != null && input_ != null && input_ instanceof FacesConfigType) {
- ((FacesConfigType)input_).eAdapters().remove(_facesConfigOthersAdapter);
- }
- }
-
- private Adapter getFacesConfigAdapter() {
- if (_facesConfigOthersAdapter == null) {
- _facesConfigOthersAdapter = new FacesConfigOthersAdapter();
- }
- return _facesConfigOthersAdapter;
- }
-
- public boolean isEditor() {
- return true;
- }
-
- /**
- * Reset the editor input for the application section
- */
- public void resetApplicationInput() {
- if (getInput() instanceof FacesConfigType) {
- setInputForApplicationSections((FacesConfigType) getInput());
- }
- }
-
- /**
- * Reset the editor input for the factory sections
- */
- public void resetFactoryInput() {
- if (getInput() instanceof FacesConfigType) {
- setInputForFactorySections((FacesConfigType) getInput());
- }
- }
-
- /**
- * Reset the editor input for the lifecycle section
- */
- public void resetLifecycleInput() {
- if (getInput() instanceof FacesConfigType) {
- setInputForLifecycleSections((FacesConfigType) getInput());
- }
- }
-
- /**
- * Sets the model for all Application sub-model elements to facesConfig
- * @param facesConfig
- */
- protected void setInputForApplicationSections(FacesConfigType facesConfig) {
- ApplicationType application;
- if (facesConfig.getApplication().size() > 0) {
- application = (ApplicationType) facesConfig.getApplication().get(0);
- } else {
- application = null;
- }
- for (Iterator it = leftSections.iterator(); it.hasNext();) {
- ApplicationSection section = (ApplicationSection) it.next();
- section.setInput(application);
- }
- }
-
- /**
- * Sets the model for all Factory sub-model elements to facesConfig
- * @param facesConfig
- */
- protected void setInputForFactorySections(FacesConfigType facesConfig) {
- FactoryType factory;
- if (facesConfig.getFactory().size() > 0) {
- factory = (FactoryType) facesConfig.getFactory().get(0);
- } else {
- factory = null;
- }
-
- for (Iterator it = rightSections.iterator(); it.hasNext();) {
- Object section = it.next();
- if (section instanceof FactorySection)
- ((FactorySection) section).setInput(factory);
- }
- }
-
- /**
- * Sets the model for all Lifecycle sub-model elements to facesConfig
- * @param facesConfig
- */
- protected void setInputForLifecycleSections(FacesConfigType facesConfig) {
- LifecycleType lifecycle;
- if (facesConfig.getLifecycle().size() > 0) {
- lifecycle = (LifecycleType) facesConfig.getLifecycle().get(0);
-
- } else {
- lifecycle = null;
- }
- for (Iterator it = rightSections.iterator(); it.hasNext();) {
- Object section = it.next();
- if (section instanceof LifecycleSection)
- ((LifecycleSection) section).setInput(lifecycle);
- }
- }
-
- public Object getInput() {
- return input;
- }
-
- public void refresh() {
-
- // only refresh the expanded section;
- for (int i = 0, n = leftSections.size(); i < n; i++) {
- OthersPageBaseSection section = (OthersPageBaseSection) leftSections
- .get(i);
- if (section.getSection().isExpanded()) {
- section.refresh();
- }
- }
-
- for (int i = 0, n = rightSections.size(); i < n; i++) {
- OthersPageBaseSection section = (OthersPageBaseSection) leftSections
- .get(i);
- if (section.getSection().isExpanded()) {
- section.refresh();
- }
- }
-
- }
-
- /**
- * set other sections' expand state to false, except this section;
- *
- * @param section
- * the section that be expanded.
- */
- public void closeOtherSections(AbstractFacesConfigSection section) {
- OthersPageBaseSection[] sections;
- if (leftSections.contains(section)) {
- sections = (OthersPageBaseSection[]) leftSections
- .toArray(new OthersPageBaseSection[leftSections.size()]);
- } else {
- sections = (OthersPageBaseSection[]) rightSections
- .toArray(new OthersPageBaseSection[rightSections.size()]);
- }
- for (int i = 0, n = sections.length; i < n; i++) {
- AbstractFacesConfigSection aSection = sections[i];
- if (aSection != section && aSection.getSection().isExpanded()) {
- aSection.getSection().setExpanded(false);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- aSection.getSection().setLayoutData(gd);
- }
- }
- }
-
- /**
- * An adapter on faces config.
- *
- * @author sfshi
- *
- */
- class FacesConfigOthersAdapter extends AdapterImpl {
- public void notifyChanged(Notification msg) {
- if (msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.ADD) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Application()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- resetApplicationInput();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- resetApplicationInput();
- }
- });
- }
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Factory()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- resetFactoryInput();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- resetFactoryInput();
- }
- });
- }
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Lifecycle()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- resetLifecycleInput();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- resetLifecycleInput();
- }
- });
- }
- }
- }
- }
- }
-
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- // TODO Auto-generated method stub
-
- selectionChangedListeners.add(listener);
- }
-
- public ISelection getSelection() {
- if (currentSelection != null)
- return currentSelection;
-
- return StructuredSelection.EMPTY;
- }
-
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- // TODO Auto-generated method stub
-
- selectionChangedListeners.remove(listener);
- }
-
- public void selectionChanged(SelectionChangedEvent event) {
- currentSelection = event.getSelection();
- if (event.getSource() instanceof OthersPageBaseSection) {
- OthersPageBaseSection source = (OthersPageBaseSection) event
- .getSource();
-
- if (source.getSection().isExpanded()) {
- for (int i = 0, n = selectionChangedListeners.size(); i < n; i++) {
- ((ISelectionChangedListener) selectionChangedListeners
- .get(i)).selectionChanged(event);
- }
- }
- }
- }
-
- /**
- * get the section that is expanded.
- *
- * @return the page section
- */
- protected OthersPageBaseSection getActiveSection() {
- for (int i = 0, n = leftSections.size(); i < n; i++) {
-
- OthersPageBaseSection section = (OthersPageBaseSection) leftSections
- .get(i);
- if (section.getSection().isExpanded()) {
- return section;
- }
- }
-
- for (int i = 0, n = rightSections.size(); i < n; i++) {
-
- OthersPageBaseSection section = (OthersPageBaseSection) leftSections
- .get(i);
- if (section.getSection().isExpanded()) {
- return section;
- }
- }
- return null;
-
- }
-
- public Object getAdapter(Class adapter) {
-
- if (adapter == IPropertySheetPage.class) {
- return getPropertySheetPage();
- }
-
- if (adapter == IContentOutlinePage.class) {
- return getOutlinePage();
- }
-
- return super.getAdapter(adapter);
- }
-
- private IPropertySheetPage getPropertySheetPage() {
-
- AdapterFactoryEditingDomain editingDomain = (AdapterFactoryEditingDomain) getEditor()
- .getAdapter(EditingDomain.class);
- AdapterFactory adapterFactory = (AdapterFactory) getEditor()
- .getAdapter(AdapterFactory.class);
- if (propertySheetPage == null) {
- propertySheetPage = new ExtendedPropertySheetPage(editingDomain) {
- public void setSelectionToViewer(List selection) {
- // FacesConfigEditor.this.setSelectionToViewer(selection);
- // FacesConfigEditor.this.setFocus();
- }
-
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- // getActionBarContributor().shareGlobalActions(this,
- // actionBars);
- }
- };
- ((ExtendedPropertySheetPage) propertySheetPage)
- .setPropertySourceProvider(new AdapterFactoryContentProvider(
- adapterFactory));
- // this.addSelectionChangedListener((ExtendedPropertySheetPage)
- // propertySheetPage);
- }
-
- return propertySheetPage;
-
- }
-
- private IContentOutlinePage getOutlinePage() {
-
- if (contentOutlinePage == null) {
- // The content outline is just a tree.
- //
- class OthersContentOutlinePage extends ContentOutlinePage {
- public void createControl(Composite parent) {
- super.createControl(parent);
- TreeViewer contentOutlineViewer = getTreeViewer();
- contentOutlineViewer.addSelectionChangedListener(this);
-
- AdapterFactory adapterFactory = (AdapterFactory) getEditor()
- .getAdapter(AdapterFactory.class);
- // Set up the tree viewer.
- contentOutlineViewer
- .setContentProvider(new AdapterFactoryContentProvider(
- adapterFactory));
- contentOutlineViewer
- .setLabelProvider(new AdapterFactoryLabelProvider(
- adapterFactory));
- contentOutlineViewer.addFilter(new ViewerFilter() {
-
- public boolean select(Viewer viewer,
- Object parentElement, Object element) {
- return FacesConfigPackage.eINSTANCE
- .getApplicationType().isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getFactoryType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getLifecycleType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getActionListenerType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getDefaultRenderKitIdType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getLocaleConfigType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getDefaultLocaleType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getSupportedLocaleType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getMessageBundleType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getNavigationHandlerType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getPropertyResolverType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getStateManagerType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getVariableResolverType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getViewHandlerType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE
- .getApplicationFactoryType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getFacesContextFactoryType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getLifecycleFactoryType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getRenderKitFactoryType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE
- .getPhaseListenerType().isInstance(
- element)
-
- ;
- }
- });
-
- contentOutlineViewer.setSorter(new ViewerSorter());
- contentOutlineViewer.setInput(getInput());
- }
-
- }
-
- contentOutlinePage = new OthersContentOutlinePage();
-
- // Listen to selection so that we can handle it is a special
- // way.
- //
- contentOutlinePage
- .addSelectionChangedListener(new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- public void selectionChanged(SelectionChangedEvent event) {
- setSelection(event.getSelection());
- }
- });
-
- }
-
- return contentOutlinePage;
-
- }
-
- /**
- * handle the selection changed event from outline page.
- *
- * @param selection
- */
- public void setSelection(ISelection selection) {
-
- if (selection instanceof IStructuredSelection) {
- IStructuredSelection ss = (IStructuredSelection) selection;
- if (ss.isEmpty())
- return;
-
- final EObject object = (EObject) ss.getFirstElement();
- OthersPageBaseSection section = null;
-
- if (FacesConfigPackage.eINSTANCE.getActionListenerType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(0);
- } else if (FacesConfigPackage.eINSTANCE.getDefaultRenderKitIdType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(1);
- } else if (FacesConfigPackage.eINSTANCE.getLocaleConfigType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(2);
- } else if (FacesConfigPackage.eINSTANCE.getDefaultLocaleType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(2);
- } else if (FacesConfigPackage.eINSTANCE.getSupportedLocaleType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(2);
- } else if (FacesConfigPackage.eINSTANCE.getMessageBundleType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(3);
- } else if (FacesConfigPackage.eINSTANCE.getNavigationHandlerType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(4);
- } else if (FacesConfigPackage.eINSTANCE.getPropertyResolverType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(5);
- } else if (FacesConfigPackage.eINSTANCE.getStateManagerType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(6);
- } else if (FacesConfigPackage.eINSTANCE.getVariableResolverType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(7);
- } else if (FacesConfigPackage.eINSTANCE.getViewHandlerType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) leftSections.get(8);
- } else if (FacesConfigPackage.eINSTANCE.getApplicationFactoryType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) rightSections.get(0);
- } else if (FacesConfigPackage.eINSTANCE
- .getFacesContextFactoryType().isInstance(object)) {
- section = (OthersPageBaseSection) rightSections.get(1);
- } else if (FacesConfigPackage.eINSTANCE.getLifecycleFactoryType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) rightSections.get(2);
- } else if (FacesConfigPackage.eINSTANCE.getRenderKitFactoryType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) rightSections.get(3);
- } else if (FacesConfigPackage.eINSTANCE.getPhaseListenerType()
- .isInstance(object)) {
- section = (OthersPageBaseSection) rightSections.get(4);
- }
- if (section != null) {
- if ((Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread())) {
- setSelectionInSection(section, object);
- }
- else {
- final OthersPageBaseSection baseSection = section;
- PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() {
- public void run() {
- setSelectionInSection(baseSection, object);
- }
- });
- }
- }
- }
- }
-
- private void setSelectionInSection(final OthersPageBaseSection section, final Object object) {
- if (!section.getSection().isExpanded()) {
- this.closeOtherSections(section);
- GridData gd = new GridData(GridData.FILL_BOTH);
- section.getSection().setLayoutData(gd);
- section.getSection().setExpanded(true);
- }
- IStructuredSelection newselection = new StructuredSelection(
- object);
- section.getTableViewer().setSelection(newselection);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.edit.domain.IEditingDomainProvider#getEditingDomain()
- */
- public EditingDomain getEditingDomain() {
- return ((FacesConfigEditor) getEditor()).getEditingDomain();
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OverviewPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OverviewPage.java
deleted file mode 100644
index 808a89f5b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/OverviewPage.java
+++ /dev/null
@@ -1,248 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OverviewComponentsSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OverviewGeneralSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OverviewManagedBeanSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OverviewNavigationSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.OverviewOthersSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * @author jchoi, Xiao-guang Zhang
- * @version
- */
-public class OverviewPage extends FormPage implements ISelectionProvider,
- IFacesConfigPage {
-
-
- /**
- * The id of this page in the faces-config editor.
- */
- public static final String PAGE_ID = "org.eclipse.jst.jsf.facesconfig.ui.page.OverviewPage"; //$NON-NLS-1$
-
- private static final int LAYOUT_MARGIN_HEIGHT = 2;
-
- private static final int LAYOUT_MARGIN_WIDTH = 2;
-
- private Object input;
-
- private OverviewGeneralSection generalSection;
-
- private OverviewManagedBeanSection beanSection;
-
- private OverviewComponentsSection componentsSection;
-
- //
- private OverviewNavigationSection navigationSection;
-
- //
- private OverviewOthersSection otherSection;
-
- /**
- *
- * @param editor
- */
- public OverviewPage(FormEditor editor) {
- super(editor, "OverviewPage", EditorMessages.OverviewPage_page_name); //$NON-NLS-1$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.forms.editor.FormPage#createFormContent(org.eclipse.ui.forms.IManagedForm)
- */
- protected void createFormContent(IManagedForm managedForm) {
-
- ScrolledForm form = managedForm.getForm();
- form.setText(EditorMessages.OverviewPage_PageflowOverview_summary);
- form.setBackgroundImage(EditorPlugin.getDefault().getImage(
- "form_banner.gif")); //$NON-NLS-1$
- Composite body = form.getBody();
- GridLayout gridLayout = new GridLayout();
- gridLayout.marginWidth = LAYOUT_MARGIN_WIDTH;
- gridLayout.marginHeight = LAYOUT_MARGIN_HEIGHT;
- body.setLayout(gridLayout);
- gridLayout = new GridLayout(2, true);
- form.getBody().setLayout(gridLayout);
- FormEditor editor = getEditor();
- FormToolkit toolkit = editor.getToolkit();
-
- // add overview general information
- generalSection = new OverviewGeneralSection(managedForm.getForm()
- .getBody(), managedForm, this, toolkit);
- generalSection.initialize();
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = 2;
- generalSection.getSection().setLayoutData(gd);
-
- // Navigation section
- navigationSection = new OverviewNavigationSection(managedForm.getForm()
- .getBody(), managedForm, this, toolkit);
- navigationSection.initialize();
- gd = new GridData(GridData.FILL_BOTH);
- navigationSection.getSection().setLayoutData(gd);
- navigationSection.getSection().setExpanded(true);
-
- // ManagedBeans section
- beanSection = new OverviewManagedBeanSection(managedForm.getForm()
- .getBody(), managedForm, this, toolkit);
- beanSection.initialize();
- gd = new GridData(GridData.FILL_BOTH);
- beanSection.getSection().setLayoutData(gd);
- beanSection.getSection().setExpanded(true);
-
- /* components section */
- componentsSection = new OverviewComponentsSection(managedForm.getForm()
- .getBody(), managedForm, this, toolkit);
- componentsSection.initialize();
- gd = new GridData(GridData.FILL_BOTH);
- componentsSection.getSection().setLayoutData(gd);
- componentsSection.getSection().setExpanded(true);
-
- /* other sections */
- otherSection = new OverviewOthersSection(managedForm.getForm()
- .getBody(), managedForm, this, toolkit);
- otherSection.initialize();
- gd = new GridData(GridData.FILL_BOTH);
- otherSection.getSection().setLayoutData(gd);
- otherSection.getSection().setExpanded(true);
-
- this.getSite().setSelectionProvider(this);
-
- }
-
- /**
- * set input for this page when the it got activated at the first time; if
- * it's not the first time, then refresh the page.
- *
- * @see org.eclipse.ui.forms.editor.FormPage#setActive(boolean)
- */
- public void setActive(boolean active) {
- super.setActive(active);
- if (active) {
- if (getInput() != ((FacesConfigEditor) getEditor())
- .getFacesConfig()) {
- setInput(((FacesConfigEditor) getEditor()).getFacesConfig());
- } else {
- this.refresh();
- }
- }
- }
-
- /**
- *
- */
- public void setInput(Object input) {
- if (input instanceof FacesConfigType) {
- this.input = input;
- navigationSection.setInput(input);
- beanSection.setInput(input);
- componentsSection.setInput(input);
- otherSection.setInput(input);
- }
- }
-
- /**
- * Call refreshAll on all sections on this page
- */
- public void refreshAll() {
- generalSection.refreshAll();
- navigationSection.refreshAll();
- beanSection.refreshAll();
- componentsSection.refreshAll();
- otherSection.refreshAll();
- }
-
- public Object getInput() {
- return input;
- }
-
- public void refresh() {
- generalSection.refresh();
- navigationSection.refresh();
- beanSection.refresh();
- componentsSection.refresh();
- otherSection.refresh();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.forms.editor.IFormPage#isEditor()
- */
- public boolean isEditor() {
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- // do not support change in selection
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return StructuredSelection.EMPTY;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- // do not support change in selection
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // do not support change in selection
- }
-
- public void dispose() {
- beanSection.dispose();
- componentsSection.dispose();
- generalSection.dispose();
- navigationSection.dispose();
- otherSection.dispose();
- super.dispose();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/WaitForLoadPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/WaitForLoadPage.java
deleted file mode 100644
index 1b201600f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/WaitForLoadPage.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page;
-
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.editor.FormEditor;
-import org.eclipse.ui.forms.editor.FormPage;
-import org.eclipse.ui.forms.widgets.ScrolledForm;
-
-/**
- * A page the exists only be used before the editor's model is fully loaded
- * as a status placeholder while the user waits.
- *
- * @author cbateman
- *
- */
-public class WaitForLoadPage extends FormPage
-{
-
- /**
- * @param editor the parent
- * @param id the id of the editor within its parent
- * @param title the title displayed to the user on the editor's tab
- */
- public WaitForLoadPage(FormEditor editor, String id, String title) {
- super(editor, id, title);
- }
-
- @Override
- protected void createFormContent(IManagedForm managedForm) {
- // get the form
- ScrolledForm form = managedForm.getForm();
- //FormToolkit toolkit = getEditor().getToolkit();
- form.setText(EditorMessages.FacesConfigEditor_WaitForLoadPage_Title);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ComponentDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ComponentDetailsPage.java
deleted file mode 100644
index 9a882d542..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ComponentDetailsPage.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AttributeSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ComponentGeneralSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.FacetSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.PropertySection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ComponentDetailsPage extends FacesConfigDetailsPage {
-
- /**
- *
- * @param page
- */
- public ComponentDetailsPage(FacesConfigMasterDetailPage page) {
- super(page);
- }
-
- /**
- * create the detail sections and set layout for them.
- */
- protected IFacesConfigSection[] createDetailSections(Composite composite,
- IManagedForm managedForm, FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- ComponentGeneralSection generalSection = new ComponentGeneralSection(
- composite, managedForm, getPage(), toolkit);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.getSection().setLayoutData(gd);
-
- AttributeSection attributeSection = new AttributeSection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- attributeSection.getSection().setLayoutData(gd);
-
- FacetSection facetSection = new FacetSection(composite, managedForm,
- getPage(), toolkit);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- facetSection.getSection().setLayoutData(gd);
-
- PropertySection propertySection = new PropertySection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_BOTH);
- propertySection.getSection().setLayoutData(gd);
- return new IFacesConfigSection[] { generalSection, attributeSection, facetSection,
- propertySection };
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ConverterDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ConverterDetailsPage.java
deleted file mode 100644
index 0e720f440..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ConverterDetailsPage.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AttributeSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ConverterGeneralSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.PropertySection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ConverterDetailsPage extends FacesConfigDetailsPage {
-
- /**
- *
- * @param page
- */
- public ConverterDetailsPage(FacesConfigMasterDetailPage page) {
- super(page);
- }
-
- /**
- * create the detail sections and set layout for them.
- */
- protected IFacesConfigSection[] createDetailSections(Composite composite,
- IManagedForm managedForm, FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- ConverterGeneralSection generalSection = new ConverterGeneralSection(
- composite, managedForm, getPage(), toolkit);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.getSection().setLayoutData(gd);
-
- AttributeSection attributeSection = new AttributeSection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- attributeSection.getSection().setLayoutData(gd);
-
-
- PropertySection propertySection = new PropertySection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_BOTH);
- propertySection.getSection().setLayoutData(gd);
- return new IFacesConfigSection[] { generalSection, attributeSection,
- propertySection };
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/FacesConfigDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/FacesConfigDetailsPage.java
deleted file mode 100644
index eec368ac5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/FacesConfigDetailsPage.java
+++ /dev/null
@@ -1,185 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.AbstractFormPart;
-import org.eclipse.ui.forms.IDetailsPage;
-import org.eclipse.ui.forms.IFormPart;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * The detail part of a page. It contains several IFacesConfigSection instances.
- *
- * @author sfshi
- *
- */
-public abstract class FacesConfigDetailsPage extends AbstractFormPart implements
- IDetailsPage, ISelectionProvider, ISelectionChangedListener {
-
- private FacesConfigMasterDetailPage page;
-
- private IFacesConfigSection[] detailSections;
-
- private List selectionChangedListeners = new ArrayList();
-
- /**
- * @param page
- */
- public FacesConfigDetailsPage(FacesConfigMasterDetailPage page) {
- super();
- this.page = page;
- }
-
- public void createContents(Composite parent) {
- GridLayout layout = new GridLayout();
- layout.marginWidth = 0;
- layout.marginHeight = 0;
- parent.setLayout(layout);
-
- parent.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- FormToolkit toolkit = getManagedForm().getToolkit();
- Composite detailsContainer = toolkit.createComposite(parent);
- toolkit.paintBordersFor(detailsContainer);
- detailsContainer.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- gl.marginHeight = 0;
- detailsContainer.setLayout(gl);
-
- detailSections = createDetailSections(detailsContainer,
- getManagedForm(), toolkit, page);
- if (detailSections != null) {
- for (int i = 0, n = detailSections.length; i < n; i++) {
- detailSections[i].initialize();
- if (detailSections[i] instanceof ISelectionProvider) {
- ((ISelectionProvider) detailSections[i])
- .addSelectionChangedListener(this);
- }
- }
- }
- }
-
- /**
- * create the sub detail sections and set layout data for them.
- *
- * @param composite
- * @param managedForm
- * @param toolkit
- * @param page_
- * @return the detail sections
- */
- abstract protected IFacesConfigSection[] createDetailSections(
- Composite composite, IManagedForm managedForm, FormToolkit toolkit,
- FacesConfigMasterDetailPage page_);
-
- /**
- *
- */
- public void selectionChanged(IFormPart part, ISelection selection) {
- Object selectedItem = ((StructuredSelection) selection)
- .getFirstElement();
- if (detailSections != null) {
- for (int i = 0, n = detailSections.length; i < n; i++) {
- IFacesConfigSection aSection = detailSections[i];
- aSection.setInput(selectedItem);
- }
- }
-
- }
-
- /**
- * @return the master/detail page for this page
- */
- public FacesConfigMasterDetailPage getPage() {
- return page;
- }
-
- public void refresh() {
- super.refresh();
- if (detailSections != null) {
- for (int i = 0, n = detailSections.length; i < n; i++) {
- detailSections[i].refresh();
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener.selectionChanged(new SelectionChangedEvent(this, event
- .getSelection()));
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return StructuredSelection.EMPTY;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // no selection allowed
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ManagedBeanDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ManagedBeanDetailsPage.java
deleted file mode 100644
index 9ee1641c9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ManagedBeanDetailsPage.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.InitializationSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ManagedBeanGeneralSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ManagedBeanDetailsPage extends FacesConfigDetailsPage {
-
- /**
- *
- * @param page
- */
- public ManagedBeanDetailsPage(FacesConfigMasterDetailPage page) {
- super(page);
- }
-
- /**
- * create the detail sections and set layout for them.
- */
- protected IFacesConfigSection[] createDetailSections(Composite composite,
- IManagedForm managedForm, FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- ManagedBeanGeneralSection generalSection = new ManagedBeanGeneralSection(
- composite, managedForm, getPage(), toolkit);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.getSection().setLayoutData(gd);
-
- InitializationSection initializationSection = new InitializationSection(
- composite, managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_BOTH | GridData.VERTICAL_ALIGN_FILL);
- initializationSection.getSection().setLayoutData(gd);
-
- return new IFacesConfigSection[] { generalSection, initializationSection};
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/RenderkitDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/RenderkitDetailsPage.java
deleted file mode 100644
index efb8dd7a5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/RenderkitDetailsPage.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.RendererSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.RenderkitGeneralSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class RenderkitDetailsPage extends FacesConfigDetailsPage {
-
- /**
- *
- * @param page
- */
- public RenderkitDetailsPage(FacesConfigMasterDetailPage page) {
- super(page);
- }
-
- /**
- * create the detail sections and set layout for them.
- */
- protected IFacesConfigSection[] createDetailSections(Composite composite,
- IManagedForm managedForm, FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- RenderkitGeneralSection generalSection = new RenderkitGeneralSection(
- composite, managedForm, getPage(), toolkit);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.getSection().setLayoutData(gd);
-
- RendererSection rendererSection = new RendererSection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_BOTH | GridData.VERTICAL_ALIGN_FILL);
- rendererSection.getSection().setLayoutData(gd);
-
- return new IFacesConfigSection[] { generalSection,rendererSection };
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ValidatorDetailsPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ValidatorDetailsPage.java
deleted file mode 100644
index a2385781a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/page/detail/ValidatorDetailsPage.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.page.detail;
-
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.section.AttributeSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.PropertySection;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ValidatorGeneralSection;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ValidatorDetailsPage extends FacesConfigDetailsPage {
-
- /**
- *
- * @param page
- */
- public ValidatorDetailsPage(FacesConfigMasterDetailPage page) {
- super(page);
- }
-
- /**
- * create the detail sections and set layout for them.
- */
- protected IFacesConfigSection[] createDetailSections(Composite composite,
- IManagedForm managedForm, FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- ValidatorGeneralSection generalSection = new ValidatorGeneralSection(
- composite, managedForm, getPage(), toolkit);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.getSection().setLayoutData(gd);
-
- AttributeSection attributeSection = new AttributeSection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- attributeSection.getSection().setLayoutData(gd);
-
- PropertySection propertySection = new PropertySection(composite,
- managedForm, getPage(), toolkit);
- gd = new GridData(GridData.FILL_BOTH);
- propertySection.getSection().setLayoutData(gd);
- return new IFacesConfigSection[] { generalSection, attributeSection,
- propertySection };
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/DelegatingZoomManager.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/DelegatingZoomManager.java
deleted file mode 100644
index 0a8f33570..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/DelegatingZoomManager.java
+++ /dev/null
@@ -1,374 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-// import org.eclipse.core.runtime.ListenerList;
-import org.eclipse.core.runtime.ListenerList;
-import org.eclipse.draw2d.ScalableFigure;
-import org.eclipse.draw2d.Viewport;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.editparts.ZoomListener;
-import org.eclipse.gef.editparts.ZoomManager;
-
-/**
- * A delegating ZoomManager.
- *
- */
-public class DelegatingZoomManager extends ZoomManager implements ZoomListener {
- /** Default string or double value of zoom level */
- private static final String DEFAULT_ZOOM_LEVEL_STRING = "100%"; //$NON-NLS-1$
-
- private static final double DEFAULT_ZOOM_LEVEL = 1;
-
- /** the current ZoomManager all work is delegated to */
- private ZoomManager currentZoomManager = null;
-
- /** listeners of zoom */
- private ListenerList zoomListeners = new ListenerList(
- ListenerList.IDENTITY);
-
- /**
- * Creates a new DelegatingZoomManager instance.
- */
- public DelegatingZoomManager() {
- super((ScalableFigure) null, (Viewport) null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomListener#zoomChanged(double)
- */
- public void zoomChanged(double zoom) {
- Object[] listeners = zoomListeners.getListeners();
- for (int i = 0; i < listeners.length; ++i) {
- ((ZoomListener) listeners[i]).zoomChanged(zoom);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#addZoomListener(ZoomListener)
- */
- public void addZoomListener(ZoomListener listener) {
- zoomListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#removeZoomListener(oZoomListener)
- */
- public void removeZoomListener(ZoomListener listener) {
- zoomListeners.remove(listener);
- }
-
- /**
- * Sets the ZoomManager all work should be delegated to.
- *
- * @param zoomManager
- */
- public void setCurrentZoomManager(ZoomManager zoomManager) {
- if (null != currentZoomManager) {
- currentZoomManager.removeZoomListener(this);
- }
-
- currentZoomManager = zoomManager;
- if (null != currentZoomManager) {
- currentZoomManager.addZoomListener(this);
- zoomChanged(currentZoomManager.getZoom());
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#canZoomIn()
- */
- public boolean canZoomIn() {
- if (null == currentZoomManager) {
- return false;
- }
-
- return currentZoomManager.canZoomIn();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#canZoomOut()
- */
- public boolean canZoomOut() {
- if (null == currentZoomManager) {
- return false;
- }
-
- return currentZoomManager.canZoomOut();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getMaxZoom()
- */
- public double getMaxZoom() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getMaxZoom();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getMinZoom()
- */
- public double getMinZoom() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getMinZoom();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getNextZoomLevel()
- */
- public double getNextZoomLevel() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getNextZoomLevel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getPreviousZoomLevel()
- */
- public double getPreviousZoomLevel() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getPreviousZoomLevel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getScalableFigure()
- */
- public ScalableFigure getScalableFigure() {
- if (null == currentZoomManager) {
- return null;
- }
-
- return currentZoomManager.getScalableFigure();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getUIMultiplier()
- */
- public double getUIMultiplier() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getUIMultiplier();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getViewport()
- */
- public Viewport getViewport() {
- if (null == currentZoomManager) {
- return null;
- }
-
- return currentZoomManager.getViewport();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getZoom()
- */
- public double getZoom() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL;
- }
-
- return currentZoomManager.getZoom();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getZoomAsText()
- */
- public String getZoomAsText() {
- if (null == currentZoomManager) {
- return DEFAULT_ZOOM_LEVEL_STRING;
- }
-
- return currentZoomManager.getZoomAsText();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getZoomLevels()
- */
- public double[] getZoomLevels() {
- if (null == currentZoomManager) {
- return new double[] { DEFAULT_ZOOM_LEVEL };
- }
-
- return currentZoomManager.getZoomLevels();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#getZoomLevelsAsText()
- */
- public String[] getZoomLevelsAsText() {
- if (null == currentZoomManager) {
- return new String[] { DEFAULT_ZOOM_LEVEL_STRING };
- }
-
- return currentZoomManager.getZoomLevelsAsText();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setUIMultiplier(double)
- */
- public void setUIMultiplier(double multiplier) {
- if (null == currentZoomManager) {
- return;
- }
-
- currentZoomManager.setUIMultiplier(multiplier);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setViewLocation(Point)
- */
- public void setViewLocation(Point p) {
- if (null == currentZoomManager) {
- return;
- }
-
- currentZoomManager.setViewLocation(p);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setZoom(double)
- */
- public void setZoom(double zoom) {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.setZoom(zoom);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setZoomAnimationStyle(int)
- */
- public void setZoomAnimationStyle(int style) {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.setZoomAnimationStyle(style);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setZoomAsText(String)
- */
- public void setZoomAsText(String zoomString) {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.setZoomAsText(zoomString);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#setZoomLevels(double[])
- */
- public void setZoomLevels(double[] zoomLevels) {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.setZoomLevels(zoomLevels);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#zoomIn()
- */
- public void zoomIn() {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.zoomIn();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#zoomOut()
- */
- public void zoomOut() {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.zoomOut();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ZoomManager#zoomTo(Rectangle)
- */
- public void zoomTo(Rectangle rect) {
- if (null == currentZoomManager) {
- return;
- }
- currentZoomManager.zoomTo(rect);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowActionBarContributor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowActionBarContributor.java
deleted file mode 100644
index 349b69d19..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowActionBarContributor.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.gef.editparts.ZoomManager;
-import org.eclipse.gef.ui.actions.ActionBarContributor;
-import org.eclipse.gef.ui.actions.AlignmentRetargetAction;
-import org.eclipse.gef.ui.actions.DeleteRetargetAction;
-import org.eclipse.gef.ui.actions.GEFActionConstants;
-import org.eclipse.gef.ui.actions.RedoRetargetAction;
-import org.eclipse.gef.ui.actions.UndoRetargetAction;
-import org.eclipse.gef.ui.actions.ZoomComboContributionItem;
-import org.eclipse.gef.ui.actions.ZoomInRetargetAction;
-import org.eclipse.gef.ui.actions.ZoomOutRetargetAction;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.action.Separator;
-import org.eclipse.jst.jsf.facesconfig.ui.INestedActionContributor;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchActionConstants;
-import org.eclipse.ui.actions.ActionFactory;
-
-/**
- * The action bar contributor for the page flow editor
- *
- */
-public class PageflowActionBarContributor extends ActionBarContributor
- implements INestedActionContributor {
-
- IEditorPart activeEditor;
-
- /*
- * (non-Javadoc)
- *
- * @see ActionBarContributor#buildActions()
- */
- protected void buildActions() {
- addRetargetAction(new UndoRetargetAction());
- addRetargetAction(new RedoRetargetAction());
- addRetargetAction(new DeleteRetargetAction());
- addRetargetAction(new ZoomInRetargetAction());
- addRetargetAction(new ZoomOutRetargetAction());
-
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.LEFT));
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.CENTER));
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.RIGHT));
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.TOP));
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.MIDDLE));
- addRetargetAction(new AlignmentRetargetAction(PositionConstants.BOTTOM));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ActionBarContributor#declareGlobalActionKeys()
- */
- public void declareGlobalActionKeys() {
- // do nothing
- }
-
- /**
- * Update the action keys
- */
- public void updateActionKeys() {
- declareGlobalActionKeys();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see EditorActionBarContributor#contributeToToolBar(IToolBarManager)
- */
- public void contributeToToolBar(IToolBarManager tbm) {
- tbm.add(getAction(ActionFactory.UNDO.getId()));
- tbm.add(getAction(ActionFactory.REDO.getId()));
- tbm.add(new Separator());
- tbm.add(getAction(GEFActionConstants.ALIGN_LEFT));
- tbm.add(getAction(GEFActionConstants.ALIGN_CENTER));
- tbm.add(getAction(GEFActionConstants.ALIGN_RIGHT));
- tbm.add(new Separator());
- tbm.add(getAction(GEFActionConstants.ALIGN_TOP));
- tbm.add(getAction(GEFActionConstants.ALIGN_MIDDLE));
- tbm.add(getAction(GEFActionConstants.ALIGN_BOTTOM));
-
- tbm.add(new Separator());
- String[] zoomStrings = new String[] { ZoomManager.FIT_ALL,
- ZoomManager.FIT_HEIGHT, ZoomManager.FIT_WIDTH };
- tbm.add(new ZoomComboContributionItem(getPage(), zoomStrings));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see EditorActionBarContributor#contributeToMenu(IMenuManager)
- */
- public void contributeToMenu(IMenuManager menubar) {
- super.contributeToMenu(menubar);
- MenuManager viewMenu = new MenuManager("View"); //$NON-NLS-1$
- viewMenu.add(getAction(GEFActionConstants.ZOOM_IN));
- viewMenu.add(getAction(GEFActionConstants.ZOOM_OUT));
- menubar.insertAfter(IWorkbenchActionConstants.M_EDIT, viewMenu);
- }
-
- public void setActiveEditor(IEditorPart editor) {
- if (editor instanceof PageflowEditor) {
- activeEditor = editor;
- // updateActionKeys();
- super.setActiveEditor(editor);
- }
- }
-
- public void update() {
- if (activeEditor != null) {
- ((PageflowEditor) activeEditor).updateActions();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditor.java
deleted file mode 100644
index f65230ac2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditor.java
+++ /dev/null
@@ -1,1225 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IResourceChangeEvent;
-import org.eclipse.core.resources.IResourceChangeListener;
-import org.eclipse.core.resources.IResourceDelta;
-import org.eclipse.core.resources.IResourceDeltaVisitor;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.core.runtime.SubProgressMonitor;
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.gef.ContextMenuProvider;
-import org.eclipse.gef.DefaultEditDomain;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.GraphicalViewer;
-import org.eclipse.gef.KeyHandler;
-import org.eclipse.gef.KeyStroke;
-import org.eclipse.gef.RootEditPart;
-import org.eclipse.gef.commands.CommandStack;
-import org.eclipse.gef.commands.CommandStackEvent;
-import org.eclipse.gef.commands.CommandStackEventListener;
-import org.eclipse.gef.editparts.ScalableFreeformRootEditPart;
-import org.eclipse.gef.editparts.ScalableRootEditPart;
-import org.eclipse.gef.editparts.ZoomManager;
-import org.eclipse.gef.palette.PaletteRoot;
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.gef.ui.actions.ActionRegistry;
-import org.eclipse.gef.ui.actions.DeleteAction;
-import org.eclipse.gef.ui.actions.GEFActionConstants;
-import org.eclipse.gef.ui.actions.RedoAction;
-import org.eclipse.gef.ui.actions.SelectionAction;
-import org.eclipse.gef.ui.actions.StackAction;
-import org.eclipse.gef.ui.actions.UndoAction;
-import org.eclipse.gef.ui.actions.UpdateAction;
-import org.eclipse.gef.ui.actions.ZoomInAction;
-import org.eclipse.gef.ui.actions.ZoomOutAction;
-import org.eclipse.gef.ui.parts.GraphicalEditorWithFlyoutPalette;
-import org.eclipse.gef.ui.parts.GraphicalViewerKeyHandler;
-import org.eclipse.gef.ui.parts.ScrollingGraphicalViewer;
-import org.eclipse.gef.ui.parts.SelectionSynchronizer;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.resource.FontRegistry;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jface.util.IPropertyChangeListener;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.jface.util.TransferDropTargetListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.AlignmentAction;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.OpenEditorAction;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.ShowPropertyViewAction;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.PreExecuteCommandStack;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.ConfigurableRootEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.IConnectionPreference;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.IFigurePreference;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.ILayerPanePreference;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.INodePreference;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowEditPartsFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.FC2PFTransformer;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.EditPartMarkerUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowAnnotationUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowModelManager;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowResourceFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.ISelectionListener;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.actions.ActionFactory;
-import org.eclipse.ui.ide.IGotoMarker;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-import org.eclipse.ui.views.properties.PropertySheetPage;
-
-/**
- * This the the main editor page for modifying a complete pageflow.
- */
-public class PageflowEditor extends GraphicalEditorWithFlyoutPalette implements
- IAdaptable, IPropertyChangeListener, IGotoMarker {
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(PageflowEditor.class);
-
- /** pageflow context menu registration ID */
- private static final String PAGEFLOW_CONTEXTMENU_REG_ID = ".pageflow.editor.contextmenu"; //$NON-NLS-1$
-
- /** the edit domain */
- private final DefaultEditDomain domain;
-
- /** the palette root */
- private PaletteRoot paletteRoot = null;
-
- /** the parent multi-page editor */
- private IEditorPart parentEditor = null;
-
- /** the graphical viewer */
- private GraphicalViewer viewer = null;
-
- /** the undoable <code>IPropertySheetPage</code> */
- private PropertySheetPage undoablePropertySheetPage = null;
-
- /** the editor's action registry */
- private ActionRegistry actionRegistry = null;
-
- /**
- * The id of the editor page
- */
- public static final String PAGE_ID = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor"; //$NON-NLS-1$
-
- /** the list of action ids that are to EditPart actions */
- private List editPartActionIDs = new ArrayList();
-
- /** the selection listener */
- private ISelectionListener selectionListener = new ISelectionListener() {
- public void selectionChanged(IWorkbenchPart part, ISelection selection) {
- updateActions();
- }
- };
-
- /** the selection synchronizer for the edit part viewer */
- private SelectionSynchronizer synchronizer = null;
-
- /** the shared key handler */
- private KeyHandler sharedKeyHandler = null;
-
- /** pageflow model manager */
- private PageflowModelManager pageflowManager;
-
- /** the dirty status of this page */
- private boolean isDirty = false;
-
- /** the command stack of this page */
- private CommandStack commandStack;
-
- private FC2PFTransformer modelsTransform;
-
- List stackActions = new ArrayList();
-
- /**
- * @return the faces-config to pageflow model
- */
- public FC2PFTransformer getModelsTransform() {
- if (modelsTransform == null) {
- modelsTransform = new FC2PFTransformer();
- }
- return modelsTransform;
- }
-
- /**
- * update the editor actions
- */
- public void updateActions() {
- updateActions(stackActions);
- updateActions(editPartActionIDs);
- }
-
- /**
- * This class listens for command stack changes of the page and decides if
- * the editor is dirty or not.
- *
- */
- private class PageCommandStackListener implements CommandStackEventListener {
- public void stackChanged(CommandStackEvent event) {
- if (((CommandStack) event.getSource()).isDirty()) {
- // at least one command stack is dirty,
- // so the multi page editor is dirty too
- setDirty(true);
- }
- updateActions();
- }
- }
-
- /**
- * This class listens to changes to the file system in the workspace, and
- * validate the current pageflow based on web files' status.
- */
- private class ResourceTracker implements IResourceChangeListener,
- IResourceDeltaVisitor {
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.resources.IResourceChangeListener#resourceChanged(org.eclipse.core.resources.IResourceChangeEvent)
- */
- public void resourceChanged(IResourceChangeEvent event) {
- IResourceDelta delta = event.getDelta();
- try {
- if (delta != null) {
- delta.accept(this);
- }
- } catch (CoreException exception) {
- // Pageflow.PageflowEditor.Error.ResourceChange = Failed in the
- // resource change.
- log.error("Pageflow.PageflowEditor.Error.ResourceChange", //$NON-NLS-1$
- exception);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.resources.IResourceDeltaVisitor#visit(org.eclipse.core.resources.IResourceDelta)
- */
- public boolean visit(IResourceDelta delta) {
- // if the delta is not a file instance, just return true
- if (!(delta.getResource() instanceof IFile)) {
- return true;
- }
-
- // web file is changed.
- if (WebrootUtil.isValidWebFile(((IFile) delta.getResource())
- .getFullPath())) {
- webPageChanged(((IFile) delta.getResource()).getFullPath());
- return false;
- }
- return false;
- }
- }
-
- /** the resource tracker instance */
- private ResourceTracker resourceTracker = null;
-
- /**
- * Returns the resource tracker instance
- *
- * @return - Returns the resource tracker instance
- */
- private ResourceTracker getResourceTracker() {
- if (null == resourceTracker) {
- resourceTracker = new ResourceTracker();
- }
- return resourceTracker;
- }
-
- /**
- * Changes the dirty state.
- *
- * @param dirty -
- * dirty state
- */
- protected void setDirty(boolean dirty) {
- if (isDirty != dirty) {
- isDirty = dirty;
- }
- }
-
- /**
- * Updates the specified actions.
- *
- * @param actionIds -
- * the list of ids of actions to update
- */
- protected void updateActions(List actionIds) {
- for (Iterator ids = actionIds.iterator(); ids.hasNext();) {
- IAction action = getActionRegistry().getAction(ids.next());
- if (null != action && action instanceof UpdateAction) {
- ((UpdateAction) action).update();
- }
- }
- }
-
- /**
- * Creates a new PageflowPage instance.
- * <p>
- * By design this page uses its own <code>EditDomain</code>. The main
- * goal of this approach is that this page has its own undo/redo command
- * stack.
- *
- * @param parent -
- * the parent multi page editor
- */
- public PageflowEditor(IEditorPart parent) {
- domain = new DefaultEditDomain(parent);
- domain.setCommandStack(getCommandStack());
- this.setEditDomain(domain);
- parentEditor = parent;
- }
-
- /**
- * Adds an <code>CommandStack</code> action to this editor.
- * <p>
- * <code>CommandStack</code> actions are actions that depend and work on
- * the <code>CommandStack</code>.
- *
- * @param action -
- * the <code>CommandStack</code> action
- */
- protected void addStackAction(StackAction action) {
- getActionRegistry().registerAction(action);
- stackActions.add(action.getId());
- }
-
- /**
- * Creates different kinds of actions and registers them to the
- * ActionRegistry.
- */
- protected void createActions() {
- // register delete action
- addEditPartAction(new DeleteAction((IWorkbenchPart) this));
- // register undo/redo action
- addStackAction(new UndoAction(this));
- addStackAction(new RedoAction(this));
-
- // Allows opening of JSP files from the pageflow
- addEditPartAction(new OpenEditorAction(this));
-
- // Allows showing property view for the pageflow
- SelectionAction action = new ShowPropertyViewAction(this);
- action
- .setImageDescriptor(getImageDescriptorForView("org.eclipse.ui.views.PropertySheet")); //$NON-NLS-1$
- addEditPartAction(action);
- // Allows showing property view for the pageflow
- // addEditPartAction(new ShowPaletteViewAction((IWorkbenchPart) this));
-
- // register alignment actions
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.LEFT));
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.RIGHT));
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.TOP));
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.BOTTOM));
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.CENTER));
- addEditPartAction(new AlignmentAction((IWorkbenchPart) this,
- PositionConstants.MIDDLE));
-
- // register zoom in/out action
- IAction zoomIn = new ZoomInAction(getZoomManager(getGraphicalViewer()));
- IAction zoomOut = new ZoomOutAction(
- getZoomManager(getGraphicalViewer()));
- addAction(zoomIn);
- addAction(zoomOut);
-
-// getSite().getKeyBindingService().registerAction(zoomIn);
-// getSite().getKeyBindingService().registerAction(zoomOut);
- }
-
- /**
- * Returns the zoom manager of the specified viewer.
- *
- * @param viewer_ -
- * the viewer to get the zoom manager from
- * @return - the zoom manager
- */
- private ZoomManager getZoomManager(GraphicalViewer viewer_) {
- // get zoom manager from root edit part
- RootEditPart rootEditPart = viewer_.getRootEditPart();
- ZoomManager zoomManager = null;
- if (rootEditPart instanceof ScalableFreeformRootEditPart) {
- zoomManager = ((ScalableFreeformRootEditPart) rootEditPart)
- .getZoomManager();
- } else if (rootEditPart instanceof ScalableRootEditPart) {
- zoomManager = ((ScalableRootEditPart) rootEditPart)
- .getZoomManager();
- }
- return zoomManager;
- }
-
- /**
- * Adds an action to this editor's <code>ActionRegistry</code>.
- *
- * @param action -
- * the action to add.
- */
- protected void addAction(IAction action) {
- getActionRegistry().registerAction(action);
- }
-
- /**
- * Adds an <code>EditPart</code> action to this editor.
- * <p>
- * <code>EditPart</code> actions are actions that depend and work on the
- * selected <code>EditPart</code>s.
- *
- * @param action -
- * the <code>EditPart</code> action
- */
- protected void addEditPartAction(SelectionAction action) {
- getActionRegistry().registerAction(action);
- editPartActionIDs.add(action.getId());
- }
-
- /**
- * Returns the action registry of this editor.
- *
- * @return - the action registry
- */
- public ActionRegistry getActionRegistry() {
- if (null == actionRegistry) {
- actionRegistry = new ActionRegistry();
- }
-
- return actionRegistry;
- }
-
- /**
- * Creates the GraphicalViewer on the specified <code>Composite</code>.
- *
- * @param parent -
- * the parent composite
- */
- public void createGraphicalViewer(Composite parent) {
- viewer = new ScrollingGraphicalViewer();
- viewer.createControl(parent);
-
- // configure the viewer
- viewer.getControl().setBackground(parent.getBackground());
-
- viewer.setRootEditPart(new ConfigurableRootEditPart());
- // _viewer.setRootEditPart(new ScalableFreeformRootEditPart());
- viewer.setKeyHandler(new GraphicalViewerKeyHandler(viewer));
-
- // hook the viewer into the editor
- registerEditPartViewer(viewer);
-
- // configure the viewer with context menu and template drag and drop
- configureEditPartViewer(viewer);
-
- // initialize the viewer with input
- viewer.setEditPartFactory(new PageflowEditPartsFactory());
- // viewer.setContents(getPageflow());
-
- // support the resource drag&drop
- viewer
- .addDropTargetListener((TransferDropTargetListener) new ResourceTransferDropTargetListener(
- viewer, getParentEditor()) {
- protected CreationFactory getFactory(Object obj) {
- return getResourceFactory((IResource) obj);
- }
- });
-
- // apply Editor's preferences
- // propertyChange(null);
- // add listener to Editor's preferences changing
- EditorPlugin.getDefault().getPreferenceStore()
- .addPropertyChangeListener(this);
- }
-
- private CreationFactory getResourceFactory(IResource resource) {
- return new PageflowResourceFactory(resource);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISaveablePart#doSave(org.eclipse.core.runtime.IProgressMonitor)
- */
- public final void doSave(IProgressMonitor monitor) {
- // our policy: delegate saving to the parent
- getParentEditor().doSave(monitor);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISaveablePart#doSaveAs()
- */
- public final void doSaveAs() {
- // our policy: delegate saving to the parent
- getParentEditor().doSaveAs();
- }
-
- /**
- * Saves the pageflow under the specified path.
- * @param file
- *
- * @param progressMonitor
- * @throws CoreException
- */
- public void doSave(IFile file, IProgressMonitor progressMonitor)
- throws CoreException {
- if (((FileEditorInput) getEditorInput()).getFile() != file) {
- // TODO: save to other page.
- }
- if (null == progressMonitor) {
- progressMonitor = new NullProgressMonitor();
- }
- // Pageflow.Label.Saving = Saving
- progressMonitor.beginTask(PageflowMessages.Pageflow_Label_Saving + " " //$NON-NLS-1$
- + file.getFullPath(), 2);
-
- if (null == getPageflowManager()) {
- // Pageflow.PageflowEditor.Alert.nullModelManager = No model manager
- // found for saving the file.
- EditorPlugin.getAlerts().throwCoreException(
- "Pageflow.PageflowEditor.Alert.nullModelManager"); //$NON-NLS-1$
- }
-
- // save pageflow to file
- try {
- getPageflowManager().save(getPageflowFilePath(file));
-
- progressMonitor.worked(1);
- file.refreshLocal(IResource.DEPTH_ZERO, new SubProgressMonitor(
- progressMonitor, 1));
- progressMonitor.done();
- setDirty(false);
- } catch (FileNotFoundException e) {
- // Pageflow.PageflowEditor.Alert.errorSaveFileInfo = The current
- // pageflow model could not be saved.
- EditorPlugin.getAlerts().throwCoreException(e);
- } catch (IOException e) {
- // Pageflow.PageflowEditor.Alert.errorSaveFileInfo = The current
- // pageflow model could not be saved.
- EditorPlugin.getAlerts().throwCoreException(e);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IEditorPart#init(org.eclipse.ui.IEditorSite,
- * org.eclipse.ui.IEditorInput)
- */
- public void init(IEditorSite site, IEditorInput input)
- throws PartInitException {
- setSite(site);
- setInput(input);
- IFile fileFacesConfig = null;
- try {
- fileFacesConfig = ((FileEditorInput) input).getFile();
-
- // load and validate pageflow
- if (null == createPageflow(getPageflowFilePath(fileFacesConfig))) {
- // Pageflow.PageflowEditor.Error.invalidPageflowFile = The
- // specified input is not a valid pageflow.
- log.error("Pageflow.PageflowEditor.Error.invalidPageflowFile"); //$NON-NLS-1$
- throw new PartInitException(
- EditorPlugin
- .getResourceString("Pageflow.PageflowEditor.Error.invalidPageflowFile")); //$NON-NLS-1$
- }
-
- } catch (CoreException e) {
- // Pageflow.PageflowEditor.Error.invalidPageflowFile = The specified
- // input is not a valid pageflow.
- log.error("Pageflow.PageflowEditor.Error.invalidPageflowFile", e); //$NON-NLS-1$
- throw new PartInitException(e.getStatus());
- } catch (IOException e) {
- // Pageflow.PageflowEditor.Alert.errorSaveFileInfo = The current
- // pageflow model could not be saved.
- log.error("Pageflow.PageflowEditor.Alert.errorSaveFileInfo", e); //$NON-NLS-1$
- }
-
- // add selection change listener
- getSite().getWorkbenchWindow().getSelectionService()
- .addSelectionListener(getSelectionListener());
-
- // Add resource change listener
- fileFacesConfig.getWorkspace().addResourceChangeListener(
- getResourceTracker());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.IWorkbenchPart#dispose()
- */
- public void dispose() {
- // remove selection change listener
- getModelsTransform().dispose();
- getSite().getWorkbenchWindow().getSelectionService()
- .removeSelectionListener(getSelectionListener());
-
- // remove listener to Editor's preferences changing
- EditorPlugin.getDefault().getPreferenceStore()
- .removePropertyChangeListener(this);
-
- if (getEditorInput() != null) {
- IFile file = (IFile) getEditorInput().getAdapter(IResource.class);
- if (file != null) {
- file.getWorkspace().removeResourceChangeListener(
- getResourceTracker());
- }
- }
- super.dispose();
- }
-
- /**
- * get the pageflow file path based on faces-config.xml file path
- *
- * @return
- */
- private IPath getPageflowFilePath(IFile file) {
- IPath pageflowFilePath;
- pageflowFilePath = PageflowModelManager.makePageflowPath(file
- .getFullPath());
- return pageflowFilePath;
- }
-
- /**
- * Returns the pageflow object from the specified file.
- *
- * @param file -
- * the file resource
- * @return -the pageflow object from the specified file
- * @throws IOException
- */
- private Pageflow createPageflow(IPath pathPageflow) throws CoreException,
- IOException {
- Pageflow pageflow = null;
-
- try {
- getPageflowManager().load(pathPageflow);
- } catch (Exception e) {
- // Pageflow.PageflowEditor.Error.invalidPageflowFile = The specified
- // input is not a valid pageflow.
- // _log.error("Pageflow.PageflowEditor.Error.invalidPageflowFile",
- // e);
- getPageflowManager().createPageflow(pathPageflow);
- }
- IFile fileFacesConfig = ((FileEditorInput) getEditorInput()).getFile();
- // it should update related config file
- if (!fileFacesConfig.getFullPath().toString().trim().equalsIgnoreCase(
- getPageflowManager().getModel().getConfigfile())) {
- getPageflowManager().getModel().setConfigfile(
- fileFacesConfig.getFullPath().toString());
- getPageflowManager().save(pathPageflow);
- }
- pageflow = getPageflowManager().getModel();
- if (null == pageflow) {
- // Pageflow.PageflowEditor.Error.invalidPageflowModel = The model in
- // the pageflow file is not a valid pageflow model.
- log.error("Pageflow.PageflowEditor.Error.invalidPageflowModel"); //$NON-NLS-1$
- EditorPlugin.getAlerts().throwCoreException(
- "Pageflow.PageflowEditor.Error.invalidPageflowModel"); //$NON-NLS-1$
- }
- return pageflow;
- }
-
- /** get the pageflow manager for this page
- * @return the model manager
- */
- public PageflowModelManager getPageflowManager() {
- if (pageflowManager == null) {
- pageflowManager = new PageflowModelManager();
- }
- return pageflowManager;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISaveablePart#isDirty()
- */
- public final boolean isDirty() {
- return isDirty;
- }
-
- /**
- * Returns the <code>CommandStack</code> of this editor page.
- *
- * @return - the <code>CommandStack</code> of this editor page
- */
- public final CommandStack getCommandStack() {
- if (commandStack == null) {
- commandStack = new PreExecuteCommandStack();
- commandStack
- .addCommandStackEventListener(new PageCommandStackListener());
- }
- return commandStack;
- }
-
- /**
- * Returns the default <code>PaletteRoot</code> for this editor and all
- * its pages.
- *
- * @return - the default <code>PaletteRoot</code>
- */
- protected PaletteRoot getPaletteRoot() {
- if (null == paletteRoot) {
- // create root
- paletteRoot = new PageflowPaletteRoot();
- }
- return paletteRoot;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISaveablePart#isSaveAsAllowed()
- */
- public final boolean isSaveAsAllowed() {
- // our policy: delegate saving to the parent
- return getParentEditor().isSaveAsAllowed();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IWorkbenchPart#setFocus()
- */
- public void setFocus() {
- getGraphicalViewer().getControl().setFocus();
- }
-
- /**
- * Returns the multi page pageflow editor this editor page is contained in.
- *
- * @return - the parent multi page editor
- */
- protected final IEditorPart getParentEditor() {
- return parentEditor;
- }
-
- /**
- * Returns the edit domain this editor page uses.
- *
- * @return - the edit domain this editor page uses
- */
- public final DefaultEditDomain getEditDomain() {
- return domain;
- }
-
- /**
- * Hooks a <code>EditPartViewer</code> to the rest of the Editor.
- * <p>
- * By default, the viewer is added to the SelectionSynchronizer, which can
- * be used to keep 2 or more EditPartViewers in sync. The viewer is also
- * registered as the ISelectionProvider for the Editor's PartSite.
- *
- * @param viewer_ -
- * the viewer to hook into the editor
- */
- protected void registerEditPartViewer(EditPartViewer viewer_) {
- // register viewer to edit domain
- getEditDomain().addViewer(viewer_);
-
- // the multi page pageflow editor keeps track of synchronizing
- getSelectionSynchronizer().addViewer(viewer_);
-
- // add viewer as selection provider
- getSite().setSelectionProvider(viewer_);
- }
-
- /**
- * Configures the specified <code>EditPartViewer</code> including context
- * menu, key handler, etc.
- *
- * @param viewer_ -
- * the pageflow graphical viewer.
- */
- protected void configureEditPartViewer(EditPartViewer viewer_) {
- // configure the shared key handler
- if (null != viewer_.getKeyHandler()) {
- viewer_.getKeyHandler().setParent(getSharedKeyHandler());
- }
- // create the ActionRegistry
- createActions();
-
- // append the parent editor's action registry.
- ActionRegistry actionRegistry_ = (ActionRegistry) getParentEditor()
- .getAdapter(ActionRegistry.class);
- if (actionRegistry_ != null) {
- for (Iterator iter = actionRegistry_.getActions(); iter.hasNext();) {
- getActionRegistry().registerAction((IAction) iter.next());
- }
- }
- // configure and register the context menu
- ContextMenuProvider provider = new PageflowEditorContextMenuProvider(
- viewer_, getActionRegistry());
- viewer_.setContextMenu(provider);
- getSite().registerContextMenu(
- EditorPlugin.getPluginId() + PAGEFLOW_CONTEXTMENU_REG_ID,
- provider, getSite().getSelectionProvider());
-
- // enable viewer as drop target for template transfers
- viewer_
- .addDropTargetListener((TransferDropTargetListener) new PageflowTemplateTransferDropTargetListener(
- viewer_));
-
- }
-
- /**
- * Returns the pageflow that is edited.
- *
- * @return - the pageflow that is edited
- */
- public Pageflow getPageflow() {
- return getPageflowManager().getModel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditorPage#getGraphicalViewerForZoomSupport()
- */
- public GraphicalViewer getGraphicalViewer() {
- return viewer;
- }
-
- /**
- * @param contents
- */
- public void setGraphicalViewerContents(Object contents) {
- viewer.setContents(contents);
- propertyChange(null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IAdaptable#getAdapter(Class)
- */
- public Object getAdapter(Class type) {
- if (type == IContentOutlinePage.class) {
- return getOutlinePage();
- } else if (type == CommandStack.class) {
- return getCommandStack();
- } else if (type == ActionRegistry.class) {
- return getActionRegistry();
- } else if (type == IPropertySheetPage.class) {
- return getPropertySheetPage();
- } else if (type == ZoomManager.class) {
- return getZoomManager(getGraphicalViewer());
- }
- return super.getAdapter(type);
- }
-
- /**
- * Returns the outline page for the outline view with lazy creation
- *
- * @return - the outline page
- */
- protected PageflowEditorOutlinePage getOutlinePage() {
- PageflowEditorOutlinePage outlinePage = new PageflowEditorOutlinePage(
- this);
- outlinePage.initialize(this);
- return outlinePage;
- }
-
- /**
- * Returns the undoable <code>PropertySheetPage</code> for this editor.
- *
- * @return - the undoable <code>PropertySheetPage</code>
- */
- protected IPropertySheetPage getPropertySheetPage() {
- if (null == undoablePropertySheetPage) {
- undoablePropertySheetPage = new PropertySheetPage();
-
- /** set the property source for property sheet page */
- undoablePropertySheetPage
- .setRootEntry(new org.eclipse.gef.ui.properties.UndoablePropertySheetEntry(
- (CommandStack) getAdapter(CommandStack.class)));
-
- }
-
- return undoablePropertySheetPage;
- }
-
- /**
- * Returns the selection syncronizer object. The synchronizer can be used to
- * sync the selection of 2 or more EditPartViewers.
- *
- * @return - the syncrhonizer
- */
- protected SelectionSynchronizer getSelectionSynchronizer() {
- if (null == synchronizer) {
- synchronizer = new SelectionSynchronizer();
- }
- return synchronizer;
- }
-
- /**
- * Returns the shared KeyHandler that should be used for all viewers.
- *
- * @return - the shared KeyHandler
- */
- protected KeyHandler getSharedKeyHandler() {
- if (null == sharedKeyHandler) {
- sharedKeyHandler = new KeyHandler();
-
- // configure common keys for all viewers
- sharedKeyHandler
- .put(KeyStroke.getPressed(SWT.DEL, 127, 0),
- getActionRegistry().getAction(
- ActionFactory.DELETE.getId()));
- sharedKeyHandler.put(KeyStroke.getPressed(SWT.F2, 0),
- getActionRegistry().getAction(
- GEFActionConstants.DIRECT_EDIT));
- }
- return sharedKeyHandler;
- }
-
- /**
- * Returns the selection listener.
- *
- * @return - the <code>ISelectionListener</code>
- */
- protected ISelectionListener getSelectionListener() {
- return selectionListener;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.util.IPropertyChangeListener#propertyChange(org.eclipse.jface.util.PropertyChangeEvent)
- */
- public void propertyChange(PropertyChangeEvent event) {
- String property = (event == null) ? null : event.getProperty();
-
- propagateProperty(property, viewer.getRootEditPart());
- }
-
- /**
- * propagate property change to children edit part
- *
- * @param property -
- * property's string name
- * @param part -
- * parent edit part.
- */
- private void propagateProperty(String property, EditPart part) {
- processPropertyChange(property, part);
-
- if (part instanceof GraphicalEditPart) {
- // get the connections edit part
- Iterator iterConns = ((GraphicalEditPart) part)
- .getSourceConnections().iterator();
- while (iterConns.hasNext()) {
- EditPart child = (EditPart) iterConns.next();
- propagateProperty(property, child);
- }
- }
- Iterator iter = part.getChildren().iterator();
- while (iter.hasNext()) {
- EditPart child = (EditPart) iter.next();
- propagateProperty(property, child);
- }
- }
-
- /**
- * process the property change FIXME: The property change should be category
- * to improve the performance.
- *
- * @param property -
- * property's string name
- * @param part
- */
- private void processPropertyChange(String property, EditPart part) {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
-
- if (property != null
- && property.equals(GEMPreferences.USE_SYSTEM_COLORS)) {
- // reload all properties - it's easiest
- property = null;
- }
-
- if (property == null || GEMPreferences.SNAP_TO_GRID.equals(property)) {
- boolean bSnapToGrid = store.getBoolean(GEMPreferences.SNAP_TO_GRID);
- if (part instanceof ILayerPanePreference) {
- ((ILayerPanePreference) part).setGridVisible(bSnapToGrid);
- }
- }
-
- if (property == null || GEMPreferences.GRID_WIDTH.equals(property)
- || GEMPreferences.GRID_HEIGHT.equals(property)) {
- Dimension gridSpacing = new Dimension(store
- .getInt(GEMPreferences.GRID_WIDTH), store
- .getInt(GEMPreferences.GRID_HEIGHT));
- if (part instanceof ILayerPanePreference) {
- ((ILayerPanePreference) part).setGridSpacing(gridSpacing);
- }
- }
-
- if (property == null || GEMPreferences.GRID_COLOR.equals(property)) {
- Color gridFgColor = GEMPreferences.getColor(store,
- GEMPreferences.GRID_COLOR);
- if (part instanceof ILayerPanePreference) {
- ((ILayerPanePreference) part)
- .setGridForegroundColor(gridFgColor);
- }
- }
-
- if (property == null || GEMPreferences.CANVAS_COLOR.equals(property)) {
- Color containerBgColor = GEMPreferences.getColor(store,
- GEMPreferences.CANVAS_COLOR);
- if (part instanceof IFigurePreference) {
- ((IFigurePreference) part).setBackgroundColor(containerBgColor);
- }
- }
-
- if (property == null || GEMPreferences.LINE_WIDTH.equals(property)) {
- int linkLineWidth = store.getInt(GEMPreferences.LINE_WIDTH);
-
- if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part).setLineWidth(linkLineWidth);
- }
- }
-
- if (property == null || GEMPreferences.LINE_COLOR.equals(property)) {
- Color linkLineColor = GEMPreferences.getColor(store,
- GEMPreferences.LINE_COLOR);
- if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part)
- .setForegroundColor(linkLineColor);
- }
- }
-
- if (property == null
- || GEMPreferences.SHOW_LINE_LABELS.equals(property)) {
- boolean bLinkLabelVisible = store
- .getBoolean(GEMPreferences.SHOW_LINE_LABELS);
- if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part)
- .setLabelVisible(bLinkLabelVisible);
- }
- }
-
- if (property == null || GEMPreferences.LINE_LABEL_FONT.equals(property)
- || GEMPreferences.LINE_LABEL_FONT_COLOR.equals(property)) {
- Font linkLabelFont = getLinkLabelFont();
- Color linkLabelFgColor = GEMPreferences.getColor(store,
- GEMPreferences.LINE_LABEL_FONT_COLOR);
- if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part).setFont(linkLabelFont);
- ((IConnectionPreference) part)
- .setLabelForegroundColor(linkLabelFgColor);
- }
- }
-
- if (property == null
- || GEMPreferences.LINE_LABEL_COLOR.equals(property)) {
- Color linkLabelBgColor = GEMPreferences.getColor(store,
- GEMPreferences.LINE_LABEL_COLOR);
- if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part)
- .setLabelBackgroundColor(linkLabelBgColor);
- }
- }
-
- if (property == null || GEMPreferences.LINE_ROUTING.equals(property)) {
- String connectionStyle = store
- .getString(GEMPreferences.LINE_ROUTING);
- int style;
- if (GEMPreferences.LINE_ROUTING_MANHATTAN.equals(connectionStyle)) {
- style = ILayerPanePreference.LINE_ROUTING_MANHATTAN;
- } else {
- style = ILayerPanePreference.LINE_ROUTING_MANUAL;
- }
-
- if (part instanceof ILayerPanePreference) {
- ((ILayerPanePreference) part).setConnectionRouterStyle(style);
- } else if (part instanceof IConnectionPreference) {
- ((IConnectionPreference) part).setConnectionRouterStyle(style);
- }
- }
-
- if (property == null
- || GEMPreferences.FIGURE_LABEL_FONT.equals(property)
- || GEMPreferences.FIGURE_LABEL_FONT_COLOR.equals(property)) {
- Font nodeLabelFont = getNodeLabelFont();
- Color nodeLabelFgColor = GEMPreferences.getColor(store,
- GEMPreferences.FIGURE_LABEL_FONT_COLOR);
-
- if (part instanceof INodePreference) {
- ((INodePreference) part).setFont(nodeLabelFont);
- ((INodePreference) part).setForegroundColor(nodeLabelFgColor);
- }
- }
-
- if (property == null || GEMPreferences.LABEL_PLACEMENT.equals(property)) {
- int placement = PositionConstants.SOUTH;
- String nodeLabelPlacement = store
- .getString(GEMPreferences.LABEL_PLACEMENT);
- if (GEMPreferences.LABEL_PLACEMENT_TOP.equals(nodeLabelPlacement))
- placement = PositionConstants.NORTH;
- else if (GEMPreferences.LABEL_PLACEMENT_BOTTOM
- .equals(nodeLabelPlacement))
- placement = PositionConstants.SOUTH;
- else if (GEMPreferences.LABEL_PLACEMENT_LEFT
- .equals(nodeLabelPlacement))
- placement = PositionConstants.WEST;
- else if (GEMPreferences.LABEL_PLACEMENT_RIGHT
- .equals(nodeLabelPlacement))
- placement = PositionConstants.EAST;
- if (part instanceof INodePreference)
- ((INodePreference) part).setTextPlacement(placement);
- }
- }
-
- private Font getLinkLabelFont() {
- FontRegistry registry = JFaceResources.getFontRegistry();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- FontData fontData = PreferenceConverter.getFontData(store,
- GEMPreferences.LINE_LABEL_FONT);
- if (!registry.get(fontData.toString()).equals(registry.defaultFont()))
- return registry.get(fontData.toString());
-
- registry.put(fontData.toString(), new FontData[] {fontData});
- return registry.get(fontData.toString());
- }
-
- private Font getNodeLabelFont() {
- FontRegistry registry = JFaceResources.getFontRegistry();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- FontData fontData = PreferenceConverter.getFontData(store,
- GEMPreferences.FIGURE_LABEL_FONT);
- if (!registry.get(fontData.toString()).equals(registry.defaultFont()))
- return registry.get(fontData.toString());
-
- registry.put(fontData.toString(), new FontData[] {fontData});
- return registry.get(fontData.toString());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.ui.ide.IGotoMarker#gotoMarker(org.eclipse.core.resources.IMarker)
- */
- public void gotoMarker(IMarker marker) {
- // The LOCATION attribute in the marker should be the ID string
- Object id = null;
- try {
- id = marker.getAttribute(IMarker.LOCATION);
- } catch (CoreException e) {
- // Pageflow.PageflowEditor.Error.invalidMarkerAttribute = Unable to
- // get marker's attribute
- log
- .error(
- "Pageflow.PageflowEditor.Error.invalidMarkerAttribute", //$NON-NLS-1$
- e);
- }
- if (id instanceof String) {
- GraphicalEditPart part = EditPartMarkerUtil.findEditPart(
- (GraphicalEditPart) getGraphicalViewer().getRootEditPart(),
- (String) id);
- if (part != null) {
- getGraphicalViewer().reveal(part);
- getGraphicalViewer().select(part);
- return;
- }
- }
-
- }
-
- /**
- * the related web page is changed in outside editor, the pageflow should be
- * revalidated to update the validation icons
- *
- * @param fullPath
- */
- public void webPageChanged(IPath fullPath) {
- PageflowPage page = getPageflowManager().foundPage(
- WebrootUtil.getWebPath(fullPath));
-
- if (page != null && getGraphicalViewer() != null
- && getGraphicalViewer().getRootEditPart() != null) {
- GraphicalEditPart pagePart = EditPartMarkerUtil.findEditPart(
- (GraphicalEditPart) getGraphicalViewer().getRootEditPart(),
- page.getId());
- PageflowAnnotationUtil
- .validatePage((PageflowNodeEditPart) pagePart);
- }
- }
-
- /**
- * Get the image desriptor from the view's id.
- *
- * @param viewid
- * @return
- */
- private ImageDescriptor getImageDescriptorForView(String viewid) {
- IConfigurationElement[] elements = Platform.getExtensionRegistry()
- .getConfigurationElementsFor("org.eclipse.ui.views"); //$NON-NLS-1$
- for (int i = 0; i < elements.length; i++) {
- String name = elements[i].getName();
- String id = elements[i].getAttribute("id"); //$NON-NLS-1$
- if ("view".equals(name) && viewid.equals(id)) { //$NON-NLS-1$
- String iconPath = elements[i].getAttribute("icon"); //$NON-NLS-1$
- if (iconPath != null) {
- return AbstractUIPlugin.imageDescriptorFromPlugin(
- elements[i].getDeclaringExtension().getContributor().getName(),
- iconPath);
- }
- }
- }
- return null;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorContextMenuProvider.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorContextMenuProvider.java
deleted file mode 100644
index 3e239190d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorContextMenuProvider.java
+++ /dev/null
@@ -1,242 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.gef.ContextMenuProvider;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.ui.actions.ActionRegistry;
-import org.eclipse.gef.ui.actions.GEFActionConstants;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.ShowPropertyViewAction;
-import org.eclipse.ui.actions.ActionFactory;
-
-/**
- * This is the context menu provider for pageflow editor.
- *
- */
-public class PageflowEditorContextMenuProvider extends ContextMenuProvider {
- /** the action registry */
- private final ActionRegistry actionRegistry;
-
- /**
- * Creates a new PageflowEditorContextMenuProvider instance.
- *
- * @param viewer -
- * the editor viewer
- * @param actionRegistry -
- * action registry of the editor
- */
- public PageflowEditorContextMenuProvider(EditPartViewer viewer,
- ActionRegistry actionRegistry) {
- super(viewer);
-
- this.actionRegistry = actionRegistry;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ContextMenuProvider#buildContextMenu(IMenuManager)
- */
- public void buildContextMenu(IMenuManager menuManager) {
- // add GEF menu groups, such as undo, edit, save, etc.
- GEFActionConstants.addStandardActionGroups(menuManager);
-
- // add typical undo/redo commands
- appendActionToUndoGroup(menuManager, ActionFactory.UNDO.getId());
- appendActionToUndoGroup(menuManager, ActionFactory.REDO.getId());
- // add edit commands, including copy, paste, delete
- appendActionToEditGroup(menuManager, ActionFactory.COPY.getId());
- appendActionToEditGroup(menuManager, ActionFactory.PASTE.getId());
- appendActionToEditGroup(menuManager, ActionFactory.DELETE.getId());
- // Add Open Editor Action
- appendActionToEditGroup(menuManager, FacesConfigEditor.EDITOR_ID);
-
- // append the save submenu
- appendActionToSaveGroup(menuManager, ActionFactory.SAVE.getId());
-
- // append the alignment submenu, including top, bottom, middle, left,
- // right and center.
- appendAlignmentSubmenu(menuManager);
-
- appendShowViewSubmenu(menuManager);
-
- }
-
- /**
- * Appends the alignment subment.
- *
- * @param menuManager
- * manager of workbench
- */
- private void appendShowViewSubmenu(IMenuManager menuManager) {
- // Show View Actions
- MenuManager submenu = new MenuManager(
- PageflowMessages.Pageflow_Contextmenu_ShowView_Label);
-
- IAction action = getActionRegistry().getAction(
- ShowPropertyViewAction.SHOW_PROPERTY_VIEW);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- // action = getActionRegistry().getAction(
- // ShowPaletteViewAction.SHOW_PALETTE_VIEW);
- // if (null != action && action.isEnabled()) {
- // submenu.add(action);
- // }
-
- if (!submenu.isEmpty()) {
- menuManager.appendToGroup(GEFActionConstants.GROUP_REST, submenu);
- }
- }
-
- /**
- * Appends the alignment subment.
- *
- * @param menuManager
- * manager of workbench
- */
- private void appendAlignmentSubmenu(IMenuManager menuManager) {
- // Alignment Actions
- MenuManager submenu = new MenuManager(
- PageflowMessages.Pageflow_Contextmenu_Align_Label);
-
- IAction action = getActionRegistry().getAction(
- GEFActionConstants.ALIGN_LEFT);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- action = getActionRegistry().getAction(GEFActionConstants.ALIGN_CENTER);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- action = getActionRegistry().getAction(GEFActionConstants.ALIGN_RIGHT);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- action = getActionRegistry().getAction(GEFActionConstants.ALIGN_TOP);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- action = getActionRegistry().getAction(GEFActionConstants.ALIGN_MIDDLE);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- action = getActionRegistry().getAction(GEFActionConstants.ALIGN_BOTTOM);
- if (null != action && action.isEnabled()) {
- submenu.add(action);
- }
-
- if (!submenu.isEmpty()) {
- menuManager.appendToGroup(GEFActionConstants.GROUP_EDIT, submenu);
- }
- }
-
- /**
- * Returns the action registry.
- *
- * @return - the action registry
- */
- protected ActionRegistry getActionRegistry() {
- return actionRegistry;
- }
-
- /**
- * Appends the specified action to the specified menu group
- *
- * @param menu -
- * menu manager
- * @param actionId -
- * action's ID
- * @param menuGroup -
- * menu group name
- */
- // TODO: dead code
-// private void appendActionToMenu(IMenuManager menu, String actionId,
-// String menuGroup) {
-// IAction action = getActionRegistry().getAction(actionId);
-// if (null != action && action.isEnabled()) {
-// menu.appendToGroup(menuGroup, action);
-// }
-// }
-
- /**
- * Appends the specified action to the 'Undo' menu group
- *
- * @param menu -
- * menu manager
- * @param actionId -
- * action's ID
- */
- private void appendActionToUndoGroup(IMenuManager menu, String actionId) {
- IAction action = getActionRegistry().getAction(actionId);
- if (null != action && action.isEnabled()) {
- menu.appendToGroup(GEFActionConstants.GROUP_UNDO, action);
- }
- }
-
- /**
- * Appends the specified action to the 'edit' menu group
- *
- * @param menu -
- * menu manager
- * @param actionId -
- * action's ID
- */
- private void appendActionToEditGroup(IMenuManager menu, String actionId) {
- IAction action = getActionRegistry().getAction(actionId);
- if (null != action && action.isEnabled()) {
- menu.appendToGroup(GEFActionConstants.GROUP_EDIT, action);
- }
- }
-
- /**
- * Appends the specified action to the 'add' menu group
- *
- * @param menu -
- * menu manager
- * @param actionId -
- * action's ID
- */
- // TODO: dead code
-// private void appendActionToAddGroup(IMenuManager menu, String actionId) {
-// IAction action = getActionRegistry().getAction(actionId);
-// if (null != action && action.isEnabled()) {
-// menu.appendToGroup(GEFActionConstants.GROUP_ADD, action);
-// }
-// }
-
- /**
- * Appends the specified action to the 'save' menu group
- *
- * @param menu -
- * menu manager
- * @param actionId -
- * action's ID
- */
- private void appendActionToSaveGroup(IMenuManager menu, String actionId) {
- IAction action = getActionRegistry().getAction(actionId);
- if (null != action && action.isEnabled()) {
- menu.appendToGroup(GEFActionConstants.GROUP_SAVE, action);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorOutlinePage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorOutlinePage.java
deleted file mode 100644
index 82ca489ab..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowEditorOutlinePage.java
+++ /dev/null
@@ -1,545 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.LightweightSystem;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.draw2d.Viewport;
-import org.eclipse.draw2d.parts.ScrollableThumbnail;
-import org.eclipse.gef.ContextMenuProvider;
-import org.eclipse.gef.EditDomain;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartListener;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.LayerConstants;
-import org.eclipse.gef.RootEditPart;
-import org.eclipse.gef.editparts.ScalableFreeformRootEditPart;
-import org.eclipse.gef.editparts.ScalableRootEditPart;
-import org.eclipse.gef.ui.parts.TreeViewer;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowTreePartFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Canvas;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.part.EditorPart;
-import org.eclipse.ui.part.Page;
-import org.eclipse.ui.part.PageBook;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
-
-/**
- * This is an implementation of an outline page showing an overview figure and
- * an tree outline of the main graphical viewer provided by the current active
- * page of an multi page editor.
- *
- */
-public class PageflowEditorOutlinePage extends Page implements
- IContentOutlinePage {
- /** the pageflow editor */
- private final PageflowEditor editor;
-
- /** the outlineContent for the tree viewer */
- private PageflowElement outlineContent = null;
-
- /** the control of the overview */
- private Canvas overview = null;
-
- /** the root edit part (outlineContent for the thumbnail) */
- private RootEditPart overviewContent = null;
-
- /** the thumbnail */
- private ScrollableThumbnail thumbnail = null;
-
- /** the tree viewer */
- private TreeViewer treeViewer = null;
-
- /** the control of the tree view */
- private Control outline = null;
-
- /** the pagebook */
- private PageBook pageBook = null;
-
- /** action for showing the tree page */
- private IAction showOutlineAction = null;
-
- /** action for showing the overview page */
- private IAction showOverviewAction = null;
-
- /** the LightweightSystem */
- private LightweightSystem lws = null;
-
- /** the edit domain */
- private EditDomain editDomain = null;
-
- /**
- * Creates a new PageflowEditorOutlinePage instance.
- *
- * @param editor -
- * Pageflow Editor
- */
- public PageflowEditorOutlinePage(EditorPart editor) {
- super();
- this.editor = (PageflowEditor) editor;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISelectionProvider#addSelectionChangedListener(ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- getTreeViewer().addSelectionChangedListener(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPage#createControl(Composite)
- */
- public void createControl(Composite parent) {
- // pagebook
- pageBook = new PageBook(parent, SWT.NONE);
-
- // tree viewer control
- outline = getTreeViewer().createControl(pageBook);
- configureEditPartViewer(getTreeViewer());
-
- // overview canvas
- overview = new Canvas(pageBook, SWT.NONE);
- lws = new LightweightSystem(overview);
-
- // create actions
- IToolBarManager tbm = getSite().getActionBars().getToolBarManager();
- showOutlineAction = new Action() {
- public void run() {
- showPage(outline);
- }
- };
- showOutlineAction.setImageDescriptor(EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/Pageflow_Outline.gif")); //$NON-NLS-1$
- tbm.add(showOutlineAction);
- showOverviewAction = new Action() {
- public void run() {
- showPage(overview);
- }
- };
- showOverviewAction.setImageDescriptor(EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/Pageflow_Outline_Overview.gif")); //$NON-NLS-1$
- tbm.add(showOverviewAction);
-
- // initialize outline page
- initializeOutlineViewer();
-
- // initialize overview
- initializeOverview();
-
- // initialize pagebook
- showPage(outline);
- }
-
- /**
- * Configures the outline viewer
- */
- private void initializeOutlineViewer() {
- if (null != getEditDomain()) {
- getEditDomain().addViewer(getTreeViewer());
- }
- // getTreeViewer().setEditPartFactory(new PageflowTreePartFactory());
-
- // synchronize selections
- editor.getSelectionSynchronizer().addViewer(getTreeViewer());
-
- // add content
- getTreeViewer().setContents(getOutlineContent());
- }
-
- /**
- * Shows the spcified page.
- *
- * @param id -
- * control id of pagebook in outline page. it is can be _outline
- * or _overview
- */
- protected void showPage(Control id) {
- if (id == outline) {
- showOutlineAction.setChecked(true);
- showOverviewAction.setChecked(false);
- pageBook.showPage(outline);
- if (thumbnail != null) {
- thumbnail.setVisible(false);
- }
- } else if (id == overview) {
- showOutlineAction.setChecked(false);
- showOverviewAction.setChecked(true);
- pageBook.showPage(overview);
- if (thumbnail != null) {
- thumbnail.setVisible(true);
- }
- }
- }
-
- /**
- * Returns the current edit domain.
- *
- * @return - the edit domain
- */
- public EditDomain getEditDomain() {
- return editDomain;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPage#dispose()
- */
- public void dispose() {
- editor.getSelectionSynchronizer().removeViewer(getTreeViewer());
-
- if (null != thumbnail) {
- thumbnail.deactivate();
- }
-
- super.dispose();
- }
-
- /**
- * initialize Overview.
- *
- */
- private void initializeOverview() {
- // check if control was created
- if (null == lws) {
- return;
- }
-
- // deactivate old thumbnail
- if (null != thumbnail) {
- thumbnail.deactivate();
- }
-
- // create empty thumbnail
- thumbnail = new ScrollableThumbnail();
- thumbnail.setBorder(new MarginBorder(3));
- lws.setContents(thumbnail);
-
- // initialize thumbnail
- if (null != getOverviewContent()) {
- Viewport viewport = null;
- IFigure source = null;
- if (getOverviewContent() instanceof ScalableFreeformRootEditPart) {
- viewport = (Viewport) ((ScalableFreeformRootEditPart) getOverviewContent())
- .getFigure();
- source = ((ScalableFreeformRootEditPart) getOverviewContent())
- .getLayer(LayerConstants.PRINTABLE_LAYERS);
- }
- if (getOverviewContent() instanceof ScalableRootEditPart) {
- viewport = (Viewport) ((ScalableRootEditPart) getOverviewContent())
- .getFigure();
- source = ((ScalableRootEditPart) getOverviewContent())
- .getLayer(LayerConstants.PRINTABLE_LAYERS);
- }
-
- if (null != viewport && null != source) {
- thumbnail.setViewport(viewport);
- thumbnail.setSource(source);
- }
- }
- }
-
- /**
- * Returns the outlineContent.
- *
- * @return - the outlineContent
- */
- public PageflowElement getOutlineContent() {
- return outlineContent;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPage#getControl()
- */
- public Control getControl() {
- return pageBook;
- }
-
- /**
- * Returns the root edit part
- *
- * @return - the root edit part
- */
- public RootEditPart getOverviewContent() {
- return overviewContent;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return getTreeViewer().getSelection();
- }
-
- /**
- * Returns the tree viewer.
- *
- * @return - the tree viewer
- */
- public TreeViewer getTreeViewer() {
- if (null == treeViewer) {
- treeViewer = new TreeViewer();
- treeViewer.setEditPartFactory(new PageflowTreePartFactory());
- }
-
- return treeViewer;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISelectionProvider#removeSelectionChangedListener(ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- getTreeViewer().removeSelectionChangedListener(listener);
- }
-
- /**
- * Sets the outlineContent.
- *
- * @param element -
- * Pageflow Element
- */
- public void setOutlineContent(PageflowElement element) {
- if (outlineContent != element) {
- outlineContent = element;
-
- // refresh viewer
- if (null != getTreeViewer().getControl()) {
- getTreeViewer().setContents(element);
-
- // bugfix: something is overwriting visibility
- if (null != pageBook) {
- if (showOverviewAction.isChecked()) {
- showPage(outline);
- showPage(overview);
- } else {
- showPage(outline);
- }
- }
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPage#setFocus()
- */
- public void setFocus() {
- if (getControl() != null) {
- getControl().setFocus();
- }
- }
-
- /**
- * Sets the root edit part.
- *
- * @param part -
- * root edit part for pageflow model
- */
- public void setOverviewContent(RootEditPart part) {
- if (overviewContent != part) {
- overviewContent = part;
- // reinitialize thumbnail
- // if (null != thumbnail && thumbnail.isVisible())
- initializeOverview();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISelectionProvider#setSelection(ISelection)
- */
- public void setSelection(ISelection selection) {
- getTreeViewer().setSelection(selection);
- }
-
- /**
- * Initializes this outline page from a given editor page.
- *
- * @param newPage -
- * Pageflow EditorPage
- */
- public void initialize(PageflowEditor newPage) {
- if (null != newPage.getGraphicalViewer()) {
- setOverviewContent(newPage.getGraphicalViewer().getRootEditPart());
- EditPart currentContent = newPage.getGraphicalViewer()
- .getContents();
- setOutlineContent(null != currentContent ? (PageflowElement) currentContent
- .getModel()
- : null);
- setEditDomain(newPage.getEditDomain());
- getViewerContentListener().setViewer(newPage.getGraphicalViewer());
- } else {
- setOverviewContent(null);
- setOutlineContent(null);
- setEditDomain(null);
- }
- }
-
- /**
- * Sets the edit domain.
- *
- * @param domain -
- * editor's edit domain
- */
- public void setEditDomain(EditDomain domain) {
- if (editDomain != domain) {
- // refresh viewer
- if (null != getTreeViewer()) {
- if (null != editDomain) {
- editDomain.removeViewer(getTreeViewer());
- }
- if (null != domain) {
- domain.addViewer(getTreeViewer());
- }
- }
- editDomain = domain;
- }
- }
-
- /**
- * the current viewer content listener
- */
- private final ViewerContentListener viewerContentListener = new ViewerContentListener();
-
- /**
- * This class listens for changes of the content of an EditPartViewer. If
- * the content changed, it will update the outline viewer.
- * <p>
- * Important: this class has to be disposed with
- * <code>setViewer(null)</code>.
- *
- * @author Gunnar Wagenknecht
- */
- private class ViewerContentListener implements EditPartListener {
- /* the viewer */
- private EditPartViewer _viewer;
-
- /**
- * Sets a new viewer. <code>null</code> is allowed to dispose.
- *
- * @param viewer
- */
- public void setViewer(EditPartViewer viewer) {
- if (null != this._viewer)
- this._viewer.getRootEditPart().removeEditPartListener(this);
-
- this._viewer = viewer;
-
- if (null != this._viewer)
- this._viewer.getRootEditPart().addEditPartListener(this);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.EditPartListener#childAdded(org.eclipse.gef.EditPart,
- * int)
- */
- public void childAdded(EditPart child, int index) {
- // this is out event, update the viewers
- if (child.getModel() instanceof PageflowElement)
- setOutlineContent((PageflowElement) child.getModel());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.EditPartListener#partActivated(org.eclipse.gef.EditPart)
- */
- public void partActivated(EditPart editpart) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.EditPartListener#partDeactivated(org.eclipse.gef.EditPart)
- */
- public void partDeactivated(EditPart editpart) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.EditPartListener#removingChild(org.eclipse.gef.EditPart,
- * int)
- */
- public void removingChild(EditPart child, int index) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.EditPartListener#selectedStateChanged(org.eclipse.gef.EditPart)
- */
- public void selectedStateChanged(EditPart editpart) {
- // do nothing
- }
- }
-
- /**
- * Returns the viewer content listener.
- *
- * @return the viewer content listener
- */
- private ViewerContentListener getViewerContentListener() {
- return viewerContentListener;
- }
-
- /**
- * Configures the specified <code>EditPartViewer</code>.
- *
- * @param viewer
- */
- protected void configureEditPartViewer(EditPartViewer viewer) {
- // configure the shared key handler
- if (viewer.getKeyHandler() != null) {
- viewer.getKeyHandler().setParent(editor.getSharedKeyHandler());
- }
-
- // configure the context menu
- ContextMenuProvider provider = new PageflowEditorContextMenuProvider(
- viewer, editor.getActionRegistry());
- viewer.setContextMenu(provider);
- getSite().registerContextMenu(
- EditorPlugin.getPluginId()
- + ".pageflow.editor.outlineview.contextmenu", provider, //$NON-NLS-1$
- getSite().getSelectionProvider());
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.java
deleted file mode 100644
index a64b442d9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.java
+++ /dev/null
@@ -1,483 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Pageflow message bundle
- *
- */
-public final class PageflowMessages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages"; //$NON-NLS-1$
-
- private PageflowMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, PageflowMessages.class);
- }
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Label_True;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Label_False;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Label_Saving;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Dialog_Label_CreateFileTitle;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Dialog_Label_FileNotExistedPart1;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Dialog_Label_FileNotExistedPart2;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_OpenEditor_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_OpenEditor_ToolTip;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_ShowPropertyView_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_ShowPropertyView_ToolTip;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_ShowPaletteView_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_ShowPaletteView_ToolTip;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_SyncWithFacesConfig_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_SyncWithFacesConfig_ToolTip;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_UpdateFacesConfig_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Action_UpdateFacesConfig_ToolTip;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Group_Controls;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Select_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Select_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Marquee_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Marquee_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Link_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Link_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Group_Nodes;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Begin_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Begin_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_End_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_End_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Action_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Action_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Page_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_PaletteTool_Page_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Contextmenu_Align_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Contextmenu_ShowView_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_AddNodeCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_CreateNodeCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_DeleteNodeCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_ConnectionCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_CreateBendpointCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_MoveBendpointCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_DeleteBendpointCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_OpenEditorCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_OrphanChildCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_UpdatePageflowCommand_Label;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Title;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Description;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_comment;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_name;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_largeicon;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_smallicon;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_action;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_path;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_begin;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_end;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_configfile;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_source;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_target;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_outcome;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_redirect;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_fromaction;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Attributes_referenceLink;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Items_Pageflow;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Items_PFPage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Model_Items_PFLink;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_Choice;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_Title;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_JSPName;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Title;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTableWithJSP_Title;
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Component;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowLinkPropertySource_Title;
- /**
- * see PageFlowMessages.properties
- */
- public static String ProjectWebPageSelectionDialog_Description;
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowLinkPropertySource_Text;
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Action;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Property_Action_OutcomeSelectionDialog_Outcome;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_UndefinedOutcome;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_NotExistedSourcePage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_MissingSourcePage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_InvalidWebPage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_NotExitedWebPage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_MissingWebPage;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_MissingManagedBean;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String Pageflow_Validation_MissingAction;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String ExistingPagePathDialogCellEdito_LabelText;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowLinkEditPart_FromAction;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowLinkEditPart_FromOutcome;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowContainerEditPolicy_OrphanLabel;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowNode_NoRecursiveContainment;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String PageflowXYLayoutEditPolicy_Add;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String SetConstraintCommand_Resize;
-
- /**
- * see PageFlowMessages.properties
- */
- public static String SetConstraintCommand_Location;
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.properties
deleted file mode 100644
index 29b93615d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowMessages.properties
+++ /dev/null
@@ -1,155 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-####################################################
-# Generic Strings for UI
-####################################################
-Pageflow_Label_True=true
-Pageflow_Label_False=false
-
-Pageflow_Label_Saving=Saving
-
-Pageflow_Dialog_Label_CreateFileTitle=Create File
-Pageflow_Dialog_Label_FileNotExistedPart1=The file
-Pageflow_Dialog_Label_FileNotExistedPart2=doesn't exist. Click OK to create it.
-
-####################################################
-# Generic Strings for Action and PaletteTool
-####################################################
-Pageflow_Action_OpenEditor_Label=Open
-Pageflow_Action_OpenEditor_ToolTip=Open Page or Action component
-
-Pageflow_Action_ShowPropertyView_Label=Properties
-Pageflow_Action_ShowPropertyView_ToolTip=Show Properties View
-
-Pageflow_Action_ShowPaletteView_Label=Palette
-Pageflow_Action_ShowPaletteView_ToolTip=Show Palette View
-
-Pageflow_Action_SyncWithFacesConfig_Label=Synchronize with Faces-config
-Pageflow_Action_SyncWithFacesConfig_ToolTip=Synchronizing PageFlow Model with Faces-config
-
-Pageflow_Action_UpdateFacesConfig_Label=Update Faces-config
-Pageflow_Action_UpdateFacesConfig_ToolTip=Update Faces-config File from The Current PageFlow
-
-Pageflow_PaletteTool_Group_Controls=Controls
-
-Pageflow_PaletteTool_Select_Label=Select
-Pageflow_PaletteTool_Select_Description=Select One or More Items
-
-Pageflow_PaletteTool_Marquee_Label=Marquee
-Pageflow_PaletteTool_Marquee_Description=Marquee One or More Items
-
-Pageflow_PaletteTool_Link_Label=Link
-Pageflow_PaletteTool_Link_Description=Creates a Link
-
-Pageflow_PaletteTool_Group_Nodes=Nodes
-
-Pageflow_PaletteTool_Begin_Label=Begin
-Pageflow_PaletteTool_Begin_Description=Creates a PageFlow Begin
-
-Pageflow_PaletteTool_End_Label=End
-Pageflow_PaletteTool_End_Description=Creates a PageFlow End
-
-Pageflow_PaletteTool_Action_Label=Action
-Pageflow_PaletteTool_Action_Description=Creates a PageFlow Action
-
-Pageflow_PaletteTool_Page_Label=Page
-Pageflow_PaletteTool_Page_Description=Creates a PageFlow Page
-
-Pageflow_Contextmenu_Align_Label=Align
-
-Pageflow_Contextmenu_ShowView_Label=Show View
-
-
-
-####################################################
-# Generic Strings for Commands
-####################################################
-Pageflow_Commands_AddNodeCommand_Label=Add
-Pageflow_Commands_CreateNodeCommand_Label=Create
-Pageflow_Commands_DeleteNodeCommand_Label=Delete
-
-Pageflow_Commands_ConnectionCommand_Label=Connection
-Pageflow_Commands_CreateBendpointCommand_Label=Create Bendpoint
-Pageflow_Commands_MoveBendpointCommand_Label=Move Bendpoint
-Pageflow_Commands_DeleteBendpointCommand_Label=Delete Bendpoint
-
-Pageflow_Commands_OpenEditorCommand_Label=Open
-Pageflow_Commands_OrphanChildCommand_Label=Orphan Child
-Pageflow_Commands_UpdatePageflowCommand_Label=Update Pageflow
-
-Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Title=Select JSP File
-Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Description=Please select a jsp file.
-
-####################################################
-# Generic Strings for property attribute name
-####################################################
-Pageflow_Model_Attributes_comment=description
-Pageflow_Model_Attributes_name=display-name
-Pageflow_Model_Attributes_largeicon=large-icon
-Pageflow_Model_Attributes_smallicon=small-icon
-
-Pageflow_Model_Attributes_action=from-action
-Pageflow_Model_Attributes_path=path
-Pageflow_Model_Attributes_begin=begin
-Pageflow_Model_Attributes_end=end
-Pageflow_Model_Attributes_configfile=config file
-
-Pageflow_Model_Attributes_source = from-view-id
-Pageflow_Model_Attributes_target = to-view-id
-
-Pageflow_Model_Attributes_outcome=from-outcome
-Pageflow_Model_Attributes_redirect=redirect
-
-Pageflow_Model_Attributes_fromaction=from-action
-Pageflow_Model_Attributes_referenceLink=reference
-
-Pageflow_Model_Items_Pageflow=File
-Pageflow_Model_Items_PFPage=Page
-Pageflow_Model_Items_PFLink=Link
-
-
-Pageflow_Property_Action_OutcomeSelectionDialog_Choice=Enter the outcome or select one from action list below:
-
-Pageflow_Property_Action_OutcomeSelectionDialog_Title=Outcome Selection
-Pageflow_Property_Action_OutcomeSelectionDialog_JSPName=JSP File Name:
-Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Title=Actions
-Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTableWithJSP_Title=Actions in {0}
-Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Component=Component ID
-Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Action=Action
-
-Pageflow_Property_Action_OutcomeSelectionDialog_Outcome=Outcome:
-
-####################################################
-#Pageflow validation
-####################################################
-Pageflow_Validation_UndefinedOutcome=The outcome \''{0}\'' is not defined in previous page \''{1}\''.
-Pageflow_Validation_NotExistedSourcePage=The source page \''{0}\'' is not existed.
-Pageflow_Validation_MissingSourcePage=The source page should be specified.
-
-Pageflow_Validation_InvalidWebPage=The file \''{0}\'' is not valid web file.
-Pageflow_Validation_NotExitedWebPage=The web page \''{0}\'' is not existed.
-Pageflow_Validation_MissingWebPage=The web page's path should be specified.
-
-Pageflow_Validation_MissingManagedBean=The managed bean \''{0}\'' is not defined.
-Pageflow_Validation_MissingAction=The action should be specified.
-
-ExistingPagePathDialogCellEdito_LabelText = Please enter or select a web page path:
-
-PageflowLinkEditPart_FromAction=fromAction:
-PageflowLinkEditPart_FromOutcome=fromOutcome:
-
-#######################################################
-PageflowContainerEditPolicy_OrphanLabel=label here
-PageflowNode_NoRecursiveContainment=Recursive containment not allowed for
-PageflowXYLayoutEditPolicy_Add=Add
-SetConstraintCommand_Location=Change Page Location
-SetConstraintCommand_Resize=Resize Page
-ProjectWebPageSelectionDialog_Description=Please select a Web Page
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowPaletteRoot.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowPaletteRoot.java
deleted file mode 100644
index eefad9294..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowPaletteRoot.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.gef.palette.CombinedTemplateCreationEntry;
-import org.eclipse.gef.palette.ConnectionCreationToolEntry;
-import org.eclipse.gef.palette.MarqueeToolEntry;
-import org.eclipse.gef.palette.PaletteDrawer;
-import org.eclipse.gef.palette.PaletteGroup;
-import org.eclipse.gef.palette.PaletteRoot;
-import org.eclipse.gef.palette.PaletteSeparator;
-import org.eclipse.gef.palette.SelectionToolEntry;
-import org.eclipse.gef.palette.ToolEntry;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.ModelCreationFactory;
-
-/**
- * This is the root of the palette used by pageflow editors.
- */
-public class PageflowPaletteRoot extends PaletteRoot {
-
- /**
- * Creates a new PageflowPaletteRoot instance.
- */
- public PageflowPaletteRoot() {
- // create root
- super();
-
- // a group of default control tools
- // Pageflow.PaletteTool.Group.Controls = Controls
- PaletteGroup controls = new PaletteGroup(
- PageflowMessages.Pageflow_PaletteTool_Group_Controls);
- add(controls);
-
- // the selection tool
- // Pageflow.PaletteTool.Select.Label = Select
- // Pageflow.PaletteTool.Select.Description = Select one or more items
- ToolEntry tool = new SelectionToolEntry(
- PageflowMessages.Pageflow_PaletteTool_Select_Label,
- PageflowMessages.Pageflow_PaletteTool_Select_Description);
-
- controls.add(tool);
-
- // use selection tool as default entry
- setDefaultEntry(tool);
-
- // the marquee selection tool
- // Pageflow.PaletteTool.Marquee.Label = Marquee
- // Pageflow.PaletteTool.Marquee.Description = Marquee one or more items
- controls.add(new MarqueeToolEntry(
- PageflowMessages.Pageflow_PaletteTool_Marquee_Label,
- PageflowMessages.Pageflow_PaletteTool_Marquee_Description));
-
- controls.add(new PaletteSeparator());
-
- // conection creation
- // Pageflow.PaletteTool.Link.Label = Link
- // Pageflow.PaletteTool.Link.Description = Creates an link
- ConnectionCreationToolEntry linkEntry = new ConnectionCreationToolEntry(
- PageflowMessages.Pageflow_PaletteTool_Link_Label,
- PageflowMessages.Pageflow_PaletteTool_Link_Description,
- new ModelCreationFactory(PageflowLink.class), EditorPlugin
- .getDefault().getImageDescriptor(
- "facesconfig/Pageflow_Link.gif"), //$NON-NLS-1$
- EditorPlugin.getDefault().getImageDescriptor(
- "facesconfig/Pageflow_Link24.gif")); //$NON-NLS-1$
- linkEntry.setUserModificationPermission(PERMISSION_FULL_MODIFICATION);
- controls.add(linkEntry);
-
- controls.add(new PaletteSeparator());
-
- // Pageflow.PaletteTool.Group.Nodes = Nodes
- PaletteDrawer nodes = new PaletteDrawer(
- PageflowMessages.Pageflow_PaletteTool_Group_Nodes);
- add(nodes);
-
- // use CombinedTemplateCreationEntry which can be also dragged
- CombinedTemplateCreationEntry entry;
-
- // Pageflow.PaletteTool.Page.Label = Page
- // Pageflow.PaletteTool.Page.Description = Creates a pageflow page
- entry = new CombinedTemplateCreationEntry(
- PageflowMessages.Pageflow_PaletteTool_Page_Label,
- PageflowMessages.Pageflow_PaletteTool_Page_Description,
- PageflowPage.class,
- new ModelCreationFactory(PageflowPage.class), EditorPlugin
- .getDefault().getImageDescriptor(
- "facesconfig/Pageflow_Page16.gif"), //$NON-NLS-1$
- EditorPlugin.getDefault().getImageDescriptor(
- "facesconfig/Pageflow_Page24.gif")); //$NON-NLS-1$
- nodes.add(entry);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowTemplateTransferDropTargetListener.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowTemplateTransferDropTargetListener.java
deleted file mode 100644
index 4c4a8a4df..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/PageflowTemplateTransferDropTargetListener.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.dnd.TemplateTransferDropTargetListener;
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.ModelCreationFactory;
-
-/**
- * This is the drop listener for template transfers from the palette. Only need
- * to implement the <code>getFactory</code> method.
- */
-public class PageflowTemplateTransferDropTargetListener extends
- TemplateTransferDropTargetListener {
- /**
- * Creates a new PageflowTemplateTransferDropTargetListener instance.
- *
- * @param viewer -
- * target pageflow editor view.
- */
- public PageflowTemplateTransferDropTargetListener(EditPartViewer viewer) {
- super(viewer);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see TemplateTransferDropTargetListener#getFactory(Object)
- */
- protected CreationFactory getFactory(Object template) {
- if (template instanceof Class) {
- return new ModelCreationFactory((Class) template);
- }
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/ResourceTransferDropTargetListener.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/ResourceTransferDropTargetListener.java
deleted file mode 100644
index ecb6c73be..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/ResourceTransferDropTargetListener.java
+++ /dev/null
@@ -1,212 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartViewer;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.dnd.AbstractTransferDropTargetListener;
-import org.eclipse.gef.requests.CreateRequest;
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.dnd.DND;
-import org.eclipse.swt.dnd.DropTargetEvent;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.part.FileEditorInput;
-import org.eclipse.ui.part.ResourceTransfer;
-import org.eclipse.ui.views.navigator.LocalSelectionTransfer;
-
-/**
- * This is the listener for resource drag and drop operations
- *
- */
-public abstract class ResourceTransferDropTargetListener extends
- AbstractTransferDropTargetListener {
- /** the pageflow editor */
- private IEditorPart editor = null;
-
- /**
- * Creates a new ResourceTransferDropTargetListener instance.
- *
- * @param viewer -
- * target pageflow editor view.
- * @param editor
- */
- public ResourceTransferDropTargetListener(EditPartViewer viewer,
- IEditorPart editor) {
- super(viewer, ResourceTransfer.getInstance());
-
- this.editor = editor;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#createTargetRequest()
- */
- protected Request createTargetRequest() {
- CreateRequest request = new CreateRequest();
- if (getCurrentEvent().data == null) {
- request.setFactory(getFactory(null));
- } else {
- IResource[] resources = (IResource[]) getCurrentEvent().data;
- request.setFactory(getFactory(resources[0]));
- }
- return request;
- }
-
- /**
- * get the request for creating a new resource object
- *
- * @return - creation request
- */
- protected final CreateRequest getCreateRequest() {
- return (CreateRequest) getTargetRequest();
- }
-
- /**
- * get creation factory for resource object, which should be implemented.
- *
- * @param obj -
- * resource object
- * @return - creation factory for resource object
- */
- abstract protected CreationFactory getFactory(Object obj);
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#handleDragOperationChanged()
- */
- protected void handleDragOperationChanged() {
- getCurrentEvent().detail = DND.DROP_COPY;
- super.handleDragOperationChanged();
- }
-
- /**
- * get the current transfered local selection object.
- *
- * @return
- */
- private Object getCurrentLocalObject() {
- ISelection sel = LocalSelectionTransfer.getInstance().getSelection();
- if (sel instanceof IStructuredSelection) {
- return ((IStructuredSelection) sel).getFirstElement();
- }
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#handleDragOver()
- */
- protected void handleDragOver() {
- if (!isValidJSFFile(getCurrentLocalObject())) {
- getCurrentEvent().detail = DND.ERROR_INVALID_DATA;
- } else {
- getCurrentEvent().detail = DND.DROP_COPY;
- }
- getCurrentEvent().feedback = DND.FEEDBACK_SCROLL | DND.FEEDBACK_EXPAND;
- super.handleDragOver();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#handleDrop()
- */
- protected void handleDrop() {
- getCurrentEvent().detail = DND.DROP_COPY;
- super.handleDrop();
- // because the handle drop can change this event to DND.DROP_NONE
- if (getCurrentEvent().detail == DND.DROP_COPY) {
- selectAddedObject();
- }
- }
-
- /**
- * select the new drag and drop object in the pageflow view.
- */
- private void selectAddedObject() {
- Object model = getCreateRequest().getNewObject();
- if (null == model) {
- return;
- }
- EditPartViewer viewer = getViewer();
- Object editpart = viewer.getEditPartRegistry().get(model);
- if (editpart instanceof EditPart) {
- viewer.flush();
- viewer.select((EditPart) editpart);
- // Activate the editor window
- PlatformUI.getWorkbench().getActiveWorkbenchWindow()
- .getActivePage().activate(editor);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#updateTargetRequest()
- */
- protected void updateTargetRequest() {
- CreateRequest request = getCreateRequest();
- request.setLocation(getDropLocation());
- }
-
- /**
- * Allow drop if any of these types in the drop data, which can be jsp file
- * or a sub folder of the webroot folder.
- *
- */
- private boolean isValidJSFFile(Object resource) {
- if (resource == null || !(resource instanceof IResource)) {
- return false;
- }
-
- if (((IResource) resource).getProject() == ((FileEditorInput) editor
- .getEditorInput()).getFile().getProject()) {
- if (WebrootUtil.getWebPath(((IResource) resource).getFullPath())
- .length() > 0) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTransferDropTargetListener#isEnabled()
- */
- public boolean isEnabled(DropTargetEvent dropTargetEvent) {
- if (super.isEnabled(dropTargetEvent)) {
- if (dropTargetEvent.data != null) {
- IResource[] resources = (IResource[]) dropTargetEvent.data;
- // The resource should be under the same project of the current
- // faces-config file
- if (isValidJSFFile(resources[0])) {
- return true;
- }
- return false;
- }
- // If no data, can't verify, so allow the drop
- return true;
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/AlignmentAction.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/AlignmentAction.java
deleted file mode 100644
index e108d8e55..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/AlignmentAction.java
+++ /dev/null
@@ -1,329 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.action;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.geometry.PrecisionRectangle;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.RequestConstants;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CompoundCommand;
-import org.eclipse.gef.requests.AlignmentRequest;
-import org.eclipse.gef.tools.ToolUtilities;
-import org.eclipse.gef.ui.actions.GEFActionConstants;
-import org.eclipse.gef.ui.actions.SelectionAction;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPart;
-
-/**
- * An improved alignment action to align the selected parts in different action.
- *
- * @author xgzhang
- * @version original version is from GEF
- */
-public final class AlignmentAction extends SelectionAction {
-
- /**
- * Indicates that the bottom edges should be aligned.
- */
- public static final String ID_ALIGN_BOTTOM = GEFActionConstants.ALIGN_BOTTOM;
-
- /**
- * Indicates that the horizontal centers should be aligned.
- */
- public static final String ID_ALIGN_CENTER = GEFActionConstants.ALIGN_CENTER;
-
- /**
- * Indicates that the left edges should be aligned.
- */
- public static final String ID_ALIGN_LEFT = GEFActionConstants.ALIGN_LEFT;
-
- /**
- * Indicates that the vertical midpoints should be aligned.
- */
- public static final String ID_ALIGN_MIDDLE = GEFActionConstants.ALIGN_MIDDLE;
-
- /**
- * Indicates that the right edges should be aligned.
- */
- public static final String ID_ALIGN_RIGHT = GEFActionConstants.ALIGN_RIGHT;
-
- /**
- * Indicates that the top edges should be aligned.
- */
- public static final String ID_ALIGN_TOP = GEFActionConstants.ALIGN_TOP;
-
- private int alignment;
-
- private List operationSet;
-
- /**
- * @deprecated use AlignmentAction(IWorkbenchPart, int align)
- * @param editor
- * the editor
- * @param align
- * the alignment ID
- */
- public AlignmentAction(IEditorPart editor, int align) {
- this((IWorkbenchPart) editor, align);
- }
-
- /**
- * Constructs an AlignmentAction with the given part and alignment ID. The
- * alignment ID must by one of:
- * <UL>
- * <LI>GEFActionConstants.ALIGN_LEFT
- * <LI>GEFActionConstants.ALIGN_RIGHT
- * <LI>GEFActionConstants.ALIGN_CENTER
- * <LI>GEFActionConstants.ALIGN_TOP
- * <LI>GEFActionConstants.ALIGN_BOTTOM
- * <LI>GEFActionConstants.ALIGN_MIDDLE
- * </UL>
- *
- * @param part
- * the workbench part used to obtain context
- * @param align
- * the aligment ID.
- */
- public AlignmentAction(IWorkbenchPart part, int align) {
- super(part);
- alignment = align;
- initUI();
- }
-
- /**
- * Returns the alignment rectangle to which all selected parts should be
- * aligned.
- *
- * @param request
- * the alignment Request
- * @return the alignment rectangle
- */
- protected Rectangle calculateAlignmentRectangle(Request request) {
- List editparts = getOperationSet(request);
- if (editparts == null || editparts.isEmpty()) {
- return null;
- }
- GraphicalEditPart part = null;
- if (alignment == PositionConstants.MIDDLE
- || alignment == PositionConstants.CENTER) {
- part = (GraphicalEditPart) editparts.get(editparts.size() - 1);
- } else {
- part = getFitnessPart(editparts);
- }
- Rectangle rect = new PrecisionRectangle(part.getFigure().getBounds());
- part.getFigure().translateToAbsolute(rect);
- return rect;
- }
-
- /**
- * get the Fitness part in the four kinds of alignment directions
- *
- * @param editparts
- */
- private GraphicalEditPart getFitnessPart(List editparts) {
- if (alignment == PositionConstants.MIDDLE
- || alignment == PositionConstants.CENTER) {
- return null;
- }
-
- int positionComparor = Integer.MAX_VALUE;
-
- if (alignment == PositionConstants.LEFT
- || alignment == PositionConstants.TOP) {
- positionComparor = Integer.MAX_VALUE;
- } else if (alignment == PositionConstants.RIGHT
- || alignment == PositionConstants.BOTTOM) {
- positionComparor = Integer.MIN_VALUE;
- }
-
- GraphicalEditPart fitnessPart = null;
-
- for (Iterator iter = editparts.iterator(); iter.hasNext();) {
- GraphicalEditPart part = (GraphicalEditPart) iter.next();
- Rectangle rectPart = part.getFigure().getBounds();
- switch (alignment) {
- case PositionConstants.LEFT:
- if (rectPart.getLeft().x < positionComparor) {
- fitnessPart = part;
- positionComparor = rectPart.getLeft().x;
- }
- break;
-
- case PositionConstants.RIGHT:
- if (rectPart.getRight().x > positionComparor) {
- fitnessPart = part;
- positionComparor = rectPart.getRight().x;
- }
- break;
- case PositionConstants.TOP:
- if (rectPart.getTop().y < positionComparor) {
- fitnessPart = part;
- positionComparor = rectPart.getTop().y;
- }
- break;
- case PositionConstants.BOTTOM:
- if (rectPart.getBottom().y > positionComparor) {
- fitnessPart = part;
- positionComparor = rectPart.getBottom().y;
- }
- break;
- }
- }
-
- return fitnessPart;
- }
-
- /**
- * @see org.eclipse.gef.ui.actions.WorkbenchPartAction#calculateEnabled()
- */
- protected boolean calculateEnabled() {
- operationSet = null;
- Command cmd = createAlignmentCommand();
- if (cmd == null) {
- return false;
- }
- return cmd.canExecute();
- }
-
- private Command createAlignmentCommand() {
- AlignmentRequest request = new AlignmentRequest(
- RequestConstants.REQ_ALIGN);
- request.setAlignmentRectangle(calculateAlignmentRectangle(request));
- request.setAlignment(alignment);
- List editparts = getOperationSet(request);
- if (editparts.size() < 2) {
- return null;
- }
-
- CompoundCommand command = new CompoundCommand();
- command.setDebugLabel(getText());
- for (int i = 0; i < editparts.size(); i++) {
- EditPart editpart = (EditPart) editparts.get(i);
- command.add(editpart.getCommand(request));
- }
- return command;
- }
-
- /**
- * @see org.eclipse.gef.Disposable#dispose()
- */
- public void dispose() {
- operationSet = Collections.EMPTY_LIST;
- super.dispose();
- }
-
- /**
- * Returns the list of editparts which will participate in alignment.
- *
- * @param request
- * the alignment request
- * @return the list of parts which will be aligned
- */
- protected List getOperationSet(Request request) {
- if (operationSet != null) {
- return operationSet;
- }
- List editparts = new ArrayList(getSelectedObjects());
- if (editparts.isEmpty()
- || !(editparts.get(0) instanceof GraphicalEditPart)) {
- return Collections.EMPTY_LIST;
- }
- Object primary = editparts.get(editparts.size() - 1);
- editparts = ToolUtilities.getSelectionWithoutDependants(editparts);
- ToolUtilities.filterEditPartsUnderstanding(editparts, request);
- if (editparts.size() < 2 || !editparts.contains(primary)) {
- return Collections.EMPTY_LIST;
- }
- EditPart parent = ((EditPart) editparts.get(0)).getParent();
- for (int i = 1; i < editparts.size(); i++) {
- EditPart part = (EditPart) editparts.get(i);
- if (part.getParent() != parent) {
- return Collections.EMPTY_LIST;
- }
- }
- return editparts;
- }
-
- /**
- * Initializes the actions UI presentation.
- */
- protected void initUI() {
- switch (alignment) {
- case PositionConstants.LEFT:
- setId(GEFActionConstants.ALIGN_LEFT);
- setText(EditorMessages.AlignmentAction_AlignLeftAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignLeftAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_HORZ_ALIGN_LEFT);
- setDisabledImageDescriptor(InternalImages.DESC_HORZ_ALIGN_LEFT_DIS);
- break;
-
- case PositionConstants.RIGHT:
- setId(GEFActionConstants.ALIGN_RIGHT);
- setText(EditorMessages.AlignmentAction_AlignRightAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignRightAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_HORZ_ALIGN_RIGHT);
- setDisabledImageDescriptor(InternalImages.DESC_HORZ_ALIGN_RIGHT_DIS);
- break;
-
- case PositionConstants.TOP:
- setId(GEFActionConstants.ALIGN_TOP);
- setText(EditorMessages.AlignmentAction_AlignTopAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignTopAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_VERT_ALIGN_TOP);
- setDisabledImageDescriptor(InternalImages.DESC_VERT_ALIGN_TOP_DIS);
- break;
-
- case PositionConstants.BOTTOM:
- setId(GEFActionConstants.ALIGN_BOTTOM);
- setText(EditorMessages.AlignmentAction_AlignBottomAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignBottomAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_VERT_ALIGN_BOTTOM);
- setDisabledImageDescriptor(InternalImages.DESC_VERT_ALIGN_BOTTOM_DIS);
- break;
-
- case PositionConstants.CENTER:
- setId(GEFActionConstants.ALIGN_CENTER);
- setText(EditorMessages.AlignmentAction_AlignCenterAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignCenterAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_HORZ_ALIGN_CENTER);
- setDisabledImageDescriptor(InternalImages.DESC_HORZ_ALIGN_CENTER_DIS);
- break;
-
- case PositionConstants.MIDDLE:
- setId(GEFActionConstants.ALIGN_MIDDLE);
- setText(EditorMessages.AlignmentAction_AlignMiddleAction_Label);
- setToolTipText(EditorMessages.AlignmentAction_AlignMiddleAction_Tooltip);
- setImageDescriptor(InternalImages.DESC_VERT_ALIGN_MIDDLE);
- setDisabledImageDescriptor(InternalImages.DESC_VERT_ALIGN_MIDDLE_DIS);
- break;
- }
- }
-
- /**
- * @see org.eclipse.jface.action.IAction#run()
- */
- public void run() {
- operationSet = null;
- execute(createAlignmentCommand());
- }
-
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/InternalImages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/InternalImages.java
deleted file mode 100644
index 8daa9ba7a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/InternalImages.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 Oracle Corporation.
- * 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:
- * Ian Trimble - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.action;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-
-/**
- * Supplies image descriptors, intended for internal use only.
- *
- * @author Ian Trimble - Oracle
- */
-public class InternalImages {
-
- /**
- * ImageDescriptor instance for center alignment image.
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_CENTER;
-
- /**
- * ImageDescriptor instance for left alignment image.
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_LEFT;
-
- /**
- * ImageDescriptor instance for right alignment image.
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_RIGHT;
-
- /**
- * ImageDescriptor instance for middle alignment image.
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_MIDDLE;
-
- /**
- * ImageDescriptor instance for top alignment image.
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_TOP;
-
- /**
- * ImageDescriptor instance for bottom alignment image.
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_BOTTOM;
-
- /**
- * ImageDescriptor instance for center alignment image (disabled).
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_CENTER_DIS;
-
- /**
- * ImageDescriptor instance for left alignment image (disabled).
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_LEFT_DIS;
-
- /**
- * ImageDescriptor instance for right alignment image (disabled).
- */
- public static final ImageDescriptor DESC_HORZ_ALIGN_RIGHT_DIS;
-
- /**
- * ImageDescriptor instance for middle alignment image (disabled).
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_MIDDLE_DIS;
-
- /**
- * ImageDescriptor instance for top alignment image (disabled).
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_TOP_DIS;
-
- /**
- * ImageDescriptor instance for bottom alignment image (disabled).
- */
- public static final ImageDescriptor DESC_VERT_ALIGN_BOTTOM_DIS;
-
- static {
- DESC_VERT_ALIGN_BOTTOM = createDescriptor("icons/alignbottom.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_CENTER = createDescriptor("icons/aligncenter.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_LEFT = createDescriptor("icons/alignleft.gif"); //$NON-NLS-1$
- DESC_VERT_ALIGN_MIDDLE = createDescriptor("icons/alignmid.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_RIGHT = createDescriptor("icons/alignright.gif"); //$NON-NLS-1$
- DESC_VERT_ALIGN_TOP = createDescriptor("icons/aligntop.gif"); //$NON-NLS-1$
- DESC_VERT_ALIGN_BOTTOM_DIS = createDescriptor("icons/alignbottom_d.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_CENTER_DIS = createDescriptor("icons/aligncenter_d.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_LEFT_DIS = createDescriptor("icons/alignleft_d.gif"); //$NON-NLS-1$
- DESC_VERT_ALIGN_MIDDLE_DIS = createDescriptor("icons/alignmid_d.gif"); //$NON-NLS-1$
- DESC_HORZ_ALIGN_RIGHT_DIS = createDescriptor("icons/alignright_d.gif"); //$NON-NLS-1$
- DESC_VERT_ALIGN_TOP_DIS = createDescriptor("icons/aligntop_d.gif"); //$NON-NLS-1$
- }
-
- private static ImageDescriptor createDescriptor(String filename) {
- return ImageDescriptor.createFromFile(InternalImages.class, filename);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/OpenEditorAction.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/OpenEditorAction.java
deleted file mode 100644
index 7c27eabd4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/OpenEditorAction.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.action;
-
-import java.util.List;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CompoundCommand;
-import org.eclipse.gef.ui.actions.SelectionAction;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.ui.IWorkbenchPart;
-
-/**
- *
- * This is the Action for opening a JSP page in the default JSP Editor from a
- * Pageflow Diagram
- *
- */
-public class OpenEditorAction extends SelectionAction {
- /** The name of the request */
- public static final String OPEN_EDITOR_REQUEST = PageflowMessages.Pageflow_Commands_OpenEditorCommand_Label;
-
- /** The request */
- Request request;
-
- /**
- * The constructor
- *
- * @param part -
- * the IWorkbenchPart
- */
- public OpenEditorAction(IWorkbenchPart part) {
- super(part);
- request = new Request(OPEN_EDITOR_REQUEST);
- // Pageflow.Action.OpenEditor.Label = Edit Page
- setText(PageflowMessages.Pageflow_Action_OpenEditor_Label);
- setId(FacesConfigEditor.EDITOR_ID);
- // Pageflow.Action.OpenEditor.ToolTip = Edit this page
- setToolTipText(PageflowMessages.Pageflow_Action_OpenEditor_ToolTip);
- }
-
- /**
- * Determines if the action can be enabled
- *
- * @return boolean - the enabled state
- */
- protected boolean calculateEnabled() {
- return canPerformAction();
- }
-
- /**
- * Determines if the action can be performed
- *
- * @return boolean - the perform state
- */
- private boolean canPerformAction() {
- if (getSelectedObjects().isEmpty()) {
- return false;
- }
- List parts = getSelectedObjects();
- for (int i = 0; i < parts.size(); i++) {
- Object o = parts.get(i);
- if (!(o instanceof EditPart)) {
- return false;
- }
- EditPart part = (EditPart) o;
- if (!(part.getModel() instanceof PageflowPage)) {
- return false;
- }
- }
- return true;
- }
-
- /**
- * Returns the command for the action
- *
- * @return Command - the action command
- */
- private Command getCommand() {
- List editparts = getSelectedObjects();
- CompoundCommand cc = new CompoundCommand();
- cc.setDebugLabel(OPEN_EDITOR_REQUEST);
- for (int i = 0; i < editparts.size(); i++) {
- EditPart part = (EditPart) editparts.get(i);
- cc.add(part.getCommand(request));
- }
- return cc;
- }
-
- /**
- * Runs the command
- */
- public void run() {
- execute(getCommand());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.ui.actions.WorkbenchPartAction#execute(org.eclipse.gef.commands.Command)
- */
- protected void execute(Command command) {
- if (command == null || !command.canExecute()) {
- return;
- }
- command.execute();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/ShowPropertyViewAction.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/ShowPropertyViewAction.java
deleted file mode 100644
index 24fe9daaf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/ShowPropertyViewAction.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.action;
-
-import java.util.List;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.ui.actions.SelectionAction;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-
-/**
- *
- * This is the Action for opening a JSP page in the default JSP Editor from a
- * Pageflow Diagram
- *
- * @author Xiao-guang Zhang
- */
-public class ShowPropertyViewAction extends SelectionAction {
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(ShowPropertyViewAction.class);
-
- /** The ID of the action */
- public static final String SHOW_PROPERTY_VIEW = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.ShowPropertyViewAction"; //$NON-NLS-1$
-
- /**
- * The constructor
- *
- * @param part -
- * the IWorkbenchPart
- */
- public ShowPropertyViewAction(IWorkbenchPart part) {
- super(part);
- // Pageflow.Action.ShowPropertyView.Label = Properties
- setText(PageflowMessages.Pageflow_Action_ShowPropertyView_Label);
- setId(SHOW_PROPERTY_VIEW);
- // Pageflow.Action.ShowPropertyView.ToolTip = Show properties
- setToolTipText(PageflowMessages.Pageflow_Action_ShowPropertyView_ToolTip);
- }
-
- /**
- * Determines if the action can be enabled
- *
- * @return boolean - the enabled state
- */
- protected boolean calculateEnabled() {
- return canPerformAction();
- }
-
- /**
- * Determines if the action can be performed
- *
- * @return boolean - the perform state
- */
- private boolean canPerformAction() {
- if (getSelectedObjects().isEmpty()) {
- return false;
- }
- List parts = getSelectedObjects();
- for (int i = 0; i < parts.size(); i++) {
- Object o = parts.get(i);
- if (!(o instanceof EditPart)) {
- return false;
- }
- EditPart part = (EditPart) o;
- if (!((part.getModel() instanceof PageflowElement))) {
- return false;
- }
- }
- return true;
- }
-
- /**
- * Runs the command
- */
- public void run() {
- List editparts = getSelectedObjects();
- if (editparts.size() > 0) {
- EditPart part = (EditPart) editparts.get(0);
- // execute(getCommand());
- if (part.getModel() instanceof PageflowElement) {
- // ensure the visibility of the palette view and property veiw.
- IWorkbenchWindow dw = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow();
- IWorkbenchPage page = dw.getActivePage();
- if (page != null) {
- try {
- page.showView("org.eclipse.ui.views.PropertySheet"); //$NON-NLS-1$
- } catch (PartInitException e) {
- // Pageflow.PageflowEditor.Error.canNotShowPropertyView
- // = Failed to show property sheet view.
- log
- .error(
- "Pageflow.PageflowEditor.Error.canNotShowPropertyView", //$NON-NLS-1$
- e);
- }
-
- }
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom.gif
deleted file mode 100644
index 9eea5581b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom_d.gif
deleted file mode 100644
index 1c62797ec..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignbottom_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter.gif
deleted file mode 100644
index 4e8c94a88..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter_d.gif
deleted file mode 100644
index ceeafb780..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligncenter_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft.gif
deleted file mode 100644
index 55cecc20e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft_d.gif
deleted file mode 100644
index 60fcc8f5c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignleft_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid.gif
deleted file mode 100644
index 5f13c93d4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid_d.gif
deleted file mode 100644
index 2f7534e6f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignmid_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright.gif
deleted file mode 100644
index f6ead1580..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright_d.gif
deleted file mode 100644
index 0495ed5d6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/alignright_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop.gif
deleted file mode 100644
index 2f9ceeb11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop_d.gif b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop_d.gif
deleted file mode 100644
index 9f1b49b1c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/action/icons/aligntop_d.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AbstractBatchEditCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AbstractBatchEditCommand.java
deleted file mode 100644
index eded9f1ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AbstractBatchEditCommand.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.FC2PFTransformer;
-
-/**
- * A batched edit command will enable adapters to interven before and after a
- * set of operations was done by sending notification to the adapters.
- *
- * @author hmeng
- */
-
-/*package*/ abstract class AbstractBatchEditCommand extends Command {
- Pageflow pageflow;
-
- /**
- * @param pageflow
- */
- public AbstractBatchEditCommand(Pageflow pageflow) {
- this(pageflow, null);
- }
-
- /**
- * @param pageflow
- * @param label
- */
- public AbstractBatchEditCommand(Pageflow pageflow, String label) {
- super(label);
- this.pageflow = pageflow;
- }
-
- /**
- * @return the pageflow
- */
- public Pageflow getPageflow() {
- return pageflow;
- }
-
- /**
- * The subclass should extend methods doXXX only.
- */
- final public void execute() {
- preExecute();
- doExecute();
- postExecute();
- }
-
- final public void redo() {
- doRedo();
- }
-
- final public void undo() {
- preExecute();
- doUndo();
- postExecute();
- }
-
- /**
- *
- */
- abstract public void doExecute();
-
- /**
- * Do the customized redo
- */
- public void doRedo() {
- execute();
- }
-
- abstract void doUndo();
-
- final void preExecute() {
- getPageflow().eNotify(
- new ENotificationImpl((InternalEObject) getPageflow(),
- FC2PFTransformer.MY_NOTIFICATION_TYPE,
- PageflowPackage.PAGEFLOW, null, null));
- }
-
- /**
- * execute the post-execution handling
- */
- final protected void postExecute() {
- getPageflow().eNotify(
- new ENotificationImpl((InternalEObject) getPageflow(),
- FC2PFTransformer.MY_NOTIFICATION_TYPE1,
- PageflowPackage.PAGEFLOW, null, null));
- notifyPageflow(getPageflow());
- }
-
- /**
- * @param pageflow_
- */
- protected void notifyPageflow(Pageflow pageflow_) {
- pageflow_.notifyModelChanged(new ENotificationImpl(
- (InternalEObject) pageflow_, Notification.ADD,
- PageflowPackage.PAGEFLOW, null, null));
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddConnectionCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddConnectionCommand.java
deleted file mode 100644
index 149da0bdd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddConnectionCommand.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.layout.PageflowLayoutManager;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-
-/**
- * Add a new connection
- *
- * @author hmeng
- *
- */
-public class AddConnectionCommand extends ConnectionCommand {
-
- public boolean canExecute() {
- // if user don't set PFLink object before, this command can't be
- // executed.
- if (link == null) {
- return false;
- }
-
- // It is a connection create command
- if (oldSource == null && oldTarget == null) {
- // It is a connection create command
- // Source and target must be pointing to some
- // real connection point
- if (source == null || target == null) {
- return false;
- }
-
- if (!PageflowValidation.getInstance().isValidLinkForCreation(
- source, target)) {
- return false;
- }
- }
- return true;
- }
-
- public void doExecute() {
- // It is a connection create command
- if (canExecute() && oldSource == null && oldTarget == null) {
- Pageflow pageflow = null;
- // Get a reference to the pageflow
- if (source != null) {
- pageflow = source.getPageflow();
- } else if (target != null) {
- pageflow = target.getPageflow();
- }
- pageflow.connect(source, target, link);
-
- // self loop link
- if (source == target) {
- PageflowLayoutManager.updateSelfLoopLink(link);
- }
- }
- }
-
- public void redo() {
- // TODO Auto-generated method stub
- super.redo();
- }
-
- public void undo() {
- if (canExecute()) {
- // It was a connection create command
- if (oldSource == null && oldTarget == null) {
-
- Pageflow pageflow = null;
- // Get a reference to the pageflow
- if (source != null) {
- pageflow = source.getPageflow();
- } else if (target != null) {
- pageflow = target.getPageflow();
- }
-
- // Ensure that link knows nothing about nodes anymore.
- link.setSource(null);
- link.setTarget(null);
- // Remove link from pageflow
- pageflow.getLinks().remove(link);
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddNodeCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddNodeCommand.java
deleted file mode 100644
index be41ab27f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/AddNodeCommand.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * This is the add command for pageflow editpart
- *
- */
-public class AddNodeCommand extends Command {
- /** Pageflow node including Page, action, begin, end. */
- private PageflowNode child;
-
- /** parent Pageflow */
- private Pageflow parent;
-
- /** index of pageflow nodes */
- private int index = -1;
-
- /**
- * Default constructor
- */
- public AddNodeCommand() {
- // Pageflow.Commands.AddNodeCommand.Label = add
- super(PageflowMessages.Pageflow_Commands_AddNodeCommand_Label);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- if (index < 0) {
- parent.getNodes().add(child);
- } else {
- parent.getNodes().add(index, child);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- if (index < 0) {
- parent.getNodes().add(child);
- } else {
- parent.getNodes().add(index, child);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- parent.getNodes().remove(child);
- }
-
- /**
- * get parent pageflow of the node.
- * @return the parent
- *
- */
- public Pageflow getParent() {
- return parent;
- }
-
- /**
- * Set the child pageflow node
- *
- * @param subpart -
- * child pageflow node
- */
- public void setChild(PageflowNode subpart) {
- child = subpart;
- }
-
- /**
- * Creates a new AbstractEditorPage instance.
- *
- * @param i -
- * index of pageflow node
- */
- public void setIndex(int i) {
- index = i;
- }
-
- /**
- * Set the new parent pageflow
- *
- * @param newParent -
- * parent pageflow
- */
- public void setParent(Pageflow newParent) {
- parent = newParent;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/BendpointCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/BendpointCommand.java
deleted file mode 100644
index e4690d0fc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/BendpointCommand.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-
-/**
- * base class for bend point commands.
- *
- */
-/*package*/ abstract class BendpointCommand extends Command {
- /** the index of the bend point */
- protected int index;
-
- /** the location of the bendpoint */
- protected Point location;
-
- /** the parent link */
- protected PageflowLink link;
-
- /** relative dimension between the bendpoint with start point of the pflink */
- private Dimension dimStart;
-
- /** relative dimension between the bendpoint with end point of the pflink */
- private Dimension dimEnd;
-
- /**
- * @param label
- */
- public BendpointCommand(String label) {
- super(label);
- }
-
- /**
- * get the dimension between the bendpoint and start point
- *
- * @return - the start dimension
- */
- protected Dimension getFirstRelativeDimension() {
- return dimStart;
- }
-
- /**
- * get the dimension between the bendpoint and end point
- *
- * @return - the end dimension
- */
- protected Dimension getSecondRelativeDimension() {
- return dimEnd;
- }
-
- /**
- * get the index of the bend point
- *
- * @return - the index
- */
- protected int getIndex() {
- return index;
- }
-
- /**
- * get the location of the bend point
- *
- * @return - the index
- */
- protected Point getLocation() {
- return location;
- }
-
- /**
- * get the parent link
- *
- * @return - parent link
- */
- protected PageflowLink getPFLink() {
- return link;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- execute();
- }
-
- /**
- * set the relative dimensions of the bendpoint
- *
- * @param dim1 -
- * the dimension between the bendpoint and start point
- * @param dim2 -
- * the dimension between the bendpoint and end point
- */
- public void setRelativeDimensions(Dimension dim1, Dimension dim2) {
- dimStart = dim1;
- dimEnd = dim2;
- }
-
- /**
- * set the index of the bendpoint in the bendpoint list
- *
- * @param i -
- * index
- */
- public void setIndex(int i) {
- index = i;
- }
-
- /**
- * set the location of the bendpoing
- *
- * @param p -
- * new location
- */
- public void setLocation(Point p) {
- location = p;
- }
-
- /**
- * set the parent link
- *
- * @param newLink -
- * new parent pflink
- */
- public void setPFLink(PageflowLink newLink) {
- link = newLink;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommand.java
deleted file mode 100644
index dafa9f613..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommand.java
+++ /dev/null
@@ -1,154 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.TransformUtil;
-
-/**
- * This is the connection command for pageflow editpart
- *
- * @author Xiao-guang Zhang, hmeng
- */
-public abstract class ConnectionCommand extends Command {
- /** Old source pageflow node */
- protected PageflowNode oldSource;
-
- /** Old target pageflow node */
- protected PageflowNode oldTarget;
-
- /** New source pageflow node */
- protected PageflowNode source;
-
- /** New target pageflow node */
- protected PageflowNode target;
-
- /** pageflow link */
- protected PageflowLink link;
-
- /**
- * Default constructor
- */
- public ConnectionCommand() {
- super(PageflowMessages.Pageflow_Commands_ConnectionCommand_Label);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#canExecute()
- */
- public boolean canExecute() {
- return TransformUtil.isValidPageflowElement(link);
- }
-
- /**
- * perform the main command execution. Sub-classes should override.
- */
- protected void doExecute() {
- // do nothing; sub-class can over-ride
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public final void execute() {
- if (canExecute()) {
- doExecute();
- } else {
- link = null;
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- execute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ommand#undo()
- */
- public void undo() {
- // do nothing
- }
-
- /**
- * Get the source pageflow node
- *
- * @return - the source pageflow node
- */
- public PageflowNode getSource() {
- return source;
- }
-
- /**
- * Get the target pageflow node
- *
- * @return - the target pageflow node.
- */
- public PageflowNode getTarget() {
- return target;
- }
-
- /**
- * Get the pageflow link
- *
- * @return - the pageflow link.
- */
- public PageflowLink getPFLink() {
- return link;
- }
-
- /**
- * Set the source pageflow node
- *
- * @param newSource -
- * new source pageflow node
- */
- public void setSource(PageflowNode newSource) {
- source = newSource;
- }
-
- /**
- * Set the target pageflow node
- *
- * @param newTarget -
- * new target pageflow node
- */
- public void setTarget(PageflowNode newTarget) {
- target = newTarget;
- }
-
- /**
- * Set the pageflow link
- *
- * @param link -
- * new pageflow link
- */
- public void setPFLink(PageflowLink link) {
- this.link = link;
- oldSource = link.getSource();
- oldTarget = link.getTarget();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommandFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommandFactory.java
deleted file mode 100644
index 8c7397c98..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ConnectionCommandFactory.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.Request;
-import org.eclipse.gef.RequestConstants;
-
-/**
- * The factory helps to create connection commands.
- *
- * @author hmeng
- *
- */
-public class ConnectionCommandFactory {
- /**
- * @param request
- * @return the connection command for the request
- */
- public static ConnectionCommand createCommand(Request request) {
- ConnectionCommand command = null;
- if (request.getType() == RequestConstants.REQ_CONNECTION_START
- || request.getType() == RequestConstants.REQ_CONNECTION_END) {
- command = new AddConnectionCommand();
- } else if (request.getType() == RequestConstants.REQ_RECONNECT_SOURCE
- || request.getType() == RequestConstants.REQ_RECONNECT_TARGET) {
- command = new ReconnectConnectionCommand();
- } else if (request.getType() == RequestConstants.REQ_DELETE) {
- command = new DeleteConnectionCommand();
- }
- return command;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateBendpointCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateBendpointCommand.java
deleted file mode 100644
index 60df11d4a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateBendpointCommand.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.Map;
-
-import org.eclipse.emf.ecore.EPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-
-/**
- * Create a new bend point command
- *
- */
-public class CreateBendpointCommand extends BendpointCommand {
- /**
- * Default constructor
- */
- public CreateBendpointCommand() {
- // Pageflow.Commands.CreateBendpointCommand.Label = Create Bendpoint
- super(PageflowMessages.Pageflow_Commands_CreateBendpointCommand_Label);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- Map registry = EPackage.Registry.INSTANCE;
- String pageflowURI = PageflowPackage.eNS_URI;
- PageflowPackage pageflowPackage = (PageflowPackage) registry
- .get(pageflowURI);
- PageflowFactory factory = pageflowPackage.getPageflowFactory();
- PageflowLinkBendpoint _newBendpoint = factory.createPFLinkBendpoint();
-
- _newBendpoint.setRelativeDimensions(getFirstRelativeDimension(),
- getSecondRelativeDimension());
- getPFLink().insertBendpoint(getIndex(), _newBendpoint);
- super.execute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- super.undo();
- getPFLink().removeBendpoint(getIndex());
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateNodeCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateNodeCommand.java
deleted file mode 100644
index 0cb7b282f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/CreateNodeCommand.java
+++ /dev/null
@@ -1,253 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.internal.dialogs.CommonResourceDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IWorkbenchWindow;
-
-/**
- * This is the creation command for pageflow editpart
- *
- * @author Xiao-guang Zhang
- */
-public class CreateNodeCommand extends Command implements IPreExecuteCommand {
- private static final String UNNAMED_NODE = "unnamed"; //$NON-NLS-1$
-
- /** new pageflow node */
- private PageflowNode child;
-
- /** size of pageflow node figure */
- private Rectangle rect;
-
- /** parent pageflow */
- private Pageflow parent;
-
- /** index of pageflow nodes */
- // private int _index = -1;
- public CreateNodeCommand() {
- // Pageflow.Commands.CreateNodeCommand.Label = Create new node
- super(PageflowMessages.Pageflow_Commands_CreateNodeCommand_Label);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#canExecute()
- */
- public boolean canExecute() {
- return child != null && parent != null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- if (rect != null) {
- child.setX(rect.x);
- child.setY(rect.y);
- if (!rect.isEmpty()) {
- child.setHeight(rect.getSize().height);
- child.setWidth(rect.getSize().width);
- }
- }
-
- if (child.getName() == UNNAMED_NODE) {
- child.setName(parent.getDefaultNodeName(child.getClass()));
- }
-
- parent.getNodes().add(child);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- if (rect != null) {
- child.setX(rect.x);
- child.setY(rect.y);
- if (!rect.isEmpty()) {
- child.setHeight(rect.getSize().height);
- child.setWidth(rect.getSize().width);
- }
- }
-
- parent.getNodes().add(child);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- parent.getNodes().remove(child);
- }
-
- /**
- * select a jsp page in current project.
- *
- * @return
- */
- private boolean selectJSPPage() {
-
- Shell shell = null;
- IWorkbenchWindow workbenchWindow = EditorPlugin
- .getActiveWorkbenchWindow();
- if (workbenchWindow.getShell() != null) {
- shell = workbenchWindow.getShell();
- } else {
- shell = new Shell();
- }
- IProject project = WebrootUtil.getProject(getParent());
-
- CommonResourceDialog dialog = new CommonResourceDialog(shell, project,
- SWT.NONE);
-
- dialog
- .setTitle(PageflowMessages.Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Title);
- // no suffix filter
- dialog.setSuffixs(null);
- dialog
- .setResourceDescription(PageflowMessages.Pageflow_Commands_CreateNodeCommand_SelectJSPDialog_Description);
-
- if (dialog.open() == Window.OK) {
- Object[] result = dialog.getResult();
- if (result != null) {
- IFile jspFile = (IFile) result[0];
- if (jspFile != null) {
- // get the project path for the new created file, i.e.,
- // /project/webroot/*.jsp
- String jsfSelection = WebrootUtil.getWebPath(jspFile
- .getFullPath());
- if (jsfSelection != null && jsfSelection.length() > 0) {
- if (PageflowValidation.getInstance().isExistedPage(
- this.parent, jsfSelection)) {
- // Pageflow.PageflowEditor.Alert.DNDResourceTitle =
- // Pageflow Creation Error
- // Pageflow.PageflowEditor.Alert.ExistingPage = The
- // web page {0} is already existed in current
- // PageFlow.
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.PageflowEditor.Alert.DNDResourceTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.ExistingPage", //$NON-NLS-1$
- jsfSelection);
- return false;
- }
-
- ((PageflowPage) (child)).setPath(jsfSelection);
- ((PageflowPage) (child)).setName(WebrootUtil
- .getPageNameFromWebPath(jsfSelection));
- }
-
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * call the JSF wizard to create a new jsf page.
- * @return the parent
- *
- */
- public Pageflow getParent() {
- return parent;
- }
-
- /**
- * set the child node
- *
- * @param subpart -
- * new child pageflow node
- */
- public void setChild(PageflowNode subpart) {
- child = subpart;
- }
-
- /**
- * set the location of the new pageflow node
- *
- * @param r -
- * location of the new pageflow node
- */
- public void setLocation(Rectangle r) {
- rect = r;
- }
-
- /**
- * set the parent pageflow
- *
- * @param newParent -
- * the new parent pageflow
- */
- public void setParent(Pageflow newParent) {
- parent = newParent;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.commands.IPreExecuteCommand#preExecute()
- */
- public boolean preExecute() {
- // note that the model adds the ports to the node in this call
- // pop up the new the wizard to create the new jsf file
- if (child instanceof PageflowPage) {
- // if the new page's file path is not empty, i.e., drag a file from
- // resource navigator view
- if (null != ((PageflowPage) child).getPath()) {
- if (PageflowValidation.getInstance().isExistedPage(parent,
- (PageflowPage) child)) {
- // Pageflow.PageflowEditor.Alert.DNDResourceTitle = Pageflow
- // Creation Error
- // Pageflow.PageflowEditor.Alert.ExistingPage = The web page
- // {0} is already existed in current PageFlow.
- EditorPlugin.getAlerts().error(
- "Pageflow.PageflowEditor.Alert.DNDResourceTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.ExistingPage", //$NON-NLS-1$
- ((PageflowPage) child).getPath());
- return false;
- }
- } else
- // create a new jsf page from scratch
- {
- // return createNewJSFPage();
- return selectJSPPage();
- }
- }
- return true;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DelegatingCommandStack.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DelegatingCommandStack.java
deleted file mode 100644
index 1586f6fd0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DelegatingCommandStack.java
+++ /dev/null
@@ -1,262 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.EventObject;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CommandStack;
-import org.eclipse.gef.commands.CommandStackListener;
-import org.eclipse.gef.commands.UnexecutableCommand;
-
-/**
- * This is a delegating command stack, which delegates everything to another
- * CommandStack except event listners.
- * <p>
- * Event listeners registered to a <code>DelegatingCommandStack</code> will be
- * informed whenever the underlying <code>CommandStack</code> changes. They
- * will not be registered to the underlying <code>CommandStack</code> directly
- * but they will be informed about change events of them.
- *
- */
-public class DelegatingCommandStack extends CommandStack implements
- CommandStackListener {
- /** the empty object array */
- private static final Object[] EMPTY_OBJECT_ARRAY = new Object[] {};
-
- /** the current command stack */
- private CommandStack currentCommandStack = null;
-
- /**
- * Returns the current <code>CommandStack</code>.
- *
- * @return - the current <code>CommandStack</code>
- */
- public CommandStack getCurrentCommandStack() {
- return currentCommandStack;
- }
-
- /**
- * Sets the current <code>CommandStack</code>.
- *
- * @param stack -
- * the <code>CommandStack</code> to set
- */
- public void setCurrentCommandStack(CommandStack stack) {
- if (currentCommandStack == stack) {
- return;
- }
-
- // remove from old command stack
- if (null != currentCommandStack) {
- currentCommandStack.removeCommandStackListener(this);
- }
-
- // set new command stack
- currentCommandStack = stack;
-
- if (currentCommandStack != null) {
- // watch new command stack
- currentCommandStack.addCommandStackListener(this);
-
- // the command stack changed
- notifyListeners();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#canRedo()
- */
- public boolean canRedo() {
- if (null == currentCommandStack) {
- return false;
- }
-
- return currentCommandStack.canRedo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#canUndo()
- */
- public boolean canUndo() {
- if (null == currentCommandStack) {
- return false;
- }
-
- return currentCommandStack.canUndo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#dispose()
- */
- public void dispose() {
- if (null != currentCommandStack) {
- currentCommandStack.dispose();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#execute(org.eclipse.gef.commands.Command)
- */
- public void execute(Command command) {
- if (null != currentCommandStack) {
- currentCommandStack.execute(command);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#flush()
- */
- public void flush() {
- if (null != currentCommandStack) {
- currentCommandStack.flush();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#getCommands()
- */
- public Object[] getCommands() {
- if (null == currentCommandStack) {
- return EMPTY_OBJECT_ARRAY;
- }
-
- return currentCommandStack.getCommands();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#getRedoCommand()
- */
- public Command getRedoCommand() {
- if (null == currentCommandStack) {
- return UnexecutableCommand.INSTANCE;
- }
-
- return currentCommandStack.getRedoCommand();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#getUndoCommand()
- */
- public Command getUndoCommand() {
- if (null == currentCommandStack) {
- return UnexecutableCommand.INSTANCE;
- }
-
- return currentCommandStack.getUndoCommand();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#getUndoLimit()
- */
- public int getUndoLimit() {
- if (null == currentCommandStack) {
- return -1;
- }
-
- return currentCommandStack.getUndoLimit();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#isDirty()
- */
- public boolean isDirty() {
- if (null == currentCommandStack) {
- return false;
- }
-
- return currentCommandStack.isDirty();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#markSaveLocation()
- */
- public void markSaveLocation() {
- if (null != currentCommandStack) {
- currentCommandStack.markSaveLocation();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#redo()
- */
- public void redo() {
- if (null != currentCommandStack) {
- currentCommandStack.redo();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#setUndoLimit(int)
- */
- public void setUndoLimit(int undoLimit) {
- if (null != currentCommandStack) {
- currentCommandStack.setUndoLimit(undoLimit);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStack#undo()
- */
- public void undo() {
- if (null != currentCommandStack) {
- currentCommandStack.undo();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Object#toString()
- */
- public String toString() {
- return "DelegatingCommandStack(" + currentCommandStack + ")"; //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see CommandStackListener#commandStackChanged(java.util.EventObject)
- */
- public void commandStackChanged(EventObject event) {
- notifyListeners();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteBendpointCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteBendpointCommand.java
deleted file mode 100644
index 25e004937..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteBendpointCommand.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-
-/**
- *
- */
-public class DeleteBendpointCommand extends BendpointCommand {
-
- /** the deleting bendpoint */
- private PageflowLinkBendpoint bendpoint;
-
- /**
- * Default constructor
- */
- public DeleteBendpointCommand() {
-
- // Pageflow.Commands.DeleteBendpointCommand.Label = Delete Bendpoint
- super(PageflowMessages.Pageflow_Commands_DeleteBendpointCommand_Label);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- super.execute();
- bendpoint = (PageflowLinkBendpoint) getPFLink().getBendPoints().get(
- getIndex());
- getPFLink().removeBendpoint(getIndex());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- super.undo();
- getPFLink().insertBendpoint(getIndex(), bendpoint);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteConnectionCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteConnectionCommand.java
deleted file mode 100644
index dd22437fd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteConnectionCommand.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-/**
- * Delete a connection.
- *
- * @author hmeng
- *
- */
-public class DeleteConnectionCommand extends ConnectionCommand {
-
- public boolean canExecute() {
- return link != null;
- }
-
- protected void doExecute() {
- // It is a delete connection command
- if (link != null) {
- link.setSource(null);
- link.setTarget(null);
- oldSource.getPageflow().getLinks().remove(link);
- link.eAdapters().clear();
- }
- }
-
- public void undo() {
- // It is a delete connection command
- if (canExecute()) {
- link.setSource(oldSource);
- link.setTarget(oldTarget);
- oldSource.getPageflow().getLinks().add(link);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteNodeCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteNodeCommand.java
deleted file mode 100644
index 4660942a7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/DeleteNodeCommand.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * This is the delete command for pageflow editpart
- *
- */
-public class DeleteNodeCommand extends AbstractBatchEditCommand {
- /** the deleting pageflow node */
- private PageflowNode child;
-
- /** parent pageflow */
- private Pageflow parent;
-
- /** index of pageflow nodes */
- private int index = -1;
-
- /** source connections with the deleting node */
- private List sourceConnections = new ArrayList();
-
- private List sourceConnectionSources = new ArrayList();
-
- private List sourceConnectionTargets = new ArrayList();
-
- /** target connections with the deleting node */
- private List targetConnections = new ArrayList();
-
- private List targetConnectionSources = new ArrayList();
-
- private List targetConnectionTargets = new ArrayList();
-
- /**
- * @param pageflow
- */
- public DeleteNodeCommand(Pageflow pageflow) {
- // Pageflow.Commands.DeleteNodeCommand.Label = Delete
- super(pageflow, PageflowMessages.Pageflow_Commands_DeleteNodeCommand_Label);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void doExecute() {
- primExecute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void doRedo() {
- primExecute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void doUndo() {
- parent.getNodes().add(index, child);
- restoreConnections(child);
- }
-
- /**
- * delete the connections related with the pageflow node.
- *
- * @param node -
- * the deleting pageflow node
- */
- private void deleteConnections(PageflowNode node) {
- while (node.getOutlinks().size() > 0) {
- // Note:should save the source and target of the link, otherwise
- // source and target will be lost,
- // when the source and target node remove the link.
- PageflowLink link = (PageflowLink) node.getOutlinks().get(0);
- sourceConnections.add(link);
- sourceConnectionSources.add(link.getSource());
- sourceConnectionTargets.add(link.getTarget());
-
- link.getTarget().getInlinks().remove(link);
- node.getOutlinks().remove(link);
- parent.getLinks().remove(link);
- }
-
- while (node.getInlinks().size() > 0) {
- // Note: should save the source and target of the link, otherwise
- // source and target will be lost,
- // when the source and target node remove the link.
- PageflowLink link = (PageflowLink) node.getInlinks().get(0);
- targetConnections.add(link);
- targetConnectionSources.add(link.getSource());
- targetConnectionTargets.add(link.getTarget());
-
- link.getSource().getOutlinks().remove(link);
- node.getInlinks().remove(link);
- parent.getLinks().remove(link);
- }
- }
-
- /**
- * execute the delete command
- *
- *
- */
- protected void primExecute() {
- deleteConnections(child);
- index = parent.getNodes().indexOf(child);
- parent.getNodes().remove(child);
- }
-
- /**
- * restore the connections of the deleted pageflow node
- *
- * @param node -
- * the deleted pageflow node
- */
- private void restoreConnections(PageflowNode node) {
- for (int i = 0; i < sourceConnections.size(); i++) {
- // restore the link with the source and target
- PageflowLink link = (PageflowLink) sourceConnections.get(i);
- PageflowNode source = (PageflowNode) sourceConnectionSources.get(i);
- PageflowNode target = (PageflowNode) sourceConnectionTargets.get(i);
- link.setSource(source);
- link.setTarget(target);
-
- parent.getLinks().add(link);
- node.getOutlinks().add(link);
- link.getTarget().getInlinks().add(link);
- }
- sourceConnections.clear();
- for (int i = 0; i < targetConnections.size(); i++) {
- // restore the link with the source and target
- PageflowLink link = (PageflowLink) targetConnections.get(i);
- PageflowNode source = (PageflowNode) targetConnectionSources.get(i);
- PageflowNode target = (PageflowNode) targetConnectionTargets.get(i);
- link.setSource(source);
- link.setTarget(target);
-
- parent.getLinks().add(link);
- node.getInlinks().add(link);
- link.getSource().getOutlinks().add(link);
- }
- targetConnections.clear();
- }
-
- /**
- * set the child pageflow node
- *
- * @param c -
- * the child pageflow node
- */
- public void setChild(PageflowNode c) {
- child = c;
- }
-
- /**
- * set the parent pageflow
- *
- * @param p -
- * the parent pageflow
- */
- public void setParent(Pageflow p) {
- parent = p;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandGEFAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandGEFAdapter.java
deleted file mode 100644
index 456c1b888..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandGEFAdapter.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.commands.Command;
-
-/**
- * This class is used to adapter EMF Command to GEF Command.
- *
- * @author xgzhang
- * @version
- */
-/*package*/ class EMFCommandGEFAdapter extends Command {
- private org.eclipse.emf.common.command.Command emfCommand;
-
- /**
- * @param emfCommand
- */
- public EMFCommandGEFAdapter(
- org.eclipse.emf.common.command.Command emfCommand) {
- super();
- this.emfCommand = emfCommand;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#canExecute()
- */
- public boolean canExecute() {
- if (emfCommand == null) {
- return false;
- }
- return emfCommand.canExecute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#canUndo()
- */
- public boolean canUndo() {
- if (emfCommand == null) {
- return false;
- }
- return emfCommand.canUndo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#dispose()
- */
- public void dispose() {
- if (emfCommand == null) {
- return;
- }
- emfCommand.dispose();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#execute()
- */
- public void execute() {
- if (emfCommand == null) {
- return;
- }
- emfCommand.execute();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#getLabel()
- */
- public String getLabel() {
- if (emfCommand == null) {
- return null;
- }
- return emfCommand.getLabel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#redo()
- */
- public void redo() {
- if (emfCommand == null) {
- return;
- }
- emfCommand.redo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.Command#undo()
- */
- public void undo() {
- if (emfCommand == null) {
- return;
- }
- emfCommand.undo();
- }
-
- /**
- *
- */
- org.eclipse.emf.common.command.Command getEMFCommand() {
- return emfCommand;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandStackGEFAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandStackGEFAdapter.java
deleted file mode 100644
index a253dff20..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/EMFCommandStackGEFAdapter.java
+++ /dev/null
@@ -1,199 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.EventObject;
-
-import org.eclipse.emf.common.command.BasicCommandStack;
-import org.eclipse.emf.common.command.CommandStackListener;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CommandStack;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-
-/**
- * This adapter is used to let editor be able to monitor EMF CommandStack, e.g.,
- * in StructuredTextEditor, using GEF CommandStack.
- *
- * @author xgzhang
- * @version
- */
-public class EMFCommandStackGEFAdapter extends CommandStack implements
- CommandStackListener {
- private org.eclipse.emf.common.command.BasicCommandStack emfCommandStack;
- private IStructuredModel model;
-
- /**
- * @param doc
- */
- public EMFCommandStackGEFAdapter (IDocument doc) {
-
- super();
-
- model = StructuredModelManager.getModelManager().getExistingModelForEdit(doc);
-
- if (model == null) {
- model = StructuredModelManager.getModelManager().getModelForEdit((IStructuredDocument) doc);
- }
-
- emfCommandStack = ((BasicCommandStack) this.model.getUndoManager().getCommandStack());
- emfCommandStack.addCommandStackListener(this);
- }
-
-
- @Override
- public void dispose() {
- model.releaseFromEdit();
- super.dispose();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#canRedo()
- */
- public boolean canRedo() {
- if (emfCommandStack == null) {
- return false;
- }
- return emfCommandStack.canRedo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#canUndo()
- */
- public boolean canUndo() {
- if (emfCommandStack == null) {
- return false;
- }
- return emfCommandStack.canUndo();
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#execute(org.eclipse.gef.commands.Command)
- */
- public void execute(Command command) {
- if (!(command instanceof EMFCommandGEFAdapter)) {
- return;
- }
-
- org.eclipse.emf.common.command.Command emfCommand = ((EMFCommandGEFAdapter) command)
- .getEMFCommand();
- if (emfCommand != null) {
- emfCommandStack.execute(emfCommand);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#flush()
- */
- public void flush() {
- if (emfCommandStack == null) {
- return;
- }
- emfCommandStack.flush();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#getRedoCommand()
- */
- public Command getRedoCommand() {
- if (emfCommandStack == null || emfCommandStack.getRedoCommand() == null) {
- return null;
- }
-
- return new EMFCommandGEFAdapter(emfCommandStack.getRedoCommand());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#getUndoCommand()
- */
- public Command getUndoCommand() {
- if (emfCommandStack == null || emfCommandStack.getUndoCommand() == null) {
- return null;
- }
-
- return new EMFCommandGEFAdapter(emfCommandStack.getUndoCommand());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#isDirty()
- */
- public boolean isDirty() {
- if (emfCommandStack == null) {
- return false;
- }
- return emfCommandStack.isSaveNeeded();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#markSaveLocation()
- */
- public void markSaveLocation() {
- if (emfCommandStack == null) {
- return;
- }
- emfCommandStack.saveIsDone();
- super.markSaveLocation();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#redo()
- */
- public void redo() {
- if (emfCommandStack == null) {
- return;
- }
- emfCommandStack.redo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#undo()
- */
- public void undo() {
- if (emfCommandStack == null) {
- return;
- }
- emfCommandStack.undo();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.command.CommandStackListener#commandStackChanged(java.util.EventObject)
- */
- public void commandStackChanged(EventObject event) {
- this.notifyListeners();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/IPreExecuteCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/IPreExecuteCommand.java
deleted file mode 100644
index 4bed8f6e3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/IPreExecuteCommand.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-/**
- * Command with pre execute checking.
- *
- * @author Xiao-guang Zhang
- *
- *
- */
-/*package*/ interface IPreExecuteCommand {
- /**
- * Do something pre-execution of the actual command execution.
- *
- * @return - successful to do the pre-execution
- */
- boolean preExecute();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/MoveBendpointCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/MoveBendpointCommand.java
deleted file mode 100644
index dc1e0fa48..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/MoveBendpointCommand.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.Map;
-
-import org.eclipse.emf.ecore.EPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-
-/**
- * Move bend point command
- */
-public class MoveBendpointCommand extends BendpointCommand {
- /**
- * old bend point of the link
- */
- private PageflowLinkBendpoint oldBendpoint;
-
- /**
- * Default constructor
- */
- public MoveBendpointCommand() {
- // Pageflow.Commands.MoveBendpointCommand.Label = Move Bendpoint
- super(PageflowMessages.Pageflow_Commands_MoveBendpointCommand_Label);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- Map registry = EPackage.Registry.INSTANCE;
- String pageflowURI = PageflowPackage.eNS_URI;
- PageflowPackage pageflowPackage = (PageflowPackage) registry
- .get(pageflowURI);
- PageflowFactory factory = pageflowPackage.getPageflowFactory();
- PageflowLinkBendpoint _newBendpoint = factory.createPFLinkBendpoint();
-
- _newBendpoint.setRelativeDimensions(getFirstRelativeDimension(),
- getSecondRelativeDimension());
- setOldBendpoint((PageflowLinkBendpoint) getPFLink().getBendPoints().get(
- getIndex()));
-
- getPFLink().setBendpoint(getIndex(), _newBendpoint);
- super.execute();
- }
-
- /**
- * get the old bend point
- *
- * @return - old bend point
- */
- protected PageflowLinkBendpoint getOldBendpoint() {
- return oldBendpoint;
- }
-
- /**
- * set the old bend point
- *
- * @param bp -
- * old bend point
- */
- public void setOldBendpoint(PageflowLinkBendpoint bp) {
- oldBendpoint = bp;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- super.undo();
- getPFLink().setBendpoint(getIndex(), getOldBendpoint());
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OpenEditorCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OpenEditorCommand.java
deleted file mode 100644
index e293eb8ab..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OpenEditorCommand.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.FacesConfigEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.IEditorDescriptor;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.ui.part.FileEditorInput;
-
-/**
- *
- * This is the Command for opening a file in its default editor
- *
- * @author Xiao-guang Zhang
- */
-public class OpenEditorCommand extends Command {
-
- /** The edit part */
- private EditPart part;
-
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(FacesConfigEditor.class);
-
- /*
- * (non-Javadoc)
- *
- * @see Command#canExecute()
- */
- public boolean canExecute() {
- return true;
- }
-
- /**
- * The constructor
- *
- * @param part -
- * the EditPart
- */
- public OpenEditorCommand(EditPart part) {
- // Pageflow.Commands.OpenEditorCommand.Label = Open Editor
- super(PageflowMessages.Pageflow_Commands_OpenEditorCommand_Label);
- this.part = part;
- }
-
- /**
- * open existed JSF file or call the wizard to create a new one.
- *
- */
- private void executeOpenPFPage() {
- IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
- String pagePath = ((PageflowPage) (part.getModel())).getPath();
-
- // Check the fileName is empty or not
- if (pagePath != null && pagePath.length() > 0) {
- String resourceName = WebrootUtil.getProjectPath((EObject) part
- .getModel(), pagePath);
- Path resourcePath = new Path(resourceName);
- if (resourcePath.getFileExtension() != null) {
- final IFile file = (IFile) workspaceRoot
- .findMember(resourcePath);
- openExistingJSFFile(file);
- } else {
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle =
- // Open JSF File Error
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFFolderInfo =
- // Cannot open the page in the page editor.
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFFolderInfo"); //$NON-NLS-1$
- }
- } else
- // if the fileName is empty, a new jsf file should be created!
- {
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle = Open JSF
- // File Error
- // Pageflow.PageflowEditor.Alert.confirmCreateNewJSFFile = No jsp
- // file is related with this page.
- EditorPlugin.getAlerts().error(
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.confirmCreateNewJSFFile");// ) //$NON-NLS-1$
- }
- }
-
- /**
- * open existing jsf file in a new editor.
- *
- * @param file
- */
- private void openExistingJSFFile(final IFile file) {
- // if the file is existed, open it.
- if (null != file && file.exists()) {
- Display display = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getShell().getDisplay();
- display.asyncExec(new Runnable() {
- public void run() {
- IDE.setDefaultEditor(file, null);
- try {
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
- IEditorDescriptor desc = IDE.getEditorDescriptor(file);
- page.openEditor(new FileEditorInput(file),
- desc.getId(), true, IWorkbenchPage.MATCH_INPUT
- | IWorkbenchPage.MATCH_ID);
- } catch (PartInitException e) {
- // Pageflow.PageflowEditor.Error.CanNotOpenEditor4JSF =
- // The jsf file can not be opened in the editor.
- log
- .error(
- "Pageflow.PageflowEditor.Error.canNotOpenEditor4JSF", //$NON-NLS-1$
- e);
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle
- // = Open JSF File Error
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Error.CanNotOpenEditor4JSF"); //$NON-NLS-1$
- }
- }
- });
- } else
- // otherwise, pop-up a error message box
- {
- String pagePath = ((PageflowPage) (part.getModel())).getPath();
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle = Open JSF
- // File Error
- // Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFInfo = The JSF
- // file is not existed.
- EditorPlugin.getAlerts().error(
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.errorOpenEditor4JSFInfo", //$NON-NLS-1$
- pagePath);
- }
- }
-
- /**
- * Executes the OpenEditorCommand and opens the editor
- */
- public void execute() {
- if (part.getModel() instanceof PageflowPage) {
- executeOpenPFPage();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OrphanChildCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OrphanChildCommand.java
deleted file mode 100644
index a695c320d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/OrphanChildCommand.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import java.util.List;
-
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * This is the orphan child command for pageflow container
- *
- */
-public class OrphanChildCommand extends Command {
-
- /** old location of pageflow node */
- private Point oldLocation;
-
- /** the parent pageflow */
- private Pageflow pageflow;
-
- /** the child pageflow node */
- private PageflowNode child;
-
- /** the index of pageflow nodes */
- private int index;
-
- /**
- * Default constructor
- */
- public OrphanChildCommand() {
- // Pageflow.Commands.OrphanChildCommand.Label = Orphan Child
- super(PageflowMessages.Pageflow_Commands_OrphanChildCommand_Label);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- List children = pageflow.getNodes();
- index = children.indexOf(child);
- oldLocation = new Point(child.getX(), child.getY());
- pageflow.getNodes().remove(child);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- pageflow.getNodes().remove(child);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- child.setX(oldLocation.x);
- child.setY(oldLocation.y);
- pageflow.getNodes().add(index, child);
- }
-
- /**
- * set the child pageflow node
- *
- * @param child -
- * child pageflow node
- */
- public void setChild(PageflowNode child) {
- this.child = child;
- }
-
- /**
- * set the parent pageflow
- *
- * @param parent -
- * parent pageflow
- */
- public void setParent(Pageflow parent) {
- pageflow = parent;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/PreExecuteCommandStack.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/PreExecuteCommandStack.java
deleted file mode 100644
index 2741862d8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/PreExecuteCommandStack.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CommandStack;
-
-/**
- * Before the command stack called execute to do the actual model modification,
- * it will call the command's IPreExecuteCommand inteface to check the command
- * can be execute or not.
- *
- *
- * @author Xiao-guang Zhang
- */
-public class PreExecuteCommandStack extends CommandStack {
- /**
- *
- */
- public PreExecuteCommandStack() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.commands.CommandStack#execute(org.eclipse.gef.commands.Command)
- */
- public void execute(Command command) {
- if (command == null || !command.canExecute()) {
- return;
- }
- if (command instanceof IPreExecuteCommand) {
- if (!((IPreExecuteCommand) command).preExecute()) {
- return;
- }
- }
- super.execute(command);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ReconnectConnectionCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ReconnectConnectionCommand.java
deleted file mode 100644
index 63519caf1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/ReconnectConnectionCommand.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-
-/**
- * Change the end of a link.
- *
- * @author hmeng
- *
- */
-public class ReconnectConnectionCommand extends ConnectionCommand {
-
- /**
- * Default constructor
- */
- public ReconnectConnectionCommand() {
- super();
- }
-
- public boolean canExecute() {
- // if user didn't set PFLink object beforehand, this command can't be
- // executed.
- if (link == null || link.eContainer() == null) {
- return false;
- }
-
- // Reconnect both source and target
- if (oldSource != null && source != null && oldTarget != null
- && target != null) {
- if (!PageflowValidation.getInstance().isValidLinkForCreation(
- source, target)) {
- return false;
- }
- }
-
- // Reconnect source
- if (oldSource != null && source != null) {
- if (!PageflowValidation.getInstance().isValidLinkForCreation(
- source, oldTarget)) {
- return false;
- }
- }
- // Reconnect target
- if (oldTarget != null && target != null) {
- if (!PageflowValidation.getInstance().isValidLinkForCreation(
- oldSource, target)) {
- return false;
- }
- }
-
- return true;
-
- }
-
- public void doExecute() {
- String outcome = null, action = null, largeIcon = null, smallIcon = null;
- boolean isRedirect = false;
- outcome = link.getOutcome();
- action = link.getFromaction();
- isRedirect = link.isRedirect();
- largeIcon = link.getLargeicon();
- smallIcon = link.getSmallicon();
- // It is a reconnect source command
- if (oldSource != null && source != null) {
- link.setSource(source);
- }
- // It is a reconnect target command
- if (oldTarget != null && target != null) {
- link.setTarget(target);
- }
- link.setOutcome(outcome);
- link.setFromaction(action);
- link.setLargeicon(largeIcon);
- link.setSmallicon(smallIcon);
- link.setRedirect(isRedirect);
- }
-
- public void undo() {
- if (canExecute()) {
- // It was a reconnect source command
- if (oldSource != null && source != null) {
- // The link source must be replaced by the oldSource
- if (link.getSource() != null) {
- link.getSource().getOutlinks().remove(link);
- }
- source.getOutlinks().remove(link);
- link.setSource(oldSource);
- }
- // It was a reconnect target command
- if (oldTarget != null && target != null) {
- // The link target must be replaced by the oldTarget
- if (link.getTarget() != null) {
- link.getTarget().getInlinks().remove(link);
- }
- target.getInlinks().remove(link);
- link.setTarget(oldTarget);
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/RenameNodeCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/RenameNodeCommand.java
deleted file mode 100644
index e3e526920..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/RenameNodeCommand.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * Command to rename Node.
- *
- * @author xgzhang
- */
-public class RenameNodeCommand extends Command {
-
- /** new pageflow node */
- private PageflowNode node;
-
- /** new node name */
- private String name;
-
- /** old node name */
- private String oldName;
-
- /**
- * @see org.eclipse.gef.commands.Command#execute()
- */
- public void execute() {
- node.setName(name);
- }
-
- /**
- * Sets the new Activity name
- *
- * @param string
- * the new name
- */
- public void setName(String string) {
- name = string;
- }
-
- /**
- * Sets the old Activity name
- *
- * @param string
- * the old name
- */
- public void setOldName(String string) {
- oldName = string;
- }
-
- /**
- * Sets the source Activity
- * @param node
- * the source Activity
- */
- public void setSource(PageflowNode node) {
- this.node = node;
- }
-
- /**
- * @see org.eclipse.gef.commands.Command#undo()
- */
- public void undo() {
- node.setName(oldName);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/SetConstraintCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/SetConstraintCommand.java
deleted file mode 100644
index c36b92961..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/command/SetConstraintCommand.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.command;
-
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-
-/**
- * This is the SetConstraint command for XY layout edit policy
- *
- */
-public class SetConstraintCommand extends Command {
- /** location command label */
- private static final String COMMAND_LABEL_LOCATION = PageflowMessages.SetConstraintCommand_Location;
-
- /** resize command label */
- private static final String COMMAND_LABEL_RESIZE = PageflowMessages.SetConstraintCommand_Resize;
-
- /** new position */
- private Point newPos;
-
- /** new size */
- private Dimension newSize;
-
- /** olde position */
- private Point oldPos;
-
- /** old size */
- private Dimension oldSize;
-
- /** pageflow element */
- private PageflowElement part;
-
- /*
- * (non-Javadoc)
- *
- * @see Command#execute()
- */
- public void execute() {
- oldSize = new Dimension(part.getWidth(), part.getHeight());
- oldPos = new Point(part.getX(), part.getY());
- part.setX(newPos.x);
- part.setY(newPos.y);
- part.setHeight(newSize.height);
- part.setWidth(newSize.width);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#redo()
- */
- public void redo() {
- part.setX(newPos.x);
- part.setY(newPos.y);
- part.setHeight(newSize.height);
- part.setWidth(newSize.width);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Command#undo()
- */
- public void undo() {
- part.setX(oldPos.x);
- part.setY(oldPos.y);
- part.setHeight(oldSize.height);
- part.setWidth(oldSize.width);
- }
-
- /**
- * return the label of the constraints
- */
- public String getLabel() {
- if (oldSize.equals(newSize)) {
- return COMMAND_LABEL_LOCATION;
- }
- return COMMAND_LABEL_RESIZE;
- }
-
- /**
- * set the new location using rectangle
- *
- * @param r -
- * new location
- */
- public void setLocation(Rectangle r) {
- setLocation(r.getLocation());
- setSize(r.getSize());
- }
-
- /**
- * set the new location using point
- *
- * @param p -
- * new location point
- */
- public void setLocation(Point p) {
- newPos = p;
- }
-
- /**
- * set the pageflow element
- *
- * @param part -
- * pageflow element
- */
- public void setPart(PageflowElement part) {
- this.part = part;
- }
-
- /**
- * set the new size
- *
- * @param p -
- * new size
- */
- public void setSize(Dimension p) {
- newSize = p;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ConfigurableRootEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ConfigurableRootEditPart.java
deleted file mode 100644
index 083c65edc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ConfigurableRootEditPart.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.SimpleLoweredBorder;
-import org.eclipse.gef.editparts.ScalableFreeformRootEditPart;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-
-/**
- * This RootEditPart can set its own's background, fourground color, and font.
- * All this properties can be changed.
- *
- * @author Xiao-guang Zhang
- *
- */
-public class ConfigurableRootEditPart extends ScalableFreeformRootEditPart
- implements IFigurePreference {
- /**
- *
- */
- public ConfigurableRootEditPart() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editparts.AbstractGraphicalEditPart#createFigure()
- */
- protected IFigure createFigure() {
- IFigure fig = super.createFigure();
- fig.setOpaque(true);
- fig.setBorder(new SimpleLoweredBorder());
- return fig;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setForegroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setForegroundColor(Color c) {
- getFigure().setForegroundColor(c);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setBackgroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setBackgroundColor(Color c) {
- getFigure().setBackgroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setFont(org.eclipse.swt.graphics.Font)
- */
- public void setFont(Font f) {
- getFigure().setFont(f);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/DirectEditCellEditorLocator.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/DirectEditCellEditorLocator.java
deleted file mode 100644
index 4c71c04bf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/DirectEditCellEditorLocator.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.tools.CellEditorLocator;
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * CellEditorLocator for Pageflow Node.
- *
- * @author - Xiaoguang Zhang
- */
-/*package*/ class DirectEditCellEditorLocator implements CellEditorLocator {
- /** the source label */
- private Label label;
-
- /**
- * Creates a new DirectEditCellEditorLocator for the given Label
- *
- * @param label
- * the Label
- */
- public DirectEditCellEditorLocator(Label label) {
- setLabel(label);
- }
-
- /*
- * (non-javadoc)
- *
- * @see CellEditorLocator#relocate(CellEditor)
- */
- public void relocate(CellEditor celleditor) {
- Text text = (Text) celleditor.getControl();
- Point pref = text.computeSize(-1, -1);
- // get the label's boundary
- Rectangle rect = label.getTextBounds().getCopy();
- label.translateToAbsolute(rect);
-
- // because the label can be empty and the size is too small
- // here get the prefered text size according to label's size and default
- // size.
- int width, height;
- if (pref.x > rect.width) {
- width = pref.x;
- } else {
- width = rect.width;
- }
-
- if (pref.y > rect.height) {
- height = pref.y;
- } else {
- height = rect.height;
- }
-
- // set the boundary of the text control
- text.setBounds(rect.x - 1, rect.y - 1, width + 1, height + 1);
- }
-
- /**
- * Returns the Label figure.
- *
- * @return the Label
- */
- protected Label getLabel() {
- return label;
- }
-
- /**
- * Sets the label.
- *
- * @param label
- * The label to set
- */
- protected void setLabel(Label label) {
- this.label = label;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IAnnotationEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IAnnotationEditPart.java
deleted file mode 100644
index 2c29393d0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IAnnotationEditPart.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.jface.text.source.Annotation;
-
-/**
- * Edit part's Annotation interface
- *
- * @author Xiao-guang Zhang
- *
- */
-public interface IAnnotationEditPart {
- /**
- * decorate current Edit Part.
- * @param annotation
- */
- void addAnnotation(Annotation annotation);
-
- /**
- * un-decorate current EditPart
- *
- */
- void removeAnnotation();
-
- /**
- * get the maker's resource instance.
- *
- * @return marker resource
- */
- IResource getMarkerResource();
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IConnectionPreference.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IConnectionPreference.java
deleted file mode 100644
index 8ff1b9a99..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IConnectionPreference.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.swt.graphics.Color;
-
-/**
- * This interface can be used to set Connection's preference
- *
- * @author Xiaoguang Zhang
- *
- */
-public interface IConnectionPreference extends IFigurePreference {
-
- /**
- * set the connection line width
- *
- * @param w
- */
- void setLineWidth(int w);
-
- /**
- * set the label visible or not
- *
- * @param b
- */
- void setLabelVisible(boolean b);
-
- /**
- * set the label's foreground color
- *
- * @param c
- */
- void setLabelForegroundColor(Color c);
-
- /**
- * set the label's background color
- *
- * @param c
- */
- void setLabelBackgroundColor(Color c);
-
- /**
- * set the connection router's style, it can be LINE_ROUTING_MANUAL,
- * LINE_ROUTING_MANHATTAN
- *
- * @param style -
- * The new connection router's style
- */
- void setConnectionRouterStyle(int style);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IFigurePreference.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IFigurePreference.java
deleted file mode 100644
index 3dc924b1e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/IFigurePreference.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-
-/**
- * This interface can be implemented to set the figure's preferences
- *
- * @author Xiao-guang Zhang
- *
- */
-public interface IFigurePreference {
- /**
- * Sets the foreground color.
- *
- * @param c
- * The new foreground color
- */
- void setForegroundColor(Color c);
-
- /**
- * Sets the background color.
- *
- * @param c
- * The new background color
- */
- void setBackgroundColor(Color c);
-
- /**
- * sets the new font
- *
- * @param f
- */
- void setFont(Font f);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ILayerPanePreference.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ILayerPanePreference.java
deleted file mode 100644
index 91d2af63b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/ILayerPanePreference.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.swt.graphics.Color;
-
-/**
- * LayerPane has muliple layers, this interface will be used to set different
- * layer's style.
- *
- * @author Xiao-guang Zhang
- *
- */
-public interface ILayerPanePreference extends IFigurePreference {
- /**
- * Use manual line router
- */
- public static int LINE_ROUTING_MANUAL = 0;
-
- /**
- * Use manhattan line router
- */
- public static int LINE_ROUTING_MANHATTAN = 1;
-
- /**
- * sets the grid to be shown or not
- *
- * @param bVisible
- */
- void setGridVisible(boolean bVisible);
-
- /**
- * sets the grid's dimension
- *
- * @param d
- * The new grid spacing
- */
- void setGridSpacing(Dimension d);
-
- /**
- * set the grid's foregoundColor
- *
- * @param c -
- * The new foreground color
- */
- void setGridForegroundColor(Color c);
-
- /**
- * set the connection router's style, it can be LINE_ROUTING_MANUAL,
- * LINE_ROUTING_MANHATTAN
- *
- * @param style -
- * The new connection router's style
- */
- void setConnectionRouterStyle(int style);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/INodePreference.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/INodePreference.java
deleted file mode 100644
index 3a2a3f938..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/INodePreference.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-
-/**
- * This interface can be used to set NodeEditPart's preference
- *
- * @author Xiaoguang Zhang
- *
- */
-
-public interface INodePreference extends IFigurePreference {
-
- /**
- * Sets the text placement of the label relative to its icon. The default is
- * {@link org.eclipse.draw2d.PositionConstants#EAST}. Other possible values are
- * {@link org.eclipse.draw2d.PositionConstants#NORTH}, {@link org.eclipse.draw2d.PositionConstants#SOUTH} and
- * {@link org.eclipse.draw2d.PositionConstants#WEST}.
- *
- * @param where
- * the text placement
- */
- void setTextPlacement(int where);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PFValidator.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PFValidator.java
deleted file mode 100644
index 413a5a1f9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PFValidator.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-/**
- * @author hmeng
- */
-
-public interface PFValidator {
- /**
- * Validate the current page flow
- */
- void validate();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowContainerEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowContainerEditPart.java
deleted file mode 100644
index 83590a129..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowContainerEditPart.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PageflowContainerEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PageflowXYLayoutEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.PFBatchAdapter;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * abstract class for pageflow container.
- */
-abstract class PageflowContainerEditPart extends PageflowElementEditPart {
-
- /**
- * @param element -
- * pageflow model.
- */
- public PageflowContainerEditPart(PageflowElement element) {
- super(element);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#createFigure()
- */
- protected IFigure createFigure() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#createEditPolicies()
- */
- protected void createEditPolicies() {
- installEditPolicy(EditPolicy.CONTAINER_ROLE,
- new PageflowContainerEditPolicy());
- installEditPolicy(EditPolicy.LAYOUT_ROLE,
- new PageflowXYLayoutEditPolicy());
- }
-
- public Adapter createEMFAdapter() {
- return new PFBatchAdapter() {
- /*
- * (non-Javadoc)
- *
- * @see PageflowElementEditPart#notifyChanged(Notification)
- */
- public void doNotifyChanged(Notification notification) {
- int type = notification.getEventType();
-
- switch (type) {
- case Notification.ADD:
- case Notification.ADD_MANY:
- case Notification.REMOVE:
- case Notification.REMOVE_MANY:
- refreshChildrenOnUIThread();
- break;
- case Notification.SET:
- refreshVisualsOnUIThread();
- break;
- }
- super.notifyChanged(notification);
- }
- };
- }
-
- private void refreshChildrenOnUIThread() {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshChildren();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshChildren();
- }
- });
- }
- }
-
- private void refreshVisualsOnUIThread() {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshVisuals();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshVisuals();
- }
- });
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowDirectEditManager.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowDirectEditManager.java
deleted file mode 100644
index 5fa56d1fd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowDirectEditManager.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.tools.CellEditorLocator;
-import org.eclipse.gef.tools.DirectEditManager;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * DirectEditManager for Pageflow node
- *
- * @author - Xiaoguang Zhang
- */
-/*package*/ final class PageflowDirectEditManager extends DirectEditManager {
- /** text font */
- private Font scaledFont;
-
- /** verify listener for the text control */
- private VerifyListener verifyListener;
-
- /** the direct editor's parent label. */
- private final Label label;
-
- /**
- * Creates a new PageflowDirectEditManager with the given attributes.
- *
- * @param source
- * the source EditPart
- * @param editorType
- * type of editor
- * @param locator
- * the CellEditorLocator
- * @param label
- */
- public PageflowDirectEditManager(GraphicalEditPart source,
- Class editorType, CellEditorLocator locator, Label label) {
- super(source, editorType, locator);
- this.label = label;
- }
-
- /*
- * (non-javadoc)
- *
- * @see org.eclipse.gef.tools.DirectEditManager#bringDown()
- */
- protected void bringDown() {
- // This method might be re-entered when super.bringDown() is called.
- Font disposeFont = scaledFont;
- scaledFont = null;
- super.bringDown();
- if (disposeFont != null && !disposeFont.isDisposed()) {
- disposeFont.dispose();
- }
- }
-
- /*
- * (non-javadoc)
- *
- * @see org.eclipse.gef.tools.DirectEditManager#initCellEditor()
- */
- protected void initCellEditor() {
- Text text = (Text) getCellEditor().getControl();
- verifyListener = new VerifyListener() {
- public void verifyText(VerifyEvent event) {
- Text text_ = (Text) getCellEditor().getControl();
- String oldText = text_.getText();
- // get the left string of the new input character
- String leftText = oldText.substring(0, event.start);
- // get the right string of the new input charactor
- String rightText = oldText.substring(event.end, oldText
- .length());
-
- GC gc = new GC(text_);
- Point size = gc.textExtent(leftText + event.text + rightText);
- gc.dispose();
- if (size.x != 0) {
- size = text_.computeSize(size.x, SWT.DEFAULT);
- }
- getCellEditor().getControl().setSize(size.x, size.y);
- }
- };
- text.addVerifyListener(verifyListener);
-
- // set the initial text, font, to the direct editor
- String initialLabelText = label.getText();
- getCellEditor().setValue(initialLabelText);
- IFigure figure = getEditPart().getFigure();
- final Font figureFont = figure.getFont();
- // take a copy of the font data for the label we are cell editing
- FontData data = figureFont.getFontData()[0];
- Dimension fontSize = new Dimension(0, data.getHeight());
- label.translateToAbsolute(fontSize);
- data.setHeight(fontSize.height);
-
- if (scaledFont != null && !scaledFont.isDisposed())
- {
- scaledFont.dispose();
- }
- scaledFont = new Font(figureFont.getDevice(), data);
-
- text.setFont(scaledFont);
- text.selectAll();
- }
-
- /*
- * (non-javadoc)
- *
- * @see org.eclipse.gef.tools.DirectEditManager#unhookListeners()
- */
- protected void unhookListeners() {
- super.unhookListeners();
- Text text = (Text) getCellEditor().getControl();
- text.removeVerifyListener(verifyListener);
- verifyListener = null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPart.java
deleted file mode 100644
index 3f3a80f7a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPart.java
+++ /dev/null
@@ -1,424 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.draw2d.BendpointConnectionRouter;
-import org.eclipse.draw2d.ConnectionLayer;
-import org.eclipse.draw2d.FanRouter;
-import org.eclipse.draw2d.FreeformLayer;
-import org.eclipse.draw2d.FreeformLayout;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.ManhattanConnectionRouter;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.util.TreeIterator;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.CompoundSnapToHelper;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.LayerConstants;
-import org.eclipse.gef.SnapToGeometry;
-import org.eclipse.gef.SnapToGrid;
-import org.eclipse.gef.SnapToGuides;
-import org.eclipse.gef.SnapToHelper;
-import org.eclipse.gef.editparts.AbstractEditPart;
-import org.eclipse.gef.editparts.GridLayer;
-import org.eclipse.gef.editpolicies.RootComponentEditPolicy;
-import org.eclipse.gef.editpolicies.SnapFeedbackPolicy;
-import org.eclipse.gef.rulers.RulerProvider;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.FC2PFTransformer;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.PFBatchAdapter;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowAnnotationUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * The container editr part for the whole pageflow, which uses the
- * WindowFigure(GEM) as the container figure.
- *
- */
-public class PageflowEditPart extends PageflowContainerEditPart implements
- LayerConstants, ILayerPanePreference {
- /** The seperation for the two possible coincided connections */
- private static final int CONNECTION_SEPERATION = 20;
-
- private int connectionStyle = -1;
-
- /**
- * Creates a new PageflowEditPart instance.
- *
- * @param pageflow -
- * pageflow model
- */
- protected PageflowEditPart(Pageflow pageflow) {
- super(pageflow);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#createFigure()
- */
- protected IFigure createFigure() {
- FreeformLayer layer = new FreeformLayer();
- // layer.setOpaque(true);
- layer.setLayoutManager(new FreeformLayout());
- return layer;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#createEditPolicies()
- */
- protected void createEditPolicies() {
- super.createEditPolicies();
-
- installEditPolicy(EditPolicy.NODE_ROLE, null);
- installEditPolicy(EditPolicy.GRAPHICAL_NODE_ROLE, null);
- // installEditPolicy(EditPolicy.SELECTION_FEEDBACK_ROLE, null);
- installEditPolicy(EditPolicy.COMPONENT_ROLE,
- new RootComponentEditPolicy());
- installEditPolicy("Snap Feedback", new SnapFeedbackPolicy()); //$NON-NLS-1$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.core.runtime.IAdaptable#getAdapter(java.lang.Class)
- */
- public Object getAdapter(Class key) {
- if (key == SnapToHelper.class) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
-
- List snapStrategies = new ArrayList();
- Boolean bRulerVisible = (Boolean) getViewer().getProperty(
- RulerProvider.PROPERTY_RULER_VISIBILITY);
- if (bRulerVisible != null && bRulerVisible.booleanValue()) {
- snapStrategies.add(new SnapToGuides(this));
- }
-
- boolean bSnapToGeometry = store
- .getBoolean(GEMPreferences.SNAP_TO_GEOMETRY);
- if (bSnapToGeometry) {
- snapStrategies.add(new SnapToGeometry(this));
- }
- boolean bSnapToGrid = store.getBoolean(GEMPreferences.SNAP_TO_GRID);
- if (bSnapToGrid) {
- snapStrategies.add(new SnapToGrid(this));
- }
-
- if (snapStrategies.size() == 0) {
- return null;
- }
- if (snapStrategies.size() == 1) {
- return snapStrategies.get(0);
- }
-
- SnapToHelper ss[] = new SnapToHelper[snapStrategies.size()];
- for (int i = 0; i < snapStrategies.size(); i++) {
- ss[i] = (SnapToHelper) snapStrategies.get(i);
- }
- return new CompoundSnapToHelper(ss);
- }
- return super.getAdapter(key);
- }
-
- /**
- * Returns the Pageflow.
- *
- * @return the pageflow
- */
- public Pageflow getPageflow() {
- return (Pageflow) getPageflowElement();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#getModelChildren()
- */
- protected List getModelChildren() {
- List allChildren = new LinkedList();
- Iterator it;
-
- it = getPageflow().getNodes().iterator();
- while (it.hasNext()) {
- allChildren.add(it.next());
- }
-
- return allChildren;
- }
-
- public Adapter createEMFAdapter() {
- return new PFBatchAdapter() {
- /*
- * (non-Javadoc)
- *
- * @see Adapter#notifyChanged(Notification)
- */
- public void doNotifyChanged(Notification notification) {
- int type = notification.getEventType();
-
- // int featureId = notification.getFeatureID(
- // PageflowPackage.class );
- switch (type) {
- case Notification.ADD:
- case Notification.ADD_MANY:
- case Notification.REMOVE:
- case Notification.REMOVE_MANY:
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshChildren();
- }
- else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
-
- public void run() {
- refreshChildren();
- }
-
- });
- }
- break;
-
- case Notification.SET:
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshChildren();
- refreshVisuals();
- }
- else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
-
- public void run() {
- refreshChildren();
- refreshVisuals();
- }
-
- });
- }
- break;
- case FC2PFTransformer.MY_NOTIFICATION_TYPE1:
- restore((Pageflow) getModel());
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshChildren();
- refreshVisuals();
- }
- else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
-
- public void run() {
- refreshChildren();
- refreshVisuals();
- }
-
- });
- }
- break;
- // restore all children
- case FC2PFTransformer.MY_NOTIFICATION_TYPE:
- // stop all children
- postPone((Pageflow) getModel());
- break;
- }
- }
-
- protected void restore(Pageflow pageflow) {
- TreeIterator nodes;
- // restore
- nodes = pageflow.eAllContents();
- while (nodes.hasNext()) {
- setPostpone((EObject) nodes.next(), false);
- }
- setPostpone(pageflow, false);
- }
-
- void setPostpone(EObject node, boolean enable) {
- List adapters = node.eAdapters();
- for (int i = 0; i < adapters.size(); i++) {
- if (adapters.get(i) instanceof PFBatchAdapter) {
- ((PFBatchAdapter) adapters.get(i))
- .setNeedPostpone(enable);
- }
- }
- }
-
- protected void postPone(Pageflow pageflow) {
- TreeIterator nodes;
- // postpone
- nodes = pageflow.eAllContents();
- while (nodes.hasNext()) {
- setPostpone((EObject) nodes.next(), true);
- }
- setPostpone(pageflow, true);
- }
-
- };
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editparts.AbstractEditPart#refreshVisuals()
- */
- protected void refreshVisuals() {
- super.refreshVisuals();
- for (int i = 0; i < this.getChildren().size(); i++) {
- ((AbstractEditPart) getChildren().get(i)).refresh();
- }
- ConnectionLayer cLayer = (ConnectionLayer) getLayer(CONNECTION_LAYER);
-
- if (cLayer.getConnectionRouter() == null) {
- setConnectionRouterStyle(getConnectionRouterStyle());
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editparts.AbstractEditPart#refreshChildren()
- */
- protected void refreshChildren() {
- super.refreshChildren();
- PageflowAnnotationUtil.validatePageflow(this);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setFont(org.eclipse.swt.graphics.Font)
- */
- public void setFont(Font f) {
- getFigure().setFont(f);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.ILayerPanePreference#setConnectionRouterStyle(int)
- */
- public void setConnectionRouterStyle(int style) {
- //TODO does this need to be execed on UI thread only???
- connectionStyle = style;
- ConnectionLayer cLayer = (ConnectionLayer) getLayer(CONNECTION_LAYER);
- if (style == ILayerPanePreference.LINE_ROUTING_MANHATTAN) {
- FanRouter router = new FanRouter();
- router.setSeparation(CONNECTION_SEPERATION);
- router.setNextRouter(new ManhattanConnectionRouter());
- cLayer.setConnectionRouter(router);
- } else if (style == ILayerPanePreference.LINE_ROUTING_MANUAL) {
- FanRouter router = new FanRouter();
- router.setSeparation(CONNECTION_SEPERATION);
- router.setNextRouter(new BendpointConnectionRouter());
- cLayer.setConnectionRouter(router);
- }
- }
-
- /**
- * get the foreground color from preference
- * @return the router style value
- *
- */
- public int getConnectionRouterStyle() {
- if (this.connectionStyle == -1) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
- String connectionStyle_ = store
- .getString(GEMPreferences.LINE_ROUTING);
-
- if (GEMPreferences.LINE_ROUTING_MANHATTAN.equals(connectionStyle_)) {
- this.connectionStyle = ILayerPanePreference.LINE_ROUTING_MANHATTAN;
- } else {
- this.connectionStyle = ILayerPanePreference.LINE_ROUTING_MANUAL;
- }
- }
- return this.connectionStyle;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setForegroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setForegroundColor(Color c) {
- getFigure().setForegroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setBackgroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setBackgroundColor(Color c) {
- // getLayer(PRIMARY_LAYER).setOpaque(true);
- getLayer(PRIMARY_LAYER).setBackgroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setGridVisible(boolean)
- */
- public void setGridVisible(boolean bVisible) {
- GridLayer gl = (GridLayer) getLayer(GRID_LAYER);
- gl.setVisible(bVisible);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setGridSpacing(org.eclipse.draw2d.geometry.Dimension)
- */
- public void setGridSpacing(Dimension d) {
- GridLayer gl = (GridLayer) getLayer(GRID_LAYER);
- gl.setSpacing(d);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.ILayerPanePreference#setGridForegroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setGridForegroundColor(Color c) {
- GridLayer gl = (GridLayer) getLayer(GRID_LAYER);
- gl.setForegroundColor(c);
- }
-
- protected void performDirectEdit() {
- // do nothing
- }
-
- protected void performOpen() {
- // do nothing
- }
-
- public void addAnnotation(Annotation annotation) {
- // do nothing
-
- }
-
- public void removeAnnotation() {
- // do nothing
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPartsFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPartsFactory.java
deleted file mode 100644
index fe5723589..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowEditPartsFactory.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- *
- * Edit part factory to create different pageflow elements.
- *
- *
- */
-public class PageflowEditPartsFactory implements EditPartFactory {
- /*
- * (non-Javadoc)
- *
- * @see EditPartFactory#createEditPart(EditPart, Object)
- */
- public EditPart createEditPart(EditPart context, Object obj) {
- if (obj instanceof Pageflow) {
- return new PageflowEditPart((Pageflow) obj);
- } else if (obj instanceof PageflowNode) {
- return new PageflowNodeEditPart((PageflowNode) obj);
- } else if (obj instanceof PageflowLink) {
- return new PageflowLinkEditPart((PageflowLink) obj);
- }
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementEditPart.java
deleted file mode 100644
index b897c5e24..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementEditPart.java
+++ /dev/null
@@ -1,362 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.RequestConstants;
-import org.eclipse.gef.editparts.AbstractGraphicalEditPart;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure.PageflowNodeFigure;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowElementPropertySource;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.PFBatchAdapter;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- *
- *
- * <code>PageflowElementEditPart</code> is the base class for all the
- * EditParts in the application, whose model is a subclass of PageflowElement.
- * This class maintains the figure's size and location inresponse to changes in
- * the model, and registers as a listener on its model using the
- * <code>org.eclipse.emf.common.notify.Adapter</code> interface
- */
-public abstract class PageflowElementEditPart extends AbstractGraphicalEditPart
- implements IAnnotationEditPart {
- /** image description for different edit part */
- public static final ImageDescriptor IMG_ACTION = EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/Pageflow_Action16.gif"); //$NON-NLS-1$
-
- private Adapter adapter;
-
- /**
- * @return the emf adapter
- */
- public Adapter createEMFAdapter() {
- return new PFBatchAdapter() {
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#notifyChanged()
- */
- public void doNotifyChanged(Notification notification) {
- int type = notification.getEventType();
- int featureId = notification
- .getFeatureID(PageflowPackage.class);
- if (type == Notification.SET) {
- switch (featureId) {
- case PageflowPackage.PAGEFLOW_ELEMENT__X:
- case PageflowPackage.PAGEFLOW_ELEMENT__Y:
- case PageflowPackage.PAGEFLOW_ELEMENT__WIDTH:
- case PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT:
- refreshVisuals();
- break;
- }
- }
- }
- };
- }
-
- private static final ImageDescriptor IMG_PAGE = EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/Pageflow_Page.gif"); //$NON-NLS-1$
-
- private static final ImageDescriptor IMG_NODE = EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/FacesConfig_Pageflow16.gif"); //$NON-NLS-1$
-
- /** property source of the pageflow element */
- private IPropertySource propertySource = null;
-
- private Image image = null;
-
- /**
- * @param element
- */
- protected PageflowElementEditPart(PageflowElement element) {
- setModel(element);
- }
-
- /**
- * Returns the image for the pageflow element.
- *
- * @param element -
- * pageflow element
- * @return - the image for the pageflow element.
- */
- public Image getImage(PageflowElement element) {
- if (image == null) {
- ImageDescriptor imageDescriptor = null;
-
- if (element instanceof PageflowPage) {
- imageDescriptor = IMG_PAGE;
- } else {
- imageDescriptor = IMG_NODE;
- }
-
- image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- if (null == image) {
- EditorPlugin.getDefault().getImageRegistry().put(
- imageDescriptor.toString(), imageDescriptor);
- image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- }
- }
-
- return image;
- }
-
- /**
- * get the type name of the pageflow element
- *
- * @param element -
- * pageflow element
- * @return - the type name of the pageflow element
- */
- public static String getTypeName(PageflowElement element) {
- if (element instanceof Pageflow) {
- return "Pageflow"; //$NON-NLS-1$
- } else if (element instanceof PageflowPage) {
- return "Page"; //$NON-NLS-1$
- }
-
- return "[unknown]"; //$NON-NLS-1$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#activate()
- */
- public void activate() {
- if (isActive()) {
- return;
- }
-
- // start listening for changes in the model
- hookIntoPageflowElement(getPageflowElement());
-
- super.activate();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#deactivate()
- */
- public void deactivate() {
- if (!isActive()) {
- return;
- }
-
- // stop listening for changes in the model
- unhookFromPageflowElement(getPageflowElement());
-
- super.deactivate();
- }
-
- /**
- * Returns the model as pageflow element.
- *
- * @return - pageflow element
- */
- public PageflowElement getPageflowElement() {
- return (PageflowElement) getModel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#refreshVisuals()
- */
- protected void refreshVisuals() {
- if (getParent() != null) {
- final AbstractGraphicalEditPart part = this;
- //ensure that this is executed on the UI thread
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshVisuals(part);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
-
- public void run() {
- refreshVisuals(part);
- }
- });
- }
- }
- }
-
- private void refreshVisuals(AbstractGraphicalEditPart part) {
- Point loc = new Point(getPageflowElement().getX(),
- getPageflowElement().getY());
- Dimension size = new Dimension(getPageflowElement().getWidth(),
- getPageflowElement().getHeight());
- Rectangle r = new Rectangle(loc, size);
-
- ((GraphicalEditPart) getParent()).setLayoutConstraint(part,
- getFigure(), r);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IAdaptable#getAdapter(Class)
- */
- public Object getAdapter(Class key) {
- /*
- * override the default behavior defined in AbstractEditPart which would
- * expect the model to be a property sourced. instead the editpart can
- * provide a property source
- */
- if (key == IPropertySource.class) {
- return getPropertySource();
- }
- if (key == Adapter.class) {
- if (adapter == null) {
- adapter = createEMFAdapter();
- }
- return adapter;
- }
- return super.getAdapter(key);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see PageflowElementEditPart#getPropertySource()
- */
- private IPropertySource getPropertySource() {
- if (propertySource == null) {
- propertySource = new PageflowElementPropertySource(
- getPageflowElement());
- }
- return propertySource;
- }
-
- /**
- * Registers this edit part as a listener for change notifications to the
- * specified pageflow element.
- *
- * @param element
- * the pagelfow element that should be observed for change
- * notifications
- */
- protected void hookIntoPageflowElement(PageflowElement element) {
- if (null != element) {
- if (!element.eAdapters().contains(getAdapter(Adapter.class))) {
- element.eAdapters().add((Adapter) getAdapter(Adapter.class));
- }
- }
- }
-
- /**
- * Removes this edit part from the specified pageflow element. Thus, it will
- * no longe receive change notifications.
- *
- * @param element
- * the pagelfow element that should not be observed any more
- */
- protected void unhookFromPageflowElement(PageflowElement element) {
- if (null != element) {
- element.eAdapters().remove(getAdapter(Adapter.class));
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#createFigure()
- */
- protected IFigure createFigure() {
- IFigure figure_ = null;
- figure_ = new PageflowNodeFigure();
- PageflowElement elm = getPageflowElement();
- if (elm.getName() != null) {
- ((PageflowNodeFigure) figure_).setImageText(getImage(elm), elm
- .getName());
- } else {
- ((PageflowNodeFigure) figure_).setImageText(getImage(elm),
- getTypeName(elm));
- }
- ((PageflowNodeFigure) figure_).update();
- return figure_;
- }
-
- /**
- * perform corresponding request related with double click or direct edit
- * click.
- *
- * @param request :
- * request composed by mouse click.
- */
- public void performRequest(Request request) {
- // the request is triggered by double clicked on a edit part
- if (request.getType() == RequestConstants.REQ_OPEN) {
- performOpen();
- } else if (request.getType() == RequestConstants.REQ_DIRECT_EDIT) {
- performDirectEdit();
- }
- }
-
- /**
- * perfrom direct edit request
- *
- */
- protected abstract void performDirectEdit();
-
- /**
- * perform double click request
- *
- */
- protected abstract void performOpen();
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#decorateEditPart()
- */
- public abstract void addAnnotation(Annotation annotation);
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#undecorateEditPart()
- */
- public abstract void removeAnnotation();
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.marker.IEditPartMarker#getMarkerResource()
- */
- public IResource getMarkerResource() {
- IResource resource = WebrootUtil.getResource((EObject) getModel());
- return resource;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementTreeEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementTreeEditPart.java
deleted file mode 100644
index 9336e11e9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowElementTreeEditPart.java
+++ /dev/null
@@ -1,257 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.gef.editparts.AbstractTreeEditPart;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowElementPropertySource;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * This is the abstract base <code>TreeEditPart</code> for pageflow elements.
- */
-public class PageflowElementTreeEditPart extends AbstractTreeEditPart implements
- Adapter {
- /** Image descriptor of tree item for the different edit parts */
- private static final ImageDescriptor IMG_PAGE = EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/Pageflow_Page16.gif"); //$NON-NLS-1$
-
- private static final ImageDescriptor IMG_NODE = EditorPlugin.getDefault()
- .getImageDescriptor("facesconfig/FacesConfig_Pageflow16.gif"); //$NON-NLS-1$
-
- /** Property resource for shared property view */
- private IPropertySource propertySource = null;
-
- /** notifer to pageflow element */
- private Notifier target = null;
-
- /**
- * Returns the image for the pageflow element.
- *
- * @param element -
- * pageflow element, such as Begin, End, Page, and Action.
- * @return - the image for the pageflow element
- */
- public static Image getImage(PageflowElement element) {
- ImageDescriptor imageDescriptor = null;
-
- if (element instanceof PageflowPage) {
- imageDescriptor = IMG_PAGE;
- } else {
- imageDescriptor = IMG_NODE;
- }
-
- if (null == imageDescriptor) {
- return null;
- }
-
- Image image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- if (null == image) {
- EditorPlugin.getDefault().getImageRegistry().put(
- imageDescriptor.toString(), imageDescriptor);
- image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- }
-
- return image;
- }
-
- /**
- * Creates a new PageflowElementTreeEditPart instance.
- *
- * @param pageflowElement -
- * create a new edit part according to the pageflow model
- */
- public PageflowElementTreeEditPart(PageflowElement pageflowElement) {
- super(pageflowElement);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IAdaptable#getAdapter(Class)
- */
- public Object getAdapter(Class key) {
- /*
- * override the default behavior defined in AbstractEditPart which would
- * expect the model to be a property sourced. instead the editpart can
- * provide a property source
- */
- if (key == IPropertySource.class) {
- return getPropertySource();
- }
- return super.getAdapter(key);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTreeEditPart#getImage()
- */
- protected Image getImage() {
- return getImage(getPageflowElement());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see PageflowElementEditPart#getPropertySource()
- */
- private IPropertySource getPropertySource() {
- if (propertySource == null) {
- propertySource = new PageflowElementPropertySource(
- getPageflowElement());
- }
- return propertySource;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Adapter#getTarget()
- */
- public Notifier getTarget() {
- return target;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractTreeEditPart#getText()
- */
- protected String getText() {
- return (null != getPageflowElement().getName() ? getPageflowElement()
- .getName() : "[unnamed]"); //$NON-NLS-1$
- }
-
- /**
- * Returns the model as <code>PageflowElement</code>.
- *
- * @return - the model as <code>PageflowElement</code>
- */
- public PageflowElement getPageflowElement() {
- return (PageflowElement) getModel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Adapter#isAdapterForType(Object)
- */
- public boolean isAdapterForType(Object type) {
- return type.equals(getModel().getClass());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Adapter#notifyChanged(Notification)
- */
- public void notifyChanged(Notification notification) {
- int type = notification.getEventType();
-
- switch (type) {
- case Notification.ADD:
- case Notification.ADD_MANY:
- case Notification.REMOVE:
- case Notification.REMOVE_MANY:
- case Notification.SET:
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshVisuals();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshVisuals();
- }
- });
- }
- break;
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Adapter#setTarget(Notifier)
- */
- public void setTarget(Notifier newTarget) {
- target = newTarget;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#activate()
- */
- public void activate() {
- if (isActive())
- return;
-
- // start listening for changes in the model
- hookIntoPageflowElement(getPageflowElement());
-
- super.activate();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#deactivate()
- */
- public void deactivate() {
- if (!isActive())
- return;
-
- // stop listening for changes in the model
- unhookFromPageflowElement(getPageflowElement());
-
- super.deactivate();
- }
-
- /**
- * Registers this edit part as a listener for change notifications to the
- * specified pageflow element.
- *
- * @param element -
- * the pagelfow element that should be observed for change
- * notifications
- */
- protected void hookIntoPageflowElement(PageflowElement element) {
- if (null != element) {
- element.eAdapters().add(this);
- }
- }
-
- /**
- * Removes this edit part from the specified pageflow element. Thus, it will
- * no longe receive change notifications.
- *
- * @param element
- * -the pagelfow element that should not be observed
- */
- protected void unhookFromPageflowElement(PageflowElement element) {
- if (null != element) {
- element.eAdapters().remove(this);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowLinkEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowLinkEditPart.java
deleted file mode 100644
index f1bc513b0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowLinkEditPart.java
+++ /dev/null
@@ -1,491 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.RelativeBendpoint;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.editparts.AbstractConnectionEditPart;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PFLinkBendpointEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PFLinkEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PFLinkEndpointEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure.PFLinkFigure;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PageflowLinkPropertySource;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.PFBatchAdapter;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowAnnotationUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <code>PFLinkEditPart</code> is the EditPart for PFLink model elements. The
- * figure for this EditPart is simply a PolylineConnection. Because both
- * AbstractConnectionEditPart and the Adapter interface have a getTarget method,
- * we use an inner class to implement the Adapter interface in order to work
- * around the name collision.
- *
- *
- */
-public class PageflowLinkEditPart extends AbstractConnectionEditPart implements
- IConnectionPreference, IAnnotationEditPart, PFValidator {
- private static final String PAGEFLOW_ERROR_IMAGE_FILE = "facesconfig/Pageflow_Quickfix_Error.gif"; //$NON-NLS-1$
-
- /** adapter for notification */
- private PFLinkAdapter adapter = new PFLinkAdapter();
-
- /** property source of the pflink */
- private IPropertySource propertySource = null;
-
- /** image description for different edit part */
- public static final ImageDescriptor IMG_WARNING = EditorPlugin.getDefault()
- .getImageDescriptor(PAGEFLOW_ERROR_IMAGE_FILE);
-
- private int connectionStyle = -1;
-
- private PFLinkBendpointEditPolicy bendpointEditPolicy;
-
- /**
- * @param element
- */
- public PageflowLinkEditPart(PageflowLink element) {
- super();
- // element.getPageflow()
- setModel(element);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#createFigure()
- */
- protected IFigure createFigure() {
- IFigure figure_ = new PFLinkFigure();
- return figure_;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#createEditPolicies()
- */
- protected void createEditPolicies() {
- installEditPolicy(EditPolicy.CONNECTION_ENDPOINTS_ROLE,
- new PFLinkEndpointEditPolicy());
-
- if (getConnectionRouterStyle() == ILayerPanePreference.LINE_ROUTING_MANUAL) {
- installEditPolicy(EditPolicy.CONNECTION_BENDPOINTS_ROLE,
- getBendpointEditPolicy());
- }
- //PFLinkEditPolicy policy = new PFLinkEditPolicy();
- // policy.setSseModel(model);
- installEditPolicy(EditPolicy.CONNECTION_ROLE, new PFLinkEditPolicy());
-
- }
-
- private PFLinkBendpointEditPolicy getBendpointEditPolicy() {
- if (bendpointEditPolicy == null) {
- bendpointEditPolicy = new PFLinkBendpointEditPolicy();
- }
- return bendpointEditPolicy;
- }
-
- private PageflowLink getPFLink() {
- return (PageflowLink) getModel();
- }
-
- private class PFLinkAdapter extends PFBatchAdapter {
- private Notifier _newTarget = null;
-
- // private IPropertySource _propertySource = null;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.Adapter#getTarget()
- */
- public Notifier getTarget() {
- return _newTarget;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.Adapter#isAdapterForType(java.lang.Object)
- */
- public boolean isAdapterForType(Object type) {
- return getModel().getClass() == type;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.Adapter#notifyChanged(org.eclipse.emf.common.notify.Notification)
- */
- public void doNotifyChanged(Notification notification) {
- int type = notification.getEventType();
- int featureId = notification.getFeatureID(PageflowPackage.class);
- // FC2PFTransformer.getInstance().NotifyChanged(notification,
- // getPFLink());
- switch (type) {
- case Notification.ADD:
- case Notification.ADD_MANY:
- case Notification.REMOVE:
- case Notification.SET:
- if (featureId == PageflowPackage.PF_LINK__OUTCOME
- || featureId == PageflowPackage.PF_LINK__SOURCE
- || featureId == PageflowPackage.PF_LINK__TARGET) {
- PageflowAnnotationUtil
- .validateLink(PageflowLinkEditPart.this);
- }
-
- refreshVisualsOnUIThread();
- break;
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.Adapter#setTarget(org.eclipse.emf.common.notify.Notifier)
- */
- public void setTarget(Notifier newTarget) {
- this._newTarget = newTarget;
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see EditPart#activate()
- */
- public void activate() {
- getPFLink().eAdapters().add(adapter);
- //PageflowLink element = (PageflowLink) getModel();
- super.activate();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see EditPart#deactivate()
- */
- public void deactivate() {
- // getPFLink().eAdapters().remove(adapter);
- // PageflowLink element = (PageflowLink) getModel();
- // NavigationCaseType navCase = ((NavigationCaseType) element
- // .getFCElements().getData().get(0));
- // navCase.eAdapters().remove(fcAdapter);
- // TreeIterator iterator = navCase.eAllContents();
- // while (iterator.hasNext()) {
- // ((EObject) iterator.next()).eAdapters().remove(fcAdapter);
- // }
-
- super.deactivate();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IAdaptable#getAdapter(java.lang.Class)
- */
- public Object getAdapter(Class key) {
- /*
- * override the default behavior defined in AbstractEditPart which would
- * expect the model to be a property sourced. instead the editpart can
- * provide a property source
- */
- if (key == IPropertySource.class) {
- return getPropertySource();
- }
- return super.getAdapter(key);
- }
-
- private IPropertySource getPropertySource() {
- if (propertySource == null) {
- propertySource = new PageflowLinkPropertySource(getPFLink());
- }
- return propertySource;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#refreshVisuals()
- */
- protected void refreshVisuals() {
- super.refreshVisuals();
- resetLabel();
- if (getConnectionRouterStyle() == ILayerPanePreference.LINE_ROUTING_MANUAL) {
- refreshBendpoints();
- }
- }
-
- private void refreshVisualsOnUIThread() {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshVisuals();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshVisuals();
- }
- });
- }
- }
-
- /**
- * set the bendpoint constraints of the pflink connection
- *
- */
- protected void refreshBendpoints() {
- // bendpoints stored in pflink
- List modelConstraint = getPFLink().getBendPoints();
- // bendpoint constraint list
- List figureConstraint = new ArrayList();
- for (int i = 0; i < modelConstraint.size(); i++) {
- PageflowLinkBendpoint wbp = (PageflowLinkBendpoint) modelConstraint
- .get(i);
- RelativeBendpoint rbp = new RelativeBendpoint(getConnectionFigure());
- rbp.setRelativeDimensions(wbp.getFirstRelativeDimension(), wbp
- .getSecondRelativeDimension());
- rbp.setWeight((i + 1) / ((float) modelConstraint.size() + 1));
- figureConstraint.add(rbp);
- }
- // set the router constaints.
- getConnectionFigure().setRoutingConstraint(figureConstraint);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IConnectionPreference#setLineWidth(int)
- */
- public void setLineWidth(int w) {
- ((PFLinkFigure) getFigure()).setLineWidth(w);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IConnectionPreference#setLabelVisible(boolean)
- */
- public void setLabelVisible(boolean b) {
- ((PFLinkFigure) getFigure()).setLabelVisible(b);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setForegroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setForegroundColor(Color c) {
- ((PFLinkFigure) getFigure()).setForegroundColor(c);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setBackgroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setBackgroundColor(Color c) {
- ((PFLinkFigure) getFigure()).setBackgroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setFont(org.eclipse.swt.graphics.Font)
- */
- public void setFont(Font f) {
- ((PFLinkFigure) getFigure()).setFont(f);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IConnectionPreference#setLabelForeground(org.eclipse.swt.graphics.Color)
- */
- public void setLabelForegroundColor(Color c) {
- ((PFLinkFigure) getFigure()).setLabelForegroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IConnectionPreference#setLabelBackground(org.eclipse.swt.graphics.Color)
- */
- public void setLabelBackgroundColor(Color c) {
- ((PFLinkFigure) getFigure()).setLabelBackgroundColor(c);
- }
-
- private boolean needDrawingLabel() {
- return (((PageflowLink) getModel()).getOutcome() != null && ((PageflowLink) getModel())
- .getOutcome().trim().length() > 0);
- }
-
- private boolean needDrawingAction() {
- return (((PageflowLink) getModel()).getFromaction() != null && ((PageflowLink) getModel())
- .getFromaction().trim().length() > 0);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#decorateEditPart()
- */
- public void addAnnotation(final Annotation annotation) {
- getViewer().getControl().getDisplay().asyncExec(new Runnable() {
- public void run() {
- ((PFLinkFigure) getFigure()).setImage(getImage(IMG_WARNING));
- ((PFLinkFigure) getFigure()).setToolTipText(annotation
- .getText());
- }
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#undecorateEditPart()
- */
- public void removeAnnotation() {
- if (Thread.currentThread() == getViewer().getControl().getDisplay().getThread()) {
- ((PFLinkFigure) getFigure()).clearIcon();
- resetLabel();
- } else {
- getViewer().getControl().getDisplay().asyncExec(new Runnable() {
- public void run() {
- ((PFLinkFigure) getFigure()).clearIcon();
- resetLabel();
- }
- });
- }
- }
-
- private void resetLabel() {
- StringBuffer tip = new StringBuffer();
- if (needDrawingAction()) {
- ((PFLinkFigure) getFigure()).setActionImage();
- tip.append(PageflowMessages.PageflowLinkEditPart_FromAction).append(
- ((PageflowLink) getModel()).getFromaction());
- } else if (((PFLinkFigure) getFigure()).getImage() != getImage(IMG_WARNING)) {
- ((PFLinkFigure) getFigure()).clearIcon();
- }
- if (needDrawingLabel()) {
- ((PFLinkFigure) getFigure()).setLabel(((PageflowLink) getModel())
- .getOutcome());
- if (tip.length() > 0)
- tip.append("\n"); //$NON-NLS-1$
- tip.append(PageflowMessages.PageflowLinkEditPart_FromOutcome).append(
- ((PageflowLink) getModel()).getOutcome());
- } else {
- ((PFLinkFigure) getFigure()).clearOutcome();
- }
- ((PFLinkFigure) getFigure()).setToolTipText(tip.toString());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.marker.IEditPartMarker#getMarkerResource()
- *
- */
- public IResource getMarkerResource() {
- // IResource resource = null;
- // if (getModel() instanceof PFLink)
- // {
- // resource =
- // FacesConfigUtil.getFacesConfigResource(((PFLink)getModel()).getPageflow());
- // }
- // FIXME: it should be changed to link to faces-config file.
- IResource resource = WebrootUtil.getResource((EObject) getModel());
- return resource;
- }
-
- private static Image getImage(ImageDescriptor imageDescriptor) {
- Image image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- if (null == image) {
- EditorPlugin.getDefault().getImageRegistry().put(
- imageDescriptor.toString(), imageDescriptor);
- image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- }
-
- return image;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IConnectionPreference#setConnectionRouterStyle(int)
- */
- public void setConnectionRouterStyle(int style) {
- connectionStyle = style;
- if (getConnectionRouterStyle() == ILayerPanePreference.LINE_ROUTING_MANUAL) {
- installEditPolicy(EditPolicy.CONNECTION_BENDPOINTS_ROLE,
- getBendpointEditPolicy());
- refreshVisuals();
- } else {
- removeEditPolicy(EditPolicy.CONNECTION_BENDPOINTS_ROLE);
- refreshVisuals();
- }
-
- }
-
- /**
- * get the foreground color from preference
- *
- */
- private int getConnectionRouterStyle() {
- if (this.connectionStyle == -1) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
- String connectionStyle_ = store
- .getString(GEMPreferences.LINE_ROUTING);
-
- if (GEMPreferences.LINE_ROUTING_MANHATTAN.equals(connectionStyle_)) {
- this.connectionStyle = ILayerPanePreference.LINE_ROUTING_MANHATTAN;
- } else {
- this.connectionStyle = ILayerPanePreference.LINE_ROUTING_MANUAL;
- }
- }
- return this.connectionStyle;
- }
-
- public void validate() {
- PageflowAnnotationUtil.validateLink(this);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowNodeEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowNodeEditPart.java
deleted file mode 100644
index 8eac668e8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowNodeEditPart.java
+++ /dev/null
@@ -1,502 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.draw2d.ConnectionAnchor;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.gef.ConnectionEditPart;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.NodeEditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.requests.DropRequest;
-import org.eclipse.gef.tools.DirectEditManager;
-import org.eclipse.jdt.ui.JavaElementImageDescriptor;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jface.viewers.TextCellEditor;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.OpenEditorCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PageflowElementEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PageflowNodeDirectEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy.PageflowNodeEditPolicy;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure.ILabelDecorator;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure.PageflowNodeFigure;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.PFBatchAdapter;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowAnnotationUtil;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.PlatformUI;
-
-
-/**
- * The base class for the applications EditParts that represent
- * PageflowNode-derived objects in the model. This class implements the
- * NodeEditPart interface which supports:
- * <ul>
- * <li>feedback for Connections when they are being
- * <li>
- * <li>initially connected and when they are disonnected/reconnected</li>
- * </ul>
- *
- *
- */
-public class PageflowNodeEditPart extends PageflowElementEditPart implements
- NodeEditPart, INodePreference, PFValidator {
-
- /** property source of pageflow node */
- // private IPropertySource propertySource = null;
- protected DirectEditManager editManager;
-
- private class ImageDecorator implements ILabelDecorator {
- private Image decrateImage = null;
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.figures.ILabelDecorator#decorateImage(org.eclipse.swt.graphics.Image,
- * java.lang.Object)
- */
- public Image decorateImage(Image image, Object element) {
- dispose();
- int adornmentFlags = computeAdornmentFlags(element);
- if (adornmentFlags != 0) {
- ImageDescriptor baseImage = ImageDescriptor.createFromImage(image);
- org.eclipse.swt.graphics.Rectangle bounds = image.getBounds();
- decrateImage = (new JavaElementImageDescriptor(baseImage,
- adornmentFlags, new org.eclipse.swt.graphics.Point(
- bounds.width, bounds.height))).createImage();
- return decrateImage;
- }
- return image;
- }
-
- /**
- * Computes adornment flags for specified object.
- *
- * Note: This method is for internal use only. Clients should not call
- * this method.
- *
- * @param obj Object to complute flags for.
- * @return Adornment flags.
- */
- protected int computeAdornmentFlags(Object obj) {
- return JavaElementImageDescriptor.WARNING;
- }
-
- /**
- * Disposes this instance.
- */
- public void dispose() {
- if (decrateImage != null) {
- decrateImage.dispose();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.figures.ILabelDecorator#decorateText(java.lang.String,
- * java.lang.Object)
- */
- public String decorateText(String text, Object element) {
- // TODO Auto-generated method stub
- return null;
- }
-
- }
-
- /**
- * Disposes this instance.
- */
- public void dispose() {
- if (imageDecorator != null) {
- imageDecorator.dispose();
- }
- }
-
- private ImageDecorator imageDecorator = null;
-
- /**
- * Creates a new PageflowNodeEditPart instance.
- *
- * @param element -
- * pageflow node
- */
- public PageflowNodeEditPart(PageflowNode element) {
- super(element);
- }
-
- /**
- * get the pageflow node
- *
- * @return - pageflow node
- */
- public PageflowNode getPageflowNode() {
- return (PageflowNode) getModel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#getModelSourceConnections()
- */
- protected List getModelSourceConnections() {
- return getPageflowNode().getOutlinks();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractGraphicalEditPart#getModelTargetConnections()
- */
- protected List getModelTargetConnections() {
- return getPageflowNode().getInlinks();
- }
-
- /**
- * Returns the Figure of this, as a node type figure.
- *
- * @return - Figure as a NodeFigure.
- */
- protected PageflowNodeFigure getPageflowNodeFigure() {
- return (PageflowNodeFigure) getFigure();
- }
-
- public Adapter createEMFAdapter() {
- return new PFBatchAdapter() {
- /**
- * when ports are added to a PageflowNode, add this EditPart as a
- * listener on the port so that it gets notified of PFLinks being
- * added or removed. When links are added or removed from a port
- * owned by the PageflowNode of this EditPart, refresh the
- * connections.
- */
- public void doNotifyChanged(Notification notification) {
- int type = notification.getEventType();
- // FC2PFTransformer.getInstance().NotifyChanged(notification,
- // (PageflowElement) getModel());
- switch (type) {
- case Notification.ADD:
- case Notification.ADD_MANY:
- case Notification.REMOVE:
- case Notification.REMOVE_MANY:
- if (notification.getNewValue() instanceof PageflowLink) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshTargetConnections();
- refreshSourceConnections();
- validate();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshTargetConnections();
- refreshSourceConnections();
- validate();
- }
- });
- }
- }
- break;
-
- case Notification.SET:
- int featureId = notification
- .getFeatureID(PageflowPackage.class);
- if (needValidation(featureId)) {
- validate();
- }
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshVisuals();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable(){
- public void run() {
- refreshVisuals();
- }
- });
- }
- break;
- }
- }
- };
- }
-
- private boolean needValidation(int featureId) {
- if (getModel() instanceof PageflowPage) {
- if (featureId == PageflowPackage.PF_PAGE__PATH) {
- return true;
- }
- }
- return false;
- }
-
- public void validate() {
- if (getModel() instanceof PageflowPage) {
- PageflowAnnotationUtil.validatePage(this);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#createEditPolicies()
- */
- protected void createEditPolicies() {
- // install the edit policy to handle connection creation
- installEditPolicy(EditPolicy.GRAPHICAL_NODE_ROLE,
- new PageflowNodeEditPolicy());
-
- installEditPolicy(EditPolicy.COMPONENT_ROLE,
- new PageflowElementEditPolicy());
-
- // install the direct policy
- installEditPolicy(EditPolicy.DIRECT_EDIT_ROLE,
- new PageflowNodeDirectEditPolicy());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see NodeEditPart#getSourceConnectionAnchor(ConnectionEditPart)
- */
- public ConnectionAnchor getSourceConnectionAnchor(
- ConnectionEditPart connection) {
- PageflowLink link = (PageflowLink) connection.getModel();
- return getPageflowNodeFigure().getSourceConnectionAnchorAt(
- new Point(link.getSource().getX(), link.getSource().getY()));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see NodeEditPart#getSourceConnectionAnchor(Request)
- */
- public ConnectionAnchor getSourceConnectionAnchor(Request request) {
- Point pt = new Point(((DropRequest) request).getLocation());
- return getPageflowNodeFigure().getSourceConnectionAnchorAt(pt);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see NodeEditPart#getTargetConnectionAnchor(ConnectionEditPart)
- */
- public ConnectionAnchor getTargetConnectionAnchor(
- ConnectionEditPart connection) {
- PageflowLink link = (PageflowLink) connection.getModel();
- return getPageflowNodeFigure().getTargetConnectionAnchorAt(
- new Point(link.getTarget().getX(), link.getTarget().getY()));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see NodeEditPart#getTargetConnectionAnchor(Request)
- */
- public ConnectionAnchor getTargetConnectionAnchor(Request request) {
- Point pt = new Point(((DropRequest) request).getLocation());
- return getPageflowNodeFigure().getTargetConnectionAnchorAt(pt);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#refreshVisuals()
- */
- protected void refreshVisuals() {
- super.refreshVisuals();
-
- getPageflowNodeFigure().setText(getPageflowNode().getName());
- }
-
- /**
- * make this a listener on its ports
- */
- public void activate() {
- super.activate();
-
- Iterator it;
-
- it = getPageflowNode().getInlinks().iterator();
- while (it.hasNext()) {
- PageflowLink link = (PageflowLink) it.next();
-
- hookIntoPageflowElement(link);
- }
-
- it = getPageflowNode().getOutlinks().iterator();
- while (it.hasNext()) {
- PageflowLink link = (PageflowLink) it.next();
-
- hookIntoPageflowElement(link);
- }
- }
-
- /**
- * remove this as a listener on its ports
- */
- public void deactivate() {
- super.deactivate();
- dispose();
- Iterator it;
-
- it = getPageflowNode().getInlinks().iterator();
- while (it.hasNext()) {
- PageflowLink link = (PageflowLink) it.next();
-
- unhookFromPageflowElement(link);
- }
-
- it = getPageflowNode().getOutlinks().iterator();
- while (it.hasNext()) {
- PageflowLink link = (PageflowLink) it.next();
-
- unhookFromPageflowElement(link);
- }
- }
-
- /**
- * perfrom direct edit request
- *
- */
- protected void performDirectEdit() {
- if (editManager == null) {
- Label l = ((PageflowNodeFigure) getFigure()).getLabel();
- editManager = new PageflowDirectEditManager(this,
- TextCellEditor.class, new DirectEditCellEditorLocator(l), l);
- }
- editManager.show();
- }
-
- /**
- * perform double click request
- *
- */
- protected void performOpen() {
- // only Page and Action support the double-click commands
- if (getModel() instanceof PageflowPage) {
- // CommandStack stack =
- // getViewer().getEditDomain().getCommandStack();
- Command command = new OpenEditorCommand(this);
- if (command != null && command.canExecute()) {
- // stack.execute(command);
- command.execute();
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setForegroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setForegroundColor(Color c) {
- getPageflowNodeFigure().setForegroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setBackgroundColor(org.eclipse.swt.graphics.Color)
- */
- public void setBackgroundColor(Color c) {
- getPageflowNodeFigure().setBackgroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IFigurePreference#setFont(org.eclipse.swt.graphics.Font)
- */
- public void setFont(Font f) {
- getPageflowNodeFigure().setFont(f);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.INodePreference#setTextPlacement(int)
- */
- public void setTextPlacement(int where) {
- getPageflowNodeFigure().setTextPlacement(where);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#decorateEditPart()
- */
- public void addAnnotation(final Annotation annotation) {
- getViewer().getControl().getDisplay().asyncExec(new Runnable() {
- /* (non-Javadoc)
- * @see java.lang.Runnable#run()
- */
- public void run() {
- getPageflowNodeFigure().setImage(
- getDecoratedImage((PageflowElement) getModel()));
- getPageflowNodeFigure().setToolTipText(annotation.getText());
- }
-
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.editparts.IEditPartDecorator#undecorateEditPart()
- */
- public void removeAnnotation() {
- getViewer().getControl().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getPageflowNodeFigure().setImage(
- getImage((PageflowElement) getModel()));
- getPageflowNodeFigure().setToolTipText(null);
- }
-
- });
- }
-
- /**
- * Returns the image for the pageflow element.
- *
- * @param element -
- * pageflow element
- * @return - the image for the pageflow element.
- */
- private Image getDecoratedImage(PageflowElement element) {
- Image decoratedImage = getImage(element);
-
- decoratedImage = getImageDecorator().decorateImage(getImage(element),
- null);
-
- return decoratedImage;
- }
-
- private ImageDecorator getImageDecorator() {
- if (imageDecorator == null) {
- imageDecorator = new ImageDecorator();
- }
- return imageDecorator;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreeEditPart.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreeEditPart.java
deleted file mode 100644
index 34976d37e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreeEditPart.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-
-/**
- * The <code>TreeEditPart</code> implementation for a pageflow.
- *
- *
- */
-/*package*/ class PageflowTreeEditPart extends PageflowElementTreeEditPart {
-
- /**
- * Creates a new PageflowTreeEditPart instance.
- *
- * @param pageflow
- */
- public PageflowTreeEditPart(Pageflow pageflow) {
- super(pageflow);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see AbstractEditPart#getModelChildren()
- */
- protected List getModelChildren() {
- List children_ = getPageflow().getNodes();
-
- return new ArrayList(children_);
- }
-
- /**
- * Returns the model as <code>Pageflow</code>.
- *
- * @return the model as <code>Pageflow</code>
- */
- public Pageflow getPageflow() {
- return (Pageflow) getModel();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreePartFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreePartFactory.java
deleted file mode 100644
index 940113a5d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpart/PageflowTreePartFactory.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPartFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-
-/**
- * Edit Part Factory for creation pageflow tree parts
- *
- */
-public class PageflowTreePartFactory implements EditPartFactory {
- /*
- * (non-Javadoc)
- *
- * @see EditPartFactory#createEditPart()
- */
- public EditPart createEditPart(EditPart context, Object model) {
-
- if (model instanceof Pageflow) {
- return new PageflowTreeEditPart((Pageflow) model);
-
- } else if (model instanceof PageflowElement) {
- return new PageflowElementTreeEditPart((PageflowElement) model);
- }
-
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkBendpointEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkBendpointEditPolicy.java
deleted file mode 100644
index 4dabafbb6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkBendpointEditPolicy.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.draw2d.Connection;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.BendpointEditPolicy;
-import org.eclipse.gef.requests.BendpointRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.CreateBendpointCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.DeleteBendpointCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.MoveBendpointCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-
-/**
- * Customize the bendpoint edit policy fro pageflow link connections
- *
- */
-public class PFLinkBendpointEditPolicy extends BendpointEditPolicy {
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editpolicies.BendpointEditPolicy#getCreateBendpointCommand(org.eclipse.gef.requests.BendpointRequest)
- */
- protected Command getCreateBendpointCommand(BendpointRequest request) {
- CreateBendpointCommand createCmd = new CreateBendpointCommand();
- Point p = request.getLocation();
- Connection conn = getConnection();
-
- conn.translateToRelative(p);
-
- createCmd.setLocation(p);
- Point ref1 = getConnection().getSourceAnchor().getReferencePoint();
- Point ref2 = getConnection().getTargetAnchor().getReferencePoint();
-
- conn.translateToRelative(ref1);
- conn.translateToRelative(ref2);
-
- createCmd.setRelativeDimensions(p.getDifference(ref1), p
- .getDifference(ref2));
- createCmd.setPFLink((PageflowLink) request.getSource().getModel());
- createCmd.setIndex(request.getIndex());
- return createCmd;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editpolicies.BendpointEditPolicy#getDeleteBendpointCommand(org.eclipse.gef.requests.BendpointRequest)
- */
- protected Command getDeleteBendpointCommand(BendpointRequest request) {
- DeleteBendpointCommand deleteCom = new DeleteBendpointCommand();
- Point p = request.getLocation();
- deleteCom.setLocation(p);
- deleteCom.setPFLink((PageflowLink) request.getSource().getModel());
- deleteCom.setIndex(request.getIndex());
- return deleteCom;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.editpolicies.BendpointEditPolicy#getMoveBendpointCommand(org.eclipse.gef.requests.BendpointRequest)
- */
- protected Command getMoveBendpointCommand(BendpointRequest request) {
- MoveBendpointCommand moveCmd = new MoveBendpointCommand();
- Point p = request.getLocation();
- Connection conn = getConnection();
-
- conn.translateToRelative(p);
-
- moveCmd.setLocation(p);
-
- Point ref1 = getConnection().getSourceAnchor().getReferencePoint();
- Point ref2 = getConnection().getTargetAnchor().getReferencePoint();
-
- conn.translateToRelative(ref1);
- conn.translateToRelative(ref2);
-
- moveCmd.setRelativeDimensions(p.getDifference(ref1), p
- .getDifference(ref2));
- moveCmd.setPFLink((PageflowLink) request.getSource().getModel());
- moveCmd.setIndex(request.getIndex());
- return moveCmd;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEditPolicy.java
deleted file mode 100644
index d25b22700..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEditPolicy.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.ConnectionEditPolicy;
-import org.eclipse.gef.requests.GroupRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.ConnectionCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.DeleteConnectionCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-
-/**
- * Customize the connection edit policy for pageflow links
- *
- */
-public class PFLinkEditPolicy extends ConnectionEditPolicy {
-
- /**
- * Default constructor
- */
- public PFLinkEditPolicy() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ConnectionEditPolicy#getDeleteCommand
- */
- protected Command getDeleteCommand(GroupRequest request) {
- ConnectionCommand c = new DeleteConnectionCommand();
- c.setPFLink((PageflowLink) getHost().getModel());
- return c;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEndpointEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEndpointEditPolicy.java
deleted file mode 100644
index 59875dbc5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PFLinkEndpointEditPolicy.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.draw2d.PolylineConnection;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.editpolicies.ConnectionEndpointEditPolicy;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-
-/**
- * Customize the endpoint edit policy for pageflow links
- *
- */
-public class PFLinkEndpointEditPolicy extends ConnectionEndpointEditPolicy {
- /**
- *
- */
- public PFLinkEndpointEditPolicy() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ConnectionEndpointEditPolicy#addSelectionHandles
- */
- protected void addSelectionHandles() {
- super.addSelectionHandles();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- int connectionWidth = store.getInt(GEMPreferences.LINE_WIDTH);
- getConnectionFigure().setLineWidth(connectionWidth + 1);
- }
-
- private PolylineConnection getConnectionFigure() {
- return (PolylineConnection) ((GraphicalEditPart) getHost()).getFigure();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ConnectionEndpointEditPolicy#removeSelectionHandles
- */
- protected void removeSelectionHandles() {
- super.removeSelectionHandles();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- int connectionWidth = store.getInt(GEMPreferences.LINE_WIDTH);
- getConnectionFigure().setLineWidth(connectionWidth);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowContainerEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowContainerEditPolicy.java
deleted file mode 100644
index f392f25a6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowContainerEditPolicy.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import java.util.List;
-
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.commands.CompoundCommand;
-import org.eclipse.gef.editpolicies.ContainerEditPolicy;
-import org.eclipse.gef.requests.CreateRequest;
-import org.eclipse.gef.requests.GroupRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.OrphanChildCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * Customize the container policy for page flow containers
- *
- */
-public class PageflowContainerEditPolicy extends ContainerEditPolicy {
- /*
- * (non-Javadoc)
- *
- * @see ContainerEditPolicy#getCreateCommand()
- */
- protected Command getCreateCommand(CreateRequest request) {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ContainerEditPolicy#getOrphanChildrenCommand()
- */
- public Command getOrphanChildrenCommand(GroupRequest request) {
- List parts = request.getEditParts();
- CompoundCommand result = new CompoundCommand("orphanchildcommand"); //$NON-NLS-1$
- for (int i = 0; i < parts.size(); i++) {
- OrphanChildCommand orphan = new OrphanChildCommand();
- orphan
- .setChild((PageflowNode) ((EditPart) parts.get(i))
- .getModel());
- orphan.setParent((Pageflow) getHost().getModel());
- orphan.setLabel(PageflowMessages.PageflowContainerEditPolicy_OrphanLabel);
- result.add(orphan);
- }
- return result.unwrap();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowElementEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowElementEditPolicy.java
deleted file mode 100644
index 04e86db81..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowElementEditPolicy.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.requests.GroupRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.DeleteNodeCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * Customize component edit policies for page flows
- *
- */
-public class PageflowElementEditPolicy extends
- org.eclipse.gef.editpolicies.ComponentEditPolicy {
- /*
- * (non-Javadoc)
- *
- * @see ComponentEditPolicy#createDeleteCommand()
- */
- protected Command createDeleteCommand(GroupRequest request) {
- Object parent = getHost().getParent().getModel();
- DeleteNodeCommand deleteCmd = new DeleteNodeCommand((Pageflow) parent);
- deleteCmd.setParent((Pageflow) parent);
- deleteCmd.setChild((PageflowNode) getHost().getModel());
- return deleteCmd;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeDirectEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeDirectEditPolicy.java
deleted file mode 100644
index c89d648c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeDirectEditPolicy.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.DirectEditPolicy;
-import org.eclipse.gef.requests.DirectEditRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.RenameNodeCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * EditPolicy for the direct editing of pageflow node's name.
- *
- * @author Xiaoguang Zhang
- */
-public class PageflowNodeDirectEditPolicy extends DirectEditPolicy {
-
- /*
- * (non-javadoc)
- *
- * @see DirectEditPolicy#getDirectEditCommand(DirectEditRequest)
- */
- protected Command getDirectEditCommand(DirectEditRequest request) {
- RenameNodeCommand cmd = new RenameNodeCommand();
- cmd.setSource((PageflowNode) getHost().getModel());
- cmd.setOldName(((PageflowNode) getHost().getModel()).getName());
- cmd.setName((String) request.getCellEditor().getValue());
- return cmd;
- }
-
- /*
- * (non-javadoc)
- *
- * @see DirectEditPolicy#showCurrentEditValue(DirectEditRequest)
- */
- protected void showCurrentEditValue(DirectEditRequest request) {
- // String value = (String)request.getCellEditor().getValue();
- // ((PageflowNodeFigure)getHostFigure()).setText(value);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeEditPolicy.java
deleted file mode 100644
index 192d818ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeEditPolicy.java
+++ /dev/null
@@ -1,162 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.Connection;
-import org.eclipse.draw2d.PolylineConnection;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.GraphicalNodeEditPolicy;
-import org.eclipse.gef.requests.CreateConnectionRequest;
-import org.eclipse.gef.requests.ReconnectRequest;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.action.OpenEditorAction;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.ConnectionCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.ConnectionCommandFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.OpenEditorCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure.PageflowNodeFigure;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-
-/**
- * Customizes conntection policies
- *
- */
-public class PageflowNodeEditPolicy extends GraphicalNodeEditPolicy {
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#createDummyConnection()
- */
- protected Connection createDummyConnection(Request req) {
- PolylineConnection conn = new PolylineConnection();
- conn.setLineWidth(getLineWidth());
- conn.setForegroundColor(ColorConstants.black);
-
- return conn;
- }
-
- /**
- * get the connection line width from preference.
- */
- private int getLineWidth() {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- int lineWidth = store.getInt(GEMPreferences.LINE_WIDTH);
- return lineWidth;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#getConnectionCompleteCommand()
- */
- protected Command getConnectionCompleteCommand(
- CreateConnectionRequest request) {
- ConnectionCommand command = (ConnectionCommand) request
- .getStartCommand();
- // ConnectionAnchor anchor =
- // getPageflowNodeEditPart().getTargetConnectionAnchor(request);
-
- command.setTarget(getPageflowNode());
-
- return command;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#getConnectionCreateCommand()
- */
- protected Command getConnectionCreateCommand(CreateConnectionRequest request) {
- ConnectionCommand command = ConnectionCommandFactory
- .createCommand(request);
- command.setPFLink((PageflowLink) request.getNewObject());
- PageflowNode flowObject = getPageflowNode();
- command.setSource(flowObject);
- request.setStartCommand(command);
- return command;
- }
-
- /**
- * get the edit part of pageflow node
- *
- * @return - the edit part of pageflow node
- */
- protected PageflowNodeEditPart getPageflowNodeEditPart() {
- return (PageflowNodeEditPart) getHost();
- }
-
- /**
- * get the pageflow node
- *
- * @return - the pageflow node
- */
- protected PageflowNode getPageflowNode() {
- return (PageflowNode) getHost().getModel();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#getReconnectTargetCommand()
- */
- protected Command getReconnectTargetCommand(ReconnectRequest request) {
- ConnectionCommand cmd = ConnectionCommandFactory.createCommand(request);
- cmd
- .setPFLink((PageflowLink) request.getConnectionEditPart()
- .getModel());
- cmd.setTarget(getPageflowNode());
- return cmd;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#getReconnectSourceCommand()
- */
- protected Command getReconnectSourceCommand(ReconnectRequest request) {
- ConnectionCommand cmd = ConnectionCommandFactory.createCommand(request);
- cmd
- .setPFLink((PageflowLink) request.getConnectionEditPart()
- .getModel());
- cmd.setSource(getPageflowNode());
- return cmd;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see GraphicalNodeEditPolicy#getCommand()
- */
- public Command getCommand(Request request) {
- if (OpenEditorAction.OPEN_EDITOR_REQUEST.equals(request.getType())) {
- return new OpenEditorCommand(getHost());
- }
-
- return super.getCommand(request);
- }
-
- /**
- * return the pageflow node figure
- *
- * @return - the pageflow node's figure
- */
- protected PageflowNodeFigure getPageflowNodeFigure() {
- return (PageflowNodeFigure) ((GraphicalEditPart) getHost()).getFigure();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeSelectionEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeSelectionEditPolicy.java
deleted file mode 100644
index fb0465df2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowNodeSelectionEditPolicy.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.gef.editpolicies.NonResizableEditPolicy;
-
-/**
- * Handles selection of Node. Primary selection is denoted by highlight and a
- * focus rectangle. Normal selection is denoted by highlight only.
- *
- * @author xgzhang
- */
-public class PageflowNodeSelectionEditPolicy extends NonResizableEditPolicy {
-
-// private PageflowNodeFigure getFigure() {
-// PageflowNodeEditPart part = (PageflowNodeEditPart) getHost();
-// return ((PageflowNodeFigure) part.getFigure());
-// }
-
- /**
- * @see org.eclipse.gef.editpolicies.SelectionHandlesEditPolicy#hideSelection()
- */
- protected void hideSelection() {
- super.hideSelection();
- // getFigure().setSelected(false);
- }
-
- /**
- * @see org.eclipse.gef.editpolicies.SelectionHandlesEditPolicy#showSelection()
- */
- protected void showPrimarySelection() {
- super.showPrimarySelection();
- // getFigure().setSelected(true);
- }
-
- /**
- * @see org.eclipse.gef.editpolicies.SelectionHandlesEditPolicy#showSelection()
- */
- protected void showSelection() {
- super.showSelection();
- // getFigure().setSelected(true);
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowXYLayoutEditPolicy.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowXYLayoutEditPolicy.java
deleted file mode 100644
index dccbfa61b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/editpolicy/PageflowXYLayoutEditPolicy.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpolicy;
-
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.EditPolicy;
-import org.eclipse.gef.Request;
-import org.eclipse.gef.commands.Command;
-import org.eclipse.gef.editpolicies.ResizableEditPolicy;
-import org.eclipse.gef.editpolicies.XYLayoutEditPolicy;
-import org.eclipse.gef.requests.CreateRequest;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.AddNodeCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.CreateNodeCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.command.SetConstraintCommand;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-
-/**
- * Customize the layout policy for page flows
- *
- */
-public class PageflowXYLayoutEditPolicy extends XYLayoutEditPolicy {
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#createAddCommand()
- */
- protected Command createAddCommand(EditPart childEditPart, Object constraint) {
- PageflowNode part = (PageflowNode) childEditPart.getModel();
- Rectangle rect = (Rectangle) constraint;
-
- AddNodeCommand add = new AddNodeCommand();
- add.setParent((Pageflow) getHost().getModel());
- add.setChild(part);
- add.setLabel(PageflowMessages.PageflowXYLayoutEditPolicy_Add);
- add.setDebugLabel("PageFlowXYEP add subpart"); //$NON-NLS-1$
-
- SetConstraintCommand setConstraint = new SetConstraintCommand();
-
- setConstraint.setLocation(rect);
- setConstraint.setPart(part);
- setConstraint.setLabel(PageflowMessages.PageflowXYLayoutEditPolicy_Add);
- setConstraint.setDebugLabel("PageFlowXYEP setConstraint"); //$NON-NLS-1$
- return add.chain(setConstraint);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#createChangeConstraintCommand()
- */
- protected Command createChangeConstraintCommand(EditPart child,
- Object constraint) {
- SetConstraintCommand locationCommand = new SetConstraintCommand();
- locationCommand.setPart((PageflowNode) child.getModel());
- locationCommand.setLocation((Rectangle) constraint);
- return locationCommand;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#createChildEditPolicy()
- */
- protected EditPolicy createChildEditPolicy(EditPart child) {
- if (child instanceof PageflowNodeEditPart) {
- return new PageflowNodeSelectionEditPolicy();
- }
-
- return new ResizableEditPolicy();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#getCreateCommand()
- */
- protected Command getCreateCommand(CreateRequest request) {
- CreateNodeCommand create = new CreateNodeCommand();
- create.setParent((Pageflow) getHost().getModel());
- create.setChild((PageflowNode) request.getNewObject());
- Rectangle constraint = (Rectangle) getConstraintFor(request);
- create.setLocation(constraint);
- create.setLabel(PageflowMessages.PageflowXYLayoutEditPolicy_Add);
- return create;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#getDeleteDependantCommand()
- */
- protected Command getDeleteDependantCommand(Request request) {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see XYLayoutEditPolicy#getOrphanChildrenCommand()
- */
- protected Command getOrphanChildrenCommand(Request request) {
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ConnectionLabel.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ConnectionLabel.java
deleted file mode 100644
index 702e58e09..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ConnectionLabel.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;
-
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.LineBorder;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * This label is used in connection figure, which has a border.
- *
- * @author Xiao-guang Zhang
- *
- */
-public class ConnectionLabel extends Label {
- /**
- *
- */
- public ConnectionLabel() {
- this(null, null);
- }
-
- /**
- * @param s
- */
- public ConnectionLabel(String s) {
- this(s, null);
- }
-
- /**
- * @param i
- */
- public ConnectionLabel(Image i) {
- this(null, i);
- }
-
- /**
- * @param s
- * @param i
- */
- public ConnectionLabel(String s, Image i) {
- super(s, i);
-
- // setBorder(new LineBorder());
- setOpaque(true);
- }
-
- /**
- * set the label's border's width
- *
- * @param w
- */
- public void setBorderWidth(int w) {
- if (getBorder() != null) {
- ((LineBorder) getBorder()).setWidth(w);
- }
- }
-
- /**
- * set the label's border's color
- *
- * @param c
- */
- public void setBorderColor(Color c) {
- if (getBorder() != null) {
- ((LineBorder) getBorder()).setColor(c);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ILabelDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ILabelDecorator.java
deleted file mode 100644
index d1d01373a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/ILabelDecorator.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;
-
-import org.eclipse.swt.graphics.Image;
-
-/**
- * A label decorator decorates the label text and image for some element. The
- * original label text and image are obtained by some other means,
- *
- *
- * @author Xiao-guang Zhang
- */
-public interface ILabelDecorator {
- /**
- * Returns an image that is based on the given image, but decorated with
- * additional information relating to the state of the provided element.
- *
- * @param image
- * the input image to decorate, or <code>null</code> if the
- * element has no image
- * @param element
- * the element whose image is being decorated
- * @return the decorated image, or <code>null</code> if no decoration is
- * to be applied
- *
- * @see org.eclipse.jface.resource.CompositeImageDescriptor
- */
- public Image decorateImage(Image image, Object element);
-
- /**
- * Returns a text label that is based on the given text label, but decorated
- * with additional information relating to the state of the provided
- * element.
- *
- *
- * @param text
- * the input text label to decorate
- * @param element
- * the element whose image is being decorated
- * @return the decorated text label, or <code>null</code> if no decoration
- * is to be applied
- */
- public String decorateText(String text, Object element);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/NodeLabel.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/NodeLabel.java
deleted file mode 100644
index fa5764d82..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/NodeLabel.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;
-
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * This derived label has simple tooltip support
- *
- * @author Xiao-guang Zhang
- *
- */
-public class NodeLabel extends Label {
- /**
- *
- */
- public NodeLabel() {
- super();
- }
-
- /**
- * @param s
- */
- public NodeLabel(String s) {
- super(s);
- }
-
- /**
- * @param i
- */
- public NodeLabel(Image i) {
- super(i);
- }
-
- /**
- * @param s
- * @param i
- */
- public NodeLabel(String s, Image i) {
- super(s, i);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Label#setTextPlacement(int)
- */
- public void setTextPlacement(int where) {
- super.setTextPlacement(where);
- layout();
- invalidate();
- }
-
- /**
- * set tooltip text
- *
- * @param text
- */
- public void setToolTipText(String text) {
- Label toolTipLabel = null;
-
- if (text != null && text.length() > 0) {
- toolTipLabel = new Label(text);
- toolTipLabel.setBorder(new MarginBorder(3));
- }
-
- super.setToolTip(toolTipLabel);
- }
-
- /**
- * get tooltip's text
- *
- * @return the tool tip text string
- */
- public String getToolTipText() {
- if (getToolTip() != null)
- return ((Label) getToolTip()).getText();
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PFLinkFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PFLinkFigure.java
deleted file mode 100644
index f9ecd41e0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PFLinkFigure.java
+++ /dev/null
@@ -1,318 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;
-
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.draw2d.MidpointLocator;
-import org.eclipse.draw2d.PolygonDecoration;
-import org.eclipse.draw2d.PolylineConnection;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.resource.FontRegistry;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.Image;
-
-/**
- *
- * The figure for pflink, used by pflink edit part, which is a polyline with a
- * label control on it, and with tooltip support.
- *
- * @author Xiao-guang Zhang
- */
-public class PFLinkFigure extends PolylineConnection {
- /** the label attached to the connection */
- private ConnectionLabel textLabel = null;
-
- //private ConnectionLabel iconLabel = null;
-
- /** The label's background color */
- private Color labelBgColor;
-
- /** The label's foreground color */
- private Color labelFgColor;
-
- /** The label's visiblity */
- private boolean bLabelVisible = false;
-
- /** The connection's line width */
- private int lineWidth = 0;
-
- /** the polygon decoration for connection line */
- private PolygonDecoration arrow;
-
- /**
- *
- */
- public PFLinkFigure() {
- arrow = new PolygonDecoration();
- arrow.setTemplate(PolygonDecoration.TRIANGLE_TIP);
- arrow.setScale(10, getLineWidth() * 2);
- setTargetDecoration(arrow);
- setForegroundColor(getForegroundColor());
- }
-
- /**
- * set the connection's label string
- *
- * @param strLabel
- */
- public void setLabel(String strLabel) {
- if (null != strLabel) {
- if (textLabel == null) {
- textLabel = new ConnectionLabel();
- textLabel.setFont(getLabelFont());
- textLabel.setBackgroundColor(getLabelBackgroundColor());
- textLabel.setForegroundColor(getLabelForegroundColor());
- setLineWidth(getLineWidth());
- setLabelVisible(getLabelVisible());
- setForegroundColor(getForegroundColor());
- add(textLabel, new MidpointLocator(this, 1));
- }
- // textLabel.setVisible(true);
- textLabel.setText(strLabel);
- }
- }
-
- /**
- * Set the icon image to null
- */
- public void clearIcon() {
- setImage(null);
- }
-
- /**
- * Set the label to empty string
- */
- public void clearOutcome() {
- setLabel(""); //$NON-NLS-1$
- }
-
- /**
- * set the connection's label string
- *
- * @param image
- */
- public void setImage(Image image) {
- if (textLabel == null) {
- textLabel = new ConnectionLabel();
- textLabel.setFont(getLabelFont());
- textLabel.setBackgroundColor(getLabelBackgroundColor());
- textLabel.setForegroundColor(getLabelForegroundColor());
- setLineWidth(getLineWidth());
- setLabelVisible(getLabelVisible());
- setForegroundColor(getForegroundColor());
- add(textLabel, new MidpointLocator(this, 0));
- }
- textLabel.setIcon(image);
- }
-
- /**
- * Set the action image
- */
- public void setActionImage() {
- ImageDescriptor imageDescriptor = PageflowElementEditPart.IMG_ACTION;
- Image image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- if (null == image) {
- EditorPlugin.getDefault().getImageRegistry().put(
- imageDescriptor.toString(), imageDescriptor);
- image = EditorPlugin.getDefault().getImageRegistry().get(
- imageDescriptor.toString());
- }
- setImage(image);
- }
-
- /**
- * @return the icon image
- */
- public Image getImage() {
- if (textLabel != null)
- {
- return textLabel.getIcon();
- }
- return null;
- }
-
-
- /**
- * @param text
- */
- public void setToolTipText(String text) {
- Label toolTipLabel = null;
-
- if (text != null && text.length() > 0) {
- toolTipLabel = new Label(text);
- toolTipLabel.setBorder(new MarginBorder(3));
- }
-
- super.setToolTip(toolTipLabel);
- }
-
- /**
- * @return the tool tip text or null if none
- */
- public String getToolTipText() {
- if (getToolTip() != null)
- {
- return ((Label) getToolTip()).getText();
- }
- return null;
- }
-
- /**
- * set the font including label's
- *
- */
- public void setFont(Font f) {
- if (textLabel != null)
- textLabel.setFont(f);
- super.setFont(f);
- }
-
- /**
- * get the label's font from preference
- *
- */
- private Font getLabelFont() {
- FontRegistry registry = JFaceResources.getFontRegistry();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- FontData fontData = PreferenceConverter.getFontData(store,
- GEMPreferences.LINE_LABEL_FONT);
- if (!registry.get(fontData.toString()).equals(registry.defaultFont()))
- return registry.get(fontData.toString());
-
- registry.put(fontData.toString(), new FontData[] {fontData});
- return registry.get(fontData.toString());
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Shape#setLineWidth(int)
- */
- public void setLineWidth(int w) {
- if (textLabel != null)
- textLabel.setBorderWidth(w);
- arrow.setScale(10, getLineWidth() * 2);
- super.setLineWidth(w);
- }
-
- /**
- * get the connection line width from preference.
- */
- public int getLineWidth() {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- lineWidth = store.getInt(GEMPreferences.LINE_WIDTH);
- return lineWidth;
- }
-
- /**
- * set label's visibility
- *
- * @param flag -
- * visible or not.
- */
- public void setLabelVisible(boolean flag) {
- if (textLabel != null)
- textLabel.setVisible(flag);
- }
-
- /**
- * get the label's visiblity from preference
- *
- */
- private boolean getLabelVisible() {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- bLabelVisible = store.getBoolean(GEMPreferences.SHOW_LINE_LABELS);
- return bLabelVisible;
- }
-
- /**
- * set the label's foreground color
- *
- * @param c
- */
- public void setLabelForegroundColor(Color c) {
- labelFgColor = c;
- if (textLabel != null)
- textLabel.setForegroundColor(c);
- }
-
- /**
- * get the label's foreground color from preference
- *
- */
- private Color getLabelForegroundColor() {
- if (labelFgColor == null) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
- labelFgColor = GEMPreferences.getColor(store,
- GEMPreferences.LINE_LABEL_FONT_COLOR);
- }
- return labelFgColor;
- }
-
- /**
- * set the label's background color
- *
- * @param c
- */
- public void setLabelBackgroundColor(Color c) {
- labelBgColor = c;
- if (textLabel != null)
- textLabel.setBackgroundColor(c);
- }
-
- /**
- * get the label's background color from preference
- *
- */
- private Color getLabelBackgroundColor() {
- if (labelBgColor == null) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
- labelBgColor = GEMPreferences.getColor(store,
- GEMPreferences.LINE_LABEL_COLOR);
- }
- return labelBgColor;
- }
-
- /**
- * get the foreground color from preference
- *
- */
- public Color getForegroundColor() {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- final Color newFgColor = GEMPreferences.getColor(store, GEMPreferences.LINE_COLOR);
- setForegroundColor(newFgColor);
- return newFgColor;
- }
-
- /**
- * set the figure's foreground, which will also update the label's border's
- * color.
- */
- public void setForegroundColor(Color c) {
- if (textLabel != null)
- textLabel.setBorderColor(c);
- super.setForegroundColor(c);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PageflowNodeFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PageflowNodeFigure.java
deleted file mode 100644
index 9a0827329..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/figure/PageflowNodeFigure.java
+++ /dev/null
@@ -1,376 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.figure;
-
-import java.util.Vector;
-
-import org.eclipse.draw2d.ChopboxAnchor;
-import org.eclipse.draw2d.ConnectionAnchor;
-import org.eclipse.draw2d.Figure;
-import org.eclipse.draw2d.FlowLayout;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.LabelAnchor;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.resource.FontRegistry;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.preference.GEMPreferences;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontData;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * The figure for pageflow node, used by pageflow node edit part.
- *
- */
-public class PageflowNodeFigure extends Figure {
- /** Same connection anchors for source and target */
- protected Vector connectionAnchors = new Vector(1);
-
- /** label of the pageflow node figure */
- private NodeLabel label;
-
- /** the foreground color of Label */
- private Color labelFgColor;
-
- /** the background color of Label */
-// private Color labelBgColor; // TODO: variable is never read because getter is private
-
- /** the text placement for the label */
- private int textPlacement = PositionConstants.SOUTH;
-
- /**
- * Default constructor
- */
- public PageflowNodeFigure() {
- setLayoutManager(new FlowLayout());
-
- // initializeConnectionAnchors();
- }
-
- /**
- * get the source(output) anchor according to the input point.
- *
- * @param p -
- * the input point
- * @return - Source ConnectionAnchor
- */
- public ConnectionAnchor getSourceConnectionAnchorAt(Point p) {
- if (getSourceConnectionAnchors().size() == 0)
- return null;
- return (ConnectionAnchor) getSourceConnectionAnchors().get(0);
- }
-
- /**
- * get the default source anchor
- *
- * @return - Source ConnectionAnchor
- */
- public ConnectionAnchor getSourceConnectionAnchor() {
- if (getSourceConnectionAnchors().size() == 0)
- return null;
- return (ConnectionAnchor) getSourceConnectionAnchors().get(0);
- }
-
- /**
- * Get the source connection anchors vector
- *
- * @return - the vector
- */
- private Vector getSourceConnectionAnchors() {
- return connectionAnchors;
- }
-
- /**
- * get the target (input) connection Anchor according the input point
- *
- * @param p -
- * the input Point
- * @return - ConnectionAnchor
- */
- public ConnectionAnchor getTargetConnectionAnchorAt(Point p) {
- if (getTargetConnectionAnchors().size() == 0)
- return null;
- return (ConnectionAnchor) getTargetConnectionAnchors().get(0);
- }
-
- /**
- * get the default target (input) connection Anchor
- *
- * @return - ConnectionAnchor
- */
- public ConnectionAnchor getTargetConnectionAnchor() {
- if (getTargetConnectionAnchors().size() == 0)
- return null;
- return (ConnectionAnchor) getTargetConnectionAnchors().get(0);
- }
-
- /**
- * Get the target connection anchors vector
- *
- * @return - the vector
- */
- private Vector getTargetConnectionAnchors() {
- return connectionAnchors;
- }
-
- /**
- * update the anchors
- *
- */
- public void update() {
- initializeConnectionAnchors();
- }
-
- /**
- * Initialize the connection anchors
- *
- */
- private void initializeConnectionAnchors() {
- connectionAnchors.removeAllElements();
- ChopboxAnchor inputConnectionAnchor = new LabelAnchor(label);
- connectionAnchors.addElement(inputConnectionAnchor);
- }
-
- /**
- * get the text placement from preference.
- *
- */
- private int getTextPlacement() {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- String s = store.getString(GEMPreferences.LABEL_PLACEMENT);
- if (GEMPreferences.LABEL_PLACEMENT_TOP.equals(s))
- textPlacement = PositionConstants.NORTH;
- else if (GEMPreferences.LABEL_PLACEMENT_BOTTOM.equals(s))
- textPlacement = PositionConstants.SOUTH;
- else if (GEMPreferences.LABEL_PLACEMENT_LEFT.equals(s))
- textPlacement = PositionConstants.WEST;
- else if (GEMPreferences.LABEL_PLACEMENT_RIGHT.equals(s))
- textPlacement = PositionConstants.EAST;
- return textPlacement;
- }
-
- /**
- * get the label's background color from preference.
- *
- * @return
- */
- // TODO: dead code
-// private Color getLabelBackgroundColor() {
-// return labelBgColor;
-// }
-
- /**
- * get the label's foreground color from preference.
- *
- * @return
- */
- private Color getLabelForegroundColor() {
- if (labelFgColor == null) {
- IPreferenceStore store = EditorPlugin.getDefault()
- .getPreferenceStore();
- labelFgColor = GEMPreferences.getColor(store,
- GEMPreferences.FIGURE_LABEL_FONT_COLOR);
- }
- return labelFgColor;
- }
-
- /**
- * get the labe's font from preference.
- *
- * @return
- */
- private Font getLabelFont() {
- FontRegistry registry = JFaceResources.getFontRegistry();
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- FontData fontData = PreferenceConverter.getFontData(store,
- GEMPreferences.FIGURE_LABEL_FONT);
- if (!registry.get(fontData.toString()).equals(registry.defaultFont()))
- return registry.get(fontData.toString());
-
- registry.put(fontData.toString(), new FontData[] {fontData});
- return registry.get(fontData.toString());
- }
-
- /**
- * set the image and text of the figure
- *
- * @param image -
- * the image
- * @param str -
- * the label
- */
- public void setImageText(Image image, String str) {
- if (image == null)
- setText(str);
- else if (str == null)
- setImage(image);
- else {
- if (label == null) {
- label = new NodeLabel(str, image);
- label.setTextPlacement(getTextPlacement());
- label.setForegroundColor(getLabelForegroundColor());
- label.setFont(getLabelFont());
- add(label);
- initializeConnectionAnchors();
- } else {
- label.setIcon(image);
- label.setText(str);
- }
- }
- }
-
- /**
- * set the image of the figure
- *
- * @param image -
- * the image
- */
- public void setImage(Image image) {
- if (image == null)
- return;
- if (label == null) {
- label = new NodeLabel(image);
- label.setTextPlacement(getTextPlacement());
- label.setForegroundColor(getLabelForegroundColor());
- label.setFont(getLabelFont());
- add(label);
- initializeConnectionAnchors();
- } else
- label.setIcon(image);
- }
-
- /**
- * set the text of the figure
- *
- * @param str -
- * the text
- */
- public void setText(String str) {
- if (str == null)
- return;
- if (label == null) {
- label = new NodeLabel(str);
- label.setTextPlacement(getTextPlacement());
- label.setForegroundColor(getLabelForegroundColor());
- label.setFont(getLabelFont());
- add(label);
- initializeConnectionAnchors();
- } else
- label.setText(str);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Figure#useLocalCoordinates()
- */
- protected boolean useLocalCoordinates() {
- return true;
- }
-
- /**
- * Returns the imageBounds.
- *
- * @return - Rectangle of image
- */
- public Rectangle getImageBounds() {
- return label.getIconBounds();
- }
-
- /**
- * Returns the textBounds.
- *
- * @return - Rectangle of text field
- */
- public Rectangle getTextBounds() {
- return label.getTextBounds();
- }
-
- /**
- * Returns the label.
- *
- * @return - Label
- */
- public Label getLabel() {
- return label;
- }
-
- /**
- * set the label's backaground
- */
- public void setBackgroundColor(Color bg) {
-// TODO: var is never read: labelBgColor = bg;
- if (label != null)
- label.setBackgroundColor(bg);
- }
-
- /**
- * set the label's foreground
- */
- public void setForegroundColor(Color fg) {
- labelFgColor = fg;
-
- if (label != null)
- label.setForegroundColor(fg);
- }
-
- /**
- * Set the label's font
- */
- public void setFont(Font f) {
- if (label != null)
- label.setFont(f);
- super.setFont(f);
- }
-
- /**
- * Set the text placement for the label
- *
- * @param where
- */
- public void setTextPlacement(int where) {
- textPlacement = where;
- if (label != null)
- label.setTextPlacement(where);
- }
-
-
- /**
- * @param text
- */
- public void setToolTipText(String text) {
- Label toolTipLabel = null;
-
- if (text != null && text.length() > 0) {
- toolTipLabel = new Label(text);
- toolTipLabel.setBorder(new MarginBorder(3));
- }
-
- super.setToolTip(toolTipLabel);
- }
- /**
- * @return the figure's tool tip text or null if none
- */
- public String getToolTipText() {
- if (getToolTip() != null)
- return ((Label) getToolTip()).getText();
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/layout/PageflowLayoutManager.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/layout/PageflowLayoutManager.java
deleted file mode 100644
index 74c3470a9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/layout/PageflowLayoutManager.java
+++ /dev/null
@@ -1,550 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.layout;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.draw2d.graph.DirectedGraph;
-import org.eclipse.draw2d.graph.DirectedGraphLayout;
-import org.eclipse.draw2d.graph.Edge;
-import org.eclipse.draw2d.graph.EdgeList;
-import org.eclipse.draw2d.graph.Node;
-import org.eclipse.draw2d.graph.NodeList;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowModelManager;
-
-/**
- * This class is a singleton adpater to create the directed graph for the
- * specified pageflow model or update the location information of pageflow model
- * according to directed graph layout algorithms.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowLayoutManager {
- /** node's default size */
- private static final int NODE_DEFAULT_WIDTH = 50;
-
- private static final int NODE_DEFAULT_HEIGHT = 50;
-
- /**
- * the margin of the top and left , and margin between each connnected
- * directed graph.
- */
- private static final int X_SPACE = 50;
-
- private static final int Y_SPACE = 50;
-
- /** node's default padding */
- private static final int DEFAULT_PADDING = 30;
-
- private static PageflowLayoutManager manager;
-
- private Map copiedLinks = null;
-
- /**
- * constructor of PageflowDirectedGraphAdapter
- *
- */
- private PageflowLayoutManager() {
- // no external instantiation
- }
-
- /**
- * return the singleton instance of PageflowDirectedGraphAdapter
- *
- * @return - the singleton instance of PageflowDirectedGraphAdapter
- */
- static public PageflowLayoutManager getInstance() {
- if (manager == null) {
- manager = new PageflowLayoutManager();
- }
- return manager;
- }
-
- /**
- * layout pageflow using directed graph layout algorithms
- *
- * @param pageflow -
- * pageflow model
- */
- public void layoutPageflow(Pageflow pageflow) {
- List selfLoopLinks = removeSelfLoopLinks(pageflow);
-
- List lstGraph = createGraphs(pageflow);
- for (Iterator iter = lstGraph.iterator(); iter.hasNext();) {
- DirectedGraph graph = (DirectedGraph) iter.next();
- new DirectedGraphLayout().visit(graph);// .visit(graph);
- }
- updatePageflow(lstGraph);
-
- if (selfLoopLinks != null) {
- addSelfLoopLinks(pageflow, selfLoopLinks);
- }
- }
-
- /**
- * remove the self loop links from pageflow, because the layout algorithm
- * does not allow it.
- *
- * @param pageflow
- * @return
- */
- private List removeSelfLoopLinks(Pageflow pageflow) {
- List selfLoopLinks = new ArrayList();
-
- if (pageflow.getLinks() != null) {
- for (Iterator iter = pageflow.getLinks().iterator(); iter.hasNext();) {
- PageflowLink link = (PageflowLink) iter.next();
-
- if (link.getSource() == link.getTarget()) {
- iter.remove();
- link.getBendPoints().clear();
- selfLoopLinks.add(link);
- }
- }
- }
- return selfLoopLinks;
- }
-
- /**
- * add back the self loop links with updated bendpoints.
- *
- * @param pageflow
- * @param selfLoopLinks
- */
- private void addSelfLoopLinks(Pageflow pageflow, List selfLoopLinks) {
- if (pageflow.getLinks() != null && selfLoopLinks != null
- && selfLoopLinks.size() > 0) {
- EList links = pageflow.getLinks();
- for (Iterator iter = selfLoopLinks.iterator(); iter.hasNext();) {
- PageflowLink link = (PageflowLink) iter.next();
- updateSelfLoopLink(link);
- links.add(link);
- }
- }
- }
-
- /**
- * Update the bendpoints of the self loop link Follow the following style:
- *
- * LeftTop-Top | | Left----Node
- *
- * @param selfLoopLink
- */
- public static void updateSelfLoopLink(PageflowLink selfLoopLink) {
- PageflowNode sourceNode = selfLoopLink.getSource();
- Rectangle rectNode = getPageflowNodeBounds(sourceNode);
-
- EList outLinks = sourceNode.getOutlinks();
- if (outLinks != null && outLinks.size() > 0) {
- for (Iterator iter = outLinks.iterator(); iter.hasNext();) {
- PageflowLink anotherSelfLoopLink = (PageflowLink) iter.next();
- if (anotherSelfLoopLink != selfLoopLink
- && anotherSelfLoopLink.getTarget() == sourceNode) {
- rectNode = getFitnessRectangle(rectNode,
- anotherSelfLoopLink);
- }
- }
- }
-
- PageflowFactory factory = PageflowModelManager.getFactory();
- PageflowLinkBendpoint bpTop = factory.createPFLinkBendpoint();
- PageflowLinkBendpoint bpLeftTop = factory.createPFLinkBendpoint();
- PageflowLinkBendpoint bpLeft = factory.createPFLinkBendpoint();
-
- bpTop.setD1Height(-rectNode.height);
- bpTop.setD2Height(-rectNode.height);
-
- bpLeftTop.setD1Width(-rectNode.width);
- bpLeftTop.setD1Height(-rectNode.height);
- bpLeftTop.setD2Width(-rectNode.width);
- bpLeftTop.setD2Height(-rectNode.height);
-
- bpLeft.setD1Width(-rectNode.width);
- bpLeft.setD2Width(-rectNode.width);
-
- selfLoopLink.getBendPoints().add(bpTop);
- selfLoopLink.getBendPoints().add(bpLeftTop);
- selfLoopLink.getBendPoints().add(bpLeft);
- }
-
- /**
- * Calculate the fitness rectangle without conflict with the existing self
- * loop's rectangle.
- *
- * @param rectDefault
- * @param anotherSelfLoopLink
- */
- private static Rectangle getFitnessRectangle(Rectangle rectDefault,
- PageflowLink anotherSelfLoopLink) {
- EList bendPoints = anotherSelfLoopLink.getBendPoints();
- if (bendPoints != null && bendPoints.size() > 0) {
- for (Iterator iterBendPoint = bendPoints.iterator(); iterBendPoint
- .hasNext();) {
- PageflowLinkBendpoint bendPoint = (PageflowLinkBendpoint) iterBendPoint
- .next();
- if (bendPoint.getD1Width() == -rectDefault.width
- && bendPoint.getD1Height() == -rectDefault.height) {
- rectDefault = new Rectangle(0, 0, rectDefault.width
- + DEFAULT_PADDING, rectDefault.height
- + DEFAULT_PADDING);
- break;
- }
- }
- }
- return rectDefault;
- }
-
- /**
- * get the pageflow node's bounds, the orginal point is (0,0)
- *
- * @param pfNode
- * @return
- */
- private static Rectangle getPageflowNodeBounds(PageflowNode pfNode) {
- return new Rectangle(0, 0, 64, 36);
- }
-
- /**
- * get the pageflow node's border rectangle
- *
- * @param pfNode
- * @return
- */
- private static Rectangle getPageflowNodeRectangle(PageflowNode pfNode) {
- Rectangle rectNode = null;
-
- Rectangle bounds = getPageflowNodeBounds(pfNode);
-
- rectNode = new Rectangle(pfNode.getX(), pfNode.getY(), bounds.width,
- bounds.height);
-
- return rectNode;
- }
-
- /**
- * create the connected subgraphs for the pageflow model, because there
- * maybe more than one connected graph in one pageflow definition.
- *
- * @param pageflow -
- * Pageflow model
- * @return - the connected subgraphs
- */
- private List createGraphs(Pageflow pageflow) {
- /** the connected subgraphs */
- List lstGraph = null;
-
- if (pageflow != null) {
- // Graph is not connected totally.
- DirectedGraph graph = null;
- HashMap nodesMap = new HashMap();
-
- NodeList nodes = new NodeList();
- EdgeList edges = new EdgeList();
-
- // get all nodes in the pageflow
- List pfNodes = pageflow.getNodes();
- if (pfNodes != null) {
- for (Iterator iter = pfNodes.iterator(); iter.hasNext();) {
- PageflowNode pfNode = (PageflowNode) iter.next();
- Node node = new Node(pfNode);
- Rectangle rectNode = null;
- rectNode = getPageflowNodeBounds(pfNode);
- if (rectNode != null) {
- node.width = rectNode.width * 2;
- node.height = rectNode.height * 2;
- node.setPadding(new Insets(node.height, node.width,
- node.height, node.width));
- } else {
- node.width = NODE_DEFAULT_WIDTH;
- node.height = NODE_DEFAULT_HEIGHT;
- node.setPadding(new Insets(DEFAULT_PADDING));
- }
- nodesMap.put(pfNode, node);
- nodes.add(node);
- }
- }
- // get all edges in the pageflow
- List pfLinks = pageflow.getLinks();
- for (Iterator iter = pfLinks.iterator(); iter.hasNext();) {
- PageflowLink link = (PageflowLink) iter.next();
- PageflowNode source = link.getSource();
- PageflowNode target = link.getTarget();
- Node sourceNode = (Node) nodesMap.get(source);
- Node targetNode = (Node) nodesMap.get(target);
-
- if (sourceNode != null && targetNode != null) {
- Edge edge = new Edge(sourceNode, targetNode);
- edges.add(edge);
- }
- }
-
- graph = new DirectedGraph();
-
- graph.nodes = nodes;
- graph.edges = edges;
-
- // get the connected subgraphs.
- lstGraph = new ArrayList();
- lstGraph.add(graph);// ..getConnectedSubGraphs();
- }
- return lstGraph;
- }
-
- /**
- * update the pageflow according to layout results which are stored in the
- * connected subgraphs
- *
- * @param lstGraph -
- * connected subgraphs
- *
- */
- private void updatePageflow(List lstGraph) {
- // y coordiantion of the subgraph's start point
- int topSubGraph = 0;
-
- for (Iterator iter = lstGraph.iterator(); iter.hasNext();) {
- // sub graph's bottom
- int bottomSubGraph = 0;
- DirectedGraph graph = (DirectedGraph) iter.next();
- for (int i = 0; i < graph.nodes.size(); i++) {
- Node node = graph.nodes.getNode(i);
- if (!(node.data instanceof PageflowNode)) {
- continue;
- }
- PageflowNode pfNode = (PageflowNode) node.data;
- pfNode.setX(X_SPACE + node.y);
-
- pfNode.setY(Y_SPACE + node.x + topSubGraph);
-
- if ((Y_SPACE + node.x + topSubGraph) > bottomSubGraph) {
- bottomSubGraph = Y_SPACE + node.x + topSubGraph;
- }
- }
- topSubGraph = bottomSubGraph + Y_SPACE;
- }
- }
-
- /**
- * update new pageflow's layout using the existing one.
- * @param newPageflow
- * @param oldPageflow
- */
- public void updatePageflowLayout(Pageflow newPageflow, Pageflow oldPageflow) {
- List notUpdatedNodes = new ArrayList();
-
- copiedLinks = new HashMap();
-
- if (oldPageflow.getNodes().size() > 0) {
- for (Iterator iter = newPageflow.getNodes().iterator(); iter
- .hasNext();) {
- PageflowNode newNode = (PageflowNode) iter.next();
-
- if (!updatePageflowNode(newNode, oldPageflow)) {
- notUpdatedNodes.add(newNode);
- }
- }
- } else {
- notUpdatedNodes.addAll(newPageflow.getNodes());
- }
-
- if (oldPageflow.getLinks().size() > 0) {
- for (Iterator iter = newPageflow.getLinks().iterator(); iter
- .hasNext();) {
- PageflowLink newLink = (PageflowLink) iter.next();
-
- updatePFLink(newLink, oldPageflow);
- }
- }
-
- // if there are still some nodes which are not updated,
- // they should be check whether there are some layout conflict.
- if (notUpdatedNodes.size() > 0) {
- resolveConflict(newPageflow, notUpdatedNodes);
- }
-
- }
-
- /**
- * Update pageflow node using the same node
- *
- * @param object
- * @return - the old pageflow node.
- */
- private boolean updatePageflowNode(PageflowNode newNode,
- Pageflow oldPageflow) {
- for (Iterator iter = oldPageflow.getNodes().iterator(); iter.hasNext();) {
- PageflowNode oldNode = (PageflowNode) iter.next();
-
- if (oldNode instanceof PageflowPage
- && newNode instanceof PageflowPage) {
- if (((PageflowPage) oldNode).getPath().trim().equals(
- ((PageflowPage) newNode).getPath().trim())) {
- updatePageflowNode(newNode, oldNode);
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * Update pageflow node using the same node
- *
- * @param object
- */
- private void updatePageflowNode(PageflowNode newNode, PageflowNode node) {
- newNode.setX(node.getX());
- newNode.setY(node.getY());
- }
-
- /**
- * If there are conflict for the nodes, it will resolve it.
- *
- * @param newPageflow
- * @param notUpdatedNodes
- */
- private void resolveConflict(Pageflow newPageflow, List notUpdatedNodes) {
- for (Iterator iter = notUpdatedNodes.iterator(); iter.hasNext();) {
- resolveConflict(newPageflow, (PageflowNode) iter.next());
- }
- }
-
- /**
- * Resolve the layout conflict
- *
- * @param newPageflow
- * @param node
- */
- private void resolveConflict(Pageflow newPageflow, PageflowNode node) {
- Rectangle nodeRect = getPageflowNodeRectangle(node);
- boolean bModified = false;
- for (int i = 0, size = newPageflow.getNodes().size(); i < size; i++) {
- PageflowNode fixedNode = (PageflowNode) newPageflow.getNodes().get(
- i);
- if (node == fixedNode) {
- continue;
- }
- Rectangle fixedNodeRect = getPageflowNodeRectangle(fixedNode);
- if (fixedNodeRect.intersects(nodeRect)) {
- nodeRect.x += fixedNodeRect.width + X_SPACE;
- nodeRect.y += fixedNodeRect.height + Y_SPACE;
- bModified = true;
- }
- }
- if (bModified) {
- node.setX(nodeRect.x);
- node.setY(nodeRect.y);
- }
- }
-
- /**
- * Update the link using the same link in the old pageflow
- *
- * @param newLink
- * @param oldPageflow
- */
- private void updatePFLink(PageflowLink newLink, Pageflow oldPageflow) {
- for (Iterator iter = oldPageflow.getLinks().iterator(); iter.hasNext();) {
- PageflowLink oldLink = (PageflowLink) iter.next();
-
- if (copiedLinks.get(oldLink) != null) {
- continue;
- }
-
- if (isSameLink(newLink, oldLink)) {
- updatePFLink(newLink, oldLink);
- break;
- }
- }
- }
-
- /**
- * Check whether this two links in differnet pageflow are same or not.
- *
- * @param newLink
- * @param oldLink
- * @return
- */
- private boolean isSameLink(PageflowLink newLink, PageflowLink oldLink) {
- PageflowNode newSource = newLink.getSource();
- PageflowNode newTarget = newLink.getTarget();
-
- PageflowNode oldSource = oldLink.getSource();
- PageflowNode oldTarget = oldLink.getTarget();
-
- // Page-Page
- if (newSource instanceof PageflowPage
- && oldSource instanceof PageflowPage
- && newTarget instanceof PageflowPage
- && oldTarget instanceof PageflowPage) {
- if (((PageflowPage) newSource).getPath().trim().equalsIgnoreCase(
- ((PageflowPage) oldSource).getPath().trim())
- && ((PageflowPage) newTarget)
- .getPath()
- .trim()
- .equalsIgnoreCase(
- ((PageflowPage) oldTarget).getPath().trim())) {
- if ((newLink.getOutcome() == null && oldLink.getOutcome() == null)
- || (newLink.getOutcome() != null
- && oldLink.getOutcome() != null && newLink
- .getOutcome().trim().equals(
- oldLink.getOutcome().trim()))) {
- return true;
- }
- }
- }
-
- return false;
- }
-
- /**
- * Update the link using the same link
- *
- * @param nodesMap
- * @param object
- * @return
- */
- private PageflowLink updatePFLink(PageflowLink newLink, PageflowLink link) {
- PageflowFactory factory = PageflowModelManager.getFactory();
-
- newLink.getBendPoints().clear();
-
- for (Iterator iter = link.getBendPoints().iterator(); iter.hasNext();) {
- PageflowLinkBendpoint bendPoint = (PageflowLinkBendpoint) iter
- .next();
- PageflowLinkBendpoint newBendPoint = factory
- .createPFLinkBendpoint();
- newBendPoint.setD1Height(bendPoint.getD1Height());
- newBendPoint.setD1Width(bendPoint.getD1Width());
- newBendPoint.setD2Height(bendPoint.getD2Height());
- newBendPoint.setD2Width(bendPoint.getD2Width());
- newLink.getBendPoints().add(newBendPoint);
- }
-
- copiedLinks.put(link, link);
- return newLink;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/Pageflow.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/Pageflow.java
deleted file mode 100644
index b76fdafc2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/Pageflow.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.emf.common.util.EList;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>Pageflow</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getNodes <em>Nodes</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getLinks <em>Links</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getConfigfile <em>Configfile</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflow()
- * @model
- * @generated
- */
-public interface Pageflow extends PageflowElement {
- /**
- * Returns the value of the '<em><b>Nodes</b></em>' containment
- * reference list. The list contents are of type
- * {@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode}.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Nodes</em>' containment reference list
- * isn't clear, there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Nodes</em>' containment reference list.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflow_Nodes()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow
- * @model type="org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode"
- * opposite="pageflow" containment="true"
- * @generated
- */
- EList getNodes();
-
- /**
- * Returns the value of the '<em><b>Links</b></em>' containment
- * reference list. The list contents are of type
- * {@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink}. It
- * is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Links</em>' containment reference list
- * isn't clear, there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Links</em>' containment reference list.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflow_Links()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow
- * @model type="org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PFLink"
- * opposite="pageflow" containment="true"
- * @generated
- */
- EList getLinks();
-
- /**
- * Returns the value of the '<em><b>Configfile</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Configfile</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Configfile</em>' attribute.
- * @see #setConfigfile(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflow_Configfile()
- * @model
- * @generated
- */
- String getConfigfile();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getConfigfile <em>Configfile</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Configfile</em>' attribute.
- * @see #getConfigfile()
- * @generated
- */
- void setConfigfile(String value);
-
- /**
- *
- * @param source
- * @param target
- * @param link
- * @generated NOT
- */
- public void connect(PageflowNode source, PageflowNode target, PageflowLink link);
-
- /**
- *
- * @param nodeType
- * @return the default node name
- * @generated NOT
- */
- public String getDefaultNodeName(Class nodeType);
-}
-// Pageflow
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowElement.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowElement.java
deleted file mode 100644
index ba2ee9b68..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowElement.java
+++ /dev/null
@@ -1,292 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.ReferenceElement;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>Element</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getName <em>Name</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getComment <em>Comment</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getX <em>X</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getY <em>Y</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getWidth <em>Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getHeight <em>Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getId <em>Id</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement()
- * @model abstract="true"
- * @generated
- */
-public interface PageflowElement extends EObject {
- /**
- * The pageflow model is based on faces-config model, its elements will
- * reference faces-config elements with ReferenceElement.
- * @return the ref element
- *
- * @generated NOT
- */
- public ReferenceElement getFCElements();
-
- /**
- * Returns the value of the '<em><b>Name</b></em>' attribute. The
- * default value is <code>"unnamed"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Name</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Name</em>' attribute.
- * @see #setName(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Name()
- * @model default="unnamed"
- * @generated
- */
- String getName();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getName <em>Name</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Name</em>' attribute.
- * @see #getName()
- * @generated
- */
- void setName(String value);
-
- /**
- * Returns the value of the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Comment</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Comment</em>' attribute.
- * @see #setComment(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Comment()
- * @model
- * @generated
- */
- String getComment();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getComment <em>Comment</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Comment</em>' attribute.
- * @see #getComment()
- * @generated
- */
- void setComment(String value);
-
- /**
- * Returns the value of the '<em><b>X</b></em>' attribute. The default
- * value is <code>"0"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>X</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>X</em>' attribute.
- * @see #setX(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_X()
- * @model default="0"
- * @generated
- */
- int getX();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getX <em>X</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>X</em>' attribute.
- * @see #getX()
- * @generated
- */
- void setX(int value);
-
- /**
- * Returns the value of the '<em><b>Y</b></em>' attribute. The default
- * value is <code>"0"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Y</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Y</em>' attribute.
- * @see #setY(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Y()
- * @model default="0"
- * @generated
- */
- int getY();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getY <em>Y</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Y</em>' attribute.
- * @see #getY()
- * @generated
- */
- void setY(int value);
-
- /**
- * Returns the value of the '<em><b>Width</b></em>' attribute. The
- * default value is <code>"-1"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Width</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Width</em>' attribute.
- * @see #setWidth(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Width()
- * @model default="-1"
- * @generated
- */
- int getWidth();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getWidth <em>Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Width</em>' attribute.
- * @see #getWidth()
- * @generated
- */
- void setWidth(int value);
-
- /**
- * Returns the value of the '<em><b>Height</b></em>' attribute. The
- * default value is <code>"-1"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Height</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Height</em>' attribute.
- * @see #setHeight(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Height()
- * @model default="-1"
- * @generated
- */
- int getHeight();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getHeight <em>Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Height</em>' attribute.
- * @see #getHeight()
- * @generated
- */
- void setHeight(int value);
-
- /**
- * Returns the value of the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Id</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Id</em>' attribute.
- * @see #setId(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowElement_Id()
- * @model id="true" required="true" volatile="true"
- * @generated
- */
- String getId();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getId <em>Id</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Id</em>' attribute.
- * @see #getId()
- * @generated
- */
- void setId(String value);
-
- /**
- * Returns the value of the '<em><b>Reference Link</b></em>' attribute.
- * The default value is <code>""</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Reference Link</em>' attribute isn't
- * clear, there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Reference Link</em>' attribute.
- * @see #setReferenceLink(String)
- * @model default="" dataType="org.eclipse.emf.ecore.xml.type.String"
- * extendedMetaData="kind='attribute' name='referenceLink'"
- * @generated
- */
- String getReferenceLink();
-
- /**
- * Sets the value of the '{@link PageflowElement#getReferenceLink() <em>Reference Link</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Reference Link</em>' attribute.
- * @see #getReferenceLink()
- * @generated
- */
- void setReferenceLink(String value);
-
- /**
- * @param nofitification
- * @generated NOT
- */
- void notifyModelChanged(Notification nofitification);
-
- /**
- * When the model is modified, the adapters or reference elements should be
- * updated.
- *
- * @generated NOT
- */
- void update();
-
- /**
- * @generated NOT
- */
- void dispose();
-}
-// PageflowElement
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowFactory.java
deleted file mode 100644
index 3d52525eb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowFactory.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.emf.ecore.EFactory;
-
-/**
- * <!-- begin-user-doc --> The <b>Factory</b> for the model. It provides a
- * create method for each non-abstract class of the model. <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage
- * @generated
- */
-public interface PageflowFactory extends EFactory {
- /**
- * The singleton instance of the factory. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- PageflowFactory eINSTANCE = new org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowFactoryImpl();
-
- /**
- * Returns a new object of class '<em>Pageflow</em>'. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @return a new object of class '<em>Pageflow</em>'.
- * @generated
- */
- Pageflow createPageflow();
-
- /**
- * Returns a new object of class '<em>PF Link</em>'. <!-- begin-user-doc
- * --> <!-- end-user-doc -->
- *
- * @return a new object of class '<em>PF Link</em>'.
- * @generated
- */
- PageflowLink createPFLink();
-
- /**
- * Returns a new object of class '<em>PF Page</em>'. <!-- begin-user-doc
- * --> <!-- end-user-doc -->
- *
- * @return a new object of class '<em>PF Page</em>'.
- * @generated
- */
- PageflowPage createPFPage();
-
- /**
- * Returns a new object of class '<em>PF Link Bendpoint</em>'. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @return a new object of class '<em>PF Link Bendpoint</em>'.
- * @generated
- */
- PageflowLinkBendpoint createPFLinkBendpoint();
-
- /**
- * Returns the package supported by this factory. <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- *
- * @return the package supported by this factory.
- * @generated
- */
- PageflowPackage getPageflowPackage();
-
-}
-// PageflowFactory
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLink.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLink.java
deleted file mode 100644
index ac22bcdfa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLink.java
+++ /dev/null
@@ -1,326 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import java.util.Vector;
-
-import org.eclipse.emf.common.util.EList;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>PF Link</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow <em>Pageflow</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget <em>Target</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource <em>Source</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSmallicon <em>Smallicon</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getLargeicon <em>Largeicon</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getFromaction <em>Fromaction</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome <em>Outcome</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#isRedirect <em>Redirect</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getBendPoints <em>Bend Points</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink()
- * @model
- * @generated
- */
-public interface PageflowLink extends PageflowElement {
- /**
- * Returns the value of the '<em><b>Pageflow</b></em>' container reference.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getLinks <em>Links</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Pageflow</em>' container reference isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Pageflow</em>' container reference.
- * @see #setPageflow(Pageflow)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Pageflow()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getLinks
- * @model opposite="links" required="true"
- * @generated
- */
- Pageflow getPageflow();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow <em>Pageflow</em>}' container reference.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Pageflow</em>' container reference.
- * @see #getPageflow()
- * @generated
- */
- void setPageflow(Pageflow value);
-
- /**
- * Returns the value of the '<em><b>Target</b></em>' reference.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getInlinks <em>Inlinks</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Target</em>' reference isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Target</em>' reference.
- * @see #setTarget(PageflowNode)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Target()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getInlinks
- * @model opposite="inlinks" required="true"
- * @generated
- */
- PageflowNode getTarget();
-
- /**
- * @param path
- */
- void setTargetPath(String path);
-
- /**
- * @param path
- */
- void setSourcePath(String path);
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget <em>Target</em>}' reference.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Target</em>' reference.
- * @see #getTarget()
- * @generated
- */
- void setTarget(PageflowNode value);
-
- /**
- * Returns the value of the '<em><b>Source</b></em>' reference.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getOutlinks <em>Outlinks</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Source</em>' reference isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Source</em>' reference.
- * @see #setSource(PageflowNode)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Source()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getOutlinks
- * @model opposite="outlinks" required="true"
- * @generated
- */
- PageflowNode getSource();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource <em>Source</em>}' reference.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Source</em>' reference.
- * @see #getSource()
- * @generated
- */
- void setSource(PageflowNode value);
-
- /**
- * Returns the value of the '<em><b>Smallicon</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Smallicon</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Smallicon</em>' attribute.
- * @see #setSmallicon(String)
- * @model
- * @generated
- */
- String getSmallicon();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSmallicon <em>Smallicon</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Smallicon</em>' attribute.
- * @see #getSmallicon()
- * @generated
- */
- void setSmallicon(String value);
-
- /**
- * Returns the value of the '<em><b>Largeicon</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Largeicon</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Largeicon</em>' attribute.
- * @see #setLargeicon(String)
- * @model
- * @generated
- */
- String getLargeicon();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getLargeicon <em>Largeicon</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Largeicon</em>' attribute.
- * @see #getLargeicon()
- * @generated
- */
- void setLargeicon(String value);
-
- /**
- * Returns the value of the '<em><b>Fromaction</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Fromaction</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Fromaction</em>' attribute.
- * @see #setFromaction(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Fromaction()
- * @model
- * @generated
- */
- String getFromaction();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getFromaction <em>Fromaction</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Fromaction</em>' attribute.
- * @see #getFromaction()
- * @generated
- */
- void setFromaction(String value);
-
- /**
- * Returns the value of the '<em><b>Outcome</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Outcome</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Outcome</em>' attribute.
- * @see #setOutcome(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Outcome()
- * @model
- * @generated
- */
- String getOutcome();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome <em>Outcome</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Outcome</em>' attribute.
- * @see #getOutcome()
- * @generated
- */
- void setOutcome(String value);
-
- /**
- * Returns the value of the '<em><b>Redirect</b></em>' attribute.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Redirect</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Redirect</em>' attribute.
- * @see #setRedirect(boolean)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_Redirect()
- * @model
- * @generated
- */
- boolean isRedirect();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#isRedirect <em>Redirect</em>}' attribute.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- * @param value the new value of the '<em>Redirect</em>' attribute.
- * @see #isRedirect()
- * @generated
- */
- void setRedirect(boolean value);
-
- /**
- * Returns the value of the '<em><b>Bend Points</b></em>' containment reference list.
- * The list contents are of type {@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint}.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink <em>Link</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Bend Points</em>' containment reference list isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- * @return the value of the '<em>Bend Points</em>' containment reference list.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLink_BendPoints()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink
- * @model type="org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PFLinkBendpoint" opposite="link" containment="true"
- * @generated
- */
- EList getBendPoints();
-
- /**
- * <!-- begin-user-doc -->
- * insert a new bendpoint to the link
- * @param index
- * @param point
- * <!--end-user-doc -->
- *
- * @generated NOT
- */
- public void insertBendpoint(int index, PageflowLinkBendpoint point);
-
- /**
- * <!-- begin-user-doc -->
- * remove the current bendpoint
- * @param index
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void removeBendpoint(int index);
-
- /**
- * <!-- begin-user-doc -->
- * Set the current bendpoint
- *
- * @param index
- * @param point
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setBendpoint(int index, PageflowLinkBendpoint point);
-
- /**
- * <!-- begin-user-doc -->
- * Set a group of bendpoints to reconstruct the link
- * @param points
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setBendpoints(Vector points);
-
-}
-// PFLink
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLinkBendpoint.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLinkBendpoint.java
deleted file mode 100644
index 4e4070950..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowLinkBendpoint.java
+++ /dev/null
@@ -1,237 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.emf.ecore.EObject;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>PF Link Bendpoint</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Width <em>D1 Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Height <em>D1 Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Width <em>D2 Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Height <em>D2 Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getWeight <em>Weight</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink <em>Link</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint()
- * @model
- * @generated
- */
-public interface PageflowLinkBendpoint extends EObject {
- /**
- * Returns the value of the '<em><b>D1 Width</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>D1 Width</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>D1 Width</em>' attribute.
- * @see #setD1Width(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_D1Width()
- * @model
- * @generated
- */
- int getD1Width();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Width <em>D1 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>D1 Width</em>' attribute.
- * @see #getD1Width()
- * @generated
- */
- void setD1Width(int value);
-
- /**
- * Returns the value of the '<em><b>D1 Height</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>D1 Height</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>D1 Height</em>' attribute.
- * @see #setD1Height(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_D1Height()
- * @model
- * @generated
- */
- int getD1Height();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Height <em>D1 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>D1 Height</em>' attribute.
- * @see #getD1Height()
- * @generated
- */
- void setD1Height(int value);
-
- /**
- * Returns the value of the '<em><b>D2 Width</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>D2 Width</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>D2 Width</em>' attribute.
- * @see #setD2Width(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_D2Width()
- * @model
- * @generated
- */
- int getD2Width();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Width <em>D2 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>D2 Width</em>' attribute.
- * @see #getD2Width()
- * @generated
- */
- void setD2Width(int value);
-
- /**
- * Returns the value of the '<em><b>D2 Height</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>D2 Height</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>D2 Height</em>' attribute.
- * @see #setD2Height(int)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_D2Height()
- * @model
- * @generated
- */
- int getD2Height();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Height <em>D2 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>D2 Height</em>' attribute.
- * @see #getD2Height()
- * @generated
- */
- void setD2Height(int value);
-
- /**
- * Returns the value of the '<em><b>Weight</b></em>' attribute. The
- * default value is <code>"0.5"</code>. <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Weight</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Weight</em>' attribute.
- * @see #setWeight(float)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_Weight()
- * @model default="0.5"
- * @generated
- */
- float getWeight();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getWeight <em>Weight</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Weight</em>' attribute.
- * @see #getWeight()
- * @generated
- */
- void setWeight(float value);
-
- /**
- * Returns the value of the '<em><b>Link</b></em>' container reference.
- * It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getBendPoints <em>Bend Points</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Link</em>' container reference isn't
- * clear, there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Link</em>' container reference.
- * @see #setLink(PageflowLink)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFLinkBendpoint_Link()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getBendPoints
- * @model opposite="bendPoints" required="true"
- * @generated
- */
- PageflowLink getLink();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink <em>Link</em>}'
- * container reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Link</em>' container reference.
- * @see #getLink()
- * @generated
- */
- void setLink(PageflowLink value);
-
- /**
- * <!-- begin-user-doc -->
- * @return the first relative dim
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public Dimension getFirstRelativeDimension();
-
- /**
- * <!-- begin-user-doc -->
- * @return the second relative dim
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public Dimension getSecondRelativeDimension();
-
- /**
- * <!-- begin-user-doc -->
- * @param dim1
- * @param dim2
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setRelativeDimensions(Dimension dim1, Dimension dim2);
-
-}
-// PFLinkBendpoint
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowNode.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowNode.java
deleted file mode 100644
index 0559badf4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowNode.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.emf.common.util.EList;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>Node</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow <em>Pageflow</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getOutlinks <em>Outlinks</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getInlinks <em>Inlinks</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowNode()
- * @model abstract="true"
- * @generated
- */
-public interface PageflowNode extends PageflowElement {
- /**
- * Returns the value of the '<em><b>Pageflow</b></em>' container
- * reference. It is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getNodes <em>Nodes</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Pageflow</em>' container reference isn't
- * clear, there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Pageflow</em>' container reference.
- * @see #setPageflow(Pageflow)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowNode_Pageflow()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getNodes
- * @model opposite="nodes" required="true"
- * @generated
- */
- Pageflow getPageflow();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow <em>Pageflow</em>}'
- * container reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Pageflow</em>' container
- * reference.
- * @see #getPageflow()
- * @generated
- */
- void setPageflow(Pageflow value);
-
- /**
- * Returns the value of the '<em><b>Outlinks</b></em>' reference list.
- * The list contents are of type
- * {@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink}. It
- * is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource <em>Source</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Outlinks</em>' reference list isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Outlinks</em>' reference list.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowNode_Outlinks()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource
- * @model type="org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PFLink"
- * opposite="source"
- * @generated
- */
- EList getOutlinks();
-
- /**
- * Returns the value of the '<em><b>Inlinks</b></em>' reference list.
- * The list contents are of type
- * {@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink}. It
- * is bidirectional and its opposite is '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget <em>Target</em>}'.
- * <!-- begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Inlinks</em>' reference list isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Inlinks</em>' reference list.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPageflowNode_Inlinks()
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget
- * @model type="org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PFLink"
- * opposite="target"
- * @generated
- */
- EList getInlinks();
-
- /**
- * @param target
- * @return the page flow node
- * @generated NOT
- */
- PageflowLink findLinkTo(PageflowNode target);
-
-}
-// PageflowNode
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPackage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPackage.java
deleted file mode 100644
index e50714248..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPackage.java
+++ /dev/null
@@ -1,1161 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EPackage;
-import org.eclipse.emf.ecore.EReference;
-
-/**
- * <!-- begin-user-doc --> The <b>Package</b> for the model. It contains
- * accessors for the meta objects to represent
- * <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
- * </ul>
- * <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory
- * @generated
- */
-public interface PageflowPackage extends EPackage {
- /**
- * The package name. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- String eNAME = "pageflow"; //$NON-NLS-1$
-
- /**
- * The package namespace URI. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- String eNS_URI = "http://www.sybase.com/suade/pageflow"; //$NON-NLS-1$
-
- /**
- * The package namespace name. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- String eNS_PREFIX = "pageflow"; //$NON-NLS-1$
-
- /**
- * The singleton instance of the package. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- PageflowPackage eINSTANCE = org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl
- .init();
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl <em>Element</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPageflowElement()
- * @generated
- */
- int PAGEFLOW_ELEMENT = 3;
-
- /**
- * The feature id for the '<em><b>Name</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__NAME = 0;
-
- /**
- * The feature id for the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__COMMENT = 1;
-
- /**
- * The feature id for the '<em><b>X</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__X = 2;
-
- /**
- * The feature id for the '<em><b>Y</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__Y = 3;
-
- /**
- * The feature id for the '<em><b>Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__WIDTH = 4;
-
- /**
- * The feature id for the '<em><b>Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__HEIGHT = 5;
-
- /**
- * The feature id for the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__ID = 6;
-
- /**
- * The feature id for the '<em><b>Reference Link</b></em>' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT__REFERENCE_LINK = 7;
-
- /**
- * The number of structural features of the the '<em>Element</em>'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_ELEMENT_FEATURE_COUNT = 8;
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowImpl <em>Pageflow</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPageflow()
- * @generated
- */
- int PAGEFLOW = 0;
-
- /**
- * The feature id for the '<em><b>Name</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__NAME = PAGEFLOW_ELEMENT__NAME;
-
- /**
- * The feature id for the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__COMMENT = PAGEFLOW_ELEMENT__COMMENT;
-
- /**
- * The feature id for the '<em><b>X</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__X = PAGEFLOW_ELEMENT__X;
-
- /**
- * The feature id for the '<em><b>Y</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__Y = PAGEFLOW_ELEMENT__Y;
-
- /**
- * The feature id for the '<em><b>Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__WIDTH = PAGEFLOW_ELEMENT__WIDTH;
-
- /**
- * The feature id for the '<em><b>Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__HEIGHT = PAGEFLOW_ELEMENT__HEIGHT;
-
- /**
- * The feature id for the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__ID = PAGEFLOW_ELEMENT__ID;
-
- /**
- * The feature id for the '<em><b>Reference Link</b></em>' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__REFERENCE_LINK = PAGEFLOW_ELEMENT__REFERENCE_LINK;
-
- /**
- * The feature id for the '<em><b>Nodes</b></em>' containment reference
- * list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__NODES = PAGEFLOW_ELEMENT_FEATURE_COUNT + 0;
-
- /**
- * The feature id for the '<em><b>Links</b></em>' containment reference
- * list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__LINKS = PAGEFLOW_ELEMENT_FEATURE_COUNT + 1;
-
- /**
- * The feature id for the '<em><b>Configfile</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW__CONFIGFILE = PAGEFLOW_ELEMENT_FEATURE_COUNT + 2;
-
- /**
- * The number of structural features of the the '<em>Pageflow</em>'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_FEATURE_COUNT = PAGEFLOW_ELEMENT_FEATURE_COUNT + 3;
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowNodeImpl <em>Node</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowNodeImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPageflowNode()
- * @generated
- */
- int PAGEFLOW_NODE = 1;
-
- /**
- * The feature id for the '<em><b>Name</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__NAME = PAGEFLOW_ELEMENT__NAME;
-
- /**
- * The feature id for the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__COMMENT = PAGEFLOW_ELEMENT__COMMENT;
-
- /**
- * The feature id for the '<em><b>X</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__X = PAGEFLOW_ELEMENT__X;
-
- /**
- * The feature id for the '<em><b>Y</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__Y = PAGEFLOW_ELEMENT__Y;
-
- /**
- * The feature id for the '<em><b>Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__WIDTH = PAGEFLOW_ELEMENT__WIDTH;
-
- /**
- * The feature id for the '<em><b>Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__HEIGHT = PAGEFLOW_ELEMENT__HEIGHT;
-
- /**
- * The feature id for the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__ID = PAGEFLOW_ELEMENT__ID;
-
- /**
- * The feature id for the '<em><b>Reference Link</b></em>' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__REFERENCE_LINK = PAGEFLOW_ELEMENT__REFERENCE_LINK;
-
- /**
- * The feature id for the '<em><b>Pageflow</b></em>' container
- * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__PAGEFLOW = PAGEFLOW_ELEMENT_FEATURE_COUNT + 0;
-
- /**
- * The feature id for the '<em><b>Outlinks</b></em>' reference list.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__OUTLINKS = PAGEFLOW_ELEMENT_FEATURE_COUNT + 1;
-
- /**
- * The feature id for the '<em><b>Inlinks</b></em>' reference list.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE__INLINKS = PAGEFLOW_ELEMENT_FEATURE_COUNT + 2;
-
- /**
- * The number of structural features of the the '<em>Node</em>' class.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PAGEFLOW_NODE_FEATURE_COUNT = PAGEFLOW_ELEMENT_FEATURE_COUNT + 3;
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl <em>PF Link</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPFLink()
- * @generated
- */
- int PF_LINK = 2;
-
- /**
- * The feature id for the '<em><b>Name</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__NAME = PAGEFLOW_ELEMENT__NAME;
-
- /**
- * The feature id for the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__COMMENT = PAGEFLOW_ELEMENT__COMMENT;
-
- /**
- * The feature id for the '<em><b>X</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__X = PAGEFLOW_ELEMENT__X;
-
- /**
- * The feature id for the '<em><b>Y</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__Y = PAGEFLOW_ELEMENT__Y;
-
- /**
- * The feature id for the '<em><b>Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__WIDTH = PAGEFLOW_ELEMENT__WIDTH;
-
- /**
- * The feature id for the '<em><b>Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__HEIGHT = PAGEFLOW_ELEMENT__HEIGHT;
-
- /**
- * The feature id for the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__ID = PAGEFLOW_ELEMENT__ID;
-
- /**
- * The feature id for the '<em><b>Reference Link</b></em>' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__REFERENCE_LINK = PAGEFLOW_ELEMENT__REFERENCE_LINK;
-
- /**
- * The feature id for the '<em><b>Pageflow</b></em>' container
- * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__PAGEFLOW = PAGEFLOW_ELEMENT_FEATURE_COUNT + 0;
-
- /**
- * The feature id for the '<em><b>Target</b></em>' reference. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__TARGET = PAGEFLOW_ELEMENT_FEATURE_COUNT + 1;
-
- /**
- * The feature id for the '<em><b>Source</b></em>' reference. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__SOURCE = PAGEFLOW_ELEMENT_FEATURE_COUNT + 2;
-
- /**
- * The feature id for the '<em><b>Outcome</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__OUTCOME = PAGEFLOW_ELEMENT_FEATURE_COUNT + 3;
-
- /**
- * The feature id for the '<em><b>Redirect</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__REDIRECT = PAGEFLOW_ELEMENT_FEATURE_COUNT + 4;
-
- /**
- * The feature id for the '<em><b>Bend Points</b></em>' containment
- * reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__BEND_POINTS = PAGEFLOW_ELEMENT_FEATURE_COUNT + 5;
-
- /**
- * The feature id for the '<em><b>Smallicon</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__SMALLICON = PAGEFLOW_ELEMENT_FEATURE_COUNT + 6;
-
- /**
- * The feature id for the '<em><b>Largeicon</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__LARGEICON = PAGEFLOW_ELEMENT_FEATURE_COUNT + 7;
-
- /**
- * The feature id for the '<em><b>Fromaction</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK__FROMACTION = PAGEFLOW_ELEMENT_FEATURE_COUNT + 8;
-
- /**
- * The number of structural features of the the '<em>PF Link</em>'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_FEATURE_COUNT = PAGEFLOW_ELEMENT_FEATURE_COUNT + 9;
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl <em>PF Page</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPFPage()
- * @generated
- */
- int PF_PAGE = 5;
-
- /**
- * The feature id for the '<em><b>Name</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__NAME = PAGEFLOW_NODE__NAME;
-
- /**
- * The feature id for the '<em><b>Comment</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__COMMENT = PAGEFLOW_NODE__COMMENT;
-
- /**
- * The feature id for the '<em><b>X</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__X = PAGEFLOW_NODE__X;
-
- /**
- * The feature id for the '<em><b>Y</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__Y = PAGEFLOW_NODE__Y;
-
- /**
- * The feature id for the '<em><b>Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__WIDTH = PAGEFLOW_NODE__WIDTH;
-
- /**
- * The feature id for the '<em><b>Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__HEIGHT = PAGEFLOW_NODE__HEIGHT;
-
- /**
- * The feature id for the '<em><b>Id</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__ID = PAGEFLOW_NODE__ID;
-
- /**
- * The feature id for the '<em><b>Pageflow</b></em>' container
- * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__PAGEFLOW = PAGEFLOW_NODE__PAGEFLOW;
-
- /**
- * The feature id for the '<em><b>Outlinks</b></em>' reference list.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__OUTLINKS = PAGEFLOW_NODE__OUTLINKS;
-
- /**
- * The feature id for the '<em><b>Inlinks</b></em>' reference list.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__INLINKS = PAGEFLOW_NODE__INLINKS;
-
- /**
- * The feature id for the '<em><b>Path</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__PATH = PAGEFLOW_NODE_FEATURE_COUNT + 0;
-
- /**
- * The feature id for the '<em><b>Smallicon</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__SMALLICON = PAGEFLOW_NODE_FEATURE_COUNT + 1;
-
- /**
- * The feature id for the '<em><b>Largeicon</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE__LARGEICON = PAGEFLOW_NODE_FEATURE_COUNT + 2;
-
- /**
- * The number of structural features of the the '<em>PF Page</em>'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_PAGE_FEATURE_COUNT = PAGEFLOW_NODE_FEATURE_COUNT + 3;
-
- /**
- * The meta object id for the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl <em>PF Link Bendpoint</em>}'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl#getPFLinkBendpoint()
- * @generated
- */
- int PF_LINK_BENDPOINT = 8;
-
- /**
- * The feature id for the '<em><b>D1 Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__D1_WIDTH = 0;
-
- /**
- * The feature id for the '<em><b>D1 Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__D1_HEIGHT = 1;
-
- /**
- * The feature id for the '<em><b>D2 Width</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__D2_WIDTH = 2;
-
- /**
- * The feature id for the '<em><b>D2 Height</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__D2_HEIGHT = 3;
-
- /**
- * The feature id for the '<em><b>Weight</b></em>' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__WEIGHT = 4;
-
- /**
- * The feature id for the '<em><b>Link</b></em>' container reference.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT__LINK = 5;
-
- /**
- * The number of structural features of the the '<em>PF Link Bendpoint</em>'
- * class. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- * @ordered
- */
- int PF_LINK_BENDPOINT_FEATURE_COUNT = 6;
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>Pageflow</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow
- * @generated
- */
- EClass getPageflow();
-
- /**
- * Returns the meta object for the containment reference list '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getNodes <em>Nodes</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the containment reference list '<em>Nodes</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getNodes()
- * @see #getPageflow()
- * @generated
- */
- EReference getPageflow_Nodes();
-
- /**
- * Returns the meta object for the containment reference list '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getLinks <em>Links</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the containment reference list '<em>Links</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getLinks()
- * @see #getPageflow()
- * @generated
- */
- EReference getPageflow_Links();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getConfigfile <em>Configfile</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Configfile</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow#getConfigfile()
- * @see #getPageflow()
- * @generated
- */
- EAttribute getPageflow_Configfile();
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode <em>Node</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>Node</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode
- * @generated
- */
- EClass getPageflowNode();
-
- /**
- * Returns the meta object for the container reference '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the container reference '<em>Pageflow</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getPageflow()
- * @see #getPageflowNode()
- * @generated
- */
- EReference getPageflowNode_Pageflow();
-
- /**
- * Returns the meta object for the reference list '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getOutlinks <em>Outlinks</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the reference list '<em>Outlinks</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getOutlinks()
- * @see #getPageflowNode()
- * @generated
- */
- EReference getPageflowNode_Outlinks();
-
- /**
- * Returns the meta object for the reference list '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getInlinks <em>Inlinks</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the reference list '<em>Inlinks</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode#getInlinks()
- * @see #getPageflowNode()
- * @generated
- */
- EReference getPageflowNode_Inlinks();
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink <em>PF Link</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>PF Link</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink
- * @generated
- */
- EClass getPFLink();
-
- /**
- * Returns the meta object for the container reference '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the container reference '<em>Pageflow</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getPageflow()
- * @see #getPFLink()
- * @generated
- */
- EReference getPFLink_Pageflow();
-
- /**
- * Returns the meta object for the reference '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget <em>Target</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the reference '<em>Target</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getTarget()
- * @see #getPFLink()
- * @generated
- */
- EReference getPFLink_Target();
-
- /**
- * Returns the meta object for the reference '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource <em>Source</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the reference '<em>Source</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getSource()
- * @see #getPFLink()
- * @generated
- */
- EReference getPFLink_Source();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome <em>Outcome</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Outcome</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome()
- * @see #getPFLink()
- * @generated
- */
- EAttribute getPFLink_Outcome();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome <em>Outcome</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Outcome</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getOutcome()
- * @see #getPFLink()
- * @generated
- */
- EAttribute getPFLink_Fromaction();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#isRedirect <em>Redirect</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Redirect</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#isRedirect()
- * @see #getPFLink()
- * @generated
- */
- EAttribute getPFLink_Redirect();
-
- /**
- * Returns the meta object for the containment reference list '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getBendPoints <em>Bend Points</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the containment reference list '<em>Bend Points</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink#getBendPoints()
- * @see #getPFLink()
- * @generated
- */
- EReference getPFLink_BendPoints();
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement <em>Element</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>Element</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement
- * @generated
- */
- EClass getPageflowElement();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getName <em>Name</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Name</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getName()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Name();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getComment <em>Comment</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Comment</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getComment()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Comment();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getX <em>X</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>X</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getX()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_X();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getY <em>Y</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Y</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getY()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Y();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getWidth <em>Width</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Width</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getWidth()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Width();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getHeight <em>Height</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Height</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getHeight()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Height();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getId <em>Id</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Id</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement#getId()
- * @see #getPageflowElement()
- * @generated
- */
- EAttribute getPageflowElement_Id();
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage <em>PF Page</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>PF Page</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage
- * @generated
- */
- EClass getPFPage();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getPath <em>Path</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Path</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getPath()
- * @see #getPFPage()
- * @generated
- */
- EAttribute getPFPage_Path();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getSmallicon <em>Smallicon</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Smallicon</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getSmallicon()
- * @see #getPFPage()
- * @generated
- */
- EAttribute getPFPage_Smallicon();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getLargeicon <em>Largeicon</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Largeicon</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getLargeicon()
- * @see #getPFPage()
- * @generated
- */
- EAttribute getPFPage_Largeicon();
-
- /**
- * Returns the meta object for class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint <em>PF Link Bendpoint</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for class '<em>PF Link Bendpoint</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint
- * @generated
- */
- EClass getPFLinkBendpoint();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Width <em>D1 Width</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>D1 Width</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Width()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EAttribute getPFLinkBendpoint_D1Width();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Height <em>D1 Height</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>D1 Height</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD1Height()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EAttribute getPFLinkBendpoint_D1Height();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Width <em>D2 Width</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>D2 Width</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Width()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EAttribute getPFLinkBendpoint_D2Width();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Height <em>D2 Height</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>D2 Height</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getD2Height()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EAttribute getPFLinkBendpoint_D2Height();
-
- /**
- * Returns the meta object for the attribute '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getWeight <em>Weight</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the attribute '<em>Weight</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getWeight()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EAttribute getPFLinkBendpoint_Weight();
-
- /**
- * Returns the meta object for the container reference '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink <em>Link</em>}'.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the meta object for the container reference '<em>Link</em>'.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint#getLink()
- * @see #getPFLinkBendpoint()
- * @generated
- */
- EReference getPFLinkBendpoint_Link();
-
- /**
- * Returns the factory that creates the instances of the model. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @return the factory that creates the instances of the model.
- * @generated
- */
- PageflowFactory getPageflowFactory();
-
-}
-// PageflowPackage
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPage.java
deleted file mode 100644
index b6cecb55e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/PageflowPage.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model;
-
-/**
- * <!-- begin-user-doc --> A representation of the model object '<em><b>PF Page</b></em>'.
- * <!-- end-user-doc -->
- *
- * <p>
- * The following features are supported:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getPath <em>Path</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getSmallicon <em>Smallicon</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getLargeicon <em>Largeicon</em>}</li>
- * </ul>
- * </p>
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFPage()
- * @model
- * @generated
- */
-public interface PageflowPage extends PageflowNode {
- /**
- * Returns the value of the '<em><b>Path</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Path</em>' attribute isn't clear, there
- * really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Path</em>' attribute.
- * @see #setPath(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFPage_Path()
- * @model
- * @generated
- */
- String getPath();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getPath <em>Path</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Path</em>' attribute.
- * @see #getPath()
- * @generated
- */
- void setPath(String value);
-
- /**
- * Returns the value of the '<em><b>Smallicon</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Smallicon</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Smallicon</em>' attribute.
- * @see #setSmallicon(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFPage_Smallicon()
- * @model
- * @generated
- */
- String getSmallicon();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getSmallicon <em>Smallicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Smallicon</em>' attribute.
- * @see #getSmallicon()
- * @generated
- */
- void setSmallicon(String value);
-
- /**
- * Returns the value of the '<em><b>Largeicon</b></em>' attribute. <!--
- * begin-user-doc -->
- * <p>
- * If the meaning of the '<em>Largeicon</em>' attribute isn't clear,
- * there really should be more of a description here...
- * </p>
- * <!-- end-user-doc -->
- *
- * @return the value of the '<em>Largeicon</em>' attribute.
- * @see #setLargeicon(String)
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#getPFPage_Largeicon()
- * @model
- * @generated
- */
- String getLargeicon();
-
- /**
- * Sets the value of the '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage#getLargeicon <em>Largeicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @param value
- * the new value of the '<em>Largeicon</em>' attribute.
- * @see #getLargeicon()
- * @generated
- */
- void setLargeicon(String value);
-
-}
-// PFPage
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/LinkReferenceElement.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/LinkReferenceElement.java
deleted file mode 100644
index 0ed483c5e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/LinkReferenceElement.java
+++ /dev/null
@@ -1,274 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FromActionType;
-import org.eclipse.jst.jsf.facesconfig.emf.FromOutcomeType;
-import org.eclipse.jst.jsf.facesconfig.emf.IconType;
-import org.eclipse.jst.jsf.facesconfig.emf.LargeIconType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.RedirectType;
-import org.eclipse.jst.jsf.facesconfig.emf.SmallIconType;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.TransformUtil;
-
-/**
- * The reference element represents a mapping from pageflow link to a navigation
- * case.
- *
- * @author hmeng
- */
-
-public class LinkReferenceElement extends ReferenceElement {
-
- public void add(EObject object) {
- Assert.isTrue(object instanceof NavigationCaseType);
- clear();
- super.add(object);
- }
-
- /**
- * @param pageflowElement
- */
- public LinkReferenceElement(PageflowElement pageflowElement) {
- super(pageflowElement);
- }
-
- /**
- * @param pageflowElement
- * @param facesConfigObject
- */
- public LinkReferenceElement(PageflowElement pageflowElement,
- EObject facesConfigObject) {
- super(pageflowElement, facesConfigObject);
- }
-
- public void update() {
- for (Iterator nodes = getData().iterator(); nodes.hasNext();) {
- Object next = nodes.next();
- if (!TransformUtil.isValidFacesConfigElement((EObject) next)) {
- nodes.remove();
- }
- }
- }
-
- public Object get(int eFeature) {
- Object result = null;
- switch (eFeature) {
- case PageflowPackage.PF_LINK__COMMENT:
- break;
- case PageflowPackage.PF_LINK__OUTCOME:
- if (!isEmpty()) {
- FromOutcomeType outcome = ((NavigationCaseType) getData()
- .get(0)).getFromOutcome();
- if (outcome != null) {
- result = outcome.getTextContent();
- }
- }
- break;
- case PageflowPackage.PF_LINK__NAME:
- break;
- case PageflowPackage.PF_LINK__REDIRECT:
- result = new Boolean(false);
- if (!isEmpty()) {
- RedirectType outcome = ((NavigationCaseType) getData().get(0))
- .getRedirect();
- if (outcome != null) {
- result = new Boolean(true);
- }
- }
- break;
-
- case PageflowPackage.PF_LINK__FROMACTION:
- if (!isEmpty()) {
- FromActionType fromActionType = ((NavigationCaseType) getData()
- .get(0)).getFromAction();
- if (fromActionType != null) {
- result = fromActionType.getTextContent();
- }
- }
- break;
- case PageflowPackage.PF_LINK__SMALLICON:
- if (!isEmpty()) {
- List icons = ((NavigationCaseType) getData().get(0)).getIcon();
- if (icons.size() > 0) {
- result = ((IconType) icons.get(0)).getSmallIcon() != null ? ((IconType) icons
- .get(0)).getSmallIcon().getTextContent()
- : null;
- }
- }
- break;
- case PageflowPackage.PF_LINK__LARGEICON:
- if (!isEmpty()) {
- List icons = ((NavigationCaseType) getData().get(0)).getIcon();
- if (icons.size() > 0) {
- result = ((IconType) icons.get(0)).getLargeIcon() != null ? ((IconType) icons
- .get(0)).getLargeIcon().getTextContent()
- : null;
- }
- }
- break;
- }
- return result;
- }
-
- public void set(EStructuralFeature eFeature, Object newVal) {
- switch (eFeature.getFeatureID()) {
- case PageflowPackage.PF_LINK__COMMENT:
- break;
- case PageflowPackage.PF_LINK__OUTCOME: {
- FromOutcomeType oldOutcome = null;
- FromOutcomeType newOutcome = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- oldOutcome = ((NavigationCaseType) getData().get(0))
- .getFromOutcome();
- if (newValue == null || newValue.length() == 0) {
- ((NavigationCaseType) getData().get(0))
- .setFromOutcome(null);
- } else {
- if (oldOutcome == null) {
- newOutcome = FacesConfigFactory.eINSTANCE
- .createFromOutcomeType();
- newOutcome.setTextContent(newValue);
- ((NavigationCaseType) getData().get(0))
- .setFromOutcome(newOutcome);
- } else {
- oldOutcome.setTextContent(newValue);
- }
- }
- }
- break;
- }
- case PageflowPackage.PF_LINK__NAME:
- break;
- case PageflowPackage.PF_LINK__REDIRECT:
- RedirectType redirect = null;
- RedirectType oldRedirect = null;
- boolean newRedirect = ((Boolean) newVal).booleanValue();
- if (!isEmpty()) {
- oldRedirect = ((NavigationCaseType) getData().get(0))
- .getRedirect();
- if (!newRedirect) {
- redirect = null;
- } else {
- if (oldRedirect == null) {
- redirect = FacesConfigFactory.eINSTANCE
- .createRedirectType();
- }
- }
- ((NavigationCaseType) getData().get(0)).setRedirect(redirect);
- }
- break;
- case PageflowPackage.PF_LINK__FROMACTION:
- FromActionType oldFromActionType,
- newFromActionType;
- String newFromaction = (String) newVal;
- if (!isEmpty()) {
- oldFromActionType = ((NavigationCaseType) getData().get(0))
- .getFromAction();
- if (newFromaction == null || newFromaction.length() == 0) {
- ((NavigationCaseType) getData().get(0)).setFromAction(null);
- } else {
- if (oldFromActionType == null) {
- newFromActionType = FacesConfigFactory.eINSTANCE
- .createFromActionType();
- newFromActionType.setTextContent(newFromaction);
- ((NavigationCaseType) getData().get(0))
- .setFromAction(newFromActionType);
- } else {
- oldFromActionType.setTextContent(newFromaction);
- }
- }
- }
- break;
- case PageflowPackage.PF_LINK__SMALLICON: {
- SmallIconType oldSmallicon = null;
- SmallIconType newSmallIconType = null;
- IconType icon = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- List icons = ((NavigationCaseType) getData().get(0)).getIcon();
- if (newValue == null || newValue.length() == 0) {
- if (icons.size() > 0) {
- if (((IconType) icons.get(0)).getSmallIcon() != null) {
- ((IconType) icons.get(0)).setSmallIcon(null);
- }
- }
- } else {
- if (icons.size() == 0) {
- icon = FacesConfigFactory.eINSTANCE.createIconType();
- newSmallIconType = FacesConfigFactory.eINSTANCE
- .createSmallIconType();
- newSmallIconType.setTextContent(newValue);
- icon.setSmallIcon(newSmallIconType);
- icons.add(icon);
- } else if (((IconType) icons.get(0)).getSmallIcon() == null) {
- newSmallIconType = FacesConfigFactory.eINSTANCE
- .createSmallIconType();
- newSmallIconType.setTextContent(newValue);
- icon = ((IconType) icons.get(0));
- icon.setSmallIcon(newSmallIconType);
- } else {
- oldSmallicon = ((IconType) icons.get(0)).getSmallIcon();
- oldSmallicon.setTextContent(newValue);
- }
- }
- }
- break;
- }
- case PageflowPackage.PF_LINK__LARGEICON: {
- String newValue = (String) newVal;
- LargeIconType oldLargeIcon = null;
- LargeIconType newLargeIconType = null;
- IconType icon = null;
- if (!isEmpty()) {
- List icons = ((NavigationCaseType) getData().get(0)).getIcon();
- if (newValue == null || newValue.length() == 0) {
- if (icons.size() > 0) {
- if (((IconType) icons.get(0)).getLargeIcon() != null) {
- ((IconType) icons.get(0)).setLargeIcon(null);
- }
- }
- } else {
- if (icons.size() == 0) {
- icon = FacesConfigFactory.eINSTANCE.createIconType();
- newLargeIconType = FacesConfigFactory.eINSTANCE
- .createLargeIconType();
- newLargeIconType.setTextContent(newValue);
- icon.setLargeIcon(newLargeIconType);
- icons.add(icon);
- } else if (((IconType) icons.get(0)).getLargeIcon() == null) {
- newLargeIconType = FacesConfigFactory.eINSTANCE
- .createLargeIconType();
- newLargeIconType.setTextContent(newValue);
- icon = ((IconType) icons.get(0));
- icon.setLargeIcon(newLargeIconType);
- } else {
- oldLargeIcon = ((IconType) icons.get(0)).getLargeIcon();
- oldLargeIcon.setTextContent(newValue);
- }
- }
- }
- break;
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageReferenceElement.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageReferenceElement.java
deleted file mode 100644
index 0a81af6ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageReferenceElement.java
+++ /dev/null
@@ -1,400 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FromViewIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.IconType;
-import org.eclipse.jst.jsf.facesconfig.emf.LargeIconType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.emf.SmallIconType;
-import org.eclipse.jst.jsf.facesconfig.emf.ToViewIdType;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.FC2PFTransformer;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.TransformUtil;
-
-/**
- * The reference element represents a mapping from pageflow page to one or more
- * navigation rules/cases's view IDs (fromViewID or toViewID).
- *
- * @author hmeng
- */
-
-public class PageReferenceElement extends ReferenceElement {
-
- /**
- * @param pageflowElement
- */
- public PageReferenceElement(PageflowElement pageflowElement) {
- super(pageflowElement);
- }
-
- /**
- * @param pageflowElement
- * @param facesConfigObject
- */
- public PageReferenceElement(PageflowElement pageflowElement,
- EObject facesConfigObject) {
- super(pageflowElement, facesConfigObject);
- }
-
- public void add(EObject object) {
- Assert.isTrue(object instanceof FromViewIdType
- || object instanceof ToViewIdType);
- super.add(object);
- }
-
- public void update() {
- outer: for (Iterator nodes = getData().iterator(); nodes.hasNext();) {
- Object next = nodes.next();
- if (next instanceof FromViewIdType) {
- if (!TransformUtil.isValidFacesConfigElement((EObject) next)) {
- nodes.remove();
- continue;
- }
- List links = ((PageflowPage) pageflowElement).getOutlinks();
- for (int i = 0; i < links.size(); i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- if (!link.getFCElements().isEmpty()
- && TransformUtil
- .isValidFacesConfigElement((NavigationCaseType) ((PageflowLink) links
- .get(i)).getFCElements().getData()
- .get(0))) {
- NavigationRuleType rule = (NavigationRuleType) ((NavigationCaseType) ((PageflowLink) links
- .get(i)).getFCElements().getData().get(0))
- .eContainer();
- if (rule == null || rule.getFromViewId() == next) {
- // There navigation case
- // matching this end.
- continue outer;
- }
- }
- }
- // No case contains this end.
- nodes.remove();
- } else if (next instanceof ToViewIdType) {
- if (!TransformUtil.isValidFacesConfigElement((EObject) next)) {
- nodes.remove();
- continue;
- }
- // Verify this is case end.
- List links = ((PageflowPage) pageflowElement).getInlinks();
- for (int i = 0; i < links.size(); i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- if (!link.getFCElements().isEmpty()
- && TransformUtil
- .isValidFacesConfigElement((NavigationCaseType) link
- .getFCElements().getData().get(0))) {
- if (((NavigationCaseType) ((PageflowLink) links.get(i))
- .getFCElements().getData().get(0))
- .getToViewId() == next) {
- // There navigation case
- // matching this end.
- continue outer;
- }
- }
- }
- // No case contains this end.
- nodes.remove();
- }
- }
- }
-
- public Object get(int eFeature) {
- Object result = null;
- switch (eFeature) {
- case PageflowPackage.PF_PAGE__COMMENT:
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List descriptions = rule.getDescription();
- if (descriptions.size() > 0) {
- result = ((DescriptionType) descriptions.get(0))
- .getTextContent();
- break;
- }
- }
- }
- }
- break;
- case PageflowPackage.PF_PAGE__LARGEICON:
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List icons = rule.getIcon();
- if (icons.size() > 0) {
- result = ((IconType) icons.get(0)).getLargeIcon() != null ? ((IconType) icons
- .get(0)).getLargeIcon().getTextContent()
- : null;
- break;
- }
- }
- }
- }
- break;
- case PageflowPackage.PF_PAGE__NAME:
- // To see if it is in navigation rule.
- if (!isEmpty() && !isEndOnly()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List displaynames = rule.getDisplayName();
- if (displaynames.size() > 0) {
- result = ((DisplayNameType) displaynames.get(0))
- .getTextContent();
- break;
- }
- }
- }
- }
- break;
- case PageflowPackage.PF_PAGE__PATH:
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- if (getData().get(i) instanceof FromViewIdType) {
- result = ((FromViewIdType) getData().get(i))
- .getTextContent();
- break;
- }
- }
- if (result == null && getData().get(0) instanceof ToViewIdType) {
- result = ((ToViewIdType) getData().get(0)).getTextContent();
- }
- }
- break;
- case PageflowPackage.PF_PAGE__SMALLICON:
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List icons = rule.getIcon();
- if (icons.size() > 0) {
- result = ((IconType) icons.get(0)).getSmallIcon() != null ? ((IconType) icons
- .get(0)).getSmallIcon().getTextContent()
- : null;
- break;
- }
- }
- }
- }
- break;
- }
- return result;
- }
-
- private NavigationRuleType resolveRuleFromFCElement(Object object) {
- if (object instanceof FromViewIdType) {
- return (NavigationRuleType) ((FromViewIdType) object).eContainer();
- }
- return null;
- }
-
- private NavigationRuleType resolveRuleFromPFElement(Object object) {
- if (object instanceof PageflowLink) {
- NavigationCaseType caseType = (NavigationCaseType) ((PageflowLink) object)
- .getFCElements().getData().get(0);
- return (NavigationRuleType) caseType.eContainer();
- }
- return null;
- }
-
- public void set(EStructuralFeature eFeature, Object newVal) {
- switch (eFeature.getFeatureID()) {
- case PageflowPackage.PF_PAGE__COMMENT: {
- DescriptionType description = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- rule.getDescription().clear();
- description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(newValue);
- rule.getDescription().add(description);
- }
- }
- }
- break;
- }
- case PageflowPackage.PF_PAGE__LARGEICON: {
- LargeIconType oldLargeIcon = null;
- LargeIconType newLargeIconType = null;
- IconType icon = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List icons = rule.getIcon();
- if (newValue == null || newValue.length() == 0) {
- if (icons.size() > 0) {
- if (((IconType) icons.get(0)).getLargeIcon() != null) {
- ((IconType) icons.get(0))
- .setLargeIcon(null);
- }
- }
- } else {
- if (icons.size() == 0) {
- icon = FacesConfigFactory.eINSTANCE
- .createIconType();
- newLargeIconType = FacesConfigFactory.eINSTANCE
- .createLargeIconType();
- newLargeIconType.setTextContent(newValue);
- icon.setLargeIcon(newLargeIconType);
- icons.add(icon);
- } else if (((IconType) icons.get(0)).getLargeIcon() == null) {
- newLargeIconType = FacesConfigFactory.eINSTANCE
- .createLargeIconType();
- newLargeIconType.setTextContent(newValue);
- icon = ((IconType) icons.get(0));
- icon.setLargeIcon(newLargeIconType);
- } else {
- oldLargeIcon = ((IconType) icons.get(0))
- .getLargeIcon();
- oldLargeIcon.setTextContent(newValue);
- }
- }
- }
- }
- }
- break;
- }
- case PageflowPackage.PF_PAGE__NAME:
- DisplayNameType newDisplayNameType = null;
- String newName = (String) newVal;
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- rule.getDisplayName().clear();
- if (newName != null && newName.length() > 0) {
- newDisplayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- newDisplayNameType.setTextContent(newName);
- rule.getDisplayName().add(newDisplayNameType);
- }
- }
- }
- }
- break;
- case PageflowPackage.PF_PAGE__PATH: {
- Object oldPath = null;
- Object newPath = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- if (getData().get(i) instanceof FromViewIdType) {
- oldPath = getData().get(i);
- ((FromViewIdType) oldPath).setTextContent(newValue);
- } else if (getData().get(i) instanceof ToViewIdType) {
- oldPath = getData().get(i);
- ((ToViewIdType) oldPath).setTextContent(newValue);
- }
- }
- }
- // Create new fromViewID or toViewID node as needed.
- else if (newValue != null && !"*".equals(newValue)) { //$NON-NLS-1$
- if (((PageflowPage) pageflowElement).getOutlinks().size() > 0) {
- List links = ((PageflowPage) pageflowElement).getOutlinks();
- for (int i = 0, n = links.size(); i < n; i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- NavigationRuleType rule = resolveRuleFromPFElement(link);
- newPath = FC2PFTransformer.createRLFromViewID(newValue);
- rule.setFromViewId((FromViewIdType) newPath);
- add((EObject) newPath);
- }
- links = ((PageflowPage) pageflowElement).getInlinks();
- for (int i = 0, n = links.size(); i < n; i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- NavigationCaseType caseType = (NavigationCaseType) link
- .getFCElements().getData().get(0);
- newPath = FC2PFTransformer.createFCToViewID(newValue);
- caseType.setToViewId((ToViewIdType) newPath);
- add((EObject) newPath);
- }
- }
- }
- break;
- }
- case PageflowPackage.PF_PAGE__SMALLICON: {
- SmallIconType oldSmallicon = null;
- SmallIconType newSmallIconType = null;
- IconType icon = null;
- String newValue = (String) newVal;
- if (!isEmpty()) {
- for (int i = 0, n = getData().size(); i < n; i++) {
- NavigationRuleType rule = null;
- if ((rule = resolveRuleFromFCElement(getData().get(i))) != null) {
- List icons = rule.getIcon();
- if (newValue == null || newValue.length() == 0) {
- if (icons.size() > 0) {
- if (((IconType) icons.get(0)).getSmallIcon() != null) {
- ((IconType) icons.get(0))
- .setSmallIcon(null);
- }
- }
- } else {
- if (icons.size() == 0) {
- icon = FacesConfigFactory.eINSTANCE
- .createIconType();
- newSmallIconType = FacesConfigFactory.eINSTANCE
- .createSmallIconType();
- newSmallIconType.setTextContent(newValue);
- icon.setSmallIcon(newSmallIconType);
- icons.add(icon);
- } else if (((IconType) icons.get(0)).getSmallIcon() == null) {
- newSmallIconType = FacesConfigFactory.eINSTANCE
- .createSmallIconType();
- newSmallIconType.setTextContent(newValue);
- icon = ((IconType) icons.get(0));
- icon.setSmallIcon(newSmallIconType);
- } else {
- oldSmallicon = ((IconType) icons.get(0))
- .getSmallIcon();
- oldSmallicon.setTextContent(newValue);
- }
- }
- }
- }
- }
- break;
- }
- }
- }
-
- /**
- * @return true if none of the data are from view id's
- */
- public boolean isEndOnly() {
- for (int i = 0, n = getData().size(); i < n; i++) {
- if (getData().get(i) instanceof FromViewIdType) {
- return false;
- }
- }
- return true;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowElementImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowElementImpl.java
deleted file mode 100644
index 6948fd73c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowElementImpl.java
+++ /dev/null
@@ -1,616 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.impl.EObjectImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization.TransformUtil;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>Element</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getName <em>Name</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getComment <em>Comment</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getX <em>X</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getY <em>Y</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getWidth <em>Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getHeight <em>Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowElementImpl#getId <em>Id</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public abstract class PageflowElementImpl extends EObjectImpl implements
- PageflowElement {
- private static final String idPrefix = "pf"; //$NON-NLS-1$
-
- /**
- * @generated NOT
- */
- private String id;
-
- /**
- * @generated NOT
- */
- private static int counter = 0;
-
- /**
- * the reference element
- */
- protected ReferenceElement refElement;
-
- /**
- * The default value of the '{@link #getName() <em>Name</em>}' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getName()
- * @generated
- * @ordered
- */
- protected static final String NAME_EDEFAULT = "unnamed"; //$NON-NLS-1$
-
- /**
- * The cached value of the '{@link #getName() <em>Name</em>}' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getName()
- * @generated
- * @ordered
- */
- protected String name = NAME_EDEFAULT;
-
- /**
- * The default value of the '{@link #getComment() <em>Comment</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getComment()
- * @generated
- * @ordered
- */
- protected static final String COMMENT_EDEFAULT = null;
-
- /**
- * The cached value of the '{@link #getComment() <em>Comment</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getComment()
- * @generated
- * @ordered
- */
- protected String comment = COMMENT_EDEFAULT;
-
- /**
- * The default value of the '{@link #getX() <em>X</em>}' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getX()
- * @generated
- * @ordered
- */
- protected static final int X_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getX() <em>X</em>}' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getX()
- * @generated
- * @ordered
- */
- protected int x = X_EDEFAULT;
-
- /**
- * The default value of the '{@link #getY() <em>Y</em>}' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getY()
- * @generated
- * @ordered
- */
- protected static final int Y_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getY() <em>Y</em>}' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getY()
- * @generated
- * @ordered
- */
- protected int y = Y_EDEFAULT;
-
- /**
- * The default value of the '{@link #getWidth() <em>Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getWidth()
- * @generated
- * @ordered
- */
- protected static final int WIDTH_EDEFAULT = -1;
-
- /**
- * The cached value of the '{@link #getWidth() <em>Width</em>}' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getWidth()
- * @generated
- * @ordered
- */
- protected int width = WIDTH_EDEFAULT;
-
- /**
- * The default value of the '{@link #getHeight() <em>Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getHeight()
- * @generated
- * @ordered
- */
- protected static final int HEIGHT_EDEFAULT = -1;
-
- /**
- * The default value of the '{@link #getReferenceLink() <em>Reference Link</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getReferenceLink()
- * @generated
- * @ordered
- */
- protected static final String REFERENCE_LINK_EDEFAULT = ""; //$NON-NLS-1$
-
- /**
- * The cached value of the '{@link #getReferenceLink() <em>Reference Link</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getReferenceLink()
- * @generated
- * @ordered
- */
- protected String referenceLink = REFERENCE_LINK_EDEFAULT;
-
- /**
- * The cached value of the '{@link #getHeight() <em>Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getHeight()
- * @generated
- * @ordered
- */
- protected int height = HEIGHT_EDEFAULT;
-
- /**
- * The default value of the '{@link #getId() <em>Id</em>}' attribute. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getId()
- * @generated
- * @ordered
- */
- protected static final String ID_EDEFAULT = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowElementImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPageflowElement();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String getName() {
- return name == null || name.length() == 0 ? NAME_EDEFAULT : name;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setName(String newName) {
- String oldName = name;
- name = newName;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__NAME, oldName, name));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String getComment() {
- return comment;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setComment(String newComment) {
- String oldComment = comment;
- comment = newComment;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__COMMENT, oldComment,
- comment));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getX() {
- return x;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setX(int newX) {
- int oldX = x;
- x = newX;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__X, oldX, x));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getY() {
- return y;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setY(int newY) {
- int oldY = y;
- y = newY;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__Y, oldY, y));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getWidth() {
- return width;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setWidth(int newWidth) {
- int oldWidth = width;
- width = newWidth;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__WIDTH, oldWidth, width));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getHeight() {
- return height;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setHeight(int newHeight) {
- int oldHeight = height;
- height = newHeight;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT, oldHeight, height));
- }
-
- /**
- * Generate (and cache) an id as needed
- *
- * @generated NOT
- */
- public String getId() {
- if (id == null) {
- id = generateId();
- }
- return id;
- }
-
- /**
- * Generate a random id based on the current time
- *
- * @return the generated id
- *
- * @generated NOT
- */
- public synchronized String generateId() {
- long current = System.currentTimeMillis();
- return idPrefix + current + counter++;
- }
-
- /**
- * Set or generate an Id This method should not be called except when
- * populating from the serialization
- *
- * @generated NOT
- */
- public void setId(String newId) {
- if (newId == null && id == null) {
- id = generateId();
- } else {
- id = newId;
- }
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String getReferenceLink() {
- return referenceLink;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setReferenceLink(String newReferenceLink) {
- String oldReferenceLink = referenceLink;
- referenceLink = newReferenceLink;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__REFERENCE_LINK,
- oldReferenceLink, referenceLink));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_ELEMENT__NAME:
- return getName();
- case PageflowPackage.PAGEFLOW_ELEMENT__COMMENT:
- return getComment();
- case PageflowPackage.PAGEFLOW_ELEMENT__X:
- return new Integer(getX());
- case PageflowPackage.PAGEFLOW_ELEMENT__Y:
- return new Integer(getY());
- case PageflowPackage.PAGEFLOW_ELEMENT__WIDTH:
- return new Integer(getWidth());
- case PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT:
- return new Integer(getHeight());
- case PageflowPackage.PAGEFLOW_ELEMENT__ID:
- return getId();
- case PageflowPackage.PAGEFLOW_ELEMENT__REFERENCE_LINK:
- return getReferenceLink();
- }
- return eDynamicGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_ELEMENT__NAME:
- setName((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__COMMENT:
- setComment((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__X:
- setX(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__Y:
- setY(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__WIDTH:
- setWidth(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT:
- setHeight(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__ID:
- setId((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__REFERENCE_LINK:
- setReferenceLink((String) newValue);
- return;
- }
- eDynamicSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_ELEMENT__NAME:
- setName(NAME_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__COMMENT:
- setComment(COMMENT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__X:
- setX(X_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__Y:
- setY(Y_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__WIDTH:
- setWidth(WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT:
- setHeight(HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__ID:
- setId(ID_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_ELEMENT__REFERENCE_LINK:
- setReferenceLink(REFERENCE_LINK_EDEFAULT);
- return;
- }
- eDynamicUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_ELEMENT__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT
- .equals(name);
- case PageflowPackage.PAGEFLOW_ELEMENT__COMMENT:
- return COMMENT_EDEFAULT == null ? comment != null
- : !COMMENT_EDEFAULT.equals(comment);
- case PageflowPackage.PAGEFLOW_ELEMENT__X:
- return x != X_EDEFAULT;
- case PageflowPackage.PAGEFLOW_ELEMENT__Y:
- return y != Y_EDEFAULT;
- case PageflowPackage.PAGEFLOW_ELEMENT__WIDTH:
- return width != WIDTH_EDEFAULT;
- case PageflowPackage.PAGEFLOW_ELEMENT__HEIGHT:
- return height != HEIGHT_EDEFAULT;
- case PageflowPackage.PAGEFLOW_ELEMENT__ID:
- return ID_EDEFAULT == null ? getId() != null : !ID_EDEFAULT
- .equals(getId());
- case PageflowPackage.PAGEFLOW_ELEMENT__REFERENCE_LINK:
- return REFERENCE_LINK_EDEFAULT == null ? referenceLink != null
- : !REFERENCE_LINK_EDEFAULT.equals(referenceLink);
- }
- return eDynamicIsSet(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String toString() {
- if (eIsProxy())
- return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (name: "); //$NON-NLS-1$
- result.append(name);
- result.append(", comment: "); //$NON-NLS-1$
- result.append(comment);
- result.append(", x: "); //$NON-NLS-1$
- result.append(x);
- result.append(", y: "); //$NON-NLS-1$
- result.append(y);
- result.append(", width: "); //$NON-NLS-1$
- result.append(width);
- result.append(", height: "); //$NON-NLS-1$
- result.append(height);
- result.append(", referenceLink: "); //$NON-NLS-1$
- result.append(referenceLink);
- result.append(')');
- return result.toString();
- }
-
- /**
- * The synchronizer will use this to notify adapters for the faces-config's
- * modification.
- *
- * @generated NOT
- */
- public void notifyModelChanged(Notification notification) {
- if (eNotificationRequired())
- eNotify(notification);
- }
-
- /**
- * @generated NOT
- */
-
- public ReferenceElement getFCElements() {
- return null;
- }
-
- /**
- * @generated NOT
- */
- public void update() {
- getFCElements().update();
- if (!TransformUtil.isValidPageflowElement(this)) {
- eAdapters().clear();
- }
- }
-
- /**
- * @generated NOT
- */
- public void dispose() {
- getFCElements().dispose();
- eAdapters.clear();
- }
-
-}
-// PageflowElementImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowFactoryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowFactoryImpl.java
deleted file mode 100644
index aabbe3e3a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowFactoryImpl.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.impl.EFactoryImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model <b>Factory</b>. <!--
- * end-user-doc -->
- *
- * @generated
- */
-public class PageflowFactoryImpl extends EFactoryImpl implements
- PageflowFactory {
- /**
- * Creates and instance of the factory. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- public PageflowFactoryImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EObject create(EClass eClass) {
- switch (eClass.getClassifierID()) {
- case PageflowPackage.PAGEFLOW:
- return createPageflow();
- case PageflowPackage.PF_LINK:
- return createPFLink();
- case PageflowPackage.PF_PAGE:
- return createPFPage();
- case PageflowPackage.PF_LINK_BENDPOINT:
- return createPFLinkBendpoint();
- default:
- throw new IllegalArgumentException("The class '" + eClass.getName() //$NON-NLS-1$
- + "' is not a valid classifier"); //$NON-NLS-1$
- }
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Pageflow createPageflow() {
- PageflowImpl pageflow = new PageflowImpl();
- return pageflow;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowLink createPFLink() {
- PageflowLinkImpl pfLink = new PageflowLinkImpl();
- return pfLink;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowPage createPFPage() {
- PageflowPageImpl pfPage = new PageflowPageImpl();
- return pfPage;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowLinkBendpoint createPFLinkBendpoint() {
- PageflowLinkBendpointImpl pfLinkBendpoint = new PageflowLinkBendpointImpl();
- return pfLinkBendpoint;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowPackage getPageflowPackage() {
- return (PageflowPackage) getEPackage();
- }
-}
-// PageflowFactoryImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowImpl.java
deleted file mode 100644
index f637ac262..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowImpl.java
+++ /dev/null
@@ -1,472 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.NotificationChain;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.common.util.TreeIterator;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList;
-import org.eclipse.emf.ecore.util.InternalEList;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>Pageflow</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowImpl#getNodes <em>Nodes</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowImpl#getLinks <em>Links</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowImpl#getConfigfile <em>Configfile</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public class PageflowImpl extends PageflowElementImpl implements Pageflow {
-
- /**
- * The cached value of the '{@link #getNodes() <em>Nodes</em>}'
- * containment reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getNodes()
- * @generated
- * @ordered
- */
- protected EList nodes = null;
-
- /**
- * The cached value of the '{@link #getLinks() <em>Links</em>}'
- * containment reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getLinks()
- * @generated
- * @ordered
- */
- protected EList links = null;
-
- /**
- * The default value of the '{@link #getConfigfile() <em>Configfile</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getConfigfile()
- * @generated
- * @ordered
- */
- protected static final String CONFIGFILE_EDEFAULT = null;
-
- /**
- * The cached value of the '{@link #getConfigfile() <em>Configfile</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getConfigfile()
- * @generated
- * @ordered
- */
- protected String configfile = CONFIGFILE_EDEFAULT;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPageflow();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EList getNodes() {
- if (nodes == null) {
- nodes = new EObjectContainmentWithInverseEList(PageflowNode.class,
- this, PageflowPackage.PAGEFLOW__NODES,
- PageflowPackage.PAGEFLOW_NODE__PAGEFLOW);
- }
- return nodes;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EList getLinks() {
- if (links == null) {
- links = new EObjectContainmentWithInverseEList(PageflowLink.class,
- this, PageflowPackage.PAGEFLOW__LINKS,
- PageflowPackage.PF_LINK__PAGEFLOW);
- }
- return links;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String getConfigfile() {
- return configfile;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setConfigfile(String newConfigfile) {
- String oldConfigfile = configfile;
- configfile = newConfigfile;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW__CONFIGFILE, oldConfigfile,
- configfile));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseAdd(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PAGEFLOW__NODES:
- return ((InternalEList) getNodes()).basicAdd(otherEnd, msgs);
- case PageflowPackage.PAGEFLOW__LINKS:
- return ((InternalEList) getLinks()).basicAdd(otherEnd, msgs);
- default:
- return eDynamicInverseAdd(otherEnd, featureID, baseClass, msgs);
- }
- }
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseRemove(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PAGEFLOW__NODES:
- return ((InternalEList) getNodes()).basicRemove(otherEnd, msgs);
- case PageflowPackage.PAGEFLOW__LINKS:
- return ((InternalEList) getLinks()).basicRemove(otherEnd, msgs);
- default:
- return eDynamicInverseRemove(otherEnd, featureID, baseClass,
- msgs);
- }
- }
- return eBasicSetContainer(null, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW__NAME:
- return getName();
- case PageflowPackage.PAGEFLOW__COMMENT:
- return getComment();
- case PageflowPackage.PAGEFLOW__X:
- return new Integer(getX());
- case PageflowPackage.PAGEFLOW__Y:
- return new Integer(getY());
- case PageflowPackage.PAGEFLOW__WIDTH:
- return new Integer(getWidth());
- case PageflowPackage.PAGEFLOW__HEIGHT:
- return new Integer(getHeight());
- case PageflowPackage.PAGEFLOW__ID:
- return getId();
- case PageflowPackage.PAGEFLOW__NODES:
- return getNodes();
- case PageflowPackage.PAGEFLOW__LINKS:
- return getLinks();
- case PageflowPackage.PAGEFLOW__CONFIGFILE:
- return getConfigfile();
- }
- return super.eGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW__NAME:
- setName((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW__COMMENT:
- setComment((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW__X:
- setX(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW__Y:
- setY(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW__WIDTH:
- setWidth(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW__HEIGHT:
- setHeight(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW__ID:
- setId((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW__NODES:
- getNodes().clear();
- getNodes().addAll((Collection) newValue);
- return;
- case PageflowPackage.PAGEFLOW__LINKS:
- getLinks().clear();
- getLinks().addAll((Collection) newValue);
- return;
- case PageflowPackage.PAGEFLOW__CONFIGFILE:
- setConfigfile((String) newValue);
- return;
- }
- super.eSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW__NAME:
- setName(NAME_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__COMMENT:
- setComment(COMMENT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__X:
- setX(X_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__Y:
- setY(Y_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__WIDTH:
- setWidth(WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__HEIGHT:
- setHeight(HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__ID:
- setId(ID_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW__NODES:
- getNodes().clear();
- return;
- case PageflowPackage.PAGEFLOW__LINKS:
- getLinks().clear();
- return;
- case PageflowPackage.PAGEFLOW__CONFIGFILE:
- setConfigfile(CONFIGFILE_EDEFAULT);
- return;
- }
- super.eUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT
- .equals(name);
- case PageflowPackage.PAGEFLOW__COMMENT:
- return COMMENT_EDEFAULT == null ? comment != null
- : !COMMENT_EDEFAULT.equals(comment);
- case PageflowPackage.PAGEFLOW__X:
- return x != X_EDEFAULT;
- case PageflowPackage.PAGEFLOW__Y:
- return y != Y_EDEFAULT;
- case PageflowPackage.PAGEFLOW__WIDTH:
- return width != WIDTH_EDEFAULT;
- case PageflowPackage.PAGEFLOW__HEIGHT:
- return height != HEIGHT_EDEFAULT;
- case PageflowPackage.PAGEFLOW__ID:
- return ID_EDEFAULT == null ? getId() != null : !ID_EDEFAULT
- .equals(getId());
- case PageflowPackage.PAGEFLOW__NODES:
- return nodes != null && !nodes.isEmpty();
- case PageflowPackage.PAGEFLOW__LINKS:
- return links != null && !links.isEmpty();
- case PageflowPackage.PAGEFLOW__CONFIGFILE:
- return CONFIGFILE_EDEFAULT == null ? configfile != null
- : !CONFIGFILE_EDEFAULT.equals(configfile);
- }
- return super.eIsSet(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String toString() {
- if (eIsProxy())
- return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (configfile: "); //$NON-NLS-1$
- result.append(configfile);
- result.append(')');
- return result.toString();
- }
-
- /**
- * set the valid link's source and target node.
- *
- * @generated NOT
- */
- public void connect(PageflowNode source, PageflowNode target,
- PageflowLink link) {
- if (link != null) {
- if (PageflowValidation.getInstance().isValidLinkForCreation(source,
- target)) {
- this.getLinks().add(link);
- link.setSource(source);
- link.setTarget(target);
- }
- }
- }
-
- /** node prefixs map */
- private HashMap mapNodePrefix = null;
-
- /**
- * get the prefix's map, and if the map is not existed, create it.
- *
- * @return - map for prefix
- *
- * @generated NOT
- */
- private HashMap getNodePrefixMap() {
- if (mapNodePrefix == null) {
- mapNodePrefix = new HashMap();
- mapNodePrefix.put(PageflowPageImpl.class, new String("Page")); //$NON-NLS-1$
- }
- return mapNodePrefix;
- }
-
- /**
- * get the default node name according current nodetype
- *
- * @param nodeType -
- * node type, such as PFBeginImpl, PFPageImpl, etc.
- * @return - the default node name.
- *
- * @generated NOT
- */
- public String getDefaultNodeName(Class nodeType) {
- HashMap mapNodePrefix_ = getNodePrefixMap();
-
- String strNodePrefix = (String) mapNodePrefix_.get(nodeType);
-
- String strNodeName = null;
- boolean bFound = true;
- int numNode = 1;
- while (bFound) {
- strNodeName = strNodePrefix + numNode;
- boolean bExisted = false;
- for (Iterator iter = getNodes().iterator(); iter.hasNext();) {
- PageflowNode node = (PageflowNode) iter.next();
- if (strNodeName.equalsIgnoreCase(node.getName())) {
- bExisted = true;
- break;
- }
- }
- if (!bExisted) {
- bFound = false;
- }
- numNode++;
- }
-
- return strNodeName;
-
- }
-
- /**
- * When faces-config has been changed, the pageflow model will be notified
- * to enable refresher do some update in pageflow.
- *
- * @generated NOT
- */
- public void notifyModelChanged(Notification notification) {
- TreeIterator children = eAllContents();
- while (children.hasNext()) {
- Object next = children.next();
- if (next instanceof PageflowElement) {
- ((PageflowElement) next).update();
- }
- }
- super.notifyModelChanged(notification);
- }
-
- /**
- * @generated NOT
- */
- public void dispose() {
- TreeIterator children = eAllContents();
- while (children.hasNext()) {
- Object next = children.next();
- if (next instanceof PageflowElement) {
- ((PageflowElement) next).dispose();
- }
- }
- eAdapters.clear();
- }
-}
-// PageflowImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkBendpointImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkBendpointImpl.java
deleted file mode 100644
index bdb66fcf8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkBendpointImpl.java
+++ /dev/null
@@ -1,552 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.NotificationChain;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.impl.EObjectImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.osgi.util.NLS;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>PF Link Bendpoint</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getD1Width <em>D1 Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getD1Height <em>D1 Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getD2Width <em>D2 Width</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getD2Height <em>D2 Height</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getWeight <em>Weight</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkBendpointImpl#getLink <em>Link</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public class PageflowLinkBendpointImpl extends EObjectImpl implements PageflowLinkBendpoint {
- /**
- * The default value of the '{@link #getD1Width() <em>D1 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD1Width()
- * @generated
- * @ordered
- */
- protected static final int D1_WIDTH_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getD1Width() <em>D1 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD1Width()
- * @generated
- * @ordered
- */
- protected int d1Width = D1_WIDTH_EDEFAULT;
-
- /**
- * The default value of the '{@link #getD1Height() <em>D1 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD1Height()
- * @generated
- * @ordered
- */
- protected static final int D1_HEIGHT_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getD1Height() <em>D1 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD1Height()
- * @generated
- * @ordered
- */
- protected int d1Height = D1_HEIGHT_EDEFAULT;
-
- /**
- * The default value of the '{@link #getD2Width() <em>D2 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD2Width()
- * @generated
- * @ordered
- */
- protected static final int D2_WIDTH_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getD2Width() <em>D2 Width</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD2Width()
- * @generated
- * @ordered
- */
- protected int d2Width = D2_WIDTH_EDEFAULT;
-
- /**
- * The default value of the '{@link #getD2Height() <em>D2 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD2Height()
- * @generated
- * @ordered
- */
- protected static final int D2_HEIGHT_EDEFAULT = 0;
-
- /**
- * The cached value of the '{@link #getD2Height() <em>D2 Height</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getD2Height()
- * @generated
- * @ordered
- */
- protected int d2Height = D2_HEIGHT_EDEFAULT;
-
- /**
- * The default value of the '{@link #getWeight() <em>Weight</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getWeight()
- * @generated
- * @ordered
- */
- protected static final float WEIGHT_EDEFAULT = 0.5F;
-
- /**
- * The cached value of the '{@link #getWeight() <em>Weight</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getWeight()
- * @generated
- * @ordered
- */
- protected float weight = WEIGHT_EDEFAULT;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- private Dimension dimStart, dimEnd;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowLinkBendpointImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPFLinkBendpoint();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getD1Width() {
- return d1Width;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setD1Width(int newD1Width) {
- int oldD1Width = d1Width;
- d1Width = newD1Width;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__D1_WIDTH, oldD1Width,
- d1Width));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getD1Height() {
- return d1Height;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setD1Height(int newD1Height) {
- int oldD1Height = d1Height;
- d1Height = newD1Height;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__D1_HEIGHT, oldD1Height,
- d1Height));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getD2Width() {
- return d2Width;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setD2Width(int newD2Width) {
- int oldD2Width = d2Width;
- d2Width = newD2Width;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__D2_WIDTH, oldD2Width,
- d2Width));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public int getD2Height() {
- return d2Height;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setD2Height(int newD2Height) {
- int oldD2Height = d2Height;
- d2Height = newD2Height;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__D2_HEIGHT, oldD2Height,
- d2Height));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public float getWeight() {
- return weight;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setWeight(float newWeight) {
- float oldWeight = weight;
- weight = newWeight;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__WEIGHT, oldWeight,
- weight));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowLink getLink() {
- if (eContainerFeatureID != PageflowPackage.PF_LINK_BENDPOINT__LINK)
- return null;
- return (PageflowLink) eContainer;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setLink(PageflowLink newLink) {
- if (newLink != eContainer
- || (eContainerFeatureID != PageflowPackage.PF_LINK_BENDPOINT__LINK && newLink != null)) {
- if (EcoreUtil.isAncestor(this, newLink))
- throw new IllegalArgumentException(
- NLS.bind(PageflowMessages.PageflowNode_NoRecursiveContainment,toString()));
- NotificationChain msgs = null;
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- if (newLink != null)
- msgs = ((InternalEObject) newLink).eInverseAdd(this,
- PageflowPackage.PF_LINK__BEND_POINTS, PageflowLink.class,
- msgs);
- msgs = eBasicSetContainer((InternalEObject) newLink,
- PageflowPackage.PF_LINK_BENDPOINT__LINK, msgs);
- if (msgs != null)
- msgs.dispatch();
- } else if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK_BENDPOINT__LINK, newLink, newLink));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseAdd(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd,
- PageflowPackage.PF_LINK_BENDPOINT__LINK, msgs);
- default:
- return eDynamicInverseAdd(otherEnd, featureID, baseClass, msgs);
- }
- }
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseRemove(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- return eBasicSetContainer(null,
- PageflowPackage.PF_LINK_BENDPOINT__LINK, msgs);
- default:
- return eDynamicInverseRemove(otherEnd, featureID, baseClass,
- msgs);
- }
- }
- return eBasicSetContainer(null, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eBasicRemoveFromContainer(NotificationChain msgs) {
- if (eContainerFeatureID >= 0) {
- switch (eContainerFeatureID) {
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- return eContainer.eInverseRemove(this,
- PageflowPackage.PF_LINK__BEND_POINTS, PageflowLink.class,
- msgs);
- default:
- return eDynamicBasicRemoveFromContainer(msgs);
- }
- }
- return eContainer.eInverseRemove(this,
- EOPPOSITE_FEATURE_BASE - eContainerFeatureID, null, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK_BENDPOINT__D1_WIDTH:
- return new Integer(getD1Width());
- case PageflowPackage.PF_LINK_BENDPOINT__D1_HEIGHT:
- return new Integer(getD1Height());
- case PageflowPackage.PF_LINK_BENDPOINT__D2_WIDTH:
- return new Integer(getD2Width());
- case PageflowPackage.PF_LINK_BENDPOINT__D2_HEIGHT:
- return new Integer(getD2Height());
- case PageflowPackage.PF_LINK_BENDPOINT__WEIGHT:
- return new Float(getWeight());
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- return getLink();
- }
- return eDynamicGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK_BENDPOINT__D1_WIDTH:
- setD1Width(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D1_HEIGHT:
- setD1Height(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_WIDTH:
- setD2Width(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_HEIGHT:
- setD2Height(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__WEIGHT:
- setWeight(((Float) newValue).floatValue());
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- setLink((PageflowLink) newValue);
- return;
- }
- eDynamicSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK_BENDPOINT__D1_WIDTH:
- setD1Width(D1_WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D1_HEIGHT:
- setD1Height(D1_HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_WIDTH:
- setD2Width(D2_WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_HEIGHT:
- setD2Height(D2_HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__WEIGHT:
- setWeight(WEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- setLink((PageflowLink) null);
- return;
- }
- eDynamicUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK_BENDPOINT__D1_WIDTH:
- return d1Width != D1_WIDTH_EDEFAULT;
- case PageflowPackage.PF_LINK_BENDPOINT__D1_HEIGHT:
- return d1Height != D1_HEIGHT_EDEFAULT;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_WIDTH:
- return d2Width != D2_WIDTH_EDEFAULT;
- case PageflowPackage.PF_LINK_BENDPOINT__D2_HEIGHT:
- return d2Height != D2_HEIGHT_EDEFAULT;
- case PageflowPackage.PF_LINK_BENDPOINT__WEIGHT:
- return weight != WEIGHT_EDEFAULT;
- case PageflowPackage.PF_LINK_BENDPOINT__LINK:
- return getLink() != null;
- }
- return eDynamicIsSet(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String toString() {
- if (eIsProxy())
- return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (d1Width: "); //$NON-NLS-1$
- result.append(d1Width);
- result.append(", d1Height: "); //$NON-NLS-1$
- result.append(d1Height);
- result.append(", d2Width: "); //$NON-NLS-1$
- result.append(d2Width);
- result.append(", d2Height: "); //$NON-NLS-1$
- result.append(d2Height);
- result.append(", weight: "); //$NON-NLS-1$
- result.append(weight);
- result.append(')');
- return result.toString();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public Dimension getFirstRelativeDimension() {
- dimStart = new Dimension(getD1Width(), getD1Height());
- return dimStart;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public Dimension getSecondRelativeDimension() {
- dimEnd = new Dimension(getD2Width(), getD2Height());
- return dimEnd;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setRelativeDimensions(Dimension dim1, Dimension dim2) {
- dimStart = dim1;
- dimEnd = dim2;
- setD1Width(dimStart.width);
- setD1Height(dimStart.height);
-
- setD2Width(dimEnd.width);
- setD2Height(dimEnd.height);
- }
-
-}
-// PFLinkBendpointImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkImpl.java
deleted file mode 100644
index 61d45f8cf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowLinkImpl.java
+++ /dev/null
@@ -1,893 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Collection;
-import java.util.Vector;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.NotificationChain;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.ecore.util.InternalEList;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.osgi.util.NLS;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>PF Link</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getPageflow <em>Pageflow</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getTarget <em>Target</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getSource <em>Source</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getOutcome <em>Outcome</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#isRedirect <em>Redirect</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getBendPoints <em>Bend Points</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getSmallicon <em>Smallicon</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowLinkImpl#getLargeicon <em>Largeicon</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- *
- */
-public class PageflowLinkImpl extends PageflowElementImpl implements
- PageflowLink {
- /**
- * The cached value of the '{@link #getTarget() <em>Target</em>}'
- * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getTarget()
- * @generated
- * @ordered
- */
- protected PageflowNode target = null;
-
- /**
- * The cached value of the '{@link #getSource() <em>Source</em>}'
- * reference. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getSource()
- * @generated
- * @ordered
- */
- protected PageflowNode source = null;
-
- /**
- * The default value of the '{@link #getOutcome() <em>Outcome</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getOutcome()
- * @generated
- * @ordered
- */
- protected static final String OUTCOME_EDEFAULT = null;
-
- /**
- * The default value of the '{@link #isRedirect() <em>Redirect</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #isRedirect()
- * @generated
- * @ordered
- */
- protected static final boolean REDIRECT_EDEFAULT = false;
-
- /**
- * The cached value of the '{@link #getBendPoints() <em>Bend Points</em>}'
- * containment reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getBendPoints()
- * @generated
- * @ordered
- */
- protected EList bendPoints = null;
-
- /**
- * The default value of the '{@link #getSmallicon() <em>Smallicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getSmallicon()
- * @generated
- * @ordered
- */
- protected static final String SMALLICON_EDEFAULT = null;
-
- /**
- * The default value of the '{@link #getLargeicon() <em>Largeicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getLargeicon()
- * @generated
- * @ordered
- */
- protected static final String LARGEICON_EDEFAULT = null;
-
- /**
- * The default value of the '{@link #getFromaction() <em>Fromaction</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getFromaction()
- * @generated
- * @ordered
- */
- protected static final String FROMACTION_EDEFAULT = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowLinkImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPFLink();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Pageflow getPageflow() {
- if (eContainerFeatureID != PageflowPackage.PF_LINK__PAGEFLOW)
- return null;
- return (Pageflow) eContainer;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setPageflow(Pageflow newPageflow) {
- if (newPageflow != eContainer
- || (eContainerFeatureID != PageflowPackage.PF_LINK__PAGEFLOW && newPageflow != null)) {
- if (EcoreUtil.isAncestor(this, newPageflow))
- throw new IllegalArgumentException(
- NLS.bind(PageflowMessages.PageflowNode_NoRecursiveContainment,toString()));
- NotificationChain msgs = null;
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- if (newPageflow != null)
- msgs = ((InternalEObject) newPageflow).eInverseAdd(this,
- PageflowPackage.PAGEFLOW__LINKS, Pageflow.class, msgs);
- msgs = eBasicSetContainer((InternalEObject) newPageflow,
- PageflowPackage.PF_LINK__PAGEFLOW, msgs);
- if (msgs != null)
- msgs.dispatch();
- } else if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__PAGEFLOW, newPageflow, newPageflow));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowNode getTarget() {
- if (target != null && target.eIsProxy()) {
- PageflowNode oldTarget = target;
- target = (PageflowNode) eResolveProxy((InternalEObject) target);
- if (target != oldTarget) {
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.RESOLVE,
- PageflowPackage.PF_LINK__TARGET, oldTarget, target));
- }
- }
- return target;
- }
-
- public void setSourcePath(String path) {
- if (getSource() != null
- && path.equals(((PageflowPage) getSource()).getPath())) {
- return;
- }
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__SOURCE, getSource(), path));
- }
-
- public void setTargetPath(String path) {
- if (getTarget() != null
- && path.equals(((PageflowPage) getTarget()).getPath())) {
- return;
- }
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__TARGET, getTarget(), path));
- }
-
- /**
- * <!-- begin-user-doc -->
- * @return the target
- * <!-- end-user-doc -->
- *
- *
- * @generated
- */
- public PageflowNode basicGetTarget() {
- return target;
- }
-
- /**
- * <!-- begin-user-doc -->
- * @param newTarget
- * @param msgs
- * @return the notification chain
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain basicSetTarget(PageflowNode newTarget,
- NotificationChain msgs) {
- PageflowNode oldTarget = target;
- target = newTarget;
- if (eNotificationRequired()) {
- ENotificationImpl notification = new ENotificationImpl(this,
- Notification.SET, PageflowPackage.PF_LINK__TARGET,
- oldTarget, newTarget);
- if (msgs == null)
- msgs = notification;
- else
- msgs.add(notification);
- }
- return msgs;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setTarget(PageflowNode newTarget) {
- if (newTarget != target) {
- NotificationChain msgs = null;
- if (target != null)
- msgs = ((InternalEObject) target).eInverseRemove(this,
- PageflowPackage.PAGEFLOW_NODE__INLINKS,
- PageflowNode.class, msgs);
- if (newTarget != null)
- msgs = ((InternalEObject) newTarget).eInverseAdd(this,
- PageflowPackage.PAGEFLOW_NODE__INLINKS,
- PageflowNode.class, msgs);
- msgs = basicSetTarget(newTarget, msgs);
- if (msgs != null)
- msgs.dispatch();
- } else if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__TARGET, newTarget, newTarget));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowNode getSource() {
- if (source != null && source.eIsProxy()) {
- PageflowNode oldSource = source;
- source = (PageflowNode) eResolveProxy((InternalEObject) source);
- if (source != oldSource) {
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.RESOLVE,
- PageflowPackage.PF_LINK__SOURCE, oldSource, source));
- }
- }
- return source;
- }
-
- /**
- * <!-- begin-user-doc -->
- * @return the pageflow node
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowNode basicGetSource() {
- return source;
- }
-
- /**
- * <!-- begin-user-doc -->
- * @param newSource
- * @param msgs
- * @return the notification chain
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain basicSetSource(PageflowNode newSource,
- NotificationChain msgs) {
- // Assert.isTrue(newSource != null);
- PageflowNode oldSource = source;
- source = newSource;
- if (eNotificationRequired()) {
- ENotificationImpl notification = new ENotificationImpl(this,
- Notification.SET, PageflowPackage.PF_LINK__SOURCE,
- oldSource, newSource);
- if (msgs == null)
- msgs = notification;
- else
- msgs.add(notification);
- }
- return msgs;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setSource(PageflowNode newSource) {
- // Assert.isTrue(newSource != null);
- if (newSource != source) {
- NotificationChain msgs = null;
- if (source != null)
- msgs = ((InternalEObject) source).eInverseRemove(this,
- PageflowPackage.PAGEFLOW_NODE__OUTLINKS,
- PageflowNode.class, msgs);
- if (newSource != null)
- msgs = ((InternalEObject) newSource).eInverseAdd(this,
- PageflowPackage.PAGEFLOW_NODE__OUTLINKS,
- PageflowNode.class, msgs);
- msgs = basicSetSource(newSource, msgs);
- if (msgs != null)
- msgs.dispatch();
- } else if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__SOURCE, newSource, newSource));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EList getBendPoints() {
- if (bendPoints == null) {
- bendPoints = new EObjectContainmentWithInverseEList(
- PageflowLinkBendpoint.class, this,
- PageflowPackage.PF_LINK__BEND_POINTS,
- PageflowPackage.PF_LINK_BENDPOINT__LINK);
- }
- return bendPoints;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseAdd(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_LINK__PAGEFLOW:
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd,
- PageflowPackage.PF_LINK__PAGEFLOW, msgs);
- case PageflowPackage.PF_LINK__TARGET:
- if (target != null)
- msgs = ((InternalEObject) target).eInverseRemove(this,
- PageflowPackage.PAGEFLOW_NODE__INLINKS,
- PageflowNode.class, msgs);
- return basicSetTarget((PageflowNode) otherEnd, msgs);
- case PageflowPackage.PF_LINK__SOURCE:
- if (source != null)
- msgs = ((InternalEObject) source).eInverseRemove(this,
- PageflowPackage.PAGEFLOW_NODE__OUTLINKS,
- PageflowNode.class, msgs);
- return basicSetSource((PageflowNode) otherEnd, msgs);
- case PageflowPackage.PF_LINK__BEND_POINTS:
- return ((InternalEList) getBendPoints()).basicAdd(otherEnd,
- msgs);
- default:
- return eDynamicInverseAdd(otherEnd, featureID, baseClass, msgs);
- }
- }
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseRemove(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_LINK__PAGEFLOW:
- return eBasicSetContainer(null,
- PageflowPackage.PF_LINK__PAGEFLOW, msgs);
- case PageflowPackage.PF_LINK__TARGET:
- return basicSetTarget(null, msgs);
- case PageflowPackage.PF_LINK__SOURCE:
- return basicSetSource(null, msgs);
- case PageflowPackage.PF_LINK__BEND_POINTS:
- return ((InternalEList) getBendPoints()).basicRemove(otherEnd,
- msgs);
- default:
- return eDynamicInverseRemove(otherEnd, featureID, baseClass,
- msgs);
- }
- }
- return eBasicSetContainer(null, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eBasicRemoveFromContainer(NotificationChain msgs) {
- if (eContainerFeatureID >= 0) {
- switch (eContainerFeatureID) {
- case PageflowPackage.PF_LINK__PAGEFLOW:
- return eContainer.eInverseRemove(this,
- PageflowPackage.PAGEFLOW__LINKS, Pageflow.class, msgs);
- default:
- return eDynamicBasicRemoveFromContainer(msgs);
- }
- }
- return eContainer.eInverseRemove(this,
- EOPPOSITE_FEATURE_BASE - eContainerFeatureID, null, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK__NAME:
- return getName();
- case PageflowPackage.PF_LINK__COMMENT:
- return getComment();
- case PageflowPackage.PF_LINK__X:
- return new Integer(getX());
- case PageflowPackage.PF_LINK__Y:
- return new Integer(getY());
- case PageflowPackage.PF_LINK__WIDTH:
- return new Integer(getWidth());
- case PageflowPackage.PF_LINK__HEIGHT:
- return new Integer(getHeight());
- case PageflowPackage.PF_LINK__ID:
- return getId();
- case PageflowPackage.PF_LINK__PAGEFLOW:
- return getPageflow();
- case PageflowPackage.PF_LINK__TARGET:
- if (resolve)
- return getTarget();
- return basicGetTarget();
- case PageflowPackage.PF_LINK__SOURCE:
- if (resolve)
- return getSource();
- return basicGetSource();
- case PageflowPackage.PF_LINK__OUTCOME:
- return getOutcome();
- case PageflowPackage.PF_LINK__REDIRECT:
- return isRedirect() ? Boolean.TRUE : Boolean.FALSE;
- case PageflowPackage.PF_LINK__BEND_POINTS:
- return getBendPoints();
- case PageflowPackage.PF_LINK__SMALLICON:
- return getSmallicon();
- case PageflowPackage.PF_LINK__LARGEICON:
- return getLargeicon();
- case PageflowPackage.PF_LINK__FROMACTION:
- return getFromaction();
- }
- return super.eGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK__NAME:
- setName((String) newValue);
- return;
- case PageflowPackage.PF_LINK__COMMENT:
- setComment((String) newValue);
- return;
- case PageflowPackage.PF_LINK__X:
- setX(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK__Y:
- setY(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK__WIDTH:
- setWidth(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK__HEIGHT:
- setHeight(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_LINK__ID:
- setId((String) newValue);
- return;
- case PageflowPackage.PF_LINK__PAGEFLOW:
- setPageflow((Pageflow) newValue);
- return;
- case PageflowPackage.PF_LINK__TARGET:
- setTarget((PageflowNode) newValue);
- return;
- case PageflowPackage.PF_LINK__SOURCE:
- setSource((PageflowNode) newValue);
- return;
- case PageflowPackage.PF_LINK__OUTCOME:
- setOutcome((String) newValue);
- return;
- case PageflowPackage.PF_LINK__REDIRECT:
- setRedirect(((Boolean) newValue).booleanValue());
- return;
- case PageflowPackage.PF_LINK__BEND_POINTS:
- getBendPoints().clear();
- getBendPoints().addAll((Collection) newValue);
- return;
- case PageflowPackage.PF_LINK__SMALLICON:
- setSmallicon((String) newValue);
- return;
- case PageflowPackage.PF_LINK__LARGEICON:
- setLargeicon((String) newValue);
- return;
- case PageflowPackage.PF_LINK__FROMACTION:
- setFromaction((String) newValue);
- return;
- }
- super.eSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK__NAME:
- setName(NAME_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__COMMENT:
- setComment(COMMENT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__X:
- setX(X_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__Y:
- setY(Y_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__WIDTH:
- setWidth(WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__HEIGHT:
- setHeight(HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__ID:
- setId(ID_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__PAGEFLOW:
- setPageflow((Pageflow) null);
- return;
- case PageflowPackage.PF_LINK__TARGET:
- setTarget((PageflowNode) null);
- return;
- case PageflowPackage.PF_LINK__SOURCE:
- setSource((PageflowNode) null);
- return;
- case PageflowPackage.PF_LINK__OUTCOME:
- setOutcome(OUTCOME_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__REDIRECT:
- setRedirect(REDIRECT_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__BEND_POINTS:
- getBendPoints().clear();
- return;
- case PageflowPackage.PF_LINK__SMALLICON:
- setSmallicon(SMALLICON_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__LARGEICON:
- setLargeicon(LARGEICON_EDEFAULT);
- return;
- case PageflowPackage.PF_LINK__FROMACTION:
- setFromaction(FROMACTION_EDEFAULT);
- return;
- }
- super.eUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_LINK__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT
- .equals(name);
- case PageflowPackage.PF_LINK__COMMENT:
- return COMMENT_EDEFAULT == null ? comment != null
- : !COMMENT_EDEFAULT.equals(comment);
- case PageflowPackage.PF_LINK__X:
- return x != X_EDEFAULT;
- case PageflowPackage.PF_LINK__Y:
- return y != Y_EDEFAULT;
- case PageflowPackage.PF_LINK__WIDTH:
- return width != WIDTH_EDEFAULT;
- case PageflowPackage.PF_LINK__HEIGHT:
- return height != HEIGHT_EDEFAULT;
- case PageflowPackage.PF_LINK__ID:
- return ID_EDEFAULT == null ? getId() != null : !ID_EDEFAULT
- .equals(getId());
- case PageflowPackage.PF_LINK__PAGEFLOW:
- return getPageflow() != null;
- case PageflowPackage.PF_LINK__TARGET:
- return target != null;
- case PageflowPackage.PF_LINK__SOURCE:
- return source != null;
- case PageflowPackage.PF_LINK__OUTCOME:
- return OUTCOME_EDEFAULT == null ? getOutcome() != null
- : !OUTCOME_EDEFAULT.equals(getOutcome());
- case PageflowPackage.PF_LINK__REDIRECT:
- return isRedirect() != REDIRECT_EDEFAULT;
- case PageflowPackage.PF_LINK__BEND_POINTS:
- return bendPoints != null && !bendPoints.isEmpty();
- case PageflowPackage.PF_LINK__SMALLICON:
- return SMALLICON_EDEFAULT == null ? getSmallicon() != null
- : !SMALLICON_EDEFAULT.equals(getSmallicon());
- case PageflowPackage.PF_LINK__LARGEICON:
- return LARGEICON_EDEFAULT == null ? getLargeicon() != null
- : !LARGEICON_EDEFAULT.equals(getLargeicon());
- case PageflowPackage.PF_LINK__FROMACTION:
- return FROMACTION_EDEFAULT == null ? getFromaction() != null
- : !FROMACTION_EDEFAULT.equals(getFromaction());
- }
- return super.eIsSet(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String toString() {
- if (eIsProxy())
- return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (smallicon: "); //$NON-NLS-1$
- result.append(getSmallicon());
- result.append(", largeicon: "); //$NON-NLS-1$
- result.append(getLargeicon());
- result.append(", fromaction: "); //$NON-NLS-1$
- result.append(getFromaction());
- result.append(", outcome: "); //$NON-NLS-1$
- result.append(getOutcome());
- result.append(", redirect: "); //$NON-NLS-1$
- result.append(isRedirect());
- result.append(')');
- return result.toString();
- }
-
- /**
- * <!-- begin-user-doc --> insert a new bendpoint to the link <!--
- * end-user-doc -->
- *
- * @generated NOT
- */
- public void insertBendpoint(int index, PageflowLinkBendpoint point) {
- getBendPoints().add(index, point);
-
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.ADD,
- PageflowPackage.PF_LINK__BEND_POINTS, null, point));
- }
-
- /**
- * <!-- begin-user-doc --> remove the current bendpoint <!-- end-user-doc
- * -->
- *
- * @generated NOT
- */
- public void removeBendpoint(int index) {
- getBendPoints().remove(index);
- }
-
- /**
- * <!-- begin-user-doc --> Set the current bendpoint <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setBendpoint(int index, PageflowLinkBendpoint point) {
- getBendPoints().set(index, point);
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__BEND_POINTS, null, point));
-
- }
-
- /**
- * <!-- begin-user-doc --> Set a group of bendpoints to reconstruct the link
- * <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setBendpoints(Vector points) {
- bendPoints = (EList) points;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.ADD_MANY,
- PageflowPackage.PF_LINK__BEND_POINTS, null, points));
-
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public boolean isRedirect() {
- Boolean result = (Boolean) getFCElements().get(
- PageflowPackage.PF_LINK__REDIRECT);
- return result.booleanValue();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setRedirect(boolean newRedirect) {
- Boolean oldRedirect = new Boolean(isRedirect());
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__REDIRECT, oldRedirect,
- new Boolean(newRedirect)));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getOutcome() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_LINK__OUTCOME);
-
- return result;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setOutcome(String newValue) {
- String oldOutcome = getOutcome();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__OUTCOME, oldOutcome, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getSmallicon() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_LINK__SMALLICON);
- return result;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setSmallicon(String newValue) {
- String oldSmallicon = getSmallicon();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__SMALLICON, oldSmallicon, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getLargeicon() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_LINK__LARGEICON);
-
- return result;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setLargeicon(String newValue) {
- String oldLargeIcon = getLargeicon();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__LARGEICON, oldLargeIcon, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getFromaction() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_LINK__FROMACTION);
- return result;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setFromaction(String newFromaction) {
- String oldFromActionType = getFromaction();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_LINK__FROMACTION, oldFromActionType,
- newFromaction));
- }
-
- /**
- * @generated NOT
- */
- public ReferenceElement getFCElements() {
-
- if (refElement == null) {
- refElement = new LinkReferenceElement(this);
- }
- return refElement;
- }
-
-}
-// PFLinkImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowNodeImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowNodeImpl.java
deleted file mode 100644
index 6e64d61e5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowNodeImpl.java
+++ /dev/null
@@ -1,390 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Collection;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.NotificationChain;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.ecore.util.InternalEList;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.osgi.util.NLS;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>Node</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowNodeImpl#getPageflow <em>Pageflow</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowNodeImpl#getOutlinks <em>Outlinks</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowNodeImpl#getInlinks <em>Inlinks</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public abstract class PageflowNodeImpl extends PageflowElementImpl implements
- PageflowNode {
- /**
- * The cached value of the '{@link #getOutlinks() <em>Outlinks</em>}'
- * reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getOutlinks()
- * @generated
- * @ordered
- */
- protected EList outlinks = null;
-
- /**
- * The cached value of the '{@link #getInlinks() <em>Inlinks</em>}'
- * reference list. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getInlinks()
- * @generated
- * @ordered
- */
- protected EList inlinks = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowNodeImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPageflowNode();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Pageflow getPageflow() {
- if (eContainerFeatureID != PageflowPackage.PAGEFLOW_NODE__PAGEFLOW)
- return null;
- return (Pageflow) eContainer;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void setPageflow(Pageflow newPageflow) {
- if (newPageflow != eContainer
- || (eContainerFeatureID != PageflowPackage.PAGEFLOW_NODE__PAGEFLOW && newPageflow != null)) {
- if (EcoreUtil.isAncestor(this, newPageflow))
- throw new IllegalArgumentException(
- NLS.bind(PageflowMessages.PageflowNode_NoRecursiveContainment,toString()));
- NotificationChain msgs = null;
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- if (newPageflow != null)
- msgs = ((InternalEObject) newPageflow).eInverseAdd(this,
- PageflowPackage.PAGEFLOW__NODES, Pageflow.class, msgs);
- msgs = eBasicSetContainer((InternalEObject) newPageflow,
- PageflowPackage.PAGEFLOW_NODE__PAGEFLOW, msgs);
- if (msgs != null)
- msgs.dispatch();
- } else if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_NODE__PAGEFLOW, newPageflow,
- newPageflow));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EList getOutlinks() {
- if (outlinks == null) {
- outlinks = new EObjectWithInverseResolvingEList(PageflowLink.class, this,
- PageflowPackage.PAGEFLOW_NODE__OUTLINKS,
- PageflowPackage.PF_LINK__SOURCE);
- }
- return outlinks;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EList getInlinks() {
- if (inlinks == null) {
- inlinks = new EObjectWithInverseResolvingEList(PageflowLink.class, this,
- PageflowPackage.PAGEFLOW_NODE__INLINKS,
- PageflowPackage.PF_LINK__TARGET);
- }
- return inlinks;
- }
-
- /**
- * @generated NOT
- */
- public PageflowLink findLinkTo(PageflowNode target) {
- //
- java.util.Iterator i = this.getOutlinks().iterator();
- while (i.hasNext()) {
- PageflowLink link = (PageflowLink) i.next();
- if (link.getTarget() == target)
- return link;
- }
- return null;
-
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseAdd(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd,
- PageflowPackage.PAGEFLOW_NODE__PAGEFLOW, msgs);
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- return ((InternalEList) getOutlinks()).basicAdd(otherEnd, msgs);
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- return ((InternalEList) getInlinks()).basicAdd(otherEnd, msgs);
- default:
- return eDynamicInverseAdd(otherEnd, featureID, baseClass, msgs);
- }
- }
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseRemove(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- return eBasicSetContainer(null,
- PageflowPackage.PAGEFLOW_NODE__PAGEFLOW, msgs);
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- return ((InternalEList) getOutlinks()).basicRemove(otherEnd,
- msgs);
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- return ((InternalEList) getInlinks()).basicRemove(otherEnd,
- msgs);
- default:
- return eDynamicInverseRemove(otherEnd, featureID, baseClass,
- msgs);
- }
- }
- return eBasicSetContainer(null, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eBasicRemoveFromContainer(NotificationChain msgs) {
- if (eContainerFeatureID >= 0) {
- switch (eContainerFeatureID) {
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- return eContainer.eInverseRemove(this,
- PageflowPackage.PAGEFLOW__NODES, Pageflow.class, msgs);
- default:
- return eDynamicBasicRemoveFromContainer(msgs);
- }
- }
- return eContainer.eInverseRemove(this,
- EOPPOSITE_FEATURE_BASE - eContainerFeatureID, null, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_NODE__NAME:
- return getName();
- case PageflowPackage.PAGEFLOW_NODE__COMMENT:
- return getComment();
- case PageflowPackage.PAGEFLOW_NODE__X:
- return new Integer(getX());
- case PageflowPackage.PAGEFLOW_NODE__Y:
- return new Integer(getY());
- case PageflowPackage.PAGEFLOW_NODE__WIDTH:
- return new Integer(getWidth());
- case PageflowPackage.PAGEFLOW_NODE__HEIGHT:
- return new Integer(getHeight());
- case PageflowPackage.PAGEFLOW_NODE__ID:
- return getId();
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- return getPageflow();
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- return getOutlinks();
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- return getInlinks();
- }
- return super.eGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_NODE__NAME:
- setName((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_NODE__COMMENT:
- setComment((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_NODE__X:
- setX(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_NODE__Y:
- setY(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_NODE__WIDTH:
- setWidth(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_NODE__HEIGHT:
- setHeight(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PAGEFLOW_NODE__ID:
- setId((String) newValue);
- return;
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- setPageflow((Pageflow) newValue);
- return;
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- getOutlinks().clear();
- getOutlinks().addAll((Collection) newValue);
- return;
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- getInlinks().clear();
- getInlinks().addAll((Collection) newValue);
- return;
- }
- super.eSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_NODE__NAME:
- setName(NAME_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__COMMENT:
- setComment(COMMENT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__X:
- setX(X_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__Y:
- setY(Y_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__WIDTH:
- setWidth(WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__HEIGHT:
- setHeight(HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__ID:
- setId(ID_EDEFAULT);
- return;
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- setPageflow((Pageflow) null);
- return;
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- getOutlinks().clear();
- return;
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- getInlinks().clear();
- return;
- }
- super.eUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PAGEFLOW_NODE__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT
- .equals(name);
- case PageflowPackage.PAGEFLOW_NODE__COMMENT:
- return COMMENT_EDEFAULT == null ? comment != null
- : !COMMENT_EDEFAULT.equals(comment);
- case PageflowPackage.PAGEFLOW_NODE__X:
- return x != X_EDEFAULT;
- case PageflowPackage.PAGEFLOW_NODE__Y:
- return y != Y_EDEFAULT;
- case PageflowPackage.PAGEFLOW_NODE__WIDTH:
- return width != WIDTH_EDEFAULT;
- case PageflowPackage.PAGEFLOW_NODE__HEIGHT:
- return height != HEIGHT_EDEFAULT;
- case PageflowPackage.PAGEFLOW_NODE__ID:
- return ID_EDEFAULT == null ? getId() != null : !ID_EDEFAULT
- .equals(getId());
- case PageflowPackage.PAGEFLOW_NODE__PAGEFLOW:
- return getPageflow() != null;
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- return outlinks != null && !outlinks.isEmpty();
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- return inlinks != null && !inlinks.isEmpty();
- }
- return super.eIsSet(eFeature);
- }
-
-}
-// PageflowNodeImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPackageImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPackageImpl.java
deleted file mode 100644
index f24f95bc8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPackageImpl.java
+++ /dev/null
@@ -1,782 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EPackage;
-import org.eclipse.emf.ecore.EReference;
-import org.eclipse.emf.ecore.impl.EPackageImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model <b>Package</b>. <!--
- * end-user-doc -->
- *
- * @generated
- */
-public class PageflowPackageImpl extends EPackageImpl implements
- PageflowPackage {
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pageflowEClass = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pageflowNodeEClass = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pfLinkEClass = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pageflowElementEClass = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pfPageEClass = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private EClass pfLinkBendpointEClass = null;
-
- /**
- * Creates an instance of the model <b>Package</b>, registered with
- * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the
- * package package URI value.
- * <p>
- * Note: the correct way to create the package is via the static factory
- * method {@link #init init()}, which also performs initialization of the
- * package, or returns the registered package, if one already exists. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @see org.eclipse.emf.ecore.EPackage.Registry
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage#eNS_URI
- * @see #init()
- * @generated
- */
- private PageflowPackageImpl() {
- super(eNS_URI, PageflowFactory.eINSTANCE);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private static boolean isInited = false;
-
- /**
- * Creates, registers, and initializes the <b>Package</b> for this model,
- * and for any others upon which it depends. Simple dependencies are
- * satisfied by calling this method on all dependent packages before doing
- * anything else. This method drives initialization for interdependent
- * packages directly, in parallel with this package, itself.
- * <p>
- * Of this package and its interdependencies, all packages which have not
- * yet been registered by their URI values are first created and registered.
- * The packages are then initialized in two steps: meta-model objects for
- * all of the packages are created before any are initialized, since one
- * package's meta-model objects may refer to those of another.
- * <p>
- * Invocation of this method will not affect any packages that have already
- * been initialized.
- *
- * <!-- begin-user-doc -->
- * @return the package
- * <!-- end-user-doc -->
- *
- * @see #eNS_URI
- * @see #createPackageContents()
- * @see #initializePackageContents()
- * @generated
- */
- public static PageflowPackage init() {
- if (isInited)
- return (PageflowPackage) EPackage.Registry.INSTANCE
- .get(PageflowPackage.eNS_URI);
-
- // Obtain or create and register package
- PageflowPackageImpl thePageflowPackage = (PageflowPackageImpl) (EPackage.Registry.INSTANCE
- .get(eNS_URI) instanceof PageflowPackageImpl ? EPackage.Registry.INSTANCE
- .get(eNS_URI)
- : new PageflowPackageImpl());
-
- isInited = true;
-
- // Create package meta-data objects
- thePageflowPackage.createPackageContents();
-
- // Initialize created meta-data
- thePageflowPackage.initializePackageContents();
-
- return thePageflowPackage;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPageflow() {
- return pageflowEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPageflow_Nodes() {
- return (EReference) pageflowEClass.getEStructuralFeatures().get(0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPageflow_Links() {
- return (EReference) pageflowEClass.getEStructuralFeatures().get(1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflow_Configfile() {
- return (EAttribute) pageflowEClass.getEStructuralFeatures().get(2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPageflowNode() {
- return pageflowNodeEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPageflowNode_Pageflow() {
- return (EReference) pageflowNodeEClass.getEStructuralFeatures().get(0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPageflowNode_Outlinks() {
- return (EReference) pageflowNodeEClass.getEStructuralFeatures().get(1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPageflowNode_Inlinks() {
- return (EReference) pageflowNodeEClass.getEStructuralFeatures().get(2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPFLink() {
- return pfLinkEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPFLink_Pageflow() {
- return (EReference) pfLinkEClass.getEStructuralFeatures().get(0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPFLink_Target() {
- return (EReference) pfLinkEClass.getEStructuralFeatures().get(1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPFLink_Source() {
- return (EReference) pfLinkEClass.getEStructuralFeatures().get(2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLink_Outcome() {
- return (EAttribute) pfLinkEClass.getEStructuralFeatures().get(3);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLink_Redirect() {
- return (EAttribute) pfLinkEClass.getEStructuralFeatures().get(4);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPFLink_BendPoints() {
- return (EReference) pfLinkEClass.getEStructuralFeatures().get(5);
- }
-
- /**
- * <!-- begin-user-doc -->
- * @return the small icon eattribute
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLink_Smallicon() {
- return (EAttribute) pfLinkEClass.getEStructuralFeatures().get(6);
- }
-
- /**
- * <!-- begin-user-doc -->
- * @return the large icon attribute
- * <!-- end-user-doc -->
- * @generated
- */
- public EAttribute getPFLink_Largeicon() {
- return (EAttribute) pfLinkEClass.getEStructuralFeatures().get(7);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLink_Fromaction() {
- return (EAttribute) pfLinkEClass.getEStructuralFeatures().get(8);
- }
-
- /**
- * <!-- begin-user-doc -->
- * @return the reference link eattribute
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_ReferenceLink() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 7);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPageflowElement() {
- return pageflowElementEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Name() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Comment() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_X() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Y() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 3);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Width() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 4);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Height() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 5);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPageflowElement_Id() {
- return (EAttribute) pageflowElementEClass.getEStructuralFeatures().get(
- 6);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPFPage() {
- return pfPageEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFPage_Path() {
- return (EAttribute) pfPageEClass.getEStructuralFeatures().get(0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFPage_Smallicon() {
- return (EAttribute) pfPageEClass.getEStructuralFeatures().get(1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFPage_Largeicon() {
- return (EAttribute) pfPageEClass.getEStructuralFeatures().get(2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EClass getPFLinkBendpoint() {
- return pfLinkBendpointEClass;
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLinkBendpoint_D1Width() {
- return (EAttribute) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 0);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLinkBendpoint_D1Height() {
- return (EAttribute) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 1);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLinkBendpoint_D2Width() {
- return (EAttribute) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 2);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLinkBendpoint_D2Height() {
- return (EAttribute) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 3);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EAttribute getPFLinkBendpoint_Weight() {
- return (EAttribute) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 4);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public EReference getPFLinkBendpoint_Link() {
- return (EReference) pfLinkBendpointEClass.getEStructuralFeatures().get(
- 5);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public PageflowFactory getPageflowFactory() {
- return (PageflowFactory) getEFactoryInstance();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private boolean isCreated = false;
-
- /**
- * Creates the meta-model objects for the package. This method is guarded to
- * have no affect on any invocation but its first. <!-- begin-user-doc -->
- * <!-- end-user-doc -->
- *
- * @generated
- */
- public void createPackageContents() {
- if (isCreated)
- return;
- isCreated = true;
-
- // Create classes and their features
- pageflowEClass = createEClass(PAGEFLOW);
- createEReference(pageflowEClass, PAGEFLOW__NODES);
- createEReference(pageflowEClass, PAGEFLOW__LINKS);
- createEAttribute(pageflowEClass, PAGEFLOW__CONFIGFILE);
-
- pageflowNodeEClass = createEClass(PAGEFLOW_NODE);
- createEReference(pageflowNodeEClass, PAGEFLOW_NODE__PAGEFLOW);
- createEReference(pageflowNodeEClass, PAGEFLOW_NODE__OUTLINKS);
- createEReference(pageflowNodeEClass, PAGEFLOW_NODE__INLINKS);
-
- pfLinkEClass = createEClass(PF_LINK);
- createEReference(pfLinkEClass, PF_LINK__PAGEFLOW);
- createEReference(pfLinkEClass, PF_LINK__TARGET);
- createEReference(pfLinkEClass, PF_LINK__SOURCE);
- createEAttribute(pfLinkEClass, PF_LINK__OUTCOME);
- createEAttribute(pfLinkEClass, PF_LINK__REDIRECT);
- createEReference(pfLinkEClass, PF_LINK__BEND_POINTS);
- createEAttribute(pfLinkEClass, PF_LINK__SMALLICON);
- createEAttribute(pfLinkEClass, PF_LINK__LARGEICON);
- createEAttribute(pfLinkEClass, PF_LINK__FROMACTION);
-
- pageflowElementEClass = createEClass(PAGEFLOW_ELEMENT);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__NAME);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__COMMENT);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__X);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__Y);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__WIDTH);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__HEIGHT);
- createEAttribute(pageflowElementEClass, PAGEFLOW_ELEMENT__ID);
- createEAttribute(pageflowElementEClass,
- PAGEFLOW_ELEMENT__REFERENCE_LINK);
-
- pfPageEClass = createEClass(PF_PAGE);
- createEAttribute(pfPageEClass, PF_PAGE__PATH);
- createEAttribute(pfPageEClass, PF_PAGE__SMALLICON);
- createEAttribute(pfPageEClass, PF_PAGE__LARGEICON);
-
- pfLinkBendpointEClass = createEClass(PF_LINK_BENDPOINT);
- createEAttribute(pfLinkBendpointEClass, PF_LINK_BENDPOINT__D1_WIDTH);
- createEAttribute(pfLinkBendpointEClass, PF_LINK_BENDPOINT__D1_HEIGHT);
- createEAttribute(pfLinkBendpointEClass, PF_LINK_BENDPOINT__D2_WIDTH);
- createEAttribute(pfLinkBendpointEClass, PF_LINK_BENDPOINT__D2_HEIGHT);
- createEAttribute(pfLinkBendpointEClass, PF_LINK_BENDPOINT__WEIGHT);
- createEReference(pfLinkBendpointEClass, PF_LINK_BENDPOINT__LINK);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- private boolean isInitialized = false;
-
- /**
- * Complete the initialization of the package and its meta-model. This
- * method is guarded to have no affect on any invocation but its first. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void initializePackageContents() {
- if (isInitialized)
- return;
- isInitialized = true;
-
- // Initialize package
- setName(eNAME);
- setNsPrefix(eNS_PREFIX);
- setNsURI(eNS_URI);
-
- // Add supertypes to classes
- pageflowEClass.getESuperTypes().add(this.getPageflowElement());
- pageflowNodeEClass.getESuperTypes().add(this.getPageflowElement());
- pfLinkEClass.getESuperTypes().add(this.getPageflowElement());
- pfPageEClass.getESuperTypes().add(this.getPageflowNode());
-
- // Initialize classes and features; add operations and parameters
- initEClass(pageflowEClass, Pageflow.class, "Pageflow", !IS_ABSTRACT, //$NON-NLS-1$
- !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getPageflow_Nodes(), this.getPageflowNode(), this
- .getPageflowNode_Pageflow(), "nodes", null, 0, -1, //$NON-NLS-1$
- Pageflow.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPageflow_Links(), this.getPFLink(), this
- .getPFLink_Pageflow(), "links", null, 0, -1, Pageflow.class, //$NON-NLS-1$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE,
- !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
- initEAttribute(getPageflow_Configfile(), ecorePackage.getEString(),
- "configfile", null, 0, 1, Pageflow.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
-
- initEClass(pageflowNodeEClass, PageflowNode.class, "PageflowNode", //$NON-NLS-1$
- IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getPageflowNode_Pageflow(), this.getPageflow(), this
- .getPageflow_Nodes(), "pageflow", null, 1, 1, //$NON-NLS-1$
- PageflowNode.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPageflowNode_Outlinks(), this.getPFLink(), this
- .getPFLink_Source(), "outlinks", null, 0, -1, //$NON-NLS-1$
- PageflowNode.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPageflowNode_Inlinks(), this.getPFLink(), this
- .getPFLink_Target(), "inlinks", null, 0, -1, //$NON-NLS-1$
- PageflowNode.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
-
- initEClass(pfLinkEClass, PageflowLink.class, "PFLink", !IS_ABSTRACT, //$NON-NLS-1$
- !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getPFLink_Pageflow(), this.getPageflow(), this
- .getPageflow_Links(), "pageflow", null, 1, 1, //$NON-NLS-1$
- PageflowLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPFLink_Target(), this.getPageflowNode(), this
- .getPageflowNode_Inlinks(), "target", null, 1, 1, //$NON-NLS-1$
- PageflowLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPFLink_Source(), this.getPageflowNode(), this
- .getPageflowNode_Outlinks(), "source", null, 1, 1, //$NON-NLS-1$
- PageflowLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLink_Outcome(), ecorePackage.getEString(),
- "outcome", null, 0, 1, PageflowLink.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLink_Redirect(), ecorePackage.getEBoolean(),
- "redirect", null, 0, 1, PageflowLink.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEReference(getPFLink_BendPoints(), this.getPFLinkBendpoint(), this
- .getPFLinkBendpoint_Link(), "bendPoints", null, 0, -1, //$NON-NLS-1$
- PageflowLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
- IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLink_Smallicon(), ecorePackage.getEString(),
- "smallicon", null, 0, 1, PageflowLink.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLink_Largeicon(), ecorePackage.getEString(),
- "largeicon", null, 0, 1, PageflowLink.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLink_Fromaction(), ecorePackage.getEString(),
- "fromaction", null, 0, 1, PageflowLink.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
-
- initEClass(pageflowElementEClass, PageflowElement.class,
- "PageflowElement", IS_ABSTRACT, !IS_INTERFACE, //$NON-NLS-1$
- IS_GENERATED_INSTANCE_CLASS);
- initEAttribute(getPageflowElement_Name(), ecorePackage.getEString(),
- "name", "unnamed", 0, 1, PageflowElement.class, !IS_TRANSIENT, //$NON-NLS-1$ //$NON-NLS-2$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPageflowElement_Comment(), ecorePackage.getEString(),
- "comment", null, 0, 1, PageflowElement.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPageflowElement_X(), ecorePackage.getEInt(), "x", //$NON-NLS-1$
- "0", 0, 1, PageflowElement.class, !IS_TRANSIENT, !IS_VOLATILE, //$NON-NLS-1$
- IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
- initEAttribute(getPageflowElement_Y(), ecorePackage.getEInt(), "y", //$NON-NLS-1$
- "0", 0, 1, PageflowElement.class, !IS_TRANSIENT, !IS_VOLATILE, //$NON-NLS-1$
- IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
- initEAttribute(getPageflowElement_Width(), ecorePackage.getEInt(),
- "width", "-1", 0, 1, PageflowElement.class, !IS_TRANSIENT, //$NON-NLS-1$ //$NON-NLS-2$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPageflowElement_Height(), ecorePackage.getEInt(),
- "height", "-1", 0, 1, PageflowElement.class, !IS_TRANSIENT, //$NON-NLS-1$ //$NON-NLS-2$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPageflowElement_Id(), ecorePackage.getEString(),
- "id", null, 1, 1, PageflowElement.class, !IS_TRANSIENT, //$NON-NLS-1$
- IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPageflowElement_ReferenceLink(), ecorePackage
- .getEString(), "referenceLink", "", 0, 1, //$NON-NLS-1$ //$NON-NLS-2$
- PageflowElement.class, !IS_TRANSIENT, !IS_VOLATILE,
- IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
-
- initEClass(pfPageEClass, PageflowPage.class, "PFPage", !IS_ABSTRACT, //$NON-NLS-1$
- !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEAttribute(getPFPage_Path(), ecorePackage.getEString(), "path", //$NON-NLS-1$
- null, 0, 1, PageflowPage.class, !IS_TRANSIENT, !IS_VOLATILE,
- IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED,
- IS_ORDERED);
- initEAttribute(getPFPage_Smallicon(), ecorePackage.getEString(),
- "smallicon", null, 0, 1, PageflowPage.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFPage_Largeicon(), ecorePackage.getEString(),
- "largeicon", null, 0, 1, PageflowPage.class, !IS_TRANSIENT, //$NON-NLS-1$
- !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE,
- !IS_DERIVED, IS_ORDERED);
-
- initEClass(pfLinkBendpointEClass, PageflowLinkBendpoint.class,
- "PFLinkBendpoint", !IS_ABSTRACT, !IS_INTERFACE, //$NON-NLS-1$
- IS_GENERATED_INSTANCE_CLASS);
- initEAttribute(getPFLinkBendpoint_D1Width(), ecorePackage.getEInt(),
- "d1Width", null, 0, 1, PageflowLinkBendpoint.class, //$NON-NLS-1$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE,
- !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLinkBendpoint_D1Height(), ecorePackage.getEInt(),
- "d1Height", null, 0, 1, PageflowLinkBendpoint.class, //$NON-NLS-1$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE,
- !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLinkBendpoint_D2Width(), ecorePackage.getEInt(),
- "d2Width", null, 0, 1, PageflowLinkBendpoint.class, //$NON-NLS-1$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE,
- !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLinkBendpoint_D2Height(), ecorePackage.getEInt(),
- "d2Height", null, 0, 1, PageflowLinkBendpoint.class, //$NON-NLS-1$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE,
- !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getPFLinkBendpoint_Weight(), ecorePackage.getEFloat(),
- "weight", "0.5", 0, 1, PageflowLinkBendpoint.class, //$NON-NLS-1$ //$NON-NLS-2$
- !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE,
- !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getPFLinkBendpoint_Link(), this.getPFLink(), this
- .getPFLink_BendPoints(), "link", null, 1, 1, //$NON-NLS-1$
- PageflowLinkBendpoint.class, !IS_TRANSIENT, !IS_VOLATILE,
- IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
- !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
-
- // Create resource
- createResource(eNS_URI);
- }
-
-}
-// PageflowPackageImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPageImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPageImpl.java
deleted file mode 100644
index eca7a66b5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/PageflowPageImpl.java
+++ /dev/null
@@ -1,531 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.Collection;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.NotificationChain;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.emf.ecore.util.InternalEList;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * <!-- begin-user-doc --> An implementation of the model object '<em><b>PF Page</b></em>'.
- * <!-- end-user-doc -->
- * <p>
- * The following features are implemented:
- * <ul>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl#getPath <em>Path</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl#getSmallicon <em>Smallicon</em>}</li>
- * <li>{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl#getLargeicon <em>Largeicon</em>}</li>
- * </ul>
- * </p>
- *
- * @generated
- */
-public class PageflowPageImpl extends PageflowNodeImpl implements PageflowPage {
- private String path;
-
- private String smallIcon;
-
- private String largeIcon;
-
- /**
- * The default value of the '{@link #getPath() <em>Path</em>}' attribute.
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getPath()
- * @generated
- * @ordered
- */
- protected static final String PATH_EDEFAULT = null;
-
- /**
- * The default value of the '{@link #getSmallicon() <em>Smallicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getSmallicon()
- * @generated
- * @ordered
- */
- protected static final String SMALLICON_EDEFAULT = null;
-
- /**
- * The default value of the '{@link #getLargeicon() <em>Largeicon</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @see #getLargeicon()
- * @generated
- * @ordered
- */
- protected static final String LARGEICON_EDEFAULT = null;
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowPageImpl() {
- super();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected EClass eStaticClass() {
- return PageflowPackage.eINSTANCE.getPFPage();
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String getPath() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_PAGE__PATH);
- // Try to return reasonable result.
- return result == null && getFCElements().isEmpty() ? path
- : (result != null ? result : PATH_EDEFAULT);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setPath(String newValue) {
- String oldPath = getPath();
- path = newValue;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_PAGE__PATH, oldPath, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
-
- public void setComment(String newValue) {
- super.setComment(newValue);
- String oldComment = getComment();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PAGEFLOW_ELEMENT__COMMENT, oldComment,
- newValue));
-
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
-
- public String getComment() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_PAGE__COMMENT);
- return result == null
- && (getFCElements().isEmpty() || ((PageReferenceElement) getFCElements())
- .isEndOnly()) ? super.getComment()
- : (result != null ? result
- : PageflowElementImpl.COMMENT_EDEFAULT);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
-
- public String getName() {
- String result;
- // To see if it is in navigation rule.
- result = (String) getFCElements().get(PageflowPackage.PF_PAGE__NAME);
- if (result == null) {
- if (super.getName() == null || super.getName().trim().length() == 0) {
- result = getPath();
- } else {
- result = super.getName();
- }
- }
- return result == null
- && (getFCElements().isEmpty() || ((PageReferenceElement) getFCElements())
- .isEndOnly()) ? PageflowElementImpl.NAME_EDEFAULT
- : (result == null ? null : result);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
-
- public void setName(String newName) {
- super.setName(newName);
- String oldName = getName();
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_PAGE__NAME, oldName, newName));
-
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getSmallicon() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_PAGE__SMALLICON);
-
- return result == null
- && (getFCElements().isEmpty() || ((PageReferenceElement) getFCElements())
- .isEndOnly()) ? smallIcon : (result != null ? result
- : SMALLICON_EDEFAULT);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setSmallicon(String newValue) {
- String oldSmallicon = getSmallicon();
- smallIcon = newValue;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_PAGE__SMALLICON, oldSmallicon, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public String getLargeicon() {
- String result = (String) getFCElements().get(
- PageflowPackage.PF_PAGE__LARGEICON);
-
- return result == null
- && (getFCElements().isEmpty() || ((PageReferenceElement) getFCElements())
- .isEndOnly()) ? largeIcon : (result != null ? result
- : LARGEICON_EDEFAULT);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated NOT
- */
- public void setLargeicon(String newValue) {
- String oldLargeIcon = getLargeicon();
- largeIcon = newValue;
- if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- PageflowPackage.PF_PAGE__LARGEICON, oldLargeIcon, newValue));
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseAdd(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd,
- PageflowPackage.PF_PAGE__PAGEFLOW, msgs);
- case PageflowPackage.PF_PAGE__OUTLINKS:
- return ((InternalEList) getOutlinks()).basicAdd(otherEnd, msgs);
- case PageflowPackage.PF_PAGE__INLINKS:
- return ((InternalEList) getInlinks()).basicAdd(otherEnd, msgs);
- default:
- return eDynamicInverseAdd(otherEnd, featureID, baseClass, msgs);
- }
- }
- if (eContainer != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return eBasicSetContainer(otherEnd, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eInverseRemove(InternalEObject otherEnd,
- int featureID, Class baseClass, NotificationChain msgs) {
- if (featureID >= 0) {
- switch (eDerivedStructuralFeatureID(featureID, baseClass)) {
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- return eBasicSetContainer(null,
- PageflowPackage.PF_PAGE__PAGEFLOW, msgs);
- case PageflowPackage.PF_PAGE__OUTLINKS:
- return ((InternalEList) getOutlinks()).basicRemove(otherEnd,
- msgs);
- case PageflowPackage.PF_PAGE__INLINKS:
- return ((InternalEList) getInlinks()).basicRemove(otherEnd,
- msgs);
- default:
- return eDynamicInverseRemove(otherEnd, featureID, baseClass,
- msgs);
- }
- }
- return eBasicSetContainer(null, featureID, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public NotificationChain eBasicRemoveFromContainer(NotificationChain msgs) {
- if (eContainerFeatureID >= 0) {
- switch (eContainerFeatureID) {
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- return eContainer.eInverseRemove(this,
- PageflowPackage.PAGEFLOW__NODES, Pageflow.class, msgs);
- default:
- return eDynamicBasicRemoveFromContainer(msgs);
- }
- }
- return eContainer.eInverseRemove(this,
- EOPPOSITE_FEATURE_BASE - eContainerFeatureID, null, msgs);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public Object eGet(EStructuralFeature eFeature, boolean resolve) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_PAGE__NAME:
- return getName();
- case PageflowPackage.PF_PAGE__COMMENT:
- return getComment();
- case PageflowPackage.PF_PAGE__X:
- return new Integer(getX());
- case PageflowPackage.PF_PAGE__Y:
- return new Integer(getY());
- case PageflowPackage.PF_PAGE__WIDTH:
- return new Integer(getWidth());
- case PageflowPackage.PF_PAGE__HEIGHT:
- return new Integer(getHeight());
- case PageflowPackage.PF_PAGE__ID:
- return getId();
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- return getPageflow();
- case PageflowPackage.PF_PAGE__OUTLINKS:
- return getOutlinks();
- case PageflowPackage.PF_PAGE__INLINKS:
- return getInlinks();
- case PageflowPackage.PF_PAGE__PATH:
- return getPath();
- case PageflowPackage.PF_PAGE__SMALLICON:
- return getSmallicon();
- case PageflowPackage.PF_PAGE__LARGEICON:
- return getLargeicon();
- }
- return super.eGet(eFeature, resolve);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eSet(EStructuralFeature eFeature, Object newValue) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_PAGE__NAME:
- setName((String) newValue);
- return;
- case PageflowPackage.PF_PAGE__COMMENT:
- setComment((String) newValue);
- return;
- case PageflowPackage.PF_PAGE__X:
- setX(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_PAGE__Y:
- setY(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_PAGE__WIDTH:
- setWidth(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_PAGE__HEIGHT:
- setHeight(((Integer) newValue).intValue());
- return;
- case PageflowPackage.PF_PAGE__ID:
- setId((String) newValue);
- return;
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- setPageflow((Pageflow) newValue);
- return;
- case PageflowPackage.PF_PAGE__OUTLINKS:
- getOutlinks().clear();
- getOutlinks().addAll((Collection) newValue);
- return;
- case PageflowPackage.PF_PAGE__INLINKS:
- getInlinks().clear();
- getInlinks().addAll((Collection) newValue);
- return;
- case PageflowPackage.PF_PAGE__PATH:
- setPath((String) newValue);
- return;
- case PageflowPackage.PF_PAGE__SMALLICON:
- setSmallicon((String) newValue);
- return;
- case PageflowPackage.PF_PAGE__LARGEICON:
- setLargeicon((String) newValue);
- return;
- }
- super.eSet(eFeature, newValue);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public void eUnset(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_PAGE__NAME:
- setName(NAME_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__COMMENT:
- setComment(COMMENT_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__X:
- setX(X_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__Y:
- setY(Y_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__WIDTH:
- setWidth(WIDTH_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__HEIGHT:
- setHeight(HEIGHT_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__ID:
- setId(ID_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- setPageflow((Pageflow) null);
- return;
- case PageflowPackage.PF_PAGE__OUTLINKS:
- getOutlinks().clear();
- return;
- case PageflowPackage.PF_PAGE__INLINKS:
- getInlinks().clear();
- return;
- case PageflowPackage.PF_PAGE__PATH:
- setPath(PATH_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__SMALLICON:
- setSmallicon(SMALLICON_EDEFAULT);
- return;
- case PageflowPackage.PF_PAGE__LARGEICON:
- setLargeicon(LARGEICON_EDEFAULT);
- return;
- }
- super.eUnset(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public boolean eIsSet(EStructuralFeature eFeature) {
- switch (eDerivedStructuralFeatureID(eFeature)) {
- case PageflowPackage.PF_PAGE__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT
- .equals(name);
- case PageflowPackage.PF_PAGE__COMMENT:
- return COMMENT_EDEFAULT == null ? comment != null
- : !COMMENT_EDEFAULT.equals(comment);
- case PageflowPackage.PF_PAGE__X:
- return x != X_EDEFAULT;
- case PageflowPackage.PF_PAGE__Y:
- return y != Y_EDEFAULT;
- case PageflowPackage.PF_PAGE__WIDTH:
- return width != WIDTH_EDEFAULT;
- case PageflowPackage.PF_PAGE__HEIGHT:
- return height != HEIGHT_EDEFAULT;
- case PageflowPackage.PF_PAGE__ID:
- return ID_EDEFAULT == null ? getId() != null : !ID_EDEFAULT
- .equals(getId());
- case PageflowPackage.PF_PAGE__PAGEFLOW:
- return getPageflow() != null;
- case PageflowPackage.PF_PAGE__OUTLINKS:
- return outlinks != null && !outlinks.isEmpty();
- case PageflowPackage.PF_PAGE__INLINKS:
- return inlinks != null && !inlinks.isEmpty();
- case PageflowPackage.PF_PAGE__PATH:
- return PATH_EDEFAULT == null ? getPath() != null : !PATH_EDEFAULT
- .equals(getPath());
- case PageflowPackage.PF_PAGE__SMALLICON:
- return SMALLICON_EDEFAULT == null ? getSmallicon() != null
- : !SMALLICON_EDEFAULT.equals(getSmallicon());
- case PageflowPackage.PF_PAGE__LARGEICON:
- return LARGEICON_EDEFAULT == null ? getLargeicon() != null
- : !LARGEICON_EDEFAULT.equals(getLargeicon());
- }
- return super.eIsSet(eFeature);
- }
-
- /**
- * <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- public String toString() {
- if (eIsProxy())
- return super.toString();
-
- StringBuffer result = new StringBuffer(super.toString());
- result.append(" (path: "); //$NON-NLS-1$
- result.append(getPath());
- result.append(", smallicon: "); //$NON-NLS-1$
- result.append(getSmallicon());
- result.append(", largeicon: "); //$NON-NLS-1$
- result.append(getLargeicon());
- result.append(')');
- return result.toString();
- }
-
- public ReferenceElement getFCElements() {
-
- if (refElement == null) {
- refElement = new PageReferenceElement(this);
- }
- return refElement;
- }
-
-}
-// PFPageImpl
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/ReferenceElement.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/ReferenceElement.java
deleted file mode 100644
index d013ee66c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/model/impl/ReferenceElement.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.wst.common.internal.emf.resource.CompatibilityXMIResource;
-
-/**
- * The base class for mapping facesconfig node from pageflow node. The
- * ReferenceElement could be extended later to enable other model to be
- * referenced by pageflow.
- *
- * @author hmeng
- *
- */
-public abstract class ReferenceElement {
-
- private List data = new ArrayList();
-
- /**
- * the pageflow element
- */
- protected PageflowElement pageflowElement;
-
- /**
- * @param pageflowElement
- */
- public ReferenceElement(PageflowElement pageflowElement) {
- this.pageflowElement = pageflowElement;
- }
-
- /**
- * @param pageflowElement
- * @param facesConfigObject
- */
- public ReferenceElement(PageflowElement pageflowElement,
- EObject facesConfigObject) {
- this(pageflowElement);
- this.add(facesConfigObject);
- }
-
- /**
- * Add object to the list.
- *
- * @param object
- */
- public void add(EObject object) {
- if (!data.contains(object)) {
- data.add(object);
- }
- }
-
-
- /**
- * The fragment path of a node.
- *
- * @param object
- * @return the path
- */
- public static String resolvePath(EObject object) {
- if (object != null) {
- ((CompatibilityXMIResource) object.eResource())
- .setFormat(CompatibilityXMIResource.FORMAT_EMF1);
- String uriTarget = object.eResource().getURIFragment(object);
- return uriTarget;
- }
- return ""; //$NON-NLS-1$
- }
-
- /**
- * Resolve each referenced data's path and combine the result into one
- * string, the path will be seperated with '|'.
- *
- * @return the resolved string
- */
- public String resolveReferenceString() {
- String result = ""; //$NON-NLS-1$
- for (int i = 0, n = data.size(); i < n; i++) {
- result += resolvePath((EObject) data.get(i)) + "|"; //$NON-NLS-1$
- }
- if (result.length() > 0) {
- result = result.substring(0, result.length());
- }
- return result;
- }
-
- /**
- * The EMF paths of all referenced elements.
- *
- * @return the list of resolved paths for the data elements
- */
- public List getPaths() {
- List paths = new ArrayList();
- for (int i = 0, n = data.size(); i < n; i++) {
- paths.add(resolvePath((EObject) data.get(i)));
- }
- return paths;
- }
-
- /**
- * The facesconfig elements that are referenced.
- *
- * @return the list of elements
- */
- public List getData() {
- return data;
- }
-
- /**
- * Clear the data
- */
- public void clear() {
- if (!data.isEmpty()) {
- data.clear();
- }
- }
-
- /**
- * @return true if the data is empty
- */
- public boolean isEmpty() {
- return data.isEmpty();
- }
-
- /**
- * Dispose the element
- */
- public void dispose() {
- clear();
- }
-
- /**
- * Update the referenced faces-config elements.
- *
- */
- abstract public void update();
-
- /**
- * Return a pageflow property's value with referenced faces-config element.
- *
- * @param eFeature
- * @return the value for eFeature
- */
- abstract public Object get(int eFeature);
-
- /**
- * To set a pageflow property's value will result in seting a faces-config
- * element.
- *
- * @param eFeature
- * @param newValue
- */
- abstract public void set(EStructuralFeature eFeature, Object newValue);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionDialogCellEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionDialogCellEditor.java
deleted file mode 100644
index a68e86cc0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionDialogCellEditor.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- *
- * Dialog Cell Editor for Action browser.
- *
- * @author Xiao-guang Zhang
- */
-public class ActionDialogCellEditor extends EditableDialogCellEditor {
-
-
- /**
- * Default constructor
- */
- public ActionDialogCellEditor() {
- super();
- }
-
-
- /**
- * @param parent
- */
- public ActionDialogCellEditor(Composite parent) {
- super(parent);
- }
-
- /**
- * @param parent
- * @param style
- */
- public ActionDialogCellEditor(Composite parent, int style) {
- super(parent, style);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see DialogCellEditor#openDialogBox(org.eclipse.swt.widgets.Control)
- */
- protected Object openDialogBox(Control cellEditorWindow) {
- String actionExpression = getDefaultText().getText();
- // IStructuredSelection selectionToPass = StructuredSelection.EMPTY;
- // Create a new jsf Wizard
-
- // FIXME sfshi 2005-11-16
- // ActionSelectionWizard actionSelectionWizard =
- // new ActionSelectionWizard(ActionSelectionWizard.CONSIDER_METHODS);
- // actionSelectionWizard.init(EditorPlugin.getDefault().getWorkbench(),
- // selectionToPass);
- // actionSelectionWizard.setActionExpression(actionExpression);
- // //using a wizard dialog to display the new jsf wizard
- // WizardDialog actionSelectionWizardDialog =
- // new WizardDialog(cellEditorWindow.getShell(),actionSelectionWizard);
- // if (actionSelectionWizardDialog.open() == WizardDialog.OK )
- // {
- // actionExpression = actionSelectionWizard.getActionExpression();
- // }
- return actionExpression;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeDialogCellEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeDialogCellEditor.java
deleted file mode 100644
index 3c683411e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeDialogCellEditor.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- *
- * Dialog Cell Editor for Action's outcome browser.
- *
- * @author Xiao-guang Zhang
- */
-public class ActionOutcomeDialogCellEditor extends EditableDialogCellEditor {
- /** the source PFLink element */
- PageflowElement element;
-
- /**
- * @param element
- */
- public ActionOutcomeDialogCellEditor(PageflowElement element) {
- super();
- this.element = element;
- }
-
- /**
- * @param parent
- * @param element
- */
- public ActionOutcomeDialogCellEditor(Composite parent,
- PageflowElement element) {
- super(parent);
- this.element = element;
- }
-
-
- /**
- * @param parent
- * @param style
- * @param element
- */
- public ActionOutcomeDialogCellEditor(Composite parent, int style,
- PageflowElement element) {
- super(parent, style);
- this.element = element;
- }
-
- /**
- * get the previous JSP page, it can be null if the previous node is not
- * PFPage, but PFAction.
- *
- * @param element_
- * @return
- */
- private String getPreviousJSPPath(PageflowElement element_) {
- String jspPath = null;
- if (element_ instanceof PageflowLink) {
- PageflowNode source = ((PageflowLink) element_).getSource();
-
- if (source instanceof PageflowPage) {
- jspPath = ((PageflowPage) source).getPath();
- }
- }
- return jspPath;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see DialogCellEditor#openDialogBox(org.eclipse.swt.widgets.Control)
- */
- protected Object openDialogBox(Control cellEditorWindow) {
- String outcome = getDefaultText().getText();
-
- String jspPathName = WebrootUtil.getProjectPath(element,
- getPreviousJSPPath(element));
-
- ActionOutcomeSelectionDialog selectionDialog = new ActionOutcomeSelectionDialog(
- getControl().getShell(), outcome, jspPathName);
-
- if (selectionDialog.open() == Window.OK) {
- outcome = selectionDialog.getSelectedAction();
- }
-
- return outcome;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeSelectionDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeSelectionDialog.java
deleted file mode 100644
index b788e53e1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionOutcomeSelectionDialog.java
+++ /dev/null
@@ -1,379 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.List;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.viewers.ColumnPixelData;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.Separator;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.JSPUtil;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-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.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.swt.widgets.Text;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Element;
-
-/**
- * This dialog is used to edit outcome property of link component of Pageflow
- * Designer.
- *
- * @author Xiao-guang Zhang
- */
-public class ActionOutcomeSelectionDialog extends Dialog {
-
- /** property's name text control */
- private Text actionText;
-
- /** linked source jsp file name */
- private String jspName;
-
- /** the current outcome */
- private String outcome;
-
- /** action table control */
- private Table actionTable;
-
- /** Column width of component name and action */
- private static final int COMPONENT_COL_WIDTH = 160;
-
- private static final int ACTION_COL_WIDTH = 160;
-
- /** Dialog default height and width */
- private static final int DIALOG_DEFAULT_WIDTH = 400;
-
- private static final int DIALOG_DEFAULT_HEIGHT = 300;
-
- private static String JSF_EL_LEFT_BRACE = "#{"; //$NON-NLS-1$
-
- private static String JSF_EL_RIGHT_BRACE = "}"; //$NON-NLS-1$
-
- /** the listener for the text modification */
- private ModifyListener modifyListener;
-
- /**
- * @param parentShell
- * @param outcome
- * @param jspName
- */
- public ActionOutcomeSelectionDialog(Shell parentShell, String outcome,
- String jspName) {
- super(parentShell);
- this.outcome = outcome;
- this.jspName = jspName;
-
- modifyListener = new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- verifyComplete();
- }
- };
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#createDialogArea(Composite)
- */
- protected Control createDialogArea(Composite parent) {
- GridLayout gridLayout;
-
- Composite container = (Composite) super.createDialogArea(parent);
- gridLayout = new GridLayout();
- gridLayout.numColumns = 1;
- gridLayout.marginWidth = 10;
- gridLayout.marginHeight = 10;
- container.setLayout(gridLayout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- // gd.widthHint = 300;
- gd.heightHint = DIALOG_DEFAULT_HEIGHT;
- gd.widthHint = DIALOG_DEFAULT_WIDTH;
- container.setLayoutData(gd);
-
- Label choiceLabel = new Label(container, SWT.LEFT);
- gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
- // gd.widthHint = 100;
- choiceLabel.setLayoutData(gd);
- // Pageflow.Property.Action.OutcomeSelectionDialog.Choice = Enter the
- // outcome or select one from action list below:
- choiceLabel
- .setText(PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_Choice);
-
- createOutcomeSection(container);
-
- createActionListSection(container);
-
- return container;
- }
-
- /**
- * create a Outcome input section
- *
- * @param container
- */
- protected void createOutcomeSection(Composite container) {
- Composite outcomeSection = new Composite(container, SWT.NONE);
- GridLayout gl = new GridLayout();
- gl.numColumns = 1;
- gl.marginWidth = 0;
- outcomeSection.setLayout(gl);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- outcomeSection.setLayoutData(gd);
-
- actionText = new Text(outcomeSection, SWT.BORDER);
- gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL
- | GridData.FILL_HORIZONTAL);
- actionText.setLayoutData(gd);
-
- actionText.addModifyListener(modifyListener);
-
- if (outcome != null && outcome.length() > 0) {
- actionText.setText(outcome);
- }
- }
-
- /**
- * create action list table section
- *
- * @param container
- */
- protected void createActionListSection(Composite container) {
- final Group actionSection = new Group(container, SWT.NONE);
- GridLayout gridLayout = new GridLayout();
- gridLayout.numColumns = 1;
- actionSection.setLayout(gridLayout);
- GridData gd = new GridData(GridData.FILL_BOTH);
- actionSection.setLayoutData(gd);
-
- String actionListTitle = null;
- if (jspName != null && jspName.length() > 0) {
- actionListTitle = NLS.bind(PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTableWithJSP_Title, jspName);
- } else {
- actionListTitle = PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Title;
- }
-
- // Pageflow.Property.Action.OutcomeSelectionDialog.ActionListTable.Title
- // = Actions
- actionSection.setText(actionListTitle);
-
- actionTable = new Table(actionSection, SWT.BORDER | SWT.FULL_SELECTION);
- actionTable.setLayoutData(new GridData(GridData.FILL_BOTH));
- actionTable.setHeaderVisible(true);
- actionTable.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- actionTable.setLayout(layout);
-
- layout.addColumnData(new ColumnPixelData(COMPONENT_COL_WIDTH));
- layout.addColumnData(new ColumnPixelData(ACTION_COL_WIDTH));
- TableColumn componentCol = new TableColumn(actionTable, SWT.NONE);
- // Pageflow.Property.Action.OutcomeSelectionDialog.ActionListTable.Component
- // = Component ID
- componentCol
- .setText(PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Component);
- TableColumn actionCol = new TableColumn(actionTable, SWT.NONE);
-
- // Pageflow.Property.Action.OutcomeSelectionDialog.ActionListTable.Action
- // = Action
- actionCol
- .setText(PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_ActionListTable_Action);
-
- actionTable.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- TableItem selItem = (TableItem) e.item;
- String action = selItem.getText(1);
- if (action != null && action.length() > 0)
- actionText.setText(action);
- }
- });
-
- addActionsInJSP();
-
- }
-
- /**
- * Creates a separator line. Expects a <code>GridLayout</code> with at
- * least 1 column.
- *
- * @param composite
- * the parent composite
- * @param nColumns
- * number of columns to span
- */
- protected void createSeparator(Composite composite, int nColumns) {
- (new Separator(SWT.SEPARATOR | SWT.HORIZONTAL)).doFillIntoGrid(null,
- composite, nColumns, convertHeightInCharsToPixels(1));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#createButtonsForButtonBar(Composite)
- */
- protected void createButtonsForButtonBar(Composite parent) {
- createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL,
- true);
- createButton(parent, IDialogConstants.CANCEL_ID,
- IDialogConstants.CANCEL_LABEL, false);
-
- verifyComplete();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#configureShell(Shell)
- */
- protected void configureShell(Shell newShell) {
- super.configureShell(newShell);
-
- // Pageflow.Property.Action.OutcomeSelectionDialog.Title = Outcome
- // Selection
- newShell
- .setText(PageflowMessages.Pageflow_Property_Action_OutcomeSelectionDialog_Title);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see Dialog#buttonPressed(int)
- */
- protected void buttonPressed(int buttonId) {
- if (buttonId == IDialogConstants.CANCEL_ID) {
- setReturnCode(CANCEL);
- close();
- return;
- } else if (buttonId == IDialogConstants.OK_ID) {
- setReturnCode(OK);
-
- outcome = actionText.getText();
-
- close();
- return;
- }
- super.buttonPressed(buttonId);
- }
-
- /**
- *
- * check the dialog inputs are complete or not, and set the OK button enable
- * or not.
- */
- private void verifyComplete() {
- if (getButton(IDialogConstants.OK_ID) != null) {
- getButton(IDialogConstants.OK_ID).setEnabled(isDialogComplete());
- }
- }
-
- /**
- * check the dialog inputs are complete or not.
- *
- * @return
- */
- private boolean isDialogComplete() {
- return isValidName();
- }
-
- /**
- * the input name is valid or not
- *
- * @return
- */
- private boolean isValidName() {
- return actionText.getText().length() > 0;
- }
-
- /**
- * get the selected action in the action table
- *
- * @return - selected action
- */
- public String getSelectedAction() {
- return outcome;
- }
-
- /**
- * add actions in the source jsp file to the action list table control
- *
- */
- private void addActionsInJSP() {
- List actionNodes = JSPUtil.getActionListInJSPFile(jspName);
-
- if (actionNodes != null) {
- for (int i = 0, n = actionNodes.size(); i < n; i++) {
- Element node = (Element) actionNodes.get(i);
- StringBuffer componentName = new StringBuffer();
-
- Attr idAttr = node.getAttributeNode("id"); //$NON-NLS-1$
- if (idAttr != null)
- componentName.append(idAttr.getNodeValue());
-
- componentName.append("(").append(node.getTagName()).append(")"); //$NON-NLS-1$ //$NON-NLS-2$
-
- Attr actionAttr = node.getAttributeNode("action"); //$NON-NLS-1$
- if (actionAttr != null) {
- String action = actionAttr.getValue();
- if (isValidEL(action))
- addActionTableItem(componentName.toString(), action);
- }
- }
- }
- }
-
- /**
- * @param expressionString
- * @return true if expressionString is valid EL
- */
- public static boolean isValidEL(String expressionString) {
- if (expressionString == null || expressionString.length() == 0)
- return true;
-
- return (expressionString.startsWith(JSF_EL_LEFT_BRACE) && expressionString
- .endsWith(JSF_EL_RIGHT_BRACE))
- || (!expressionString.startsWith(JSF_EL_LEFT_BRACE) && !expressionString
- .endsWith(JSF_EL_RIGHT_BRACE));
- }
-
- /**
- * add a new action item in the previous jsp page.
- *
- * @param componentName -
- * JSF component element
- * @param action -
- * value of action's attribute
- */
- private void addActionTableItem(String componentName, String action) {
- if (componentName != null && componentName.length() > 0
- && action != null && action.length() > 0) {
- TableItem item = new TableItem(actionTable, SWT.NONE);
- item.setText(0, componentName);
- item.setText(1, action);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionSectionDescriptor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionSectionDescriptor.java
deleted file mode 100644
index 85ff2e28e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ActionSectionDescriptor.java
+++ /dev/null
@@ -1,11 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditableDialogCellEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditableDialogCellEditor.java
deleted file mode 100644
index ee2cd23b6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditableDialogCellEditor.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.text.MessageFormat;
-
-import org.eclipse.jface.viewers.DialogCellEditor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.FocusAdapter;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * @author Hong-tao Meng
- */
-public abstract class EditableDialogCellEditor extends DialogCellEditor {
- private Text text;
-
- /**
- *
- */
- public EditableDialogCellEditor() {
- super();
- }
-
- /**
- * @param parent
- */
- public EditableDialogCellEditor(Composite parent) {
- super(parent);
- }
-
- /**
- * @param parent
- * @param style
- */
- public EditableDialogCellEditor(Composite parent, int style) {
- super(parent, style);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.DialogCellEditor#createContents(org.eclipse.swt.widgets.Composite)
- */
- protected Control createContents(Composite cell) {
- text = new Text(cell, SWT.LEFT);
- text.setFont(cell.getFont());
- text.setBackground(cell.getBackground());
- text.addKeyListener(new KeyAdapter() {
- // hook key pressed - see PR 14201
- public void keyPressed(KeyEvent e) {
- keyReleaseOccured(e);
- // disposed this cell editor
- if ((getControl() == null) || getControl().isDisposed()) {
- return;
- }
- }
- });
- // when the text control has focus, the cellEditor will deactive even
- // when you press the button.
- // Add the follow codes enable switch to the button control.
- text.addFocusListener(new FocusAdapter() {
- public void focusLost(FocusEvent e) {
- boolean newValidState = isCorrect(text.getText());
- if (newValidState) {
- markDirty();
- doSetValue(text.getText());
- } else {
- // try to insert the current value into the error message.
- setErrorMessage(MessageFormat.format(getErrorMessage(),
- new Object[] { text.getText().toString() }));
- }
- }
- });
-
- return text;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.CellEditor#doSetFocus()
- */
- protected void doSetFocus() {
- text.setFocus();
- text.selectAll();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.DialogCellEditor#updateContents(java.lang.Object)
- */
- protected void updateContents(Object value) {
- if (text == null) {
- return;
- }
-
- String text_ = "";//$NON-NLS-1$
- if (value != null) {
- text_ = value.toString();
- }
- this.text.setText(text_);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.CellEditor#keyReleaseOccured(org.eclipse.swt.events.KeyEvent)
- */
- protected void keyReleaseOccured(KeyEvent keyEvent) {
- if (keyEvent.character == '\r') {
- boolean newValidState = isCorrect(text.getText());
- if (newValidState) {
- markDirty();
- doSetValue(text.getText());
- } else {
- // try to insert the current value into the error message.
- setErrorMessage(MessageFormat.format(getErrorMessage(),
- new Object[] { text.getText().toString() }));
- }
- fireApplyEditorValue();
- }
- super.keyReleaseOccured(keyEvent);
- }
-
- /**
- * @return the default text
- */
- public Text getDefaultText() {
- return text;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditorSectionDescriptor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditorSectionDescriptor.java
deleted file mode 100644
index 6628690b6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/EditorSectionDescriptor.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.List;
-
-import org.eclipse.jface.viewers.IFilter;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section.EditorSection;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ISection;
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptor;
-
-
-
-/**
- * @author jchoi
- */
-public class EditorSectionDescriptor implements ISectionDescriptor {
- /**
- * constructor
- */
- public EditorSectionDescriptor() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getId()
- */
- public String getId() {
- return ITabbedPropertiesConstants.EDITOR_SECTION;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getInputTypes()
- */
- public List getInputTypes() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getSectionClass()
- */
- public ISection getSectionClass() {
- return new EditorSection();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getTargetTab()
- */
- public String getTargetTab() {
- return ITabbedPropertiesConstants.ATTRIBUTE_TAB_ID;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#appliesTo(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public boolean appliesTo(IWorkbenchPart part, ISelection selection) {
- Object object = null;
- if (selection instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) selection;
- object = structuredSelection.getFirstElement();
- // The editor section in the attribute tab will be shown for only
- // pageflow element
- if (object instanceof PageflowEditPart) {
- return true;
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getAfterSection()
- */
- public String getAfterSection() {
- return ITabbedPropertiesConstants.TOP_SECTION;
- }
-
- public int getEnablesFor() {
- return ENABLES_FOR_ANY;
- }
-
- public IFilter getFilter() {
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ExistingPagePathDialogCellEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ExistingPagePathDialogCellEditor.java
deleted file mode 100644
index 121a2dafd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ExistingPagePathDialogCellEditor.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.ListChoiceDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * The cell editor used to locate an existing pageflow page node in current
- * pageflow.
- *
- * @author hmeng
- *
- */
-public class ExistingPagePathDialogCellEditor extends EditableDialogCellEditor {
- Pageflow pageflow;
-
- /**
- *
- */
- public ExistingPagePathDialogCellEditor() {
- super();
- }
-
- /**
- * @param parent
- * @param style
- */
- public ExistingPagePathDialogCellEditor(Composite parent, int style) {
- super(parent, style);
- }
-
- /**
- * @param parent
- * @param pageflow
- */
- public ExistingPagePathDialogCellEditor(Composite parent, Pageflow pageflow) {
- super(parent);
- this.pageflow = pageflow;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see DialogCellEditor#openDialogBox(Control)
- */
- protected Object openDialogBox(Control cellEditorWindow) {
- String jsfSelection = ""; //$NON-NLS-1$
- if (getDefaultText() != null && getDefaultText().getText().length() > 0) {
- jsfSelection = getDefaultText().getText();
- }
- ListChoiceDialog dialog = new ListChoiceDialog(cellEditorWindow
- .getShell(), getPagePaths(),
- PageflowMessages.ExistingPagePathDialogCellEdito_LabelText);
-
- if (dialog.open() == Window.OK) {
- jsfSelection = dialog.getResult();
- }
- return jsfSelection;
- }
-
- /**
- * Collect page paths in current pageflow.
- *
- * @return
- */
- private String[] getPagePaths() {
- List result = new ArrayList();
- List list = pageflow.getNodes();
- for (int i = 0; i < list.size(); i++) {
- String path = ((PageflowPage) list.get(i)).getPath();
- if (path != null && path.trim().length() > 0) {
- result.add(path);
- }
- }
- String[] r = (String[]) result.toArray(new String[result.size()]);
- Arrays.sort(r);
- return r;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSection.java
deleted file mode 100644
index 85884e39d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSection.java
+++ /dev/null
@@ -1,379 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.part.MultiPageEditorPart;
-import org.eclipse.ui.part.PageBook;
-import org.eclipse.ui.views.properties.IPropertySheetPage;
-import org.eclipse.ui.views.properties.PropertySheetPage;
-import org.eclipse.ui.views.properties.tabbed.ISection;
-import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-import org.eclipse.wst.sse.ui.StructuredTextEditor;
-
-/**
- * This class defines the general tab for pageflow attributes. This class
- * defines the controls shown in this sectin and their event handler. For
- * MultiPageEditorPart, if it support getAdapter(IEditorPart.class) to get the
- * current active editor, then, this section can get the different
- * PropertySheetPage for different sub EditorPart.
- *
- * @author Xiao-guang Zhang
- */
-public class GeneralViewSection implements ISection,
- ISelectionChangedListener {
- /** the pagebook */
- private PageBook pageBook = null;
-
- /**
- * A data structure used to store the information about a single page within
- * a MultiPageEditorPart
- */
- protected static class PageRec {
-
- /**
- * The part including editorpart, or Control
- */
- public IWorkbenchPart part;
-
- /**
- * The page.
- */
- public IPropertySheetPage page;
-
- /**
- * Creates a new page record initialized to the given part and page.
- *
- * @param part
- * @param page
- */
- public PageRec(IWorkbenchPart part, IPropertySheetPage page) {
- this.part = part;
- this.page = page;
- }
-
- /**
- * Disposes of this page record by <code>null</code>ing its fields.
- */
- public void dispose() {
- part = null;
- page = null;
- }
- }
-
- /**
- * Map from parts to part records (key type: <code>IWorkbenchPart</code>;
- * value type: <code>PartRec</code>).
- */
- private Map mapPartToRec = new HashMap();
-
- /**
- * The page record for the default page.
- */
- private PageRec defaultPageRec;
-
- /**
- * The page rec which provided the current page or <code>null</code>
- */
- private PageRec activeRec;
-
- /*
- * (non-Javadoc)
- *
- * @see com.createControls(Composite, TabbedPropertySheetPage)
- */
- public void createControls(Composite parent,
- TabbedPropertySheetPage tabbedPropertySheetPage) {
- FillLayout layout = new FillLayout();
- layout.marginWidth = ITabbedPropertyConstants.HSPACE;
- layout.marginHeight = ITabbedPropertyConstants.VSPACE;
-
- // composite.setLayout(layout);
- parent.setLayout(layout);
- // pagebook
- pageBook = new PageBook(parent, SWT.BORDER);
-
- // create a default property page.
- createDefaultPage();
-
- // Show the default page
- if (defaultPageRec != null) {
- showPageRec(defaultPageRec);
- }
- }
-
- /**
- * Shows page contained in the given page record in this view. The page
- * record must be one from this pagebook view.
- * <p>
- * The <code>PageBookView</code> implementation of this method asks the
- * pagebook control to show the given page's control, and records that the
- * given page is now current. Subclasses may extend.
- * </p>
- *
- * @param pageRec
- * the page record containing the page to show
- */
- protected void showPageRec(PageRec pageRec) {
- // If already showing do nothing
- if (activeRec == pageRec) {
- return;
- }
- // If the page is the same, just set activeRec to pageRec
- if (activeRec != null && pageRec != null
- && activeRec.page == pageRec.page) {
- activeRec = pageRec;
- return;
- }
-
- // Show new page.
- activeRec = pageRec;
- Control pageControl = activeRec.page.getControl();
- if (pageControl != null && !pageControl.isDisposed()) {
- // Verify that the page control is not disposed
- // If we are closing, it may have already been disposed
- pageBook.showPage(pageControl);
- }
- }
-
- /**
- * Creates a page for a given part. Adds it to the pagebook but does not
- * show it.
- *
- * @param part
- * The part we are making a page for.
- * @return IWorkbenchPart
- */
- private PageRec createPage(IWorkbenchPart part) {
- PageRec rec = doCreatePage(part);
- if (rec != null) {
- mapPartToRec.put(part, rec);
- }
- return rec;
- }
-
- /*
- * (non-Javadoc) Method declared on PageBookView.
- */
- /**
- * @param part
- * @return PageRec for part
- */
- protected PageRec doCreatePage(IWorkbenchPart part) {
- // FIXME: Because the PropertySheetPage of StructuredTextEditor has a
- // bug:
- // the editor can't be opened twice if the property view is shown.
- // This bug only exists in WTP 1.0.0 version.
- if (part instanceof StructuredTextEditor) {
- return null;
- }
- // Try to get an property page.
- Object obj = part.getAdapter(IPropertySheetPage.class);
- if (obj instanceof IPropertySheetPage) {
- IPropertySheetPage page = (IPropertySheetPage) obj;
-
- page.createControl(getPageBook());
-
- return new PageRec(part, page);
- }
- // There is no content property page
- return null;
- }
-
- private void createDefaultPage() {
- // Create the default PropertySheetPage rec.
- IPropertySheetPage defaultPage = new PropertySheetPage();
- defaultPage.createControl(getPageBook());
-
- defaultPageRec = new PageRec(null, defaultPage);
- }
-
- /**
- * Returns the pagebook control for this view.
- *
- * @return the pagebook control, or <code>null</code> if not initialized
- */
- protected PageBook getPageBook() {
- return pageBook;
- }
-
- /**
- * Returns the page record for the given part.
- *
- * @param part
- * the part
- * @return the corresponding page record, or <code>null</code> if not
- * found
- */
- protected PageRec getPageRec(Object part) {
- return (PageRec) mapPartToRec.get(part);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISection#setInput(IWorkbenchPart, ISelection)
- */
- public void setInput(IWorkbenchPart part, ISelection selection) {
- if (part instanceof MultiPageEditorPart) {
- IEditorPart subPage = (IEditorPart) part
- .getAdapter(IEditorPart.class);
- if (subPage != null) {
- // get or Create a PropertySheetPage for the part.
- PageRec rec = getPageRec(subPage);
- if (rec == null) {
- rec = createPage(subPage);
- }
-
- // Show the page.
- if (rec != null) {
- showPageRec(rec);
- } else {
- showPageRec(defaultPageRec);
- }
- }
- }
- activeRec.page.selectionChanged(part, selection);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISection#aboutToBeShown()
- */
- public void aboutToBeShown() {
- refresh();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISection#aboutToBeHidden()
- */
- public void aboutToBeHidden() {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISection#dispose()
- */
- public void dispose() {
- // Deref all of the pages.
- activeRec = null;
- if (defaultPageRec != null) {
- // check for null since the default page may not have
- // been created (ex. perspective never visible)
- defaultPageRec.page.dispose();
- defaultPageRec = null;
- }
- Map clone = (Map) ((HashMap) mapPartToRec).clone();
- Iterator iter = clone.values().iterator();
- while (iter.hasNext()) {
- PageRec rec = (PageRec) iter.next();
- removePage(rec);
- }
- }
-
- /**
- * Removes a page record. If it is the last reference to the page dispose of
- * it - otherwise just decrement the reference count.
- *
- * @param rec
- */
- private void removePage(PageRec rec) {
- mapPartToRec.remove(rec.part);
-
- Control control = rec.page.getControl();
- if (control != null && !control.isDisposed()) {
- // Dispose the page's control so pages don't have to do this in
- // their
- // dispose method.
- // The page's control is a child of this view's control so if this
- // view
- // is closed, the page's control will already be disposed.
- control.dispose();
- }
-
- // free the page
- doDestroyPage(rec.part, rec);
- }
-
- /**
- * Destroys a page in the pagebook for a particular part.
- *
- * @param part
- * the input part
- * @param rec
- * a page record for the part
- */
- protected void doDestroyPage(IWorkbenchPart part, PageRec rec) {
- IPropertySheetPage page = rec.page;
- page.dispose();
- rec.dispose();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISection#getMinimumHeight()
- */
- public int getMinimumHeight() {
- return SWT.DEFAULT;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.ibm.xtools.common.ui.properties.ISection#shouldUseExtraSpace()
- */
- public boolean shouldUseExtraSpace() {
- /**
- * here should return true, otherwise, the component controls will not
- * fill the whole panel of the tab.
- */
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.ibm.xtools.common.ui.properties.ISection#refresh()
- */
- public void refresh() {
- return;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- setInput((IWorkbenchPart) event.getSource(), event.getSelection());
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSectionDescriptor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSectionDescriptor.java
deleted file mode 100644
index 4a7502807..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/GeneralViewSectionDescriptor.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.List;
-
-import org.eclipse.jface.text.ITextSelection;
-import org.eclipse.jface.viewers.IFilter;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementTreeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowLinkEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ISection;
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptor;
-
-/**
- * This class defines the section descriptor for pageflow attributes. Following
- * is the typical function of SectionDescriptor for tabbed property views. 1. In
- * tabbed property view, there are multiple sections, one or more than one
- * sections can be composed of one tab. 2. Each of section has an ID, and their
- * relationship is defined by the function "getAfterSection". 3. Not all
- * sections are enabled always. They are enabled according to current
- * WorkbenchPart and selection, which is defined in function "appliesTo".
- *
- * @author Xiao-guang Zhang
- */
-public class GeneralViewSectionDescriptor implements ISectionDescriptor {
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptor#getId()
- */
- public String getId() {
- return ITabbedPropertiesConstants.GENERAL_TAB_ID;
- }
-
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptor#getInputTypes()
- */
- public List getInputTypes() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptor#getSectionClass()
- */
- public ISection getSectionClass() {
- return new GeneralViewSection();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.ibm.xtools.common.ui.properties.ISectionDescriptor#getTargetTab()
- */
- public String getTargetTab() {
- return ITabbedPropertiesConstants.GENERAL_TAB_ID;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptor#appliesTo(IWorkbenchPart, ISelection)
- */
- public boolean appliesTo(IWorkbenchPart part, ISelection selection) {
- Object object = null;
- // FIXME: Should move the appliesTo to differnt page of
- // MultiPageEditorPart.
- if (selection instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) selection;
- object = structuredSelection.getFirstElement();
- // The general tab will be shown for only pageflow element and
- // pageflow link editparts
- if (object instanceof PageflowElementEditPart
- || object instanceof PageflowElementTreeEditPart) {
- return true;
- } else if (object instanceof PageflowLinkEditPart) {
- PageflowLink pfLink = (PageflowLink) ((PageflowLinkEditPart) object)
- .getModel();
- if (PageflowValidation.getInstance().isValidLinkForProperty(
- pfLink)) {
- return true;
- }
- } else {
- return true;
- }
- } else if (selection instanceof ITextSelection) {
- return true;
- }
-
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptor#getAfterSection()
- */
- public String getAfterSection() {
- return ""; //$NON-NLS-1$
- }
-
- public int getEnablesFor() {
- return ENABLES_FOR_ANY;
- }
-
-
- public IFilter getFilter() {
- // TODO Auto-generated method stub
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ITabbedPropertiesConstants.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ITabbedPropertiesConstants.java
deleted file mode 100644
index 54e6e75d1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ITabbedPropertiesConstants.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-/**
- * @author jchoi
- * @version
- */
-public interface ITabbedPropertiesConstants {
- /**
- * used to set grid data height hints on dialog fields
- */
- public static int BROWSE_HEIGHT = 18;
-
- /**
- * used to set grid data width hints on dialog fields
- */
- public static int BROWSE_WIDTH = 20;
-
- /**
- * the general tag id
- */
- public static final String GENERAL_TAB_ID = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.general"; //$NON-NLS-1$
-
- /**
- * the attribute tag id
- */
- public static final String ATTRIBUTE_TAB_ID = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.attribute"; //$NON-NLS-1$
-
- /**
- * the link section id
- */
- public static final String LINK_SECTION = "attribute.link"; // 4 //$NON-NLS-1$
-
- /**
- * the page section id
- */
- public static final String PAGE_SECTION = "attribute.page"; // 3 //$NON-NLS-1$
-
- /**
- * the editor section id
- */
- public static final String EDITOR_SECTION = "attribute.editor"; // 1 //$NON-NLS-1$
-
- /**
- * the top section id
- */
- public static final String TOP_SECTION = "top"; // 0 //$NON-NLS-1$
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/LinkSectionDescriptor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/LinkSectionDescriptor.java
deleted file mode 100644
index d0cc43028..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/LinkSectionDescriptor.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.List;
-
-import org.eclipse.jface.viewers.IFilter;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowLinkEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section.LinkSection;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ISection;
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptor;
-
-/**
- * @author jchoi
- * @version
- */
-public class LinkSectionDescriptor implements ISectionDescriptor {
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getId()
- */
- public String getId() {
- return ITabbedPropertiesConstants.LINK_SECTION;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getInputTypes()
- */
- public List getInputTypes() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getSectionClass()
- */
- public ISection getSectionClass() {
- return new LinkSection();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getTargetTab()
- */
- public String getTargetTab() {
- return ITabbedPropertiesConstants.ATTRIBUTE_TAB_ID;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#appliesTo(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public boolean appliesTo(IWorkbenchPart part, ISelection selection) {
- Object object = null;
- if (selection instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) selection;
- object = structuredSelection.getFirstElement();
- if (object instanceof PageflowLinkEditPart) {
- PageflowLink pfLink = (PageflowLink) ((PageflowLinkEditPart) object).getModel();
- if (PageflowValidation.getInstance().isValidLinkForProperty(
- pfLink)) {
-
- return true;
- }
-
- }
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getAfterSection()
- */
- public String getAfterSection() {
- return ITabbedPropertiesConstants.TOP_SECTION;
- }
-
- public int getEnablesFor() {
- return ENABLES_FOR_ANY;
- }
-
- public IFilter getFilter() {
- return null;
- }
-
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PagePathDialogCellEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PagePathDialogCellEditor.java
deleted file mode 100644
index fbe5502c6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PagePathDialogCellEditor.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-
-/**
- * Dialog Cell Editor for Page path browser.
- *
- * @author Xiao-guang Zhang
- */
-public class PagePathDialogCellEditor extends EditableDialogCellEditor {
- PageflowPage element;
-
- /**
- * Default constructor
- */
- public PagePathDialogCellEditor() {
- super();
- }
-
- /**
- * @param parent
- * @param element
- */
- public PagePathDialogCellEditor(Composite parent, PageflowPage element) {
- super(parent);
- this.element = element;
- }
-
-
- /**
- * @param parent
- * @param style
- */
- public PagePathDialogCellEditor(Composite parent, int style) {
- super(parent, style);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see DialogCellEditor#openDialogBox(Control)
- */
- protected Object openDialogBox(Control cellEditorWindow) {
- String jsfSelection = ""; //$NON-NLS-1$
- if (getDefaultText() != null && getDefaultText().getText().length() > 0) {
- jsfSelection = getDefaultText().getText();
- IProject project = WebrootUtil.getProject(element);
- ProjectWebPageSelectionDialog dlg = new ProjectWebPageSelectionDialog(
- cellEditorWindow.getShell(), project);
- if (dlg.open() == Window.OK) {
- jsfSelection = dlg.getResultFilePath();
- }
- }
- return jsfSelection;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageSectionDescriptor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageSectionDescriptor.java
deleted file mode 100644
index 4e7fc8096..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageSectionDescriptor.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.List;
-
-import org.eclipse.jface.viewers.IFilter;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPageImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section.PageSection;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ISection;
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptor;
-
-/**
- * @author jchoi
- * @version
- */
-public class PageSectionDescriptor implements ISectionDescriptor {
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getId()
- */
- public String getId() {
- return ITabbedPropertiesConstants.PAGE_SECTION;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getInputTypes()
- */
- public List getInputTypes() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getSectionClass()
- */
- public ISection getSectionClass() {
- return new PageSection();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getTargetTab()
- */
- public String getTargetTab() {
- return ITabbedPropertiesConstants.ATTRIBUTE_TAB_ID;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#appliesTo(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public boolean appliesTo(IWorkbenchPart part, ISelection selection) {
- Object object = null;
- if (selection instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) selection;
- object = structuredSelection.getFirstElement();
- if (object instanceof PageflowNodeEditPart) {
- Object model = ((PageflowNodeEditPart) object).getModel();
- if (model instanceof PageflowPageImpl) {
- return true;
- }
- }
- }
- return false;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISectionDescriptor#getAfterSection()
- */
- public String getAfterSection() {
- return ITabbedPropertiesConstants.TOP_SECTION;
- }
-
- public int getEnablesFor() {
- return ENABLES_FOR_ANY;
- }
-
-
- public IFilter getFilter() {
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowElementPropertySource.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowElementPropertySource.java
deleted file mode 100644
index 8eebce5fa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowElementPropertySource.java
+++ /dev/null
@@ -1,478 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.Iterator;
-import java.util.List;
-import java.util.Vector;
-
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EDataType;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.jface.viewers.ICellEditorValidator;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.views.properties.ComboBoxPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertySource;
-import org.eclipse.ui.views.properties.PropertyDescriptor;
-import org.eclipse.ui.views.properties.TextPropertyDescriptor;
-
-/**
- * This class is intended to be a generic property source for all the objects in
- * the application's model. It currently only supports String and boolean types,
- * and doesn't support reset or nested properties. It uses information in the
- * EMF EAttribute and EDataType classes to get the id, display name, and type
- * information.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowElementPropertySource implements IPropertySource {
- /** attribute name of "path" and "action", which have special property editor */
- private static final String PAGEFLOW_PATH = "path"; //$NON-NLS-1$
-
- static final String PAGEFLOW_NAME = "name"; //$NON-NLS-1$
-
- static final String PAGEFLOW_COMMENT = "comment"; //$NON-NLS-1$
-
- private static final String PAGEFLOW_CONFIG_FILE = "configfile"; //$NON-NLS-1$
-
- /** pageflow elememt */
- PageflowElement element;
-
- /** boolean value's label */
- private static final String P_VALUE_TRUE_LABEL = PageflowMessages.Pageflow_Label_True;
-
- private static final String P_VALUE_FALSE_LABEL = PageflowMessages.Pageflow_Label_False;
-
- /** Integer value for boolean type */
- private static final int P_VALUE_TRUE = 0;
-
- private static final int P_VALUE_FALSE = 1;
-
- static class BooleanLabelProvider extends LabelProvider {
- public String getText(Object element) {
- String[] values = new String[] { P_VALUE_TRUE_LABEL,
- P_VALUE_FALSE_LABEL };
- return values[((Integer) element).intValue()];
- }
-
- public Image getImage(Object element) {
- return EditorPlugin.getDefault().getImage(
- "facesconfig/Pageflow_BooleanValue.gif"); //$NON-NLS-1$
- }
- }
-
- static class PageflowLabelProvider extends LabelProvider {
-
- public Image getImage(Object element) {
- if (element instanceof String) {
- return EditorPlugin.getDefault().getImage(
- "facesconfig/Pageflow_TextValue.gif");//$NON-NLS-1$
- } else if (element instanceof Integer) {
- return EditorPlugin.getDefault().getImage(
- "facesconfig/Pageflow_IntegralValue.gif");//$NON-NLS-1$
- } else {
- return EditorPlugin.getDefault().getImage(
- "facesconfig/Pageflow_GenericValue.gif");//$NON-NLS-1$
- }
- }
- }
-
- /**
- * constructor
- *
- * @param element -
- * pageflow element model.
- */
- public PageflowElementPropertySource(PageflowElement element) {
- this.element = element;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySource#getEditableValue()
- */
- public Object getEditableValue() {
- return element;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySource#getPropertyDescriptors()
- */
- public IPropertyDescriptor[] getPropertyDescriptors() {
- // property descriptors
- List propertyDescriptors = new Vector();
-
- // if (element instanceof PageflowLink) {
- // return getLinkPropertyDescriptors();
- // }
-
- Iterator it;
- EClass cls = element.eClass();
-
- it = cls.getEAllAttributes().iterator();
- while (it.hasNext()) {
- EAttribute attr = (EAttribute) it.next();
- if (attr.isID()
- || attr.getFeatureID() == PageflowPackage.PAGEFLOW__REFERENCE_LINK) {
- continue;
- }
- EDataType type = attr.getEAttributeType();
- if (type.getInstanceClass() == String.class) {
- PropertyDescriptor propertyDescriptor;
- if (attr.getName().equalsIgnoreCase(PAGEFLOW_PATH)) {
- propertyDescriptor = getPagePathPropertyDescriptor(attr);
- } else if (attr.getName()
- .equalsIgnoreCase(PAGEFLOW_CONFIG_FILE)) {
- propertyDescriptor = null;
- } else {
- propertyDescriptor = new TextPropertyDescriptor(Integer
- .toString(attr.getFeatureID()), getString(attr
- .getName()));
- }
- if (propertyDescriptor != null) {
- propertyDescriptor
- .setLabelProvider(new PageflowLabelProvider());
- propertyDescriptors.add(propertyDescriptor);
- }
-
- } else if (type.getInstanceClass() == boolean.class) {
- PropertyDescriptor propertyDescriptor;
- propertyDescriptor = getBooleanTypePropertyDescriptor(attr);
- propertyDescriptor.setLabelProvider(new BooleanLabelProvider());
- propertyDescriptors.add(propertyDescriptor);
- }
- }
-
- return (IPropertyDescriptor[]) propertyDescriptors
- .toArray(new IPropertyDescriptor[] {});
- }
-
- /**
- * @return
- */
- // TODO: method not used; dead?
-// private IPropertyDescriptor[] getLinkPropertyDescriptors() {
-// // property descriptors
-// List propertyDescriptors = new Vector();
-//
-// Iterator it;
-// EClass cls = element.eClass();
-//
-// it = cls.getEAllAttributes().iterator();
-// while (it.hasNext()) {
-// EAttribute attr = (EAttribute) it.next();
-// if (attr.isID()
-// || attr.getName().equalsIgnoreCase(PAGEFLOW_NAME)
-// || attr.getName().equalsIgnoreCase(PAGEFLOW_COMMENT)
-// || attr.getFeatureID() == PageflowPackage.PAGEFLOW__REFERENCE_LINK) {
-// continue;
-// }
-//
-// EDataType type = attr.getEAttributeType();
-// if (type.getInstanceClass() == String.class) {
-// PropertyDescriptor propertyDescriptor;
-//
-// propertyDescriptor = new TextPropertyDescriptor(Integer
-// .toString(attr.getFeatureID()), getString(attr
-// .getName()));
-//
-// if (propertyDescriptor != null) {
-// propertyDescriptor
-// .setLabelProvider(new PageflowLabelProvider());
-// propertyDescriptors.add(propertyDescriptor);
-// }
-//
-// } else if (type.getInstanceClass() == boolean.class) {
-// PropertyDescriptor propertyDescriptor;
-// propertyDescriptor = getBooleanTypePropertyDescriptor(attr);
-// propertyDescriptor.setLabelProvider(new BooleanLabelProvider());
-// propertyDescriptors.add(propertyDescriptor);
-// }
-// }
-//
-// return (IPropertyDescriptor[]) propertyDescriptors
-// .toArray(new IPropertyDescriptor[] {});
-// }
-
- /**
- * get the property descriptor for the attribute "path" of page component
- *
- * @param attr -
- * EAttribute
- * @return
- */
- private PropertyDescriptor getPagePathPropertyDescriptor(EAttribute attr) {
- PropertyDescriptor propertyDescriptor = new PropertyDescriptor(Integer
- .toString(attr.getFeatureID()), getString(attr.getName())) {
- public CellEditor createPropertyEditor(Composite parent) {
- CellEditor editor = new PagePathDialogCellEditor(parent,
- (PageflowPage) element);
- if (getValidator() != null) {
- editor.setValidator(getValidator());
- }
- return editor;
- }
-
- /**
- * Returns the input validator for editing the property.
- *
- * @return the validator used to verify correct values for this
- * property, or <code>null</code>
- */
- protected ICellEditorValidator getValidator() {
- return new ICellEditorValidator() {
- public String isValid(Object value) {
- if (((PageflowPage) element).getPath() != null
- && value != null
- && !((PageflowPage) element).getPath()
- .equalsIgnoreCase((String) value)) {
- if (PageflowValidation.getInstance().isExistedPage(
- ((PageflowPage) element).getPageflow(),
- (String) value)) {
- // Pageflow.PageflowEditor.Alert.DNDResourceTitle
- // = Pageflow Creation Error
- // Pageflow.PageflowEditor.Alert.ExistingPage =
- // The web page {0} is already existed in
- // current PageFlow.
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.PageflowEditor.Alert.DNDResourceTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.ExistingPage", //$NON-NLS-1$
- value);
-
- return EditorPlugin
- .getResourceString("Pageflow.PageflowEditor.Alert.ExistingPage"); //$NON-NLS-1$
- }
- }
- return null;
- }
-
- };
- }
-
- };
- return propertyDescriptor;
- }
-
- /**
- * get the property descriptor for the attribute "action" of Action
- * component
- *
- * @param attr -
- * EAttribute
- * @return
- */
- // TODO: method not used; dead?
-// private PropertyDescriptor getActionPropertyDescriptor(EAttribute attr) {
-// PropertyDescriptor propertyDescriptor = new PropertyDescriptor(Integer
-// .toString(attr.getFeatureID()), getString(attr.getName())) {
-// public CellEditor createPropertyEditor(Composite parent) {
-// CellEditor editor = new ActionDialogCellEditor(parent);
-// if (getValidator() != null) {
-// editor.setValidator(getValidator());
-// }
-// return editor;
-// }
-//
-// /**
-// * Returns the input validator for editing the property.
-// *
-// * @return the validator used to verify correct values for this
-// * property, or <code>null</code>
-// */
-// protected ICellEditorValidator getValidator() {
-// return new ICellEditorValidator() {
-// public String isValid(Object value) {
-//
-// return null;
-// }
-//
-// };
-// }
-// };
-// return propertyDescriptor;
-// }
-
- /**
- * get the property descriptor for the attribute "outcome" of Link component
- *
- * @param attr -
- * EAttribute
- * @return
- */
- // TODO: method not used; dead?
-// private PropertyDescriptor getActionOutcomePropertyDescriptor(
-// EAttribute attr) {
-// PropertyDescriptor propertyDescriptor = new PropertyDescriptor(Integer
-// .toString(attr.getFeatureID()), getString(attr.getName())) {
-// public CellEditor createPropertyEditor(Composite parent) {
-// CellEditor editor = new ActionOutcomeDialogCellEditor(parent,
-// element);
-// if (getValidator() != null) {
-// editor.setValidator(getValidator());
-// }
-// return editor;
-// }
-// };
-// return propertyDescriptor;
-// }
-
- /**
- * get property descriptor for the attribute with the boolean type
- *
- * @param attr -
- * EAttribute
- * @return
- */
- PropertyDescriptor getBooleanTypePropertyDescriptor(EAttribute attr) {
- PropertyDescriptor propertyDescriptor;
- propertyDescriptor = new ComboBoxPropertyDescriptor(Integer
- .toString(attr.getFeatureID()), getString(attr.getName()),
- new String[] { P_VALUE_TRUE_LABEL, P_VALUE_FALSE_LABEL });
- return propertyDescriptor;
- }
-
- /**
- * Get a translated string from the resource locator.
- * @param key
- * @return the string for the key
- */
- protected final String getString(String key) {
- if ("comment".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_comment;
- }
-
- if ("name".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_name;
- }
-
- if ("largeicon".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_largeicon;
- }
-
- if ("smallicon".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_smallicon;
- }
-
- if ("source".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_source;
- }
-
- if ("target".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_target;
- }
-
- if ("fromaction".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_fromaction;
- }
-
- if ("path".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_path;
- }
- if ("begin".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_begin;
- }
- if ("end".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_end;
- }
- if ("configfile".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_configfile;
- }
- if ("outcome".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_outcome;
- }
- if ("redirect".equals(key)) { //$NON-NLS-1$
- return PageflowMessages.Pageflow_Model_Attributes_redirect;
- }
-
- return ""; //$NON-NLS-1$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySource#getPropertyValue(Object)
- */
- public Object getPropertyValue(Object id) {
- EStructuralFeature feature = element.eClass().getEStructuralFeature(
- Integer.parseInt((String) id));
-
- Object result = element.eGet(feature);
-
- if (result instanceof Boolean) {
- if (result == Boolean.TRUE) {
- result = new Integer(P_VALUE_TRUE);
- } else {
- result = new Integer(P_VALUE_FALSE);
- }
- }
-
- return result != null ? result : ""; //$NON-NLS-1$
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySource#isPropertySet(Object)
- */
- public boolean isPropertySet(Object id) {
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySouce#resetPropertyValue(Object)
- */
- public void resetPropertyValue(Object id) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see IPropertySource#setPropertyValue(Object, Object)
- */
- public void setPropertyValue(Object id, Object value) {
- EStructuralFeature feature = element.eClass().getEStructuralFeature(
- Integer.parseInt((String) id));
-
- Object result = element.eGet(feature);
- // if the attribute is boolean type, the value should be changed from
- // string "true" or "false"
- // to Boolean.TRUE or Boolean.FALSE
- if (result instanceof Boolean) {
- if (value.equals(new Integer(P_VALUE_TRUE))) {
- value = Boolean.TRUE;
- } else {
- value = Boolean.FALSE;
- }
- }
- element.eSet(feature, value);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowLinkPropertySource.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowLinkPropertySource.java
deleted file mode 100644
index e3c1f304a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowLinkPropertySource.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import java.util.Iterator;
-import java.util.List;
-import java.util.Vector;
-
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EDataType;
-import org.eclipse.emf.ecore.EReference;
-import org.eclipse.jface.viewers.CellEditor;
-import org.eclipse.jface.viewers.ICellEditorValidator;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-import org.eclipse.ui.views.properties.PropertyDescriptor;
-import org.eclipse.ui.views.properties.TextPropertyDescriptor;
-
-/**
- * The property source for Pageflow Link.
- *
- * @author hmeng
- */
-
-public class PageflowLinkPropertySource extends PageflowElementPropertySource {
-
- /**
- * @param element
- */
- public PageflowLinkPropertySource(PageflowElement element) {
- super(element);
- }
-
- public Object getPropertyValue(Object id) {
- Object result = super.getPropertyValue(id);
- if (Integer.parseInt((String) id) == PageflowPackage.PF_LINK__SOURCE
- || Integer.parseInt((String) id) == PageflowPackage.PF_LINK__TARGET) {
- result = ((PageflowPage) result).getPath();
- }
- return result;
- }
-
- public void setPropertyValue(Object id, Object value) {
- if (Integer.parseInt((String) id) == PageflowPackage.PF_LINK__SOURCE) {
- ((PageflowLink) element).setSourcePath((String) value);
-
- } else if (Integer.parseInt((String) id) == PageflowPackage.PF_LINK__TARGET) {
- ((PageflowLink) element).setTargetPath((String) value);
- } else {
- super.setPropertyValue(id, value);
- }
- }
-
- public IPropertyDescriptor[] getPropertyDescriptors() {
- // property descriptors
- List propertyDescriptors = new Vector();
-
- Iterator it;
- EClass cls = element.eClass();
-
- it = cls.getEAllAttributes().iterator();
- while (it.hasNext()) {
- EAttribute attr = (EAttribute) it.next();
- if (attr.isID()
- || attr.getName().equalsIgnoreCase(PAGEFLOW_NAME)
- || attr.getName().equalsIgnoreCase(PAGEFLOW_COMMENT)
- || attr.getFeatureID() == PageflowPackage.PAGEFLOW__REFERENCE_LINK) {
- continue;
- }
-
- EDataType type = attr.getEAttributeType();
- if (type.getInstanceClass() == String.class) {
- PropertyDescriptor propertyDescriptor;
-
- propertyDescriptor = new TextPropertyDescriptor(Integer
- .toString(attr.getFeatureID()),
- getString(attr.getName()));
-
- if (propertyDescriptor != null) {
- propertyDescriptor
- .setLabelProvider(new PageflowLabelProvider());
- propertyDescriptors.add(propertyDescriptor);
- }
-
- } else if (type.getInstanceClass() == boolean.class) {
- PropertyDescriptor propertyDescriptor;
- propertyDescriptor = getBooleanTypePropertyDescriptor(attr);
- propertyDescriptor.setLabelProvider(new BooleanLabelProvider());
- propertyDescriptors.add(propertyDescriptor);
- }
- }
- it = cls.getEReferences().iterator();
- while (it.hasNext()) {
- EReference attr = (EReference) it.next();
- if (attr.getFeatureID() == PageflowPackage.PF_LINK__SOURCE
- || attr.getFeatureID() == PageflowPackage.PF_LINK__TARGET) {
-
- PropertyDescriptor propertyDescriptor;
-
- propertyDescriptor = getExistingPagePathPropertyDescriptor(attr);
-
- if (propertyDescriptor != null) {
- propertyDescriptor
- .setLabelProvider(new PageflowLabelProvider());
- propertyDescriptors.add(propertyDescriptor);
- }
- }
- }
-
- return (IPropertyDescriptor[]) propertyDescriptors
- .toArray(new IPropertyDescriptor[] {});
- }
-
- /**
- * The link's ends can be modified to another page existing in current pageflow.
- * @param attr
- * @return
- */
- private PropertyDescriptor getExistingPagePathPropertyDescriptor(
- EReference attr) {
- PropertyDescriptor propertyDescriptor = new PropertyDescriptor(Integer
- .toString(attr.getFeatureID()), getString(attr.getName())) {
- public CellEditor createPropertyEditor(Composite parent) {
- CellEditor editor = new ExistingPagePathDialogCellEditor(
- parent, (Pageflow) element.eContainer());
- if (getValidator() != null) {
- editor.setValidator(getValidator());
- }
- return editor;
- }
-
- /**
- * Returns the input validator for editing the property.
- *
- * @return the validator used to verify correct values for this
- * property, or <code>null</code>
- */
- protected ICellEditorValidator getValidator() {
- return new ICellEditorValidator() {
- public String isValid(Object value) {
- if (value != null) {
- if (!PageflowValidation.getInstance()
- .isExistedPage(
- ((Pageflow) element.eContainer()),
- (String) value)) {
- // Pageflow.PageflowEditor.Alert.DNDResourceTitle
- // = Pageflow Creation Error
- // Pageflow.PageflowEditor.Alert.ExistingPage =
- // The web page {0} is already existed in
- // current PageFlow.
- EditorPlugin.getAlerts().info(PageflowMessages.PageflowLinkPropertySource_Title,
- PageflowMessages.PageflowLinkPropertySource_Text);
- // "Pageflow.PageflowEditor.Alert.DNDResourceTitle",
- // "Pageflow.PageflowEditor.Alert.ExistingPage",
- // (String) value);
-
- return EditorPlugin
- .getResourceString("Pageflow.PageflowEditor.Alert.ExistingPage"); //$NON-NLS-1$
- }
- }
- return null;
- }
-
- };
- }
-
- };
- return propertyDescriptor;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionDescriptorProvider.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionDescriptorProvider.java
deleted file mode 100644
index e36d2828e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionDescriptorProvider.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptor;
-import org.eclipse.ui.views.properties.tabbed.ISectionDescriptorProvider;
-
-/**
- * this class defines all section descriptors for pageflow. Similar with
- * PropertyDescriptors, this class defines all sections used by pageflow through
- * SectionDescriptor.
- *
- */
-public class PageflowSectionDescriptorProvider implements
- ISectionDescriptorProvider {
- /**
- * Default constructor
- */
- public PageflowSectionDescriptorProvider() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see ISectionDescriptorProvider#getSectionDescriptors()
- */
- public ISectionDescriptor[] getSectionDescriptors() {
- ISectionDescriptor[] descriptors = new ISectionDescriptor[] {
- new LinkSectionDescriptor(), new PageSectionDescriptor(),
- new EditorSectionDescriptor(),
- new GeneralViewSectionDescriptor() };
- return descriptors;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionLabelProvider.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionLabelProvider.java
deleted file mode 100644
index 1c72dae2b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PageflowSectionLabelProvider.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.gef.editparts.AbstractEditPart;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementTreeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowLinkEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * This class defines label provider for the property view's title. Tabbed
- * property view has a common area as a Title. Different decription and image
- * can be shown according to Different selection.
- *
- */
-public class PageflowSectionLabelProvider extends LabelProvider {
-
- private static final String PAGEFLOW_IMAGE_FILE = "facesconfig/FacesConfig_Pageflow16.gif"; //$NON-NLS-1$
-
- /**
- * Default constructor
- */
- public PageflowSectionLabelProvider() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see getImage(java.lang.Object)
- */
- public Image getImage(Object object) {
- Image result = EditorPlugin.getDefault().getImage(
- PAGEFLOW_IMAGE_FILE);
-
- return result;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see getText(java.lang.Object)
- */
- public String getText(Object object) {
- String result = null;
- if (object instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) object;
- Object pageflow = structuredSelection.getFirstElement();
- if (pageflow instanceof PageflowElementEditPart
- || pageflow instanceof PageflowLinkEditPart
- || pageflow instanceof PageflowElementTreeEditPart) {
-
- if (((PageflowElement) ((AbstractEditPart) pageflow).getModel())
- .eClass() == PageflowPackage.eINSTANCE.getPageflow()) {
- result = PageflowMessages.Pageflow_Model_Items_Pageflow;
- } else if (((PageflowElement) ((AbstractEditPart) pageflow)
- .getModel()).eClass() == PageflowPackage.eINSTANCE
- .getPFPage()) {
- result = PageflowMessages.Pageflow_Model_Items_PFPage;
- } else if (((PageflowElement) ((AbstractEditPart) pageflow)
- .getModel()).eClass() == PageflowPackage.eINSTANCE
- .getPFLink()) {
- result = PageflowMessages.Pageflow_Model_Items_PFLink;
- }
- }
- }
- return result;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ProjectWebPageSelectionDialog.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ProjectWebPageSelectionDialog.java
deleted file mode 100644
index 7d668d7d1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/ProjectWebPageSelectionDialog.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.jst.jsf.common.ui.internal.dialogs.CommonResourceDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * @author hmeng
- */
-
-public class ProjectWebPageSelectionDialog extends CommonResourceDialog {
-
- /**
- * @param parentShell
- * @param project
- * @param style
- */
- public ProjectWebPageSelectionDialog(Shell parentShell, IProject project,
- int style) {
- super(parentShell, project, style);
- init();
- }
-
- /**
- * @param parentShell
- * @param project
- */
- public ProjectWebPageSelectionDialog(Shell parentShell, IProject project) {
- super(parentShell, project);
- init();
- }
-
- private void init() {
- setResourceDescription(PageflowMessages.ProjectWebPageSelectionDialog_Description);
- setSuffixs(new String[] { "jsp", "jspx", "jsf", "html", "htm" }); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
- }
-
- /**
- * @return the rseult file path
- */
- public String getResultFilePath() {
- String result = ""; //$NON-NLS-1$
- IFile selectedFile = (IFile) getResult()[0];
- IPath path = selectedFile.getProjectRelativePath();
- path = path.removeFirstSegments(1);
- result = "/" + path.toString(); //$NON-NLS-1$
- return result;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.java
deleted file mode 100644
index d8fb04dc0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * NLS Message bundle for properties
- *
- */
-public final class PropertyMessages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PropertyMessages"; //$NON-NLS-1$
-
- private PropertyMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, PropertyMessages.class);
- }
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_displayName;
- /**
- * see PropertyMessages.properties
- */
- public static String property_description;
- /**
- * see PropertyMessages.properties
- */
- public static String property_configFile;
- /**
- * see PropertyMessages.properties
- */
- public static String property_largeIcon;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_smallIcon;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_fromAction;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_fromView;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_fromOutcome;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_redirect;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_browseButton;
-
- /**
- * see PropertyMessages.properties
- */
- public static String property_Command_SetValue;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.properties
deleted file mode 100644
index 3de4f3af7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/PropertyMessages.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-property_displayName=Display Name:
-property_description=Description:
-property_configFile=Faces-config file:
-property_largeIcon=Large Icon:
-property_smallIcon=Small Icon:
-property_fromAction=From Action:
-property_fromView=Page Path:
-property_fromOutcome=From Outcome:
-property_redirect=Redirect:
-property_browseButton=...
-
-property_Command_SetValue=Set {0} Property
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartGroup.java
deleted file mode 100644
index 6ccbc2c4f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartGroup.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldGroup;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PropertyMessages;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author jchoi
- * @version
- */
-/*package*/ abstract class AbstractEditPartGroup extends DialogFieldGroup {
-
- private StringDialogField descField;
-
- private StringDialogField displayNameField;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- displayNameField = new StringDialogField();
- displayNameField.setLabelText(PropertyMessages.property_displayName);
- displayNameField
- .setDialogFieldChangeListener(getDefaultChangeListener());
- descField = new StringDialogField();
-
- descField.setLabelText(PropertyMessages.property_description);
- descField.setDialogFieldChangeListener(getDefaultChangeListener());
-
- }
-
-
- /**
- * @param toolkit
- * @param parent
- * @param col
- */
- protected void layoutDialogFields(FormToolkit toolkit, Composite parent,
- int col) {
- displayNameField.doFillIntoGrid(toolkit, parent, col);
- descField.doFillIntoGrid(toolkit, parent, col);
-
- }
-
- /**
- * @param elem
- */
- protected void refreshData(PageflowElement elem) {
- descField.setTextWithoutUpdate(elem.getComment());
- displayNameField.setTextWithoutUpdate(elem.getName());
- }
-
- /**
- * @return the description field
- */
- protected StringDialogField getDescField() {
- return descField;
- }
-
- /**
- * @return the display name field
- */
- protected StringDialogField getDisplayNameField() {
- return displayNameField;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#validateDialogFields()
- */
- public IStatus[] validateDialogFields() {
-
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartSection.java
deleted file mode 100644
index 00dcfca48..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/AbstractEditPartSection.java
+++ /dev/null
@@ -1,238 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import java.util.EventObject;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.EditPart;
-import org.eclipse.gef.commands.CommandStack;
-import org.eclipse.gef.commands.CommandStackListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldChangeListener;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.IPropertySource;
-import org.eclipse.ui.views.properties.tabbed.AbstractPropertySection;
-
-/**
- * This is base section, which support GEF command stack to redo/undo setting
- * properties.
- *
- * @author jchoi, Xiao-guang Zhang
- */
-/*package*/ abstract class AbstractEditPartSection extends AbstractPropertySection {
-
- IDialogFieldChangeListener changeListener = new IDialogFieldChangeListener() {
- public void dialogFieldChanged(DialogField field) {
- validate();
- }
- };
-
- /** property source of edit part */
- private IPropertySource propertySource;
-
- /** EditPart instance */
- private EditPart editPart;
-
- /** map for property registry to store a map between the property id and name */
- private Map propertyRegistry;
-
- /** GEF command stack */
- private CommandStack commandStack;
-
- /** command stack listener to refresh the section */
- private CommandStackListener commandStackListener;
-
- /**
- *
- */
- public AbstractEditPartSection() {
- super();
- }
-
- /**
- * refresh the whole section
- *
- */
- public void refreshData() {
- super.refresh();
- }
-
- /**
- * TODO: this method seems unused
- */
- public abstract void validate();
-
- /**
- * dispose the command stack listener
- */
- public void dispose() {
- super.dispose();
- if (getCommandStack() != null) {
- getCommandStack().removeCommandStackListener(
- getCommandStackListener());
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#setInput(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public void setInput(IWorkbenchPart part, ISelection selection) {
- if (part != null) {
- if (part.getAdapter(CommandStack.class) != null) {
- setCommandStack((CommandStack) part
- .getAdapter(CommandStack.class));
- }
-
- if (selection instanceof StructuredSelection) {
- StructuredSelection structuredSelection = (StructuredSelection) selection;
- if (structuredSelection.getFirstElement() instanceof EditPart) {
- editPart = (EditPart) structuredSelection.getFirstElement();
- }
-
- if (editPart != null
- && ((IAdaptable) editPart)
- .getAdapter(IPropertySource.class) != null) {
- propertySource = (IPropertySource) ((IAdaptable) editPart)
- .getAdapter(IPropertySource.class);
- }
-
- }
- }
-
- super.setInput(part, selection);
- }
-
- /**
- * get the commandstacklistener, if not existed, create a new one.
- *
- * @return
- */
- private CommandStackListener getCommandStackListener() {
- if (commandStackListener == null) {
- commandStackListener = new CommandStackListener() {
- public void commandStackChanged(EventObject e) {
- refreshData();
- }
- };
- }
- return commandStackListener;
- }
-
- /**
- * set a <code>CommandStack</code> forthis section, and add a
- * <code>CommandStackListener</code> for this commandstack
- *
- * @param stack
- */
- public void setCommandStack(CommandStack stack) {
- commandStack = stack;
- stack.addCommandStackListener(getCommandStackListener());
- }
-
- /**
- * get the <code>CommandStack</code>
- *
- * @return the command stack
- */
- public CommandStack getCommandStack() {
- return commandStack;
- }
-
- /**
- * get the property source registered for current editpart
- *
- * @return the property source
- */
- public IPropertySource getPropertySource() {
- return propertySource;
- }
-
- /**
- * get the property's EMF featureID based on property name.
- *
- * @param propertyName
- * @return the feature id for propertyName
- */
- protected Object getFeatureID(String propertyName) {
- if (editPart != null && !(editPart.getModel() instanceof EObject)) {
- return null;
- }
-
- Object propertyID = getPropertyRegistry().get(propertyName);
- if (propertyID == null) {
-
- EClass cls = ((EObject) editPart.getModel()).eClass();
- for (Iterator it = cls.getEAllAttributes().iterator(); it.hasNext();) {
- EAttribute attr = (EAttribute) it.next();
- if (attr.getName().equalsIgnoreCase(propertyName)) {
- propertyID = Integer.toString(attr.getFeatureID());
- getPropertyRegistry().put(propertyName, propertyID);
- break;
- }
- }
- }
- return propertyID;
- }
-
- /**
- * @return the property registry
- */
- protected Map getPropertyRegistry() {
- if (propertyRegistry == null) {
- propertyRegistry = new HashMap();
- }
- return propertyRegistry;
- }
-
- /**
- * get the input edit part
- *
- * @return the input
- */
- public Object getInput() {
- return editPart;
- }
-
- /**
- * set the value of property
- *
- * @param propertyName
- * @param propertyValue
- */
- public void setValue(String propertyName, Object propertyValue) {
- if (propertyName != null && propertyValue != null
- && getPropertySource() != null) {
- SetPropertyValueCommand setCommand = new SetPropertyValueCommand(
- propertyName);
- setCommand.setTarget(getPropertySource());
- setCommand.setPropertyId(getFeatureID(propertyName));
- setCommand.setPropertyValue(propertyValue);
- if (getCommandStack() != null) {
- getCommandStack().execute(setCommand);
- } else {
- setCommand.execute();
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorGroup.java
deleted file mode 100644
index dd6bea929..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorGroup.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author jchoi
- * @version
- */
-/*package*/ class EditorGroup extends AbstractEditPartGroup {
- private Pageflow pageflow = null;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- super.initialize();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#refreshData()
- */
- public void refreshData() {
- if (pageflow != null) {
- super.refreshData(pageflow);
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- Composite top;
- if (toolkit == null) {
- top = new Composite(parent, SWT.NONE);
- } else {
- top = toolkit.createComposite(parent);
- }
- FillLayout fillLayout = new FillLayout(SWT.VERTICAL);
- parent.setLayout(fillLayout);
-
- GridLayout layout = new GridLayout();
- layout.numColumns = 3;
- top.setLayout(layout);
-
- Label separator = toolkit.createSeparator(top, SWT.HORIZONTAL);
- GridData data = new GridData(GridData.FILL_HORIZONTAL);
- data.horizontalSpan = 3;
- separator.setLayoutData(data);
- super.layoutDialogFields(toolkit, top, 3);
-
- }
-
- /**
- * @param elem
- */
- public void setPropertyProvider(Pageflow elem) {
- pageflow = elem;
- this.refreshData();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorSection.java
deleted file mode 100644
index 1b9d62cd8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/EditorSection.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory;
-
-/**
- * Edit section for Pagflow (EditPart)
- *
- * @author jchoi, Xiao-guang Zhang
- */
-public class EditorSection extends AbstractEditPartSection {
- /** edit group */
- private EditorGroup group;
-
- /** the emf model for Pageflow */
- private Pageflow pageflow;
-
- /**
- *
- */
- public EditorSection() {
- super();
- group = new EditorGroup();
- group.setDefaultChangeListener(changeListener);
- group.initialize();
-
- group.getDisplayNameField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- EditorSection.this.setValue(
- PageflowPackageImpl.eINSTANCE
- .getPageflowElement_Name().getName(),
- group.getDisplayNameField().getText());
- }
- });
-
- group.getDescField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- EditorSection.this
- .setValue(
- PageflowPackageImpl.eINSTANCE
- .getPageflowElement_Comment()
- .getName(), group
- .getDescField().getText());
- }
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#createControls(org.eclipse.swt.widgets.Composite,
- * org.eclipse.wst.common.ui.properties.internal.provisional.TabbedPropertySheetPage)
- */
- public void createControls(Composite parent,
- TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
- TabbedPropertySheetWidgetFactory factory = aTabbedPropertySheetPage
- .getWidgetFactory();
- Composite top = factory.createFlatFormComposite(parent);
-
- group.layoutDialogFields(factory, top);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#setInput(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
-
- if (getInput() != null && getInput() instanceof PageflowEditPart) {
- Object model = ((PageflowEditPart) getInput()).getModel();
- if (model instanceof Pageflow) {
- pageflow = (Pageflow) model;
- refreshData();
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.properties.sections.AbstractEditPartSection#refreshData()
- */
- public void refreshData() {
- super.refreshData();
- group.setPropertyProvider(pageflow);
- }
-
- public void validate() {
- // do nothing.
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkGroup.java
deleted file mode 100644
index bfe0d8732..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkGroup.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ComboDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IStringButtonAdapter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.ActionOutcomeSelectionDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.ITabbedPropertiesConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PropertyMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author jchoi
- * @version
- */
-/*package*/ class LinkGroup extends AbstractEditPartGroup {
- private StringButtonDialogField fromOutcomeField;
-
- private StringDialogField fromActionField;
-
- private ComboDialogField redirectField;
-
- private PageflowLink pfLink;
-
- /** Integer value for boolean type */
- private static final Integer P_VALUE_TRUE = new Integer(0);
-
- private static final Integer P_VALUE_FALSE = new Integer(1);
-
- private class StringButtonAdapter implements IStringButtonAdapter {
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.IStringButtonAdapter#changeControlPressed(org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogField)
- */
- public void changeControlPressed(DialogField field) {
- String outcome = ""; //$NON-NLS-1$
- String jspPage = ""; //$NON-NLS-1$
- Shell shell = field.getLabelControl(null, null).getShell();
- if (pfLink != null) {
- outcome = pfLink.getOutcome();
- jspPage = WebrootUtil.getProjectPath(pfLink,
- getPreviousJSPPath(pfLink));
- ActionOutcomeSelectionDialog actionDialog = new ActionOutcomeSelectionDialog(
- shell, outcome, jspPage);
- if (actionDialog.open() == Window.OK) {
- outcome = actionDialog.getSelectedAction();
- fromOutcomeField.setText(outcome);
- pfLink.setOutcome(outcome);
- refreshData();
- }
- }
- }
-
- /**
- * @param _element
- * @return
- */
- private String getPreviousJSPPath(PageflowElement element) {
- String jspPath = null;
- if (element instanceof PageflowLink) {
- PageflowNode source = ((PageflowLink) element).getSource();
- if (source instanceof PageflowPage) {
- jspPath = ((PageflowPage) source).getPath();
- }
- }
- return jspPath;
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- fromOutcomeField = new StringButtonDialogField(
- new StringButtonAdapter());
- fromOutcomeField.setLabelText(PropertyMessages.property_fromOutcome);
- fromOutcomeField.setButtonLabel(PropertyMessages.property_browseButton);
- fromOutcomeField
- .setDialogFieldChangeListener(getDefaultChangeListener());
- fromActionField = new StringDialogField();
- fromActionField.setLabelText(PropertyMessages.property_fromAction);
- fromActionField
- .setDialogFieldChangeListener(getDefaultChangeListener());
- redirectField = new ComboDialogField(SWT.DROP_DOWN | SWT.READ_ONLY);
- redirectField.setLabelText(PropertyMessages.property_redirect);
- redirectField
- .setDialogFieldChangeListener((getDefaultChangeListener()));
- List redirectList;
- redirectList = new ArrayList();
- redirectList.add(Boolean.TRUE.toString());
- redirectList.add(Boolean.FALSE.toString());
- redirectField.setItems((String[]) redirectList.toArray(new String[0]));
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#refreshData()
- */
- public void refreshData() {
- if (pfLink != null) {
- fromOutcomeField.setTextWithoutUpdate(pfLink.getOutcome());
- fromActionField.setTextWithoutUpdate(pfLink.getFromaction());
- if (pfLink.isRedirect()) {
- redirectField.setTextWithoutUpdate(Boolean.TRUE.toString());
- } else {
- redirectField.setTextWithoutUpdate(Boolean.FALSE.toString());
- }
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- Composite top;
- if (toolkit == null) {
- top = new Composite(parent, SWT.NONE);
- } else {
- top = toolkit.createComposite(parent);
- }
- FillLayout fillLayout = new FillLayout(SWT.VERTICAL);
- parent.setLayout(fillLayout);
-
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- top.setLayout(layout);
-
- fromActionField.doFillIntoGrid(toolkit, top, numberOfColumns);
- fromOutcomeField.doFillIntoGrid(toolkit, top, numberOfColumns);
- redirectField.doFillIntoGrid(toolkit, top, numberOfColumns);
-
- LayoutUtil.setHorizontalGrabbing(fromOutcomeField.getTextControl(
- toolkit, top));
- GridData data = new GridData();
- data.widthHint = ITabbedPropertiesConstants.BROWSE_WIDTH;
- data.heightHint = ITabbedPropertiesConstants.BROWSE_HEIGHT;
-
- fromOutcomeField.getChangeControl(toolkit, top).setLayoutData(data);
-
- }
-
- /**
- * @param elem
- */
- public void setPropertyProvider(PageflowLink elem) {
- pfLink = elem;
- this.refreshData();
- }
-
- /**
- * @return the outcome field
- */
- public StringButtonDialogField getFromOutcomeField() {
- return fromOutcomeField;
- }
-
- /**
- * @return the fromAction field
- */
- public StringDialogField getFromActionField() {
- return fromActionField;
- }
-
- /**
- * @return the redirect field
- */
- public ComboDialogField getRedirectField() {
- return redirectField;
- }
-
- /**
- * @return the redirect value
- */
- public Integer getRedirectValue() {
- if (redirectField.getText().equalsIgnoreCase(Boolean.TRUE.toString())) {
- return LinkGroup.P_VALUE_TRUE;
- }
- return LinkGroup.P_VALUE_FALSE;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkSection.java
deleted file mode 100644
index c6b0dce56..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/LinkSection.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowLinkEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory;
-
-/**
- * Edit section for Pagflow Link element (EditPart)
- *
- * @author jchoi
- */
-public class LinkSection extends AbstractEditPartSection {
- /** edit group */
- private LinkGroup group;
-
- /** the emf model for Pageflow link */
- private PageflowLink pfLink;
-
- /**
- *
- */
- public LinkSection() {
- super();
- group = new LinkGroup();
- group.setDefaultChangeListener(changeListener);
- group.initialize();
-
- group.getFromOutcomeField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- LinkSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPFLink_Outcome().getName(), group
- .getFromOutcomeField().getText());
- }
- });
-
- group.getRedirectField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- LinkSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPFLink_Redirect().getName(), group
- .getRedirectValue());
- }
- });
- group.getFromActionField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- LinkSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPFLink_Fromaction().getName(), group
- .getFromActionField().getText());
- }
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#createControls(org.eclipse.swt.widgets.Composite,
- * org.eclipse.wst.common.ui.properties.internal.provisional.TabbedPropertySheetPage)
- */
- public void createControls(Composite parent,
- TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
- TabbedPropertySheetWidgetFactory factory = aTabbedPropertySheetPage
- .getWidgetFactory();
- Composite top = factory.createFlatFormComposite(parent);
-
- group.layoutDialogFields(factory, top);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#setInput(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
-
- if (getInput() != null && getInput() instanceof PageflowLinkEditPart) {
- Object model = ((PageflowLinkEditPart) getInput()).getModel();
- if (model instanceof PageflowLink) {
- pfLink = (PageflowLink) model;
- if (PageflowValidation.getInstance().isValidLinkForProperty(
- pfLink)) {
- refreshData();
- }
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.properties.sections.AbstractEditPartSection#refreshData()
- */
- public void refreshData() {
- super.refresh();
- group.setPropertyProvider(pfLink);
- }
-
- public void validate() {
- // do nothing
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageGroup.java
deleted file mode 100644
index 6d3252bc0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageGroup.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IStringButtonAdapter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.ITabbedPropertiesConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.ProjectWebPageSelectionDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PropertyMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author jchoi
- * @version
- */
-/*package*/ class PageGroup extends AbstractEditPartGroup {
-
- private StringButtonDialogField fromViewField;
-
- private PageflowPage pfPage = null;
-
- private StringDialogField largeIconField;
-
- private StringDialogField smallIconField;
-
- class StringButtonAdapter implements IStringButtonAdapter {
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.IStringButtonAdapter#changeControlPressed(org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogField)
- */
- public void changeControlPressed(DialogField field) {
- IProject project = WebrootUtil.getProject(pfPage);
- ProjectWebPageSelectionDialog dlg = new ProjectWebPageSelectionDialog(
- field.getLabelControl(null, null).getShell(), project);
- if (dlg.open() == Window.OK) {
- fromViewField.setText(dlg.getResultFilePath());
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- fromViewField = new StringButtonDialogField(new StringButtonAdapter());
- fromViewField.setLabelText(PropertyMessages.property_fromView);
- fromViewField.setButtonLabel(PropertyMessages.property_browseButton);
- fromViewField.setDialogFieldChangeListener(getDefaultChangeListener());
-
- largeIconField = new StringDialogField();
- largeIconField.setLabelText(PropertyMessages.property_largeIcon);
- largeIconField
- .setDialogFieldChangeListener((getDefaultChangeListener()));
- smallIconField = new StringDialogField();
- smallIconField.setLabelText(PropertyMessages.property_smallIcon);
- smallIconField
- .setDialogFieldChangeListener((getDefaultChangeListener()));
- super.initialize();
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#refreshData()
- */
- public void refreshData() {
- if (pfPage != null) {
- fromViewField.setTextWithoutUpdate(assertString(pfPage.getPath()));
- largeIconField.setTextWithoutUpdate(assertString(pfPage
- .getLargeicon()));
- smallIconField.setTextWithoutUpdate(assertString(pfPage
- .getSmallicon()));
- super.refreshData(pfPage);
-
- }
-
- }
- /**
- * @param value
- * @return the assertion string
- */
- private static String assertString(String value) {
- return value == null ? "" : value; //$NON-NLS-1$
- }
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- Composite top;
- if (toolkit == null) {
- top = new Composite(parent, SWT.NONE);
- } else {
- top = toolkit.createComposite(parent);
- }
- FillLayout fillLayout = new FillLayout(SWT.VERTICAL);
- parent.setLayout(fillLayout);
-
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- top.setLayout(layout);
-
- fromViewField.doFillIntoGrid(toolkit, top, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(fromViewField.getTextControl(toolkit,
- top));
- largeIconField.doFillIntoGrid(toolkit, top, numberOfColumns);
- smallIconField.doFillIntoGrid(toolkit, top, numberOfColumns);
- super.layoutDialogFields(toolkit, top, 4);
-
- GridData data = new GridData();
- data.widthHint = ITabbedPropertiesConstants.BROWSE_WIDTH;
- data.heightHint = ITabbedPropertiesConstants.BROWSE_HEIGHT;
-
- fromViewField.getChangeControl(toolkit, top).setLayoutData(data);
- }
-
- /**
- * @param elem
- */
- public void setPropertyProvider(PageflowPage elem) {
- pfPage = elem;
- this.refreshData();
- }
-
- /**
- * @return the fromView field
- */
- public StringButtonDialogField getFromViewField() {
- return fromViewField;
- }
-
- /**
- * @return the large icon field
- */
- public StringDialogField getLargeIconField() {
- return largeIconField;
- }
-
- /**
- * @return the small icon field
- */
- public StringDialogField getSmallIconField() {
- return smallIconField;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageSection.java
deleted file mode 100644
index 5a0920355..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/PageSection.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowValidation;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory;
-
-/**
- * Edit section for Pagflow Page Element (EditPart)
- *
- * @author jchoi, Xiao-guang Zhang
- */
-public class PageSection extends AbstractEditPartSection {
- /** edit group */
- private PageGroup group;
-
- /** the emf model for Pageflow page */
- private PageflowPage pfPage = null;
-
- /**
- *
- */
- public PageSection() {
- super();
- group = new PageGroup();
- group.setDefaultChangeListener(changeListener);
- group.initialize();
-
- group.getFromViewField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- if (pfPage != null) {
- String jsfNew = group.getFromViewField().getText();
- if (jsfNew != null && jsfNew.length() > 0) {
- if (PageflowValidation.getInstance()
- .isExistedPage(pfPage.getPageflow(),
- jsfNew)) {
- // Pageflow.PageflowEditor.Alert.DNDResourceTitle
- // = Pageflow Creation Error
- // Pageflow.PageflowEditor.Alert.ExistingPage
- // = The web page {0} is already existed in
- // current PageFlow.
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.PageflowEditor.Alert.DNDResourceTitle", //$NON-NLS-1$
- "Pageflow.PageflowEditor.Alert.ExistingPage", //$NON-NLS-1$
- jsfNew);
- } else {
- PageSection.this
- .setValue(
- PageflowPackageImpl.eINSTANCE
- .getPFPage_Path()
- .getName(), jsfNew);
- }
- }
- }
- }
- });
-
- group.getLargeIconField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- PageSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPFPage_Largeicon().getName(), group
- .getLargeIconField().getText());
- }
- });
- group.getSmallIconField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- PageSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPFPage_Smallicon().getName(), group
- .getSmallIconField().getText());
- }
- });
-
- group.getDescField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- PageSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPageflowElement_Comment().getName(), group
- .getDescField().getText());
- }
- });
-
- group.getDisplayNameField().setDialogFieldApplyListener(
- new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- PageSection.this.setValue(PageflowPackageImpl.eINSTANCE
- .getPageflowElement_Name().getName(), group
- .getDisplayNameField().getText());
- }
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#createControls(org.eclipse.swt.widgets.Composite,
- * org.eclipse.wst.common.ui.properties.internal.provisional.TabbedPropertySheetPage)
- */
- public void createControls(Composite parent,
- TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
- TabbedPropertySheetWidgetFactory factory = aTabbedPropertySheetPage
- .getWidgetFactory();
- Composite top = factory.createFlatFormComposite(parent);
-
- group.layoutDialogFields(factory, top);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.ui.properties.internal.provisional.ISection#setInput(org.eclipse.ui.IWorkbenchPart,
- * org.eclipse.jface.viewers.ISelection)
- */
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
-
- if (getInput() != null && getInput() instanceof PageflowNodeEditPart) {
- Object model = ((PageflowNodeEditPart) getInput()).getModel();
- if (model instanceof PageflowPage) {
- pfPage = (PageflowPage) model;
- refreshData();
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.properties.sections.AbstractEditPartSection#refreshData()
- */
- public void refreshData() {
- super.refreshData();
- group.setPropertyProvider(pfPage);
- }
-
- public void validate() {
- // do nothing
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/SetPropertyValueCommand.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/SetPropertyValueCommand.java
deleted file mode 100644
index 96d227628..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/properties/section/SetPropertyValueCommand.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.section;
-
-import java.text.MessageFormat;
-
-import org.eclipse.gef.commands.Command;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.properties.PropertyMessages;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/*package*/ class SetPropertyValueCommand extends Command {
-
- private Object propertyValue;
-
- private Object propertyID;
-
- private Object undoValue;
-
- private boolean resetOnUndo;
-
- private IPropertySource target;
-
- /**
- * @param propLabel
- */
- public SetPropertyValueCommand(String propLabel) {
- super(MessageFormat.format(
- PropertyMessages.property_Command_SetValue,
- new Object[] { propLabel }).trim());
- }
-
- public boolean canExecute() {
- return true;
- }
-
- public void execute() {
- boolean wasPropertySet = getTarget().isPropertySet(propertyID);
- undoValue = getTarget().getPropertyValue(propertyID);
- if (undoValue instanceof IPropertySource) {
- undoValue = ((IPropertySource) undoValue).getEditableValue();
- }
- if (propertyValue instanceof IPropertySource) {
- propertyValue = ((IPropertySource) propertyValue)
- .getEditableValue();
- }
- getTarget().setPropertyValue(propertyID, propertyValue);
- resetOnUndo = wasPropertySet != getTarget().isPropertySet(propertyID);
- if (resetOnUndo) {
- undoValue = null;
- }
- }
-
- /**
- * @return the target
- */
- private IPropertySource getTarget() {
- return target;
- }
-
- void setTarget(IPropertySource aTarget) {
- target = aTarget;
- }
-
- public void redo() {
- execute();
- }
-
- void setPropertyId(Object pName) {
- propertyID = pName;
- }
-
- void setPropertyValue(Object val) {
- propertyValue = val;
- }
-
- public void undo() {
- if (resetOnUndo) {
- getTarget().resetPropertyValue(propertyID);
- } else {
- getTarget().setPropertyValue(propertyID, undoValue);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFSynchronizer.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFSynchronizer.java
deleted file mode 100644
index 2cc7a136c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFSynchronizer.java
+++ /dev/null
@@ -1,271 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FromViewIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.emf.ToViewIdType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-
-/**
- * The adapter that listens to modification of faces-config and updates pageflow
- * as needed.
- *
- * @author hmeng
- *
- */
-
-public class FC2PFSynchronizer extends AdapterImpl {
- private final boolean DEBUG = false;
-
- FC2PFTransformer transformer;
-
- private static final Logger logger = EditorPlugin
- .getLogger(FC2PFSynchronizer.class);
-
- /**
- * @param transformer
- */
- public FC2PFSynchronizer(FC2PFTransformer transformer) {
- this.transformer = transformer;
- }
-
- public Notifier getTarget() {
- // can't set target so return null
- return null;
- }
-
- public void setTarget(Notifier newTarget) {
- // do nothing
- }
-
- public boolean isAdapterForType(Object type) {
- return type == FC2PFSynchronizer.class;
- }
-
- public void notifyChanged(Notification notification) {
- if (!isProcessorFor(notification)) {
- return;
- }
- transformer.setInEvent(true);
- try {
- int type = notification.getEventType();
- switch (type) {
- case Notification.ADD: {
- processAdd(notification);
- notifyPageflow(notification);
- break;
- }
- case Notification.SET: {
- processSet(notification);
- notifyPageflow(notification);
- break;
- }
- case Notification.REMOVE:
- processRemove(notification);
- notifyPageflow(notification);
- break;
- }
- } catch (Exception e) {
- logger.error(e);
- } finally {
- if (notification.getEventType() != Notification.REMOVING_ADAPTER) {
- transformer.refreshFCAdapter((EObject) notification
- .getNotifier());
- transformer.refreshPFAdapter(transformer.getPageflow());
- }
- transformer.setInEvent(false);
- }
- }
-
- private boolean isProcessorFor(Notification notification) {
- boolean result = false;
- if (transformer.isListenToNotify()
- && (notification.getNotifier() instanceof EObject)) {
- if (notification.getNotifier() == transformer.getFacesConfig()) {
- // For faces-config, only navigation rule's change is awared.
- if (notification.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_NavigationRule()) {
- result = true;
- }
- } else {
- result = true;
- }
- }
- return result;
- }
-
- private void processAdd(Notification notification) {
- Object feature = notification.getFeature();
- if (feature == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_NavigationCase()) {
- if (DEBUG)
- System.out.println("New navigation case"); //$NON-NLS-1$
- NavigationCaseType newCase = (NavigationCaseType) notification
- .getNewValue();
- transformer.updatePageflowElements(transformer.getPageflow(),
- newCase);
- } else if (feature == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_NavigationRule()) {
- NavigationRuleType newRule = (NavigationRuleType) notification
- .getNewValue();
- if (newRule.getNavigationCase().size() > 0) {
- for (int i = 0; i < newRule.getNavigationCase().size(); i++) {
- transformer.updatePageflowElements(transformer
- .getPageflow(), (NavigationCaseType) newRule
- .getNavigationCase().get(i));
- }
- }
- if (DEBUG)
- System.out.println("New navigation rule"); //$NON-NLS-1$
- } else if (DEBUG)
- System.out.println("Something is added"); //$NON-NLS-1$
- }
-
- /**
- * Notify pageflow the changes.
- *
- * @param notification
- */
- private void notifyPageflow(Notification notification) {
- Assert.isTrue(notification.getNotifier() instanceof InternalEObject);
- transformer.getPageflow().notifyModelChanged(
- new ENotificationImpl((InternalEObject) notification
- .getNotifier(), Notification.SET,
- PageflowPackage.PAGEFLOW, null, null));
- }
-
- /**
- * Deal with the case when some element is removed.
- *
- * @param notification
- */
- private void processRemove(Notification notification) {
- if (notification.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_NavigationCase()) {
- if (notification.getOldValue() instanceof NavigationCaseType) {
- NavigationCaseType caseType = (NavigationCaseType) notification
- .getOldValue();
- transformer.removeLink(caseType);
- }
- if (DEBUG)
- System.out.println("Navigation case"); //$NON-NLS-1$
- } else if (notification.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationCaseType()) {
- if (notification.getOldValue() instanceof NavigationRuleType) {
- NavigationRuleType rule = (NavigationRuleType) notification
- .getOldValue();
- for (int i = 0; i < rule.getNavigationCase().size(); i++) {
- NavigationCaseType caseType = (NavigationCaseType) rule
- .getNavigationCase().get(i);
- transformer.refreshLink(caseType);
- }
- }
- if (DEBUG)
- System.out.println("navigation rule"); //$NON-NLS-1$
- } else if (notification.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_NavigationRule()) {
- if (notification.getOldValue() instanceof NavigationRuleType) {
- NavigationRuleType rule = (NavigationRuleType) notification
- .getOldValue();
- for (int i = 0; i < rule.getNavigationCase().size(); i++) {
- NavigationCaseType caseType = (NavigationCaseType) rule
- .getNavigationCase().get(i);
- transformer.refreshLink(caseType);
- }
- }
- }
- if (DEBUG)
- System.out.println("Something is removed"); //$NON-NLS-1$
- }
-
- /**
- * Deal with property change.
- *
- * @param notification
- */
- private void processSet(Notification notification) {
- Object feature = notification.getFeature();
- if (feature == FacesConfigPackage.eINSTANCE
- .getFromViewIdType_TextContent()
- || feature == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_FromViewId()) {
- fromViewIdChanged(notification);
- } else if (feature == FacesConfigPackage.eINSTANCE
- .getToViewIdType_TextContent()
- || feature == FacesConfigPackage.eINSTANCE
- .getNavigationCaseType_ToViewId()) {
- toViewIdChanged(notification);
- }
- if (DEBUG)
- System.out.println("Something is set"); //$NON-NLS-1$
- }
-
- private void fromViewIdChanged(Notification notification) {
- // remove
- Object feature = notification.getFeature();
- if (feature == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_FromViewId()
- && notification.getNewValue() == null
- && notification.getOldValue() instanceof FromViewIdType) {
- NavigationRuleType rule = (NavigationRuleType) notification
- .getNotifier();
- for (int i = 0; i < rule.getNavigationCase().size(); i++) {
- NavigationCaseType caseType = (NavigationCaseType) rule
- .getNavigationCase().get(i);
- transformer.refreshLink(caseType);
- }
- }
- // add or change
- else if (feature == FacesConfigPackage.eINSTANCE
- .getFromViewIdType_TextContent()) {
- NavigationRuleType rule = (NavigationRuleType) ((EObject) notification
- .getNotifier()).eContainer();
- for (int i = 0; i < rule.getNavigationCase().size(); i++) {
- NavigationCaseType caseType = (NavigationCaseType) rule
- .getNavigationCase().get(i);
- transformer.refreshLink(caseType);
- }
- }
- }
-
- private void toViewIdChanged(Notification notification) {
- // remove
- Object feature = notification.getFeature();
- if (feature == FacesConfigPackage.eINSTANCE
- .getNavigationCaseType_ToViewId()
- && notification.getNewValue() == null
- && notification.getOldValue() instanceof ToViewIdType) {
- NavigationCaseType caseType = (NavigationCaseType) notification
- .getNotifier();
- transformer.refreshLink(caseType);
- }
- // add or change
- else if (feature == FacesConfigPackage.eINSTANCE
- .getToViewIdType_TextContent()) {
- NavigationCaseType caseType = (NavigationCaseType) ((EObject) notification
- .getNotifier()).eContainer();
- transformer.refreshLink(caseType);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFTransformer.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFTransformer.java
deleted file mode 100644
index e2a9fb08e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/FC2PFTransformer.java
+++ /dev/null
@@ -1,983 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;
-
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.common.util.TreeIterator;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.FromViewIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.IconType;
-import org.eclipse.jst.jsf.facesconfig.emf.LargeIconType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.emf.SmallIconType;
-import org.eclipse.jst.jsf.facesconfig.emf.ToViewIdType;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageReferenceElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.ReferenceElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowModelManager;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.util.PageflowTransform;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-
-/**
- * Update and synchronize pageflow from faces-config or vice-versa.
- *
- * @author hmeng
- *
- */
-
-public class FC2PFTransformer extends AdapterImpl {
-
- // For code debug.
- private static final boolean DEBUG = false;
-
- /**
- * the first notification event type after the defaults
- */
- public static final int MY_NOTIFICATION_TYPE = Notification.EVENT_TYPE_COUNT + 1;
-
- /**
- * the first notification event type after MY_NOTIFICATION_TYPE
- */
- public static final int MY_NOTIFICATION_TYPE1 = MY_NOTIFICATION_TYPE + 1;
-
- /**
- * The listener is active.
- */
- private boolean listenToNotify;
-
- /**
- * Avoid redundent event.
- */
- private boolean isInEvent;
-
- boolean pageflowChanged = false;
-
- /**
- * Perform operations batched.
- */
- boolean needBatchOperations = false;
-
- /**
- * Catches
- */
- private Map mapPaths2PF = new HashMap();
-
- private Map mapCases2Links = new HashMap();
-
- /**
- * The pageflow model.
- */
- private Pageflow pageflow;
-
- /**
- * The faces-config model.
- */
- FacesConfigType facesConfig;
-
- /**
- * Default constructor
- */
- public FC2PFTransformer() {
- super();
- // TODO Auto-generated constructor stub
- }
-
- /**
- * @param listenToNotify
- */
- public void setListenToNotify(boolean listenToNotify) {
- this.listenToNotify = listenToNotify;
- }
-
- private void postEMFChanged() {
- startFCNotify();
- // Refresh all facesConfig?
- facesConfig.eNotify(new ENotificationImpl(
- (InternalEObject) facesConfig, Notification.REMOVE,
- FacesConfigPackage.FACES_CONFIG_TYPE__NAVIGATION_RULE, null,
- null));
- List rules;
- rules = facesConfig.getNavigationRule();
- for (int i = 0; i < rules.size(); i++) {
- ((NavigationRuleType) rules.get(i)).eNotify(new ENotificationImpl(
- (InternalEObject) rules.get(i), Notification.REMOVE,
- FacesConfigPackage.NAVIGATION_RULE_TYPE__NAVIGATION_CASE,
- null, null));
- }
- }
-
- /**
- * Set notify adapters.
- *
- */
- private void startFCNotify() {
- TreeIterator iterator = facesConfig.eAllContents();
- while (iterator.hasNext()) {
- EObject object = (EObject) iterator.next();
- object.eSetDeliver(true);
- }
- facesConfig.eSetDeliver(true);
- }
-
- /**
- * Set not notify adapters
- *
- * @return
- */
- private TreeIterator stopFCNotify() {
- TreeIterator iterator = facesConfig.eAllContents();
- // Stop the listener
- while (iterator.hasNext()) {
- EObject object = (EObject) iterator.next();
- object.eSetDeliver(false);
- }
- facesConfig.eSetDeliver(false);
- return iterator;
- }
-
- /**
- * For performance issue, we are going to update DOM only after the EMF
- * modifications are done.
- */
- boolean isNeedBatchOperations() {
- return needBatchOperations;
- }
-
- /**
- * @param enable
- */
- public void setNeedBatchOperations(boolean enable) {
- this.needBatchOperations = enable;
- if (!enable) {
- isInEvent = true;
- postEMFChanged();
- isInEvent = false;
- } else {
- stopFCNotify();
- }
- }
-
- private void updateFacesRule(NavigationRuleType navigationRule,
- PageflowPage pageSource) {
- FacesConfigFactory factory = FacesConfigFactory.eINSTANCE;
- if (pageSource.getComment() != null) {
- DescriptionType description = factory.createDescriptionType();
- description.setTextContent(pageSource.getComment());
- navigationRule.getDescription().clear();
- navigationRule.getDescription().add(description);
- }
- // set the navigation rule's icon
- if (pageSource.getLargeicon() != null
- || pageSource.getSmallicon() != null) {
- IconType icon = factory.createIconType();
- if (pageSource.getLargeicon() != null) {
- LargeIconType largeicon = factory.createLargeIconType();
- largeicon.setTextContent(pageSource.getLargeicon());
- icon.setLargeIcon(largeicon);
- }
-
- if (pageSource.getSmallicon() != null) {
- SmallIconType smallicon = factory.createSmallIconType();
- smallicon.setTextContent(pageSource.getSmallicon());
- icon.setSmallIcon(smallicon);
- }
- navigationRule.getIcon().clear();
- navigationRule.getIcon().add(icon);
- }
- if (pageSource.getName() != null) {
- DisplayNameType displayName = factory.createDisplayNameType();
- displayName.setTextContent(pageSource.getName());
- navigationRule.getDisplayName().clear();
- navigationRule.getDisplayName().add(displayName);
- }
- }
-
- /**
- * TODO: If we cache the case's properties in a link, then we can restore
- * them.
- *
- * @param navigationCase
- * @param link
- */
- // TODO: not used, dead?
-// private void updateFacesCase(NavigationCaseType navigationCase,
-// PageflowLink link) {
-// FacesConfigFactory factory = FacesConfigFactory.eINSTANCE;
-// if (link.getComment() != null) {
-// DescriptionType description = factory.createDescriptionType();
-// description.setTextContent(link.getComment());
-// navigationCase.getDescription().clear();
-// navigationCase.getDescription().add(description);
-// }
-// // set the navigation rule's icon
-// if (link.getLargeicon() != null || link.getSmallicon() != null) {
-// IconType icon = factory.createIconType();
-// if (link.getLargeicon() != null) {
-// LargeIconType largeicon = factory.createLargeIconType();
-// largeicon.setTextContent(link.getLargeicon());
-// icon.setLargeIcon(largeicon);
-// }
-//
-// if (link.getSmallicon() != null) {
-// SmallIconType smallicon = factory.createSmallIconType();
-// smallicon.setTextContent(link.getSmallicon());
-// icon.setSmallIcon(smallicon);
-// }
-// navigationCase.getIcon().clear();
-// navigationCase.getIcon().add(icon);
-// }
-// if (link.getFromaction() != null) {
-// FromActionType fromAction = factory.createFromActionType();
-// fromAction.setTextContent(link.getFromaction());
-// navigationCase.setFromAction(fromAction);
-// }
-// if (link.getOutcome() != null) {
-// FromOutcomeType fromOutcome = factory.createFromOutcomeType();
-// fromOutcome.setTextContent(link.getOutcome());
-// navigationCase.setFromOutcome(fromOutcome);
-// }
-// }
-
- private void createFacesCase(PageflowLink link, PageflowPage source,
- PageflowPage target_) {
- NavigationRuleType rule = FacesConfigFactory.eINSTANCE
- .createNavigationRuleType();
- FromViewIdType from = FacesConfigFactory.eINSTANCE
- .createFromViewIdType();
- from.setTextContent((source).getPath());
- rule.setFromViewId(from);
- NavigationCaseType navCase = FacesConfigFactory.eINSTANCE
- .createNavigationCaseType();
- ToViewIdType toView = FacesConfigFactory.eINSTANCE.createToViewIdType();
- toView.setTextContent((target_).getPath());
- navCase.setToViewId(toView);
- rule.getNavigationCase().add(navCase);
- facesConfig.getNavigationRule().add(rule);
- updateFacesRule(rule, source);
- source.getFCElements().add(from);
- target_.getFCElements().add(toView);
- link.getFCElements().add(navCase);
- mapCases2Links.put(navCase, link);
- }
-
- private void removePageflowPage(PageflowPage source) {
- Assert.isTrue(source.getOutlinks().size() == 0
- && source.getInlinks().size() == 0);
- pageflow.getNodes().remove(source);
- }
-
- void removeCase(NavigationCaseType navCase) {
- NavigationRuleType rule = (NavigationRuleType) navCase.eContainer();
- (rule).getNavigationCase().remove(navCase);
- if (rule.getNavigationCase().size() == 0) {
- facesConfig.getNavigationRule().remove(rule);
- }
- }
-
- /**
- * Remove a link in pageflow model.
- *
- * @param pLink
- */
- private void removeLink(PageflowLink pLink) {
- // Link
- PageflowPage source = (PageflowPage) pLink.getSource();
- PageflowPage target_ = (PageflowPage) pLink.getTarget();
- pLink.getPageflow().getLinks().remove(pLink);
- source.getOutlinks().remove(pLink);
- target_.getInlinks().remove(pLink);
- // Navigation case
- pLink.getFCElements().clear();
- cleanPage(source);
- cleanPage(target_);
- }
-
- /**
- * Remove a link in pageflow model.
- *
- * @param pLink
- */
- void changePFLinkStart(PageflowLink pLink, String newValue) {
- PageflowPage newPage = null;
- if ((newPage = getValidPFPageInCache(newValue)) != null) {
- if (newValue.equals(((PageflowPage) pLink.getSource()).getPath())) {
- return;
- }
- } else if ((newPage = TransformUtil.findPage(newValue, pageflow)) == null) {
- return;
- }
-
- // remove old case
- NavigationCaseType caseType = (NavigationCaseType) pLink
- .getFCElements().getData().get(0);
- //NavigationRuleType rule = (NavigationRuleType) caseType.eContainer();
- removeCase(caseType);
-
- // create new rule / case
- NavigationCaseType newCase = FacesConfigFactory.eINSTANCE
- .createNavigationCaseType();
- ToViewIdType toView = FacesConfigFactory.eINSTANCE.createToViewIdType();
- toView.setTextContent(caseType.getToViewId().getTextContent());
- newCase.setToViewId(toView);
-
- NavigationRuleType newRule = FacesConfigFactory.eINSTANCE
- .createNavigationRuleType();
- FromViewIdType fromView = FacesConfigFactory.eINSTANCE
- .createFromViewIdType();
- fromView.setTextContent(newValue);
- newRule.setFromViewId(fromView);
- newRule.getNavigationCase().add(newCase);
- facesConfig.getNavigationRule().add(newRule);
-
- // update
- // updateNode(rule, newRule);
- updateNode(caseType, newCase);
-
- pLink.getFCElements().clear();
- pLink.getFCElements().add(newCase);
- pLink.setSource(newPage);
-
- updatePageflowElements(pageflow, newCase);
- }
-
- private void updateNode(EObject old, EObject newOne) {
- if (old instanceof NavigationRuleType) {
- ((NavigationRuleType) newOne).getDescription().clear();
- ((NavigationRuleType) newOne).getDescription().addAll(
- ((NavigationRuleType) old).getDescription());
- ((NavigationRuleType) newOne).getDisplayName().clear();
- ((NavigationRuleType) newOne).getDisplayName().addAll(
- ((NavigationRuleType) old).getDisplayName());
- ((NavigationRuleType) newOne).getDescription().clear();
- ((NavigationRuleType) newOne).getIcon().clear();
- ((NavigationRuleType) newOne).getIcon().addAll(
- ((NavigationRuleType) old).getIcon());
- } else if (old instanceof NavigationCaseType) {
- ((NavigationCaseType) newOne).getDescription().clear();
- ((NavigationCaseType) newOne).getDescription().addAll(
- ((NavigationCaseType) old).getDescription());
- ((NavigationCaseType) newOne).getDisplayName().clear();
- ((NavigationCaseType) newOne).getDisplayName().addAll(
- ((NavigationCaseType) old).getDisplayName());
- ((NavigationCaseType) newOne).getDescription().clear();
- ((NavigationCaseType) newOne).getIcon().clear();
- ((NavigationCaseType) newOne).getIcon().addAll(
- ((NavigationCaseType) old).getIcon());
- ((NavigationCaseType) newOne)
- .setFromAction(((NavigationCaseType) old).getFromAction());
- ((NavigationCaseType) newOne)
- .setFromOutcome(((NavigationCaseType) old).getFromOutcome());
- }
- }
-
- void changePFLinkEnd(PageflowLink pLink, String newValue) {
- PageflowPage newPage = null;
- if ((newPage = getValidPFPageInCache(newValue)) != null) {
- if (newValue.equals(((PageflowPage) pLink.getSource()).getPath())) {
- return;
- }
- } else if ((newPage = TransformUtil.findPage(newValue, pageflow)) == null) {
- return;
- }
-
- // remove old case
- NavigationCaseType caseType = (NavigationCaseType) pLink
- .getFCElements().getData().get(0);
- ToViewIdType toView = caseType.getToViewId(); // FacesConfigFactory.eINSTANCE.createToViewIdType();
- if (toView == null) {
- toView = FacesConfigFactory.eINSTANCE.createToViewIdType();
- }
- toView.setTextContent(newValue);
- caseType.setToViewId(toView);
-
- pLink.setTarget(newPage);
-
- updatePageflowElements(pageflow, caseType);
- }
-
- void removeLink(NavigationCaseType caseType) {
- PageflowLink link = (PageflowLink) mapCases2Links.get(caseType);
- if (link != null) {
- removeLink(link);
- }
- }
-
- void addLink(PageflowPage source, PageflowPage target_, PageflowLink value) {
- if (source != null && target_ != null && value != null) {
- createFacesCase(value, source, target_);
- }
- }
-
- private void cleanPage(PageflowPage source) {
- if (source.getInlinks().size() == 0 && source.getOutlinks().size() == 0) {
- removePageflowPage(source);
- }
- source.update();
- }
-
- void refreshPFAdapter(EObject object) {
- TreeIterator content = object.eAllContents();
- while (content.hasNext()) {
- Object next = content.next();
- adapt((EObject) next);
- }
- adapt(object);
- }
-
- void refreshFCAdapter(EObject object) {
- List rules = facesConfig.getNavigationRule();
- if (rules != null) {
- for (int i = 0; i < rules.size(); i++) {
- NavigationRuleType rule = (NavigationRuleType) rules.get(i);
- adapt(rule);
- TreeIterator children = rule.eAllContents();
- while (children.hasNext()) {
- adapt((EObject) children.next());
- }
- }
- }
- adapt(facesConfig);
- }
-
- /**
- * @param facesConfig
- */
- public void setFacesConfig(FacesConfigType facesConfig) {
- this.facesConfig = facesConfig;
- refreshFCAdapter(facesConfig);
- }
-
- /**
- * @param pageflow
- */
- public void setPageflow(Pageflow pageflow) {
- this.pageflow = pageflow;
- pageflow.eAdapters().add(this);
- refreshPFAdapter(pageflow);
- }
-
- /**
- * Install compatible synchronization adapter for particular object.
- *
- * @param object
- */
- public void adapt(EObject object) {
- if (object != null && !isAdapted(object)) {
- if (object instanceof PageflowElement) {
- object.eAdapters().add(new PF2FCSynchronizer(this));
- } else {
- object.eAdapters().add(new FC2PFSynchronizer(this));
- }
- }
- }
-
- /**
- * Remove the synchronization adapter.
- *
- * @param object
- */
- public void unAdapt(EObject object) {
- Iterator adapters = object.eAdapters().iterator();
- while (adapters.hasNext()) {
- Object adapter = adapters.next();
- if (adapter instanceof FC2PFSynchronizer
- || adapter instanceof PF2FCSynchronizer) {
- adapters.remove();
- }
- }
- }
-
- /**
- * @param object
- * @return true if this transformer adapts object
- */
- public boolean isAdapted(EObject object) {
- if (object != null) {
- Iterator adapters = object.eAdapters().iterator();
- while (adapters.hasNext()) {
- Object adapter = adapters.next();
- if (adapter instanceof FC2PFSynchronizer
- || adapter instanceof PF2FCSynchronizer) {
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * clear the internal maps
- */
- public void clearCaches() {
- mapPaths2PF.clear();
- mapCases2Links.clear();
- }
-
- /**
- * dispose of this object.
- */
- public void dispose() {
- clearCaches();
- Pageflow pageFlow = getPageflow();
-
- if (pageFlow != null)
- {
- pageFlow.dispose();
- }
- }
-
- public Notifier getTarget() {
- return null;
- }
-
- public boolean isAdapterForType(Object type) {
- return false;
- }
-
- public void setTarget(Notifier newTarget) {
- // do nothing
- }
-
- /**
- * @param caseType
- * @return the from view id in caseType
- */
- public static FromViewIdType getSource(NavigationCaseType caseType) {
- if (caseType.eContainer() instanceof NavigationRuleType) {
- NavigationRuleType rule = (NavigationRuleType) caseType
- .eContainer();
- return rule.getFromViewId();
- }
- return null;
- }
-
- private PageflowPage getOrCreateStartPage(NavigationCaseType navCase) {// FromViewIdType
- PageflowPage startPageflowNode = null;
- String path = "*"; //$NON-NLS-1$
- NavigationRuleType rule = (NavigationRuleType) navCase.eContainer();
- FromViewIdType source = getSource(navCase);
- if (source != null) {
- path = source.getTextContent();
- }
- if (getValidPFPageInCache(path) == null) {
- startPageflowNode = TransformUtil.findPage(path, pageflow);
-
- if (startPageflowNode == null) {
- // not exist or is "*"
- if (DEBUG)
- System.out.println("Create new start page"); //$NON-NLS-1$
- startPageflowNode = createPFPage(path);
- pageflowChanged = true;
- }
- mapPaths2PF.put(path, startPageflowNode);
- PageflowTransform.getInstance().updatePageflowSourcePage(
- startPageflowNode, rule);
- } else {
- startPageflowNode = (PageflowPage) mapPaths2PF.get(path);
- }
- if (source != null) {
- ReferenceElement element = new PageReferenceElement(
- startPageflowNode);
- element.add(source);
- startPageflowNode
- .setReferenceLink(element.resolveReferenceString());
- startPageflowNode.getFCElements().add(source);
- }
- return startPageflowNode;
- }
-
- /**
- * Search for an existing pageflow page matching to navigation case's
- * target, if there is no such page existing, create one.
- *
- * @param navCase
- * @return
- */
- private PageflowPage getOrCreateEndPage(NavigationCaseType navCase) {
- PageflowPage endPageflowNode = null;
- ToViewIdType target_ = navCase.getToViewId();
- if (target_ != null) {
- String path = target_.getTextContent();
- if (getValidPFPageInCache(path) == null) {
- endPageflowNode = TransformUtil.findPage(path, pageflow);
- if (endPageflowNode == null) {
- endPageflowNode = createPFPage(path);
- if (DEBUG)
- System.out.println("Create new end page"); //$NON-NLS-1$
- pageflowChanged = true;
- }
- mapPaths2PF.put(path, endPageflowNode);
- PageflowTransform.getInstance().updatePageflowTargetPage(
- endPageflowNode, navCase);
- } else {
- endPageflowNode = (PageflowPage) mapPaths2PF.get(path);
- }
- if (target_ != null) {
- ReferenceElement element = new PageReferenceElement(
- endPageflowNode);
- element.add(target_);
- endPageflowNode.setReferenceLink(element
- .resolveReferenceString());
- endPageflowNode.getFCElements().add(target_);
- }
- }
- return endPageflowNode;
- }
-
- /**
- * Return a valid cached pageflow node.
- *
- * @param key
- * @return
- */
- private PageflowPage getValidPFPageInCache(Object key) {
- EObject element = (EObject) mapPaths2PF.get(key);
- if (!TransformUtil.isValidPageflowElement(element)
- || !(element instanceof PageflowPage)
- || !((PageflowPage) element).getPath().equals(key)) {
- mapPaths2PF.remove(key);
- element = null;
- }
- return (PageflowPage) element;
- }
-
- /**
- * Return a valid cached pageflow link.
- *
- * @param caseType
- * @return
- */
- private PageflowLink getValidPFLinkInCache(EObject caseType) {
- PageflowLink link = (PageflowLink) mapCases2Links.get(caseType);
- if (!TransformUtil.isValidLink(link)) {
- mapCases2Links.remove(caseType);
- link = null;
- }
- return link;
-
- }
-
- /**
- * Update pageflow model elements against faces-config navigation case.
- * @param pageflow_
- * @param caseFC
- * @return true if the pageflow was changed
- */
- public boolean updatePageflowElements(Pageflow pageflow_,
- NavigationCaseType caseFC) {
- this.pageflowChanged = false;
- this.pageflow = pageflow_;
- ToViewIdType target_ = caseFC.getToViewId();
- if (target_ == null) {
- return false;
- }
-
- PageflowPage start = null, end = null;
- // start page
- start = getOrCreateStartPage(caseFC);
- String action = null;
- // action
- if (caseFC.getFromAction() != null) {
- action = caseFC.getFromAction().getTextContent();
- }
- // from outcome
- String fromOutCome = null;
- if (caseFC.getFromOutcome() != null) {
- fromOutCome = caseFC.getFromOutcome().getTextContent();
- }
- // end page
- end = getOrCreateEndPage(caseFC);
- // link
- // Is there a link in pageflow model?
- PageflowLink link = null;
- if ((link = findUnmappedLink(start, end, caseFC)) == null) {
- if (end != null) {
- if (DEBUG)
- System.out.println("Create new link"); //$NON-NLS-1$
- link = createPFLink(start, end, action, fromOutCome);
- pageflowChanged = true;
- }
- }
- if (link != null) {
- link.getFCElements().clear();
- link.getFCElements().add(caseFC);
- mapCases2Links.put(caseFC, link);
- }
- adapt(start);
- adapt(end);
- adapt(caseFC);
- adapt(link);
- return pageflowChanged;
- }
-
- private boolean cleanPageflowNavigationRule(Pageflow pageflow_) {
- boolean dirty = false;
- List links = pageflow_.getLinks();
- Iterator linksIterator = links.iterator();
- while (linksIterator.hasNext()) {
- PageflowLink link = (PageflowLink) linksIterator.next();
- if (link.getFCElements().isEmpty()) {
- linksIterator.remove();
- if (link.getSource() != null) {
- link.getSource().getOutlinks().remove(link);
- }
- if (link.getTarget() != null) {
- link.getTarget().getInlinks().remove(link);
- }
- dirty = true;
- }
- }
- return dirty;
- }
-
- /**
- * merge the two navigation rules list between pageflow and face-config
- * file. merge rule: 1. if the from-view-id, from-action, and from-outcome
- * are same, they are the same navigation case, then the navigation case in
- * face-config file should be updated by one in the pageflow. 2. otherwise
- * the new navigation case should be created.
- *
- * FIXME: Not merge, only update page flow from faces-config.
- *
- * @param rulesFC -
- * navigation rules in faces-config.
- * @param navigationRulesInPageflow -
- * navigation rules in pageflow model.
- *
- * @return boolean - whether add a new rule or not.
- */
- private boolean updateNavigationRulesInPageflowFromFacesConfig(List rulesFC) {
- boolean isNew = false;
- // if the faces-config file is empty, the links should be removed.
- if (rulesFC == null || rulesFC.isEmpty()) {
- for (Iterator iterLink = pageflow.getLinks().iterator(); iterLink
- .hasNext();) {
- PageflowLink link = (PageflowLink) iterLink.next();
- link.getSource().getOutlinks().remove(link);
- link.getTarget().getInlinks().remove(link);
- }
- pageflow.getLinks().clear();
- } else {
- // Rule - Cases
- for (Iterator iterRulesFC = rulesFC.iterator(); iterRulesFC
- .hasNext();) {
- NavigationRuleType ruleFC = (NavigationRuleType) iterRulesFC
- .next();
-
- List casesFC = ruleFC.getNavigationCase();
- for (Iterator iterCasesFC = casesFC.iterator(); iterCasesFC
- .hasNext();) {
- NavigationCaseType navigationCaseFC = (NavigationCaseType) iterCasesFC
- .next();
- isNew |= updatePageflowElements(pageflow, navigationCaseFC);
- }
- }
- }
- isNew |= cleanPageflowNavigationRule(pageflow);
- return isNew;
- }
-
- /**
- * Find a pageflow link that is not linked to a faces-config element. Since
- * user might edit faces-config file with other editor, so the path is not
- * always valid, here we still try to match link and navigation case. TODO:
- * should we always resolve mapping from referenceLink on PageflowElement?
- */
- private PageflowLink findUnmappedLink(PageflowPage start, PageflowPage end,
- NavigationCaseType caseFC) {
- List links = start.getOutlinks();
- for (int i = 0, n = links.size(); i < n; i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- if (link.getSource() == start && link.getTarget() == end) {
- link.update();
- if (link.getFCElements().isEmpty()
- || link.getFCElements().getData().get(0) == caseFC) {
- return link;
- }
- }
- }
- return null;
- }
-
- /**
- * create a new PFLink object according to fromOutcome attribute
- *
- * @param fromOutcome -
- * PFLink's fromOutcome attribute
- * @return - new PFLink object
- */
- public PageflowLink createPFLink(String fromOutcome) {
- PageflowLink link = null;
- link = PageflowModelManager.getFactory().createPFLink();
- if (fromOutcome != null && fromOutcome.length() > 0) {
- link.setOutcome(fromOutcome.trim());
- }
- pageflow.getLinks().add(link);
- return link;
- }
-
- /**
- * create a new PFLink object according to fromOutcome attribute
- * @param start
- * @param target_
- * @param action
- *
- * @param fromOutcome -
- * PFLink's fromOutcome attribute
- * @return - new PFLink object
- */
- public PageflowLink createPFLink(PageflowNode start, PageflowNode target_,
- String action, String fromOutcome) {
- Assert.isTrue(start != null && target_ != null);
- PageflowLink link = null;
- link = createPFLink(fromOutcome);
- link.setFromaction(action);
- link.setSource(start);
- link.setTarget(target_);
- start.getOutlinks().add(link);
- target_.getInlinks().add(link);
- return link;
- }
-
- /**
- * Create a new PFPage according to from-view-id
- *
- * @param fromViewID -
- * page's from-view-id
- * @return the page flow page
- */
- public PageflowPage createPFPage(String fromViewID) {
- PageflowPage page = PageflowFactory.eINSTANCE.createPFPage();
- if (fromViewID != null && fromViewID.length() > 0) {
- page.setPath(fromViewID.trim());
- page.setName(WebrootUtil.getPageNameFromWebPath(fromViewID.trim()));
- }
- this.pageflow.getNodes().add(page);
- return page;
- }
-
- /**
- * update pageflow model according to the face-config model
- *
- * @author sfshi
- * @return true if new rules were added
- */
- public boolean updatePageflowModelFromEMF() {
- if (pageflow != null && facesConfig != null) {
- List navigationRulesInFacesconfig = facesConfig.getNavigationRule();
- clearCaches();
- // if add new one, we can relayout the current pageflow.
- return updateNavigationRulesInPageflowFromFacesConfig(navigationRulesInFacesconfig);
- }
- return false;
- }
-
- void refreshLink(NavigationCaseType caseType) {
- PageflowLink link = getValidPFLinkInCache(caseType);
- if (link != null) {
- removeLink(link);
- }
- // update pageflow
- if (TransformUtil.isValidFacesConfigElement(caseType)) {
- updatePageflowElements(pageflow, caseType);
- }
- }
-
- public void notifyChanged(Notification msg) {
- int type = msg.getEventType();
- switch (type) {
- case MY_NOTIFICATION_TYPE:
- setNeedBatchOperations(true);
- break;
- case MY_NOTIFICATION_TYPE1:
- setNeedBatchOperations(false);
- }
- }
-
- /**
- * @return true if is listening to notifications and not
- * currently in an event
- */
- public boolean isListenToNotify() {
- return listenToNotify && !isInEvent;
- }
-
- /**
- * @return true if in event
- */
-// public boolean isInEvent() {
-// return isInEvent;
-// }
-
- /**
- * @param isInEvent
- */
- public void setInEvent(boolean isInEvent) {
- this.isInEvent = isInEvent;
- }
-
- /**
- * @return the faces config model
- */
- public FacesConfigType getFacesConfig() {
- return facesConfig;
- }
-
- /**
- * @return the root page flow
- */
- public Pageflow getPageflow() {
- return pageflow;
- }
-
- /**
- * @param value
- * @return a new fromViewId with the text content set to value
- */
- public static FromViewIdType createRLFromViewID(String value) {
- FromViewIdType fromView = FacesConfigFactory.eINSTANCE
- .createFromViewIdType();
- fromView.setTextContent(value);
- return fromView;
- }
-
- /**
- * @param value
- * @return a new to view with the text content set to value
- */
- public static ToViewIdType createFCToViewID(String value) {
- ToViewIdType toView = FacesConfigFactory.eINSTANCE.createToViewIdType();
- toView.setTextContent(value);
- return toView;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PF2FCSynchronizer.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PF2FCSynchronizer.java
deleted file mode 100644
index 88b4953fe..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PF2FCSynchronizer.java
+++ /dev/null
@@ -1,218 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.InternalEObject;
-import org.eclipse.emf.ecore.impl.ENotificationImpl;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * The adapter that listens to modification of pageflow and updates faces-config
- * as needed.
- *
- * @author hmeng
- *
- */
-public class PF2FCSynchronizer extends AdapterImpl {
- FC2PFTransformer tranformer;
-
- private final boolean DEBUG = false;
-
- private static final Logger logger = EditorPlugin
- .getLogger(PF2FCSynchronizer.class);
-
- /**
- * @param tranformer
- */
- public PF2FCSynchronizer(FC2PFTransformer tranformer) {
- this.tranformer = tranformer;
- }
-
- public Notifier getTarget() {
- // TODO Auto-generated method stub
- return null;
- }
-
- public void setTarget(Notifier newTarget) {
- // TODO Auto-generated method stub
-
- }
-
- public boolean isAdapterForType(Object type) {
- return type == PF2FCSynchronizer.class;
- }
-
- public void notifyChanged(Notification notification) {
- if (!isProcessorFor(notification)) {
- return;
- }
- tranformer.setInEvent(true);
- try {
- if (!(notification.getNotifier() instanceof PageflowElement)) {
- return;
- }
- processChange(notification);
- } catch (Exception e) {
- logger.error(e);
- } finally {
- if (notification.getEventType() != Notification.REMOVING_ADAPTER) {
- tranformer.refreshPFAdapter(tranformer.getPageflow());
- tranformer.refreshFCAdapter(tranformer.getFacesConfig());
- }
- tranformer.setInEvent(false);
- }
- }
-
- private boolean isProcessorFor(Notification notification) {
- return tranformer.isListenToNotify();
- }
-
- private void processChange(Notification notification) {
- PageflowElement element;
- element = (PageflowElement) notification.getNotifier();
- int type = notification.getEventType();
- switch (type) {
- case Notification.ADD: {
- int featureId = notification.getFeatureID(PageflowPackage.class);
- switch (featureId) {
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- addOutLink(notification, element);
- break;
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- addInLink(notification, element);
- break;
- case PageflowPackage.PAGEFLOW:
- break;
- }
- if (!tranformer.isNeedBatchOperations()) {
- updateAndNotify(notification);
- }
- break;
- }
- case Notification.SET:
- if (notification.getNewValue() != null) {
- processSet(notification, element);
- updateAndNotify(notification);
- }
- break;
- case Notification.REMOVE:
- case Notification.REMOVE_MANY: {
- int featureId = notification.getFeatureID(PageflowPackage.class);
- switch (featureId) {
- case PageflowPackage.PF_PAGE:
- // removePage(notification, (PageflowPage) element);
- break;
- case PageflowPackage.PAGEFLOW_NODE__OUTLINKS:
- case PageflowPackage.PAGEFLOW_NODE__INLINKS:
- removeLink(notification, element);
- break;
- }
- if (!tranformer.isNeedBatchOperations()) {
- updateAndNotify(notification);
- }
- break;
- }
- }
- }
-
- private void processSet(Notification notification, PageflowElement element) {
- if (notification.getNewValue() != null) {
- int value = notification.getFeatureID(PageflowPackage.class);
- if (element instanceof PageflowPage) {
- setProperties(notification, element, value);
- } else if (element instanceof PageflowLink) {
- if (DEBUG)
- System.out.println("The link property is changed"); //$NON-NLS-1$
- setProperties(notification, element, value);
- }
- }
- }
-
- private void setProperties(Notification notification,
- PageflowElement element, int value) {
- if (notification.getFeature() == PageflowPackage.eINSTANCE
- .getPFLink_Source()) {
- if (notification.getNewValue() instanceof String) {
- tranformer.changePFLinkStart((PageflowLink) element,
- (String) notification.getNewValue());
- }
- } else if (notification.getFeature() == PageflowPackage.eINSTANCE
- .getPFLink_Target()) {
- if (notification.getNewValue() instanceof String) {
- tranformer.changePFLinkEnd((PageflowLink) element,
- (String) notification.getNewValue());
- }
- } else {
- element.getFCElements().set(
- (EStructuralFeature) notification.getFeature(),
- notification.getNewValue());
- }
- }
-
- private void addInLink(Notification notification, PageflowElement element) {
- Object value = notification.getNewValue();
- PageflowLink link = (PageflowLink) value;
- if (element instanceof PageflowPage) {
- PageflowNode source = link.getSource();
- if (source instanceof PageflowPage) {
- tranformer.addLink((PageflowPage) source,
- (PageflowPage) element, link);
- }
- }
-
- }
-
- private void addOutLink(Notification notification, PageflowElement element) {
- Object value = notification.getNewValue();
- // for outLink remove, only target is referenced.
- PageflowLink link = (PageflowLink) value;
- if (element instanceof PageflowPage) {
- PageflowNode target_ = link.getTarget();
- // page->page
- if (target_ instanceof PageflowPage) {
- tranformer.addLink((PageflowPage) element,
- (PageflowPage) target_, link);
- }
- }
- }
-
- private void removeLink(Notification notification, PageflowElement element) {
- Object value = notification.getOldValue();
- PageflowLink link = (PageflowLink) value;
-
- if (!link.getFCElements().isEmpty()) {
- NavigationCaseType caseFC = (NavigationCaseType) link
- .getFCElements().getData().get(0);
- if (caseFC != null)
- tranformer.removeCase(caseFC);
- }
- link.update();
- }
-
- private void updateAndNotify(Notification notification) {
- tranformer.getPageflow().notifyModelChanged(
- new ENotificationImpl((InternalEObject) notification
- .getNotifier(), Notification.SET,
- PageflowPackage.PAGEFLOW, null, null));
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PFBatchAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PFBatchAdapter.java
deleted file mode 100644
index d30e7d133..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/PFBatchAdapter.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.gef.editparts.AbstractGraphicalEditPart;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * @author hmeng
- */
-
-public abstract class PFBatchAdapter extends AdapterImpl {
- private boolean needPostpone;
-
- AbstractGraphicalEditPart editPart;
-
- /**
- * @param msg
- * @return true postponement needed
- */
- public boolean isNeedPostpone(Notification msg) {
- return needPostpone
- && !(msg.getEventType() == FC2PFTransformer.MY_NOTIFICATION_TYPE || msg
- .getEventType() == FC2PFTransformer.MY_NOTIFICATION_TYPE1);
- }
-
- /**
- * @param needPostpone
- */
- public void setNeedPostpone(boolean needPostpone) {
- this.needPostpone = needPostpone;
- }
-
- final public void notifyChanged(final Notification msg) {
- if (!isNeedPostpone(msg)) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread())
- doNotifyChanged(msg);
- else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- doNotifyChanged(msg);
- }
- });
- }
- }
- }
-
- /**
- * @param notification
- */
- abstract public void doNotifyChanged(Notification notification);
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/TransformUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/TransformUtil.java
deleted file mode 100644
index d2b40b992..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/synchronization/TransformUtil.java
+++ /dev/null
@@ -1,131 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.synchronization;
-
-import java.util.List;
-
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.FromOutcomeType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * The util for pageflow and faces-config transforming
- *
- * @author hmeng
- */
-
-public class TransformUtil {
-
- /**
- * To see if the faces-config element is on a valid hirachy.
- * @param object
- * @return true if object's root ancestor is a facesConfig model
- */
- public static boolean isValidFacesConfigElement(EObject object) {
- EObject parent = EcoreUtil.getRootContainer(object);
- boolean result = parent instanceof FacesConfigType;
- return result;
- }
-
- /**
- * To see if the pageflow element is on a valid hirachy.
- * @param element
- * @return true if element's root ancestor is a page flow element
- */
- public static boolean isValidPageflowElement(EObject element) {
- EObject root = EcoreUtil.getRootContainer(element);
- boolean result = root instanceof Pageflow;
- return result;
- }
-
- /**
- * @param link
- * @return true the link is valid
- */
- public static boolean isValidLink(PageflowLink link) {
- return isValidPageflowElement(link) && link.getSource() != null
- && link.getTarget() != null;
- }
-
- /**
- * @param rule
- * @return gets the from-view-id from rule
- */
- public static String getFromViewID(NavigationRuleType rule) {
- String result = "*"; //$NON-NLS-1$
- if (rule.getFromViewId() != null) {
- result = rule.getFromViewId().getTextContent();
- }
- return result;
- }
-
- /**
- * @param navCase
- * @return gets the to-view-id from navCase
- */
- public static String getToViewID(NavigationCaseType navCase) {
- String result = "*"; //$NON-NLS-1$
- if (navCase.getToViewId() != null) {
- result = navCase.getToViewId().getTextContent();
- }
- return result;
- }
-
- /**
- * @param path
- * @param pageflow
- * @return get pageflowpage in pageflow corresponding to path
- */
- public static PageflowPage findPage(String path, Pageflow pageflow) {
- List nodes = pageflow.getNodes();
- for (int i = 0; i < nodes.size(); i++) {
- if (nodes.get(i) instanceof PageflowPage) {
- if (path != null) {
- if (path.equals(((PageflowPage) nodes.get(i)).getPath())) {
- return (PageflowPage) nodes.get(i);
- }
- }
- }
- }
- return null;
- }
-
- /**
- * @param action
- * @param outcome
- * @param pageflow
- * @return find the end case
- */
- public static PageflowNode findCaseEnd(PageflowPage action,
- FromOutcomeType outcome, Pageflow pageflow) {
- // TODO: find a case end in pageflow model
- List links = action.getOutlinks();
- for (int i = 0; i < links.size(); i++) {
- PageflowLink link = (PageflowLink) links.get(i);
- String outcomeStr = ""; //$NON-NLS-1$
- if (outcome != null) {
- outcomeStr = outcome.getTextContent();
- }
- if (link.getOutcome().equals(outcomeStr)) {
- return link.getTarget();
- }
- }
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/EditPartMarkerUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/EditPartMarkerUtil.java
deleted file mode 100644
index a1e3c645b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/EditPartMarkerUtil.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.util.Iterator;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-
-/**
- *
- * Utility class to add and remove edit part markers.
- *
- * FIXME: add the identification mechanism of the model and remove the
- * dependency on the PageflowElement
- *
- * @author Xiao-guang Zhang
- *
- *
- */
-public class EditPartMarkerUtil {
-
- /**
- * Removes all markers that were created using createMarker()
- *
- * @param model -
- * the emf model related with edit part
- * @throws CoreException
- */
- public static void removeAllMarkers(EObject model) throws CoreException {
- IResource resource = getResource(model);
-
- if (resource != null) {
- String markerTypes[] = { IMarker.PROBLEM, IMarker.TASK };
-
- for (int iMT = 0; iMT < markerTypes.length; iMT++) {
- IMarker[] markers = resource.findMarkers(markerTypes[iMT],
- false, IResource.DEPTH_ONE);
-
- for (int iMark = 0; iMark < markers.length; iMark++) {
- markers[iMark].delete();
- }
- }
- }
- }
-
- /**
- * Removes a specific problem marker type with the given severity.
- *
- * @param model -
- * the model related with this edit part.
- * @param sMarkerType -
- * the marker type, either IMarker.PROBLEM or IMarker.TASK
- * @param iSeverity -
- * severity/priority: if sMarkerType is IMarker.PROBLEM, then
- * this value is one of the PROBLEM severities; if sMarkerType is
- * IMarker.TASK, this is a task priority.
- * @throws CoreException
- * passed on from IResource.findMarkers()
- */
- public static void removeAllMarkers(EObject model, String sMarkerType,
- int iSeverity) throws CoreException {
- IResource resource = getResource(model);
-
- if (resource != null) {
- IMarker[] markers = resource.findMarkers(sMarkerType, false,
- IResource.DEPTH_ONE);
-
- for (int i = 0; i < markers.length; i++) {
- IMarker marker = markers[i];
- int iMarkerSeverity = marker.getAttribute(IMarker.SEVERITY,
- IMarker.SEVERITY_ERROR);
-
- if (iMarkerSeverity == iSeverity || iSeverity == -1) {
- markers[i].delete();
- }
- }
- }
- }
-
- /**
- * get the resouce according to part or model.
- *
- * @param part
- * @param model
- * @return
- */
- private static IResource getResource(EObject model) {
- IResource resource = null;
- resource = WebrootUtil.getResource(model);
- return resource;
- }
-
- /**
- * Create a problem marker.
- *
- * @param model -
- * the model related with this edit part.
- * @param sMarkerType
- * @param severity -
- * the problem severity, one of IMarker.SEVERITY_ERROR,
- * IMarker.SEVERITY_WARNING or IMarker.SEVERITY_INFO
- * @param message -
- * the text associated with this marker
- * @param location -
- * a unique ID that the application can use to locate the
- * editpart
- *
- * that corresponds to this marker; this is typically the DiagramElement's
- * ID string
- * @throws CoreException
- */
- public static void createMarker(EObject model, String sMarkerType,
- int severity, String message, String location) throws CoreException {
- IResource resource = getResource(model);
-
- if (resource != null) {
- IMarker marker = resource.createMarker(sMarkerType);
- marker.setAttribute(IMarker.MESSAGE, message);
- marker.setAttribute(IMarker.SEVERITY, severity);
- // The problem view doesn't show the location - only the line number
- // is shown in the "location" column. Doh!
- if (location != null && location.length() > 0) {
- marker.setAttribute(IMarker.LOCATION, location);
- }
- }
- }
-
- /**
- * Removes a specific problem marker type with the given severity.
- *
- * @param model -
- * the model related with this edit part.
- * @param sMarkerType -
- * the marker type, either IMarker.PROBLEM or IMarker.TASK
- * @throws CoreException
- * passed on from IResource.findMarkers()
- */
- public static void removeMarker(EObject model, String sMarkerType)
- throws CoreException {
- IResource resource = getResource(model);
- if (resource != null) {
- IMarker[] markers = resource.findMarkers(sMarkerType, false,
- IResource.DEPTH_ONE);
-
- for (int i = 0; i < markers.length; i++) {
- IMarker marker = markers[i];
- // get the marker's location
- Object id = marker.getAttribute(IMarker.LOCATION);
-
- if (model instanceof PageflowElement) {
- if (((PageflowElement) model).getId().equals(id)) {
- markers[i].delete();
- }
- }
- }
- }
- }
-
- /**
- * Searches the hierarchy starting at the given EditPart for a given model
- * object ID string (the DiagramElement.ID value) and returns that EditPart
- *
- * @param containerPart
- * @param id
- * @return the EditPart that corresponds to the given ID string, or null if
- * not found
- */
- public static GraphicalEditPart findEditPart(
- GraphicalEditPart containerPart, String id) {
- Object model = containerPart.getModel();
- if (model instanceof PageflowElement) {
- String modelId = ((PageflowElement) model).getId();
- if (modelId != null && modelId.equals(id)) {
- return containerPart;
- }
- }
-
- Iterator iterNode = containerPart.getChildren().iterator();
- while (iterNode.hasNext()) {
- GraphicalEditPart child = (GraphicalEditPart) iterNode.next();
- GraphicalEditPart foundPart = findEditPart(child, id);
- if (foundPart != null) {
- return foundPart;
- }
- }
-
- Iterator iterConnection = containerPart.getSourceConnections()
- .iterator();
- while (iterConnection.hasNext()) {
- GraphicalEditPart child = (GraphicalEditPart) iterConnection.next();
- GraphicalEditPart foundPart = findEditPart(child, id);
- if (foundPart != null) {
- return foundPart;
- }
- }
-
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPDomAdapter.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPDomAdapter.java
deleted file mode 100644
index 36845dc9f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPDomAdapter.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.ITaglibContextResolver;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.internal.IStructuredDocumentContextResolverFactory2;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
-import org.w3c.dom.Document;
-import org.w3c.dom.NodeList;
-
-/**
- * This class is defined as a simple adapter to JSP DOM model. User can get the
- * taglib prefix, and get the needed element by element tage name, and
- * namespace(prefix) Usage: User should initialize this class instance before
- * using it. Following is a typical example: JSPDomAdapter jspAdapter = new
- * JSPDomAdapter(); IFile jspFile =
- * ResourcesPlugin.getWorkspace().getRoot().getFile(jspPath); if
- * (_jspAdapter.initialize(jspFile)) { //the prefix of JSF HTML TagLib String
- * prefix = _jspAdapter.getTagLibPrefix(JSPDomAdapter.JSF_HTML_TAGLIB); }
- *
- * @author Xiao-guang Zhang
- */
-public class JSPDomAdapter {
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(JSPDomAdapter.class);
-
- /** JSP Taglib's tag name */
- public static String JSP_TAGLIB_TAG = "jsp:directive.taglib"; //$NON-NLS-1$
-
- /** JSF HTML TagLib name */
- public static String JSF_HTML_TAGLIB = "http://java.sun.com/jsf/html"; //$NON-NLS-1$
-
- /** singleton model manager */
- private static IModelManager modelManager;
-
- /** source jsp file */
- private IFile jspFile;
-
- /** Structured Model of JSP File */
- private IStructuredModel model;
-
- /** Root Document (Node) of JSP file */
- private Document document;
-
- /**
- *
- */
- public JSPDomAdapter() {
- super();
-
- }
-
- /**
- * initialize this adapter to get the StructuredModel for the input file.
- * At last user should call releaseModel() method to release the Structured Model.
- *
- * @param file -
- * JSP file
- * @return - True means sucessfully load jsp file.
- */
- public boolean initialize(final IFile file) {
- jspFile = file;
-
- if (jspFile != null && jspFile.exists()) {
- try {
- model = getModel(jspFile);
- } catch (final IOException e) {
- // PageFlow.JSPDomAdapter.FailToGetStructuredModel = Failed to
- // get the structured model
- log.error("PageFlow.JSPDomAdapter.FailToGetStructuredModel", e); //$NON-NLS-1$
- } catch (final CoreException e) {
- // PageFlow.JSPDomAdapter.FailToGetStructuredModel = Failed to
- // get the structured model
- log.error("PageFlow.JSPDomAdapter.FailToGetStructuredModel", e);//$NON-NLS-1$
- }
-
- if (model != null && model instanceof IDOMModel) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * get the prefix for the input taglib URI, e.g.,
- * http://java.sun.com/jsf/html -> "h"
- *
- * @param taglibURI
- * @return the prefix
- */
- public String getTagLibPrefix(final String taglibURI) {
- String prefix = null;
-
- final IStructuredDocument sdocument = model.getStructuredDocument();
-
- if (sdocument != null)
- {
- IStructuredDocumentContext context =
- IStructuredDocumentContextFactory.INSTANCE.getContext(sdocument, -1);
- ITaglibContextResolver resolver =
- IStructuredDocumentContextResolverFactory2.INSTANCE.getTaglibContextResolverFromDelegates(context);
- prefix = resolver.getTagPrefixForURI(taglibURI);
- }
-
- return prefix;
- }
-
- /**
- * get the elements by the namespace and its tag name, e.g., h and
- * commandButton.
- *
- * @param namespace -
- * namespace for the taglib, e.g., h for
- * http://java.sun.com/jsf/html
- * @param elementName -
- * element Tag Name, e.g., h
- * @return - Element Node list.
- */
- public List getElementsByTagNameNS(final String namespace, final String elementName) {
- List nodes = null;
-
- if (getDocument() != null) {
- NodeList listNodes = null;
- if (namespace != null) {
- listNodes = getDocument().getElementsByTagName(
- namespace + ":" + elementName); //$NON-NLS-1$
- } else {
- listNodes = getDocument().getElementsByTagName(elementName);
- }
-
- if (listNodes != null && listNodes.getLength() > 0) {
- nodes = new ArrayList();
- for (int i = 0; i < listNodes.getLength(); i++) {
- nodes.add(listNodes.item(i));
- }
- }
- }
- return nodes;
- }
-
- /**
- * get the singleton model manager.
- *
- * @return
- */
- private IModelManager getModelManager() {
- if (modelManager == null) {
- modelManager = StructuredModelManager.getModelManager();
- }
- return modelManager;
- }
-
- /**
- * get the structured model for the JSP file
- *
- * @param file -
- * JSP File
- * @return - IStructuredModel
- * @throws IOException
- * @throws CoreException
- */
- private IStructuredModel getModel(final IFile file) throws IOException,
- CoreException {
- return getModelManager().getModelForRead(file);
- }
-
- /**
- * get the root docuement for the StructuredModel
- *
- * @return
- */
- private Document getDocument() {
- if (document == null) {
- if (model != null && model instanceof IDOMModel) {
- document = ((IDOMModel) model).getDocument();
- }
- }
- return document;
- }
-
-
- /**
- * signal we are done with the model
- */
- public void releaseModel() {
- if (model != null) {
- model.releaseFromRead();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPUtil.java
deleted file mode 100644
index 7b1414b72..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/JSPUtil.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-
-/**
- * utility class for JSP related information.
- *
- * @author Yang Liu
- */
-public class JSPUtil {
-
- /**
- * get the action list in the jsp file
- * @param jspFileName
- *
- * @return - action list
- */
- public static List getActionListInJSPFile(String jspFileName) {
- /** jsp dom adapter */
-
- List actions = new ArrayList();
-
- // convert the relative directory to project directory, e.g., /a.jsp to
- // /testproject/webroot/a.sjp
- String physicalJspPath = jspFileName;
- if (physicalJspPath != null && physicalJspPath.length() > 0)
- {
- IPath jspPath = new Path(physicalJspPath);
- IFile jspFile = ResourcesPlugin.getWorkspace().getRoot().getFile(
- jspPath);
-
- if (jspFile != null && jspFile.exists())
- {
- JSPDomAdapter jspAdapter = null;
- try
- {
- jspAdapter = new JSPDomAdapter();
- // initialize the adapter to initialize the model of jsp
- if (jspAdapter.initialize(jspFile))
- {
- // the prefix of JSF HTML TagLib
- String prefix = jspAdapter
- .getTagLibPrefix(JSPDomAdapter.JSF_HTML_TAGLIB);
-
- // get the command butonns
- List buttonActions = jspAdapter.getElementsByTagNameNS(
- prefix, "commandButton");//$NON-NLS-1$
- if (buttonActions != null)
- actions.addAll(buttonActions);
-
- // get the command links
- List linkActions = jspAdapter.getElementsByTagNameNS(
- prefix, "commandLink");//$NON-NLS-1$
- if (linkActions != null)
- actions.addAll(linkActions);
- }
- }
- finally
- {
- if (jspAdapter != null)
- {
- jspAdapter.releaseModel();
- }
- }
- }
- }
- return actions;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/ModelCreationFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/ModelCreationFactory.java
deleted file mode 100644
index b869353ed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/ModelCreationFactory.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-
-/**
- * This class implements the CreationFactory used by the CreationTool. It in
- * turn uses the EMF-generated factories to create the model instances
- *
- * @author Xiao-guang Zhang
- */
-public class ModelCreationFactory implements CreationFactory {
- private Class targetClass;
-
- /**
- * @param targetClass
- */
- public ModelCreationFactory(Class targetClass) {
- this.targetClass = targetClass;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.requests.CreationFactory#getNewObject()
- */
- public Object getNewObject() {
- PageflowFactory factory = PageflowModelManager.getFactory();
-
- Object result = null;
-
- if (targetClass.equals(PageflowLink.class)) {
- result = factory.createPFLink();
-
- } else if (targetClass.equals(PageflowPage.class)) {
- result = factory.createPFPage();
- }
-
- return result;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.gef.requests.CreationFactory#getObjectType()
- */
- public Object getObjectType() {
- return targetClass;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAdapterFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAdapterFactory.java
deleted file mode 100644
index 8da99bf53..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAdapterFactory.java
+++ /dev/null
@@ -1,256 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notifier;
-import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-
-/**
- * <!-- begin-user-doc --> The <b>Adapter Factory</b> for the model. It
- * provides an adapter <code>createXXX</code> method for each class of the
- * model. <!-- end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage
- * @generated
- */
-// FIXME: this appears to be a dead class.
-public class PageflowAdapterFactory extends AdapterFactoryImpl {
- /**
- * The cached model package. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected static PageflowPackage modelPackage;
-
- /**
- * Creates an instance of the adapter factory. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- public PageflowAdapterFactory() {
- if (modelPackage == null) {
- modelPackage = PageflowPackage.eINSTANCE;
- }
- }
-
- /**
- * Returns whether this factory is applicable for the type of the object.
- * <!-- begin-user-doc --> This implementation returns <code>true</code>
- * if the object is either the model's package or is an instance object of
- * the model. <!-- end-user-doc -->
- *
- * @return whether this factory is applicable for the type of the object.
- * @generated
- */
- public boolean isFactoryForType(Object object) {
- if (object == modelPackage) {
- return true;
- }
- if (object instanceof EObject) {
- return ((EObject) object).eClass().getEPackage() == modelPackage;
- }
- return false;
- }
-
- /**
- * The switch the delegates to the <code>createXXX</code> methods. <!--
- * begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected PageflowSwitch modelSwitch = new PageflowSwitch() {
- public Object casePageflow(Pageflow object) {
- return createPageflowAdapter();
- }
-
- public Object casePageflowNode(PageflowNode object) {
- return createPageflowNodeAdapter();
- }
-
- public Object casePFLink(PageflowLink object) {
- return createPFLinkAdapter();
- }
-
- public Object casePageflowElement(PageflowElement object) {
- return createPageflowElementAdapter();
- }
-
- public Object casePFPage(PageflowPage object) {
- return createPFPageAdapter();
- }
-
- public Object casePFLinkBendpoint(PageflowLinkBendpoint object) {
- return createPFLinkBendpointAdapter();
- }
-
- public Object defaultCase(EObject object) {
- return createEObjectAdapter();
- }
- };
-
- /**
- * Creates an adapter for the <code>target</code>. <!-- begin-user-doc
- * --> <!-- end-user-doc -->
- *
- * @param target
- * the object to adapt.
- * @return the adapter for the <code>target</code>.
- * @generated
- */
- public Adapter createAdapter(Notifier target) {
- return (Adapter) modelSwitch.doSwitch((EObject) target);
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow <em>Pageflow</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow
- * @generated
- */
- public Adapter createPageflowAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode <em>Node</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode
- * @generated
- */
- public Adapter createPageflowNodeAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink <em>PF Link</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink
- * @generated
- */
- public Adapter createPFLinkAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement <em>Element</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement
- * @generated
- */
- public Adapter createPageflowElementAdapter() {
- return null;
- }
-
- /**
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @generated
- */
- public Adapter createPFActionAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage <em>PF Page</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage
- * @generated
- */
- public Adapter createPFPageAdapter() {
- return null;
- }
-
- /**
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @generated
- */
- public Adapter createPFBeginAdapter() {
- return null;
- }
-
- /**
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @generated
- */
- public Adapter createPFEndAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for an object of class '{@link org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint <em>PF Link Bendpoint</em>}'.
- * <!-- begin-user-doc --> This default implementation returns null so that
- * we can easily ignore cases; it's useful to ignore a case when inheritance
- * will catch all the cases anyway. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint
- * @generated
- */
- public Adapter createPFLinkBendpointAdapter() {
- return null;
- }
-
- /**
- * Creates a new adapter for the default case. <!-- begin-user-doc --> This
- * default implementation returns null. <!-- end-user-doc -->
- *
- * @return the new adapter.
- * @generated
- */
- public Adapter createEObjectAdapter() {
- return null;
- }
-
-}
-// PageflowAdapterFactory
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAnnotationUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAnnotationUtil.java
deleted file mode 100644
index b6a23620b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowAnnotationUtil.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.util.Iterator;
-
-import org.eclipse.core.resources.IMarker;
-import org.eclipse.gef.GraphicalEditPart;
-import org.eclipse.jface.text.source.Annotation;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.IAnnotationEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PFValidator;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowElementEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowLinkEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.editpart.PageflowNodeEditPart;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * This class can be used to add annotation for the current pageflow model and
- * decoration for view.
- *
- * @author Xiao-guang Zhang
- *
- *
- */
-public class PageflowAnnotationUtil {
-
- /**
- *
- * validate the pageflow and its edit part
- *
- * @param containerPart -
- * it can be null, then the edit part will not be updated
- */
- public static void validatePageflow(final GraphicalEditPart containerPart) {
- if (containerPart == null) {
- return;
- }
-
- // removeAllAnnotations(containerPart);
-
- // validate the nodes including page and actions.
- final Iterator iterChild = containerPart.getChildren().iterator();
- while (iterChild.hasNext()) {
-
- final PageflowElementEditPart element = (PageflowElementEditPart) iterChild
- .next();
- // String errorMessage = null;
- if (element instanceof PFValidator) {
- ((PFValidator) element).validate();
- }
- // if (element.getModel() instanceof PageflowPage) {
- // errorMessage = PageflowValidation.getInstance().getNotifyMessage(
- // (PageflowPage) element.getModel());
- // }
-
- // if (errorMessage != null) {
- // addAnnotation(element, errorMessage);
- // } else {
- // removeAnnotation(element);
- // }
-
- // validate the connections.
- final Iterator iterLinks = element.getSourceConnections().iterator();
- while (iterLinks.hasNext()) {
- final PageflowLinkEditPart link = (PageflowLinkEditPart) iterLinks
- .next();
- link.validate();
- // validateLink(link);
- }
- }
-
- }
-
- /**
- * validate the page based on model and its's edit part.
- *
- * @param pagePart -
- * it can be null, then the edit part will not be updated
- */
- public static void validatePage(final PageflowNodeEditPart pagePart) {
- if (pagePart != null && pagePart.getParent() != null) {
- return;
- }
-
- String errorMessage = null;
-
- removeAnnotation(pagePart);
-
- errorMessage = PageflowValidation.getInstance().getNotifyMessage(
- (PageflowPage) pagePart.getModel());
-
- if (errorMessage != null) {
- addAnnotation(pagePart, errorMessage);
- } else {
- removeAnnotation(pagePart);
- }
-
- // validate the connections.
- // Iterator iterLinks = pagePart.getSourceConnections().iterator();
- // while (iterLinks.hasNext()) {
- // PageflowLinkEditPart link = (PageflowLinkEditPart) iterLinks.next();
- //
- // validateLink(link);
- // }
- }
-
- /**
- * validate the link based on model and its's edit part.
- *
- * @param linkPart -
- * it can be null, then the edit part will not be updated
- */
- public static void validateLink(final PageflowLinkEditPart linkPart) {
- if (linkPart != null && linkPart.getParent() != null) {
- String errorMessage = null;
-
- removeAnnotation(linkPart);
-
- errorMessage = PageflowValidation.getInstance().isValidLink(
- (PageflowLink) linkPart.getModel());
-
- if (errorMessage != null) {
- addAnnotation(linkPart, errorMessage);
- } else {
- removeAnnotation(linkPart);
- }
- }
- }
-
- /**
- * add a marker with IMarker.PROBLEM type, IMarker.SEVERITY_ERROR severity,
- * and message.
- *
- * @param editPart
- * @param model
- * @param message
- */
- private static void addAnnotation(final GraphicalEditPart editPart, final String message) {
- if (editPart != null && editPart instanceof IAnnotationEditPart) {
- final Annotation annotation = new Annotation(IMarker.PROBLEM, false,
- message);
- ((IAnnotationEditPart) editPart).addAnnotation(annotation);
- }
- }
-
- /**
- * remove a marker
- *
- * @param editPart
- * @param model
- */
- private static void removeAnnotation(final GraphicalEditPart editPart) {
- if (editPart != null && editPart instanceof IAnnotationEditPart) {
- ((IAnnotationEditPart) editPart).removeAnnotation();
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowModelManager.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowModelManager.java
deleted file mode 100644
index 5e2689a92..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowModelManager.java
+++ /dev/null
@@ -1,279 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.EPackage;
-import org.eclipse.emf.ecore.resource.Resource;
-import org.eclipse.emf.ecore.resource.ResourceSet;
-import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl;
-import org.eclipse.emf.ecore.xmi.XMLResource;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.impl.PageflowPackageImpl;
-
-/**
- * Drives the model. Acts as the model entry point, including create, load, save
- * operations.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowModelManager {
- /**
- * In EMF, a resource provides the way to have access to the model content.
- */
- private Resource resourcePageflow = null;
-
- /**
- * the path of current pageflow model resource provides the way to have
- * access to the model content.
- */
- private IPath pathPageflow = null;
-
- /**
- * Contains the factory associated with the model.
- */
- private static PageflowFactory pageflowFactory = null;
-
- /**
- * Gives access to the top level pageflow contained in the resource.
- */
- private Pageflow pageflow = null;
-
- /**
- * resource set
- */
- private ResourceSet resourceSet = null;
-
- /** unicode encoding UTF-8 support */
- private static HashMap defaultSaveOptions = new HashMap();
-
- static {
- defaultSaveOptions.put(XMLResource.OPTION_ENCODING, "UTF-8"); //$NON-NLS-1$
- }
-
- /**
- * Uses lazy initialization.
- *
- * @param path -
- * pageflow file name
- * @return the resource containing the pageflow
- */
- public Resource getResource(IPath path) {
- if (resourcePageflow == null) {
- pathPageflow = path;
- ResourceSet resSet = getResourceSet();
- resourcePageflow = resSet.getResource(URI.createPlatformResourceURI(path
- .toString(), false), true);
- }
-
- return resourcePageflow;
- }
-
- /**
- *
- * @return the top level pageflow model
- */
- public Pageflow getModel() {
- if (null == pageflow) {
- EList l = resourcePageflow.getContents();
- Iterator i = l.iterator();
- while (i.hasNext()) {
- Object o = i.next();
- if (o instanceof Pageflow) {
- pageflow = (Pageflow) o;
- }
- }
- }
- return pageflow;
- }
-
- /**
- * Creates a resource to contain the network. The resource file does not
- * exist yet.
- *
- * @param path
- * @return
- */
- private Resource createResource(IPath path) {
- if (resourcePageflow == null) {
- pathPageflow = path;
- ResourceSet resSet = getResourceSet();
- resourcePageflow = resSet.createResource(URI.createPlatformResourceURI(path
- .toString(), false));
- }
- return resourcePageflow;
- }
-
- /**
- * Returns the resource set.
- *
- * @param
- * @return
- */
- private ResourceSet getResourceSet() {
- if (null == resourceSet) {
- // Initialize the pageflow package, this line can not be removed.
- PageflowPackageImpl.init();
- // Register the XML resource factory for the .pageflow extension
- Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE;
- Map regMap = reg.getExtensionToFactoryMap();
- // m.put("pageflow", new XMIResourceFactoryImpl());
- regMap.put("pageflow", new PageflowResourceFactoryImpl()); //$NON-NLS-1$
-
- resourceSet = new ResourceSetImpl();
- }
-
- return resourceSet;
- }
-
- /**
- * Returns the factory associated with the model. Object creation are made
- * through that factory.
- *
- * @return - pageflow factory
- */
- static public PageflowFactory getFactory() {
- if (pageflowFactory == null) {
- // Access the factory (needed to create instances)
- Map registry = EPackage.Registry.INSTANCE;
- String pageflowURI = PageflowPackage.eNS_URI;
- PageflowPackage pageflowPackage = (PageflowPackage) registry
- .get(pageflowURI);
- pageflowFactory = pageflowPackage.getPageflowFactory();
- }
- return pageflowFactory;
- }
-
- /**
- * Creates a new pageflow model with begin and end nodes.
- *
- * @param path -
- * the new pageflow file name
- * @return - new pageflow model
- */
- public Pageflow createPageflow(IPath path) {
- createResource(path);
- // Create a new pageflow model
- Map registry = EPackage.Registry.INSTANCE;
- String pageflowURI = PageflowPackage.eNS_URI;
- PageflowPackage nPackage = (PageflowPackage) registry.get(pageflowURI);
- PageflowFactory nFactory = nPackage.getPageflowFactory();
- pageflow = nFactory.createPageflow();
-
- resourcePageflow.getContents().add(pageflow);
- return pageflow;
- }
-
- /**
- * Loads the content of the model from the file.
- *
- * @param path
- */
- public void load(IPath path) {
- getResource(path);
- }
-
- /**
- * reloads the content of the model from the file.
- *
- * @param path
- */
- public void reload(IPath path) {
- getResource(path).unload();
- load(path);
- }
-
- /**
- * Saves the content of the model to the file.
- *
- * @param path
- * @throws IOException
- */
- public void save(final IPath path) throws IOException {
- if (!pathPageflow.toString().equalsIgnoreCase(path.toString())) {
- pathPageflow = path;
- URI fileURI = URI.createPlatformResourceURI(path.toString(), false);
- resourcePageflow.setURI(fileURI);
- }
- resourcePageflow.save(defaultSaveOptions);
- }
-
- /**
- * get the file path of current pageflow resource
- *
- * @return - the file path
- */
- public IPath getPath() {
- return pathPageflow;
- }
-
- /**
- * @param webPath
- * @return found page node according the web path.
- */
- public PageflowPage foundPage(String webPath) {
- PageflowPage page = null;
-
- if (getModel() != null) {
- Iterator iterNodes = getModel().getNodes().iterator();
- while (iterNodes.hasNext()) {
- PageflowNode node = (PageflowNode) iterNodes.next();
- if (node instanceof PageflowPage) {
- if (((PageflowPage) node).getPath().equalsIgnoreCase(webPath)) {
- page = (PageflowPage) node;
- break;
- }
- }
- }
- }
-
- return page;
- }
-
- /**
- *
- * Build a path for the resource in the .metadata directory given the path
- * of the model resource. For example, given a model resource path of
- * \test\folder\filename.ext the resulting Pageflow path name will be
- * \test\.metadata\folder\filename.pageflow
- *
- * @param pathFacesConfig -
- * faces-config file path.
- *
- * @return the ipath
- */
- public static IPath makePageflowPath(IPath pathFacesConfig) {
- IPath pageflowPath;
- String[] segs = pathFacesConfig.removeFileExtension().segments();
- pageflowPath = new Path(segs[0]).makeAbsolute();
- pageflowPath = pageflowPath.append(".metadata"); //$NON-NLS-1$
- for (int i = 1; i < segs.length; i++) {
- pageflowPath = pageflowPath.append(segs[i]);
- }
- // pageflowPath.removeFileExtension();
- pageflowPath = pageflowPath.addFileExtension("pageflow"); //$NON-NLS-1$
- return pageflowPath;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactory.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactory.java
deleted file mode 100644
index 24f995ced..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactory.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.gef.requests.CreationFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowFactory;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-
-/**
- *
- * This is the Page Flow Resource Factory for resource drag and drop
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowResourceFactory implements CreationFactory {
- /** resource */
- private IResource resource;
-
- /**
- * @param resource
- */
- public PageflowResourceFactory(IResource resource) {
- this.resource = resource;
- }
-
- /*
- * (non-javadoc)
- *
- * @see Factory#getNewObject()
- */
- public Object getNewObject() {
- if (null == resource) {
- return null;
- }
-
- String strWebPath = WebrootUtil.getWebPath(resource.getFullPath());
- if (strWebPath.length() > 0) {
- PageflowFactory factory = PageflowModelManager.getFactory();
- Object result = factory.createPFPage();
- PageflowPage page = (PageflowPage) result;
- page.setPath(strWebPath);
- page.setName(WebrootUtil.getPageNameFromWebPath(strWebPath));
- return page;
- }
-
- EditorPlugin
- .getAlerts()
- .error(
- "Pageflow.Error.DNDResourceTitle", //$NON-NLS-1$
- EditorPlugin
- .getResourceString("Pageflow.Error.InvalidResource") //$NON-NLS-1$
- + resource.getName());
-
- return null;
- }
-
- /*
- * (non-javadoc)
- *
- * @see Factory#getObjectType()
- */
- public Object getObjectType() {
- return resource;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactoryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactoryImpl.java
deleted file mode 100644
index 1181474f8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceFactoryImpl.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.resource.Resource;
-import org.eclipse.emf.ecore.xmi.impl.XMLResourceFactoryImpl;
-
-/**
- * The <b>Resource Factory</b> associated with the package.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowResourceFactoryImpl extends XMLResourceFactoryImpl {
- /**
- * Creates an instance of the resource factory.
- */
- public PageflowResourceFactoryImpl() {
- super();
- }
-
- /**
- * Creates an instance of the resource.
- */
- public Resource createResource(URI uri) {
- Resource result = new PageflowResourceImpl(uri);
- return result;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceImpl.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceImpl.java
deleted file mode 100644
index 07e13ee12..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowResourceImpl.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl;
-
-/**
- *
- * The <b>Resource </b> associated with the package.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowResourceImpl extends XMLResourceImpl {
- /**
- * Creates an instance of the resource. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @param uri
- * the URI of the new resource.
- * @generated
- */
- public PageflowResourceImpl(URI uri) {
- super(uri);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowSwitch.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowSwitch.java
deleted file mode 100644
index 3487f12c4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowSwitch.java
+++ /dev/null
@@ -1,262 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.util.List;
-
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLinkBendpoint;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowElement;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage;
-
-/**
- * <!-- begin-user-doc --> The <b>Switch</b> for the model's inheritance
- * hierarchy. It supports the call {@link #doSwitch(EObject)} to invoke
- * the <code>caseXXX</code> method for each class of the model, starting with
- * the actual class of the object and proceeding up the inheritance hierarchy
- * until a non-null result is returned, which is the result of the switch. <!--
- * end-user-doc -->
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPackage
- * @generated
- */
-public class PageflowSwitch {
- /**
- * The cached model package <!-- begin-user-doc --> <!-- end-user-doc -->
- *
- * @generated
- */
- protected static PageflowPackage modelPackage;
-
- /**
- * Creates an instance of the switch. <!-- begin-user-doc --> <!--
- * end-user-doc -->
- *
- * @generated
- */
- public PageflowSwitch() {
- if (modelPackage == null) {
- modelPackage = PageflowPackage.eINSTANCE;
- }
- }
-
- /**
- * Calls <code>caseXXX</code> for each class of the model until one
- * returns a non null result; it yields that result.
- *
- * <!-- begin-user-doc -->
- * @param theEObject
- *
- * @return the first non-null result returned by a <code>caseXXX</code>
- * call.
- * <!-- end-user-doc -->
- * @generated
- */
- public Object doSwitch(EObject theEObject) {
- return doSwitch(theEObject.eClass(), theEObject);
- }
-
- /**
- * Calls <code>caseXXX</code> for each class of the model until one
- * returns a non null result; it yields that result.
- *
- * <!-- begin-user-doc -->
- * @param theEClass
- * @param theEObject
- *
- * @return the first non-null result returned by a <code>caseXXX</code>
- * call.
- * <!-- end-user-doc -->
- *
- * @generated
- */
- protected Object doSwitch(EClass theEClass, EObject theEObject) {
- if (theEClass.eContainer() == modelPackage) {
- return doSwitch(theEClass.getClassifierID(), theEObject);
- }
- List eSuperTypes = theEClass.getESuperTypes();
- return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch(
- (EClass) eSuperTypes.get(0), theEObject);
- }
-
- /**
- * Calls <code>caseXXX</code> for each class of the model until one
- * returns a non null result; it yields that result.
- *
- * <!-- begin-user-doc -->
- * @param classifierID
- * @param theEObject
- *
- * @return the first non-null result returned by a <code>caseXXX</code>
- * call.
- * <!-- end-user-doc -->
- *
- * @generated
- */
- protected Object doSwitch(int classifierID, EObject theEObject) {
- switch (classifierID) {
- case PageflowPackage.PAGEFLOW: {
- Pageflow pageflow = (Pageflow) theEObject;
- Object result = casePageflow(pageflow);
- if (result == null)
- result = casePageflowElement(pageflow);
- if (result == null)
- result = defaultCase(theEObject);
- return result;
- }
- case PageflowPackage.PF_LINK: {
- PageflowLink pfLink = (PageflowLink) theEObject;
- Object result = casePFLink(pfLink);
- if (result == null)
- result = casePageflowElement(pfLink);
- if (result == null)
- result = defaultCase(theEObject);
- return result;
- }
-
- case PageflowPackage.PF_PAGE: {
- PageflowPage pfPage = (PageflowPage) theEObject;
- Object result = casePFPage(pfPage);
- if (result == null)
- result = casePageflowNode(pfPage);
- if (result == null)
- result = casePageflowElement(pfPage);
- if (result == null)
- result = defaultCase(theEObject);
- return result;
- }
-
- case PageflowPackage.PF_LINK_BENDPOINT: {
- PageflowLinkBendpoint pfLinkBendpoint = (PageflowLinkBendpoint) theEObject;
- Object result = casePFLinkBendpoint(pfLinkBendpoint);
- if (result == null)
- result = defaultCase(theEObject);
- return result;
- }
- default:
- return defaultCase(theEObject);
- }
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>Pageflow</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>Pageflow</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePageflow(Pageflow object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>Node</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>Node</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePageflowNode(PageflowNode object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>PF Link</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>PF Link</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePFLink(PageflowLink object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>Element</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>Element</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePageflowElement(PageflowElement object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>PF Page</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>PF Page</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePFPage(PageflowPage object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>PF Link Bendpoint</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>PF Link Bendpoint</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
- * @generated
- */
- public Object casePFLinkBendpoint(PageflowLinkBendpoint object) {
- return null;
- }
-
- /**
- * Returns the result of interpretting the object as an instance of '<em>EObject</em>'.
- * <!-- begin-user-doc --> This implementation returns null; returning a
- * non-null result will terminate the switch, but this is the last case
- * anyway. <!-- end-user-doc -->
- *
- * @param object
- * the target of the switch.
- * @return the result of interpretting the object as an instance of '<em>EObject</em>'.
- * @see #doSwitch(org.eclipse.emf.ecore.EObject)
- * @generated
- */
- public Object defaultCase(EObject object) {
- return null;
- }
-
-}
-// PageflowSwitch
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowTransform.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowTransform.java
deleted file mode 100644
index 327af05c9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowTransform.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.IconType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-
-/**
- * The tranform between pageflow and navigation rules in faces-config file.
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowTransform {
-
- /** The shared singleton instance. */
- private static PageflowTransform transform;
-
- private PageflowTransform() {
- // private contructor
- }
-
- /**
- * Returns the shared singleton instance.
- * @return the singleton transform instance
- */
- public static PageflowTransform getInstance() {
- if (transform == null) {
- transform = new PageflowTransform();
- }
- return transform;
- }
-
- /**
- * Update source PFPage with Faces-config model.
- *
- * @param sourcePage
- * @param navigationRuleFC
- * @author sfshi
- */
- public void updatePageflowSourcePage(PageflowPage sourcePage,
- NavigationRuleType navigationRuleFC) {
- // set the descriiption of link
- if (navigationRuleFC.getDescription() != null
- && navigationRuleFC.getDescription().size() > 0) {
- String description = ((DescriptionType) navigationRuleFC
- .getDescription().get(0)).getTextContent();
- sourcePage.setComment(description);
- }
- // set the display-name of link
- if (navigationRuleFC.getDisplayName() != null
- && navigationRuleFC.getDisplayName().size() > 0) {
- String displayName = ((DisplayNameType) navigationRuleFC
- .getDisplayName().get(0)).getTextContent();
- sourcePage.setName(displayName);
- }
-
- // Set the icon of link
- if (navigationRuleFC.getIcon() != null
- && navigationRuleFC.getIcon().size() > 0) {
- boolean largeUpdated = false;
- boolean smallUpdated = false;
- for (int i = 0; i < navigationRuleFC.getIcon().size(); i++) {
- IconType icon = (IconType) navigationRuleFC.getIcon().get(i);
- if (!largeUpdated && icon.getLargeIcon() != null) {
- sourcePage.setLargeicon(icon.getLargeIcon()
- .getTextContent());
- largeUpdated = true;
- }
-
- if (!smallUpdated && icon.getSmallIcon() != null) {
- sourcePage.setSmallicon(icon.getSmallIcon()
- .getTextContent());
- smallUpdated = true;
- }
- if (largeUpdated && smallUpdated) {
- return;
- }
- }
- }
- }
-
- /**
- * Update target PFPage with Faces-config model.
- *
- * @param targetPage
- * @param navigationCaseFC
- * @author sfshi
- */
- public void updatePageflowTargetPage(PageflowPage targetPage,
- NavigationCaseType navigationCaseFC) {
- // set the descriiption of link
- if (navigationCaseFC.getDescription() != null
- && navigationCaseFC.getDescription().size() > 0) {
- String description = ((DescriptionType) navigationCaseFC
- .getDescription().get(0)).getTextContent();
- targetPage.setComment(description);
- }
- // set the display-name of link
- if (navigationCaseFC.getDisplayName() != null
- && navigationCaseFC.getDisplayName().size() > 0) {
- String displayName = ((DisplayNameType) navigationCaseFC
- .getDisplayName().get(0)).getTextContent();
- targetPage.setName(displayName);
- }
-
- // Set the icon of link
- if (navigationCaseFC.getIcon() != null
- && navigationCaseFC.getIcon().size() > 0) {
- boolean largeUpdated = false;
- boolean smallUpdated = false;
- for (int i = 0; i < navigationCaseFC.getIcon().size(); i++) {
- IconType icon = (IconType) navigationCaseFC.getIcon().get(0);
- if (!largeUpdated && icon.getLargeIcon() != null) {
- targetPage.setLargeicon(icon.getLargeIcon()
- .getTextContent());
- largeUpdated = true;
- }
-
- if (!smallUpdated && icon.getSmallIcon() != null) {
- targetPage.setSmallicon(icon.getSmallIcon()
- .getTextContent());
- smallUpdated = true;
- }
- if (largeUpdated && smallUpdated) {
- return;
- }
- }
- }
- }
-
- /**
- * update the pageflow model 's information, including pageflow's name,
- * description and related config file
- *
- * @param newPageflow
- * @param oldPageflow
- */
- public static void updatePageflowModelInfo(Pageflow newPageflow,
- Pageflow oldPageflow) {
- if (newPageflow == null || oldPageflow == null) {
- return;
- }
- newPageflow.setName(oldPageflow.getName());
- newPageflow.setComment(oldPageflow.getComment());
- newPageflow.setConfigfile(oldPageflow.getConfigfile());
-
- }
-}
-// PageflowTransform
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowValidation.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowValidation.java
deleted file mode 100644
index 7f69a64ff..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/pageflow/util/PageflowValidation.java
+++ /dev/null
@@ -1,288 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.pageflow.util;
-
-import java.util.Iterator;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.Pageflow;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowLink;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowNode;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.model.PageflowPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.WebrootUtil;
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Pageflow's validation functions
- *
- * @author Xiao-guang Zhang
- */
-public class PageflowValidation {
- /** PageflowValidation singleton instance */
- private static PageflowValidation instance;
-
- /** constructor */
- private PageflowValidation() {
- // no external instantiation
- }
-
- /**
- * get the singleton instance of pageflow validation
- *
- * @return the singleton instance of pageflow validation
- */
- public static PageflowValidation getInstance() {
- if (instance == null) {
- instance = new PageflowValidation();
- }
- return instance;
- }
-
- /**
- * check whether the source and target pageflow node are allowed to create a
- * new link NOT allowed source and target: 1. target node is Begin or source
- * node is End 2. both of source and target node are Action. 3. double
- * connection from the same source to target
- *
- * @param source -
- * source pageflow node
- * @param target -
- * target pageflow node
- * @return - is valid link or not.
- *
- */
- public boolean isValidLinkForCreation(PageflowNode source,
- PageflowNode target) {
- // Source and target must be pointing to some real pageflow node
- if (source == null || target == null) {
- return false;
- }
- return true;
- }
-
- /**
- * determine the pflink is valid or not for property souce. in our model,
- * there are five types of invalid pflinke for property source. 1. link
- * between page and action 2. the source of link is Begin or End node 3. the
- * target of link is Begin or End node.
- * @param link
- *
- * @return - valid link or not.
- *
- */
- public boolean isValidLinkForProperty(PageflowLink link) {
- return true;
- }
-
- /**
- * determine the pflink is valid or not for face-config rule in our model,
- * there are four types of invalid pflinke. 1. the source of link is Begin
- * or End node 2. the target of link is Begin or End node.
- * @param link
- *
- * @return - valid link or not.
- *
- */
- public boolean isValidLinkForNavigationRule(PageflowLink link) {
- return true;
- }
-
- /**
- * determine the pflink is valid or not for face-config rule in our model,
- * there are four types of invalid pflinke.
- * @param link
- *
- * @return - valid link or not.
- *
- */
- public String isValidLink(PageflowLink link) {
- String errorMessage = null;
- // action-page style
- // TODO: it should guarantee that outcome should be defined in the
- // managed bean's method.
-
- if (link.getSource() instanceof PageflowPage
- && link.getTarget() instanceof PageflowPage) {
- String outcome = link.getOutcome();
- if (outcome != null && outcome.length() >= 0) {
- // if (isValidServiceOutcome(outcome))
- // {
- // return errorMessage;
- // }
- String webPath = ((PageflowPage) link.getSource()).getPath();
- if (webPath != null) {
- String projectPath = WebrootUtil.getProjectPath(link,
- webPath);
-
- Path resourcePath = new Path(projectPath);
- IWorkspaceRoot workspaceRoot = ResourcesPlugin
- .getWorkspace().getRoot();
- final IResource resource = workspaceRoot
- .findMember(resourcePath);
-
- if (resource == null || !resource.exists()) {
- // Pageflow.Validation.NotExistedSourcePage = The source
- // page {0} is not existed.
- errorMessage = NLS
- .bind(
- PageflowMessages.Pageflow_Validation_UndefinedOutcome,
- outcome, webPath);
- }
- } else {
- // Pageflow.Validation.MissingSourcePage = The source page
- // should be specified.
- errorMessage = PageflowMessages.Pageflow_Validation_MissingSourcePage;
- }
- }
- }
- return errorMessage;
- }
-
- /**
- * Check whether the page is already existed in the pageflow.
- *
- * @param pageflow
- * @param page
- * @return true if page exists (?)
- */
- public boolean isExistedPage(Pageflow pageflow, PageflowPage page) {
- if (pageflow == null || page == null || page.getPath() == null) {
- return false;
- }
-
- return isExistedPage(pageflow, page.getPath());
- }
-
- /**
- * Check whether the page is already existed in the pageflow.
- *
- * @param pageflow
- * @param pagePath
- * @return true if pageflow's path is equal to pagePath
- */
- public boolean isExistedPage(Pageflow pageflow, String pagePath) {
- if (pageflow == null || pagePath == null) {
- return false;
- }
-
- Iterator iter = pageflow.getNodes().iterator();
-
- while (iter.hasNext()) {
- PageflowNode existedNode = (PageflowNode) iter.next();
-
- if (existedNode instanceof PageflowPage) {
- if (((PageflowPage) existedNode).getPath() != null
- && ((PageflowPage) existedNode).getPath()
- .equalsIgnoreCase(pagePath)) {
- return true;
- }
- }
- }
-
- return false;
- }
-
- /**
- * Check whether the page is valid or not validate page is : 1. if the page
- * is general jsp page, it should physically existed. 2. if the page is in
- * the form of /foldername/* (it contains the folder), the folder should be
- * existed.
- *
- * @param page
- * @return the notify message for page
- */
- public String getNotifyMessage(PageflowPage page) {
- String errorMessage = null;
- IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace().getRoot();
- String pagePath = page.getPath();
-
- // Check the path is empty or not
- if (pagePath != null && pagePath.length() > 0) {
- String resourceName = WebrootUtil.getProjectPath(page, pagePath);
- Path resourcePath = new Path(resourceName);
-
- final IResource resource = workspaceRoot.findMember(resourcePath);
-
- if (resource != null && resource.exists()) {
- // This page is related with jsp file
- if (resourcePath.getFileExtension() != null) {
- if (!WebrootUtil.isValidWebFile(resourcePath)) {
- // Pageflow.Validation.InvalidWebPage = the file {0} is
- // not valid web file.
- errorMessage = NLS
- .bind(
- PageflowMessages.Pageflow_Validation_InvalidWebPage,
- pagePath);
- }
- }
- } else {
- // Pageflow.Validation.NotExitedWebPage = the web page {0} is
- // not existed.
- errorMessage = NLS.bind(
- PageflowMessages.Pageflow_Validation_NotExitedWebPage,
- pagePath);
- }
- } else {
- // Pageflow.Validation.MissingWebPage = the web page's path should
- // be specified.
- errorMessage = PageflowMessages.Pageflow_Validation_MissingWebPage;
- }
- return errorMessage;
- }
-
- /**
- * check that the action is valid EL or not,
- *
- * @param actionEL -
- * action string, it should be in the form of #{...}
- * @return - True or False
- */
- public static boolean isValidActionEL(String actionEL) {
- if (actionEL != null && actionEL.length() > 3) {
- // action is defined in JSF expression language, e.g,
- // #{beanname.methodname}
- if (actionEL.substring(0, 2).equalsIgnoreCase("#{")//$NON-NLS-1$
- && actionEL.substring(actionEL.length() - 1,
- actionEL.length()).equalsIgnoreCase("}"))//$NON-NLS-1$
- {
- // Check the bean is existed or not.
- return true;
- }
-
- }
- return false;
- }
-
- /**
- * get the managed bean from action's expression, e.g., beanName.methodName.
- * The return will be beanName.
- *
- * @param actionEL
- * @return the managed bean name
- */
- public static String getManagedBeanforAction(String actionEL) {
- String managedBeanName = null;
- if (isValidActionEL(actionEL)) {
- actionEL = actionEL.substring(2, actionEL.length() - 1);
- String[] actionParts = actionEL.split("[.]"); //$NON-NLS-1$
- managedBeanName = actionParts[0];
- }
-
- return managedBeanName;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseFigureDecorator.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseFigureDecorator.java
deleted file mode 100644
index ffe8a64f0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseFigureDecorator.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.draw2d.Label; import org.eclipse.draw2d.PositionConstants; import org.eclipse.draw2d.RotatableDecoration; import org.eclipse.draw2d.geometry.Point; import org.eclipse.draw2d.geometry.Rectangle; import org.eclipse.draw2d.geometry.Transform; import org.eclipse.jface.resource.JFaceResources; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.graphics.Image; /** * A figure decorator * */ /*package*/ class BaseFigureDecorator extends Label implements RotatableDecoration { /** * The default position for the decorator */ protected static int DEFAULT_DECORATOR_POSITION = PositionConstants.SOUTH_WEST; private Point location = new Point(); private Transform transform = new Transform(); private int position; /** * @param image */ public BaseFigureDecorator(Image image) { this.position = DEFAULT_DECORATOR_POSITION; setIcon(image); setSize(getPreferredSize()); } /** * @param image * @param tooltip */ public BaseFigureDecorator(Image image, String tooltip) { this.position = DEFAULT_DECORATOR_POSITION; setIcon(image); setSize(getPreferredSize()); setToolTip(new Label(tooltip)); } /** * @param image * @param tooltip * @param position */ public BaseFigureDecorator(Image image, String tooltip, int position) { this.position = position; setIcon(image); setSize(getPreferredSize()); setToolTip(new Label(tooltip)); } public Font getFont() { Font localFont = getLocalFont(); if (localFont == null) { localFont = JFaceResources.getFontRegistry().get( JFaceResources.DEFAULT_FONT); // TODO: it's not clear that setFont is correct to call // here since this does a revalidate if the font changes // whereas the deprecated assignment to font that it replaces // does not setFont(localFont); } return localFont; } /** * * @return Returns the position. * */ public int getPosition() { return position; } /** * * @param position * * The position to set. * */ public void setPosition(int position) { this.position = position; } /** * @param tooltip */ public void setToolTipText(String tooltip) { super.setToolTip(new Label(tooltip)); } /** * @return the label tool tip text */ public String getToolTipText() { Label label = (Label) super.getToolTip(); return label.getText(); } /** * * Sets the location of this PolygonDecoration. * * * * @param p * * the new location * */ public void setLocation(Point p) { bounds = null; location.setLocation(p); transform.setTranslation(p.x, p.y); } public Rectangle getBounds() { if (bounds == null) { if (prefSize == null) { getPreferredSize(); } int w = prefSize.width; int h = prefSize.height; Point p = location; // transform.getTransformed(new Point(w/2,h/2)); bounds = new Rectangle(p.x - w / 2, p.y - h / 2, w, h).getExpanded( w, h); } return bounds; } /** * * @see org.eclipse.draw2d.Figure#useLocalCoordinates() * */ protected boolean useLocalCoordinates() { return false; } /** * @param x * @param y */ public void setScale(double x, double y) { // TODO: figure out how to scale images bounds = null; transform.setScale(x, y); } /** * * Sets the rotation of this decoration so that the decoration points toward * the * * given reference point. * * @param ref * the reference point * * @see org.eclipse.draw2d.RotatableDecoration#setReferencePoint(org.eclipse.draw2d.geometry.Point) * */ public void setReferencePoint(Point ref) { // TODO: figure out how to rotate images bounds = null; Point pt = Point.SINGLETON; pt.setLocation(ref); pt.negate().translate(location); setRotation(Math.atan2(pt.y, pt.x)); } /** * * Sets the angle by which rotation is to be done on the PolygonDecoration. * * * * @param angle * Angle of rotation * * @since 2.0 * */ public void setRotation(double angle) { bounds = null; // transform.setRotation(angle); } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseNodeFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseNodeFigure.java
deleted file mode 100644
index 096bef977..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/BaseNodeFigure.java
+++ /dev/null
@@ -1,946 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Enumeration;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Vector;
-
-import org.eclipse.draw2d.ConnectionAnchor;
-import org.eclipse.draw2d.Figure;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Layer;
-import org.eclipse.draw2d.LayoutManager;
-import org.eclipse.draw2d.PolylineConnection;
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * The <code>BaseNodeFigure</code> class is the base class for all the figures
- * representing DiagramNodes, ie those that can have ports with maxConnections
- * to other nodes.
- *
- * Assumes that all NodeFigures have some number of input and output ports
- *
- * @author ddean
- *
- */
-/*package*/ class BaseNodeFigure extends Figure implements IBaseFigure {
- private IBaseFigure baseFigure;
-
- private boolean anchorsVisible = true;
-
- private Hashtable connectionAnchors = new Hashtable(7);
-
- private Vector inputConnectionAnchors = new Vector(2, 2);
-
- private Vector outputConnectionAnchors = new Vector(2, 2);
-
- private Vector topConnectionAnchors = new Vector();
-
- private Vector bottomConnectionAnchors = new Vector();
-
- private Vector leftConnectionAnchors = new Vector();
-
- private Vector rightConnectionAnchors = new Vector();
-
- /**
- * @param figure
- */
- public BaseNodeFigure(IBaseFigure figure) {
- setBaseFigure(figure);
- ObserveVisibleXYLayout layout = new ObserveVisibleXYLayout();
- layout.setObserveVisibility(true);
- setLayoutManager(layout);
- }
-
- /**
- * @param figure
- */
- public void setBaseFigure(IBaseFigure figure) {
- setBaseFigure(figure, new Rectangle(0, 0, -1, -1));
- }
-
- public void setHighlight(boolean flag) {
- if (baseFigure != null) {
- moveToTop(this, baseFigure);
- baseFigure.setHighlight(flag);
- }
- }
-
- /**
- * @param figure
- * @param constraint
- */
- public void setBaseFigure(IBaseFigure figure, Rectangle constraint) {
- if (!getChildren().contains(figure)) {
- if (getChildren().contains(baseFigure))
- remove(baseFigure);
-
- baseFigure = figure;
- if (!getChildren().contains(baseFigure)) {
- // CR389070: Figures are abbreviating rule figures names and
- // making them unreadable
- if (getParent() != null
- && getParent().getLayoutManager() != null) {
- Rectangle r = getBounds().getCopy();
- r.width = -1;
- r.height = -1;
- getParent().getLayoutManager().setConstraint(this, r);
- }
- // CR389495: Working with nested complex activities causes in
- // the BP editor causes lockup
- // ensure that constraints are set on figure before add() - this
- // will cause a layout()
- this.add(baseFigure, constraint, 0);
- }
- }
- }
-
- /**
- * @return the base figure
- */
- public IBaseFigure getBaseFigure() {
- return baseFigure;
- }
-
- /***************************************************************************
- * Input/Output Ports
- **************************************************************************/
-
- /**
- * Add an input port and its anchor
- *
- * @param portName
- * unique name to refer to the port
- */
- public void addInput(String portName) {
- InputPortFigure inputPort = new InputPortFigure();
- add(inputPort);
- inputPort.setToolTipText(portName);
-
- PortConnectionAnchor anchor = new PortConnectionAnchor(inputPort);
- getTargetConnectionAnchors().add(anchor);
- connectionAnchors.put(portName, anchor);
- }
-
- /**
- * Add an output port and its anchor
- *
- * @param portName
- * unique name to refer to the port
- * @return the connection anchor
- */
- public PortConnectionAnchor addOutput(String portName) {
- OutputPortFigure outputPort = new OutputPortFigure();
- add(outputPort);
- outputPort.setToolTipText(portName);
-
- PortConnectionAnchor anchor = new PortConnectionAnchor(outputPort);
- getSourceConnectionAnchors().add(anchor);
- connectionAnchors.put(portName, anchor);
- return anchor;
- }
-
- /**
- * Searches for and returns the anchor on this figure that is closest to the
- * reference point <code>p</code>
- *
- * @param p
- * the reference point
- * @return the anchor on this figure that is closest to <code>p</code>
- */
- public ConnectionAnchor connectionAnchorAt(Point p) {
- ConnectionAnchor closest = null;
- long min = Long.MAX_VALUE;
-
- Enumeration e = getSourceConnectionAnchors().elements();
- while (e.hasMoreElements()) {
- ConnectionAnchor c = (ConnectionAnchor) e.nextElement();
- Point p2 = c.getLocation(null);
- long d = p.getDistance2(p2);
- if (d < min) {
- min = d;
- closest = c;
- }
- }
- e = getTargetConnectionAnchors().elements();
- while (e.hasMoreElements()) {
- ConnectionAnchor c = (ConnectionAnchor) e.nextElement();
- Point p2 = c.getLocation(null);
- long d = p.getDistance2(p2);
- if (d < min) {
- min = d;
- closest = c;
- }
- }
- return closest;
- }
-
- /**
- * returns an anchor given its name
- *
- * @param portName
- * name of the anchor
- * @return the anchor with the name <code>portName</code>
- */
- public ConnectionAnchor getConnectionAnchor(String portName) {
- return (ConnectionAnchor) connectionAnchors.get(portName);
- }
-
- /**
- * returns the name of the specified anchor
- *
- * @param c
- * the anchor whose name is requested
- * @return the name of the specifed anchor
- */
- public String getConnectionAnchorName(ConnectionAnchor c) {
- Enumeration enumer = connectionAnchors.keys();
- String key;
- while (enumer.hasMoreElements()) {
- key = (String) enumer.nextElement();
- if (connectionAnchors.get(key).equals(c))
- return key;
- }
- return null;
- }
-
- /**
- * returns the source connection anchor that is closest to the reference
- * point
- *
- * @param p
- * the reference point
- * @return the closest connection anchor to <code>p</code>
- */
- public ConnectionAnchor getSourceConnectionAnchorAt(Point p) {
- ConnectionAnchor closest = null;
- long min = Long.MAX_VALUE;
-
- Enumeration e = getSourceConnectionAnchors().elements();
- while (e.hasMoreElements()) {
- ConnectionAnchor c = (ConnectionAnchor) e.nextElement();
- Point p2 = c.getLocation(null);
- long d = p.getDistance2(p2);
- if (d < min) {
- min = d;
- closest = c;
- }
- }
- return closest;
- }
-
- /**
- * returns all the source connection anchors on this node figure
- *
- * @return a vector of all the source connection anchors for this figure
- */
- public Vector getSourceConnectionAnchors() {
- return outputConnectionAnchors;
- }
-
- /**
- * returns the target connection anchor that is closest to the reference
- * point
- *
- * @param p
- * the reference point
- * @return the closest target connection anchor to <code>p</code>
- */
- public ConnectionAnchor getTargetConnectionAnchorAt(Point p) {
- ConnectionAnchor closest = null;
- long min = Long.MAX_VALUE;
-
- Enumeration e = getTargetConnectionAnchors().elements();
- while (e.hasMoreElements()) {
- ConnectionAnchor c = (ConnectionAnchor) e.nextElement();
- Point p2 = c.getLocation(null);
- long d = p.getDistance2(p2);
- if (d < min) {
- min = d;
- closest = c;
- }
- }
- return closest;
- }
-
- /**
- * returns all the target connection anchors on this node figure
- *
- * @return a vector of all the target connection anchors for this figure
- */
- public Vector getTargetConnectionAnchors() {
- return inputConnectionAnchors;
- }
-
- /**
- * Returns the name of the specified anchor
- *
- * @param anchor
- * the connectio anchor whose name is requested
- * @return the anchor's name
- */
- public String getNameForAnchor(ConnectionAnchor anchor) {
- if (anchor != null) {
- Iterator it = connectionAnchors.keySet().iterator();
- String name;
-
- while (it.hasNext()) {
- name = (String) it.next();
-
- if (anchor.equals(connectionAnchors.get(name))) {
- return name;
- }
- }
- }
- return null;
- }
-
- /**
- * @param visible
- */
- public void setAnchorsVisible(boolean visible) {
- if (anchorsVisible != visible) {
- anchorsVisible = visible;
- //ConnectionAnchor port;
- List all = new ArrayList();
- all.addAll(getTargetConnectionAnchors());
- all.addAll(getSourceConnectionAnchors());
- Iterator it = all.iterator();
- while (it.hasNext()) {
- IFigure fig = ((ConnectionAnchor) it.next()).getOwner();
- fig.setVisible(visible);
- }
- validate();
- }
- }
-
- /**
- * Determine which side of the figure to place each anchor based on the
- * relative position (north, south, east or west) of the connection line's
- * opposite anchor. If the anchor is not connected to anything else, the
- * default is to place target (input) anchors on the left and source
- * (output) anchors on the right.
- */
- private void determineAnchorPositions() {
- Iterator it;
- topConnectionAnchors.clear();
- bottomConnectionAnchors.clear();
- leftConnectionAnchors.clear();
- rightConnectionAnchors.clear();
-
- if (anchorsVisible) {
- //final Dimension size = baseFigure.getPreferredSize();
- PortConnectionAnchor port;
-
- // start with outputs
- it = getSourceConnectionAnchors().iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
- // CR386077: SplitActivity True and False outputs switch
- // positions based on their targets
- int direction = port.getOrientation();
- if (direction == PositionConstants.NONE) {
- Point loc = port.getOwner().getParent().getBounds()
- .getLocation();
- // loc.x += size.width/2;
- // loc.y += size.height/2;
- Iterator itc = port.getConnections().iterator();
- if (itc.hasNext()) {
- while (itc.hasNext()) {
- PolylineConnection conn = (PolylineConnection) itc
- .next();
- ConnectionAnchor otherPort;
- if (port == conn.getSourceAnchor())
- otherPort = conn.getTargetAnchor();
- else
- otherPort = conn.getSourceAnchor();
- if (otherPort.getOwner() == null)
- continue;
- Point otherLoc = otherPort.getOwner().getParent()
- .getBounds().getLocation();
- // Dimension otherSize =
- // ((BaseNodeFigure)otherPort.getOwner().getParent()).getBaseFigure().getPreferredSize();
- // otherLoc.x += otherSize.width/2;
- // otherLoc.y += otherSize.height/2;
- direction = loc.getPosition(otherLoc);
- if (direction == PositionConstants.NORTH)
- topConnectionAnchors.add(port);
- else if (direction == PositionConstants.SOUTH)
- bottomConnectionAnchors.add(port);
- else if (direction == PositionConstants.WEST)
- leftConnectionAnchors.add(port);
- else
- rightConnectionAnchors.add(port);
- ((PortFigure) port.getOwner())
- .setOrientation(direction);
- break; // currently, only the first connection is
- // considered
- }
- } else {
- rightConnectionAnchors.add(port);
- ((PortFigure) port.getOwner())
- .setOrientation(PositionConstants.EAST);
- }
- } else {
- // CR386077: SplitActivity True and False outputs switch
- // positions based on their targets
- if (direction == PositionConstants.NORTH)
- topConnectionAnchors.add(port);
- else if (direction == PositionConstants.SOUTH)
- bottomConnectionAnchors.add(port);
- else if (direction == PositionConstants.WEST)
- leftConnectionAnchors.add(port);
- else
- rightConnectionAnchors.add(port);
- }
- }
- it = getTargetConnectionAnchors().iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
- // CR386077: SplitActivity True and False outputs switch
- // positions based on their targets
- int direction = port.getOrientation();
- if (direction == PositionConstants.NONE) {
- Point loc = port.getOwner().getParent().getBounds()
- .getLocation();
- // loc.x += size.width/2;
- // loc.y += size.height/2;
- Iterator itc = port.getConnections().iterator();
- if (itc.hasNext()) {
- while (itc.hasNext()) {
- PolylineConnection conn = (PolylineConnection) itc
- .next();
- ConnectionAnchor otherPort;
- if (port == conn.getSourceAnchor())
- otherPort = conn.getTargetAnchor();
- else
- otherPort = conn.getSourceAnchor();
- if (otherPort.getOwner() == null)
- continue;
- Point otherLoc = otherPort.getOwner().getParent()
- .getBounds().getLocation();
- // Dimension otherSize =
- // ((BaseNodeFigure)otherPort.getOwner().getParent()).getBaseFigure().getPreferredSize();
- // otherLoc.x += otherSize.width/2;
- // otherLoc.y += otherSize.height/2;
- direction = loc.getPosition(otherLoc);
- if (direction == PositionConstants.NORTH)
- topConnectionAnchors.add(port);
- else if (direction == PositionConstants.SOUTH)
- bottomConnectionAnchors.add(port);
- else if (direction == PositionConstants.EAST)
- rightConnectionAnchors.add(port);
- else
- leftConnectionAnchors.add(port);
- ((PortFigure) port.getOwner())
- .setOrientation(direction);
- break; // currently, only the first connection is
- // considered
- }
- } else {
- leftConnectionAnchors.add(port);
- ((PortFigure) port.getOwner())
- .setOrientation(PositionConstants.WEST);
- }
- } else {
- // CR386077: SplitActivity True and False outputs switch
- // positions based on their targets
- if (direction == PositionConstants.NORTH)
- topConnectionAnchors.add(port);
- else if (direction == PositionConstants.SOUTH)
- bottomConnectionAnchors.add(port);
- else if (direction == PositionConstants.EAST)
- rightConnectionAnchors.add(port);
- else
- leftConnectionAnchors.add(port);
- }
- }
-
- Comparator comparePorts = new Comparator() {
- public int compare(Object arg0, Object arg1) {
- PortConnectionAnchor port0 = (PortConnectionAnchor) arg0;
- if (port0.getConnections().size() < 1)
- return 0;
- PortConnectionAnchor port1 = (PortConnectionAnchor) arg1;
- if (port1.getConnections().size() < 1)
- return 0;
- // CR386077: SplitActivity True and False outputs switch
- // positions based on their targets
- if (port0.getOrientation() != PositionConstants.NONE)
- return 0;
- if (port1.getOrientation() != PositionConstants.NONE)
- return 0;
-
- PolylineConnection conn0 = (PolylineConnection) port0
- .getConnections().get(0);
- ConnectionAnchor otherPort0;
- if (port0 == conn0.getSourceAnchor())
- otherPort0 = conn0.getTargetAnchor();
- else
- otherPort0 = conn0.getSourceAnchor();
- Point otherLoc0 = otherPort0.getOwner().getParent()
- .getBounds().getLocation();
- // Dimension otherSize0 =
- // ((BaseNodeFigure)otherPort0.getOwner().getParent()).getBaseFigure().getPreferredSize();
- // otherLoc0.x += otherSize0.width/2;
- // otherLoc0.y += otherSize0.height/2;
-
- PolylineConnection conn1 = (PolylineConnection) port1
- .getConnections().get(0);
- ConnectionAnchor otherPort1;
- if (port1 == conn1.getSourceAnchor())
- otherPort1 = conn1.getTargetAnchor();
- else
- otherPort1 = conn1.getSourceAnchor();
- Point otherLoc1 = otherPort1.getOwner().getParent()
- .getBounds().getLocation();
-// Dimension otherSize1 = ((BaseNodeFigure) otherPort1
-// .getOwner().getParent()).getBaseFigure()
-// .getPreferredSize();
- // otherLoc1.x += otherSize1.width/2;
- // otherLoc1.y += otherSize1.height/2;
-
- switch (((PortFigure) port0.getOwner()).getOrientation()) {
- case PositionConstants.NORTH:
- case PositionConstants.SOUTH:
- return otherLoc0.x - otherLoc1.x;
- case PositionConstants.EAST:
- case PositionConstants.WEST:
- return otherLoc0.y - otherLoc1.y;
- }
- return 0;
- }
- };
-
- // order the anchors on each side so connection lines don't cross
- Collections.sort(topConnectionAnchors, comparePorts);
- Collections.sort(leftConnectionAnchors, comparePorts);
- Collections.sort(bottomConnectionAnchors, comparePorts);
- Collections.sort(rightConnectionAnchors, comparePorts);
- }
- }
-
- private void placeAnchors() {
- determineAnchorPositions();
- if (anchorsVisible) {
- Iterator it;
- PortConnectionAnchor port;
- int y, x;
-
- Dimension sz = baseFigure.getPreferredSize();
- LayoutManager layout = getLayoutManager();
- // CR389070: Figures are abbreviating rule figures names and making
- // them unreadable
- Dimension d = getAnchorSize();
-
- // left ports
- x = 0;
- y = FigureConstants.PORT_SPACING / 2;
- // CR374981: Long activity labels do not get wrapped or truncated
- // keep a constant inset on all 4 sides of the icon
- // if ( topConnectionAnchors.size()>0 )
- y += d.height;
- y += (sz.height - (leftConnectionAnchors.size() * (d.height + FigureConstants.PORT_SPACING))) / 2;
- it = leftConnectionAnchors.iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
-
- Rectangle r = new Rectangle(x, y, -1, -1);
- Rectangle oldrect = (Rectangle) layout.getConstraint(port
- .getOwner());
- if (!r.equals(oldrect))
- layout.setConstraint(port.getOwner(), new Rectangle(x, y,
- -1, -1));
-
- y += d.height + FigureConstants.PORT_SPACING;
- }
-
- // right ports
- x = sz.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- x += d.width;
- y = FigureConstants.PORT_SPACING / 2;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- y += d.height;
- y += (sz.height - (rightConnectionAnchors.size() * (d.height + FigureConstants.PORT_SPACING))) / 2;
- it = rightConnectionAnchors.iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
-
- Rectangle r = new Rectangle(x, y, -1, -1);
- Rectangle oldrect = (Rectangle) layout.getConstraint(port
- .getOwner());
- if (!r.equals(oldrect))
- layout.setConstraint(port.getOwner(), new Rectangle(x, y,
- -1, -1));
-
- y += d.height + FigureConstants.PORT_SPACING;
- }
-
- // top ports
- y = 0;
- x = FigureConstants.PORT_SPACING / 2;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- x += d.width;
- x += (sz.width - (topConnectionAnchors.size() * (d.width + FigureConstants.PORT_SPACING))) / 2;
- it = topConnectionAnchors.iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
-
- Rectangle r = new Rectangle(x, y, -1, -1);
- Rectangle oldrect = (Rectangle) layout.getConstraint(port
- .getOwner());
- if (!r.equals(oldrect))
- layout.setConstraint(port.getOwner(), new Rectangle(x, y,
- -1, -1));
-
- x += d.width + FigureConstants.PORT_SPACING;
- }
-
- // bottom ports
- y = sz.height;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- y += d.height;
- x = FigureConstants.PORT_SPACING / 2;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- x += d.width;
- x += (sz.width - (bottomConnectionAnchors.size() * (d.width + FigureConstants.PORT_SPACING))) / 2;
- it = bottomConnectionAnchors.iterator();
- while (it.hasNext()) {
- port = (PortConnectionAnchor) it.next();
-
- Rectangle r = new Rectangle(x, y, -1, -1);
- Rectangle oldrect = (Rectangle) layout.getConstraint(port
- .getOwner());
- if (!r.equals(oldrect))
- layout.setConstraint(port.getOwner(), new Rectangle(x, y,
- -1, -1));
-
- x += d.width + FigureConstants.PORT_SPACING;
- }
- }
- }
-
- /**
- * CR389070: Figures are abbreviating rule figures names and making them
- * unreadable Anchor size is now dependent on icon size, not constant. Asks
- * the connection anchor for its size.
- */
- private Dimension getAnchorSize() {
- Dimension d = new Dimension(FigureConstants.PORT_SIDE,
- FigureConstants.PORT_SIDE);
- if (!connectionAnchors.isEmpty()) {
- Iterator iter = connectionAnchors.values().iterator();
- PortConnectionAnchor a = (PortConnectionAnchor) iter.next();
- d = a.getOwner().getPreferredSize();
- }
- return d;
- }
-
- /**
- * @return the anchor insets
- */
- protected final Insets getAnchorInsets() {
- Insets in = new Insets(0, 0, 0, 0);
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- Dimension d = getAnchorSize();
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- in.left = d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( rightConnectionAnchors.size()>0 )
- in.right = d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- in.top = d.height;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( bottomConnectionAnchors.size()>0 )
- in.bottom = d.height;
- return in;
- }
-
- public void invalidate() {
- super.invalidate();
- }
-
- /**
- * validate method override to arrange the input and output ports around the
- * links of the node figures
- */
- public void validate() {
- placeAnchors();
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- int x = 0;
- int y = 0;
- // if anchors are not visible (CompoundNodeFigure is maximized) always
- // set position at 0,0
- if (anchorsVisible) {
- Dimension d = getAnchorSize();
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- x = d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- y = d.height;
- }
- getLayoutManager().setConstraint(baseFigure,
- new Rectangle(x, y, -1, -1));
- layout();
- super.validate();
- }
-
- /***************************************************************************
- * Miscellaneous
- **************************************************************************/
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Figure#useLocalCoordinates()
- */
- protected boolean useLocalCoordinates() {
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.IFigure#setBounds(org.eclipse.draw2d.geometry.Rectangle)
- */
- public void setBounds(Rectangle rect) {
- Rectangle r = rect.getCopy();
- r.x = 0;
- r.y = 0;
- if (anchorsVisible) {
- // CR389070: Figures are abbreviating rule figures names and making
- // them unreadable
- Dimension d = getAnchorSize();
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- {
- r.x += d.width;
- r.width -= d.width;
- }
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( rightConnectionAnchors.size()>0 )
- r.width -= d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- {
- r.y += d.height;
- r.height -= d.height;
- }
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( bottomConnectionAnchors.size()>0 )
- r.height -= d.height;
- }
- baseFigure.setBounds(r);
- r.setLocation(rect.getLocation());
- super.setBounds(r);
- }
-
- public Rectangle getBounds() {
- Dimension size = baseFigure.getBounds().getSize();
- if (anchorsVisible) {
- // CR389070: Figures are abbreviating rule figures names and making
- // them unreadable
- Dimension d = getAnchorSize();
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- size.width += d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( rightConnectionAnchors.size()>0 )
- size.width += d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- size.height += d.height;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( bottomConnectionAnchors.size()>0 )
- size.height += d.height;
- }
- Rectangle r = super.getBounds();
- r.setSize(size);
- return r;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.IFigure#getPreferredSize(int, int)
- */
- public Dimension getPreferredSize(int wHint, int hHint) {
- Dimension size = baseFigure.getPreferredSize(wHint, hHint).getCopy();
- if (anchorsVisible) {
- // CR389070: Figures are abbreviating rule figures names and making
- // them unreadable
- Dimension d = getAnchorSize();
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( leftConnectionAnchors.size()>0 )
- size.width += d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( rightConnectionAnchors.size()>0 )
- size.width += d.width;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( topConnectionAnchors.size()>0 )
- size.height += d.height;
- // CR374981: Long activity labels do not get wrapped or truncated
- // if ( bottomConnectionAnchors.size()>0 )
- size.height += d.height;
- }
- return size;
- }
-
- private static void moveToTop(IFigure parent, IFigure child) {
- parent.getChildren().remove(child);
- parent.getChildren().add(child);
- }
-
- /**
- * move to top layer
- */
- protected final void moveToTop() {
- IFigure parent = getParent();
- IFigure child = this;
- while (parent != null && !(parent instanceof Layer)) {
- child = parent;
- parent = parent.getParent();
- }
- if (parent instanceof Layer) {
- parent.getChildren().remove(child);
- parent.getChildren().add(child);
- }
- }
-
- /***************************************************************************
- * IBaseFigure methods delegate to the baseFigure
- **************************************************************************/
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setText(java.lang.String)
- */
- public void setText(String text) {
- baseFigure.setText(text);
- }
-
- public void setIcon(Image image) {
- baseFigure.setIcon(image);
- }
-
- /**
- * The description property of a DiagramNode is displayed as a tool tip.
- * This method is used to set it. Passing a null or zero-length string will
- * remove the tool tip
- *
- * @param text
- * the description to use for this node's tool tip
- *
- * @see IBaseFigure#setToolTipText(java.lang.String)
- */
- public void setToolTipText(String text) {
- baseFigure.setToolTipText(text);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#addDecorator(com.sybase.stf.gem.diagram.editor.figures.BaseFigureDecorator)
- */
- public void addDecorator(BaseFigureDecorator decorator) {
- baseFigure.addDecorator(decorator);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator()
- */
- public void removeDecorator() {
- baseFigure.removeDecorator();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator(int)
- */
- public void removeDecorator(int position) {
- baseFigure.removeDecorator(position);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getDecorators()
- */
- public List getDecorators() {
- return baseFigure.getDecorators();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getText()
- */
- public String getText() {
- return baseFigure.getText();
- }
-
- /*
- * CR374981: Long activity labels do not get wrapped or truncated This
- * method was added to the IBaseFigure interface to support direct edit of
- * figure labels on the canvas.
- */
- public Rectangle getTextBounds() {
- Rectangle r = baseFigure.getTextBounds().getCopy();
- r.x += getBounds().x;
- r.y += getBounds().y;
- return r;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getIcon()
- */
- public Image getIcon() {
- return baseFigure.getIcon();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getToolTipText()
- */
- public String getToolTipText() {
- return baseFigure.getToolTipText();
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ColorFontFieldEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ColorFontFieldEditor.java
deleted file mode 100644
index 38744fcd4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ColorFontFieldEditor.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.core.runtime.Assert; import org.eclipse.jface.dialogs.IDialogConstants; import org.eclipse.jface.preference.FieldEditor; import org.eclipse.jface.preference.PreferenceConverter; import org.eclipse.jface.resource.ColorRegistry; import org.eclipse.jface.resource.JFaceResources; import org.eclipse.jface.resource.StringConverter; import org.eclipse.swt.SWT; import org.eclipse.swt.events.DisposeEvent; import org.eclipse.swt.events.DisposeListener; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.graphics.Color; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.graphics.FontData; import org.eclipse.swt.graphics.RGB; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.FontDialog; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Text; /** * * A field editor for a font type preference. * */ /*package*/ class ColorFontFieldEditor extends FieldEditor { private static final String ColorFontFieldEditor_ColorPref = "Color"; //$NON-NLS-1$ private static final int NUM_CONTROLS_WHEN_PREVIEWER = 4; private static final int NUM_CONTROLS_WHEN_NO_PREVIEWER = 3; /** * * The change font button, or <code>null</code> if none * * (before creation and after disposal). * */ private Button changeFontButton = null; /** * * The text for the change font button, or <code>null</code> * * if missing. * */ private String changeButtonText; /** * * The text for the preview, or <code>null</code> if no preview is desired * */ private String previewText; /** * * Font data for the chosen font button, or <code>null</code> if none. * */ private FontData[] chosenFont; /** * * Font color for the chosen font * */ private RGB fontRGB; /** * * The label that displays the selected font, or <code>null</code> if * none. * */ private Label valueControl; /** * * The previewer, or <code>null</code> if none. * */ private DefaultPreviewer previewer; /** * * Internal font previewer implementation. * */ private static class DefaultPreviewer { private Text text; private String string; private Font font; private Color color; /** * @param s * @param parent */ public DefaultPreviewer(String s, Composite parent) { string = s; text = new Text(parent, SWT.READ_ONLY | SWT.BORDER); text.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent e) { if (font != null) font.dispose(); } }); if (string != null) text.setText(string); } /** * @return the text control */ public Control getControl() { return text; } /** * @param fontData */ public void setFont(FontData[] fontData) { if (font != null && !font.isDisposed()) font.dispose(); font = new Font(text.getDisplay(), fontData); text.setFont(font); } /** * @param fontRGB */ public void setRGB(RGB fontRGB) { if (fontRGB != null) { if (color != null && !color.isDisposed()) color.dispose(); color = new Color(null, fontRGB); text.setForeground(color); } } /** * @return the preferred extent */ public int getPreferredExtent() { return 40; } } /** * * Creates a new font field editor * */ protected ColorFontFieldEditor() { // control instantiation } /** * * Creates a font field editor with an optional preview area. * * * * @param name * the name of the preference this field editor works on * * @param labelText * the label text of the field editor * * @param previewAreaText * the text used for the preview window. If it is * * <code>null</code> there will be no preview area, * * @param parent * the parent of the field editor's control * */ public ColorFontFieldEditor( String name, String labelText, String previewAreaText, Composite parent) { init(name, labelText); previewText = previewAreaText; changeButtonText = JFaceResources.getString("openChange"); //$NON-NLS-1$ createControl(parent); } /** * * Creates a font field editor without a preview. * * * * @param name * the name of the preference this field editor works on * * @param labelText * the label text of the field editor * * @param parent * the parent of the field editor's control * */ public ColorFontFieldEditor(String name, String labelText, Composite parent) { this(name, labelText, null, parent); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void adjustForNumColumns(int numColumns) { GridData data = new GridData(); if (valueControl.getLayoutData() != null) data = (GridData) valueControl.getLayoutData(); data.horizontalSpan = numColumns - getNumberOfControls() + 1; valueControl.setLayoutData(data); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void applyFont() { if (chosenFont != null && previewer != null) previewer.setFont(chosenFont); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void doFillIntoGrid(Composite parent, int numColumns) { getLabelControl(parent); valueControl = getValueControl(parent); GridData gd = new GridData(GridData.FILL_HORIZONTAL | GridData.GRAB_HORIZONTAL); gd.horizontalSpan = numColumns - getNumberOfControls() + 1; valueControl.setLayoutData(gd); if (previewText != null) { previewer = new DefaultPreviewer(previewText, parent); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = previewer.getPreferredExtent(); gd.widthHint = previewer.getPreferredExtent(); previewer.getControl().setLayoutData(gd); } changeFontButton = getChangeControl(parent); gd = new GridData(); int widthHint = convertHorizontalDLUsToPixels(changeFontButton, IDialogConstants.BUTTON_WIDTH); gd.widthHint = Math.max(widthHint, changeFontButton.computeSize( SWT.DEFAULT, SWT.DEFAULT, true).x); changeFontButton.setLayoutData(gd); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void doLoad() { if (changeFontButton == null) return; fontRGB = PreferenceConverter.getColor(getPreferenceStore(), getPreferenceName() + ColorFontFieldEditor_ColorPref); updateFont(PreferenceConverter.getFontDataArray(getPreferenceStore(), getPreferenceName())); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void doLoadDefault() { if (changeFontButton == null) return; updateFont(PreferenceConverter.getDefaultFontDataArray( getPreferenceStore(), getPreferenceName())); } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ protected void doStore() { if (chosenFont != null) { PreferenceConverter.setValue(getPreferenceStore(), getPreferenceName(), chosenFont); } if (fontRGB != null) { PreferenceConverter.setValue(getPreferenceStore(), getPreferenceName() + ColorFontFieldEditor_ColorPref, fontRGB); } } /** * * Returns the change button for this field editor. * * * @param parent * @return the change button * */ protected Button getChangeControl(Composite parent) { if (changeFontButton == null) { changeFontButton = new Button(parent, SWT.PUSH); if (changeButtonText != null) changeFontButton.setText(changeButtonText); changeFontButton.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent event) { FontDialog fontDialog = new FontDialog(changeFontButton .getShell()); if (chosenFont != null) fontDialog.setFontList(chosenFont); if (fontRGB != null) fontDialog.setRGB(fontRGB); FontData font = fontDialog.open(); if (font != null) { FontData[] oldFont = chosenFont; if (oldFont == null) oldFont = JFaceResources.getDefaultFont() .getFontData(); setPresentsDefaultValue(false); FontData[] newData = new FontData[1]; newData[0] = font; fontRGB = fontDialog.getRGB(); updateFont(newData); fireValueChanged(VALUE, oldFont[0], font); } } }); changeFontButton.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent event) { changeFontButton = null; } }); changeFontButton.setFont(parent.getFont()); setButtonLayoutData(changeFontButton); } else checkParent(changeFontButton, parent); return changeFontButton; } /* * (non-Javadoc) * * Method declared on FieldEditor. * */ public int getNumberOfControls() { if (previewer == null) { return NUM_CONTROLS_WHEN_NO_PREVIEWER; } return NUM_CONTROLS_WHEN_PREVIEWER; } /** * * Returns the preferred preview height. * * * * @return the height, or <code>-1</code> if no previewer * * is installed * */ public int getPreferredPreviewHeight() { if (previewer == null) return -1; return previewer.getPreferredExtent(); } /** * * Returns the preview control for this field editor. * * * * @return the preview control * */ public Control getPreviewControl() { if (previewer == null) return null; return previewer.getControl(); } /** * * Returns the value control for this field editor. The value control * * displays the currently selected font name. * @param parent * * * * @return the value control * */ protected Label getValueControl(Composite parent) { if (valueControl == null) { valueControl = new Label(parent, SWT.LEFT); valueControl.setFont(parent.getFont()); valueControl.addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent event) { valueControl = null; } }); } else checkParent(valueControl, parent); return valueControl; } /** * * Sets the text of the change button. * * * * @param text * the new text * */ public void setChangeButtonText(String text) { Assert.isNotNull(text); changeButtonText = text; if (changeFontButton != null) changeFontButton.setText(text); } /** * * Updates the change font button and the previewer to reflect the * * newly selected font. * */ private void updateFont(FontData font[]) { FontData[] bestFont = JFaceResources.getFontRegistry().filterData( font, valueControl.getDisplay()); // if we have nothing valid do as best we can if (bestFont == null) bestFont = getDefaultFontData(); // Now cache this value in the receiver this.chosenFont = bestFont; if (valueControl != null) { if (fontRGB != null) { ColorRegistry registry = JFaceResources.getColorRegistry(); Color color = registry.get(fontRGB.toString()); if (color == null) { registry.put(fontRGB.toString(), fontRGB); color = registry.get(fontRGB.toString()); } valueControl.setForeground(color); } valueControl.setText(StringConverter.asString(chosenFont[0])); } if (previewer != null) { previewer.setFont(bestFont); } } /** * * Store the default preference for the field * * being edited * */ protected void setToDefault() { FontData[] defaultFontData = PreferenceConverter .getDefaultFontDataArray(getPreferenceStore(), getPreferenceName()); PreferenceConverter.setValue(getPreferenceStore(), getPreferenceName(), defaultFontData); } /** * * Get the system default font data. * */ private FontData[] getDefaultFontData() { return valueControl.getDisplay().getSystemFont().getFontData(); } /* * * @see FieldEditor.setEnabled(boolean,Composite). * */ public void setEnabled(boolean enabled, Composite parent) { super.setEnabled(enabled, parent); getChangeControl(parent).setEnabled(enabled); getValueControl(parent).setEnabled(enabled); } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ComboFieldEditor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ComboFieldEditor.java
deleted file mode 100644
index 53ce7b21c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ComboFieldEditor.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.core.runtime.Assert; import org.eclipse.jface.preference.FieldEditor; import org.eclipse.swt.SWT; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.widgets.Combo; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; /** * * A field editor for a combo box that allows the drop-down selection of one of * a list of items. * */ /*package*/ class ComboFieldEditor extends FieldEditor { /** * * The <code>Combo</code> widget. * */ private Combo fCombo; /** * * The value (not the name) of the currently selected item in the Combo * widget. * */ private String fValue; /** * * The names (labels) and underlying values to populate the combo widget. * These should be * * arranged as: { {name1, value1}, {name2, value2}, ...} * */ private String[][] fEntryNamesAndValues; /** * @param name * @param labelText * @param entryNamesAndValues * @param parent */ public ComboFieldEditor(String name, String labelText, String[][] entryNamesAndValues, Composite parent) { init(name, labelText); Assert.isTrue(checkArray(entryNamesAndValues)); fEntryNamesAndValues = entryNamesAndValues; createControl(parent); } /** * * Checks whether given <code>String[][]</code> is of "type" * * <code>String[][2]</code>. * * * * @return <code>true</code> if it is ok, and <code>false</code> * otherwise * */ private boolean checkArray(String[][] table) { if (table == null) { return false; } for (int i = 0; i < table.length; i++) { String[] array = table[i]; if (array == null || array.length != 2) { return false; } } return true; } /** * * @see FieldEditor#adjustForNumColumns(int) * */ protected void adjustForNumColumns(int numColumns) { if (numColumns > 1) { Control control = getLabelControl(); int left = numColumns; if (control != null) { ((GridData) control.getLayoutData()).horizontalSpan = 1; left = left - 1; } ((GridData) fCombo.getLayoutData()).horizontalSpan = left; } else { Control control = getLabelControl(); if (control != null) { ((GridData) control.getLayoutData()).horizontalSpan = 1; } ((GridData) fCombo.getLayoutData()).horizontalSpan = 1; } } /** * * @see FieldEditor#doFillIntoGrid(Composite, int) * */ protected void doFillIntoGrid(Composite parent, int numColumns) { int comboC = 1; if (numColumns > 1) { comboC = numColumns - 1; } Control control = getLabelControl(parent); GridData gd = new GridData(); gd.horizontalSpan = 1; control.setLayoutData(gd); control = getComboBoxControl(parent); gd = new GridData(); gd.horizontalSpan = comboC; gd.horizontalAlignment = GridData.FILL; control.setLayoutData(gd); } /** * * @see FieldEditor#doLoad() * */ protected void doLoad() { updateComboForValue(getPreferenceStore().getString(getPreferenceName())); } /** * * @see FieldEditor#doLoadDefault() * */ protected void doLoadDefault() { updateComboForValue(getPreferenceStore().getDefaultString( getPreferenceName())); } /** * * @see FieldEditor#doStore() * */ protected void doStore() { if (fValue == null) { getPreferenceStore().setToDefault(getPreferenceName()); return; } getPreferenceStore().setValue(getPreferenceName(), fValue); } /** * * @see FieldEditor#getNumberOfControls() * */ public int getNumberOfControls() { return 1; } /** * * Lazily create and return the Combo control. * @param parent * @return the combo box * */ public Combo getComboBoxControl(Composite parent) { if (fCombo == null) { fCombo = new Combo(parent, SWT.READ_ONLY); for (int i = 0; i < fEntryNamesAndValues.length; i++) { fCombo.add(fEntryNamesAndValues[i][0], i); } fCombo.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent evt) { String oldValue = fValue; String name = fCombo.getText(); fValue = getValueForName(name); setPresentsDefaultValue(false); fireValueChanged(VALUE, oldValue, fValue); } }); } return fCombo; } /** * * Given the name (label) of an entry, return the corresponding value. * @param name * @return the value corresponding to name or the first value if * not found * */ protected String getValueForName(String name) { for (int i = 0; i < fEntryNamesAndValues.length; i++) { String[] entry = fEntryNamesAndValues[i]; if (name.equals(entry[0])) { return entry[1]; } } return fEntryNamesAndValues[0][0]; } /** * * Set the name in the combo widget to match the specified value. * @param value * */ protected void updateComboForValue(String value) { fValue = value; for (int i = 0; i < fEntryNamesAndValues.length; i++) { if (value.equals(fEntryNamesAndValues[i][1])) { fCombo.setText(fEntryNamesAndValues[i][0]); return; } } if (fEntryNamesAndValues.length > 0) { fValue = fEntryNamesAndValues[0][1]; } } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundFigureListener.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundFigureListener.java
deleted file mode 100644
index c2646482f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundFigureListener.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-/**
- * @author bbrodt
- *
- * Interface definition for listeners of CompoundFigure events. Events are
- * generated when a user presses a different tab (tabChanged event) or presses
- * one of the minimize/maximize/restore buttons (stateChanged event)
- */
-/*package*/ interface CompoundFigureListener extends WindowFigureListener {
- /**
- * @param oldState
- * @param newState
- */
- void stateChanged(int oldState, int newState);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundNodeFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundNodeFigure.java
deleted file mode 100644
index 8de3c5eec..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/CompoundNodeFigure.java
+++ /dev/null
@@ -1,480 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.Iterator;
-
-import org.eclipse.draw2d.ActionEvent;
-import org.eclipse.draw2d.ActionListener;
-import org.eclipse.draw2d.FreeformFigure;
-import org.eclipse.draw2d.FreeformListener;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.Layer;
-import org.eclipse.draw2d.LayoutManager;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * The figure for Compound nodes
- */
-/*package*/ class CompoundNodeFigure extends BaseNodeFigure implements
- FreeformFigure, IContainerFigure {
-
- private static final String RESTORE_HILITE_IMAGE_FILE = "restore_hilite.gif"; //$NON-NLS-1$
-
- private static final String RESTORE_IMAGE_FILE = "restore.gif"; //$NON-NLS-1$
-
- private static final String MAXIMIZE_HILITE_IMAGE_FILE = "maximize_hilite.gif"; //$NON-NLS-1$
-
- private static final String MAXIMIZE_IMAGE_FILE = "maximize.gif"; //$NON-NLS-1$
-
- private static final String MINIMIZE_HILITE_IMAGE_FILE = "minimize_hilite.gif"; //$NON-NLS-1$
-
- private static final String MINIMIZE_IMAGE_FILE = "minimize.gif"; //$NON-NLS-1$
-
- private final static int MINIMIZED = 1;
-
- final static int RESTORED = 2;
-
- private final static int MAXIMIZED = 3;
-
- private int state = RESTORED;
-
- private TitleBarButton minButton;
-
- private TitleBarButton maxButton;
-
- private IconFigure iconFigure;
-
- private WindowFigure windowFigure;
-
- private static String DEFAULT_NAME = "CompoundNode"; //$NON-NLS-1$
-
- private static String DEFAULT_ICON = "editor/CompoundNode.gif"; //$NON-NLS-1$
-
- private static Image minimizeImage = EditorPlugin.getDefault().getImage(
- MINIMIZE_IMAGE_FILE);
-
- private static Image minimizeHiliteImage = EditorPlugin.getDefault()
- .getImage(MINIMIZE_HILITE_IMAGE_FILE);
-
- private static Image maximizeImage = EditorPlugin.getDefault().getImage(
- MAXIMIZE_IMAGE_FILE);
-
- private static Image maximizeHiliteImage = EditorPlugin.getDefault()
- .getImage(MAXIMIZE_HILITE_IMAGE_FILE);
-
- private static Image restoreImage = EditorPlugin.getDefault().getImage(
- RESTORE_IMAGE_FILE);
-
- private static Image restoreHiliteImage = EditorPlugin.getDefault()
- .getImage(RESTORE_HILITE_IMAGE_FILE);
-
- /**
- * Default constructor
- */
- public CompoundNodeFigure() {
- // create all of the figures and adornments:
- // the icon figure
- super(new IconFigure(DEFAULT_NAME, EditorPlugin.getDefault().getImage(
- DEFAULT_ICON)));
- iconFigure = (IconFigure) getBaseFigure();
- // and the window figure
- windowFigure = new WindowFigure();
- windowFigure.setForegroundColor(IconFigure.defaultForegroundColor);
- windowFigure.setFont(IconFigure.defaultFont);
-
- // then the minimize/maximize buttons.
- // Note that the maxButton is also used for the "Restore" action
- // TODO:
- // The reason for putting these buttons in CompoundNodeFigure instead of
- // WindowFigure where they really belong, is that the TitleBarButton is
- // a
- // draw2d Button (which subclasses Figure) and these must be placed in
- // the
- // titlebar (i.e. a SchemeBorder) because that's where they belong. The
- // problem
- // with this is that the Figure.paint() method first draws all of its
- // children
- // figures, then the border which means that the buttons would be
- // obscured.
- // This should be fixed as time allows and the WindowFigureListener
- // interface
- // should then also be modified to include a buttonPressed()
- // notification
- // for which CompoundNodeFigure can be a listener.
- minButton = new TitleBarButton(minimizeImage, minimizeHiliteImage,
- null, null);
- maxButton = new TitleBarButton(maximizeImage, maximizeHiliteImage,
- restoreImage, restoreHiliteImage);
-
- add(minButton);
- add(maxButton);
-
- minButton.addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent event) {
- setState(CompoundNodeFigure.MINIMIZED);
- }
- });
- maxButton.addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent event) {
- setState(maxButton.getState() ? CompoundNodeFigure.MAXIMIZED
- : CompoundNodeFigure.RESTORED);
- }
- });
-
- // show as a normal window initially
- showIcon();
-
- // testing BaseFigureDecorators:
- // BaseFigureDecorator decorator;
- // decorator = new
- // BaseFigureDecorator(EditorPlugin.getDefault().getGEMImage("delete.gif"),
- // "top right",
- // PositionConstants.NORTH_EAST);
- // addDecorator(decorator);
- // decorator = new
- // BaseFigureDecorator(EditorPlugin.getDefault().getGEMImage("delete.gif"),
- // "top left",
- // PositionConstants.NORTH_WEST);
- // addDecorator(decorator);
- // decorator = new
- // BaseFigureDecorator(EditorPlugin.getDefault().getGEMImage("delete.gif"),
- // "bottom right",
- // PositionConstants.SOUTH_EAST);
- // addDecorator(decorator);
- // decorator = new
- // BaseFigureDecorator(EditorPlugin.getDefault().getGEMImage("delete.gif"),
- // "bottom left",
- // PositionConstants.SOUTH_WEST);
- // addDecorator(decorator);
- }
-
- public void setOpaque(boolean flag) {
- windowFigure.setOpaque(flag);
- }
-
- /*
- * Remove the window figure and its buttons and replace them with the icon
- * figure.
- */
- private void showIcon() {
- // CR400779: GEM minimizing a complex activity sometimes leaves junk on
- // the screen
- setVisible(false);
- minButton.setVisible(false);
- maxButton.setVisible(false);
- super.setBaseFigure(iconFigure);
-
- setAnchorsVisible(true);
- // CR400779: GEM minimizing a complex activity sometimes leaves junk on
- // the screen
- setVisible(true);
- }
-
- /*
- * Remove the icon figure and replace with the window figure. Make sure the
- * buttons are reset to their correct states.
- */
- private void showWindow() {
- // CR400779: GEM minimizing a complex activity sometimes leaves junk on
- // the screen
- setVisible(false);
- if (state == RESTORED) {
- super.setBaseFigure(windowFigure);
-
- minButton.setVisible(true);
- minButton.setState(false);
- minButton.setToolTip(new Label(PreferenceMessages.CompoundNodeFigure_MinimizeLabel));
-
- maxButton.setVisible(true);
- maxButton.setState(false);
- maxButton.setToolTip(new Label(PreferenceMessages.CompoundNodeFigure_MaximizeLabel));
-
- setAnchorsVisible(true);
- } else if (state == MAXIMIZED) {
- setAnchorsVisible(false);
-
- Rectangle constraint = new Rectangle(0, 0, -1, -1);
- IFigure parent = getParent();
- if (parent != null) {
- constraint = parent.getBounds().getCopy();
- constraint.width += constraint.x;
- constraint.height += constraint.y;
- constraint.x = 0;
- constraint.y = 0;
- }
-
- super.setBaseFigure(windowFigure, constraint);
- if (parent != null && parent.getLayoutManager() != null) {
- // System.out.println("CompoundNode.showWindow: maximize
- // "+constraint);
- parent.getLayoutManager().setConstraint(this, constraint);
- }
-
- // the maximize button is used for both Maximize and Restore actions
- minButton.setVisible(false);
-
- maxButton.setVisible(true);
- maxButton.setState(true);
- maxButton.setToolTip(new Label(PreferenceMessages.CompoundNodeFigure_RestoreLabel));
- }
- // CR400779: GEM minimizing a complex activity sometimes leaves junk on
- // the screen
- setVisible(true);
- }
-
- public void addDecorator(BaseFigureDecorator decorator) {
- iconFigure.addDecorator(decorator);
- }
-
- public void removeDecorator() {
- iconFigure.removeDecorator();
- }
-
- public void removeDecorator(int position) {
- iconFigure.removeDecorator(position);
- }
-
- /**
- * @param flag
- */
- public void setHilight(boolean flag) {
- windowFigure.setHighlight(flag);
- if (flag)
- moveToTop();
- }
-
- public void setText(String name) {
- iconFigure.setText(name);
- windowFigure.setText(name);
- }
-
- public void setIcon(Image image) {
- iconFigure.setIcon(image);
- }
-
- public void setToolTipText(String text) {
- iconFigure.setToolTipText(text);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Figure#layout()
- */
- public void validate() {
- LayoutManager layout = getLayoutManager();
- if (state == MINIMIZED) {
- // iconFigure.validate();
- } else if (state == RESTORED) {
- Rectangle r = windowFigure.getBounds().getCopy();
- Insets i = windowFigure.getInsets();
- Dimension dm = maxButton.getSize();
- Insets p = windowFigure.getTabbedTitleBarBorder().getPadding();
- layout.setConstraint(maxButton, new Rectangle(r.x + r.width
- - dm.width - p.right - i.right, r.y + p.top + i.top
- - dm.height - i.bottom, -1, -1));
- layout.setConstraint(minButton, new Rectangle(r.x + r.width - 2
- * dm.width - 2 * p.right - i.right, r.y + p.top + i.top
- - dm.height - i.bottom, -1, -1));
- } else if (state == MAXIMIZED) {
- // CR387660: restore icon on complex activity bounces around
- // we need to use the parent's bounds when maximized instead of
- // current window bounds
- if (getParent() == null)
- return;
- Rectangle r = getParent().getBounds().getCopy();
- Insets i = windowFigure.getInsets();
- Dimension dm = maxButton.getSize();
- Insets p = windowFigure.getTabbedTitleBarBorder().getPadding();
- layout.setConstraint(maxButton, new Rectangle(r.x + r.width
- - dm.width - p.right - i.right, r.y + p.top, -1, -1));
- }
- super.validate();
- }
- /**
- * @return the window figure
- */
- public WindowFigure getWindowFigure() {
- return windowFigure;
- }
-
- public void setFont(Font f) {
- iconFigure.setFont(f);
- windowFigure.setFont(f);
- }
-
- public void setForegroundColor(Color c) {
- iconFigure.setForegroundColor(c);
- windowFigure.setForegroundColor(c);
- }
-
- public void setBackgroundColor(Color c) {
- iconFigure.setBackgroundColor(c);
- windowFigure.setBackgroundColor(c);
- }
-
- /**
- * @return the state
- */
- public int getState() {
- return state;
- }
-
- /**
- * @param newState
- */
- public void setState(int newState) {
- int oldState = state;
- state = newState;
-
- if (state == CompoundNodeFigure.MINIMIZED) {
- if (getParent() != null && getParent().getLayoutManager() != null) {
- Rectangle constraint = (Rectangle) getParent()
- .getLayoutManager().getConstraint(this);
- constraint.width = -1;
- constraint.height = -1;
- }
- showIcon();
- } else if (state == CompoundNodeFigure.MAXIMIZED) {
- if (getParent() != null && getParent().getLayoutManager() != null) {
- Rectangle constraint = (Rectangle) getParent()
- .getLayoutManager().getConstraint(this);
- constraint.x = 0;
- constraint.y = 0;
- constraint.width = -1;
- constraint.height = -1;
- }
- showWindow();
- } else if (state == CompoundNodeFigure.RESTORED) {
- if (getParent() != null && getParent().getLayoutManager() != null) {
- Rectangle constraint = (Rectangle) getParent()
- .getLayoutManager().getConstraint(this);
- constraint.setSize(windowFigure.getBounds().getSize());
- }
- showWindow();
- }
- fireStateChanged(oldState, newState);
- }
-
- private void fireStateChanged(int oldState, int newState) {
- Object l[] = windowFigure.getTabbedTitleBarBorder().getListeners();
- for (int i = 0; i < l.length; ++i) {
- if (l[i] instanceof CompoundFigureListener)
- ((CompoundFigureListener) l[i])
- .stateChanged(oldState, newState);
- }
- }
-
- public Dimension getMinimumSize(int wHint, int hHint) {
- if (getState() == CompoundNodeFigure.RESTORED) {
- Dimension d = windowFigure.getMinimumSize(wHint, hHint);
- d.width += minButton.getSize().width
- + maxButton.getSize().width
- + 2
- * windowFigure.getTabbedTitleBarBorder().getPadding()
- .getWidth();
- return d;
- }
- if (getState() == CompoundNodeFigure.MINIMIZED)
- return iconFigure.getMinimumSize(wHint, hHint);
- return super.getMinimumSize(wHint, hHint);
- }
-
- // //////////////////////////////////////////////////////////////////////
- // FreeformFigure methods
- // //////////////////////////////////////////////////////////////////////
-
- private WindowFreeformHelper helper = new WindowFreeformHelper(this);
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#addFreeformListener(org.eclipse.draw2d.FreeformListener)
- */
- public void addFreeformListener(FreeformListener listener) {
- addListener(FreeformListener.class, listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#fireExtentChanged()
- */
- public void fireExtentChanged() {
- // CR389495: Working with nested complex activities causes in the BP
- // editor causes lockup
- // not specifically related to this CR, but caused a problem when
- // compound node
- // was moved beyond viewport's client area and de-selected - this would
- // resize
- // the viewport so that compound node no longer participated in bounds
- // calculation.
- if (state == MAXIMIZED) {
- Iterator iter = getListeners(FreeformListener.class);
- while (iter.hasNext())
- ((FreeformListener) iter.next()).notifyFreeformExtentChanged();
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#getFreeformExtent()
- */
- public Rectangle getFreeformExtent() {
- // CR389495: Working with nested complex activities causes in the BP
- // editor causes lockup
- // same as above
- if (state == MAXIMIZED)
- return helper.getFreeformExtent();
- return getBounds();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#removeFreeformListener(org.eclipse.draw2d.FreeformListener)
- */
- public void removeFreeformListener(FreeformListener listener) {
- removeListener(FreeformListener.class, listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#setFreeformBounds(org.eclipse.draw2d.geometry.Rectangle)
- */
- public void setFreeformBounds(Rectangle bounds) {
- if (getState() == MAXIMIZED)
- helper.setFreeformBounds(bounds);
- }
-
- /*
- * CR389070: Figures are abbreviating rule figures names and making them
- * unreadable New Method on IContainerFigure
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IContainerFigure#getLayer(java.lang.Object)
- */
- public Layer getLayer(Object key) {
- if (windowFigure != null && windowFigure.isVisible())
- return windowFigure.getLayer(key);
- return null;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/FigureConstants.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/FigureConstants.java
deleted file mode 100644
index bb57abe47..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/FigureConstants.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; /** * * * * Constants for figure dimensions, etc. used in the sample app * */ /*package*/ class FigureConstants { /** * * * */ private FigureConstants() { // no external instantiation } /** * the default dimension of a port anchor */ public static final int PORT_SIDE = 10; // (int)Math.round( ARROW_SIDE * // Math.cos( 30 ) ); // CR389070: Figures are abbreviating rule figures names and making them // unreadable /** * the y port spacing value */ public static final int PORT_SPACING = 2; // ARROW_SIDE / 2; // this is the type of port; input or output /** * identifies a port that is an input */ public static int INPUT_PORT = 0; /** * identifies a port that is an output */ public static int OUTPUT_PORT = 1; } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/GEMPreferences.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/GEMPreferences.java
deleted file mode 100644
index ea0cfd704..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/GEMPreferences.java
+++ /dev/null
@@ -1,792 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.ColorFieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.IntegerFieldEditor;
-import org.eclipse.jface.preference.PreferenceConverter;
-import org.eclipse.jface.resource.ColorRegistry;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.RGB;
-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.Group;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * This class represents a preference page that is contributed to the
- * Preferences dialog. By subclassing <samp>FieldEditorPreferencePage </samp>,
- * we can use the field support built into JFace that allows us to create a page
- * that is small and knows how to save, restore and apply itself.
- * <p>
- * This page is used to modify preferences only. They are stored in the
- * preference store that belongs to the main plug-in class. That way,
- * preferences can be accessed directly via the preference store.
- */
-
-public final class GEMPreferences extends FieldEditorPreferencePage implements
- IWorkbenchPreferencePage {
- // appearance
- /**
- * Key for preference for whether or not the intro editor should be shown
- */
- public final static String SHOW_INTRO_EDITOR = "ShowIntroEditor"; //$NON-NLS-1$
-
- /**
- * use system colors preference
- */
- public final static String USE_SYSTEM_COLORS = "UseSystemColors"; //$NON-NLS-1$
-
- /**
- * canvas color preference
- */
- public final static String CANVAS_COLOR = "CanvasColor"; //$NON-NLS-1$
-
- /**
- * figure label font
- */
- public final static String FIGURE_LABEL_FONT = "FigureLabelFont"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String FIGURE_LABEL_FONT_COLOR = "FigureLabelFontColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LABEL_PLACEMENT = "LabelPlacement"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String INPUT_PORT_COLOR = "InputPortColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String OUTPUT_PORT_COLOR = "OutputPortColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String SHOW_LINE_LABELS = "ShowLineLabels"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_LABEL_FONT = "LineLabelFont"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_LABEL_FONT_COLOR = "LineLabelFontColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_LABEL_COLOR = "LineLabelColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_WIDTH = "LineWidth"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_COLOR = "LineColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LINE_ROUTING = "LineRouting"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String SNAP_TO_GRID = "SnapToGrid"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String SNAP_TO_GEOMETRY = "SnapToGeometry"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String GRID_WIDTH = "GridWidth"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String GRID_HEIGHT = "GridHeight"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String GRID_COLOR = "GridColor"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LABEL_PLACEMENT_TOP = "Top"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LABEL_PLACEMENT_BOTTOM = "Bottom"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LABEL_PLACEMENT_LEFT = "Left"; //$NON-NLS-1$
-
- /**
- *
- */
- public final static String LABEL_PLACEMENT_RIGHT = "Right"; //$NON-NLS-1$
-
- //
- /**
- * "Direct" routing was intended for connections lines without bendpoints;
- * this has been removed because it is unnecessary.
- * public final static String LINE_ROUTING_DIRECT = "Direct";
- * "Manhattan" line routing creates orthogonal lines
- */
- public final static String LINE_ROUTING_MANHATTAN = "Manhattan"; //$NON-NLS-1$
-
- /**
- * "Manual" routing allows user to create bendpoints
- */
- public final static String LINE_ROUTING_MANUAL = "Manaul"; //$NON-NLS-1$
-
- private final static String[][] m_lineRoutingLabels = {
- // display, key
- // { GEMPlugin.getResourceString("CanvasPreferences.LABEL.Direct"),
- // LINE_ROUTING_DIRECT }, //$NON-NLS-1$ //$NON-NLS-2$
- {
- PreferenceMessages.CanvasPreferences_LABEL_Manual, LINE_ROUTING_MANUAL },
- {
- PreferenceMessages.CanvasPreferences_LABEL_Manhattan, LINE_ROUTING_MANHATTAN }
- };
-
- private final static String[][] m_labelPlacementLabels = {
- {
- PreferenceMessages.CanvasPreferences_LABEL_Top, LABEL_PLACEMENT_TOP },
- {
- PreferenceMessages.CanvasPreferences_LABEL_Bottom, LABEL_PLACEMENT_BOTTOM },
- {
- PreferenceMessages.CanvasPreferences_LABEL_Left, LABEL_PLACEMENT_LEFT },
- {
- PreferenceMessages.CanvasPreferences_LABEL_Right, LABEL_PLACEMENT_RIGHT }
- };
-
- private Group canvasGroup;
-
- private Group iconGroup;
-
- private Group lineGroup;
-
- private BooleanField useSystemColors;
-
- private ColorFieldEditor canvasColor;
-
- private BooleanField snapToGrid;
-
- private IntegerFieldEditor gridWidth;
-
- private IntegerFieldEditor gridHeight;
-
- private ColorFieldEditor gridColor;
-
- private BooleanField showLineLabels;
-
- private ColorFieldEditor lineLabelColor;
-
- private ColorFieldEditor lineColor;
-
- private ColorFontFieldEditor iconFont;
-
- private ColorFontFieldEditor lineFont;
-
- // private ColorFieldEditor inputPortColor;
- //
- // private ColorFieldEditor outputPortColor;
-
- // CR392586: resource leaks
- // at least keep leaks bounded...
-// private static Hashtable resourceRegistry = new Hashtable();
-
- private class BooleanField extends BooleanFieldEditor {
- private Composite parent;
-
- /**
- * @param name
- * @param label
- * @param parent
- */
- public BooleanField(String name, String label, Composite parent) {
- super(name, label, parent);
- this.parent = parent;
- }
-
- /**
- * @return the change control button
- */
- public Button getButton() {
- return getChangeControl(parent);
- }
- }
-
- /**
- * Constructor
- */
- public GEMPreferences() {
- super(GRID);
- // FIXME: we should be encapsulating what pref store is used for all callers of this class
- setPreferenceStore(EditorPlugin.getDefault().getPreferenceStore());
- setDescription(PreferenceMessages.GEMPreferences_description);
- initializeDefaults();
- }
-
- /**
- * Sets the default values of the preferences.
- */
- private void initializeDefaults() {
- IPreferenceStore store = getPreferenceStore();
- Font f = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
-
- store.setDefault(SHOW_INTRO_EDITOR, true);
- store.setDefault(USE_SYSTEM_COLORS, true);
- PreferenceConverter.setDefault(store, CANVAS_COLOR, new RGB(255, 255,
- 255));
- PreferenceConverter.setDefault(store, FIGURE_LABEL_FONT, f
- .getFontData());
- store.setDefault(LINE_WIDTH, 1);
- store.setDefault(LINE_ROUTING, getLineRoutingLabels()[0][1]);
- store.setDefault(SHOW_LINE_LABELS, true);
- PreferenceConverter.setDefault(store, LINE_COLOR, new RGB(0, 0, 0));
- PreferenceConverter.setDefault(store, LINE_LABEL_COLOR, new RGB(255,
- 255, 255));
- PreferenceConverter.setDefault(store, LINE_LABEL_FONT, f.getFontData());
- store.setDefault(SNAP_TO_GEOMETRY, true);
- store.setDefault(SNAP_TO_GRID, true);
- store.setDefault(GRID_WIDTH, 12);
- store.setDefault(GRID_HEIGHT, 12);
- PreferenceConverter.setDefault(store, GRID_COLOR,
- new RGB(230, 230, 230));
- }
-
- /**
- * Creates the field editors. Field editors are abstractions of the common
- * GUI blocks needed to manipulate various types of preferences. Each field
- * editor knows how to save and restore itself.
- */
-
- public void createFieldEditors() {
-
- // note, we aren't saving the reference. It's assumed that parent
- // worries about destruction, persistence etc.
- addBooleanField(
- SHOW_INTRO_EDITOR,
- PreferenceMessages.EditorPreferences_LABEL_ShowIntroEditor,
- getFieldEditorParent());
-
- useSystemColors = addBooleanField(
- USE_SYSTEM_COLORS,
- PreferenceMessages.CanvasPreferenceTab_LABEL_UseSystemColors,
- getFieldEditorParent());
-
- canvasGroup = new Group(getFieldEditorParent(), SWT.NULL);
- lineGroup = new Group(getFieldEditorParent(), SWT.NULL);
- iconGroup = new Group(getFieldEditorParent(), SWT.NULL);
-
- canvasGroup.setText(PreferenceMessages.CanvasPreferenceTab_LABEL_Canvas);
- canvasColor = addColorField(
- CANVAS_COLOR,
- PreferenceMessages.CanvasPreferenceTab_LABEL_BackgroundColor, canvasGroup);
- addBooleanField(
- SNAP_TO_GEOMETRY,
- PreferenceMessages.CanvasPreferenceTab_LABEL_SnapToGeometry, canvasGroup);
- snapToGrid = addBooleanField(
- SNAP_TO_GRID,
- PreferenceMessages.CanvasPreferenceTab_LABEL_SnapToGrid, canvasGroup);
- gridColor = addColorField(
- GRID_COLOR,
- PreferenceMessages.CanvasPreferenceTab_LABEL_GridLineColor, canvasGroup);
- gridWidth = addIntegerField(
- GRID_WIDTH,
- PreferenceMessages.CanvasPreferenceTab_LABEL_GridWidth, canvasGroup);
- gridHeight = addIntegerField(
- GRID_HEIGHT,
- PreferenceMessages.CanvasPreferenceTab_LABEL_GridHeight, canvasGroup);
-
- iconGroup.setText(PreferenceMessages.CanvasPreferenceTab_LABEL_IconGroup);
- iconFont = addFontField(
- FIGURE_LABEL_FONT,
- PreferenceMessages.CanvasPreferenceTab_LABEL_IconLabelFont, iconGroup);
- addComboField(LABEL_PLACEMENT, PreferenceMessages.CanvasPreferenceTab_LABEL_LabelPlacement,
- getLabelPlacementLabels(), iconGroup);
- // inputPortColor = addColorField(
- // INPUT_PORT_COLOR,
- // EditorPlugin
- // .getResourceString("CanvasPreferenceTab.LABEL.InputPortColor"),
- // iconGroup); //$NON-NLS-1$
- // outputPortColor = addColorField(
- // OUTPUT_PORT_COLOR,
- // EditorPlugin
- // .getResourceString("CanvasPreferenceTab.LABEL.OutputPortColor"),
- // iconGroup); //$NON-NLS-1$
-
- lineGroup.setText(PreferenceMessages.CanvasPreferenceTab_LABEL_LineGroup);
- showLineLabels = addBooleanField(SHOW_LINE_LABELS, PreferenceMessages.CanvasPreferenceTab_LABEL_ShowLineLabels,
- lineGroup);
- lineFont = addFontField(
- LINE_LABEL_FONT,
- PreferenceMessages.CanvasPreferenceTab_LABEL_LineLabelFont, lineGroup);
- lineLabelColor = addColorField(
- LINE_LABEL_COLOR,
- PreferenceMessages.CanvasPreferenceTab_LABEL_LineLabelColor, lineGroup);
- lineColor = addColorField(
- LINE_COLOR,
- PreferenceMessages.CanvasPreferenceTab_LABEL_LineColor, lineGroup);
- addIntegerField(
- LINE_WIDTH,
- PreferenceMessages.CanvasPreferenceTab_LABEL_LineWidth, lineGroup);
- addComboField(LINE_ROUTING, PreferenceMessages.CanvasPreferenceTab_LABEL_LineRouting,
- getLineRoutingLabels(), lineGroup);
- }
-
- protected void initialize() {
- // Color use: Default canvas colors should pick up system defaults
- // enable or disable all of the color and font selection controls in the
- // preference dialog
- // depending on whether the "Use System Colors" checkbox is selected.
- super.initialize();
-
- ((GridLayout) getFieldEditorParent().getLayout()).numColumns = 2;
-
- canvasGroup.setLayout(new GridLayout(3, false));
- canvasGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- canvasColor.fillIntoGrid(canvasGroup, 3);
- gridColor.fillIntoGrid(canvasGroup, 3);
-
- iconGroup.setLayout(new GridLayout(3, false));
- iconGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- iconFont.fillIntoGrid(iconGroup, 3);
-
- lineGroup.setLayout(new GridLayout(3, false));
- lineGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- lineColor.fillIntoGrid(lineGroup, 3);
- lineLabelColor.fillIntoGrid(lineGroup, 3);
- lineFont.fillIntoGrid(lineGroup, 3);
-
- boolean userColorsValue = !useSystemColors.getBooleanValue();
- boolean showLineLabelsValue = showLineLabels.getBooleanValue();
- boolean snapToGridValue = snapToGrid.getBooleanValue();
- canvasColor.setEnabled(userColorsValue, canvasGroup);
- gridColor.setEnabled(snapToGridValue && userColorsValue, canvasGroup);
- iconFont.setEnabled(userColorsValue, iconGroup);
- // inputPortColor.setEnabled(userColorsValue, iconGroup);
- // outputPortColor.setEnabled(userColorsValue, iconGroup);
- lineColor.setEnabled(userColorsValue, lineGroup);
- lineLabelColor.setEnabled(showLineLabelsValue && userColorsValue,
- lineGroup);
- lineFont.setEnabled(showLineLabelsValue && userColorsValue, lineGroup);
- gridWidth.setEnabled(snapToGridValue, canvasGroup);
- gridHeight.setEnabled(snapToGridValue, canvasGroup);
-
- useSystemColors.getButton().addSelectionListener(
- new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- boolean userColorsValue_ = !useSystemColors
- .getBooleanValue();
- boolean showLineLabelsValue_ = showLineLabels
- .getBooleanValue();
- boolean snapToGridValue_ = snapToGrid.getBooleanValue();
-
- canvasColor.setEnabled(userColorsValue_, canvasGroup);
- gridColor
- .setEnabled(snapToGridValue_ && userColorsValue_,
- canvasGroup);
- iconFont.setEnabled(userColorsValue_, iconGroup);
- // inputPortColor.setEnabled(userColorsValue,
- // iconGroup);
- // outputPortColor.setEnabled(userColorsValue,
- // iconGroup);
- lineColor.setEnabled(userColorsValue_, lineGroup);
- lineLabelColor.setEnabled(showLineLabelsValue_
- && userColorsValue_, lineGroup);
- lineFont.setEnabled(showLineLabelsValue_
- && userColorsValue_, lineGroup);
- }
- });
-
- showLineLabels.getButton().addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- boolean userColorsValue_ = !useSystemColors.getBooleanValue();
- boolean showLineLabelsValue_ = showLineLabels.getBooleanValue();
- lineLabelColor.setEnabled(showLineLabelsValue_
- && userColorsValue_, lineGroup);
- lineFont.setEnabled(showLineLabelsValue_ && userColorsValue_,
- lineGroup);
- }
- });
-
- snapToGrid.getButton().addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- boolean userColorsValue_ = !useSystemColors.getBooleanValue();
- boolean snapToGridValue_ = snapToGrid.getBooleanValue();
-
- gridColor.setEnabled(snapToGridValue_ && userColorsValue_,
- canvasGroup);
- gridWidth.setEnabled(snapToGridValue_, canvasGroup);
- gridHeight.setEnabled(snapToGridValue_, canvasGroup);
- }
- });
-
- }
-
- public void init(IWorkbench workbench) {
- // no initialization
- }
-
- private ColorFieldEditor addColorField(String name, String labelText,
- Composite parent) {
- ColorFieldEditor f = new ColorFieldEditor(name, labelText, parent);
- addField(f);
- return f;
- }
-
- private ComboFieldEditor addComboField(String name, String labelText,
- String[][] entryNamesAndValues, Composite parent) {
- ComboFieldEditor f = new ComboFieldEditor(name, labelText,
- entryNamesAndValues, parent);
- addField(f);
- return f;
- }
-
- private IntegerFieldEditor addIntegerField(String name, String labelText,
- Composite parent) {
- IntegerFieldEditor f = new IntegerFieldEditor(name, labelText, parent);
- addField(f);
- return f;
- }
-
- private BooleanField addBooleanField(String name, String labelText,
- Composite parent) {
- BooleanField f = new BooleanField(name, labelText, parent);
- addField(f);
- return f;
- }
-
-// private StringFieldEditor addStringField(String name, String labelText,
-// Composite parent) {
-// StringFieldEditor f = new StringFieldEditor(name, labelText, parent);
-// addField(f);
-// return f;
-// }
-
- // protected NumberField addNumberField(String name, String labelText,
- // Composite parent)
- // {
- // NumberField f = new NumberField(name,labelText,parent);
- // addField(f);
- // return f;
- // }
-
- private ColorFontFieldEditor addFontField(String name, String labelText,
- Composite parent) {
- ColorFontFieldEditor f = new ColorFontFieldEditor(name, labelText,
- parent);
- addField(f);
- return f;
- }
-
- private static String[][] getLineRoutingLabels() {
- return m_lineRoutingLabels;
- }
-
- private static String[][] getLabelPlacementLabels() {
- return m_labelPlacementLabels;
- }
-
-// private static void propagateProperty(String property, EditPart part) {
-// Iterator iter = part.getChildren().iterator();
-// while (iter.hasNext()) {
-// EditPart child = (EditPart) iter.next();
-// Figure fig = (Figure) ((GraphicalEditPart) child).getFigure();
-// GEMPreferences.propagateProperty(property, fig);
-// propagateProperty(property, child);
-// }
-// }
-
- /**
- * @return true if the preference is set to show the introduction
- * editor. false otherwise.
- */
- public static boolean getShowIntroEditor()
- {
- IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
- return store.getBoolean(SHOW_INTRO_EDITOR);
- }
-
- /**
- * @param store
- * @param property
- * @return the color property for the key 'property'
- */
- public static Color getColor(IPreferenceStore store, String property) {
- boolean useSystemColors = store.getBoolean(USE_SYSTEM_COLORS);
-
- Color c = ColorConstants.black;
- if (useSystemColors) {
- if (GRID_COLOR.equals(property))
- // c = ColorConstants.buttonDarkest;
- c = ColorConstants.button;
- if (LINE_COLOR.equals(property))
- c = ColorConstants.listForeground;
- if (LINE_LABEL_FONT_COLOR.equals(property))
- c = ColorConstants.listForeground;
- if (LINE_LABEL_COLOR.equals(property))
- c = ColorConstants.listBackground;
- if (CANVAS_COLOR.equals(property))
- c = ColorConstants.listBackground;
- if (INPUT_PORT_COLOR.equals(property))
- c = ColorConstants.listForeground;
- if (OUTPUT_PORT_COLOR.equals(property))
- c = ColorConstants.listForeground;
- if (FIGURE_LABEL_FONT_COLOR.equals(property))
- c = ColorConstants.listForeground;
- } else {
- // CR392586: resource leaks
- RGB rgb = PreferenceConverter.getColor(store, property);
- ColorRegistry registry = JFaceResources.getColorRegistry();
- if (registry.get(rgb.toString()) != null)
- return registry.get(rgb.toString());
- registry.put(rgb.toString(), rgb);
- c = registry.get(rgb.toString());
- }
- return c;
- }
-
-// // CR392586: resource leaks
-// private static Font getFont(IPreferenceStore store, String property) {
-// FontData fd = PreferenceConverter.getFontData(store, property);
-// FontRegistry registry = JFaceResources.getFontRegistry();
-// if (!registry.get(fd.toString()).equals(registry.defaultFont()))
-// return registry.get(fd.toString());
-//
-// registry.put(fd.toString(), new FontData[] {fd});
-// return registry.get(fd.toString());
-// }
-
-// private static void propagateProperty(String property, Figure fig) {
-// IPreferenceStore store = EditorPlugin.getDefault().getPreferenceStore();
-// WindowFigure window = null;
-// IconFigure icon = null;
-// LinkFigure link = null;
-// if (fig instanceof CompoundNodeFigure) {
-// window = ((CompoundNodeFigure) fig).getWindowFigure();
-// icon = ((CompoundNodeFigure) fig).getIconFigure();
-// } else if (fig instanceof WindowFigure)
-// window = (WindowFigure) fig;
-// else if (fig instanceof LinkFigure)
-// link = (LinkFigure) fig;
-//
-// if (property != null && property.equals(USE_SYSTEM_COLORS))
-// // reload all properties - it's easiest
-// property = null;
-//
-// if (property == null || SNAP_TO_GRID.equals(property)) {
-// boolean b = store.getBoolean(SNAP_TO_GRID);
-// WindowFigure.defaultGridEnabled = b;
-//
-// if (window != null)
-// window.getGridLayer().setVisible(b);
-// }
-//
-// if (property == null || GRID_WIDTH.equals(property)
-// || GRID_HEIGHT.equals(property)) {
-// Dimension d = new Dimension(store.getInt(GRID_WIDTH), store
-// .getInt(GRID_HEIGHT));
-// WindowFigure.defaultGridSpacing = d;
-//
-// if (window != null)
-// window.getGridLayer().setSpacing(d);
-// }
-//
-// if (property == null || GRID_COLOR.equals(property)) {
-// Color c = getColor(store, GRID_COLOR);
-// WindowFigure.defaultGridColor = c;
-//
-// if (window != null)
-// window.getGridLayer().setForegroundColor(c);
-// }
-//
-// // TODO: since the line router is managed by the EditPart for the
-// // container figure, setting the line routing style in the WindowFigure
-// // does not change the line routing immediately. The editor must be
-// // restarted for line routing to take effect.
-// if (property == null || LINE_ROUTING.equals(property)) {
-// String s = store.getString(LINE_ROUTING);
-// int style;
-// if (LINE_ROUTING_MANHATTAN.equals(s))
-// style = WindowFigure.LINE_ROUTING_MANHATTAN;
-// else
-// style = WindowFigure.LINE_ROUTING_MANUAL;
-//
-// WindowFigure.defaultLineRoutingStyle = style;
-// if (window != null)
-// window.setLineRoutingStyle(style);
-// }
-//
-// if (property == null || LINE_WIDTH.equals(property)) {
-// int w = store.getInt(LINE_WIDTH);
-// LinkFigure.defaultLineWidth = w;
-//
-// if (link != null)
-// link.setLineWidth(w);
-// }
-//
-// if (property == null || LINE_COLOR.equals(property)) {
-// Color c = getColor(store, LINE_COLOR);
-// LinkFigure.defaultLineColor = c;
-//
-// if (link != null)
-// link.setForegroundColor(c);
-// }
-//
-// if (property == null || SHOW_LINE_LABELS.equals(property)) {
-// boolean b = store.getBoolean(SHOW_LINE_LABELS);
-// LinkFigure.defaultLabelVisible = b;
-//
-// if (link != null)
-// link.setLabelVisible(b);
-// }
-//
-// if (property == null || LINE_LABEL_FONT.equals(property)
-// || LINE_LABEL_FONT_COLOR.equals(property)) {
-// // CR392586: resource leaks
-// Font f = getFont(store, LINE_LABEL_FONT);
-// Color c = getColor(store, LINE_LABEL_FONT_COLOR);
-// LinkFigure.defaultFont = f;
-// LinkFigure.defaultLabelForeground = c;
-//
-// if (link != null) {
-// link.setFont(f);
-// link.setLabelForeground(c);
-// }
-// }
-//
-// if (property == null || LINE_LABEL_COLOR.equals(property)) {
-// Color c = getColor(store, LINE_LABEL_COLOR);
-// LinkFigure.defaultLabelBackground = c;
-//
-// if (link != null)
-// link.setLabelBackground(c);
-// }
-//
-// if (property == null || CANVAS_COLOR.equals(property)) {
-// Color c = getColor(store, CANVAS_COLOR);
-// WindowFigure.defaultBackgroundColor = c;
-//
-// if (window != null)
-// window.setBackgroundColor(c);
-// if (icon != null)
-// icon.setBackgroundColor(c);
-// }
-//
-// if (property == null || INPUT_PORT_COLOR.equals(property)) {
-// Color c = getColor(store, INPUT_PORT_COLOR);
-// InputPortFigure.defaultForegroundColor = c;
-//
-// if (fig instanceof InputPortFigure)
-// fig.setForegroundColor(c);
-// }
-//
-// if (property == null || OUTPUT_PORT_COLOR.equals(property)) {
-// Color c = getColor(store, OUTPUT_PORT_COLOR);
-// OutputPortFigure.defaultForegroundColor = c;
-//
-// if (fig instanceof OutputPortFigure)
-// fig.setForegroundColor(c);
-// }
-//
-// if (property == null || FIGURE_LABEL_FONT.equals(property)
-// || FIGURE_LABEL_FONT_COLOR.equals(property)) {
-// // CR392586: resource leaks
-// Font f = getFont(store, FIGURE_LABEL_FONT);
-// Color c = getColor(store, FIGURE_LABEL_FONT_COLOR);
-// IconFigure.defaultFont = f;
-// IconFigure.defaultForegroundColor = c;
-// WindowFigure.defaultFont = f;
-// WindowFigure.defaultForegroundColor = c;
-//
-// if (window != null) {
-// window.setFont(f);
-// window.setForegroundColor(c);
-// }
-// if (icon != null) {
-// icon.setFont(f);
-// icon.setForegroundColor(c);
-// }
-// if (fig instanceof IconFigure) {
-// fig.setFont(f);
-// fig.setForegroundColor(c);
-// }
-// }
-//
-// if (property == null || LABEL_PLACEMENT.equals(property)) {
-// int placement = PositionConstants.SOUTH;
-// String s = store.getString(LABEL_PLACEMENT);
-// if (LABEL_PLACEMENT_TOP.equals(s))
-// placement = PositionConstants.NORTH;
-// if (LABEL_PLACEMENT_BOTTOM.equals(s))
-// placement = PositionConstants.SOUTH;
-// if (LABEL_PLACEMENT_LEFT.equals(s))
-// placement = PositionConstants.WEST;
-// if (LABEL_PLACEMENT_RIGHT.equals(s))
-// placement = PositionConstants.EAST;
-// IconFigure.defaultTextPlacement = placement;
-//
-// if (icon != null)
-// icon.setTextPlacement(placement);
-// if (fig instanceof IconFigure)
-// ((IconFigure) fig).setTextPlacement(placement);
-// }
-//
-// Iterator iter = fig.getChildren().iterator();
-// while (iter.hasNext()) {
-// Figure child = (Figure) iter.next();
-// propagateProperty(property, child);
-// }
-// }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IBaseFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IBaseFigure.java
deleted file mode 100644
index 41196365f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IBaseFigure.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.List;
-
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Bob
- */
-/*package*/ interface IBaseFigure extends IFigure
-{
- /**
- * @param text
- */
- public abstract void setText(String text);
-
- /**
- * @return the text
- */
- public abstract String getText();
-
- /**
- * CR374981: Long activity labels do not get wrapped or truncated This
- * method was added to the IBaseFigure interface to support direct edit of
- * figure labels on the canvas.
- * @return the text bounds rectangle
- */
- public abstract Rectangle getTextBounds();
-
- /**
- * @param image
- */
- public abstract void setIcon(Image image);
-
- /**
- * @return the icon
- */
- public abstract Image getIcon();
-
- /**
- * @param text
- */
- public abstract void setToolTipText(String text);
-
- /**
- * @return the tool tip text
- */
- public abstract String getToolTipText();
-
- /**
- * @param flag
- */
- public abstract void setHighlight(boolean flag);
-
- /**
- * Add decorator. May
- * cause the figure to become invalidated
- * @param decorator
- */
- public abstract void addDecorator(BaseFigureDecorator decorator);
-
- /**
- * Remove the decorator
- */
- public abstract void removeDecorator();
-
- /**
- * @param position
- */
- public abstract void removeDecorator(int position);
-
- /**
- * @return the list of decoractors
- */
- public abstract List getDecorators();
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IContainerFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IContainerFigure.java
deleted file mode 100644
index 4de2acbd5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IContainerFigure.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.draw2d.Layer; /** * * @author bbrodt * * * * This class extends IBaseFigure by including a layer accessor. * */ /*package*/ interface IContainerFigure extends IBaseFigure { /** * @param key * @return the layer of key */ public Layer getLayer(Object key); } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IconFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IconFigure.java
deleted file mode 100644
index 1336edc08..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/IconFigure.java
+++ /dev/null
@@ -1,415 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.draw2d.AncestorListener;
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.Layer;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.XYLayout;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * And IconFigure consists of a bitmap image with a text label below it.
- *
- * @author bbrodt
- */
-/*package*/ class IconFigure extends Label implements IBaseFigure {
- private static int defaultTextPlacement = PositionConstants.SOUTH;
-
- static Font defaultFont = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
-
- static Color defaultForegroundColor = ColorConstants.black;
-
- private ArrayList decorators;
-
- private IconLabel iconLabel = null;
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- // New class that implements a separate "floating" label which is NOT
- // included in bounds calculations for this IconFigure
- private class IconLabel extends Label {
- private LabelLocator locator;
-
- private IconFigure host;
-
- /**
- * @param host
- * @param text
- */
- public IconLabel(IconFigure host, String text) {
- super(text);
- this.host = host;
- locator = new LabelLocator(this);
- }
-
- /**
- * @return the icon figure
- */
- public IconFigure getHost() {
- return host;
- }
-
- public Dimension getPreferredSize(int wHint, int hHing) {
- return host.getTextBounds().getSize();
- }
-
- public void setText(String text) {
- super.setText(text);
- if (locator != null)
- locator.setConstraints();
- }
-
- public void invalidate() {
- if (locator != null)
- locator.setConstraints();
- super.invalidate();
- }
- }
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- // helper class that relocates the IconLabel whenever ancestor is moved or
- // added/removed
- private class LabelLocator implements AncestorListener {
- IconLabel label;
-
- /**
- * @param label
- */
- public LabelLocator(IconLabel label) {
- this.label = label;
- label.getHost().addAncestorListener(this);
- }
-
- // CR408950: BP Save problems
- // fixed icon label refresh problems
- private Layer getParentLayer() {
- IFigure fig = label.getHost();
- while (fig != null) {
- if (fig instanceof Layer)
- return (Layer) fig;
- fig = fig.getParent();
- }
- return null;
- }
-
- public void ancestorAdded(IFigure ancestor) {
- Layer layer = getParentLayer();
- if (layer != null && !layer.getChildren().contains(label)) {
- layer.add(label);
- setConstraints();
- }
- }
-
- public void ancestorMoved(IFigure ancestor) {
- setConstraints();
- }
-
- public void ancestorRemoved(IFigure ancestor) {
- // CR400779: GEM minimizing a complex activity sometimes leaves junk
- // on the screen
- if (label.getParent() != null
- && label.getParent().getChildren().contains(label))
- label.getParent().remove(label);
- }
-
- /**
- *
- */
- public void setConstraints() {
- Layer layer = getParentLayer();
- if (layer != null && layer.getLayoutManager() != null
- && layer.getChildren().contains(label)) {
- Rectangle r = IconFigure.this.getParent().getBounds().getCopy();
- r.translate(IconFigure.this.getBounds().getLocation());
- r.translate(IconFigure.this.getTextLocation());
- r.width = -1;
- r.height = -1;
- Rectangle oldr = (Rectangle) layer.getLayoutManager()
- .getConstraint(label);
- if (oldr == null || oldr.x != r.x || oldr.y != r.y)
- layer.setConstraint(label, r);
- }
- }
- }
-
- /**
- * @param name
- * @param icon
- */
- public IconFigure(String name, Image icon) {
- super(name, icon);
- setTextPlacement(defaultTextPlacement);
- setOpaque(false);
- setIcon(icon);
- setIconTextGap(0);
- setForegroundColor(defaultForegroundColor);
- // CR396303: DND in RulePanel does not get correct location if viewer is
- // scrolled
- setBackgroundColor(ColorConstants.titleGradient);
- XYLayout layout = new XYLayout();
- setLayoutManager(layout);
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- iconLabel = new IconLabel(this, name);
- iconLabel.setFont(getFont());
- }
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- /**
- * @return the label
- */
- public Label getLabel() {
- return iconLabel;
- }
-
- public List getDecorators() {
- if (decorators == null)
- decorators = new ArrayList();
- return decorators;
- }
-
- public Font getFont() {
- if (defaultFont == null)
- {
- defaultFont = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
- }
-
- if (getLocalFont() == null)
- {
- // TODO: replaced a deprecated assignment to font
- // with this, but the behaviour is a little different
- setFont(defaultFont);
- }
-
- return getLocalFont();
- }
-
- public void setFont(Font f) {
- Font localFont = getLocalFont();
- if (localFont != f) {
- iconLabel.setFont(f);
- }
- super.setFont(f);
- }
-
- public void setVisible(boolean visible) {
- super.setVisible(visible);
- iconLabel.setVisible(visible);
- }
-
- public void setText(String text) {
- super.setText(text);
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- if (iconLabel != null && iconLabel.isVisible()) {
- iconLabel.setText(text);
- iconLabel.setFont(getFont());
- // labelLocator.setConstraints();
- }
- }
-
- public void setToolTipText(String text) {
- Label toolTipLabel = null;
-
- if (text != null && text.length() > 0) {
- toolTipLabel = new Label(text);
- toolTipLabel.setBorder(new MarginBorder(3));
- }
-
- super.setToolTip(toolTipLabel);
- }
-
- public String getToolTipText() {
- if (getToolTip() != null)
- return ((Label) getToolTip()).getText();
- return null;
- }
-
- public void setHighlight(boolean flag) {
- if (flag)
- setOpaque(true);
- else
- setOpaque(false);
- }
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- protected Dimension getSubStringTextSize() {
- return getTextSize();
- }
-
- /*
- * CR374981: Long activity labels do not get wrapped or truncated We must
- * override this so that the label gets truncated
- */
- public Dimension getPreferredSize(int wHint, int hHint) {
- if (prefSize == null) {
- super.getPreferredSize(-1, -1);
- prefSize.width = getIconBounds().getSize().width;
- Dimension minSize_ = getMinimumSize(wHint, hHint);
- if (prefSize.width < minSize_.width)
- prefSize.width = minSize_.width;
- if (prefSize.height < minSize_.height)
- prefSize.height = minSize_.height;
- }
- return prefSize;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.IFigure#getMinimumSize(int, int)
- */
- public Dimension getMinimumSize(int w, int h) {
- return new Dimension(8, 8);
- }
-
- public void addDecorator(BaseFigureDecorator decorator) {
- removeDecorator(decorator.getPosition());
- getDecorators().add(decorator);
- add(decorator);
- invalidate();
- }
-
- public void removeDecorator() {
- removeDecorator(BaseFigureDecorator.DEFAULT_DECORATOR_POSITION);
- }
-
- public void removeDecorator(int position) {
- Iterator it = getDecorators().iterator();
- while (it.hasNext()) {
- BaseFigureDecorator d = (BaseFigureDecorator) it.next();
- if (d.getPosition() == position) {
- it.remove();
- remove(d);
- invalidate();
- break;
- }
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Label#setTextPlacement(int)
- */
- public void setTextPlacement(int where) {
- super.setTextPlacement(where);
- layout();
- invalidate();
- }
-
- public void invalidate() {
- // CR405873: F111-Error decorator missing
- // this was moved to paintFigure()
- // placeDecorators();
- super.invalidate();
- }
-
- private void placeDecorators() {
- Point o = getLocation();
- Point p = getIconBounds().getLocation();
- Dimension size = this.getIconBounds().getSize();
- Iterator it = getDecorators().iterator();
- while (it.hasNext()) {
- int x = p.x - o.x, y = p.y - o.y;
- BaseFigureDecorator decorator = (BaseFigureDecorator) it.next();
- Dimension decoratorSize = decorator.getPreferredSize();
- switch (decorator.getPosition()) {
- case (PositionConstants.CENTER | PositionConstants.MIDDLE):
- // CR378889: Case of decoration that should be right in the
- // middle.
- // Had to add a fudge factor because it's not exactly where I
- // want it.
- int fudge = 4;
- y += size.height / 2 - decoratorSize.height / 2 + fudge;
- x += size.width / 2 - decoratorSize.width / 2;
- break;
- case PositionConstants.NORTH:
- x += size.width / 2 - decoratorSize.width / 2;
- break;
- case PositionConstants.NORTH_EAST:
- x += size.width - decoratorSize.width;
- break;
- case PositionConstants.EAST:
- x += size.width - decoratorSize.width;
- y += size.height / 2 - decoratorSize.height / 2;
- break;
- case PositionConstants.SOUTH_EAST:
- x += size.width - decoratorSize.width;
- y += size.height - decoratorSize.height;
- break;
- case PositionConstants.SOUTH:
- x += size.width / 2 - decoratorSize.width / 2;
- y += size.height - decoratorSize.height;
- break;
- case PositionConstants.SOUTH_WEST:
- y += size.height - decoratorSize.height;
- break;
- case PositionConstants.WEST:
- y += size.height / 2 - decoratorSize.height / 2;
- break;
- case PositionConstants.NORTH_WEST:
- break;
- }
- getLayoutManager().setConstraint(decorator,
- new Rectangle(x, y, -1, -1));
- }
- layout();
- }
-
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- protected void paintFigure(Graphics graphics) {
- if (isOpaque())
- super.paintFigure(graphics);
- // CR405873: F111-Error decorator missing
- placeDecorators();
- Rectangle bounds_ = getBounds();
- graphics.translate(bounds_.x, bounds_.y);
- if (getIcon() != null)
- graphics.drawImage(getIcon(), getIconLocation());
- if (iconLabel == null || !iconLabel.isVisible()) {
- if (!isEnabled()) {
- graphics.translate(1, 1);
- graphics.setForegroundColor(ColorConstants.buttonLightest);
- graphics.drawText(getSubStringText(), getTextLocation());
- graphics.translate(-1, -1);
- graphics.setForegroundColor(ColorConstants.buttonDarker);
- }
- graphics.drawText(getSubStringText(), getTextLocation());
- }
- graphics.translate(-bounds_.x, -bounds_.y);
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/InputPortFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/InputPortFigure.java
deleted file mode 100644
index 66ca25bee..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/InputPortFigure.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.draw2d.ColorConstants; import org.eclipse.swt.graphics.Color; /** * * Figure used to draw input ports * */ /*package*/ class InputPortFigure extends PortFigure { private final static Color defaultForegroundColor = ColorConstants.black; private final static Color defaultBackgroundColor = ColorConstants.white; /** * * * */ public InputPortFigure() { super(FigureConstants.INPUT_PORT); setBackgroundColor(defaultBackgroundColor); setForegroundColor(defaultForegroundColor); } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/LinkFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/LinkFigure.java
deleted file mode 100644
index 11e0a8028..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/LinkFigure.java
+++ /dev/null
@@ -1,336 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Label;
-import org.eclipse.draw2d.LineBorder;
-import org.eclipse.draw2d.MarginBorder;
-import org.eclipse.draw2d.MidpointLocator;
-import org.eclipse.draw2d.PolylineConnection;
-import org.eclipse.draw2d.PositionConstants;
-import org.eclipse.draw2d.geometry.PointList;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author Bob
- */
-/*package*/ class LinkFigure extends PolylineConnection implements IBaseFigure {
- private final static Color defaultLineColor = ColorConstants.black;
-
- private final static int defaultLineWidth = 1;
-
- private final static boolean defaultLabelVisible = false;
-
- private final static Color defaultLabelForeground = ColorConstants.black;
-
- private final static Color defaultLabelBackground = ColorConstants.white;
-
- private final static Font defaultFont = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
-
- private LinkLabel label;
-
- /**
- * Default constructor
- */
- public LinkFigure() {
- super();
- setLineWidth(defaultLineWidth);
- setForegroundColor(defaultLineColor);
-
- // BaseFigureDecorator decorator;
- // decorator = new
- // BaseFigureDecorator(GEMPlugin.getDefault().getGEMImage("delete.gif"),"target",PositionConstants.WEST);
- // addDecorator(decorator);
- // decorator = new
- // BaseFigureDecorator(GEMPlugin.getDefault().getGEMImage("delete.gif"),"target",PositionConstants.EAST);
- // addDecorator(decorator);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setToolTipText()
- */
- public void setToolTipText(final String text) {
- Label toolTip_ = null;
-
- if (text != null && text.length() > 0) {
- toolTip_ = new Label(text);
- toolTip_.setBorder(new MarginBorder(3));
- }
-
- super.setToolTip(toolTip_);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getToolTipText()
- */
- public String getToolTipText() {
- if (getToolTip() != null)
- {
- return ((Label) getToolTip()).getText();
- }
- return null;
- }
-
- public void setHighlight(final boolean flag) {
- if (flag) {
- setForegroundColor(ColorConstants.titleBackground);
- // setLineWidth(defaultLineWidth * 2);
- } else {
- setForegroundColor(defaultLineColor);
- // setLineWidth(defaultLineWidth);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setText()
- */
- public void setText(final String text) {
- if (text != null && text.length() == 0) {
- if (label != null) {
- remove(label);
- label = null;
- }
- } else {
- getLabel().setText(text);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getText()
- */
- public String getText() {
- if (label == null)
- {
- return null;
- }
- return label.getText();
- }
-
- /*
- * CR374981: Long activity labels do not get wrapped or truncated This
- * method was added to the IBaseFigure interface to support direct edit of
- * figure labels on the canvas.
- */
- public Rectangle getTextBounds() {
- return label.getTextBounds();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setIcon(org.eclipse.swt.graphics.Image)
- */
- public void setIcon(final Image image) {
- getLabel().setIcon(image);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getIcon()
- */
- public Image getIcon() {
- return getLabel().getIcon();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#addDecorator(com.sybase.stf.gem.diagram.editor.figures.BaseFigureDecorator)
- */
- public void addDecorator(final BaseFigureDecorator decorator) {
- final int pos = decorator.getPosition();
- if (pos == BaseFigureDecorator.DEFAULT_DECORATOR_POSITION
- || pos == PositionConstants.WEST
- || pos == PositionConstants.LEFT) {
- setTargetDecoration(decorator);
- } else if (pos == PositionConstants.EAST
- || pos == PositionConstants.RIGHT) {
- setSourceDecoration(decorator);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator()
- */
- public void removeDecorator() {
- removeDecorator(BaseFigureDecorator.DEFAULT_DECORATOR_POSITION);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator(int)
- */
- public void removeDecorator(final int position) {
- if (position == BaseFigureDecorator.DEFAULT_DECORATOR_POSITION)
- {
- setTargetDecoration(null);
- }
- else
- {
- setSourceDecoration(null);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getDecorators()
- */
- public List getDecorators() {
- final List list = new ArrayList(2);
- Object d;
- d = getSourceDecoration();
- if (d != null)
- {
- list.add(d);
- }
- d = getTargetDecoration();
- if (d != null)
- {
- list.add(d);
- }
- return list;
- }
-
- private LinkLabel getLabel() {
- if (label == null) {
- label = new LinkLabel();
- add(label, new MidpointLocator(this, 0));
- }
- return label;
- }
-
- @Override
- public void setFont(final Font f) {
- getLabel().setFont(f);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Shape#setLineWidth(int)
- */
- @Override
- public void setLineWidth(final int w) {
- getLabel().setBorderWidth(w);
- super.setLineWidth(w);
- }
-
- @Override
- public void setForegroundColor(final Color c) {
- getLabel().setBorderColor(c);
- super.setForegroundColor(c);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Polyline#setPoints(org.eclipse.draw2d.geometry.PointList)
- */
- @Override
- public void setPoints(final PointList points) {
- super.setPoints(points);
- if (label != null) {
- int i = getPoints().size() / 2 - 1;
- if (i < 0)
- {
- i = 0;
- }
- if (getLayoutManager() != null)
- {
- getLayoutManager().setConstraint(label,
- new MidpointLocator(this, i));
- }
- }
- }
-
- @Override
- public Rectangle getBounds() {
- if (bounds == null) {
- if (bounds == null) {
- bounds = getPoints().getBounds().getExpanded(lineWidth / 2,
- lineWidth / 2);
- }
- // CR382243: Clicking on the node icon selects the connection line
- // rather than the node
- // NOTE: expanding the bounds to include children (in this case,
- // the Link labels) causes problems when the connection line becomes
- // short (i.e., when the 2 anchor figures at each end of the
- // connection are
- // close together) because the bounds of this link figure will be
- // greater
- // than the actual length of the line. This causes the link figure
- // to
- // be hit-tested beyond its visual size.
- if (getLabel().isVisible()) {
- for (int i = 0; i < getChildren().size(); i++) {
- final IFigure child = (IFigure) getChildren().get(i);
- bounds.union(child.getBounds());
- }
- }
- }
- return bounds;
- }
-
- /*
- * Helper class for line labels.
- */
- private static class LinkLabel extends Label {
- LinkLabel() {
- setBorder(new LineBorder());
- setOpaque(true);
- setForegroundColor(defaultLabelForeground);
- setBackgroundColor(defaultLabelBackground);
- setFont(defaultFont);
- final LineBorder border_ = new LineBorder(defaultLineWidth);
- setBorder(border_);
- border_.setColor(defaultLineColor);
- setVisible(defaultLabelVisible);
- }
-
- void setBorderWidth(final int w) {
- ((LineBorder) getBorder()).setWidth(w);
- }
-
- void setBorderColor(final Color c) {
- ((LineBorder) getBorder()).setColor(c);
- }
-
- @Override
- protected boolean useLocalCoordinates() {
- return false;
- }
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ObserveVisibleXYLayout.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ObserveVisibleXYLayout.java
deleted file mode 100644
index bee006f3a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/ObserveVisibleXYLayout.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.Iterator;
-import java.util.ListIterator;
-
-import org.eclipse.draw2d.FreeformLayout;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-
-/**
- * @author Bob Brodt
- *
- * This is an XY layout that actually observes visiblity of children figures
- * when doint its layout.
- *
- * Apparently there is a bug in the GEF XYLayout class because it does not
- * observe visibility.
- *
- * @see org.eclipse.draw2d.AbstractLayout#isObservingVisibility()
- */
-/*package*/ class ObserveVisibleXYLayout extends FreeformLayout {
- protected Dimension calculatePreferredSize(IFigure f, int wHint, int hHint) {
- Rectangle rect = new Rectangle();
- ListIterator children = f.getChildren().listIterator();
- while (children.hasNext()) {
- IFigure child = (IFigure) children.next();
- // bug fix
- if (isObservingVisibility() && !child.isVisible())
- continue;
- Rectangle r = (Rectangle) constraints.get(child);
- if (r == null)
- continue;
-
- if (r.width == -1 || r.height == -1) {
- Dimension preferredSize_ = child.getPreferredSize(r.width,
- r.height);
- r = r.getCopy();
- if (r.width == -1)
- r.width = preferredSize_.width;
- if (r.height == -1)
- r.height = preferredSize_.height;
- }
- rect.union(r);
- }
- Dimension d = rect.getSize();
- Insets insets = f.getInsets();
- return new Dimension(d.width + insets.getWidth(), d.height
- + insets.getHeight()).union(getBorderPreferredSize(f));
- }
-
- public void layout(IFigure parent) {
- Iterator children = parent.getChildren().iterator();
- Point offset = getOrigin(parent);
- IFigure f;
- while (children.hasNext()) {
- f = (IFigure) children.next();
- // bug fix
- if (isObservingVisibility() && !f.isVisible())
- continue;
- Rectangle bounds = (Rectangle) getConstraint(f);
- if (bounds == null)
- continue;
-
- if (bounds.width == -1 || bounds.height == -1) {
- Dimension preferredSize_ = f.getPreferredSize(bounds.width,
- bounds.height);
- bounds = bounds.getCopy();
- if (bounds.width == -1)
- bounds.width = preferredSize_.width;
- if (bounds.height == -1)
- bounds.height = preferredSize_.height;
- }
- bounds = bounds.getTranslated(offset);
- f.setBounds(bounds);
- }
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/OutputPortFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/OutputPortFigure.java
deleted file mode 100644
index 49d920135..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/OutputPortFigure.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.draw2d.ColorConstants; import org.eclipse.swt.graphics.Color; /** * */ /*package*/ class OutputPortFigure extends PortFigure { private final static Color defaultForegroundColor = ColorConstants.black; private final static Color defaultBackgroundColor = ColorConstants.white; /** * * * */ public OutputPortFigure() { super(FigureConstants.OUTPUT_PORT); setBackgroundColor(defaultBackgroundColor); setForegroundColor(defaultForegroundColor); } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortConnectionAnchor.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortConnectionAnchor.java
deleted file mode 100644
index f81c5076f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortConnectionAnchor.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import java.util.Iterator; import java.util.Vector; import org.eclipse.draw2d.AbstractConnectionAnchor; import org.eclipse.draw2d.IFigure; import org.eclipse.draw2d.PolylineConnection; import org.eclipse.draw2d.PositionConstants; import org.eclipse.draw2d.geometry.Point; import org.eclipse.draw2d.geometry.PrecisionPoint; import org.eclipse.draw2d.geometry.Rectangle; /** * */ /*package*/ class PortConnectionAnchor extends AbstractConnectionAnchor { // CR386077: SplitActivity True and False outputs switch positions based on // their targets private final int orientation = PositionConstants.NONE; /** * * * */ public PortConnectionAnchor() { super(); } /** * * @param owner * */ public PortConnectionAnchor(IFigure owner) { super(owner); } // CR386077: SplitActivity True and False outputs switch positions based on // their targets /** * @return the orientation value; one of PositionConstants.* */ public int getOrientation() { return orientation; } /* * * (non-Javadoc) * * * * @see org.eclipse.draw2d.ConnectionAnchor#getLocation(org.eclipse.draw2d.geometry.Point) * */ public Point getLocation(Point arg0) { PortFigure portFigure = (PortFigure) getOwner(); Point result = new Point(0, 0); Rectangle r = portFigure.getBounds(); switch (portFigure.getOrientation()) { case PositionConstants.NORTH: result = new PrecisionPoint(r.x + r.width / 2, r.y); break; case PositionConstants.SOUTH: result = new PrecisionPoint(r.x + r.width / 2, r.y + r.height); break; case PositionConstants.WEST: result = new PrecisionPoint(r.x, r.y + r.height / 2); break; case PositionConstants.EAST: result = new PrecisionPoint(r.x + r.width, r.y + r.height / 2); break; } portFigure.translateToAbsolute(result); return result; } /** * @return the connections list */ public Vector getConnections() { Vector list = new Vector(); Iterator it = listeners.iterator(); while (it.hasNext()) { Object listener = it.next(); if (listener instanceof PolylineConnection) list.add(listener); } return list; } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortFigure.java
deleted file mode 100644
index f99290246..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PortFigure.java
+++ /dev/null
@@ -1 +0,0 @@
-/******************************************************************************* * Copyright (c) 2004, 2006 Sybase, Inc. 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: * Sybase, Inc. - initial API and implementation *******************************************************************************/ package org.eclipse.jst.jsf.facesconfig.ui.preference; import org.eclipse.draw2d.Figure; import org.eclipse.draw2d.Graphics; import org.eclipse.draw2d.IFigure; import org.eclipse.draw2d.Label; import org.eclipse.draw2d.PositionConstants; import org.eclipse.draw2d.geometry.Dimension; import org.eclipse.draw2d.geometry.Insets; import org.eclipse.draw2d.geometry.PointList; import org.eclipse.draw2d.geometry.Rectangle; /** * * Provides the base implementation for all the port figures. * */ /*package*/ class PortFigure extends Figure { private boolean showBox = false; private boolean showArrow = true; // orientation is one of the four positions constants // NORTH, SOUTH, EAST or WEST and indicates on which side // of the parent figure the connection anchor figure is // located. private int orientation = PositionConstants.WEST; // type is the port type; either input or output private int type = FigureConstants.INPUT_PORT; /** * * Construct a port figure. * @param type * */ public PortFigure(int type) { super(); this.type = type; setOpaque(false); } /** * * @param b * */ public void setBoxVisible(boolean b) { showBox = b; repaint(); } /** * @param b */ public void setArrowVisible(boolean b) { showArrow = b; repaint(); } /** * * @return Returns the type. * */ public int getType() { return type; } /** * * @param type * The type to set. * */ public void setType(int type) { this.type = type; } /** * @param o */ public void setOrientation(int o) { orientation = o; } /** * @return the orientation; one of PositionConstants.* */ public int getOrientation() { return orientation; } /** * @param text */ public void setToolTipText(String text) { setToolTip(new Label(text)); } /** * @return the tool tip text */ public String getToolTipText() { IFigure fig = getToolTip(); if (fig instanceof Label) return ((Label) fig).getText(); return null; } /* * * (non-Javadoc) * * * * @see org.eclipse.draw2d.IFigure#paint(org.eclipse.draw2d.Graphics) * */ public void paintFigure(Graphics g) { super.paintFigure(g); Rectangle bounds_ = getBounds(); g.setForegroundColor(getForegroundColor()); if (showBox) { // draw outer rectangle g.setBackgroundColor(getBackgroundColor()); g.fillRectangle(getBounds().getCropped(new Insets(0, 1, 1, 0))); Rectangle r = getBounds().getExpanded(-1, -1).getTranslated(0, -1); r.height += 1; g.drawRectangle(r); } if (showArrow) { // draw arrowhead g.setBackgroundColor(getForegroundColor()); PointList pts = new PointList(); if (type == FigureConstants.INPUT_PORT) { switch (orientation) { case PositionConstants.NORTH: pts.addPoint(bounds_.getTopLeft()); pts.addPoint(bounds_.getTopRight()); pts.addPoint(bounds_.getBottom()); pts.addPoint(bounds_.getTopLeft()); break; case PositionConstants.SOUTH: pts.addPoint(bounds_.getBottomLeft()); pts.addPoint(bounds_.getTop()); pts.addPoint(bounds_.getBottomRight()); pts.addPoint(bounds_.getBottomLeft()); break; case PositionConstants.EAST: pts.addPoint(bounds_.getTopRight()); pts.addPoint(bounds_.getBottomRight()); pts.addPoint(bounds_.getLeft()); pts.addPoint(bounds_.getTopRight()); break; case PositionConstants.WEST: pts.addPoint(bounds_.getTopLeft()); pts.addPoint(bounds_.getRight()); pts.addPoint(bounds_.getBottomLeft()); pts.addPoint(bounds_.getTopLeft()); break; } } else { switch (orientation) { case PositionConstants.NORTH: pts.addPoint(bounds_.getBottomLeft()); pts.addPoint(bounds_.getTop()); pts.addPoint(bounds_.getBottomRight()); pts.addPoint(bounds_.getBottomLeft()); break; case PositionConstants.SOUTH: pts.addPoint(bounds_.getTopLeft()); pts.addPoint(bounds_.getTopRight()); pts.addPoint(bounds_.getBottom()); pts.addPoint(bounds_.getTopLeft()); break; case PositionConstants.EAST: pts.addPoint(bounds_.getTopLeft()); pts.addPoint(bounds_.getRight()); pts.addPoint(bounds_.getBottomLeft()); pts.addPoint(bounds_.getTopLeft()); break; case PositionConstants.WEST: pts.addPoint(bounds_.getTopRight()); pts.addPoint(bounds_.getBottomRight()); pts.addPoint(bounds_.getLeft()); pts.addPoint(bounds_.getTopRight()); break; } } g.fillPolygon(pts); g.drawPolyline(pts); } } /* * * (non-Javadoc) * * * * @see org.eclipse.draw2d.IFigure#getPreferredSize(int, int) * */ public Dimension getPreferredSize(int wHint, int hHint) { Dimension d = new Dimension(FigureConstants.PORT_SIDE, FigureConstants.PORT_SIDE); // CR389070: Figures are abbreviating rule figures names and making them // unreadable // anchor size is now determined by the size of the owning figure icon if (getParent() instanceof BaseNodeFigure) { IBaseFigure fig = ((BaseNodeFigure) getParent()).getBaseFigure(); if (fig != null && fig.getIcon() != null) { org.eclipse.swt.graphics.Rectangle r = fig.getIcon() .getBounds(); if (r.width < 40) d.width /= 2; if (r.height < 40) d.height /= 2; } } return d; } } \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.java
deleted file mode 100644
index e9220c1ff..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * The NLS message manager for PreferenceMessages
- *
- */
-/*package*/ final class PreferenceMessages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.facesconfig.ui.preference.PreferenceMessages"; //$NON-NLS-1$
-
- private PreferenceMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, PreferenceMessages.class);
- }
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_UseSystemColors;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_BackgroundColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_Canvas;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_GridHeight;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_GridLineColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_GridWidth;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_IconLabelFont;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_IconGroup;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_InputPortColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_OutputPortColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineGroup;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_ShowLineLabels;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineLabelColor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineLabelFont;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineRouting;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LineWidth;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_SnapToGeometry;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_SnapToGrid;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_UndoStackSize;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Direct;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Manhattan;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Manual;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_LabelPlacement;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Top;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Bottom;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Left;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Right;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferenceTab_LABEL_IconSize;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Small;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Medium;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String CanvasPreferences_LABEL_Large;
-
- /**
- * label property for check box that selects whether or not
- * the introduction section editor should be loaded.
- */
- public static String EditorPreferences_LABEL_ShowIntroEditor;
-
- /**
- * see PreferenceMessages.properties
- */
- public static String GEMPreferences_description;
- /**
- * see PreferenceMessages.properties
- */
- public static String CompoundNodeFigure_MaximizeLabel;
- /**
- * see PreferenceMessages.properties
- */
- public static String CompoundNodeFigure_MinimizeLabel;
- /**
- * see PreferenceMessages.properties
- */
- public static String CompoundNodeFigure_RestoreLabel;
- /**
- * see PreferenceMessages.properties
- */
- public static String WindowFigure_NoTitleText;
- /**
- * see PreferenceMessages.properties
- */
- public static String WindowFigure_Title;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.properties
deleted file mode 100644
index 5a91a3724..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PreferenceMessages.properties
+++ /dev/null
@@ -1,54 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-#
-# Appearance preference labels
-#
-CanvasPreferenceTab_LABEL_UseSystemColors=Use System colors
-EditorPreferences_LABEL_ShowIntroEditor=Show Introduction Tab (open editors must be reloaded to take effect)
-CanvasPreferenceTab_LABEL_BackgroundColor=Background color:
-CanvasPreferenceTab_LABEL_Canvas=Canvas
-CanvasPreferenceTab_LABEL_GridHeight=Grid height:
-CanvasPreferenceTab_LABEL_GridLineColor=Grid color:
-CanvasPreferenceTab_LABEL_GridWidth=Grid width:
-CanvasPreferenceTab_LABEL_IconLabelFont=Label font:
-CanvasPreferenceTab_LABEL_IconGroup=Icons
-CanvasPreferenceTab_LABEL_InputPortColor=Input Port color:
-CanvasPreferenceTab_LABEL_OutputPortColor=Output Port color:
-CanvasPreferenceTab_LABEL_LineGroup=Connection Lines
-CanvasPreferenceTab_LABEL_LineColor=Line color:
-CanvasPreferenceTab_LABEL_ShowLineLabels=Show labels
-CanvasPreferenceTab_LABEL_LineLabelColor=Label color:
-CanvasPreferenceTab_LABEL_LineLabelFont=Label font:
-CanvasPreferenceTab_LABEL_LineRouting=Line Routing:
-CanvasPreferenceTab_LABEL_LineWidth=Line width:
-CanvasPreferenceTab_LABEL_SnapToGeometry=Snap to geometry
-CanvasPreferenceTab_LABEL_SnapToGrid=Snap to grid
-CanvasPreferenceTab_LABEL_UndoStackSize="Undo\" stack size:
-CanvasPreferences_LABEL_Direct=Direct
-CanvasPreferences_LABEL_Manhattan=Manhattan
-CanvasPreferences_LABEL_Manual=Manual
-CanvasPreferenceTab_LABEL_LabelPlacement=Label Placement:
-CanvasPreferences_LABEL_Top=Top
-CanvasPreferences_LABEL_Bottom=Bottom
-CanvasPreferences_LABEL_Left=Left
-CanvasPreferences_LABEL_Right=Right
-CanvasPreferenceTab_LABEL_IconSize=Icon Size:
-CanvasPreferences_LABEL_Small=Small
-CanvasPreferences_LABEL_Medium=Medium
-CanvasPreferences_LABEL_Large=Large
-GEMPreferences_description=Preferences for the graphical page of FacesConfig editor.
-
-#################################################
-CompoundNodeFigure_MaximizeLabel=Maximize
-CompoundNodeFigure_MinimizeLabel=Minimize
-CompoundNodeFigure_RestoreLabel=Restore
-WindowFigure_NoTitleText=??
-WindowFigure_Title=Window
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PrintedPageLayer.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PrintedPageLayer.java
deleted file mode 100644
index 566958fd9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/PrintedPageLayer.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.draw2d.Figure;
-import org.eclipse.draw2d.FreeformLayer;
-import org.eclipse.draw2d.FreeformLayeredPane;
-import org.eclipse.draw2d.RectangleFigure;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.LayerConstants;
-
-/**
- * This is a printable layer that draws page outline tiles enclosing all of the
- * printable child figures. The page outlines represent complete pages as they
- * would appear if they were printed on dead trees, thus the pageSize set on
- * this layer should be the currently selected printer's page resolution.
- *
- * The reason this needs to be added to the printable layers is so that it will
- * show up in the content outline viewer.
- */
-/*package*/ class PrintedPageLayer extends FreeformLayer {
- // our layer name
- static final String PRINTED_PAGE_LAYER = "Printed Page"; //$NON-NLS-1$
-
- // the size of the page tiles (this should be the printer's resolution)
- private Dimension pageSize = new Dimension(850, 1100);
-
- // the WindowFigure that owns this layer
- private final WindowFigure host;
-
- // flag to lock out multiple calls to setFreeformBounds() when adding
- // and removing PrintedPageFigures.
- private boolean busy;
-
- // A simple page outline figure. We can get fancy later with turned-up
- // dogears, page numbers, titles and whatnot...
- static class PrintedPageFigure extends RectangleFigure {
- PrintedPageFigure() {
- super();
- setFill(false);
- setOutline(true);
- setLineWidth(1);
- }
- }
-
- /**
- * @param figure
- */
- public PrintedPageLayer(WindowFigure figure) {
- super();
- this.host = figure;
- }
-
- /**
- * @param x
- * @param y
- * @return the print page figure
- */
- protected PrintedPageFigure createPage(int x, int y) {
- PrintedPageFigure page = new PrintedPageFigure();
- page.setBounds(new Rectangle(x, y, pageSize.width, pageSize.height));
- return page;
- }
-
- /**
- * Sets the page width and height. This should be the currently selected
- * printer's page size.
- *
- * @param d
- */
- public void setPageSize(Dimension d) {
- pageSize = d.getCopy();
- }
-
- /**
- * @see org.eclipse.draw2d.FreeformFigure#setFreeformBounds(Rectangle)
- */
- public void setFreeformBounds(Rectangle bounds) {
- if (!busy && getParent() instanceof FreeformLayeredPane
- && pageSize.width > 0 && pageSize.height > 0) {
- busy = true;
-
- // build the new printing layer extent by looking at only the
- // contents of the Primary, Connection and Feedback layers
- Rectangle b;
- FreeformLayer layer;
- layer = (FreeformLayer) host.getLayer(LayerConstants.PRIMARY_LAYER);
- b = layer.getFreeformExtent().getCopy();
- layer = (FreeformLayer) host
- .getLayer(LayerConstants.CONNECTION_LAYER);
- b = b.union(layer.getFreeformExtent());
- layer = (FreeformLayer) host
- .getLayer(LayerConstants.FEEDBACK_LAYER);
- b = b.union(layer.getFreeformExtent());
-
- // calculate x and y for the page tiles
- int x = 0, y = 0;
- if (b.x < 0) {
- while (x > b.x)
- x -= pageSize.width;
- } else {
- while (x + pageSize.width < b.x)
- x += pageSize.width;
- }
- if (b.y < 0) {
- while (y > b.y)
- y -= pageSize.height;
- } else {
- while (y + pageSize.height < b.y)
- y += pageSize.height;
- }
-
- // get list of pagefigures that intersect the new extent
- // and a list of those that don't
- List keepers = new ArrayList();
- List trash = new ArrayList();
- Iterator iter = getChildren().iterator();
- while (iter.hasNext()) {
- Figure child = (Figure) iter.next();
- if (child.getBounds().intersects(b))
- keepers.add(child);
- else
- trash.add(child);
- }
-
- // calculate width and height
- int w = 0, h = 0;
- while (x + w < b.x + b.width)
- w += pageSize.width;
- while (y + h < b.y + b.height)
- h += pageSize.height;
-
- // determine the required pagefigures
- for (int xi = x; xi < x + w; xi += pageSize.width) {
- for (int yi = y; yi < y + h; yi += pageSize.height) {
- boolean found = false;
- iter = keepers.iterator();
- while (iter.hasNext()) {
- Figure child = (Figure) iter.next();
- Point p = child.getBounds().getLocation();
- if (p.x == xi && p.y == yi) {
- found = true;
- break;
- }
- }
- if (!found) {
- // add the new page
- add(createPage(xi, yi));
- }
- }
- }
-
- // remove all the old pages
- iter = trash.iterator();
- while (iter.hasNext())
- remove((Figure) iter.next());
-
- busy = false;
- }
- super.setFreeformBounds(bounds);
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/RectangleList.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/RectangleList.java
deleted file mode 100644
index 03aadbbd8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/RectangleList.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-
-import org.eclipse.draw2d.geometry.Rectangle;
-
-/**
- * A List<Rectangle> implementation with a coordinate-based
- * convenience method for adding rectangles.
- *
- */
-class RectangleList extends ArrayList<Rectangle>
-{
- private static final long serialVersionUID = -4088355285820327890L;
-
- /**
- * Default constructor
- */
- public RectangleList() {
- super();
- }
-
- /**
- * @param x1
- * @param y1
- * @param x2
- * @param y2
- */
- public void addRectangle(int x1, int y1, int x2, int y2) {
- add(new Rectangle(x1, y1, x2 - x1, y2 - y1));
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedTitleBarBorder.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedTitleBarBorder.java
deleted file mode 100644
index 60cd9792a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedTitleBarBorder.java
+++ /dev/null
@@ -1,591 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.ListenerList;
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.FigureUtilities;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.MouseEvent;
-import org.eclipse.draw2d.MouseListener;
-import org.eclipse.draw2d.SchemeBorder;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * A border for the tabbed title bar
- *
- */
-/*package*/ class TabbedTitleBarBorder extends SchemeBorder {
- // private int state = CompoundFigureListener.RESTORED;
-
- private IFigure parent;
-
- private ListenerList listenerList;
-
- private List tabList;
-
- private int currentTab;
-
- private Font font;
-
- private boolean visible = true;
-
- // from TitleBarBorder:
- private Color textColor = ColorConstants.black;
-
- private Color bgColor = ColorConstants.menuBackground;
-
- private Insets insets;
-
- private Insets padding = new Insets(2, 2, 2, 2);
-
- /**
- * Constructs a TitleBarBorder with its label set to the name of this class.
- * @param parent
- *
- * @since 2.0
- */
- public TabbedTitleBarBorder(final IFigure parent) {
- super(SCHEMES.LOWERED);
-
- this.parent = parent;
-
- parent.addMouseListener(new MouseListener() {
- public void mousePressed(MouseEvent me) {
- Insets padding_ = getPadding();
- Point mp = me.getLocation();
- mp.x -= padding_.left;
- mp.y -= padding_.top + 3; // 3==width of the outer border
- Point pp = parent.getBounds().getLocation();
- Rectangle tr = new Rectangle(pp.x, pp.y, 0, 0);
- //int activeIndex = -1;
-
- for (int i = 0; i < getTabList().size(); ++i) {
- Tab t = (Tab) tabList.get(i);
- Dimension d = t.getTextExtents();
- d.height += padding_.top + padding_.bottom;
- d.width += padding_.left;
- tr.setSize(d);
- if (tr.contains(mp)) {
- setCurrentTab(i);
- return;
- }
- tr.x += d.width;
- }
- }
-
- public void mouseReleased(MouseEvent me) {
- // do nothing: not handling release
- }
-
- public void mouseDoubleClicked(MouseEvent me) {
- // do nothing: not handling release
- }
- });
- }
-
- /**
- * @return the tab list
- */
- protected List getTabList() {
- if (tabList == null)
- tabList = new ArrayList();
- return tabList;
- }
-
- /**
- * Add a new tab with the text
- * @param text
- * @return the previous number of tabs
- */
- public int addTab(String text) {
- getTabList().add(new Tab(text));
- return getTabList().size() - 1;
- }
-
- /**
- * @param index
- */
- public void removeTab(int index) {
- if (index >= 0 && index < getTabList().size()) {
- tabList.remove(index);
- if (index >= tabList.size())
- index = tabList.size() - 1;
- setCurrentTab(index);
- }
- }
-
- /**
- * @param newIndex
- */
- public void setCurrentTab(int newIndex) {
- if (newIndex >= 0 && newIndex < getTabList().size()) {
- Tab newTab = (Tab) tabList.get(newIndex);
- int oldIndex = -1;
- for (int i = 0; i < tabList.size(); ++i) {
- Tab t = (Tab) tabList.get(i);
- if (t.isActive()) {
- oldIndex = i;
- t.setActive(false);
- break;
- }
- }
- newTab.setActive(true);
- if (parent != null) {
- parent.invalidate();
- parent.repaint();
- }
- currentTab = newIndex;
- fireTabChanged(oldIndex, newIndex);
- }
- }
-
- /**
- * @return the index of the current tab
- */
- public int getCurrentTab() {
- return currentTab;
- }
-
- /**
- * @param index
- * @return the contents object of the tab at index
- * or null if index is out of range
- */
- public Object getContents(int index) {
- if (index >= 0 && index < getTabList().size())
- return ((Tab) tabList.get(index)).getContents();
- return null;
- }
-
- /**
- * @param index
- * @param contents
- */
- public void setContents(int index, Object contents) {
- if (index >= 0 && index < getTabList().size())
- ((Tab) tabList.get(index)).setContents(contents);
- }
-
- /**
- * @param listener
- */
- public void addTabbedWindowListener(WindowFigureListener listener) {
- if (listenerList == null)
- listenerList = new ListenerList(ListenerList.IDENTITY);
- listenerList.add(listener);
- }
-
- /**
- * @param listener
- */
- public void removeTabbedWindowListener(WindowFigureListener listener) {
- if (listenerList != null)
- listenerList.remove(listener);
- }
-
- /**
- * @return the listeners
- */
- public Object[] getListeners() {
- return listenerList.getListeners();
- }
-
- /**
- * @param oldIndex
- * @param newIndex
- */
- protected void fireTabChanged(int oldIndex, int newIndex) {
- Object l[] = listenerList.getListeners();
- for (int i = 0; i < l.length; ++i) {
- if (l[i] instanceof WindowFigureListener)
- ((WindowFigureListener) l[i]).tabChanged(oldIndex, newIndex);
- }
- }
-
- /**
- * @return Returns the font.
- */
- public Font getFont() {
- if (font == null) {
- font = parent.getFont();
- if (font == null)
- font = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
- }
- return font;
- }
-
- /**
- * @param font
- * The font to set.
- */
- public void setFont(Font font) {
- this.font = font;
- invalidate();
- }
-
- /**
- * @return Returns the insets.
- */
- public Insets getInsets() {
- return insets;
- }
-
- /**
- * @param c
- */
- public void setTextColor(Color c) {
- textColor = c;
- }
-
- /**
- * @return the text color
- */
- public Color getTextColor() {
- return textColor;
- }
-
- /**
- * @param c
- */
- public void setBackgroundColor(Color c) {
- bgColor = c;
- }
-
- /**
- * @return the background color
- */
- public Color getBackgroundColor() {
- return bgColor;
- }
-
- /**
- * @param p
- */
- public void setPadding(Insets p) {
- padding = p;
- invalidate();
- }
-
- /**
- * @return the padding insets
- */
- public Insets getPadding() {
- return padding;
- }
-
- /**
- * @param text
- */
- public void setLabel(String text) {
- setLabel(currentTab, text);
- }
-
- /**
- * @param index
- * @param text
- */
- public void setLabel(int index, String text) {
- if (index >= 0 && index < getTabList().size())
- ((Tab) tabList.get(index)).setLabel(text);
- }
-
- /**
- * @return the label
- */
- public String getLabel() {
- return getLabel(currentTab);
- }
-
- /**
- * @param index
- * @return the label
- */
- public String getLabel(int index) {
- if (index >= 0 && index < getTabList().size())
- return ((Tab) tabList.get(index)).getLabel();
- return ""; //$NON-NLS-1$
- }
-
- /**
- * @return the parent figureb
- */
- public IFigure getParent() {
- return parent;
- }
-
- /**
- * validate each of the tabs
- */
- public void invalidate() {
- insets = null;
- for (int i = 0; i < getTabList().size(); ++i) {
- Tab t = (Tab) tabList.get(i);
- t.invalidate();
- }
- }
-
- /**
- * @param f
- * @return the text extends
- */
- public Dimension getTextExtents(IFigure f) {
- Dimension d = new Dimension(0, 0);
- for (int i = 0; i < getTabList().size(); ++i) {
- Tab t = (Tab) tabList.get(i);
- if (d.height == 0)
- d = t.getTextExtents();
- else
- d.width += t.getTextExtents().width;
- }
- return d;
- }
-
- /**
- * Sets the min/max buttons visible
- *
- * @param flag -
- * if true, buttons are made visible.
- */
- public void setVisible(boolean flag) {
- visible = flag;
- }
-
- /**
- * Calculates and returns the Insets for this border.
- *
- * @param figure
- * the figure on which Insets calculations are based
- * @return the calculated Insets
- * @since 2.0
- */
- protected Insets calculateInsets(IFigure figure) {
- insets = new Insets(super.getInsets(figure));
- insets.top = getTextExtents(figure).height;
- return insets;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.Border#getInsets(org.eclipse.draw2d.IFigure)
- */
- public Insets getInsets(IFigure figure) {
- if (insets == null)
- calculateInsets(figure);
- return insets;
- }
-
- /**
- * @see org.eclipse.draw2d.Border#paint(IFigure, Graphics, Insets)
- */
- public void paint(IFigure figure, Graphics g, Insets in) {
- if (!visible)
- return;
-
- Insets is = new Insets(in);
- getInsets(figure);
- is.top += insets.top;
- super.paint(figure, g, is);
- // Insets insets = getInsets(pane);
- // Insets padding = getPadding();
- // Insets in = new Insets(figureInsets);
- // in.top += insets.top;
- // super.paint(pane, g, in);
-
- tempRect.setBounds(getPaintRectangle(figure, in));
- Rectangle r = tempRect;
- r.height = Math.min(r.height, getTextExtents(figure).height);
-
- g.clipRect(r);
- g.setBackgroundColor(getBackgroundColor());
- g.fillRectangle(r);
- int x = r.x;
- int y = r.y;
-
- Iterator iter = getTabList().iterator();
- while (iter.hasNext()) {
- Tab t = (Tab) iter.next();
- t.paint(g, figure, x, y);
- x += t.getTextExtents().width;
- }
-
- g.setBackgroundColor(getBackgroundColor());
- }
-
- /**
- * @param wHint
- * @param hHint
- * @return the minimum size
- */
- public Dimension getMinimumSize(int wHint, int hHint) {
- Dimension d = getTextExtents(parent);
- getInsets(parent);
- d.expand(insets.left + insets.right, insets.top + insets.bottom);
- // add enough width for the min/max buttons
- // d.width += minButton.getSize().width + maxButton.getSize().width;
- return d;
- }
-
- private class Tab {
- private String label = ""; //$NON-NLS-1$
-
- private Object contents = null;
-
- private Dimension textExtents;
-
- private boolean active;
-
- /**
- * @param text
- */
- public Tab(String text) {
- this.label = text;
- }
-
- /**
- * @param contents
- */
- public void setContents(Object contents) {
- this.contents = contents;
- }
-
- /**
- * @return the contents
- */
- public Object getContents() {
- return contents;
- }
-
- /**
- * @param active
- */
- public void setActive(boolean active) {
- this.active = active;
- }
-
- /**
- * @return the active state
- */
- public boolean isActive() {
- return active;
- }
-
- /**
- * @return the label
- */
- public String getLabel() {
- return label;
- }
-
- /**
- * @param text
- */
- public void setLabel(String text) {
- if (text == null)
- this.label = ""; //$NON-NLS-1$
- else
- this.label = text;
- textExtents = null;
- }
-
- /**
- * @return the text extents
- */
- public Dimension calculateTextExtents() {
- textExtents = FigureUtilities.getTextExtents(label == null ? "W" //$NON-NLS-1$
- : label, getFont());
- textExtents.width += getPadding().getWidth();
- textExtents.height += getPadding().getHeight();
- return textExtents;
- }
-
- /**
- * @return the text extents. A copy is returned based on what
- * is cached internall by calculateTextExtents
- */
- public Dimension getTextExtents() {
- if (textExtents == null)
- calculateTextExtents();
- return textExtents.getCopy();
- }
-
- /**
- *
- */
- public void invalidate() {
- textExtents = null;
- }
-
- /**
- * @param g
- * @param f
- * @param x
- * @param y
- */
- public void paint(Graphics g, IFigure f, int x, int y) {
- if (contents instanceof Composite) {
- return;
- }
- IFigure pane = (IFigure) contents;
- getTextExtents();
-
- Insets p = getPadding();
- int w = textExtents.width;
- int h = textExtents.height;
- int radius = Math.max(p.getWidth(), p.getHeight()) + 2;
-
- // CR408950: BP Save problems
- // fixed icon label refresh problems
- if (getTabList().size() > 1) {
- // only draw tabList if there are more than 1
- if (active)
- g.setBackgroundColor(pane == null ? ColorConstants.white
- : pane.getBackgroundColor());
- else
- g.setBackgroundColor(getBackgroundColor());
-
- --w;
- g.setForegroundColor(active ? ColorConstants.buttonDarkest
- : ColorConstants.buttonDarker);
- // g.setForegroundColor(ColorConstants.red);
- g.drawRectangle(x, y + h / 2, w, h);
- // g.setBackgroundColor(ColorConstants.green);
- g.fillRoundRectangle(new Rectangle(x, y, w, h), radius, radius);
- // g.setForegroundColor(ColorConstants.blue);
- g.drawRoundRectangle(new Rectangle(x, y, w, h), radius, radius);
- // g.setBackgroundColor(ColorConstants.yellow);
- g.fillRectangle(x + 1, y + h / 2, w - 1, h);
- } else
- g.setBackgroundColor(getBackgroundColor());
-
- g.setFont(getFont());
- g.setForegroundColor(getTextColor());
- if (label != null)
- g.drawString(label, x + padding.left + 1, y + padding.top);
- }
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedWindowBorder.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedWindowBorder.java
deleted file mode 100644
index 6d41870e0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TabbedWindowBorder.java
+++ /dev/null
@@ -1,252 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.FigureUtilities;
-import org.eclipse.draw2d.FrameBorder;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.SchemeBorder;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * A frame border for a tabbed window
- *
- */
-/* package */final class TabbedWindowBorder extends FrameBorder
-{
- private boolean isVisible = true;
-
- // CR392586: resource leaks
- private static MySchemeBorder normalBorder = new MySchemeBorder(
- new MySchemeBorder.MyScheme(new Color[]
- { ColorConstants.button, ColorConstants.buttonLightest,
- ColorConstants.button }, new Color[]
- { ColorConstants.buttonDarkest, ColorConstants.buttonDarker,
- ColorConstants.button }));
-
- // CR392586: resource leaks
- private static MySchemeBorder highlightBorder = new MySchemeBorder(
- new MySchemeBorder.MyScheme(new Color[]
- { FigureUtilities.lighter(ColorConstants.titleBackground),
- ColorConstants.titleBackground,
- FigureUtilities.darker(ColorConstants.titleBackground) },
- new Color[]
- {
- FigureUtilities
- .darker(ColorConstants.titleGradient),
- ColorConstants.titleGradient,
- FigureUtilities
- .lighter(ColorConstants.titleGradient) }));
-
- /**
- * A border scheme
- *
- */
- private static class MySchemeBorder extends SchemeBorder
- {
- private static class MyScheme extends SchemeBorder.Scheme
- {
- /**
- * @param highlight
- * @param shadow
- */
- public MyScheme(final Color[] highlight, final Color[] shadow)
- {
- super(highlight, shadow);
- }
-
- @Override
- public Color[] getHighlight()
- {
- return super.getHighlight();
- }
-
- @Override
- public Color[] getShadow()
- {
- return super.getHighlight();
- }
- }
-
- MySchemeBorder(final MyScheme scheme)
- {
- super(scheme);
- }
-
- /**
- * @return the scheme
- */
- public MyScheme getMyScheme()
- {
- return (MyScheme) super.getScheme();
- }
-
- /**
- * @see org.eclipse.draw2d.Border#paint(IFigure, Graphics, Insets)
- * @param comp
- * @param gc
- * @param insets
- */
- public void paint(final Composite comp, final GC gc, final Insets insets)
- {
- final Color[] tl = getMyScheme().getHighlight();
- final Color[] br = getMyScheme().getShadow();
- paint(comp, gc, insets, tl, br);
- }
-
- /**
- * Paints the border using the information in the set Scheme and the
- * inputs given. Side widths are determined by the number of colors in
- * the Scheme for each side.
- *
- * @param comp
- * the composit whose rect should be used for the inset
- * bounds
- * @param gc
- * the graphics object
- * @param insets
- * the insets
- * @param tl
- * the highlight (top/left) colors
- * @param br
- * the shadow (bottom/right) colors
- */
- protected void paint(final Composite comp, final GC gc, final Insets insets, final Color[] tl,
- final Color[] br)
- {
- final org.eclipse.swt.graphics.Rectangle rect = comp.getBounds();
-
- gc.setLineWidth(1);
- gc.setLineStyle(SWT.LINE_SOLID);
-
- final int top = rect.y - insets.top;
- final int left = rect.x - insets.left;
- int bottom = rect.y + rect.height + insets.bottom;
- int right = rect.x + rect.width + insets.right;
- gc.setClipping(new org.eclipse.swt.graphics.Rectangle(left, top,
- right - left, bottom - top));
-
- final Color color = ColorConstants.red;
- gc.setForeground(color);
- gc.drawLine(left, top, right, bottom);
-
- for (int i = 0; i < br.length; i++)
- {
- // color = br[i];
- gc.setForeground(color);
- gc.drawLine(right - i, bottom - i, right - i, top + i);
- gc.drawLine(right - i, bottom - i, left + i, bottom - i);
- }
-
- right--;
- bottom--;
-
- for (int i = 0; i < tl.length; i++)
- {
- // color = tl[i];
- gc.setForeground(color);
- gc.drawLine(left + i, top + i, right - i, top + i);
- gc.drawLine(left + i, top + i, left + i, bottom - i);
- }
- color.dispose();
- }
- }
-
- /**
- * @param parent
- */
- public TabbedWindowBorder(final IFigure parent)
- {
- // apparently paint() gets called before createBorders() has had
- // a chance to create the borders, so we just create them here
- inner = new TabbedTitleBarBorder(parent);
- outer = normalBorder;
- }
-
- /**
- * @param flag
- */
- public void setVisible(final boolean flag)
- {
- if (isVisible != flag)
- {
- isVisible = flag;
- ((TabbedTitleBarBorder) inner).setVisible(flag);
- if (flag)
- {
- ((TabbedTitleBarBorder) inner).getParent().repaint();
- }
- }
- }
-
- /**
- * @param flag
- */
- public void setHighlight(final boolean flag)
- {
- if (flag)
- {
- outer = highlightBorder;
- }
- else
- {
- outer = normalBorder;
- }
- ((TabbedTitleBarBorder) inner).getParent().repaint();
- }
-
- @Override
- protected void createBorders()
- {
- // TODO: NOTE: this is overriding default border creation
- }
-
- @Override
- public void paint(final IFigure figure, final Graphics g, final Insets insets)
- {
- if (isVisible)
- {
- if (comp != null)
- {
- final GC gc = new GC(comp);
- paint(comp, gc, insets);
- gc.dispose();
- }
- else
- {
- super.paint(figure, g, insets);
- }
- }
- }
-
- private Composite comp;
-
- /**
- * @param comp_
- * @param gc
- * @param insets
- */
- public void paint(final Composite comp_, final GC gc, final Insets insets)
- {
- this.comp = comp_;
- if (isVisible)
- {
- ((MySchemeBorder) outer).paint(comp_, gc, insets);
- }
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TitleBarButton.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TitleBarButton.java
deleted file mode 100644
index 1496ca4de..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/TitleBarButton.java
+++ /dev/null
@@ -1,240 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.Iterator;
-
-import org.eclipse.draw2d.ActionEvent;
-import org.eclipse.draw2d.ActionListener;
-import org.eclipse.draw2d.Button;
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.Cursors;
-import org.eclipse.draw2d.Graphics;
-import org.eclipse.draw2d.MouseEvent;
-import org.eclipse.draw2d.MouseMotionListener;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * A title bar button
- *
- */
-/*package*/ final class TitleBarButton extends Button {
- private boolean state = false;
-
- private Image uncheckedImage;
-
- private Image checkedImage;
-
- private Image uncheckedHiliteImage;
-
- private Image checkedHiliteImage;
-
- private RectangleList uncheckedRects;
-
- private RectangleList checkedRects;
-
- private boolean hilite = false;
-
-
-
- /**
- * @param unchecked
- * @param uncheckedHilite
- * @param checked
- * @param checkedHilite
- */
- public TitleBarButton(Image unchecked, Image uncheckedHilite,
- Image checked, Image checkedHilite) {
- super();
- uncheckedImage = unchecked;
- if (uncheckedHilite == null)
- uncheckedHiliteImage = unchecked;
- else
- uncheckedHiliteImage = uncheckedHilite;
- if (checked == null)
- checkedImage = unchecked;
- else
- checkedImage = checked;
- if (checkedHilite == null)
- checkedHiliteImage = unchecked;
- else
- checkedHiliteImage = checkedHilite;
- initialize();
- }
-
- /**
- * @param rects
- */
- public TitleBarButton(RectangleList rects) {
- super();
- uncheckedRects = rects;
- initialize();
- }
-
- /**
- * @param unchecked
- * @param checked
- */
- public TitleBarButton(RectangleList unchecked, RectangleList checked) {
- super();
- uncheckedRects = unchecked;
- checkedRects = checked;
- initialize();
- }
-
- /**
- * @return the state
- */
- public boolean getState() {
- return state;
- }
-
- /**
- * @param newState
- */
- public void setState(boolean newState) {
- state = newState;
- hilite = false;
- }
-
- private void initialize() {
- setRequestFocusEnabled(true);
- setFocusTraversable(true);
-
- if (uncheckedImage != null) {
- org.eclipse.swt.graphics.Rectangle r = uncheckedImage.getBounds();
- setBounds(new Rectangle(0, 0, r.width, r.height));
- prefSize = new Dimension(r.width, r.height);
- } else {
- setForegroundColor(ColorConstants.black);
- setBackgroundColor(ColorConstants.white);
- calculatePreferredSize();
- setBounds(new Rectangle(0, 0, prefSize.width, prefSize.height));
- }
- setCursor(Cursors.ARROW);
- setBorder(null);
- setFont(JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT));
-
- addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent event) {
- setState(!state);
- }
- });
- this.addMouseMotionListener(new MouseMotionListener() {
-
- public void mouseDragged(MouseEvent me) {
- // TODO Auto-generated method stub
-
- }
-
- public void mouseEntered(MouseEvent me) {
- hilite = true;
- repaint();
- }
-
- public void mouseExited(MouseEvent me) {
- hilite = false;
- repaint();
- }
-
- public void mouseHover(MouseEvent me) {
- // TODO Auto-generated method stub
-
- }
-
- public void mouseMoved(MouseEvent me) {
- // TODO Auto-generated method stub
-
- }
- });
- }
-
- /**
- * @return the preferred size dimensions
- */
- public Dimension calculatePreferredSize() {
- if (prefSize == null) {
- Rectangle rect = new Rectangle(0, 0, 0, 0);
- if (uncheckedRects != null) {
- Iterator<Rectangle> iter = uncheckedRects.iterator();
- while (iter.hasNext()) {
- /*Point p =*/ getLocation();
- Rectangle r = iter.next().getCopy();
- rect = rect.getUnion(r);
- }
- }
- if (checkedRects != null) {
- Iterator<Rectangle> iter = checkedRects.iterator();
- while (iter.hasNext()) {
- /*Point p =*/ getLocation();
- Rectangle r = iter.next().getCopy();
- rect = rect.getUnion(r);
- }
- }
- prefSize = rect.getSize();
- if (prefSize.width > prefSize.height)
- prefSize.height = prefSize.width;
- else if (prefSize.height > prefSize.width)
- prefSize.width = prefSize.height;
- prefSize.width += 4;
- prefSize.height += 4;
- }
- return prefSize;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.IFigure#paint(org.eclipse.draw2d.Graphics)
- */
- public void paint(Graphics graphics) {
- if (!isVisible())
- return;
- if (uncheckedImage != null) {
- if (hilite) {
- if (state == false)
- graphics.drawImage(uncheckedHiliteImage, getLocation());
- else
- graphics.drawImage(checkedHiliteImage, getLocation());
- } else {
- if (state == false)
- graphics.drawImage(uncheckedImage, getLocation());
- else
- graphics.drawImage(checkedImage, getLocation());
- }
- } else {
- Iterator<Rectangle> iter = null;
- if (state == false)
- iter = uncheckedRects.iterator();
- else
- iter = checkedRects.iterator();
- while (iter.hasNext()) {
- Point p = getLocation();
- Rectangle r = iter.next().getCopy();
- r = r.translate(p.x, p.y);
- graphics.setForegroundColor(getForegroundColor());
- if (hilite)
- graphics.setBackgroundColor(ColorConstants.lightBlue);
- else
- graphics.setBackgroundColor(ColorConstants.white);
- graphics.fillRectangle(r);
- graphics.drawRectangle(r);
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigure.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigure.java
deleted file mode 100644
index 02f38a9c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigure.java
+++ /dev/null
@@ -1,620 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.draw2d.AncestorListener;
-import org.eclipse.draw2d.ColorConstants;
-import org.eclipse.draw2d.ConnectionLayer;
-import org.eclipse.draw2d.FreeformFigure;
-import org.eclipse.draw2d.FreeformLayer;
-import org.eclipse.draw2d.FreeformLayeredPane;
-import org.eclipse.draw2d.FreeformLayout;
-import org.eclipse.draw2d.FreeformListener;
-import org.eclipse.draw2d.FreeformViewport;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.Layer;
-import org.eclipse.draw2d.LayeredPane;
-import org.eclipse.draw2d.ScalableFreeformLayeredPane;
-import org.eclipse.draw2d.ScrollPane;
-import org.eclipse.draw2d.geometry.Dimension;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Point;
-import org.eclipse.draw2d.geometry.Rectangle;
-import org.eclipse.gef.LayerConstants;
-import org.eclipse.gef.editparts.GridLayer;
-import org.eclipse.gef.editparts.GuideLayer;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.graphics.Color;
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * A ScollPane used as figure container
- *
- */
-/*package*/ class WindowFigure extends ScrollPane implements IContainerFigure,
- LayerConstants, FreeformFigure {
- private TabbedWindowBorder windowBorder;
-
- private TabbedTitleBarBorder titleBarBorder;
-
- private FreeformViewport myViewport;
-
- // private FreeformLayeredPane layeredPane;
-
- private ScalableFreeformLayeredPane scaledLayers;
-
- private LayeredPane innerLayers;
-
- private LayeredPane printableLayers;
-
- private FreeformLayer primaryLayer;
-
- private final static Font defaultFont = JFaceResources.getFontRegistry().get(
- JFaceResources.DEFAULT_FONT);
-
- private final static Color defaultForegroundColor = ColorConstants.black;
-
- private final static Color defaultBackgroundColor = ColorConstants.white;
-
- private final static Color defaultGridColor = ColorConstants.lightGray;
-
- private final static Dimension defaultGridSpacing = null;
-
- private final static boolean defaultGridEnabled = false;
-
- // Line Routing is not used within the WindowFigure class; it just serves as
- // a storage
- // location for communicating between the GEMPreferences and EditParts that
- // actually
- // create the line routers.
- private final static int LINE_ROUTING_MANUAL = 0;
-
- // TODO: should this really be static?
- private static int defaultLineRoutingStyle = LINE_ROUTING_MANUAL;
-
- private class MyGridLayer extends GridLayer {
- Point getOrigin() {
- return origin.getCopy();
- }
- }
-
- private class MyFeedbackLayer extends FreeformLayer {
- MyFeedbackLayer() {
- setEnabled(false);
- }
- }
-
- /**
- * Default constructor
- */
- public WindowFigure() {
- super();
-
- windowBorder = new TabbedWindowBorder(this);
- titleBarBorder = (TabbedTitleBarBorder) windowBorder.getInnerBorder();
- setBorder(windowBorder);
- setFont(defaultFont);
- setForegroundColor(defaultForegroundColor);
- setBackgroundColor(defaultBackgroundColor);
-
- innerLayers = new FreeformLayeredPane();
- createLayers(innerLayers);
-
- myViewport = new FreeformViewport();
- myViewport.setContents(innerLayers);
-
- setViewport(myViewport);
-
- // CR389495: Working with nested complex activities causes in the BP
- // editor causes lockup
- // not related to this CR but discovered while working on it:
- // make sure we observe grid visibility from preferences
- getGridLayer().setVisible(defaultGridEnabled);
- getGridLayer().setSpacing(defaultGridSpacing);
- getGridLayer().setForegroundColor(defaultGridColor);
-
- setText(PreferenceMessages.WindowFigure_Title);
-
- addTabbedWindowListener(new WindowFigureListener() {
- public void tabChanged(int oldIndex, int newIndex) {
- internalSetCurrentTab(newIndex);
- validate();
- }
- });
- addAncestorListener(new AncestorListener() {
-
- public void ancestorAdded(IFigure ancestor) {
- setVisible(true);
- }
-
- public void ancestorMoved(IFigure ancestor) {
- // validateComposite();
- }
-
- public void ancestorRemoved(IFigure ancestor) {
- setVisible(false);
- }
- });
- }
-
- // //////////////////////////////////////////////////////////////////////////
- // Layer management
- // //////////////////////////////////////////////////////////////////////////
-
- /**
- * @param layeredPane
- */
- protected void createLayers(LayeredPane layeredPane) {
- layeredPane.add(getScaledLayers(), SCALABLE_LAYERS);
- layeredPane.add(new FreeformLayer(), HANDLE_LAYER);
- // CR377650: Horizontal scrolling needs to be improved
- // moved the feedback layer into printable layers so it shows up in
- // content outline
- // layeredPane.add(new MyFeedbackLayer(), FEEDBACK_LAYER);
- layeredPane.add(new GuideLayer(), GUIDE_LAYER);
- }
-
- /**
- * @return the pane
- */
- protected ScalableFreeformLayeredPane createScaledLayers() {
- ScalableFreeformLayeredPane layers = new ScalableFreeformLayeredPane();
- layers.add(createGridLayer(), GRID_LAYER);
- layers.add(getPrintableLayers(), PRINTABLE_LAYERS);
- // CR389070: Figures are abbreviating rule figures names and making them
- // unreadable
- // not needed (?)
- // layers.add(new MyFeedbackLayer(), SCALED_FEEDBACK_LAYER);
- return layers;
- }
-
- /**
- * @return layered pane
- */
- protected LayeredPane getScaledLayers() {
- if (scaledLayers == null)
- scaledLayers = createScaledLayers();
- return scaledLayers;
- }
-
- /**
- * @return layered pane
- */
- protected LayeredPane createPrintableLayers() {
- FreeformLayeredPane layeredPane = new FreeformLayeredPane();
-
- PrintedPageLayer pageTileLayer = new PrintedPageLayer(this);
- // TODO: get the printer page size from printer preferences
- // and set into the PageTileLayer.
- pageTileLayer.setPageSize(new Dimension(0, 0));
- layeredPane.add(pageTileLayer, PrintedPageLayer.PRINTED_PAGE_LAYER, -1);
-
- // CR400208: Lines bleed from the bp canvas through the Fault handler
- // window
- // changed z-order of connection layer so that it is below figures
- layeredPane.add(new ConnectionLayer(), CONNECTION_LAYER, -1);
- primaryLayer = new FreeformLayer();
- layeredPane.add(primaryLayer, PRIMARY_LAYER, -1);
- primaryLayer.setLayoutManager(new FreeformLayout());
-
- // CR377650: Horizontal scrolling needs to be improved
- // let's put the feedback layer in with the printable layers so
- // we can see the feedback figures in the content outline viewer
- layeredPane.add(new MyFeedbackLayer(), FEEDBACK_LAYER);
- return layeredPane;
- }
-
- /**
- * @return the layered pane
- */
- protected LayeredPane getPrintableLayers() {
- if (printableLayers == null)
- printableLayers = createPrintableLayers();
- return printableLayers;
- }
-
- /**
- * @return the grid layer
- */
- protected GridLayer createGridLayer() {
- return new MyGridLayer();
- }
-
- /**
- * @return the grid layer
- */
- public GridLayer getGridLayer() {
- return (GridLayer) getLayer(GRID_LAYER);
- }
-
- public Layer getLayer(Object key) {
- // ScalableFreeformRootEditPart:
- Layer layer = null;
- if (scaledLayers != null)
- layer = scaledLayers.getLayer(key);
- if (layer != null)
- return layer;
- // FreeformGraphicalRootEditPart:
- if (innerLayers == null)
- return null;
- layer = innerLayers.getLayer(key);
- if (layer != null)
- return layer;
- if (printableLayers == null)
- return null;
- return printableLayers.getLayer(key);
- }
-
- // //////////////////////////////////////////////////////////////////////////
- // Properties
- // //////////////////////////////////////////////////////////////////////////
-
- /**
- * @return the scroll position
- */
- public Point getScrollPosition() {
- int x = getHorizontalScrollBar().getRangeModel().getValue();
- int y = getVerticalScrollBar().getRangeModel().getValue();
- return new Point(x, y);
- }
-
- /**
- * @return the border
- */
- public TabbedTitleBarBorder getTabbedTitleBarBorder() {
- return titleBarBorder;
- }
-
- /**
- * @return the border
- */
- public TabbedWindowBorder getTabbedWindowBorder() {
- return windowBorder;
- }
-
- /**
- * @param listener
- */
- public void addTabbedWindowListener(WindowFigureListener listener) {
- titleBarBorder.addTabbedWindowListener(listener);
- }
-
- /**
- * @param listener
- */
- public void removeTabbedWindowListener(WindowFigureListener listener) {
- titleBarBorder.removeTabbedWindowListener(listener);
- }
-
- public Dimension getMinimumSize(int wHint, int hHint) {
- Dimension d = titleBarBorder.getMinimumSize(wHint, hHint);
- d.expand(getInsets().getWidth(), getInsets().getHeight());
- return d;
- }
-
- /**
- * @param s
- * @return the previous number of tabs
- */
- public int addTab(String s) {
- return titleBarBorder.addTab(s);
- }
-
- /**
- * @param index
- */
- public void removeTab(int index) {
- titleBarBorder.removeTab(index);
- internalSetCurrentTab(titleBarBorder.getCurrentTab());
- }
-
- private void internalSetCurrentTab(int index) {
- // Object contents = titleBarBorder.getContents(index);
- // if (contents instanceof IFigure)
- // setContents((IFigure) contents);
- }
-
- /**
- * @param index
- */
- public void setCurrentTab(int index) {
- internalSetCurrentTab(index);
- titleBarBorder.setCurrentTab(index);
- }
-
- /**
- * @return the current tab index
- */
- public int getCurrentTab() {
- return titleBarBorder.getCurrentTab();
- }
-
- public void setContents(IFigure figure) {
- titleBarBorder.setContents(0, figure);
- super.setContents(figure);
- }
-
- /**
- * @param index
- * @param contents
- */
- public void setContents(int index, Object contents) {
- if (contents instanceof IFigure)
- setContents((IFigure) contents);
- titleBarBorder.setContents(index, contents);
- }
-
- /**
- * @param index
- * @return the content object of the index
- */
- public Object getContents(int index) {
- return titleBarBorder.getContents(index);
- }
-
- public void setVisible(boolean flag) {
- super.setVisible(flag);
- windowBorder.setVisible(flag);
- // hide/show the window contents if it's a SWT composite
- Object contents = getContents();
- if (contents instanceof Composite)
- ((Composite) contents).setVisible(flag);
- }
-
- public void setHighlight(boolean flag) {
- windowBorder.setHighlight(flag);
- }
-
- public void setFont(Font f) {
- titleBarBorder.setFont(f);
- }
-
- public void setForegroundColor(Color c) {
- titleBarBorder.setTextColor(c);
- }
-
- /**
- * @param style
- */
- public void setLineRoutingStyle(int style) {
- defaultLineRoutingStyle = style;
- revalidate();
- }
-
- /**
- * @return the line routing style
- */
- public int getLineRoutingStyle() {
- return defaultLineRoutingStyle;
- }
-
- public Dimension getPreferredSize(int wHint, int hHint) {
- if (prefSize == null) {
- IFigure parent = getParent();
- prefSize = parent.getSize();
- this.getLayoutManager().invalidate();
- Dimension m = super.getPreferredSize(wHint, hHint);
- if (getParent() instanceof CompoundNodeFigure) {
- if (((CompoundNodeFigure) parent).getState() == CompoundNodeFigure.RESTORED) {
- Insets in = ((CompoundNodeFigure) getParent())
- .getAnchorInsets();
- prefSize.width -= in.getWidth();
- prefSize.height -= in.getHeight();
- }
- } else {
- if (m.width > prefSize.width)
- prefSize.width = m.width;
- if (m.height > prefSize.height)
- prefSize.height = m.height;
- }
- }
- return prefSize;
- }
-
- protected boolean isValidationRoot() {
- return true;
- }
-
- // private void validateComposite() {
- // Object contents = getContents();
- // // System.out.println("validate: "+titleBarBorder.getLabel(0)+"
- // // "+contents);
- // if (contents instanceof Composite) {
- // if (getParent() == null) {
- // System.err.println("TabbedWindowFigure.validate() - ERROR");
- // return;
- // }
- // Rectangle r = getBounds().getCopy();
- // r.crop(getInsets());
- // Dimension ps = getParent().getParent().getPreferredSize();
- // Rectangle pr = getParent().getParent().getBounds();
- // titleBarBorder.invalidate();
- // titleBarBorder.getInsets(this);
- // Insets in = getParent().getParent().getInsets();
- // Composite comp = (Composite) getContents();
- // comp.setBounds(pr.x + r.x + in.left, pr.y + r.y, r.width, r.height);
- // comp.moveAbove(null);
- // }
- // }
-
- public void invalidate() {
- prefSize = null;
- super.invalidate();
- }
-
- // //////////////////////////////////////////////////////////////////////
- // IBaseFigure methods
- // //////////////////////////////////////////////////////////////////////
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setText(String
- * text)
- */
- public void setText(String name) {
- titleBarBorder.setLabel(name);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getText()
- */
- public String getText() {
- if (titleBarBorder == null)
- return PreferenceMessages.WindowFigure_NoTitleText;
- return titleBarBorder.getLabel();
- }
-
- /*
- * CR374981: Long activity labels do not get wrapped or truncated This
- * method was added to the IBaseFigure interface to support direct edit of
- * figure labels on the canvas.
- */
- public Rectangle getTextBounds() {
- Rectangle r = getClientArea().getCopy();
- r.height = titleBarBorder.getTextExtents(this).height;
- r.x += getInsets().left;
- r.y -= getInsets().top;
- return r;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getIcon()
- */
- public Image getIcon() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setIcon(org.eclipse.swt.graphics.Image)
- */
- public void setIcon(Image image) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#setToolTipText(java.lang.String)
- */
- public void setToolTipText(String text) {
- // do nothing
- }
-
- public String getToolTipText() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#addDecorator(com.sybase.stf.gem.diagram.editor.figures.BaseFigureDecorator)
- */
- public void addDecorator(BaseFigureDecorator decorator) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator()
- */
- public void removeDecorator() {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#removeDecorator(int)
- */
- public void removeDecorator(int position) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.gem.diagram.editor.figures.IBaseFigure#getDecorators()
- */
- public List getDecorators() {
- return null;
- }
-
- // //////////////////////////////////////////////////////////////////////
- // FreeformFigure methods
- // //////////////////////////////////////////////////////////////////////
-
- private WindowFreeformHelper helper = new WindowFreeformHelper(this);
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#addFreeformListener(org.eclipse.draw2d.FreeformListener)
- */
- public void addFreeformListener(FreeformListener listener) {
- addListener(FreeformListener.class, listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#fireExtentChanged()
- */
- public void fireExtentChanged() {
- Iterator iter = getListeners(FreeformListener.class);
- while (iter.hasNext())
- ((FreeformListener) iter.next()).notifyFreeformExtentChanged();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#getFreeformExtent()
- */
- public Rectangle getFreeformExtent() {
- Rectangle r = helper.getFreeformExtent();
- r.x = 0;
- r.y = 0;
- return r;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#removeFreeformListener(org.eclipse.draw2d.FreeformListener)
- */
- public void removeFreeformListener(FreeformListener listener) {
- removeListener(FreeformListener.class, listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.draw2d.FreeformFigure#setFreeformBounds(org.eclipse.draw2d.geometry.Rectangle)
- */
- public void setFreeformBounds(Rectangle bounds) {
- helper.setFreeformBounds(bounds);
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigureListener.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigureListener.java
deleted file mode 100644
index e26390440..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFigureListener.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-/**
- * @author Bob Brodt
- *
- * Defines an interface for notifying listeners of page switches on a tabbed
- * window figure.
- */
-/*package*/ interface WindowFigureListener {
- /**
- * @param oldIndex
- * @param newIndex
- */
- void tabChanged(int oldIndex, int newIndex);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFreeformHelper.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFreeformHelper.java
deleted file mode 100644
index 55be3a40a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/preference/WindowFreeformHelper.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.preference;
-
-import java.util.List;
-
-import org.eclipse.draw2d.FigureListener;
-import org.eclipse.draw2d.FreeformFigure;
-import org.eclipse.draw2d.FreeformLayeredPane;
-import org.eclipse.draw2d.FreeformListener;
-import org.eclipse.draw2d.IFigure;
-import org.eclipse.draw2d.geometry.Insets;
-import org.eclipse.draw2d.geometry.Rectangle;
-
-/**
- * Stolen from org.eclipse.draw2d.FreeformHelper. See also FreeformLayeredPane.
- *
- * @author bbrodt
- */
-/*package*/ class WindowFreeformHelper implements FreeformListener {
- FreeformLayeredPane x;
-
- class ChildTracker implements FigureListener {
- public void figureMoved(IFigure source) {
- invalidate();
- }
- }
-
- private FreeformFigure host;
-
- private Rectangle freeformExtent;
-
- private FigureListener figureListener = new ChildTracker();
-
- /**
- * @param host
- */
- public WindowFreeformHelper(FreeformFigure host) {
- this.host = host;
- }
-
- /**
- * @return the freeform extent
- */
- public Rectangle getFreeformExtent() {
- if (freeformExtent != null)
- return freeformExtent;
- Rectangle r;
- List children = host.getChildren();
- for (int i = 0; i < children.size(); i++) {
- IFigure child = (IFigure) children.get(i);
- if (child instanceof FreeformFigure)
- r = ((FreeformFigure) child).getFreeformExtent();
- else
- r = child.getBounds();
- if (freeformExtent == null)
- freeformExtent = r.getCopy();
- else
- freeformExtent.union(r);
- }
- Insets insets = host.getInsets();
- if (freeformExtent == null)
- freeformExtent = new Rectangle(0, 0, insets.getWidth(), insets
- .getHeight());
- else {
- host.translateToParent(freeformExtent);
- freeformExtent.expand(insets);
- }
- // System.out.println("New extent calculated for " + host + " = " +
- // freeformExtent);
- return freeformExtent;
- }
-
- /**
- * @param child
- */
- public void hookChild(IFigure child) {
- invalidate();
- if (child instanceof FreeformFigure)
- ((FreeformFigure) child).addFreeformListener(this);
- else
- child.addFigureListener(figureListener);
- }
-
- void invalidate() {
- freeformExtent = null;
- host.fireExtentChanged();
- if (host.getParent() != null)
- host.getParent().revalidate();
- else
- host.revalidate();
- }
-
- public void notifyFreeformExtentChanged() {
- // A childs freeform extent has changed, therefore this extent must be
- // recalculated
- invalidate();
- }
-
- /**
- * @param bounds
- */
- public void setFreeformBounds(Rectangle bounds) {
- host.setBounds(bounds);
- bounds = bounds.getCopy();
- host.translateFromParent(bounds);
- List children = host.getChildren();
- for (int i = 0; i < children.size(); i++) {
- IFigure child = (IFigure) children.get(i);
- if (child instanceof FreeformFigure)
- ((FreeformFigure) child).setFreeformBounds(bounds);
- }
- // CR420954: Compensation Handler canvas goes blank after Variables
- // Sections is expanded
- host.getLayoutManager().layout(host);
- }
-
- /**
- * @param child
- */
- public void unhookChild(IFigure child) {
- invalidate();
- if (child instanceof FreeformFigure)
- ((FreeformFigure) child).removeFreeformListener(this);
- else
- child.removeFigureListener(figureListener);
- }
-
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanContentProvider.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanContentProvider.java
deleted file mode 100644
index 45d15b4c3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanContentProvider.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.provider;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ManagedBeanScopeTreeItem;
-
-/**
- * Managed bean Content Provider.
- * <p>
- * <b>Provides grouping by Scope.</b>
- * </p>
- *
- * @author Xiao-guang Zhang, sfshi
- * @version 1.5
- */
-public class ManagedBeanContentProvider implements ITreeContentProvider {
-
- private List scopeItemList = null;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(Object
- * parent)
- */
- public Object[] getChildren(Object parent) {
-
- if (parent instanceof FacesConfigType) {
- if (scopeItemList == null) {
- scopeItemList = new ArrayList();
- for (int i = 0; i < ManagedBeanScopeTreeItem.scopeItems.length; i++) {
- ManagedBeanScopeTreeItem scopeTreeItem = new ManagedBeanScopeTreeItem(
- ManagedBeanScopeTreeItem.scopeItems[i],
- (FacesConfigType) parent);
- scopeItemList.add(scopeTreeItem);
- }
- }
- return scopeItemList.toArray();
- } else if (parent instanceof ManagedBeanScopeTreeItem) {
- return ((ManagedBeanScopeTreeItem) parent).getChildren().toArray();
- }
-
- return new Object[0];
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ITreeContentProvider#getElements(Object
- * parent)
- */
- public Object[] getElements(Object inputElement) {
- return getChildren(inputElement);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object)
- */
- public Object getParent(Object element) {
- if (element instanceof ManagedBeanScopeTreeItem) {
- return ((ManagedBeanScopeTreeItem) element).getParent();
- } else if (element instanceof ManagedBeanType) {
- String scope = null;
- if (((ManagedBeanType) element).getManagedBeanScope() != null) {
- scope = ((ManagedBeanType) element).getManagedBeanScope()
- .getTextContent();
- }
-
- if (scope != null) {
- for (int i = 0; i < scopeItemList.size(); i++) {
- if (((ManagedBeanScopeTreeItem) scopeItemList.get(i))
- .getScope().equals(scope)) {
- return scopeItemList.get(i);
- }
-
- }
- }
- }
-
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object)
- */
- public boolean hasChildren(Object element) {
- if (element instanceof FacesConfigType) {
- return true;
- } else if (element instanceof ManagedBeanScopeTreeItem) {
- return ((ManagedBeanScopeTreeItem) element).hasChildren();
- }
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.IContentProvider#dispose()
- */
- public void dispose() {
- // TODO Auto-generated method stub
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer,
- * java.lang.Object, java.lang.Object)
- */
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- if (newInput != null) {
-// initialize(newInput);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanLabelProvider.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanLabelProvider.java
deleted file mode 100644
index 8a51f088e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/provider/ManagedBeanLabelProvider.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.provider;
-
-import java.util.Hashtable;
-import java.util.Map;
-
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.section.ManagedBeanScopeTreeItem;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * The Managed Bean Page's TreeViewer Label Provider
- *
- * @author Xiao-guang Zhang, sfshi
- * @version 1.5
- */
-public class ManagedBeanLabelProvider extends LabelProvider {
-
- private static final String SCOPE_IMAGE_FILE = "Scope.gif"; //$NON-NLS-1$
- private static final String SCOPE_NONE_IMAGE_FILE = "Scope_None.gif"; //$NON-NLS-1$
- private static final String SCOPE_APPLICATION_IMAGE_FILE = "Scope_Application.gif"; //$NON-NLS-1$
- private static final String SCOPE_REQUEST_IMAGE_FILE = "Scope_Request.gif"; //$NON-NLS-1$
- private static final String SCOPE_SESSION_IMAGE_FILE = "Scope_Session.gif"; //$NON-NLS-1$
- private static final String MANAGED_BEAN_IMAGE_FILE = "facesconfig/FacesConfig_ManagedBean.gif"; //$NON-NLS-1$
-
- /** Cache of images that have been dispensed by this provider */
- private Map imageTable;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.LabelProvider#getText(Object obj)
- */
- public String getText(Object obj) {
- String text = ""; //$NON-NLS-1$
-
- if (obj instanceof ManagedBeanType) {
- ManagedBeanType bean = (ManagedBeanType) obj;
- if (bean.getManagedBeanName() != null) {
- text = bean.getManagedBeanName().getTextContent();
-
- }
- if (text == null || text.length() < 1) {
- if (bean.getManagedBeanClass() != null)
- text = bean.getManagedBeanClass().getTextContent();
- }
- } else if (obj instanceof ManagedBeanScopeTreeItem) {
- text = ((ManagedBeanScopeTreeItem) obj).getScope();
- }
-
- return text;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.LabelProvider#getImage(Object obj)
- */
- public Image getImage(Object obj) {
- ImageDescriptor imageDesc = null;
- if (obj instanceof ManagedBeanType) {
-
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- MANAGED_BEAN_IMAGE_FILE);
-
- } else if (obj instanceof ManagedBeanScopeTreeItem) {
- ManagedBeanScopeTreeItem scopeTreeItem = (ManagedBeanScopeTreeItem) obj;
- if (IFacesConfigConstants.MANAGED_BEAN_SCOPE_SESSION
- .equals(scopeTreeItem.getScope())) {
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- SCOPE_SESSION_IMAGE_FILE);
- } else if (IFacesConfigConstants.MANAGED_BEAN_SCOPE_REQUEST
- .equals(scopeTreeItem.getScope())) {
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- SCOPE_REQUEST_IMAGE_FILE);
- } else if (IFacesConfigConstants.MANAGED_BEAN_SCOPE_APPLICATION
- .equals(scopeTreeItem.getScope())) {
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- SCOPE_APPLICATION_IMAGE_FILE);
- } else if (IFacesConfigConstants.MANAGED_BEAN_SCOPE_NONE
- .equals(scopeTreeItem.getScope())) {
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- SCOPE_NONE_IMAGE_FILE);
- } else {
- imageDesc = EditorPlugin.getDefault().getImageDescriptor(
- SCOPE_IMAGE_FILE);
- }
- }
-
- if (imageDesc != null) {
- // Obtain the cached image corresponding to the descriptor
- if (imageTable == null) {
- imageTable = new Hashtable(40);
- }
- Image image = (Image) imageTable.get(imageDesc);
- if (image == null) {
- image = imageDesc.createImage();
- imageTable.put(imageDesc, image);
- }
- return image;
- }
- return PlatformUI.getWorkbench().getSharedImages().getImage(
- ISharedImages.IMG_OBJ_ELEMENT);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractFacesConfigSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractFacesConfigSection.java
deleted file mode 100644
index 88dc8d8a2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractFacesConfigSection.java
+++ /dev/null
@@ -1,295 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.help.HelpSystem;
-import org.eclipse.help.IContext;
-import org.eclipse.help.IHelpResource;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.SectionPart;
-import org.eclipse.ui.forms.events.HyperlinkAdapter;
-import org.eclipse.ui.forms.events.HyperlinkEvent;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.ImageHyperlink;
-import org.eclipse.ui.forms.widgets.Section;
-
-
-/**
- * The abstract implementation of IFacesConfigSection.
- *
- *
- * @author jchoi, xgzhang, sfshi
- *
- * @version 1.0
- */
-public abstract class AbstractFacesConfigSection extends SectionPart implements
- IFacesConfigSection, ISelectionProvider, ISelectionChangedListener {
- /** tool kit */
- private FormToolkit toolkit;
-
- /** help context id */
- private String helpContextId = null;
-
- /** help tool tip string */
- private String helpTooltip = null;
-
- /** model object */
- private Object input = null;
-
- private IFacesConfigPage page;
-
- private List selectionChangedListeners = new ArrayList();
-
- /** help image */
- private final static Image HELP_IMAGE = EditorPlugin.getDefault().getImage(
- "help.gif"); //$NON-NLS-1$
-
- /**
- * Constructor with help option.
-
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public AbstractFacesConfigSection(Composite parent,
- IManagedForm managedForm, IFacesConfigPage page,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(parent, toolkit, ExpandableComposite.TITLE_BAR
- | ExpandableComposite.TWISTIE | Section.DESCRIPTION
- | ExpandableComposite.EXPANDED);
- super.initialize(managedForm);
- this.page = page;
- this.toolkit = toolkit;
- this.helpContextId = helpContextId;
- this.helpTooltip = helpTooltip;
- }
-
- public void dispose() {
- selectionChangedListeners.clear();
- if (input != null)
- removeAdaptersFromInput(input);
- super.dispose();
- }
- /**
- *
- */
- public void initialize() {
- if (helpContextId != null) {
- createTextClientWithHelp();
- }
-
- getSection().setLayout(new GridLayout());
-
- Composite clientContainer = toolkit.createComposite(getSection());
- GridData gd = new GridData(GridData.FILL_BOTH);
- clientContainer.setLayoutData(gd);
-
- createContents(clientContainer, toolkit);
- getSection().setClient(clientContainer);
-
- }
-
- /**
- *
- *
- */
- private void createTextClientWithHelp() {
- ImageHyperlink helpImage = new ImageHyperlink(getSection(), SWT.NULL);
-
- toolkit.adapt(helpImage, true, true);
-
- helpImage.setImage(HELP_IMAGE);
-
- helpImage.setBackground(getSection().getTitleBarGradientBackground());
- if (helpTooltip != null) {
- helpImage.setToolTipText(helpTooltip);
- }
-
- helpImage.addHyperlinkListener(new HyperlinkAdapter() {
- public void linkActivated(HyperlinkEvent e) {
- IContext context = HelpSystem.getContext(helpContextId);
- if (context != null) {
- IHelpResource[] topics = context.getRelatedTopics();
- if (topics != null && topics.length == 1) {
- EditorPlugin.getDefault().getWorkbench()
- .getHelpSystem().displayHelpResource(
- topics[0].getHref());
- } else {
- EditorPlugin.getDefault().getWorkbench()
- .getHelpSystem().displayHelp(helpContextId);
- }
- }
- }
- });
-
- getSection().setTextClient(helpImage);
- }
-
- /**
- * The sub calss should implement this method to create and fill the
- * contents in the section
- *
- * @param container
- * @param toolkit_
- */
- protected abstract void createContents(Composite container,
- FormToolkit toolkit_);
-
- /**
- * get the input object of this section.
- */
- public Object getInput() {
- return input;
- }
-
- /**
- * set input object for this section.
- */
- public void setInput(Object newInput) {
- if (input != null)
- removeAdaptersFromInput(input);
-
- input = newInput;
-
- if (newInput != null)
- addAdaptersOntoInput(newInput);
- // if (this.getSection().isExpanded())
- refreshAll();
- }
-
- /**
- * Remove adapters from the input object when the section changes it's
- * input. Sub classes should overwrite this method to remove the adapters
- * that they added on.
- *
- * @param oldInput
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- // do nothing; subs should override
- }
-
- /**
- * Add adapters onto the input object when the section has new input. Sub
- * classes should their own adapters.
- *
- * @param newInput
- */
- protected void addAdaptersOntoInput(Object newInput) {
- // do nothing; subs should override
- }
-
- /**
- * @return the page that this section lies in.
- */
- public IFacesConfigPage getPage() {
- return page;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return StructuredSelection.EMPTY;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // do nothing: no selection change
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /**
- * transfer the selection changed event to detail part.
- */
- public void selectionChanged(SelectionChangedEvent event) {
-
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener.selectionChanged(new SelectionChangedEvent(this,
- event != null ? event.getSelection()
- : StructuredSelection.EMPTY));
- }
- }
-
- /**
- * the convenient method to get the AdapterFactory instance of the editor;
- *
- * @return the AdapterFactory instance.
- */
- public AdapterFactory getAdapterFactory() {
- return (AdapterFactory) getPage().getEditor().getAdapter(
- AdapterFactory.class);
- }
-
- /**
- * the convenient method to get the EditingDomain instance of the editor;
- *
- * @return the EditingDomain instance.
- */
- public EditingDomain getEditingDomain() {
- return (EditingDomain) getPage().getEditor().getAdapter(
- EditingDomain.class);
- }
-
- public void clearAll()
- {
- // do nothing, sub-classes may choose to override to clear their contents
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractOverviewSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractOverviewSection.java
deleted file mode 100644
index b8e13ba85..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AbstractOverviewSection.java
+++ /dev/null
@@ -1,136 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jst.jsf.common.ui.internal.actions.OpenPageAction;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- *
- */
-public abstract class AbstractOverviewSection extends
- AbstractFacesConfigSection {
-
- /**
- * the common table viewer used for the contents
- */
- protected TableViewer tableViewer;
-
- private String targetPageID;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param targetPageID
- * @param title
- * @param description
- * @param helpContextId
- * @param helpTooltip
- */
- public AbstractOverviewSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit, String targetPageID,
- String title, String description, String helpContextId,
- String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- this.targetPageID = targetPageID;
- getSection().setText(title);
- getSection().setDescription(description);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#createContents(org.eclipse.swt.widgets.Composite,
- * org.eclipse.ui.forms.widgets.FormToolkit)
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
-
- GridLayout layout = new GridLayout();
- layout.numColumns = 1;
- layout.marginHeight = 2;
- layout.marginWidth = 2;
- layout.verticalSpacing = 5;
- layout.horizontalSpacing = 6;
- container.setLayout(layout);
- toolkit.paintBordersFor(container);
- Table table = createTable(container);
- if (targetPageID != null) {
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection())
- .size() == 1) {
- OpenPageAction action = new OpenPageAction();
- action.setPageName(targetPageID);
- action.setSelection(tableViewer.getSelection());
- action.run();
- }
- }
- });
- }
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- ComposedAdapterFactory factory = (ComposedAdapterFactory)getAdapterFactory();
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(factory));
- configTableViewer(tableViewer);
- }
-
- /**
- *
- * @param container
- * @return the table
- */
- abstract protected Table createTable(Composite container);
-
- /**
- *
- * @param tableViewer1
- */
- abstract protected void configTableViewer(TableViewer tableViewer1);
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection#clearAll()
- */
- public void clearAll() {
- tableViewer.setInput(null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection#refreshAll()
- */
- public void refreshAll() {
- tableViewer.setInput(getInput());
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ApplicationSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ApplicationSection.java
deleted file mode 100644
index b121d0ec8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ApplicationSection.java
+++ /dev/null
@@ -1,216 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jdt.ui.IJavaElementSearchConstants;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.DialogUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * A common <code>IFacesConfigSection</code> implementation for the sections that editing
- * the child elements of <application>, including: <action-listener>,
- * <default-render-kit-id>, <message-bundle>, <navigation-handler>,
- * <view-handler>,<state-manager>, <property-resolver>, <variable-resolver> and
- * <locale-config>. This sections will use the EClass object of these elements
- * as the key.
- *
- * @author Zhi-peng Zhang, sfshi
- * @version
- */
-public class ApplicationSection extends OthersPageBaseSection {
-
- /** The Eclass object this Section operated */
- private EClass applicationChildClass;
-
- /**
- *
- * @param applicationChildClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public ApplicationSection(EClass applicationChildClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- this.applicationChildClass = applicationChildClass;
- }
-
- /**
- *
- * @param componentClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public ApplicationSection(EClass componentClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- this(componentClass, parent, managedForm, page, toolkit, null, null);
- }
-
- /**
- * Create an object which is instance of <code>applicationChildClass</code>.
- *
- * @return the child class object
- */
- public EObject createApplicationChildObject() {
- String textValue = null;
- IProject project = (IProject) this.getPage().getEditor().getAdapter(
- IProject.class);
- FacesConfigType facesConfig = (FacesConfigType) this.getPage()
- .getInput();
- if (applicationChildClass == FacesConfigPackage.eINSTANCE
- .getDefaultRenderKitIdType()) {
-
- /** Open a dialog to select a render-kit of this faces config. */
- textValue = DialogUtil.openRenderKitDialog(getSection().getShell(),
- facesConfig);
- } else if (applicationChildClass == FacesConfigPackage.eINSTANCE
- .getMessageBundleType()) {
- /**
- * Open a dialog the select the message bundles that in current
- * project. If user select a bundle that already declared in this
- * faces config, then shows a warning message.
- */
- List bundles = new ArrayList();
- if (facesConfig.getApplication().size() > 0) {
- ApplicationType applicationType = (ApplicationType) facesConfig
- .getApplication().get(0);
- bundles = applicationType.getMessageBundle();
- }
-
- textValue = DialogUtil.openMessageBundleDialog(getSection()
- .getShell(), project, bundles);
-
- } else {
- /**
- * For other types children, open a ClassDialog to select a class in
- * current project.
- */
- String superType = ModelUtil.getSuperType(applicationChildClass);
- textValue = DialogUtil.openClassDialog(getSection().getShell(),
- project, superType,
- IJavaElementSearchConstants.CONSIDER_ALL_TYPES);
- }
- if (textValue != null && textValue.length() > 0) {
- EObject component = FacesConfigFactory.eINSTANCE
- .create(applicationChildClass);
- // set text content.
- EStructuralFeature feature = applicationChildClass
- .getEStructuralFeatures().get(0);
- component.eSet(feature, textValue);
- return component;
- }
- return null;
- }
-
- /**
- * Set the <application> element as the structuredViewer's input.
- *
- * @param input
- */
- protected void setViewerInput(Object input) {
- if (input instanceof ApplicationType) {
- tableViewer.setInput(input);
- } else
- tableViewer.setInput(null);
- }
-
- /**
- * Add a filter on the table viewer. Only the elements that is a instance of
- * <code>applicationChildClass</code> could be selected.
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return applicationChildClass.isInstance(element);
- }
- });
- }
-
- /**
- * Perform some actions to create new child object and append it to the
- * <application> element.
- */
- void addButtonSelected(SelectionEvent e) {
- /** Create such a new object. */
- EObject obj = createApplicationChildObject();
- if (obj != null) {
-
- boolean needRefreshAll = false;
- Command command = null;
- if (getInput() instanceof ApplicationType) {
- /**
- * The input is a <application> element and not null, append the
- * new object to it.
- */
- ApplicationType application = (ApplicationType) getInput();
- command = AddCommand.create(getEditingDomain(), application,
- null, obj);
- } else {
- /**
- * The input is null, create a <application> element and append
- * it to <faces-config>.
- */
- needRefreshAll = true;
-
- List list = new ArrayList(2);
- ApplicationType application = FacesConfigFactory.eINSTANCE
- .createApplicationType();
- Command cmd1 = AddCommand.create(getEditingDomain(),
- application, null, obj);
- list.add(cmd1);
- Command cmd2 = AddCommand.create(getEditingDomain(), this
- .getPage().getInput(), null, application);
- list.add(cmd2);
- command = new CompoundCommand(list);
- }
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- if (needRefreshAll) {
- /** reset the application input. */
- ((OthersPage) this.getPage()).resetApplicationInput();
- }
- }
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AttributeSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AttributeSection.java
deleted file mode 100644
index 687ffcfca..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/AttributeSection.java
+++ /dev/null
@@ -1,509 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.AttributeClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.AttributeNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.AttributeType;
-import org.eclipse.jst.jsf.facesconfig.emf.DefaultValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.SuggestedValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditAttributeDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Attribute section
- *
- */
-public class AttributeSection extends AbstractFacesConfigSection {
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public AttributeSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- this.getSection().setText(EditorMessages.AttributeSection_Name);
- this.getSection().setDescription(
- EditorMessages.AttributeSection_Description);
-
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- gl.numColumns = 2;
- container.setLayout(gl);
- GridData td = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
-
- Composite attributeSection = toolkit.createComposite(container);
- GridLayout gl2 = new GridLayout();
- gl2.horizontalSpacing = 0;
- gl2.verticalSpacing = 0;
- gl2.marginWidth = 0;
- gl2.marginHeight = 0;
- gl2.numColumns = 2;
- attributeSection.setLayout(gl2);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.VERTICAL_ALIGN_BEGINNING);
- attributeSection.setLayoutData(gd);
-
- createTableSection(attributeSection, toolkit);
- createButtonsSection(attributeSection, toolkit);
-
- }
-
- /**
- * create table section
- *
- * @param container
- * @param toolkit
- */
- private void createTableSection(Composite container, FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.GRAB_HORIZONTAL);
- tableContainer.setLayoutData(gd);
- toolkit.paintBordersFor(tableContainer);
-
- GridLayout gl = new GridLayout();
- tableContainer.setLayout(gl);
-
- Table table = new Table(tableContainer, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
-
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
-
- TableColumn nameCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- nameCol
- .setText(EditorMessages.AttributeSection_Table_NameColumn);
-
- TableColumn classCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- classCol
- .setText(EditorMessages.AttributeSection_Table_ClassColumn);
-
- TableColumn valueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol
- .setText(EditorMessages.AttributeSection_Table_DefaultValueColumn);
-
- TableColumn suggestedValueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- suggestedValueCol
- .setText(EditorMessages.AttributeSection_Table_SuggestedValueColumn);
-
- table.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
- });
-
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
-
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getAttributeType()
- .isInstance(element);
- }
- });
-
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- * Update the buttons' enable and disable status
- */
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- * create buttons
- *
- * @param container
- * @param toolkit
- */
- private void createButtonsSection(Composite container, FormToolkit toolkit) {
- // create operation buttons's container
- Composite operationContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_VERTICAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- operationContainer.setLayoutData(gd);
- GridLayout gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
-
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
-
- });
- }
-
- /**
- *
- */
- public void refreshAll() {
- tableViewer.setInput(getInput());
- updateButtons();
-
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- tableViewer.refresh();
- updateButtons();
- }
-
- /**
- * add an attribute.
- *
- */
- private void addButtonSelected() {
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditAttributeDialog dialog = new AddEditAttributeDialog(shell, true);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (dialog.open() == Dialog.OK) {
-
- // AttributeType newAttribute = dialog.getResult();
- AttributeType newAttribute = FacesConfigFactory.eINSTANCE
- .createAttributeType();
-
- if (dialog.getAttributeName().length() > 0) {
- AttributeNameType attributeNameType = FacesConfigFactory.eINSTANCE
- .createAttributeNameType();
- attributeNameType.setTextContent(dialog.getAttributeName());
- newAttribute.setAttributeName(attributeNameType);
- }
-
- if (dialog.getAttributeClass().length() > 0) {
- AttributeClassType attributeClassType = FacesConfigFactory.eINSTANCE
- .createAttributeClassType();
- attributeClassType.setTextContent(dialog.getAttributeClass());
- newAttribute.setAttributeClass(attributeClassType);
- }
-
- if (dialog.getDefaultValue().length() > 0) {
- DefaultValueType defaultValueType = FacesConfigFactory.eINSTANCE
- .createDefaultValueType();
- defaultValueType.setTextContent(dialog.getDefaultValue());
- newAttribute.setDefaultValue(defaultValueType);
- }
-
- if (dialog.getSuggestedValue().length() > 0) {
- SuggestedValueType suggestedValueType = FacesConfigFactory.eINSTANCE
- .createSuggestedValueType();
- suggestedValueType.setTextContent(dialog.getSuggestedValue());
- newAttribute.setSuggestedValue(suggestedValueType);
- }
-
- Command addCommand = AddCommand.create(this.getEditingDomain(),
- getInput(), null, newAttribute); // getEReference(),
- // newAttribute);
- if (addCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(addCommand);
-
- }
- }
-
- }
-
- /**
- * edit an attribute.
- *
- */
- private void editButtonSelected() {
-
- AttributeType attribute = (AttributeType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(attribute);
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditAttributeDialog dialog = new AddEditAttributeDialog(shell, false);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (attribute.getAttributeName() != null) {
- dialog.setAttributeName(attribute.getAttributeName()
- .getTextContent());
- }
-
- if (attribute.getAttributeClass() != null) {
- dialog.setAttributeClass(attribute.getAttributeClass()
- .getTextContent());
- }
-
- if (attribute.getDefaultValue() != null) {
- dialog
- .setDefaultValue(attribute.getDefaultValue()
- .getTextContent());
- }
-
- if (attribute.getSuggestedValue() != null) {
- dialog.setSuggestedValue(attribute.getSuggestedValue()
- .getTextContent());
- }
-
- if (dialog.open() == Dialog.OK) {
- List commands = new ArrayList(4);
-
- if (attribute.getAttributeName() != null) {
- Command cmd1 = SetCommand.create(this.getEditingDomain(),
- attribute.getAttributeName(),
- FacesConfigPackage.eINSTANCE
- .getAttributeNameType_TextContent(), dialog
- .getAttributeName());
- commands.add(cmd1);
- } else if (dialog.getAttributeName().length() > 0) {
- AttributeNameType attributeNameType = FacesConfigFactory.eINSTANCE
- .createAttributeNameType();
- attributeNameType.setTextContent(dialog.getAttributeName());
-
- Command cmd2 = AddCommand.create(this.getEditingDomain(),
- attribute, FacesConfigPackage.eINSTANCE
- .getAttributeType_AttributeName(),
- attributeNameType);
- commands.add(cmd2);
- }
-
- if (attribute.getAttributeClass() != null) {
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- attribute.getAttributeClass(),
- FacesConfigPackage.eINSTANCE
- .getAttributeClassType_TextContent(), dialog
- .getAttributeClass());
- commands.add(cmd3);
- } else if (dialog.getAttributeClass().length() > 0) {
- AttributeClassType attributeClassType = FacesConfigFactory.eINSTANCE
- .createAttributeClassType();
- attributeClassType.setTextContent(dialog.getAttributeClass());
-
- Command cmd4 = AddCommand.create(this.getEditingDomain(),
- attribute, FacesConfigPackage.eINSTANCE
- .getAttributeType_AttributeClass(),
- attributeClassType);
- commands.add(cmd4);
- }
-
- if (attribute.getDefaultValue() != null) {
- Command cmd5 = SetCommand.create(this.getEditingDomain(),
- attribute.getDefaultValue(),
- FacesConfigPackage.eINSTANCE
- .getDefaultValueType_TextContent(), dialog
- .getDefaultValue());
- commands.add(cmd5);
-
- } else if (dialog.getDefaultValue().length() > 0) {
- DefaultValueType defaultValueType = FacesConfigFactory.eINSTANCE
- .createDefaultValueType();
- defaultValueType.setTextContent(dialog.getDefaultValue());
- Command cmd6 = AddCommand.create(this.getEditingDomain(),
- attribute, FacesConfigPackage.eINSTANCE
- .getAttributeType_DefaultValue(),
- defaultValueType);
- commands.add(cmd6);
- }
-
- if (attribute.getSuggestedValue() != null) {
- Command cmd7 = SetCommand.create(this.getEditingDomain(),
- attribute.getSuggestedValue(),
- FacesConfigPackage.eINSTANCE
- .getSuggestedValueType_TextContent(), dialog
- .getSuggestedValue());
- commands.add(cmd7);
- } else if (dialog.getSuggestedValue().length() > 0) {
- SuggestedValueType suggestedValueType = FacesConfigFactory.eINSTANCE
- .createSuggestedValueType();
- suggestedValueType.setTextContent(dialog.getSuggestedValue());
- Command cmd8 = AddCommand.create(this.getEditingDomain(),
- attribute, FacesConfigPackage.eINSTANCE
- .getAttributeType_SuggestedValue(),
- suggestedValueType);
- commands.add(cmd8);
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(command);
- tableViewer.refresh(attribute);
-
- }
- }
-
- }
-
- /**
- * remove an attribute.
- *
- */
- private void removeButtonSelected() {
- AttributeType attribute = (AttributeType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(attribute);
-
- Command removeCommand = RemoveCommand.create(this.getEditingDomain(),
- getInput(), null, attribute);// getEReference(), attribute);
-
- if (removeCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(removeCommand);
- refreshAll();
- }
-
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return tableViewer.getSelection();
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
-
- tableViewer.setSelection(selection);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentGeneralSection.java
deleted file mode 100644
index d3c84e968..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentGeneralSection.java
+++ /dev/null
@@ -1,406 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentType;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentTypeType;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * The sections that used for displaying and editing the general information of
- * a component, the information includs display name, description, component
- * type and component class.
- *
- * @author sfshi
- *
- */
-public class ComponentGeneralSection extends AbstractFacesConfigSection {
-
- private StringDialogField displayNameField;
-
- private StringDialogField descriptionField;
-
- private StringDialogField componentTypeField;
-
- private ClassButtonDialogField componentClassField;
-
- private ComponentGeneralAdapter componentGeneralAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public ComponentGeneralSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection()
- .setText(EditorMessages.ComponentGeneralSection_Name);
- getSection().setDescription(
- EditorMessages.ComponentGeneralSection_Description);
- }
-
- /**
- * Create the UI fields.
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- container.setLayout(layout);
- GridData td = new GridData(GridData.FILL_HORIZONTAL);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
- displayNameField = new StringDialogField();
- displayNameField
- .setLabelText(EditorMessages.ComponentGeneralSection_Label_DisplayName);
- displayNameField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- displayNameField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- String newDisplayNameValue = ((StringDialogField) field)
- .getText().trim();
- Command cmd = null;
- ComponentType component = (ComponentType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (component.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) component
- .getDisplayName().get(0);
- cmd = SetCommand.create(editingDomain, displayName,
- FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent(),
- newDisplayNameValue);
- } else {
- DisplayNameType displayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayNameType.setTextContent(newDisplayNameValue);
-
- /** For the new displayname object, add the adapter. */
- displayNameType.eAdapters().add(
- getComponentGeneralAdapter());
- cmd = AddCommand.create(editingDomain, component,
- FacesConfigPackage.eINSTANCE
- .getComponentType_DisplayName(),
- displayNameType);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- });
-
- descriptionField = new StringDialogField(2);
- descriptionField
- .setLabelText(EditorMessages.ComponentGeneralSection_Label_Description);
- descriptionField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- descriptionField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String newDescriptionValue = ((StringDialogField) field)
- .getText().trim();
-
- newDescriptionValue = ModelUtil
- .escapeEntities(newDescriptionValue);
- Command cmd = null;
- ComponentType component = (ComponentType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (component.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) component
- .getDescription().get(0);
- cmd = SetCommand.create(editingDomain, description,
- FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent(),
- newDescriptionValue);
- } else {
- DescriptionType description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(newDescriptionValue);
- /** For the new description object, add the adapter. */
- description.eAdapters().add(
- getComponentGeneralAdapter());
-
- cmd = AddCommand.create(editingDomain, component,
- FacesConfigPackage.eINSTANCE
- .getComponentType_Description(),
- description);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
- });
-
- componentTypeField = new StringDialogField();
- componentTypeField
- .setLabelText(EditorMessages.ComponentGeneralSection_Label_ComponentType);
- componentTypeField.doFillIntoGrid(toolkit, container, numberOfColumns);
- componentTypeField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- ComponentTypeType componentType = FacesConfigFactory.eINSTANCE
- .createComponentTypeType();
- componentType
- .setTextContent(((StringDialogField) field)
- .getText());
-
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getComponentType_ComponentType(),
- componentType);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
- }
- });
-
- componentClassField = new ClassButtonDialogField(null);
- componentClassField
- .setLabelText(EditorMessages.ComponentGeneralSection_Label_ComponentClass);
- componentClassField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(componentClassField.getTextControl(
- toolkit, container));
- componentClassField.setProject((IProject) getPage().getEditor()
- .getAdapter(IProject.class));
- componentClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
-
- ComponentClassType componentClass = FacesConfigFactory.eINSTANCE
- .createComponentClassType();
- componentClass
- .setTextContent(((StringDialogField) field)
- .getText());
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getComponentType_ComponentClass(),
- componentClass);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
-
- }
- });
- componentClassField
- .setSuperClassName(IFacesConfigConstants.COMPONENT_SUPER_CLASS);
- }
-
- /**
- *
- */
- public void refreshAll() {
- refresh();
- }
-
- /**
- * Refresh the content on this section.
- */
- public void refresh() {
- super.refresh();
- Object input = this.getInput();
- if (input instanceof ComponentType) {
- final ComponentType component = (ComponentType) input;
- refreshControls(component);
- }
- }
-
- private void refreshControls(ComponentType component) {
- if (component.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) component
- .getDisplayName().get(0);
- displayNameField.setTextWithoutUpdate(displayName
- .getTextContent());
- } else {
- displayNameField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (component.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) component
- .getDescription().get(0);
- String descriptionString = description.getTextContent();
- descriptionString = ModelUtil.unEscapeEntities(descriptionString);
- descriptionField.setTextWithoutUpdate(descriptionString);
- } else {
- descriptionField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (component.getComponentType() != null) {
- componentTypeField.setTextWithoutUpdate(component
- .getComponentType().getTextContent());
- } else {
- componentTypeField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (component.getComponentClass() != null) {
- componentClassField.setTextWithoutUpdate(component
- .getComponentClass().getTextContent());
- } else {
- componentClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
- }
-
- /**
- * Add ComponentGeneralAdapter onto <component> and the first <display-name>
- * and <description> elements.
- */
- protected void addAdaptersOntoInput(Object newInput) {
- ComponentType component = (ComponentType) newInput;
- if (EcoreUtil.getExistingAdapter(component,
- ComponentGeneralSection.class) == null) {
-
- component.eAdapters().add(getComponentGeneralAdapter());
- }
-
- if (component.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) component
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ComponentGeneralSection.class) == null) {
-
- displayName.eAdapters().add(getComponentGeneralAdapter());
- }
- }
-
- if (component.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) component
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ComponentGeneralSection.class) == null) {
-
- description.eAdapters().add(getComponentGeneralAdapter());
- }
- }
- }
-
- /**
- * Remove ComponentGeneralAdapter from <component> and the first
- * <display-name> and <description> elements.
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- ComponentType component = (ComponentType) oldInput;
- if (EcoreUtil.getExistingAdapter(component,
- ComponentGeneralSection.class) != null) {
- component.eAdapters().remove(getComponentGeneralAdapter());
- }
- if (component.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) component
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ComponentGeneralSection.class) != null) {
-
- displayName.eAdapters().remove(getComponentGeneralAdapter());
- }
- }
-
- if (component.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) component
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ComponentGeneralSection.class) != null) {
-
- description.eAdapters().remove(getComponentGeneralAdapter());
- }
- }
- }
-
- /**
- *
- * @return
- */
- private Adapter getComponentGeneralAdapter() {
-
- if (componentGeneralAdapter == null) {
- componentGeneralAdapter = new ComponentGeneralAdapter();
- }
- return componentGeneralAdapter;
- }
-
- /**
- * The adapter that will be added onto <component> element, to listen the
- * events of the children that are displayed in this section, notify the
- * section to refresh.
- *
- * @author sfshi
- *
- */
- class ComponentGeneralAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == ComponentGeneralSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getComponentType_ComponentClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getComponentType_ComponentType()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getComponentType_DisplayName()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getComponentType_Description()) {
- refresh();
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent()) {
- refresh();
- }
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentMasterSection.java
deleted file mode 100644
index ca2c0ac91..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ComponentMasterSection.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ComponentMasterSection extends FacesConfigMasterSection {
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- */
- public ComponentMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- super(parent, managedForm, toolkit, page, null, null);
- getSection().setText(EditorMessages.ComponentMasterSection_Name);
- getSection().setDescription(
- EditorMessages.ComponentMasterSection_Description);
- }
-
- /**
- * Config the table viwer, set a filter for it, only the object of
- * ComponentType will be selected.
- */
- protected void configViewer(StructuredViewer structuredViewer) {
- super.configViewer(structuredViewer);
- structuredViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getComponentType()
- .isInstance(element);
- }
- });
-
- }
-
- /**
- * Create a new component.
- */
- protected void addButtonSelected(SelectionEvent e) {
- ComponentType component = FacesConfigFactory.eINSTANCE
- .createComponentType();
-
- Command command = AddCommand.create(getEditingDomain(),
- this.getInput(), FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Component(), component);
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- IStructuredSelection selection = new StructuredSelection(component);
- getStructuredViewer().refresh();
- getStructuredViewer().setSelection(selection);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterGeneralSection.java
deleted file mode 100644
index 0e740503a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterGeneralSection.java
+++ /dev/null
@@ -1,490 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.ConverterClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ConverterForClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ConverterIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.ConverterType;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ConverterGeneralSection extends AbstractFacesConfigSection {
-
- private StringDialogField displayNameField;
-
- private StringDialogField descriptionField;
-
- private StringDialogField converterIdField;
-
- private ClassButtonDialogField converterForClassField;
-
- private ClassButtonDialogField converterClassField;
-
- private ConverterGeneralAdapter converterGeneralAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public ConverterGeneralSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection()
- .setText(EditorMessages.ConverterGeneralSection_Name);
- getSection().setDescription(
- EditorMessages.ConverterGeneralSection_Description);
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- container.setLayout(layout);
- GridData td = new GridData(GridData.FILL_HORIZONTAL);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
- displayNameField = new StringDialogField();
- displayNameField
- .setLabelText(EditorMessages.ConverterGeneralSection_Label_DisplayName);
- displayNameField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- displayNameField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- String newDisplayNameValue = ((StringDialogField) field)
- .getText().trim();
- Command cmd = null;
- ConverterType Converter = (ConverterType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (Converter.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) Converter
- .getDisplayName().get(0);
- cmd = SetCommand.create(editingDomain, displayName,
- FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent(),
- newDisplayNameValue);
- } else {
- DisplayNameType displayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayNameType.setTextContent(newDisplayNameValue);
-
- displayNameType.eAdapters().add(
- getConverterGeneralAdapter());
- cmd = AddCommand.create(editingDomain, Converter,
- FacesConfigPackage.eINSTANCE
- .getConverterType_DisplayName(),
- displayNameType);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- });
-
- descriptionField = new StringDialogField(2);
- descriptionField
- .setLabelText(EditorMessages.ConverterGeneralSection_Label_Description);
- descriptionField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- descriptionField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String newDescriptionValue = ((StringDialogField) field)
- .getText().trim();
-
- newDescriptionValue = ModelUtil
- .escapeEntities(newDescriptionValue);
- Command cmd = null;
- ConverterType Converter = (ConverterType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (Converter.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) Converter
- .getDescription().get(0);
- cmd = SetCommand.create(editingDomain, description,
- FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent(),
- newDescriptionValue);
- } else {
- DescriptionType description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(newDescriptionValue);
-
- description.eAdapters().add(
- getConverterGeneralAdapter());
- cmd = AddCommand.create(editingDomain, Converter,
- FacesConfigPackage.eINSTANCE
- .getConverterType_Description(),
- description);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
- });
-
- converterIdField = new StringDialogField();
- // converterIdField.setRequired(true);
- converterIdField
- .setLabelText(EditorMessages.ConverterGeneralSection_Label_ConverterID);
- converterIdField.doFillIntoGrid(toolkit, container, numberOfColumns);
- converterIdField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- ConverterIdType converterIdType = FacesConfigFactory.eINSTANCE
- .createConverterIdType();
-
- converterIdType
- .setTextContent(((StringDialogField) field)
- .getText());
-
- EditingDomain editingDomain = getEditingDomain();
- List commands = new ArrayList(2);
- Command cmd1 = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterForClass(),
- SetCommand.UNSET_VALUE);
- commands.add(cmd1);
- Command cmd2 = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterId(),
- converterIdType);
- commands.add(cmd2);
- Command command = new CompoundCommand(commands);
- if (editingDomain != null) {
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- refresh();
- }
- }
- }
- });
-
- converterForClassField = new ClassButtonDialogField(null);
- // converterForClassField.setRequired(true);
- converterForClassField
- .setLabelText(EditorMessages.ConverterGeneralSection_Label_ConverterForClass);
- converterForClassField.setProject((IProject) getPage().getEditor()
- .getAdapter(IProject.class));
- converterForClassField.doFillIntoGrid(toolkit, container,
- numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(converterForClassField.getTextControl(
- toolkit, container));
-
- converterForClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
-
- ConverterForClassType converterForClass = FacesConfigFactory.eINSTANCE
- .createConverterForClassType();
- converterForClass
- .setTextContent(((StringDialogField) field)
- .getText());
- EditingDomain editingDomain = getEditingDomain();
- List commands = new ArrayList(2);
- Command cmd1 = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterId(),
- SetCommand.UNSET_VALUE);
- commands.add(cmd1);
- Command cmd2 = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterForClass(),
- converterForClass);
- commands.add(cmd2);
- Command command = new CompoundCommand(commands);
- if (editingDomain != null) {
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- refresh();
- }
- }
-
- }
- });
-
- converterClassField = new ClassButtonDialogField(null);
- // converterClassField.setRequired(true);
- converterClassField
- .setLabelText(EditorMessages.ConverterGeneralSection_Label_ConverterClass);
- converterClassField.setProject((IProject) getPage().getEditor()
- .getAdapter(IProject.class));
- converterClassField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(converterClassField.getTextControl(
- toolkit, container));
-
- converterClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
-
- ConverterClassType ConverterClass = FacesConfigFactory.eINSTANCE
- .createConverterClassType();
- ConverterClass
- .setTextContent(((StringDialogField) field)
- .getText());
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterClass(),
- ConverterClass);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
-
- }
- });
- converterClassField
- .setInterface(IFacesConfigConstants.CONVERTER_INTERFACE);
- }
-
- /**
- *
- */
- public void refreshAll() {
- refresh();
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- Object input = this.getInput();
- if (input instanceof ConverterType) {
- final ConverterType converter = (ConverterType) input;
- refreshControls(converter);
- }
- }
-
- private void refreshControls(ConverterType converter) {
- if (converter.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) converter
- .getDisplayName().get(0);
- displayNameField.setTextWithoutUpdate(displayName
- .getTextContent());
- } else {
- displayNameField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (converter.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) converter
- .getDescription().get(0);
- String descriptionString = description.getTextContent();
- descriptionString = ModelUtil
- .unEscapeEntities(descriptionString);
- descriptionField.setTextWithoutUpdate(descriptionString);
- } else {
- descriptionField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (converter.getConverterId() != null) {
- converterIdField.setTextWithoutUpdate(converter
- .getConverterId().getTextContent());
- } else {
- converterIdField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (converter.getConverterForClass() != null) {
- converterForClassField.setTextWithoutUpdate(converter
- .getConverterForClass().getTextContent());
- } else {
- converterForClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (converter.getConverterClass() != null) {
- converterClassField.setTextWithoutUpdate(converter
- .getConverterClass().getTextContent());
- } else {
- converterClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
- }
- /**
- * Add ConverterGeneralAdapter onto <converter> and the first <display-name>
- * and <description> elements.
- */
- protected void addAdaptersOntoInput(Object newInput) {
- ConverterType converter = (ConverterType) newInput;
- if (EcoreUtil.getExistingAdapter(converter,
- ConverterGeneralSection.class) == null) {
-
- converter.eAdapters().add(getConverterGeneralAdapter());
- }
-
- if (converter.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) converter
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ConverterGeneralSection.class) == null) {
-
- displayName.eAdapters().add(getConverterGeneralAdapter());
- }
- }
-
- if (converter.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) converter
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ConverterGeneralSection.class) == null) {
-
- description.eAdapters().add(getConverterGeneralAdapter());
- }
- }
- }
-
- /**
- * Remove ConverterGeneralAdapter from <converter> and the first
- * <display-name> and <description> elements.
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- ConverterType converter = (ConverterType) oldInput;
- if (EcoreUtil.getExistingAdapter(converter,
- ConverterGeneralSection.class) != null) {
- converter.eAdapters().remove(getConverterGeneralAdapter());
- }
- if (converter.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) converter
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ConverterGeneralSection.class) != null) {
-
- displayName.eAdapters().remove(getConverterGeneralAdapter());
- }
- }
-
- if (converter.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) converter
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ConverterGeneralSection.class) != null) {
-
- description.eAdapters().remove(getConverterGeneralAdapter());
- }
- }
- }
-
- /**
- *
- * @return
- */
- private Adapter getConverterGeneralAdapter() {
-
- if (converterGeneralAdapter == null) {
- converterGeneralAdapter = new ConverterGeneralAdapter();
- }
- return converterGeneralAdapter;
- }
-
- /**
- * The adapter that will be added onto <converter> element, to listen the
- * events of the children that are displayed in this section, notify the
- * section to refresh.
- *
- * @author sfshi
- *
- */
- class ConverterGeneralAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == ConverterGeneralSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterId()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getConverterType_ConverterForClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getConverterType_Description()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getConverterType_DisplayName()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refresh();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refresh();
- }
- });
- }
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refresh();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refresh();
- }
- });
- }
- }
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterMasterSection.java
deleted file mode 100644
index 4a8492401..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ConverterMasterSection.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.ConverterType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ConverterMasterSection extends FacesConfigMasterSection {
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- */
- public ConverterMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- super(parent, managedForm, toolkit, page, null, null);
- getSection().setText(EditorMessages.ConverterMasterSection_Name);
- getSection().setDescription(
- EditorMessages.ConverterMasterSection_Description);
- }
-
- /**
- * Config the table viwer, set a filter for it, only the object of
- * ConverterType will be selected.
- */
- protected void configViewer(StructuredViewer structuredViewer) {
- super.configViewer(structuredViewer);
- structuredViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getConverterType()
- .isInstance(element);
- }
- });
-
- }
-
- /**
- * Create a new Converter.
- */
- protected void addButtonSelected(SelectionEvent e) {
- ConverterType Converter = FacesConfigFactory.eINSTANCE
- .createConverterType();
-
- Command command = AddCommand.create(getEditingDomain(),
- this.getInput(), FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Converter(), Converter);
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- IStructuredSelection selection = new StructuredSelection(Converter);
- getStructuredViewer().refresh();
- getStructuredViewer().setSelection(selection);
- }
- }
-
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacesConfigMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacesConfigMasterSection.java
deleted file mode 100644
index 91b11c749..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacesConfigMasterSection.java
+++ /dev/null
@@ -1,325 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.swt.SWT;
-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.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * An default implementation of AbstractFacesConfigSection for Master Section.
- *
- * @author sfshi
- *
- */
-public abstract class FacesConfigMasterSection extends AbstractFacesConfigSection {
-
- private StructuredViewer structuredViewer;
-
- private Button removeButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- * @param helpContextId
- * @param helpTooltip
- */
- public FacesConfigMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page,
- String helpContextId, String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- }
-
- public void dispose() {
- structuredViewer.removeSelectionChangedListener(this);
- super.dispose();
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- structuredViewer = createViewer(container, toolkit);
- structuredViewer.addSelectionChangedListener(this);
- createOperationSection(container, toolkit);
- }
-
- /**
- * Create the structured viewer, set up content & label provider for it.
- * Defaultly create a tableviewer.
- *
- * @param parent
- * @param toolkit
- * @return the structured viewer
- */
- protected StructuredViewer createViewer(Composite parent,
- FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(parent);
- toolkit.paintBordersFor(tableContainer);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.heightHint = 200;
- tableContainer.setLayoutData(gd);
- GridLayout layout = new GridLayout();
- tableContainer.setLayout(layout);
-
- TableViewer tableViewer = new TableViewer(tableContainer, SWT.SINGLE
- | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- tableViewer.getControl().setLayoutData(gd);
-
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- configViewer(tableViewer);
-
- return tableViewer;
- }
-
- /**
- * Config the viewer, such as set a filter and so on. Sub classes should
- * override this method to add filter.
- *
- * @param viewer
- */
- protected void configViewer(StructuredViewer viewer) {
- // do nothing; subs may override
- }
-
- /**
- * Defaultly we create a "New" button and a "Remove" button. Sub classes can
- * overwrite this method if need other functions.
- *
- * @param parent
- * @param toolkit
- */
- protected void createOperationSection(Composite parent, FormToolkit toolkit) {
- Composite operationContainer = toolkit.createComposite(parent);
- GridData gd = new GridData(GridData.FILL_VERTICAL);
- operationContainer.setLayoutData(gd);
- GridLayout layout = new GridLayout();
-
- operationContainer.setLayout(layout);
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add, SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected(e);
- }
- });
-
- setRemoveButton(toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove, SWT.PUSH));
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- getRemoveButton().setLayoutData(gd);
- getRemoveButton().addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected(e);
- }
- });
- }
-
- /**
- *
- * @param e
- */
- protected abstract void addButtonSelected(SelectionEvent e);
-
- /**
- *
- * @param e
- */
- protected void removeButtonSelected(SelectionEvent e) {
-
- IStructuredSelection ssel = StructuredSelection.EMPTY;
- ISelection selection = getSelection();
- if (selection instanceof IStructuredSelection) {
- ssel = (IStructuredSelection) selection;
- }
-
- if (!ssel.isEmpty()) {
- List commands = new ArrayList(ssel.size());
- for (Iterator iter = ssel.iterator(); iter.hasNext();) {
- EObject element = (EObject) iter.next();
- Command command = RemoveCommand.create(getEditingDomain(),
- element);
- commands.add(command);
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- }
- }
-
- }
-
- /**
- *
- * update the buttons' enable state.
- */
- protected void updateButtons() {
- IStructuredSelection ssel = (IStructuredSelection) structuredViewer
- .getSelection();
-
- getRemoveButton().setEnabled(!ssel.isEmpty());
- }
-
- /**
- *
- */
- public ISelection getSelection() {
- return structuredViewer.getSelection();
- }
-
- /**
- *
- */
- public void setSelection(ISelection selection) {
- structuredViewer.setSelection(selection);
- }
-
- /**
- * refresh the display of this section.
- */
- public void refresh() {
- super.refresh();
- structuredViewer.refresh();
- updateButtons();
- }
-
- /**
- *
- */
- public void refreshAll() {
- // master section refresh all:
- setViewerInput(getInput());
- updateButtons();
-
- // detial sections refresh:
- // fire an event to the detail sections, let them
- // refresh.
- selectionChanged(null);
- }
-
- /**
- * set the structuredViewer's input
- *
- * @param input
- */
- private void setViewerInput(Object input) {
- structuredViewer.setInput(input);
- }
-
- /**
- *
- */
- protected void expansionStateChanged(boolean expanded) {
- if (expanded) {
- if (structuredViewer.getInput() == null) {
- refreshAll();
- }
- structuredViewer.refresh(true);
- structuredViewer.setSelection(structuredViewer.getSelection());
- } else {
- structuredViewer.setSelection(null);
- }
- super.expansionStateChanged(expanded);
- }
-
- /**
- *
- */
- protected void expansionStateChanging(boolean expanding) {
- if (!expanding) {
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- this.getSection().setLayoutData(gd);
- } else {
- ((FacesConfigMasterDetailPage) getPage()).closeOtherSections(this);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- this.getSection().setLayoutData(gd);
- }
-
- super.expansionStateChanging(expanding);
- }
-
- /**
- * get the viewer.
- *
- * @return the viewer
- */
- public StructuredViewer getStructuredViewer() {
- return structuredViewer;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- super.selectionChanged(event);
- updateButtons();
- }
-
- private void setRemoveButton(Button removeButton) {
- this.removeButton = removeButton;
- }
-
- /**
- * @return the remove button
- */
- protected Button getRemoveButton() {
- return removeButton;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacetSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacetSection.java
deleted file mode 100644
index 8ec7fb058..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FacetSection.java
+++ /dev/null
@@ -1,455 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacetNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacetType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditFacetDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Section for facets
- *
- */
-public class FacetSection extends AbstractFacesConfigSection {
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public FacetSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- this.getSection().setText(EditorMessages.FacetSection_Name);
- this.getSection().setDescription(
- EditorMessages.FacetSection_Description);
-
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- gl.numColumns = 2;
- container.setLayout(gl);
- GridData td = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
-
- Composite facetSection = toolkit.createComposite(container);
- GridLayout gl2 = new GridLayout();
- gl2.horizontalSpacing = 0;
- gl2.marginWidth = 0;
- gl2.numColumns = 2;
- facetSection.setLayout(gl2);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.VERTICAL_ALIGN_BEGINNING);
- facetSection.setLayoutData(gd);
-
- createTableSection(facetSection, toolkit);
- createButtonsSection(facetSection, toolkit);
-
- }
-
- /**
- * create facet table section
- *
- * @param container
- * @param toolkit
- */
- private void createTableSection(Composite container, FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.GRAB_HORIZONTAL);
- tableContainer.setLayoutData(gd);
- toolkit.paintBordersFor(tableContainer);
-
- GridLayout gl = new GridLayout();
- tableContainer.setLayout(gl);
-
- Table table = new Table(tableContainer, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
-
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
-
- TableColumn facetNameCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- facetNameCol
- .setText(EditorMessages.FacetSection_Table_FacetNameColumn);
- TableColumn displayNameCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- displayNameCol
- .setText(EditorMessages.FacetSection_Table_DisplayNameColumn);
-
- TableColumn descriptionCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- descriptionCol
- .setText(EditorMessages.FacetSection_Table_DescriptionColumn);
-
- table.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
- });
-
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
-
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getFacetType().isInstance(
- element);
- }
- });
-
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- * create buttons
- *
- * @param container
- * @param toolkit
- */
- private void createButtonsSection(Composite container, FormToolkit toolkit) {
- // create operation buttons's container
- Composite operationContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_VERTICAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- operationContainer.setLayoutData(gd);
- GridLayout gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
- });
- }
-
- /**
- * refresh the table viewer and update buttons.
- */
- public void refresh() {
- super.refresh();
- tableViewer.refresh();
- updateButtons();
- }
-
- public void refreshAll() {
- tableViewer.setInput(getInput());
- updateButtons();
- }
-
- /**
- * Update the buttons' enable status.
- */
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- * add a facet.
- *
- */
- private void addButtonSelected() {
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditFacetDialog dialog = new AddEditFacetDialog(shell, true);
- if (dialog.open() == Dialog.OK) {
-
- String newFacetName = dialog.getFacetName();
- String newDisplayName = dialog.getDisplayName();
- String newDescription = dialog.getDescription();
-
- FacetType newFacet = FacesConfigFactory.eINSTANCE.createFacetType();
- if (newFacetName.length() > 0) {
- FacetNameType facetNameType = FacesConfigFactory.eINSTANCE
- .createFacetNameType();
- facetNameType.setTextContent(newFacetName);
- newFacet.setFacetName(facetNameType);
- }
-
- if (newDisplayName.length() > 0) {
- DisplayNameType displayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayNameType.setTextContent(newDisplayName);
- newFacet.getDisplayName().add(displayNameType);
- }
-
- if (newDescription.length() > 0) {
- DescriptionType descriptionType = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- descriptionType.setTextContent(newDescription);
- newFacet.getDescription().add(descriptionType);
- }
-
- Command addCommand = AddCommand.create(this.getEditingDomain(),
- getInput(), FacesConfigPackage.eINSTANCE
- .getComponentType_Facet(), newFacet);
- if (addCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(addCommand);
-
- }
- }
-
- }
-
- /**
- * edit a facet.
- *
- */
- private void editButtonSelected() {
- FacetType facet = (FacetType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(facet);
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditFacetDialog dialog = new AddEditFacetDialog(shell, false);
- if (facet.getFacetName() != null)
- dialog.setFacetName(facet.getFacetName().getTextContent());
-
- if (facet.getDisplayName().size() > 0) {
- dialog.setDisplayName(((DisplayNameType) facet.getDisplayName()
- .get(0)).getTextContent());
- }
-
- if (facet.getDescription().size() > 0) {
- dialog.setDescription(((DescriptionType) facet.getDescription()
- .get(0)).getTextContent());
- }
-
- if (dialog.open() == Dialog.OK) {
- List commands = new ArrayList(3);
-
- String newFacetName = dialog.getFacetName();
- String newDisplayName = dialog.getDisplayName();
- String newDescription = dialog.getDescription();
- if (facet.getFacetName() != null) {
- Command cmd1 = SetCommand.create(getEditingDomain(), facet
- .getFacetName(), FacesConfigPackage.eINSTANCE
- .getFacetNameType_TextContent(), newFacetName);
- commands.add(cmd1);
- } else if (newFacetName.length() > 0) {
- FacetNameType newFacetNameType = FacesConfigFactory.eINSTANCE
- .createFacetNameType();
- newFacetNameType.setTextContent(newFacetName);
- Command cmd2 = AddCommand.create(getEditingDomain(), facet,
- FacesConfigPackage.eINSTANCE.getFacetType_FacetName(),
- newFacetNameType);
- commands.add(cmd2);
- }
-
- if (facet.getDisplayName().size() > 0) {
- DisplayNameType displayNameType = (DisplayNameType) facet
- .getDisplayName().get(0);
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- displayNameType, FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent(),
- newDisplayName);
- commands.add(cmd3);
- } else if (newDisplayName.length() > 0) {
- DisplayNameType newDisplayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- newDisplayNameType.setTextContent(newDisplayName);
- Command cmd4 = AddCommand
- .create(this.getEditingDomain(), facet,
- FacesConfigPackage.eINSTANCE
- .getFacetType_DisplayName(),
- newDisplayNameType);
- commands.add(cmd4);
- }
-
- if (facet.getDescription().size() > 0) {
- DescriptionType descriptionType = (DescriptionType) facet
- .getDescription().get(0);
- Command cmd5 = SetCommand.create(this.getEditingDomain(),
- descriptionType, FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent(),
- newDescription);
- commands.add(cmd5);
- } else if (newDescription.length() > 0) {
- DescriptionType newDescriptionType = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- newDescriptionType.setTextContent(newDescription);
- Command cmd6 = AddCommand
- .create(this.getEditingDomain(), facet,
- FacesConfigPackage.eINSTANCE
- .getFacetType_Description(),
- newDescriptionType);
- commands.add(cmd6);
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- tableViewer.refresh(facet);
- }
- }
-
- }
-
- /**
- * remove a facet.
- *
- */
- private void removeButtonSelected() {
- FacetType facet = (FacetType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(facet);
- Command removeCommand = RemoveCommand.create(this.getEditingDomain(),
- getInput(), FacesConfigPackage.eINSTANCE
- .getComponentType_Facet(), facet);
-
- if (removeCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(removeCommand);
- refreshAll();
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return tableViewer.getSelection();
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
-
- tableViewer.setSelection(selection);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FactorySection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FactorySection.java
deleted file mode 100644
index 2ffe62a07..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/FactorySection.java
+++ /dev/null
@@ -1,169 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jdt.ui.IJavaElementSearchConstants;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FactoryType;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.DialogUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Zhi-peng Zhang, sfshi
- * @version
- */
-public class FactorySection extends OthersPageBaseSection {
- /** The Eclass object this Section operated */
- private EClass factoryChildClass;
-
- /**
- *
- * @param factoryChildClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public FactorySection(EClass factoryChildClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- this.factoryChildClass = factoryChildClass;
- }
-
- /**
- *
- * @param factoryChildClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public FactorySection(EClass factoryChildClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- this(factoryChildClass, parent, managedForm, page, toolkit, null, null);
- }
-
- /**
- * @return an new object which is instance of <code>factoryChildClass</code>.
- */
- public EObject createFactoryChildObject() {
- String superType = ModelUtil.getSuperType(factoryChildClass);
- IProject project = (IProject) this.getPage().getEditor().getAdapter(
- IProject.class);
- String result = DialogUtil.openClassDialog(getSection().getShell(),
- project, superType,
- IJavaElementSearchConstants.CONSIDER_ALL_TYPES);
-
- if (result != null) {
- EObject component = FacesConfigFactory.eINSTANCE
- .create(factoryChildClass);
- // set the text content value.
- EStructuralFeature feature = factoryChildClass
- .getEStructuralFeatures().get(0);
- component.eSet(feature, result);
- return component;
- }
- return null;
- }
-
- /**
- * Set the <factory> element as the structuredViewer's input.
- *
- * @param input
- */
- protected void setViewerInput(Object input) {
- if (input instanceof FactoryType) {
- tableViewer.setInput(input);
- } else
- tableViewer.setInput(null);
- }
-
- /**
- * Add a filter on the table viewer. Only the elements that is a instance of
- * <code>factoryChildClass</code> could be selected.
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return factoryChildClass.isInstance(element);
- }
- });
- }
-
- /**
- * Perform some actions to create new child object and append it to the
- * <factory> element.
- */
- void addButtonSelected(SelectionEvent e) {
- /** Create a new object which is instance of factoryChildClass. */
- EObject obj = createFactoryChildObject();
- if (obj != null) {
- boolean needRefreshAll = false;
- Command command = null;
- if (getInput() instanceof FactoryType) {
- /**
- * The input is a <factory> element and not null, append the new
- * object to it.
- */
- FactoryType factory = (FactoryType) getInput();
- command = AddCommand.create(getEditingDomain(), factory, null,
- obj);
- } else {
- /**
- * The input is null, create a <factory> element and append it
- * to <faces-config>.
- */
- needRefreshAll = true;
- List list = new ArrayList(2);
- FactoryType factory = FacesConfigFactory.eINSTANCE
- .createFactoryType();
- Command cmd1 = AddCommand.create(getEditingDomain(), factory,
- null, obj);
- list.add(cmd1);
- Command cmd2 = AddCommand.create(getEditingDomain(), this
- .getPage().getInput(), null, factory);
- list.add(cmd2);
- command = new CompoundCommand(list);
- }
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- if (needRefreshAll)
- ((OthersPage) this.getPage()).resetFactoryInput();
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IDialogFieldGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IDialogFieldGroup.java
deleted file mode 100644
index 5c5b7c544..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IDialogFieldGroup.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-/**
- * This interface is used to build relation between model SSEModel and
- * controller DialogFieldGroup
- *
- * @author Xiao-guang Zhang
- * @version
- */
-public interface IDialogFieldGroup {
- /**
- * set the input of this section
- *
- * @param newInput
- */
- void setInput(Object newInput);
-
- /**
- * @return the input of this section
- */
- Object getInput();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IFacesConfigSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IFacesConfigSection.java
deleted file mode 100644
index 4fb65dcd2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/IFacesConfigSection.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-
-/**
- * Section interface to build relation between model and adapter
- *
- * @author sfshi
- *
- */
-public interface IFacesConfigSection {
- /**
- * set the input of this section
- *
- * @param newInput
- */
- void setInput(Object newInput);
-
- /**
- * @return the input of this section
- */
- Object getInput();
-
- /**
- * initialize current section based on the input
- *
- */
- void initialize();
-
- /**
- * clear all section's contents.
- *
- */
- void clearAll();
-
- /**
- * refresh the needed parts of the section
- *
- */
- void refresh();
-
- /**
- * refresh all parts of the section
- *
- */
- void refreshAll();
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/InitializationSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/InitializationSection.java
deleted file mode 100644
index 2029efa19..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/InitializationSection.java
+++ /dev/null
@@ -1,363 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.RadiosDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-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.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.part.PageBook;
-
-/**
- * This section handles managed bean's initialization, including general class
- * type, map and list type managed bean.
- *
- * @author Xiao-guang Zhang, sfshi
- */
-public class InitializationSection extends AbstractFacesConfigSection {
- private static final String MANAGEDBEAN_GENERAL_CLASS = EditorMessages.InitializationSection_ClassType_General;
-
- private static final String MANAGEDBEAN_MAP = EditorMessages.InitializationSection_ClassType_Map;
-
- private static final String MANAGEDBEAN_LIST = EditorMessages.InitializationSection_ClassType_List;
-
- /** property initiliazation container composite */
- private Composite propertySection;
-
- /** property initiliazation DialogFieldGroup */
- private ManagedPropertyEditGroup managedPropertyGroup;
-
- /** map entries initiliazation container composite */
- private Composite mapSection;
-
- /** map entries initiliazation DialogFieldGroup */
- private MapEntriesEditGroup mapEntryGroup;
-
- /** list entries initiliazation container composite */
- private Composite listSection;
-
- /** list entries initiliazation DialogFieldGroup */
- private ListEntriesEditGroup listEntryGroup;
-
- /** the PageBook control for three kinds of managed bean */
- private PageBook pageBook;
-
- /** RadiosDialogField for three kinds of managed bean */
- private RadiosDialogField beanTypeField;
-
- /** current pages selection */
- private int currentPageIndex = 0;
-
- /**
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public InitializationSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection().setText(EditorMessages.InitializationSection_Name);
- getSection().setDescription(
- EditorMessages.InitializationSection_Description);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.managedbean.sections.BaseSectionPart#createClient(org.eclipse.swt.widgets.Composite,
- * org.eclipse.ui.forms.widgets.FormToolkit)
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- container.setLayout(gl);
- toolkit.paintBordersFor(container);
-
- createBeanTypeEntry(container, toolkit, numberOfColumns);
- createInitializationEntry(container, toolkit, numberOfColumns);
- }
-
- /**
- * create the bean type selection section
- *
- * @param container
- * @param toolkit
- */
- private void createBeanTypeEntry(Composite container, FormToolkit toolkit,
- int numberOfColumns) {
- beanTypeField = new RadiosDialogField();
- String[] items = { MANAGEDBEAN_GENERAL_CLASS, MANAGEDBEAN_MAP,
- MANAGEDBEAN_LIST };
- beanTypeField
- .setLabelText(EditorMessages.InitializationSection_ClassType);
- beanTypeField.setItems(items);
- beanTypeField.doFillIntoGrid(toolkit, container, numberOfColumns);
- beanTypeField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- RadiosDialogField beanTypeField1 = (RadiosDialogField) field;
-
- boolean bChangedSuccess = false;
- if (beanTypeField1.getSelectedIndex() == 0) {
- bChangedSuccess = switchPage(
- IFacesConfigConstants.MANAGED_PROPERTY,
- false);
- } else if (beanTypeField1.getSelectedIndex() == 1) {
- bChangedSuccess = switchPage(
- IFacesConfigConstants.MAP_ENTRIES, false);
- } else if (beanTypeField1.getSelectedIndex() == 2) {
- bChangedSuccess = switchPage(
- IFacesConfigConstants.LIST_ENTRIES, false);
- }
-
- if (bChangedSuccess) {
- currentPageIndex = beanTypeField1.getSelectedIndex();
- } else {
- beanTypeField1.setSelectedIndexWithoutUpdate(-1);
- beanTypeField1
- .setSelectedIndexWithoutUpdate(currentPageIndex);
- }
- }
- });
- }
-
- /**
- * switch to general property, map-entries, or list-entries group If
- * bForceClear equals to true, the others page will be cleared without user
- * confirmation. if bForceClear equals to false, the confirmation dialog
- * will pop up and let user determine whether this page is cleared or not.
- *
- * @param pageID -
- * IFacesConfigConstants.MANAGED_PROPERTY,
- * MAP_ENTRIES,LIST_ENTRIES
- * @param bForceClearOthers -
- * Force to clear other pages.
- */
- private boolean switchPage(String pageID, boolean bForceClearOthers) {
- if (pageID == IFacesConfigConstants.MANAGED_PROPERTY) {
- if (clearPage(IFacesConfigConstants.MAP_ENTRIES, bForceClearOthers)
- && clearPage(IFacesConfigConstants.LIST_ENTRIES,
- bForceClearOthers)) {
- managedPropertyGroup.refreshAll();
- pageBook.showPage(propertySection);
- // FIXME: there should be some other methods to resize the whole
- // section.
- InitializationSection.this.getSection().setExpanded(false);
- InitializationSection.this.getSection().setExpanded(true);
- return true;
- }
- } else if (pageID == IFacesConfigConstants.MAP_ENTRIES) {
- if (clearPage(IFacesConfigConstants.MANAGED_PROPERTY,
- bForceClearOthers)
- && clearPage(IFacesConfigConstants.LIST_ENTRIES,
- bForceClearOthers)) {
- mapEntryGroup.refreshAll();
- pageBook.showPage(mapSection);
- // FIXME: there should be some other methods to resize the whole
- // section.
- InitializationSection.this.getSection().setExpanded(false);
- InitializationSection.this.getSection().setExpanded(true);
- return true;
- }
- } else if (pageID == IFacesConfigConstants.LIST_ENTRIES) {
- if (clearPage(IFacesConfigConstants.MANAGED_PROPERTY,
- bForceClearOthers)
- && clearPage(IFacesConfigConstants.MAP_ENTRIES,
- bForceClearOthers)) {
- listEntryGroup.refreshAll();
- pageBook.showPage(listSection);
- // FIXME: there should be some other methods to resize the whole
- // section.
- InitializationSection.this.getSection().setExpanded(false);
- InitializationSection.this.getSection().setExpanded(true);
- return true;
- }
- }
- return false;
- }
-
- /**
- * clear one specified page according to pageID if bForceClear equals to
- * false, the confirmation dialog will pop up and let user determine whether
- * this page is cleared or not.
- *
- * @param pageID -
- * IFacesConfigConstants.MANAGED_PROPERTY,
- * MAP_ENTRIES,LIST_ENTRIES
- * @param bForceClear -
- * force to clear current page.
- * @return
- */
- private boolean clearPage(String pageID, boolean bForceClear) {
- ManagedBeanType managedBean = (ManagedBeanType) getInput();
-
- if (pageID == IFacesConfigConstants.MANAGED_PROPERTY) {
- if (managedBean.getManagedProperty().size() == 0) {
- return true;
- }
-
- if (bForceClear
- || EditorPlugin
- .getAlerts()
- .confirm(
- "ManagedBeanInitializationSection.Remove.Title", //$NON-NLS-1$
- "ManagedBeanInitializationSection.RemoveManagedProperty")) { //$NON-NLS-1$
- Command cmd = SetCommand.create(this.getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedProperty(),
- SetCommand.UNSET_VALUE);
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- return true;
- }
-
- return false;
- }
- } else if (pageID == IFacesConfigConstants.MAP_ENTRIES) {
- if (managedBean.getMapEntries() == null) {
- return true;
- }
-
- if (bForceClear
- || EditorPlugin
- .getAlerts()
- .confirm(
- "ManagedBeanInitializationSection.Remove.Title", //$NON-NLS-1$
- "ManagedBeanInitializationSection.RemoveMapEntries")) { //$NON-NLS-1$
- Command cmd = SetCommand.create(this.getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_MapEntries(),
- SetCommand.UNSET_VALUE);
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- return true;
- }
- }
- } else if (pageID == IFacesConfigConstants.LIST_ENTRIES) {
- if (managedBean.getListEntries() == null) {
- return true;
- }
-
- if (bForceClear
- || EditorPlugin
- .getAlerts()
- .confirm(
- "ManagedBeanInitializationSection.Remove.Title", //$NON-NLS-1$
- "ManagedBeanInitializationSection.RemoveListEntries")) { //$NON-NLS-1$
- Command cmd = SetCommand.create(this.getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ListEntries(),
- SetCommand.UNSET_VALUE);
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- return true;
- }
- }
- }
-
- return false;
- }
-
- /**
- * create property initialization section
- *
- * @param container
- * @param toolkit
- */
- private void createInitializationEntry(Composite container,
- FormToolkit toolkit, int numberOfColumns) {
- pageBook = new PageBook(container, SWT.NONE);
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = numberOfColumns;
- pageBook.setLayoutData(gd);
- toolkit.paintBordersFor(pageBook);
-
- managedPropertyGroup = new ManagedPropertyEditGroup(this);
- managedPropertyGroup.initialize();
- managedPropertyGroup.addSelectionChangedListener(this);
-
- mapEntryGroup = new MapEntriesEditGroup(this);
- mapEntryGroup.initialize();
- mapEntryGroup.addSelectionChangedListener(this);
-
- listEntryGroup = new ListEntriesEditGroup(this);
- listEntryGroup.initialize();
- listEntryGroup.addSelectionChangedListener(this);
-
- propertySection = toolkit.createComposite(pageBook);
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- propertySection.setLayout(gl);
- gd = new GridData(GridData.FILL_BOTH);
- propertySection.setLayoutData(gd);
- managedPropertyGroup.layoutDialogFields(toolkit, propertySection);
-
- mapSection = toolkit.createComposite(pageBook);
- mapEntryGroup.layoutDialogFields(toolkit, mapSection);
-
- listSection = toolkit.createComposite(pageBook);
- listEntryGroup.layoutDialogFields(toolkit, listSection);
-
- pageBook.showPage(propertySection);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.managedbean.sections.ISSESection#setInput(java.lang.Object)
- */
- public void setInput(Object newInput) {
- super.setInput(newInput);
- refreshAll();
- }
-
- public void refreshAll() {
- if (getInput() instanceof ManagedBeanType) {
- ManagedBeanType managedBean = (ManagedBeanType) getInput();
- managedPropertyGroup.setInput(managedBean);
- mapEntryGroup.setInput(managedBean);
- listEntryGroup.setInput(managedBean);
- if (managedBean.getManagedProperty().size() > 0) {
- beanTypeField.setSelectedIndexWithoutUpdate(-1);
- beanTypeField.setSelectedIndex(0);
- } else if (managedBean.getMapEntries() != null) {
- beanTypeField.setSelectedIndexWithoutUpdate(-1);
- beanTypeField.setSelectedIndex(1);
- } else if (managedBean.getListEntries() != null) {
- beanTypeField.setSelectedIndexWithoutUpdate(-1);
- beanTypeField.setSelectedIndex(2);
- } else {
- beanTypeField.setSelectedIndexWithoutUpdate(-1);
- beanTypeField.setSelectedIndex(0);
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LifecycleSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LifecycleSection.java
deleted file mode 100644
index 50e529cea..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LifecycleSection.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jdt.ui.IJavaElementSearchConstants;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.LifecycleType;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.DialogUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-public class LifecycleSection extends OthersPageBaseSection {
-
- /**
- * The Eclass object this Section operated. Since lifecycle only has one
- * type child: phase-listener, so this object should always equals
- * <code>FacesConfigPackage.eINSTANCE
- .getPhaseListenerType()</code>.
- */
- private EClass lifecycleChildClass;
-
- /**
- *
- * @param lifecycleChildClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public LifecycleSection(EClass lifecycleChildClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- this.lifecycleChildClass = lifecycleChildClass;
- }
-
- /**
- *
- * @param lifecycleChildClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public LifecycleSection(EClass lifecycleChildClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- this(lifecycleChildClass, parent, managedForm, page, toolkit, null,
- null);
- }
-
- /**
- * @return the lifecycle child
- */
- public EObject createLifecycleChildObject() {
- String superType = ModelUtil.getSuperType(lifecycleChildClass);
- IProject project = (IProject) this.getPage().getEditor().getAdapter(
- IProject.class);
- String result = DialogUtil.openClassDialog(getSection().getShell(),
- project, superType,
- IJavaElementSearchConstants.CONSIDER_ALL_TYPES);
-
- if (result != null) {
- EObject component = FacesConfigFactory.eINSTANCE
- .create(lifecycleChildClass);
- EStructuralFeature feature = lifecycleChildClass
- .getEStructuralFeatures().get(0);
- component.eSet(feature, result);
- return component;
- }
- return null;
- }
-
- /**
- * Set the <lifecycle> element as the structuredViewer's input.
- *
- * @param input
- */
- protected void setViewerInput(Object input) {
- if (input instanceof LifecycleType) {
- tableViewer.setInput(input);
- } else
- tableViewer.setInput(null);
- }
-
- /**
- * Add a filter on the table viewer. Only the elements that is a instance of
- * <code>lifecycleChildClass</code> could be selected.
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return lifecycleChildClass.isInstance(element);
- }
- });
- }
-
- /**
- * Perform some actions to create new child object and append it to the
- * <lifecycle> element.
- */
- void addButtonSelected(SelectionEvent e) {
- EObject obj = createLifecycleChildObject();
- if (obj != null) {
-
- boolean needRefreshAll = false;
- Command command = null;
- if (getInput() instanceof LifecycleType) {
- LifecycleType lifeCycle = (LifecycleType) getInput();
- command = AddCommand.create(getEditingDomain(), lifeCycle,
- null, obj);
- } else {
- needRefreshAll = true;
- LifecycleType lifeCycle = FacesConfigFactory.eINSTANCE
- .createLifecycleType();
- lifeCycle.getPhaseListener().add(obj);
- command = AddCommand.create(getEditingDomain(), this.getPage()
- .getInput(), null, lifeCycle);
- }
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- if (needRefreshAll)
- ((OthersPage) this.getPage()).resetLifecycleInput();
- }
- }
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ListEntriesEditGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ListEntriesEditGroup.java
deleted file mode 100644
index 3a1d0ef46..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ListEntriesEditGroup.java
+++ /dev/null
@@ -1,626 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldBase;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldGroup;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ListEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.emf.NullValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.EditValueDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-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.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * ListEntries editing DialogFieldGroup
- *
- * @author Xiao-guang Zhang, sfshi
- * @version
- */
-public class ListEntriesEditGroup extends DialogFieldGroup implements
- IDialogFieldGroup, ISelectionProvider, ISelectionChangedListener {
-
- private ClassButtonDialogField valueClassField;
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private IProject currentProject;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- private ManagedBeanType managedBean;
-
- private AbstractFacesConfigSection section;
-
- private List selectionChangedListeners = new ArrayList();
-
- /**
- * @param section
- */
- public ListEntriesEditGroup(AbstractFacesConfigSection section) {
- super();
- this.section = section;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- // TODO: initialize?
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#refreshData()
- */
- public void refreshData() {
- // TODO: initialize?
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- GridData data = new GridData(GridData.FILL_BOTH);
- parent.setLayoutData(data);
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- gl.marginHeight = 0;
- parent.setLayout(gl);
-
- layoutListTypeSelectionSection(toolkit, parent);
-
- createAndLayoutListValueSection(toolkit, parent);
- }
-
- /**
- *
- */
- private void layoutListTypeSelectionSection(FormToolkit toolkit,
- Composite container) {
- Composite typeSelectionSection = null;
- if (toolkit != null) {
- typeSelectionSection = toolkit.createComposite(container);
- toolkit.paintBordersFor(typeSelectionSection);
- } else {
- typeSelectionSection = SWTUtils
- .createComposite(container, SWT.NONE);
- }
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- typeSelectionSection.setLayoutData(gd);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- typeSelectionSection.setLayout(gl);
- valueClassField = new ClassButtonDialogField(getProject());
-
- valueClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_ValueClass);
- valueClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- ManagedBeanType managedBean_ = (ManagedBeanType) getInput();
- String className = ((ClassButtonDialogField) field)
- .getText();
- ValueClassType valueClass = FacesConfigFactory.eINSTANCE
- .createValueClassType();
- valueClass.setTextContent(className);
- EditingDomain editingDomain = section
- .getEditingDomain();
- Command cmd;
- boolean isNew;
- if (managedBean_.getListEntries() == null) {
- isNew = true;
- ListEntriesType listEntries = FacesConfigFactory.eINSTANCE
- .createListEntriesType();
- listEntries.setValueClass(valueClass);
- cmd = SetCommand.create(editingDomain, managedBean_,
- FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ListEntries(),
- listEntries);
- } else {
- isNew = false;
- ListEntriesType listEntries = managedBean_
- .getListEntries();
- cmd = SetCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_ValueClass(),
- valueClass);
- }
-
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- if (isNew)
- refreshAll();
- }
-
- }
- });
- valueClassField.doFillIntoGrid(toolkit, typeSelectionSection,
- numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(valueClassField.getTextControl(
- toolkit, container));
- }
-
- /**
- * @param toolkit
- * @param parent
- */
- private void createAndLayoutListValueSection(FormToolkit toolkit,
- Composite parent) {
- Composite listValueSection = null;
- if (toolkit != null) {
- listValueSection = toolkit.createComposite(parent);
- toolkit.paintBordersFor(listValueSection);
- } else {
- listValueSection = SWTUtils.createComposite(parent, SWT.NONE);
- }
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- listValueSection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- listValueSection.setLayout(gl);
- DialogFieldBase valuesTitle = new DialogFieldBase();
- valuesTitle
- .setLabelText(EditorMessages.InitializationSection_MapTable_Title);
- valuesTitle.doFillIntoGrid(toolkit, listValueSection, numberOfColumns);
-
- // list's value table
- Table listTable;
- if (toolkit == null) {
- listTable = new Table(listValueSection, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- } else {
- listTable = new Table(listValueSection, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- }
-
- listTable.addSelectionListener(new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- updateButtons();
- }
-
- });
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- listTable.setLayoutData(gd);
- listTable.setHeaderVisible(true);
- listTable.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- layout.addColumnData(new ColumnWeightData(1, true));
- listTable.setLayout(layout);
- TableColumn valueCol = new TableColumn(listTable, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol
- .setText(EditorMessages.InitializationSection_MapTable_Value);
- valueCol.setResizable(true);
-
- listTable.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
- tableViewer = new TableViewer(listTable);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- section.getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(section
- .getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getValueType().isInstance(
- element)
- || FacesConfigPackage.eINSTANCE.getNullValueType()
- .isInstance(element);
- }
- });
- tableViewer.addSelectionChangedListener(this);
-
- Composite operationContainer = null;
- if (toolkit != null) {
- operationContainer = toolkit.createComposite(listValueSection);
- } else {
- operationContainer = SWTUtils.createComposite(listValueSection,
- SWT.NONE);
- }
- gd = new GridData(GridData.FILL_VERTICAL);
- operationContainer.setLayoutData(gd);
- gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = null;
- if (toolkit != null) {
- addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- } else {
- addButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Add_more);
- }
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = null;
- if (toolkit != null) {
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more, SWT.PUSH);
- } else {
- editButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Edit_more);
- }
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = null;
- if (toolkit != null) {
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- } else {
- removeButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Remove);
- }
-
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
- });
- }
-
- private void addButtonSelected() {
- EditValueDialog dialog = new EditValueDialog(EditorPlugin
- .getActiveShell(), true, false, null);
- if (dialog.open() == Dialog.OK) {
-
- EditingDomain editingDomain = section.getEditingDomain();
- if (this.managedBean.getListEntries() == null) {
- ListEntriesType listEntries = FacesConfigFactory.eINSTANCE
- .createListEntriesType();
- if (dialog.isNullValue()) {
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- listEntries.getNullValue().add(nullValue);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) dialog.getResultData());
- listEntries.getValue().add(value);
- }
-
- Command cmd1 = SetCommand.create(editingDomain, managedBean,
- FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ListEntries(), listEntries);
- if (cmd1.canExecute()) {
- editingDomain.getCommandStack().execute(cmd1);
- refreshAll();
- }
- } else {
- ListEntriesType listEntries = managedBean.getListEntries();
- Command cmd;
- if (dialog.isNullValue()) {
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- cmd = AddCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_NullValue(), nullValue);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) dialog.getResultData());
- cmd = AddCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_Value(), value);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- }
- }
-
- private void editButtonSelected() {
- Object select = ((IStructuredSelection) tableViewer.getSelection())
- .getFirstElement();
- boolean isNullValue;
- String valueText = null;
- if (select instanceof NullValueType)
- isNullValue = true;
- else {
- isNullValue = false;
- valueText = ((ValueType) select).getTextContent();
- }
- ListEntriesType listEntries = managedBean.getListEntries();
- EditValueDialog dialog = new EditValueDialog(EditorPlugin
- .getActiveShell(), true, isNullValue, valueText);
- if (dialog.open() == Dialog.OK) {
- EditingDomain editingDomain = section.getEditingDomain();
- Command cmd = null;
- if (isNullValue && !dialog.isNullValue()) {
- List commands = new ArrayList();
- Command cmd1 = RemoveCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_NullValue(), select);
- commands.add(cmd1);
-
- // listEntries.getNullValue().remove(select);
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) dialog.getResultData());
- Command cmd2 = AddCommand
- .create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_Value(), value);
- commands.add(cmd2);
- cmd = new CompoundCommand(commands);
- } else if (!isNullValue && dialog.isNullValue()) {
- List commands = new ArrayList();
- Command cmd1 = RemoveCommand
- .create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_Value(), select);
- commands.add(cmd1);
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- Command cmd2 = AddCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_NullValue(), nullValue);
- commands.add(cmd2);
- cmd = new CompoundCommand(commands);
- } else if (!isNullValue && !dialog.isNullValue()) {
- cmd = SetCommand
- .create(editingDomain, select,
- FacesConfigPackage.eINSTANCE
- .getValueType_TextContent(), dialog
- .getResultData());
- }
-
- if (cmd != null && cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
- }
-
- private void removeButtonSelected() {
- Object select = ((IStructuredSelection) tableViewer.getSelection())
- .getFirstElement();
- ListEntriesType listEntries = managedBean.getListEntries();
- EditingDomain editingDomain = section.getEditingDomain();
- Command cmd;
- if (select instanceof NullValueType) {
- cmd = RemoveCommand
- .create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE
- .getListEntriesType_NullValue(), select);
- } else {
- cmd = RemoveCommand.create(editingDomain, listEntries,
- FacesConfigPackage.eINSTANCE.getListEntriesType_Value(),
- select);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.managedbean.sections.wizards.IDialogFieldGroup#setInput(java.lang.Object)
- */
- public void setInput(Object newInput) {
- if (newInput != null && newInput instanceof ManagedBeanType) {
- managedBean = (ManagedBeanType) newInput;
- if (managedBean.getListEntries() != null)
- refreshAll();
- }
-
- }
-
- /**
- *
- */
- public void refreshAll() {
- if (managedBean.getListEntries() != null
- && managedBean.getListEntries().getValueClass() != null) {
- this.valueClassField.setTextWithoutUpdate(managedBean
- .getListEntries().getValueClass().getTextContent());
- } else {
- valueClassField.setTextWithoutUpdate(null);
- }
- tableViewer.setInput(((ManagedBeanType) getInput()).getListEntries());
- updateButtons();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see com.sybase.stf.jmt.editors.pageflow.managedbean.sections.wizards.IDialogFieldGroup#getInput()
- */
- public Object getInput() {
- return managedBean;
- }
-
- private IProject getProject() {
- if (currentProject == null) {
- currentProject = (IProject) section.getPage().getEditor()
- .getAdapter(IProject.class);
- }
- return currentProject;
- }
-
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#validateDialogFields()
- */
- public IStatus[] validateDialogFields() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener.selectionChanged(new SelectionChangedEvent(this, event
- .getSelection()));
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LocaleConfigSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LocaleConfigSection.java
deleted file mode 100644
index 3ac917a82..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/LocaleConfigSection.java
+++ /dev/null
@@ -1,421 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTableViewer;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
-import org.eclipse.jst.jsf.facesconfig.emf.DefaultLocaleType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.LocaleConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.SupportedLocaleType;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.DialogUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Zhi-peng Zhang, sfshi
- * @version
- */
-public class LocaleConfigSection extends ApplicationSection implements
- ICheckStateListener {
- private LocaleConfigAdapter _localeConfigAdapter;
-
- /**
- *
- * @param componentClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public LocaleConfigSection(EClass componentClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page,
- FormToolkit toolkit, String helpContextId, String helpTooltip) {
- super(componentClass, parent, managedForm, page, toolkit,
- helpContextId, helpTooltip);
- }
-
- /**
- *
- * @param componentClass
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public LocaleConfigSection(EClass componentClass, Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- this(componentClass, parent, managedForm, page, toolkit, null, null);
- }
-
- public void dispose() {
- ((CheckboxTableViewer)tableViewer).removeCheckStateListener(this);
- super.dispose();
- }
- /**
- * create a CheckboxTableViewer for this section.
- */
- protected TableViewer createTableViewer(Composite parent) {
- CheckboxTableViewer tableViewer1 = CheckboxTableViewer.newCheckList(
- parent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
- tableViewer1.addCheckStateListener(this);
- tableViewer1.setSorter(new ViewerSorter());
- return tableViewer1;
- }
-
- /**
- * Add a filter for this table viewer, only <supported-locale> and
- * <default-locale> elements would be listed.
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getSupportedLocaleType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE.getDefaultLocaleType()
- .isInstance(element);
- }
- });
- }
-
- /**
- * Pop up a dialog for user to select a locale string, then create a
- * <supported-locale> element with the string as value.
- *
- * @return the supported locale object
- */
- public SupportedLocaleType createSupportedLocaleObject() {
- ArrayList locales = new ArrayList();
-
- /**
- * Compute the locales that already declared in this <locale-config>
- * element. If user select a locale that already declared, then a
- * warning message will be shown in the dialog.
- */
-
- if (getInput() instanceof ApplicationType
- && ((ApplicationType) getInput()).getLocaleConfig().size() > 0) {
- LocaleConfigType localeConfigType = (LocaleConfigType) ((ApplicationType) getInput())
- .getLocaleConfig().get(0);
- if (localeConfigType.getDefaultLocale() != null) {
- String locale = localeConfigType.getDefaultLocale()
- .getTextContent();
- if (locale != null) {
- locales.add(locale);
- }
- }
- List list = localeConfigType.getSupportedLocale();
- for (int i = 0, n = list.size(); i < n; i++) {
- String locale = ((SupportedLocaleType) list.get(i))
- .getTextContent();
- if (locale != null) {
- locales.add(locale);
- }
- }
- }
- String result = DialogUtil.openLocaleDialog(getSection().getShell(),
- locales);
- if (result != null) {
- SupportedLocaleType component = FacesConfigFactory.eINSTANCE
- .createSupportedLocaleType();
- component.setTextContent(result);
- return component;
- }
- return null;
- }
-
- /**
- * When user click "Add" button on this section, pop up a dialog to create a
- * <supported-locale> element, then add it onto <locale-config> element, if
- * the <locale-config> or <application> doesn't exist, create them together.
- */
- void addButtonSelected(SelectionEvent e) {
- SupportedLocaleType obj = createSupportedLocaleObject();
- if (obj != null) {
-
- boolean needRefreshAll = false;
- Command command = null;
-
- if (getInput() instanceof ApplicationType) {
- /** the <application> element exists. */
- ApplicationType application = (ApplicationType) getInput();
- if (application.getLocaleConfig().size() > 0) {
- /** the <locale-config> element exists. */
- LocaleConfigType localeConfig = (LocaleConfigType) application
- .getLocaleConfig().get(0);
- command = AddCommand.create(this.getEditingDomain(),
- localeConfig, null, obj);
- } else {
- /** the <locale-config> element doesn't exist, create it. */
- LocaleConfigType localeConfig = FacesConfigFactory.eINSTANCE
- .createLocaleConfigType();
- localeConfig.getSupportedLocale().add(obj);
- command = AddCommand.create(getEditingDomain(),
- application, null, localeConfig);
- }
- } else {
- /**
- * the <application> element doesn't exist, then create it,
- * after execute, reset the input for all the application
- * sections.
- */
- needRefreshAll = true;
- ApplicationType application = FacesConfigFactory.eINSTANCE
- .createApplicationType();
- LocaleConfigType localeConfig = FacesConfigFactory.eINSTANCE
- .createLocaleConfigType();
- localeConfig.getSupportedLocale().add(obj);
- application.getLocaleConfig().add(localeConfig);
- command = AddCommand.create(getEditingDomain(), this.getPage()
- .getInput(), null, application);
- }
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- if (needRefreshAll)
- /** reset input for all the application sections. */
- ((OthersPage) this.getPage()).resetApplicationInput();
- }
- }
-
- }
-
- /**
- * when user click on the CheckboxTableViewer, perform some actions to
- * set/unset <default-locale> and <supported-locale> elements.
- *
- * If an item is selected, that means it's a <default-locale>, otherwise
- * it's a <supported-locale>.
- *
- * @see org.eclipse.jface.viewers.ICheckStateListener#checkStateChanged(org.eclipse.jface.viewers.CheckStateChangedEvent)
- */
- public void checkStateChanged(CheckStateChangedEvent event) {
- boolean checked = event.getChecked();
-
- if (event.getElement() == null) {
- return;
- }
-
- EObject node = (EObject) event.getElement();
- LocaleConfigType localeConfigType = (LocaleConfigType) ((ApplicationType) getInput())
- .getLocaleConfig().get(0);
- CompoundCommand compoundCommand = new CompoundCommand();
-
- if (checked) {
- /** user checked one item, going to set it as <default-locale>. */
- if (localeConfigType.getDefaultLocale() != null) {
- /**
- * Change the <default-locale> value to <supported-locale>.
- */
- Command command = RemoveCommand.create(getEditingDomain(),
- localeConfigType, null, localeConfigType
- .getDefaultLocale());
-
- compoundCommand.append(command);
-
- SupportedLocaleType supportedLocale = FacesConfigFactory.eINSTANCE
- .createSupportedLocaleType();
- supportedLocale.setTextContent(localeConfigType
- .getDefaultLocale().getTextContent());
- command = AddCommand.create(getEditingDomain(),
- localeConfigType, FacesConfigPackage.eINSTANCE
- .getLocaleConfigType_SupportedLocale(),
- supportedLocale);
- compoundCommand.append(command);
- }
-
- /**
- * Change the selected item from <supported-locale> to
- * <default-locale>
- */
- SupportedLocaleType supportedLocale = (SupportedLocaleType) node;
- Command command = RemoveCommand.create(getEditingDomain(),
- localeConfigType, FacesConfigPackage.eINSTANCE
- .getLocaleConfigType_SupportedLocale(),
- supportedLocale);
- compoundCommand.append(command);
-
- DefaultLocaleType defaultLocale = FacesConfigFactory.eINSTANCE
- .createDefaultLocaleType();
- defaultLocale.setTextContent(supportedLocale.getTextContent());
- command = SetCommand
- .create(getEditingDomain(), localeConfigType,
- FacesConfigPackage.eINSTANCE
- .getLocaleConfigType_DefaultLocale(),
- defaultLocale);
- compoundCommand.append(command);
-
- } else {
- /**
- * User unchecked one item, going to change it from <default-locale>
- * to <supported-locale>.
- */
- DefaultLocaleType defaultLocale = (DefaultLocaleType) node;
- Command command = RemoveCommand.create(getEditingDomain(),
- localeConfigType, null, defaultLocale);
- compoundCommand.append(command);
-
- SupportedLocaleType supportedLocale = FacesConfigFactory.eINSTANCE
- .createSupportedLocaleType();
- supportedLocale.setTextContent(defaultLocale.getTextContent());
- command = AddCommand.create(getEditingDomain(), localeConfigType,
- null, supportedLocale);
- compoundCommand.append(command);
- }
-
- if (compoundCommand.canExecute()) {
- getEditingDomain().getCommandStack().execute(compoundCommand);
- this.refresh();
- setTableViewerCheckedState();
- }
- }
-
- /**
- * Set the checked state for items in the checkbox table viewer. This method
- * could be used for refresh the checked state of the table viewer.
- */
- private void setTableViewerCheckedState() {
- if (getInput() instanceof ApplicationType) {
- ApplicationType application = (ApplicationType) getInput();
- if (application.getLocaleConfig().size() > 0) {
-
- LocaleConfigType localeConfigType = (LocaleConfigType) application
- .getLocaleConfig().get(0);
- if (localeConfigType.getDefaultLocale() != null) {
- ((CheckboxTableViewer) getTableViewer()).setChecked(
- localeConfigType.getDefaultLocale(), true);
- }
- }
- }
- }
-
- @Override
- protected void addAdaptersOntoInput(Object input) {
- super.addAdaptersOntoInput(input);
- if (input != null && input instanceof ApplicationType) {
- ApplicationType application = (ApplicationType) input;
- if (EcoreUtil.getExistingAdapter(application,
- LocaleConfigSection.class) == null) {
- application.eAdapters().add(getLocaleConfigAdapter());
- }
- }
- }
-
- private Adapter getLocaleConfigAdapter() {
- if (_localeConfigAdapter == null) {
- _localeConfigAdapter = new LocaleConfigAdapter();
- }
- return _localeConfigAdapter;
- }
-
- @Override
- protected void removeAdaptersFromInput(Object input) {
- if (input != null && input instanceof ApplicationType && _localeConfigAdapter != null) {
- ApplicationType application = (ApplicationType) input;
- application.eAdapters().remove(_localeConfigAdapter);
- }
- super.removeAdaptersFromInput(input);
- }
-
- /**
- * set the structuredViewer's input. Set the first LocaleConfig as input.
- *
- * @param input
- */
- protected void setViewerInput(Object input) {
- if (input instanceof ApplicationType) {
- ApplicationType application = (ApplicationType) input;
- if (application.getLocaleConfig().size() > 0) {
- tableViewer.setInput(application.getLocaleConfig().get(0));
- } else
- tableViewer.setInput(null);
- } else
- tableViewer.setInput(null);
-
- }
-
- public void refreshAll() {
- super.refreshAll();
- setTableViewerCheckedState();
- }
-
- /**
- * A listener that is be adapted on the input <application> element, to
- * listen the event that the first <locale-config> being created and
- * removed, then reset the input of the tabel viewer.
- *
- * @author sfshi
- *
- */
- class LocaleConfigAdapter extends AdapterImpl {
- public boolean isAdapterForType(Object type) {
- if (type == LocaleConfigSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getApplicationType_LocaleConfig()) {
- /**
- * a <locale-config> was created or removed, notify this
- * section to reset it's input.
- */
-
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- setInput(getInput());
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- setInput(getInput());
- }
- });
- }
-
- }
- }
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanGeneralSection.java
deleted file mode 100644
index 6df0d5358..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanGeneralSection.java
+++ /dev/null
@@ -1,330 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ComboDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldChangeListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanScopeType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ManagedBeanGeneralSection extends AbstractFacesConfigSection {
-
- private StringDialogField mbNameField;
-
- private ClassButtonDialogField mbClassField;
-
- private ComboDialogField mbScopeField;
-
- private ManagedBeanGeneralSectionAdapter managedBeanGeneralSectionAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public ManagedBeanGeneralSection(Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection().setText(
- EditorMessages.ManagedBeanGeneralSection_Name);
- getSection().setDescription(
- EditorMessages.ManagedBeanGeneralSection_Desc);
- }
-
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- container.setLayout(layout);
-
- toolkit.paintBordersFor(container);
-
- createMBNameEntry(container, toolkit, numberOfColumns);
-
- createMBClassEntry(container, toolkit, numberOfColumns);
-
- createMBScopeEntry(container, toolkit, numberOfColumns);
-
- }
-
- /**
- * create managed bean's name editing field
- *
- * @param container
- * @param toolkit
- */
- private void createMBNameEntry(Composite container, FormToolkit toolkit,
- int numberOfColumns) {
- mbNameField = new StringDialogField();
- mbNameField
- .setLabelText(EditorMessages.ManagedBeanGeneralSection_ManagedBeanName);
- mbNameField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(mbNameField.getTextControl(toolkit,
- container));
- mbNameField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String mbNameValue = ((StringDialogField) field)
- .getText();
- Command cmd = null;
- ManagedBeanType managedBean = (ManagedBeanType) getInput();
- // if (managedBean.getManagedBeanName() != null) {
- // cmd = SetCommand
- // .create(
- // getEditingDomain(),
- // managedBean.getManagedBeanName(),
- // FacesConfigPackage.eINSTANCE
- // .getManagedBeanNameType_TextContent(),
- // mbNameValue);
- // } else {
- ManagedBeanNameType newManagedBeanName = FacesConfigFactory.eINSTANCE
- .createManagedBeanNameType();
- newManagedBeanName.setTextContent(mbNameValue);
- cmd = SetCommand.create(getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanName(),
- newManagedBeanName);
- // }
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- }
- }
- });
- }
-
- /**
- * create managed bean's class field.
- *
- * @param container
- * @param toolkit
- */
- private void createMBClassEntry(final Composite container,
- final FormToolkit toolkit, int numberOfColumns) {
- mbClassField = new ClassButtonDialogField(null);
- mbClassField
- .setLabelText(EditorMessages.ManagedBeanGeneralSection_ManagedBeanClass);
- mbClassField.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- mbClassField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(mbClassField.getTextControl(toolkit,
- container));
-
- mbClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String newValue = ((StringDialogField) field).getText();
- Command cmd = null;
- ManagedBeanType managedBean = (ManagedBeanType) getInput();
- // if (managedBean.getManagedBeanClass() != null) {
- // cmd = SetCommand
- // .create(
- // getEditingDomain(),
- // managedBean.getManagedBeanClass(),
- // FacesConfigPackage.eINSTANCE
- // .getManagedBeanClassType_TextContent(),
- // newValue);
- // } else {
- ManagedBeanClassType newManagedBeanClass = FacesConfigFactory.eINSTANCE
- .createManagedBeanClassType();
- newManagedBeanClass.setTextContent(newValue);
- cmd = SetCommand.create(getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanClass(),
- newManagedBeanClass);
- // }
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- }
- }
- });
- }
-
- /**
- * create managed bean's scope field
- *
- * @param container
- * @param toolkit
- */
- private void createMBScopeEntry(Composite container, FormToolkit toolkit,
- int numberOfColumns) {
- mbScopeField = new ComboDialogField(SWT.DROP_DOWN | SWT.READ_ONLY | SWT.BORDER);
- mbScopeField
- .setLabelText(EditorMessages.ManagedBeanGeneralSection_ManagedBeanScope);
- mbScopeField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(mbScopeField.getComboControl(toolkit,
- container));
-
- mbScopeField.setItems(ManagedBeanScopeTreeItem.scopeItems);
-
- mbScopeField
- .setDialogFieldChangeListener(new IDialogFieldChangeListener() {
- public void dialogFieldChanged(DialogField field) {
- String newValue = ((ComboDialogField) field).getText();
- Command cmd = null;
- ManagedBeanType managedBean = (ManagedBeanType) getInput();
- // if (managedBean.getManagedBeanScope() != null) {
- // cmd = SetCommand
- // .create(
- // getEditingDomain(),
- // managedBean.getManagedBeanScope(),
- // FacesConfigPackage.eINSTANCE
- // .getManagedBeanScopeType_TextContent(),
- // newValue);
- // } else {
- ManagedBeanScopeType newManagedBeanScope = FacesConfigFactory.eINSTANCE
- .createManagedBeanScopeType();
- newManagedBeanScope.setTextContent(newValue);
- cmd = SetCommand.create(getEditingDomain(),
- managedBean, FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanScope(),
- newManagedBeanScope);
- // }
- if (cmd.canExecute()) {
- getEditingDomain().getCommandStack().execute(cmd);
- }
- }
- });
- }
-
- public void refreshAll() {
- refresh();
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- Object input = this.getInput();
- if (input instanceof ManagedBeanType) {
- final ManagedBeanType component = (ManagedBeanType) input;
- refreshControls(component);
- }
- }
-
- private void refreshControls(ManagedBeanType component) {
- if (component.getManagedBeanName() != null) {
- mbNameField.setTextWithoutUpdate(component.getManagedBeanName()
- .getTextContent());
- } else {
- mbNameField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (component.getManagedBeanClass() != null) {
- mbClassField.setTextWithoutUpdate(component
- .getManagedBeanClass().getTextContent());
- } else {
- mbClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (component.getManagedBeanScope() != null) {
- mbScopeField.setTextWithoutUpdate(component
- .getManagedBeanScope().getTextContent());
- } else {
- // defaultly set it's scope to "session";
- mbScopeField
- .setTextWithoutUpdate(IFacesConfigConstants.MANAGED_BEAN_SCOPE_SESSION);
- }
-
- }
- protected void addAdaptersOntoInput(Object newInput) {
- super.addAdaptersOntoInput(newInput);
- ManagedBeanType managedBean = (ManagedBeanType) newInput;
- if (EcoreUtil.getExistingAdapter(managedBean,
- ManagedBeanGeneralSection.class) == null) {
- managedBean.eAdapters().add(getManagedBeanGeneralSectionAdatper());
- }
-
- }
-
- protected void removeAdaptersFromInput(Object oldInput) {
- super.removeAdaptersFromInput(oldInput);
- ManagedBeanType managedBean = (ManagedBeanType) oldInput;
- if (EcoreUtil.getExistingAdapter(managedBean,
- ManagedBeanGeneralSection.class) != null) {
- managedBean.eAdapters().remove(
- getManagedBeanGeneralSectionAdatper());
- }
- }
-
- private ManagedBeanGeneralSectionAdapter getManagedBeanGeneralSectionAdatper() {
- if (managedBeanGeneralSectionAdapter == null) {
- managedBeanGeneralSectionAdapter = new ManagedBeanGeneralSectionAdapter();
- }
- return managedBeanGeneralSectionAdapter;
- }
-
- class ManagedBeanGeneralSectionAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
-
- if (type == ManagedBeanGeneralSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanName()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanScope()) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refresh();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refresh();
- }
- });
- }
- }
- }
- }
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanMasterSection.java
deleted file mode 100644
index 5d67eb7f8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanMasterSection.java
+++ /dev/null
@@ -1,375 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanScopeType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.jst.jsf.facesconfig.ui.provider.ManagedBeanContentProvider;
-import org.eclipse.jst.jsf.facesconfig.ui.provider.ManagedBeanLabelProvider;
-import org.eclipse.jst.jsf.facesconfig.ui.wizard.NewManagedBeanWizard;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- */
-public class ManagedBeanMasterSection extends FacesConfigMasterSection {
-
- private ManagedBeanMasterSectionAdapter managedBeanMasterSectionAdapter;
-
- /**
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- */
- public ManagedBeanMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- super(parent, managedForm, toolkit, page, null, null);
- getSection().setText(EditorMessages.ManagedBeanMasterSection_Name);
- getSection().setDescription(
- EditorMessages.ManagedBeanMasterSection_Description);
- }
-
- protected StructuredViewer createViewer(Composite parent,
- FormToolkit toolkit) {
- Composite treeContainer = toolkit.createComposite(parent);
- toolkit.paintBordersFor(treeContainer);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- treeContainer.setLayoutData(gd);
- GridLayout layout = new GridLayout();
- treeContainer.setLayout(layout);
-
- // Create tree viewer
- TreeViewer treeViewer = new TreeViewer(treeContainer, SWT.SINGLE
- | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- treeViewer.getControl().setLayoutData(gd);
-
- treeViewer.setContentProvider(new ManagedBeanContentProvider());
- treeViewer.setLabelProvider(new ManagedBeanLabelProvider());
- treeViewer.addSelectionChangedListener(this);
-
- treeViewer.setAutoExpandLevel(3);
- return treeViewer;
- }
-
- protected void addButtonSelected(SelectionEvent e) {
- IProject project = (IProject) this.getPage().getEditor().getAdapter(
- IProject.class);
-
- NewManagedBeanWizard wizard = new NewManagedBeanWizard(project);
- IStructuredSelection selection = (IStructuredSelection) this
- .getSelection();
- if (selection.getFirstElement() instanceof ManagedBeanScopeTreeItem) {
- // if user is selecting a scope tree item, then use this scope as
- // the default scope for the new managed bean.
- ManagedBeanScopeTreeItem scopeTreeItem = (ManagedBeanScopeTreeItem) selection
- .getFirstElement();
- wizard.setDefaultScope(scopeTreeItem.getScope());
- }
-
- wizard.setForcePreviousAndNextButtons(true);
-
- Shell shell = EditorPlugin.getActiveShell();
- WizardDialog wizardDialog = new WizardDialog(shell, wizard);
- wizardDialog.create();
- wizardDialog.setBlockOnOpen(true);
- if (wizardDialog.open() == Window.OK) {
- ManagedBeanType managedBean = FacesConfigFactory.eINSTANCE
- .createManagedBeanType();
-
- ManagedBeanNameType name = FacesConfigFactory.eINSTANCE
- .createManagedBeanNameType();
- name.setTextContent(wizard.getManagedBeanName());
- managedBean.setManagedBeanName(name);
-
- ManagedBeanClassType clazz = FacesConfigFactory.eINSTANCE
- .createManagedBeanClassType();
- clazz.setTextContent(wizard.getManagedBeanClass());
- managedBean.setManagedBeanClass(clazz);
-
- ManagedBeanScopeType scope = FacesConfigFactory.eINSTANCE
- .createManagedBeanScopeType();
- scope.setTextContent(wizard.getManagedBeanScope());
- managedBean.setManagedBeanScope(scope);
-
- String desc = wizard.getManagedBeanDescription();
- if (desc != null && desc.trim().length() > 0) {
- DescriptionType description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(wizard.getManagedBeanDescription());
- managedBean.getDescription().add(description);
- }
-
- Command cmd = AddCommand.create(getEditingDomain(), getInput(),
- null, managedBean);
- if (cmd.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(cmd);
- }
- }
-
- }
-
- protected void removeButtonSelected(SelectionEvent e) {
- IStructuredSelection ssel = StructuredSelection.EMPTY;
- ISelection selection = getSelection();
- if (selection instanceof IStructuredSelection) {
- ssel = (IStructuredSelection) selection;
- }
-
- if (!ssel.isEmpty()) {
- if (ssel.getFirstElement() instanceof ManagedBeanType) {
- ManagedBeanType element = (ManagedBeanType) ssel
- .getFirstElement();
- Command command = RemoveCommand.create(getEditingDomain(), this
- .getInput(), FacesConfigPackage.eINSTANCE
- .getFacesConfigType_ManagedBean(), element);
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- }
- }
- }
- }
-
- protected void updateButtons() {
- IStructuredSelection ssel = (IStructuredSelection) getStructuredViewer()
- .getSelection();
- boolean isRemoveEnable = false;
- if (!ssel.isEmpty()) {
- Object s1 = ssel.getFirstElement();
- if (s1 instanceof ManagedBeanType) {
- isRemoveEnable = true;
- }
- }
- getRemoveButton().setEnabled(isRemoveEnable);
- }
-
- /**
- * Override the super method to ignore the selection on ScopeTreeItem.
- */
- public void selectionChanged(SelectionChangedEvent event) {
-
- if (event != null
- && event.getSelection() != null
- && ((IStructuredSelection) event.getSelection())
- .getFirstElement() instanceof ManagedBeanScopeTreeItem) {
-
- event = new SelectionChangedEvent(this, StructuredSelection.EMPTY);
- }
- super.selectionChanged(event);
- updateButtons();
-
- }
-
- protected void addAdaptersOntoInput(Object newInput) {
- super.addAdaptersOntoInput(newInput);
-
- FacesConfigType facesConfig = (FacesConfigType) newInput;
- if (EcoreUtil.getExistingAdapter(facesConfig,
- ManagedBeanMasterSection.class) == null) {
-
- facesConfig.eAdapters().add(getManagedBeanMasterSectionAdapter());
- }
-
- List managedbeans = facesConfig.getManagedBean();
- for (Iterator it = managedbeans.iterator(); it.hasNext();) {
- ManagedBeanType managedbean = (ManagedBeanType) it.next();
- if (EcoreUtil.getExistingAdapter(managedbean,
- ManagedBeanMasterSection.class) == null) {
-
- managedbean.eAdapters().add(
- getManagedBeanMasterSectionAdapter());
- }
- }
- }
-
- protected void removeAdaptersFromInput(Object oldInput) {
- FacesConfigType facesConfig = (FacesConfigType) oldInput;
- if (EcoreUtil.getExistingAdapter(facesConfig,
- ManagedBeanMasterSection.class) != null) {
-
- facesConfig.eAdapters()
- .remove(getManagedBeanMasterSectionAdapter());
- }
-
- List managedbeans = facesConfig.getManagedBean();
- for (Iterator it = managedbeans.iterator(); it.hasNext();) {
- ManagedBeanType managedbean = (ManagedBeanType) it.next();
- if (EcoreUtil.getExistingAdapter(managedbean,
- ManagedBeanMasterSection.class) != null) {
-
- managedbean.eAdapters().remove(
- getManagedBeanMasterSectionAdapter());
- }
- }
- super.removeAdaptersFromInput(oldInput);
- }
-
- private ManagedBeanMasterSectionAdapter getManagedBeanMasterSectionAdapter() {
- if (managedBeanMasterSectionAdapter == null) {
- managedBeanMasterSectionAdapter = new ManagedBeanMasterSectionAdapter();
- }
- return managedBeanMasterSectionAdapter;
- }
-
- class ManagedBeanMasterSectionAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == ManagedBeanMasterSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
- super.notifyChanged(msg);
-
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_ManagedBean()) {
- if (msg.getEventType() == Notification.ADD) {
- final EObject mbean = (EObject) msg.getNewValue();
- if (EcoreUtil.getExistingAdapter(mbean,
- ManagedBeanMasterSection.class) == null) {
-
- mbean.eAdapters().add(
- getManagedBeanMasterSectionAdapter());
- }
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- getStructuredViewer().refresh(true);
- IStructuredSelection selection = new StructuredSelection(
- mbean);
- getStructuredViewer().setSelection(selection);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getStructuredViewer().refresh(true);
- IStructuredSelection selection = new StructuredSelection(
- mbean);
- getStructuredViewer().setSelection(selection);
- }
- });
- }
- } else if (msg.getEventType() == Notification.REMOVE) {
- final EObject mbean = (EObject) msg.getOldValue();
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- getStructuredViewer().refresh(true);
- if (EcoreUtil.getExistingAdapter(mbean,
- ManagedBeanMasterSection.class) == null) {
-
- mbean.eAdapters().remove(
- getManagedBeanMasterSectionAdapter());
- }
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getStructuredViewer().refresh(true);
- if (EcoreUtil.getExistingAdapter(mbean,
- ManagedBeanMasterSection.class) == null) {
-
- mbean.eAdapters().remove(
- getManagedBeanMasterSectionAdapter());
- }
- }
- });
- }
-
- } else if (msg.getEventType() == Notification.SET) {
- final Object mbean = msg.getNewValue();
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- getStructuredViewer().refresh(mbean, true);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getStructuredViewer().refresh(mbean, true);
- }
- });
- }
- }
-
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanName()) {
-
- final Object bean = msg.getNotifier();
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- getStructuredViewer().refresh(bean, true);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getStructuredViewer().refresh(bean, true);
- }
- });
- }
-
-
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedBeanScope()) {
-
- final Object mbean = msg.getNotifier();
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- getStructuredViewer().refresh();
- IStructuredSelection selection = new StructuredSelection(
- mbean);
- getStructuredViewer().setSelection(selection);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- getStructuredViewer().refresh();
- IStructuredSelection selection = new StructuredSelection(
- mbean);
- getStructuredViewer().setSelection(selection);
- }
- });
- }
- }
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanScopeTreeItem.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanScopeTreeItem.java
deleted file mode 100644
index 4101d9e1c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedBeanScopeTreeItem.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-
-/**
- * @author Xiao-guang Zhang, sfshi
- * @version
- */
-public class ManagedBeanScopeTreeItem {
-
- /**
- * Possible values for bean scope
- */
- public static final String[] scopeItems = {
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_SESSION,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_REQUEST,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_APPLICATION,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_NONE };
-
- private String scope;
-
- private FacesConfigType facesConfig;
-
- /**
- *
- * @param managedBeanScope
- * @param facesConfig
- */
- public ManagedBeanScopeTreeItem(String managedBeanScope,
- FacesConfigType facesConfig) {
- super();
- this.scope = managedBeanScope;
-
- this.facesConfig = facesConfig;
- }
-
- /**
- * @return the parent object
- */
- public Object getParent() {
- return facesConfig;
- }
-
- /**
- * @return true if this node has children
- */
- public boolean hasChildren() {
- return !getChildren().isEmpty();
- }
-
- /**
- * @return the scope
- */
- public String getScope() {
- return scope;
- }
-
- /**
- * @return the list of children. List may be empty.
- */
- public List getChildren() {
- List result = new ArrayList();
- List managedBeans = facesConfig.getManagedBean();
- for (Iterator it = managedBeans.iterator(); it.hasNext();) {
- ManagedBeanType managedBean = (ManagedBeanType) it.next();
-
- if (managedBean.getManagedBeanScope() != null) {
- if (scope.equals(managedBean.getManagedBeanScope()
- .getTextContent())) {
- result.add(managedBean);
- }
- }
- }
-
- return result;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedPropertyEditGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedPropertyEditGroup.java
deleted file mode 100644
index c0112a1f4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ManagedPropertyEditGroup.java
+++ /dev/null
@@ -1,575 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldGroup;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ListEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedPropertyType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.NullValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditManagedPropertyDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- * @version
- */
-public class ManagedPropertyEditGroup extends DialogFieldGroup implements
- IDialogFieldGroup, ISelectionProvider, ISelectionChangedListener {
-
- private TableViewer tableViewer;
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private Button removeButton;
-
- private Button editButton;
-
- private ManagedBeanType managedBean;
-
- private AbstractFacesConfigSection section;
-
- private List selectionChangedListeners = new ArrayList();
-
- /**
- * @param section
- *
- */
- public ManagedPropertyEditGroup(AbstractFacesConfigSection section) {
- super();
- this.section = section;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#refreshData()
- */
- public void refreshData() {
- refresh();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- createGeneralClassPage(parent, toolkit);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#validateDialogFields()
- */
- public IStatus[] validateDialogFields() {
- return null;
- }
-
- /**
- * create general class initialization section
- *
- * @param container
- * @param toolkit
- */
- private void createGeneralClassPage(Composite container, FormToolkit toolkit) {
- Composite generalSection = toolkit.createComposite(container);
- generalSection.setLayoutData(new GridData(GridData.FILL_BOTH));
- toolkit.paintBordersFor(generalSection);
-
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- gl.numColumns = 2;
- generalSection.setLayout(gl);
-
- createTableSection(generalSection, toolkit);
-
- createButtonsSection(generalSection, toolkit);
- }
-
- /**
- * create proeprty table section
- *
- * @param container
- * @param toolkit
- */
- private void createTableSection(Composite container, FormToolkit toolkit) {
- // create property container
- Composite propertyContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.GRAB_HORIZONTAL);
- propertyContainer.setLayoutData(gd);
- toolkit.paintBordersFor(propertyContainer);
-
- GridLayout gl = new GridLayout();
- propertyContainer.setLayout(gl);
-
- // Create property table
- Table table = new Table(propertyContainer, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
-
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableColumn propertyCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- propertyCol
- .setText(EditorMessages.InitializationSection_PropertyTable_Name);
- propertyCol.setResizable(true);
-
- TableColumn classCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- classCol
- .setText(EditorMessages.InitializationSection_PropertyTable_Class);
- classCol.setResizable(true);
-
- TableColumn valueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol
- .setText(EditorMessages.InitializationSection_PropertyTable_Value);
- valueCol.setResizable(true);
-
- table.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
- });
-
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
-
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- section.getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(section
- .getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getManagedPropertyType()
- .isInstance(element);
- }
- });
-
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- * Update the buttons' enable and disable status
- */
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- * create property's editing buttons
- *
- * @param container
- * @param toolkit
- */
- private void createButtonsSection(Composite container, FormToolkit toolkit) {
- // create operation buttons's container
- Composite operationContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_VERTICAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- operationContainer.setLayoutData(gd);
- GridLayout gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- // create list operation buttons
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more, SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
- });
-
- }
-
- private void addButtonSelected() {
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditManagedPropertyDialog dialog = new AddEditManagedPropertyDialog(
- shell, managedBean, section);
- if (dialog.open() == Dialog.OK) {
-
- ManagedPropertyType managedProperty = createManagedPropertyFromDialog(dialog);
- Command addCommand = AddCommand.create(this.getEditingDomain(),
- getInput(), FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedProperty(),
- managedProperty);
- if (addCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(addCommand);
-
- }
- }
-
- }
-
- private void editButtonSelected() {
- ManagedPropertyType managedProperty = (ManagedPropertyType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- Shell shell = EditorPlugin.getActiveShell();
- AddEditManagedPropertyDialog dialog = new AddEditManagedPropertyDialog(
- shell, managedProperty, section);
- if (dialog.open() == Dialog.OK) {
- List commands = new ArrayList();
- String propertyName = dialog.getPropertyName();
- String propertyClass = dialog.getPropertyClass();
- PropertyNameType propertyNameType = FacesConfigFactory.eINSTANCE
- .createPropertyNameType();
- propertyNameType.setTextContent(propertyName);
- Command cmd1 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_PropertyName(),
- propertyNameType);
- commands.add(cmd1);
-
- PropertyClassType propertyClassType = FacesConfigFactory.eINSTANCE
- .createPropertyClassType();
- propertyClassType.setTextContent(propertyClass);
- Command cmd2 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_PropertyClass(),
- propertyClassType);
- commands.add(cmd2);
-
- // remove value, null-value, map-entries and list-entries element:
- if (managedProperty.getNullValue() != null) {
- Command rmCmd = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_NullValue(),
- SetCommand.UNSET_VALUE);
- commands.add(rmCmd);
- }
- if (managedProperty.getListEntries() != null) {
- Command rmCmd = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_ListEntries(),
- SetCommand.UNSET_VALUE);
- commands.add(rmCmd);
- }
- if (managedProperty.getValue() != null) {
- Command rmCmd = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_Value(),
- SetCommand.UNSET_VALUE);
- commands.add(rmCmd);
- }
- if (managedProperty.getMapEntries() != null) {
- Command rmCmd = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_MapEntries(),
- SetCommand.UNSET_VALUE);
- commands.add(rmCmd);
- }
-
- Object valueObject = dialog.getValueObject();
- if (valueObject != null) {
- String valueType = dialog.getValueType();
- if (valueType.equals(IFacesConfigConstants.VALUE)) {
-
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) valueObject);
- managedProperty.setValue(value);
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_Value(), value);
- commands.add(cmd3);
-
- } else if (valueType.equals(IFacesConfigConstants.MAP_ENTRIES)) {
-
- MapEntriesType mapEntriesType = (MapEntriesType) valueObject;
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_MapEntries(),
- mapEntriesType);
- commands.add(cmd3);
- } else if (valueType.equals(IFacesConfigConstants.LIST_ENTRIES)) {
-
- ListEntriesType listEntriesType = (ListEntriesType) valueObject;
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_ListEntries(),
- listEntriesType);
- commands.add(cmd3);
- } else if (valueType.equals(IFacesConfigConstants.NULL_VALUE)) {
-
- NullValueType nullValue = (NullValueType) valueObject;
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- managedProperty, FacesConfigPackage.eINSTANCE
- .getManagedPropertyType_NullValue(),
- nullValue);
- commands.add(cmd3);
- }
- }
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- }
- }
- }
-
- private ManagedPropertyType createManagedPropertyFromDialog(
- AddEditManagedPropertyDialog dialog) {
-
- String propertyName = dialog.getPropertyName();
- String propertyClass = dialog.getPropertyClass();
-
- ManagedPropertyType managedProperty = FacesConfigFactory.eINSTANCE
- .createManagedPropertyType();
- PropertyNameType propertyNameType = FacesConfigFactory.eINSTANCE
- .createPropertyNameType();
- propertyNameType.setTextContent(propertyName);
- PropertyClassType propertyClassType = FacesConfigFactory.eINSTANCE
- .createPropertyClassType();
- propertyClassType.setTextContent(propertyClass);
- managedProperty.setPropertyName(propertyNameType);
- managedProperty.setPropertyClass(propertyClassType);
-
- Object valueObject = dialog.getValueObject();
- if (valueObject != null) {
- String valueType = dialog.getValueType();
- if (valueType.equals(IFacesConfigConstants.VALUE)) {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent((String) valueObject);
- managedProperty.setValue(value);
- } else if (valueType.equals(IFacesConfigConstants.MAP_ENTRIES)) {
- MapEntriesType mapEntriesType = (MapEntriesType) dialog
- .getValueObject();
- managedProperty.setMapEntries(mapEntriesType);
- } else if (valueType.equals(IFacesConfigConstants.LIST_ENTRIES)) {
- ListEntriesType listEntriesType = (ListEntriesType) dialog
- .getValueObject();
- managedProperty.setListEntries(listEntriesType);
- } else if (valueType.equals(IFacesConfigConstants.NULL_VALUE)) {
- NullValueType nullValue = (NullValueType) dialog
- .getValueObject();
- managedProperty.setNullValue(nullValue);
- }
- }
- return managedProperty;
- }
-
- private void removeButtonSelected() {
- ManagedPropertyType managedProperty = (ManagedPropertyType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- Assert.isNotNull(managedProperty);
-
- Command removeCommand = RemoveCommand.create(this.getEditingDomain(),
- this.getInput(), FacesConfigPackage.eINSTANCE
- .getManagedBeanType_ManagedProperty(), managedProperty);
-
- if (removeCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(removeCommand);
- refreshAll();
- }
- }
-
- public void setInput(Object newInput) {
- if (newInput != null && newInput instanceof ManagedBeanType) {
- managedBean = (ManagedBeanType) newInput;
- refreshAll();
- }
- }
-
- /**
- *
- */
- public void refreshAll() {
- tableViewer.setInput(getInput());
- updateButtons();
-
- }
-
- /**
- *
- */
- public void refresh() {
- tableViewer.refresh();
- updateButtons();
- }
-
- public Object getInput() {
- return managedBean;
- }
-
- private EditingDomain getEditingDomain() {
- return section.getEditingDomain();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener.selectionChanged(new SelectionChangedEvent(this, event
- .getSelection()));
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/MapEntriesEditGroup.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/MapEntriesEditGroup.java
deleted file mode 100644
index e5a41b22e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/MapEntriesEditGroup.java
+++ /dev/null
@@ -1,692 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldBase;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogFieldGroup;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.KeyClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.KeyType;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntriesType;
-import org.eclipse.jst.jsf.facesconfig.emf.MapEntryType;
-import org.eclipse.jst.jsf.facesconfig.emf.NullValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditMapEntryDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * MapEntries Editing DialogFieldGroup
- *
- * @author sfshi
- * @version
- */
-public class MapEntriesEditGroup extends DialogFieldGroup implements
- IDialogFieldGroup, ISelectionProvider, ISelectionChangedListener {
- private ClassButtonDialogField keyClassField;
-
- private ClassButtonDialogField valueClassField;
-
- private TableViewer tableViewer;
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private IProject currentProject;
-
- private Button removeButton;
-
- private Button editButton;
-
- private ManagedBeanType managedBean;
-
- private AbstractFacesConfigSection section;
-
- private List selectionChangedListeners = new ArrayList();
-
- /**
- * @param section
- */
- public MapEntriesEditGroup(AbstractFacesConfigSection section) {
- super();
- this.section = section;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#initialize()
- */
- public void initialize() {
- // TODO: initialize?
- }
-
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#layoutDialogFields(org.eclipse.ui.forms.widgets.FormToolkit,
- * org.eclipse.swt.widgets.Composite)
- */
- public void layoutDialogFields(FormToolkit toolkit, Composite parent) {
- GridData data = new GridData(GridData.FILL_BOTH);
- parent.setLayoutData(data);
-
- GridLayout gl = new GridLayout();
- gl.verticalSpacing = 0;
- gl.marginHeight = 0;
- parent.setLayout(gl);
-
- layoutMapTypeSelectionSection(toolkit, parent);
-
- createAndLayoutMapValueSection(toolkit, parent);
- }
-
- /**
- *
- */
- private void layoutMapTypeSelectionSection(FormToolkit toolkit,
- Composite container) {
-
- Composite typeSelectionSection = null;
- if (toolkit != null) {
- typeSelectionSection = toolkit.createComposite(container);
- toolkit.paintBordersFor(typeSelectionSection);
- } else {
- typeSelectionSection = SWTUtils
- .createComposite(container, SWT.NONE);
- }
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- typeSelectionSection.setLayoutData(gd);
-
- int numberOfColumns = 4;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- typeSelectionSection.setLayout(gl);
- keyClassField = new ClassButtonDialogField(getProject());
- keyClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_KeyClass);
- keyClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- ManagedBeanType managedBean1 = (ManagedBeanType) getInput();
- String className = ((ClassButtonDialogField) field)
- .getText();
- KeyClassType keyClass = FacesConfigFactory.eINSTANCE
- .createKeyClassType();
- keyClass.setTextContent(className);
- EditingDomain editingDomain = section
- .getEditingDomain();
- Command cmd;
- boolean isNew;
- if (managedBean1.getMapEntries() == null) {
- isNew = true;
- MapEntriesType mapEntries = FacesConfigFactory.eINSTANCE
- .createMapEntriesType();
- mapEntries.setKeyClass(keyClass);
- cmd = SetCommand.create(editingDomain, managedBean1,
- FacesConfigPackage.eINSTANCE
- .getManagedBeanType_MapEntries(),
- mapEntries);
- } else {
- isNew = false;
- cmd = SetCommand.create(editingDomain, managedBean1
- .getMapEntries(),
- FacesConfigPackage.eINSTANCE
- .getMapEntriesType_KeyClass(),
- keyClass);
- }
-
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- if (isNew)
- refreshAll();
- }
-
- }
- });
-
- valueClassField = new ClassButtonDialogField(getProject());
-
- valueClassField
- .setLabelText(EditorMessages.InitializationSection_MapType_ValueClass);
- valueClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- ManagedBeanType managedBean1 = (ManagedBeanType) getInput();
- String className = ((ClassButtonDialogField) field)
- .getText();
- ValueClassType valueClass = FacesConfigFactory.eINSTANCE
- .createValueClassType();
- valueClass.setTextContent(className);
- EditingDomain editingDomain = section
- .getEditingDomain();
- Command cmd;
- boolean isNew;
- if (managedBean1.getMapEntries() == null) {
- isNew = true;
- MapEntriesType mapEntries = FacesConfigFactory.eINSTANCE
- .createMapEntriesType();
- mapEntries.setValueClass(valueClass);
- cmd = SetCommand.create(editingDomain, managedBean1,
- FacesConfigPackage.eINSTANCE
- .getManagedBeanType_MapEntries(),
- mapEntries);
- } else {
- isNew = false;
- cmd = SetCommand.create(editingDomain, managedBean1
- .getMapEntries(),
- FacesConfigPackage.eINSTANCE
- .getMapEntriesType_ValueClass(),
- valueClass);
- }
-
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- if (isNew)
- refreshAll();
- }
-
- }
- });
-
- keyClassField.doFillIntoGrid(toolkit, typeSelectionSection,
- numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(keyClassField.getTextControl(toolkit,
- container));
-
- valueClassField.doFillIntoGrid(toolkit, typeSelectionSection,
- numberOfColumns);
- }
-
- /**
- * @param toolkit
- * @param parent
- */
- private void createAndLayoutMapValueSection(FormToolkit toolkit,
- Composite parent) {
- Composite mapValueSection = null;
- if (toolkit != null) {
- mapValueSection = toolkit.createComposite(parent);
- toolkit.paintBordersFor(mapValueSection);
- } else {
- mapValueSection = SWTUtils.createComposite(parent, SWT.NONE);
- }
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- mapValueSection.setLayoutData(gd);
-
- int numberOfColumns = 3;
- GridLayout gl = new GridLayout(numberOfColumns, false);
- mapValueSection.setLayout(gl);
- DialogField valuesTitle = new DialogFieldBase();
- valuesTitle
- .setLabelText(EditorMessages.InitializationSection_MapTable_Title);
-
- valuesTitle.doFillIntoGrid(toolkit, mapValueSection, numberOfColumns);
- Table table;
- if (toolkit == null) {
- table = new Table(mapValueSection, SWT.FULL_SELECTION
- | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
- } else {
- table = new Table(mapValueSection, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- }
-
- table.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
-
- }
- });
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
-
- TableColumn keyCol = new TableColumn(table, SWT.NONE);
- keyCol.setText(EditorMessages.InitializationSection_MapTable_Key);
- layout.addColumnData(new ColumnWeightData(1, true));
- keyCol.setResizable(true);
-
- TableColumn valueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol.setText(EditorMessages.InitializationSection_MapTable_Value);
- valueCol.setResizable(true);
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- section.getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(section
- .getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getMapEntryType()
- .isInstance(element);
- }
- });
-
- tableViewer.addSelectionChangedListener(this);
-
- Composite operationContainer = null;
- if (toolkit != null) {
- operationContainer = toolkit.createComposite(mapValueSection);
- } else {
- operationContainer = SWTUtils.createComposite(mapValueSection,
- SWT.NONE);
- }
- gd = new GridData(GridData.FILL_VERTICAL);
- operationContainer.setLayoutData(gd);
- gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = null;
- if (toolkit != null) {
- addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- } else {
- addButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Add_more);
- }
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- if (toolkit != null) {
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more, SWT.PUSH);
- } else {
- editButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Edit_more);
- }
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- if (toolkit != null) {
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- } else {
- removeButton = SWTUtils.createPushButton(operationContainer,
- EditorMessages.UI_Button_Remove);
- }
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
- });
- }
-
- private void addButtonSelected() {
- AddEditMapEntryDialog dialog = new AddEditMapEntryDialog(EditorPlugin
- .getActiveShell(), true);
- if (dialog.open() == Dialog.OK) {
- MapEntryType mapEntry = FacesConfigFactory.eINSTANCE
- .createMapEntryType();
- if (dialog.getKey() != null) {
- KeyType key = FacesConfigFactory.eINSTANCE.createKeyType();
- key.setTextContent(dialog.getKey());
- mapEntry.setKey(key);
- }
- if (dialog.isNullValue()) {
- NullValueType nullValue = FacesConfigFactory.eINSTANCE
- .createNullValueType();
- mapEntry.setNullValue(nullValue);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent(dialog.getValue());
- mapEntry.setValue(value);
- }
-
- EditingDomain editingDomain = section.getEditingDomain();
- Command command;
- boolean isNewMapEntries = false;
- if (managedBean.getMapEntries() == null) {
- MapEntriesType mapEntriesType = FacesConfigFactory.eINSTANCE
- .createMapEntriesType();
- mapEntriesType.getMapEntry().add(mapEntry);
- command = SetCommand.create(editingDomain, managedBean,
- FacesConfigPackage.eINSTANCE
- .getManagedBeanType_MapEntries(),
- mapEntriesType);
- isNewMapEntries = true;
- } else {
- MapEntriesType mapEntries = managedBean.getMapEntries();
-
- command = AddCommand.create(editingDomain, mapEntries,
- FacesConfigPackage.eINSTANCE
- .getMapEntriesType_MapEntry(), mapEntry);
- }
-
- if (command.canExecute()) {
- editingDomain.getCommandStack().execute(command);
- if (isNewMapEntries)
- refreshAll();
- }
-
- }
- }
-
- private void editButtonSelected() {
- if (tableViewer.getSelection() == null
- || ((IStructuredSelection) tableViewer.getSelection())
- .isEmpty()) {
- return;
- }
- MapEntryType mapEntry = (MapEntryType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- AddEditMapEntryDialog dialog = new AddEditMapEntryDialog(EditorPlugin
- .getActiveShell(), false);
- if (mapEntry.getKey() != null)
- dialog.setKey(mapEntry.getKey().getTextContent());
- if (mapEntry.getNullValue() != null)
- dialog.setNullValue(true);
- else if (mapEntry.getValue() != null)
- dialog.setValue(mapEntry.getValue().getTextContent());
-
- if (dialog.open() == Dialog.OK) {
- EditingDomain editingDomain = section.getEditingDomain();
- List commands = new ArrayList();
-
- if (mapEntry.getKey() != null) {
- Command cmd1 = SetCommand.create(editingDomain, mapEntry
- .getKey(), FacesConfigPackage.eINSTANCE
- .getKeyType_TextContent(), dialog.getKey());
- commands.add(cmd1);
-
- } else {
- KeyType keyType = FacesConfigFactory.eINSTANCE.createKeyType();
- keyType.setTextContent(dialog.getKey());
- Command cmd2 = SetCommand.create(editingDomain, mapEntry,
- FacesConfigPackage.eINSTANCE.getMapEntryType_Key(),
- keyType);
- commands.add(cmd2);
- }
-
- if (dialog.isNullValue()) {
- if (mapEntry.getValue() != null) {
- Command cmd3 = SetCommand.create(editingDomain, mapEntry,
- FacesConfigPackage.eINSTANCE
- .getMapEntryType_Value(),
- SetCommand.UNSET_VALUE);
- commands.add(cmd3);
- }
- Command cmd4 = SetCommand.create(editingDomain, mapEntry,
- FacesConfigPackage.eINSTANCE
- .getMapEntryType_NullValue(),
- FacesConfigFactory.eINSTANCE.createNullValueType());
-
- commands.add(cmd4);
- } else {
- if (mapEntry.getNullValue() != null) {
- Command cmd5 = SetCommand.create(editingDomain, mapEntry,
- FacesConfigPackage.eINSTANCE
- .getMapEntryType_NullValue(),
- SetCommand.UNSET_VALUE);
- commands.add(cmd5);
- }
-
- if (mapEntry.getValue() != null) {
- Command cmd6 = SetCommand.create(editingDomain, mapEntry
- .getValue(), FacesConfigPackage.eINSTANCE
- .getValueType_TextContent(), dialog.getValue());
- commands.add(cmd6);
- } else {
- ValueType value = FacesConfigFactory.eINSTANCE
- .createValueType();
- value.setTextContent(dialog.getValue());
- Command cmd7 = SetCommand.create(editingDomain, mapEntry,
- FacesConfigPackage.eINSTANCE
- .getMapEntryType_Value(), value);
- commands.add(cmd7);
- }
-
- }
-
- Command command = new CompoundCommand(commands);
- if (command.canExecute()) {
- editingDomain.getCommandStack().execute(command);
- tableViewer.refresh(mapEntry);
- }
-
- }
-
- }
-
- private void removeButtonSelected() {
-
- MapEntryType mapEntry = (MapEntryType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
- EditingDomain editingDomain = section.getEditingDomain();
- Command cmd = RemoveCommand.create(editingDomain, mapEntry);
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- refresh();
- }
- }
-
- /**
- * get the project according to current xml node.
- *
- * @return
- */
- private IProject getProject() {
- if (currentProject == null) {
- currentProject = (IProject) section.getPage().getEditor()
- .getAdapter(IProject.class);
- }
- return currentProject;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.common.dialogfield.DialogFieldGroup#validateDialogFields()
- */
- public IStatus[] validateDialogFields() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.IDialogFieldGroup#setInput(java.lang.Object)
- */
- public void setInput(Object newInput) {
- if (newInput != null && newInput instanceof ManagedBeanType) {
- managedBean = (ManagedBeanType) newInput;
- if (managedBean.getMapEntries() != null)
- refreshAll();
- }
- }
-
- /*package*/ void refreshAll() {
- if (managedBean.getMapEntries() != null
- && managedBean.getMapEntries().getKeyClass() != null) {
- this.keyClassField.setTextWithoutUpdate(managedBean.getMapEntries()
- .getKeyClass().getTextContent());
- } else {
- this.keyClassField.setTextWithoutUpdate(null);
- }
-
- if (managedBean.getMapEntries() != null
- && managedBean.getMapEntries().getValueClass() != null) {
- this.valueClassField.setTextWithoutUpdate(managedBean
- .getMapEntries().getValueClass().getTextContent());
- } else {
- this.valueClassField.setTextWithoutUpdate(null);
- }
-
- tableViewer.setInput(((ManagedBeanType) getInput()).getMapEntries());
- updateButtons();
- }
-
- public Object getInput() {
- return this.managedBean;
- }
-
- public void refreshData() {
- refresh();
-
- }
-
- /**
- *
- */
- public void refresh() {
- tableViewer.refresh();
- updateButtons();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#addSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void addSelectionChangedListener(ISelectionChangedListener listener) {
- selectionChangedListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#removeSelectionChangedListener(org.eclipse.jface.viewers.ISelectionChangedListener)
- */
- public void removeSelectionChangedListener(
- ISelectionChangedListener listener) {
- selectionChangedListeners.remove(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
- // do nothing
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- for (Iterator listeners = selectionChangedListeners.iterator(); listeners
- .hasNext();) {
- ISelectionChangedListener listener = (ISelectionChangedListener) listeners
- .next();
- listener.selectionChanged(new SelectionChangedEvent(this, event
- .getSelection()));
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OthersPageBaseSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OthersPageBaseSection.java
deleted file mode 100644
index 4eeca6993..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OthersPageBaseSection.java
+++ /dev/null
@@ -1,320 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-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.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-/**
- * The base class for the Sections in Others Page.
- */
-public abstract class OthersPageBaseSection extends AbstractFacesConfigSection {
-
- /**
- * Table viewer for all sections based on this calss
- */
- protected TableViewer tableViewer;
-
- private Button removeButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- * @param helpContextId
- * @param helpTooltip
- */
- public OthersPageBaseSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit, String helpContextId,
- String helpTooltip) {
- super(parent, managedForm, page, toolkit, helpContextId, helpTooltip);
- }
-
- /**
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OthersPageBaseSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- this(parent, managedForm, page, toolkit, null, null);
- }
-
- public void dispose() {
- tableViewer.removeSelectionChangedListener(this);
- tableViewer = null;
- super.dispose();
- }
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#createContents(org.eclipse.swt.widgets.Composite,
- * org.eclipse.ui.forms.widgets.FormToolkit)
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- layout.marginWidth = layout.marginHeight = 5;
- container.setLayout(layout);
- createViewer(container, toolkit);
- createOperationSection(container, toolkit);
- }
-
- /**
- * create TableViewer for this section. sub-class may override it to return
- * a new type tableViewer. for example CheckboxTableViewer.
- *
- * @param parent
- * @return the table viewer for this section
- */
- protected TableViewer createTableViewer(Composite parent) {
- return new TableViewer(parent, SWT.SINGLE | SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.BORDER);
- }
-
- /**
- * Config the viewer, such as set a filter and so on. Sub classes should
- * override this method to add filter.
- *
- * @param tableViewer1
- */
- protected abstract void configTableViewer(TableViewer tableViewer1);
-
- /**
- *
- * @param parent
- * @param toolkit
- */
- protected void createViewer(Composite parent, FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(parent);
- toolkit.paintBordersFor(tableContainer);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.heightHint = 200;
- tableContainer.setLayoutData(gd);
- tableContainer.setLayout(new GridLayout());
-
- tableViewer = createTableViewer(tableContainer);
- tableViewer.getControl()
- .setLayoutData(new GridData(GridData.FILL_BOTH));
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
- configTableViewer(tableViewer);
-
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- *
- * @param parent
- * @param toolkit
- */
- protected void createOperationSection(Composite parent, FormToolkit toolkit) {
- Composite operationContainer = toolkit.createComposite(parent);
- operationContainer.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-
- operationContainer.setLayout(new GridLayout());
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add, SWT.PUSH);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected(e);
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- addButtonSelected(e);
- }
- });
-
- setRemoveButton(toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove, SWT.PUSH));
-
- getRemoveButton().setEnabled(true);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- getRemoveButton().setLayoutData(gd);
- getRemoveButton().addSelectionListener(new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected(e);
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- removeButtonSelected(e);
- }
- });
- }
-
-
- abstract void addButtonSelected(SelectionEvent e);
-
- /**
- * Respond to selection of the remove button
- * @param e
- */
- protected void removeButtonSelected(SelectionEvent e) {
- IStructuredSelection ssel = StructuredSelection.EMPTY;
- ISelection selection = getSelection();
- if (selection instanceof IStructuredSelection) {
- ssel = (IStructuredSelection) selection;
- }
-
- if (!ssel.isEmpty()) {
- List commands = new ArrayList(ssel.size());
- for (Iterator iter = ssel.iterator(); iter.hasNext();) {
- EObject element = (EObject) iter.next();
- if (element.eContainer().eContents().size() == 1) {
- // if the parent only have this one child, then remove it
- // together.
- element = element.eContainer();
- }
- Command command = RemoveCommand.create(getEditingDomain(),
- element);
- commands.add(command);
-
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- }
- }
- }
-
- public ISelection getSelection() {
- return tableViewer.getSelection();
- }
-
- /**
- * update all buttons with the current selection
- */
- protected void updateButtons() {
- if (!getRemoveButton().isDisposed()) {
- IStructuredSelection ssel = (IStructuredSelection) getSelection();
- getRemoveButton().setEnabled(!ssel.isEmpty());
- }
- }
-
- public void refresh() {
- super.refresh();
- tableViewer.refresh();
- updateButtons();
- }
-
- public void setSelection(ISelection selection) {
- tableViewer.setSelection(selection);
- }
-
- /**
- * @return Returns the tableViewer.
- */
- public TableViewer getTableViewer() {
- return tableViewer;
- }
-
- public void refreshAll() {
- setViewerInput(getInput());
- updateButtons();
- }
-
- /**
- * set the structuredViewer's input
- *
- * @param input
- */
- abstract protected void setViewerInput(Object input);
-
- public void expansionStateChanged(boolean expanded) {
- if (expanded) {
- if (tableViewer.getInput() == null) {
- refreshAll();
- }
- tableViewer.setSelection(tableViewer.getSelection());
- } else {
- tableViewer.setSelection(null);
- }
- super.expansionStateChanged(expanded);
- }
-
- protected void expansionStateChanging(boolean expanding) {
- if (!expanding) {
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- this.getSection().setLayoutData(gd);
- } else {
- ((OthersPage) getPage()).closeOtherSections(this);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- this.getSection().setLayoutData(gd);
- }
-
- super.expansionStateChanging(expanding);
- }
-
- public void selectionChanged(SelectionChangedEvent event) {
- super.selectionChanged(event);
- updateButtons();
- }
-
- /**
- * @param removeButton
- */
- protected void setRemoveButton(Button removeButton) {
- this.removeButton = removeButton;
- }
-
- /**
- * @return the button widget
- */
- protected Button getRemoveButton() {
- return removeButton;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewComponentsSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewComponentsSection.java
deleted file mode 100644
index c7f5016eb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewComponentsSection.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.ComponentsPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- * @version
- */
-public class OverviewComponentsSection extends AbstractOverviewSection {
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OverviewComponentsSection(Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, ComponentsPage.PAGE_ID,
- EditorMessages.OverviewPage_ComponentsSection_name,
- EditorMessages.OverviewPage_ComponentsSection_description,
- null, null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#configTableViewer(org.eclipse.jface.viewers.TableViewer)
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getComponentType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE.getConverterType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE.getRenderKitType()
- .isInstance(element)
- || FacesConfigPackage.eINSTANCE.getValidatorType()
- .isInstance(element);
- }
- });
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#createTable(org.eclipse.swt.widgets.Composite)
- */
- protected Table createTable(Composite container) {
- Table table = new Table(container, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = 100;
- table.setLayoutData(gd);
-
- table.setLinesVisible(true);
- table.setHeaderVisible(true);
- TableLayout tablelayout = new TableLayout();
- table.setLayout(tablelayout);
-
- TableColumn typecol = new TableColumn(table, SWT.LEFT);
- tablelayout.addColumnData(new ColumnWeightData(1, true));
- typecol
- .setText(EditorMessages.OverviewPage_ComponentsSection_table_typecol);
- typecol.setResizable(true);
-
- TableColumn namecol = new TableColumn(table, SWT.LEFT);
- tablelayout.addColumnData(new ColumnWeightData(1, true));
- namecol
- .setText(EditorMessages.OverviewPage_ComponentsSection_table_namecol);
- namecol.setResizable(true);
-
- return table;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewGeneralSection.java
deleted file mode 100644
index 8de1c9ee0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewGeneralSection.java
+++ /dev/null
@@ -1,116 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-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.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.part.FileEditorInput;
-
-/**
- * @author jchoi, Xiao-guang Zhang
- * @version
- */
-public class OverviewGeneralSection extends AbstractFacesConfigSection {
-
- private Text versionText;
-
- /**
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OverviewGeneralSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
-
- getSection().setText(
- EditorMessages.OverviewPage_GeneralSection_name);
- getSection().setDescription(
- EditorMessages.OverviewPage_GeneralSection_description);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.update.ui.forms.internal.FormSection#createClient(org.eclipse.swt.widgets.Composite,
- * org.eclipse.update.ui.forms.internal.FormWidgetFactory)
- */
- public void createContents(Composite container, FormToolkit toolkit) {
- GridLayout layout = new GridLayout();
- layout.numColumns = 2;
- container.setLayout(layout);
-
- IEditorInput editorInput = this.getPage().getEditor().getEditorInput();
-
- toolkit.createLabel(container,
- EditorMessages.OverviewPage_GeneralSection_label_name);
- Text typeText = toolkit.createText(container, ((FileEditorInput)editorInput).getName());
- typeText.setEditable(false);
- GridData data = new GridData(GridData.FILL_HORIZONTAL);
- typeText.setLayoutData(data);
-
- toolkit.createLabel(container,
- EditorMessages.OverviewPage_GeneralSection_label_version);
- versionText = toolkit.createText(container, ""); //$NON-NLS-1$
- versionText.setLayoutData(data);
- versionText.setEditable(false);
-
- // set the service type description
- data = new GridData(GridData.FILL_HORIZONTAL);
- versionText.setLayoutData(data);
-
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = 2;
- Label sep = toolkit.createSeparator(container, SWT.HORIZONTAL);
- sep.setLayoutData(gd);
- toolkit.paintBordersFor(container);
-
- // return container;
- }
-
- public void refreshAll() {
- if (getInput() == null || !(getInput() instanceof EObject)) {
- return;
- }
-
-// FacesConfigType facesConfig = (FacesConfigType)getInput();
- // TODO get the version and display it.
- // String version = FacesConfigUtil
- // .getFacesConfigVersion((IDOMModel) getInput());
- //
- // if (null == version) {
- // Document document = ((IDOMModel) getInput()).getDocument();
- // DocumentType doctype = document.getDoctype();
- // if (doctype != null) {
- // String pid = doctype.getPublicId();
- // version = pid.substring(PUBLIC_ID.length() + 1);
- // version = version.substring(version.indexOf(VERSION_PREFIX)
- // + VERSION_PREFIX.length() + 1, version.indexOf("//"));
- // }
- // if (null == version) {
- // version = "";
- // }
- // }
- // versionText.setText(version);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewManagedBeanSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewManagedBeanSection.java
deleted file mode 100644
index c0662463d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewManagedBeanSection.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.ManagedBeanPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- * @version
- */
-public class OverviewManagedBeanSection extends AbstractOverviewSection {
-
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OverviewManagedBeanSection(Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, ManagedBeanPage.PAGE_ID,
- EditorMessages.OverviewPage_ManagedBeanSection_name,
- EditorMessages.OverviewPage_ManagedBeanSection_description,
- null, null);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#configTableViewer(org.eclipse.jface.viewers.TableViewer)
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getManagedBeanType()
- .isInstance(element);
- }
- });
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#createTable()
- */
- protected Table createTable(Composite container) {
- Table table = new Table(container, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = 100;
- table.setLayoutData(gd);
-
- table.setLinesVisible(true);
- table.setHeaderVisible(true);
- TableLayout tablelayout = new TableLayout();
- table.setLayout(tablelayout);
-
- TableColumn namecol = new TableColumn(table, SWT.LEFT);
- namecol
- .setText(EditorMessages.OverviewPage_ManagedBeanSection_table_namecol);
- tablelayout.addColumnData(new ColumnWeightData(1, true));
- namecol.setResizable(true);
-
- TableColumn scopecol = new TableColumn(table, SWT.LEFT);
- scopecol
- .setText(EditorMessages.OverviewPage_ManagedBeanSection_table_scopecol);
- tablelayout.addColumnData(new ColumnWeightData(1, true));
- scopecol.setResizable(true);
-
- TableColumn classcol = new TableColumn(table, SWT.LEFT);
- classcol
- .setText(EditorMessages.OverviewPage_ManagedBeanSection_table_classcol);
- tablelayout.addColumnData(new ColumnWeightData(1, true));
- classcol.setResizable(true);
-
- return table;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewNavigationSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewNavigationSection.java
deleted file mode 100644
index ae4bd8a84..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewNavigationSection.java
+++ /dev/null
@@ -1,403 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationCaseType;
-import org.eclipse.jst.jsf.facesconfig.emf.NavigationRuleType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.pageflow.PageflowEditor;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- *
- */
-public class OverviewNavigationSection extends AbstractOverviewSection {
-
- private static final int COLUMN_WITH = 70;
-
- private OverviewNavigationSectionAdapter overviewNavigationSectionAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OverviewNavigationSection(Composite parent,
- IManagedForm managedForm, IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, PageflowEditor.PAGE_ID,
- EditorMessages.OverviewPage_NavigationSection_name,
- EditorMessages.OverviewPage_NavigationSection_description,
- null, null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#configTableViewer(org.eclipse.jface.viewers.TableViewer)
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.setContentProvider(new IStructuredContentProvider() {
-
- public Object[] getElements(Object inputElement) {
- List navigationCaseList = (List) inputElement;
- return navigationCaseList.toArray();
- }
-
- public void dispose() {
- // nothing to dispose
- }
-
- public void inputChanged(Viewer viewer, Object oldInput,
- Object newInput) {
- // do nothing
- }
- });
-
- tableViewer1.setLabelProvider(new ITableLabelProvider() {
-
- public Image getColumnImage(Object element, int columnIndex) {
- return null;
- }
-
- public String getColumnText(Object element, int columnIndex) {
- NavigationCaseType navigationCase = (NavigationCaseType) element;
- switch (columnIndex) {
-
- case 0:
- return ((NavigationRuleType) navigationCase.eContainer())
- .getFromViewId() == null ? "" //$NON-NLS-1$
- : ((NavigationRuleType) navigationCase.eContainer())
- .getFromViewId().getTextContent();
-
- case 1:
- return navigationCase.getFromOutcome() == null ? "" //$NON-NLS-1$
- : navigationCase.getFromOutcome().getTextContent();
-
- case 2:
- return navigationCase.getToViewId() == null ? "" //$NON-NLS-1$
- : navigationCase.getToViewId().getTextContent();
- }
- return null;
- }
-
- public void addListener(ILabelProviderListener listener) {
- // no listeners?
- }
-
- public void dispose() {
- // do nothing
- }
-
- public boolean isLabelProperty(Object element, String property) {
- return false;
- }
-
- public void removeListener(ILabelProviderListener listener) {
- // no listeners?
- }
- });
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#createTable(org.eclipse.swt.widgets.Composite)
- */
- protected Table createTable(Composite container) {
- Table table = new Table(container, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER | SWT.BORDER);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = 100;
- table.setLayoutData(gd);
-
- table.setLinesVisible(true);
- table.setHeaderVisible(true);
- TableLayout tablelayout = new TableLayout();
- table.setLayout(tablelayout);
-
- TableColumn column1 = new TableColumn(table, SWT.LEFT);
- column1
- .setText(EditorMessages.OverviewPage_NavigationSection_table_col1);
- // column1.setWidth(COLUMN_WITH);
- tablelayout.addColumnData(new ColumnWeightData(1, COLUMN_WITH, true));
- // tablelayout.addColumnData(new ColumnWeightData(1, true));
- column1.setResizable(true);
-
- TableColumn column2 = new TableColumn(table, SWT.LEFT);
- column2
- .setText(EditorMessages.OverviewPage_NavigationSection_table_col2);
- tablelayout.addColumnData(new ColumnWeightData(1, COLUMN_WITH, true));
- // tablelayout.addColumnData(new ColumnWeightData(1, true));
- column2.setResizable(true);
- // column2.setWidth(COLUMN_WITH);
-
- TableColumn column3 = new TableColumn(table, SWT.LEFT);
- column3
- .setText(EditorMessages.OverviewPage_NavigationSection_table_col3);
- tablelayout.addColumnData(new ColumnWeightData(1, COLUMN_WITH, true));
- // tablelayout.addColumnData(new ColumnWeightData(1, true));
- column3.setResizable(true);
- // column3.setWidth(COLUMN_WITH);
-
- return table;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.IFacesConfigSection#refreshAll()
- */
- public void refreshAll() {
- List navigationCaseList = new ArrayList();
- if (getInput() instanceof FacesConfigType) {
- List navigationRules = ((FacesConfigType) getInput())
- .getNavigationRule();
- for (int i = 0, n = navigationRules.size(); i < n; i++) {
- NavigationRuleType navigationRule = (NavigationRuleType) navigationRules
- .get(i);
- navigationCaseList.addAll(navigationRule.getNavigationCase());
- }
- }
-
- tableViewer.setInput(navigationCaseList);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#addAdaptersOntoInput(java.lang.Object)
- */
- protected void addAdaptersOntoInput(Object newInput) {
- FacesConfigType facesConfig = (FacesConfigType) newInput;
- addOverviewNavigationSectionAdapter(facesConfig);
-
- for (Iterator it = facesConfig.getNavigationRule().iterator(); it
- .hasNext();) {
- NavigationRuleType navigationRule = (NavigationRuleType) it.next();
-
- addOverviewNavigationSectionAdapter(navigationRule);
-
- if (navigationRule.getFromViewId() != null) {
- addOverviewNavigationSectionAdapter(navigationRule
- .getFromViewId());
- }
-
- for (Iterator it2 = navigationRule.getNavigationCase().iterator(); it2
- .hasNext();) {
- NavigationCaseType navigationCase = (NavigationCaseType) it2
- .next();
- addOverviewNavigationSectionAdapter(navigationCase);
-
- if (navigationCase.getFromOutcome() != null) {
- addOverviewNavigationSectionAdapter(navigationCase
- .getFromOutcome());
- }
-
- if (navigationCase.getToViewId() != null) {
- addOverviewNavigationSectionAdapter(navigationCase
- .getToViewId());
- }
- }
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#removeAdaptersFromInput(java.lang.Object)
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- super.removeAdaptersFromInput(oldInput);
- FacesConfigType facesConfig = (FacesConfigType) oldInput;
- removeOverviewNavigationSectionAdapter(facesConfig);
-
- for (Iterator it = facesConfig.getNavigationRule().iterator(); it
- .hasNext();) {
- NavigationRuleType navigationRule = (NavigationRuleType) it.next();
-
- removeOverviewNavigationSectionAdapter(navigationRule);
-
- if (navigationRule.getFromViewId() != null) {
- removeOverviewNavigationSectionAdapter(navigationRule
- .getFromViewId());
- }
-
- for (Iterator it2 = navigationRule.getNavigationCase().iterator(); it2
- .hasNext();) {
- NavigationCaseType navigationCase = (NavigationCaseType) it2
- .next();
- removeOverviewNavigationSectionAdapter(navigationCase);
-
- if (navigationCase.getFromOutcome() != null) {
- removeOverviewNavigationSectionAdapter(navigationCase
- .getFromOutcome());
- }
-
- if (navigationCase.getToViewId() != null) {
- removeOverviewNavigationSectionAdapter(navigationCase
- .getToViewId());
- }
- }
- }
-
- }
-
- private void addOverviewNavigationSectionAdapter(EObject object) {
- if (EcoreUtil.getExistingAdapter(object,
- OverviewNavigationSection.class) == null) {
- object.eAdapters().add(getOverviewNavigationSectionAdapter());
- }
-
- }
-
- private void removeOverviewNavigationSectionAdapter(EObject object) {
- if (object != null && EcoreUtil.getExistingAdapter(object,
- OverviewNavigationSection.class) != null) {
- object.eAdapters().remove(getOverviewNavigationSectionAdapter());
- }
- }
-
- private OverviewNavigationSectionAdapter getOverviewNavigationSectionAdapter() {
- if (overviewNavigationSectionAdapter == null)
- overviewNavigationSectionAdapter = new OverviewNavigationSectionAdapter();
- return overviewNavigationSectionAdapter;
- }
-
- class OverviewNavigationSectionAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == OverviewNavigationSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
-
- if ((msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_NavigationRule()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_NavigationCase()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationRuleType_FromViewId() || msg
- .getFeature() == FacesConfigPackage.eINSTANCE
- .getFromViewIdType_TextContent())) {
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.SET) {
- if (msg.getNewValue() instanceof EObject) {
- EObject newObject = (EObject) msg.getNewValue();
- addOverviewNavigationSectionAdapter(newObject);
- }
- }
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET)
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshAll();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refreshAll();
- }
- });
- }
- return;
- }
-
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationCaseType_FromOutcome()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getNavigationCaseType_ToViewId()) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.SET) {
- if (msg.getNewValue() instanceof EObject) {
- EObject newObject = (EObject) msg.getNewValue();
- addOverviewNavigationSectionAdapter(newObject);
- }
- }
- if (msg.getEventType() == Notification.ADD
-
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
-
- NavigationCaseType navigationCase = (NavigationCaseType) msg
- .getNotifier();
- refreshViewerOnUIThread(navigationCase);
- }
- return;
- }
-
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFromOutcomeType_TextContent()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getToViewIdType_TextContent()) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- NavigationCaseType navigationCase = (NavigationCaseType) ((EObject) msg
- .getNotifier()).eContainer();
- refreshViewerOnUIThread(navigationCase);
- }
- return;
- }
-
- }
-
- private void refreshViewerOnUIThread(final NavigationCaseType navigationCase) {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- tableViewer.refresh(navigationCase);
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- tableViewer.refresh(navigationCase);
- }
- });
- }
-
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewOthersSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewOthersSection.java
deleted file mode 100644
index a1179bc79..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/OverviewOthersSection.java
+++ /dev/null
@@ -1,361 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
-import org.eclipse.jst.jsf.facesconfig.emf.FactoryType;
-import org.eclipse.jst.jsf.facesconfig.emf.LifecycleType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.page.OthersPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author sfshi
- *
- */
-public class OverviewOthersSection extends AbstractOverviewSection {
-
- private static final int COLUMN_WITH = 100;
-
- private OverviewOthersSectionAdapter overviewOthersSectionAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public OverviewOthersSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, OthersPage.PAGE_ID,
- EditorMessages.OverviewPage_OthersSection_name,
- EditorMessages.OverviewPage_OthersSection_description,
- null, null);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#configTableViewer(org.eclipse.jface.viewers.TableViewer)
- */
- protected void configTableViewer(TableViewer tableViewer1) {
- tableViewer1.setContentProvider(new IStructuredContentProvider() {
-
- public Object[] getElements(Object inputElement) {
- List othersNodesList = (List) inputElement;
- return othersNodesList.toArray();
- }
-
- public void dispose() {
- // do nothing
- }
-
- public void inputChanged(Viewer viewer, Object oldInput,
- Object newInput) {
- // do nothing
- }
- });
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#createTable(org.eclipse.swt.widgets.Composite)
- */
- protected Table createTable(Composite container) {
- Table table = new Table(container, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
-
- GridData gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = 100;
- table.setLayoutData(gd);
-
- table.setLinesVisible(true);
- table.setHeaderVisible(true);
- TableLayout tablelayout = new TableLayout();
- table.setLayout(tablelayout);
-
- TableColumn valuecol = new TableColumn(table, SWT.NONE);
- tablelayout.addColumnData(new ColumnWeightData(1, COLUMN_WITH, true));
- valuecol
- .setText(EditorMessages.OverviewPage_OthersSection_table_valuecol);
- valuecol.setResizable(true);
-
- TableColumn typecol = new TableColumn(table, SWT.NONE);
- tablelayout.addColumnData(new ColumnWeightData(1, COLUMN_WITH, true));
- typecol
- .setText(EditorMessages.OverviewPage_OthersSection_table_typecol);
- typecol.setResizable(true);
-
- return table;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractOverviewSection#refreshAll()
- */
- public void refreshAll() {
- if(getSection() == null || getSection().isDisposed()) {
- return;
- }
- List othersNodesList = new ArrayList();
- if (getInput() instanceof FacesConfigType) {
- Object[] applicationNodes = null;
- Object[] factoryNodes = null;
- Object[] lifecycleNodes = null;
- FacesConfigType facesConfig = (FacesConfigType) getInput();
- IStructuredContentProvider contentProvider = new AdapterFactoryContentProvider(
- getAdapterFactory());
- if (facesConfig.getApplication().size() > 0) {
-
- ApplicationType application = (ApplicationType) facesConfig
- .getApplication().get(0);
- applicationNodes = contentProvider.getElements(application);
-
- }
-
- if (facesConfig.getFactory().size() > 0) {
- FactoryType factory = (FactoryType) facesConfig.getFactory()
- .get(0);
- factoryNodes = contentProvider.getElements(factory);
- }
-
- if (facesConfig.getLifecycle().size() > 0) {
- LifecycleType lifecycle = (LifecycleType) facesConfig
- .getLifecycle().get(0);
- lifecycleNodes = contentProvider.getElements(lifecycle);
- }
-
- if (applicationNodes != null) {
- for (int i = 0, n = applicationNodes.length; i < n; i++) {
- othersNodesList.add(applicationNodes[i]);
- }
- }
-
- if (factoryNodes != null) {
- for (int i = 0, n = factoryNodes.length; i < n; i++) {
- othersNodesList.add(factoryNodes[i]);
- }
- }
-
- if (lifecycleNodes != null) {
- for (int i = 0, n = lifecycleNodes.length; i < n; i++) {
- othersNodesList.add(lifecycleNodes[i]);
- }
- }
- }
-
- tableViewer.setInput(othersNodesList);
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#addAdaptersOntoInput(java.lang.Object)
- */
- protected void addAdaptersOntoInput(Object newInput) {
- FacesConfigType facesConfig = (FacesConfigType) newInput;
- addOverviewOthersSectionAdapter(facesConfig);
- IStructuredContentProvider contentProvider = new AdapterFactoryContentProvider(
- getAdapterFactory());
- if (facesConfig.getApplication().size() > 0) {
- ApplicationType application = (ApplicationType) facesConfig
- .getApplication().get(0);
- addOverviewOthersSectionAdapter(application);
-
- Object[] applicationNodes = contentProvider
- .getElements(application);
- for (int i = 0, n = applicationNodes.length; i < n; i++) {
- addOverviewOthersSectionAdapter((EObject) applicationNodes[i]);
- }
-
- }
-
- if (facesConfig.getFactory().size() > 0) {
- FactoryType factory = (FactoryType) facesConfig.getFactory().get(0);
- addOverviewOthersSectionAdapter(factory);
-
- Object[] factoryNodes = contentProvider.getElements(factory);
- for (int i = 0, n = factoryNodes.length; i < n; i++) {
- addOverviewOthersSectionAdapter((EObject) factoryNodes[i]);
- }
-
- }
-
- if (facesConfig.getLifecycle().size() > 0) {
- LifecycleType lifecycle = (LifecycleType) facesConfig
- .getLifecycle().get(0);
- addOverviewOthersSectionAdapter(lifecycle);
-
- Object[] lifecycleNodes = contentProvider.getElements(lifecycle);
- for (int i = 0, n = lifecycleNodes.length; i < n; i++) {
- addOverviewOthersSectionAdapter((EObject) lifecycleNodes[i]);
- }
-
- }
-
- }
-
- private void addOverviewOthersSectionAdapter(EObject object) {
- if (EcoreUtil.getExistingAdapter(object, OverviewOthersSection.class) == null) {
- object.eAdapters().add(getOverviewOthersSectionAdapter());
- }
-
- }
-
- private void removeOverviewOthersSectionAdapter(EObject object) {
- if (EcoreUtil.getExistingAdapter(object, OverviewOthersSection.class) != null) {
- object.eAdapters().remove(getOverviewOthersSectionAdapter());
- }
- }
-
- private OverviewOthersSectionAdapter getOverviewOthersSectionAdapter() {
- if (overviewOthersSectionAdapter == null) {
- overviewOthersSectionAdapter = new OverviewOthersSectionAdapter();
- }
-
- return overviewOthersSectionAdapter;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.section.AbstractFacesConfigSection#removeAdaptersFromInput(java.lang.Object)
- */
- protected void removeAdaptersFromInput(Object oldInput) {
-
- FacesConfigType facesConfig = (FacesConfigType) oldInput;
- removeOverviewOthersSectionAdapter(facesConfig);
- IStructuredContentProvider contentProvider = new AdapterFactoryContentProvider(
- getAdapterFactory());
- if (facesConfig.getApplication().size() > 0) {
- ApplicationType application = (ApplicationType) facesConfig
- .getApplication().get(0);
- removeOverviewOthersSectionAdapter(application);
-
- Object[] applicationNodes = contentProvider
- .getElements(application);
- for (int i = 0, n = applicationNodes.length; i < n; i++) {
- removeOverviewOthersSectionAdapter((EObject) applicationNodes[i]);
- }
-
- }
-
- if (facesConfig.getFactory().size() > 0) {
- FactoryType factory = (FactoryType) facesConfig.getFactory().get(0);
- removeOverviewOthersSectionAdapter(factory);
-
- Object[] factoryNodes = contentProvider.getElements(factory);
- for (int i = 0, n = factoryNodes.length; i < n; i++) {
- removeOverviewOthersSectionAdapter((EObject) factoryNodes[i]);
- }
-
- }
-
- if (facesConfig.getLifecycle().size() > 0) {
- LifecycleType lifecycle = (LifecycleType) facesConfig
- .getLifecycle().get(0);
- removeOverviewOthersSectionAdapter(lifecycle);
-
- Object[] lifecycleNodes = contentProvider.getElements(lifecycle);
- for (int i = 0, n = lifecycleNodes.length; i < n; i++) {
- removeOverviewOthersSectionAdapter((EObject) lifecycleNodes[i]);
- }
-
- }
-
- }
-
- class OverviewOthersSectionAdapter extends AdapterImpl {
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.impl.AdapterImpl#isAdapterForType(java.lang.Object)
- */
- public boolean isAdapterForType(Object type) {
- if (type == OverviewOthersSection.class)
- return true;
- return false;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.emf.common.notify.impl.AdapterImpl#notifyChanged(org.eclipse.emf.common.notify.Notification)
- */
- public void notifyChanged(Notification msg) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Application()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Factory()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Lifecycle()
- || msg.getNotifier() instanceof ApplicationType
- || msg.getNotifier() instanceof FactoryType
- || msg.getNotifier() instanceof LifecycleType) {
-
- if (msg.getEventType() == Notification.ADD) {
- EObject newObject = (EObject) msg.getNewValue();
- if (newObject != null) {
- addOverviewOthersSectionAdapter(newObject);
- }
- }
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
-
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refreshAll();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refreshAll();
- }
- });
- }
- }
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/PropertySection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/PropertySection.java
deleted file mode 100644
index e3ca1a1a4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/PropertySection.java
+++ /dev/null
@@ -1,505 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.DefaultValueType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.PropertyType;
-import org.eclipse.jst.jsf.facesconfig.emf.SuggestedValueType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditPropertyDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * Section for properties
- *
- */
-public class PropertySection extends AbstractFacesConfigSection {
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public PropertySection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- this.getSection().setText(EditorMessages.PropertySection_Name);
- this.getSection().setDescription(
- EditorMessages.PropertySection_Description);
-
- }
-
- /**
- * @param container
- * @param toolkit
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- gl.numColumns = 2;
- container.setLayout(gl);
- GridData td = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
-
- Composite propertySection = toolkit.createComposite(container);
- GridLayout gl2 = new GridLayout();
- gl2.horizontalSpacing = 0;
- gl2.verticalSpacing = 0;
- gl2.marginWidth = 0;
- gl2.marginHeight = 0;
- gl2.numColumns = 2;
- propertySection.setLayout(gl2);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.VERTICAL_ALIGN_BEGINNING);
- propertySection.setLayoutData(gd);
-
- createTableSection(propertySection, toolkit);
- createButtonsSection(propertySection, toolkit);
-
- }
-
- /**
- * create table section
- *
- * @param container
- * @param toolkit
- */
- private void createTableSection(Composite container, FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.GRAB_HORIZONTAL);
- tableContainer.setLayoutData(gd);
- toolkit.paintBordersFor(tableContainer);
-
- GridLayout gl = new GridLayout();
- tableContainer.setLayout(gl);
-
- Table table = new Table(tableContainer, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
-
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
-
- TableColumn nameCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- nameCol.setText(EditorMessages.PropertySection_Table_NameColumn);
-
- TableColumn classCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- classCol
- .setText(EditorMessages.PropertySection_Table_ClassColumn);
-
- TableColumn valueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol
- .setText(EditorMessages.PropertySection_Table_DefaultValueColumn);
-
- TableColumn suggestedValueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- suggestedValueCol
- .setText(EditorMessages.PropertySection_Table_SuggestedValueColumn);
-
- table.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
- });
-
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
-
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getPropertyType()
- .isInstance(element);
- }
- });
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- * Update the buttons' enable and disable status
- */
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- * create property's editing buttons
- *
- * @param container
- * @param toolkit
- */
- private void createButtonsSection(Composite container, FormToolkit toolkit) {
- // create operation buttons's container
- Composite operationContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_VERTICAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- operationContainer.setLayoutData(gd);
- GridLayout gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
-
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
-
- });
- }
-
- /**
- * refresh the table viewer and update buttons.
- */
- public void refresh() {
- super.refresh();
- tableViewer.refresh();
- updateButtons();
- }
-
- /**
- *
- */
- public void refreshAll() {
- tableViewer.setInput(getInput());
- updateButtons();
-
- }
-
- /**
- * add a property.
- *
- */
- private void addButtonSelected() {
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditPropertyDialog dialog = new AddEditPropertyDialog(shell, true);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (dialog.open() == Dialog.OK) {
-
- PropertyType newProperty = FacesConfigFactory.eINSTANCE
- .createPropertyType();
-
- if (dialog.getPropertyName().length() > 0) {
- PropertyNameType propertyNameType = FacesConfigFactory.eINSTANCE
- .createPropertyNameType();
- propertyNameType.setTextContent(dialog.getPropertyName());
- newProperty.setPropertyName(propertyNameType);
- }
-
- if (dialog.getPropertyClass().length() > 0) {
- PropertyClassType propertyClassType = FacesConfigFactory.eINSTANCE
- .createPropertyClassType();
- propertyClassType.setTextContent(dialog.getPropertyClass());
- newProperty.setPropertyClass(propertyClassType);
- }
-
- if (dialog.getDefaultValue().length() > 0) {
- DefaultValueType defaultValueType = FacesConfigFactory.eINSTANCE
- .createDefaultValueType();
- defaultValueType.setTextContent(dialog.getDefaultValue());
- newProperty.setDefaultValue(defaultValueType);
- }
-
- if (dialog.getSuggestedValue().length() > 0) {
- SuggestedValueType suggestedValueType = FacesConfigFactory.eINSTANCE
- .createSuggestedValueType();
- suggestedValueType.setTextContent(dialog.getSuggestedValue());
- newProperty.setSuggestedValue(suggestedValueType);
- }
-
- Command addCommand = AddCommand.create(this.getEditingDomain(),
- getInput(), null, newProperty);
- if (addCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(addCommand);
-
- }
- }
-
- }
-
- /**
- * edit a property.
- *
- */
- private void editButtonSelected() {
-
- PropertyType property = (PropertyType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(property);
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditPropertyDialog dialog = new AddEditPropertyDialog(shell, false);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (property.getPropertyName() != null) {
- dialog.setPropertyName(property.getPropertyName().getTextContent());
- }
-
- if (property.getPropertyClass() != null) {
- dialog.setPropertyClass(property.getPropertyClass()
- .getTextContent());
- }
-
- if (property.getDefaultValue() != null) {
- dialog.setDefaultValue(property.getDefaultValue().getTextContent());
- }
-
- if (property.getSuggestedValue() != null) {
- dialog.setSuggestedValue(property.getSuggestedValue()
- .getTextContent());
- }
-
- if (dialog.open() == Dialog.OK) {
- List commands = new ArrayList(4);
-
- if (property.getPropertyName() != null) {
- Command cmd1 = SetCommand.create(this.getEditingDomain(),
- property.getPropertyName(),
- FacesConfigPackage.eINSTANCE
- .getPropertyNameType_TextContent(), dialog
- .getPropertyName());
- commands.add(cmd1);
- } else if (dialog.getPropertyName().length() > 0) {
- PropertyNameType propertyNameType = FacesConfigFactory.eINSTANCE
- .createPropertyNameType();
- propertyNameType.setTextContent(dialog.getPropertyName());
-
- Command cmd2 = AddCommand.create(this.getEditingDomain(),
- property, FacesConfigPackage.eINSTANCE
- .getPropertyType_PropertyName(),
- propertyNameType);
- commands.add(cmd2);
- }
-
- if (property.getPropertyClass() != null) {
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- property.getPropertyClass(),
- FacesConfigPackage.eINSTANCE
- .getPropertyClassType_TextContent(), dialog
- .getPropertyClass());
- commands.add(cmd3);
- } else if (dialog.getPropertyClass().length() > 0) {
- PropertyClassType propertyClassType = FacesConfigFactory.eINSTANCE
- .createPropertyClassType();
- propertyClassType.setTextContent(dialog.getPropertyClass());
-
- Command cmd4 = AddCommand.create(this.getEditingDomain(),
- property, FacesConfigPackage.eINSTANCE
- .getPropertyType_PropertyClass(),
- propertyClassType);
- commands.add(cmd4);
- }
-
- if (property.getDefaultValue() != null) {
- Command cmd5 = SetCommand.create(this.getEditingDomain(),
- property.getDefaultValue(),
- FacesConfigPackage.eINSTANCE
- .getDefaultValueType_TextContent(), dialog
- .getDefaultValue());
- commands.add(cmd5);
-
- } else if (dialog.getDefaultValue().length() > 0) {
- DefaultValueType defaultValueType = FacesConfigFactory.eINSTANCE
- .createDefaultValueType();
- defaultValueType.setTextContent(dialog.getDefaultValue());
- Command cmd6 = AddCommand.create(this.getEditingDomain(),
- property, FacesConfigPackage.eINSTANCE
- .getPropertyType_DefaultValue(),
- defaultValueType);
- commands.add(cmd6);
- }
-
- if (property.getSuggestedValue() != null) {
- Command cmd7 = SetCommand.create(this.getEditingDomain(),
- property.getSuggestedValue(),
- FacesConfigPackage.eINSTANCE
- .getSuggestedValueType_TextContent(), dialog
- .getSuggestedValue());
- commands.add(cmd7);
- } else if (dialog.getSuggestedValue().length() > 0) {
- SuggestedValueType suggestedValueType = FacesConfigFactory.eINSTANCE
- .createSuggestedValueType();
- suggestedValueType.setTextContent(dialog.getSuggestedValue());
- Command cmd8 = AddCommand.create(this.getEditingDomain(),
- property, FacesConfigPackage.eINSTANCE
- .getPropertyType_SuggestedValue(),
- suggestedValueType);
- commands.add(cmd8);
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(command);
- tableViewer.refresh(property);
-
- }
- }
-
- }
-
- /**
- * remove a property.
- *
- */
- private void removeButtonSelected() {
- PropertyType property = (PropertyType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(property);
-
- Command removeCommand = RemoveCommand.create(this.getEditingDomain(),
- getInput(), null, property);
-
- if (removeCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(removeCommand);
- refreshAll();
- }
-
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return tableViewer.getSelection();
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
-
- tableViewer.setSelection(selection);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RendererSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RendererSection.java
deleted file mode 100644
index 0d164832a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RendererSection.java
+++ /dev/null
@@ -1,531 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.command.CompoundCommand;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.ecore.EReference;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.RemoveCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.ColumnWeightData;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.ComponentFamilyType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitType;
-import org.eclipse.jst.jsf.facesconfig.emf.RendererClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.RendererType;
-import org.eclipse.jst.jsf.facesconfig.emf.RendererTypeType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.dialog.AddEditRendererDialog;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.MouseAdapter;
-import org.eclipse.swt.events.MouseEvent;
-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.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class RendererSection extends AbstractFacesConfigSection {
-
- private static final int TABLE_DEFAULT_HEIGHT = 160;
-
- private TableViewer tableViewer;
-
- private Button removeButton;
-
- private Button editButton;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public RendererSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- this.getSection().setText(EditorMessages.RendererSection_Name);
- this.getSection().setDescription(
- EditorMessages.RendererSection_Description);
-
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- GridLayout gl = new GridLayout();
- gl.horizontalSpacing = 0;
- gl.marginWidth = 0;
- gl.numColumns = 2;
- container.setLayout(gl);
- GridData td = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
-
- Composite RendererSection = toolkit.createComposite(container);
- GridLayout gl2 = new GridLayout();
- gl2.horizontalSpacing = 0;
- gl2.verticalSpacing = 0;
- gl2.marginWidth = 0;
- gl2.marginHeight = 0;
- gl2.numColumns = 2;
- RendererSection.setLayout(gl2);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.VERTICAL_ALIGN_BEGINNING);
- RendererSection.setLayoutData(gd);
-
- createTableSection(RendererSection, toolkit);
- createButtonsSection(RendererSection, toolkit);
-
- }
-
- /**
- * create table section
- *
- * @param container
- * @param toolkit
- */
- private void createTableSection(Composite container, FormToolkit toolkit) {
- Composite tableContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_BOTH
- | GridData.GRAB_HORIZONTAL);
- tableContainer.setLayoutData(gd);
- toolkit.paintBordersFor(tableContainer);
-
- GridLayout gl = new GridLayout();
- tableContainer.setLayout(gl);
-
- Table table = new Table(tableContainer, SWT.H_SCROLL | SWT.V_SCROLL
- | SWT.FULL_SELECTION | SWT.BORDER);
- gd = new GridData(GridData.FILL_BOTH);
- gd.horizontalSpan = 1;
- gd.heightHint = TABLE_DEFAULT_HEIGHT;
- table.setLayoutData(gd);
-
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- TableLayout layout = new TableLayout();
- table.setLayout(layout);
-
- TableColumn nameCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- nameCol.setText(EditorMessages.RendererSection_Table_NameColumn);
-
- TableColumn valueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- valueCol
- .setText(EditorMessages.RendererSection_Table_ComponentFamilyColumn);
-
- TableColumn suggestedValueCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- suggestedValueCol
- .setText(EditorMessages.RendererSection_Table_TypeColumn);
-
- TableColumn classCol = new TableColumn(table, SWT.NONE);
- layout.addColumnData(new ColumnWeightData(1, true));
- classCol.setText(EditorMessages.RendererSection_Table_ClassColumn);
-
- table.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- updateButtons();
- }
- });
-
- table.addMouseListener(new MouseAdapter() {
- public void mouseDoubleClick(MouseEvent e) {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0)
- editButtonSelected();
- }
- });
-
- tableViewer = new TableViewer(table);
- tableViewer.setContentProvider(new AdapterFactoryContentProvider(
- getAdapterFactory()));
- tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(
- getAdapterFactory()));
-
- tableViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getRendererType()
- .isInstance(element);
- }
- });
-
- tableViewer.addSelectionChangedListener(this);
- }
-
- /**
- * Update the buttons' enable and disable status
- */
- private void updateButtons() {
- if (((IStructuredSelection) tableViewer.getSelection()).size() > 0) {
- editButton.setEnabled(true);
- removeButton.setEnabled(true);
- } else {
- editButton.setEnabled(false);
- removeButton.setEnabled(false);
- }
- }
-
- /**
- * create buttons
- *
- * @param container
- * @param toolkit
- */
- private void createButtonsSection(Composite container, FormToolkit toolkit) {
- // create operation buttons's container
- Composite operationContainer = toolkit.createComposite(container);
- GridData gd = new GridData(GridData.FILL_VERTICAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- operationContainer.setLayoutData(gd);
- GridLayout gl = new GridLayout();
- operationContainer.setLayout(gl);
-
- Button addButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Add_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- addButton.setLayoutData(gd);
-
- editButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Edit_more,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- editButton.setLayoutData(gd);
-
- removeButton = toolkit.createButton(operationContainer,
- EditorMessages.UI_Button_Remove,
- SWT.PUSH);
- gd = new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING);
- gd.grabExcessHorizontalSpace = false;
- removeButton.setLayoutData(gd);
-
- addButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- addButtonSelected();
- }
-
- });
-
- editButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- editButtonSelected();
- }
-
- });
- removeButton.addSelectionListener(new SelectionAdapter() {
-
- public void widgetSelected(SelectionEvent e) {
- removeButtonSelected();
- }
-
- });
- }
-
- /**
- *
- * @return
- */
- private EReference getEReference() {
- EReference reference = null;
- if (getInput() instanceof RenderKitType) {
- reference = FacesConfigPackage.eINSTANCE
- .getRenderKitType_Renderer();
- }
- return reference;
- }
-
-
- /**
- *
- */
- public void refreshAll() {
- tableViewer.setInput(getInput());
- updateButtons();
-
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- tableViewer.refresh();
- updateButtons();
- }
-
- /**
- * add an Renderer.
- *
- */
- private void addButtonSelected() {
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditRendererDialog dialog = new AddEditRendererDialog(shell, this
- .getPage(), true);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (dialog.open() == Dialog.OK) {
-
- // RendererType newRenderer = dialog.getResult();
- RendererType newRenderer = FacesConfigFactory.eINSTANCE
- .createRendererType();
-
- if (dialog.getRendererName().length() > 0) {
- DisplayNameType diaplayName = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- diaplayName.setTextContent(dialog.getRendererName());
- newRenderer.getDisplayName().add(diaplayName);
- }
-
- if (dialog.getRendererClass().length() > 0) {
- RendererClassType RendererClassType = FacesConfigFactory.eINSTANCE
- .createRendererClassType();
- RendererClassType.setTextContent(dialog.getRendererClass());
- newRenderer.setRendererClass(RendererClassType);
- }
-
- if (dialog.getComponentFamily().length() > 0) {
- ComponentFamilyType componentFamilyType = FacesConfigFactory.eINSTANCE
- .createComponentFamilyType();
- componentFamilyType.setTextContent(dialog.getComponentFamily());
- newRenderer.setComponentFamily(componentFamilyType);
- }
-
- if (dialog.getRendererType().length() > 0) {
- RendererTypeType rendererType = FacesConfigFactory.eINSTANCE
- .createRendererTypeType();
- rendererType.setTextContent(dialog.getRendererType());
- newRenderer.setRendererType(rendererType);
- }
-
- Command addCommand = AddCommand.create(this.getEditingDomain(),
- getInput(), getEReference(), newRenderer);
- if (addCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(addCommand);
-
- }
- }
-
- }
-
- /**
- * edit an Renderer.
- *
- */
- private void editButtonSelected() {
-
- RendererType renderer = (RendererType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(renderer);
-
- Shell shell = EditorPlugin.getActiveShell();
-
- AddEditRendererDialog dialog = new AddEditRendererDialog(shell, this
- .getPage(), false);
- dialog.setProject((IProject) getPage().getEditor().getAdapter(
- IProject.class));
- if (renderer.getDisplayName() != null
- && renderer.getDisplayName().size() > 0) {
- String name = ((DisplayNameType) (renderer.getDisplayName().get(0)))
- .getTextContent();
- if (name == null) {
- name = ""; //$NON-NLS-1$
- }
- dialog.setRendererName(name);
- }
-
- if (renderer.getRendererClass() != null) {
- dialog.setRendererClass(renderer.getRendererClass()
- .getTextContent());
- }
-
- if (renderer.getComponentFamily() != null) {
- dialog.setComponentFamily(renderer.getComponentFamily()
- .getTextContent());
- }
-
- if (renderer.getRendererType() != null) {
- dialog.setRendererType(renderer.getRendererType().getTextContent());
- }
-
- if (dialog.open() == Dialog.OK) {
- List commands = new ArrayList(4);
-
- if (renderer.getDisplayName() != null
- && renderer.getDisplayName().size() > 0) {
- DisplayNameType diaplayName = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- diaplayName.setTextContent(dialog.getRendererName());
-
- Command cmd1 = SetCommand.create(this.getEditingDomain(),
- renderer.getDisplayName().get(0),
- FacesConfigPackage.eINSTANCE
- .getRendererType_DisplayName(), diaplayName);
- commands.add(cmd1);
- } else if (dialog.getRendererName().length() > 0) {
- DisplayNameType displayName = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayName.setTextContent(dialog.getRendererName());
-
- EList dl = renderer.getDisplayName();
- dl.add(displayName);
- Command cmd2 = AddCommand.create(this.getEditingDomain(),
- renderer.getDisplayName(), FacesConfigPackage.eINSTANCE
- .getRendererType_DisplayName(), dl);
- commands.add(cmd2);
- }
-
- if (renderer.getRendererClass() != null) {
- Command cmd3 = SetCommand.create(this.getEditingDomain(),
- renderer.getRendererClass(),
- FacesConfigPackage.eINSTANCE
- .getRendererClassType_TextContent(), dialog
- .getRendererClass());
- commands.add(cmd3);
- } else if (dialog.getRendererClass().length() > 0) {
- RendererClassType RendererClassType = FacesConfigFactory.eINSTANCE
- .createRendererClassType();
- RendererClassType.setTextContent(dialog.getRendererClass());
-
- Command cmd4 = AddCommand.create(this.getEditingDomain(),
- renderer, FacesConfigPackage.eINSTANCE
- .getRendererType_RendererClass(),
- RendererClassType);
- commands.add(cmd4);
- }
-
- if (renderer.getComponentFamily() != null) {
- Command cmd5 = SetCommand.create(this.getEditingDomain(),
- renderer.getComponentFamily(),
- FacesConfigPackage.eINSTANCE
- .getDefaultValueType_TextContent(), dialog
- .getComponentFamily());
- commands.add(cmd5);
-
- } else if (dialog.getComponentFamily().length() > 0) {
- ComponentFamilyType componentFamily = FacesConfigFactory.eINSTANCE
- .createComponentFamilyType();
- componentFamily.setTextContent(dialog.getComponentFamily());
- Command cmd6 = AddCommand.create(this.getEditingDomain(),
- renderer, FacesConfigPackage.eINSTANCE
- .getRendererType_ComponentFamily(),
- componentFamily);
- commands.add(cmd6);
- }
-
- if (renderer.getRendererType() != null) {
- Command cmd7 = SetCommand.create(this.getEditingDomain(),
- renderer.getRendererType(),
- FacesConfigPackage.eINSTANCE
- .getSuggestedValueType_TextContent(), dialog
- .getRendererType());
- commands.add(cmd7);
- } else if (dialog.getRendererType().length() > 0) {
- RendererTypeType rendererType = FacesConfigFactory.eINSTANCE
- .createRendererTypeType();
- rendererType.setTextContent(dialog.getRendererType());
- Command cmd8 = AddCommand.create(this.getEditingDomain(),
- renderer, FacesConfigPackage.eINSTANCE
- .getRendererType_RendererType(), rendererType);
- commands.add(cmd8);
- }
-
- CompoundCommand command = new CompoundCommand(commands);
- if (command.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(command);
- tableViewer.refresh(renderer);
-
- }
- }
-
- }
-
- /**
- * remove an Renderer.
- *
- */
- private void removeButtonSelected() {
- RendererType Renderer = (RendererType) ((IStructuredSelection) tableViewer
- .getSelection()).getFirstElement();
-
- Assert.isNotNull(Renderer);
-
- Command removeCommand = RemoveCommand.create(this.getEditingDomain(),
- getInput(), getEReference(), Renderer);
-
- if (removeCommand.canExecute()) {
- this.getEditingDomain().getCommandStack().execute(removeCommand);
- refreshAll();
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#getSelection()
- */
- public ISelection getSelection() {
- return tableViewer.getSelection();
- }
-
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionProvider#setSelection(org.eclipse.jface.viewers.ISelection)
- */
- public void setSelection(ISelection selection) {
-
- tableViewer.setSelection(selection);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitGeneralSection.java
deleted file mode 100644
index 58e83e7e4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitGeneralSection.java
+++ /dev/null
@@ -1,416 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class RenderkitGeneralSection extends AbstractFacesConfigSection {
-
- private StringDialogField displayNameField;
-
- private StringDialogField descriptionField;
-
- private StringDialogField renderkitIdField;
-
- private ClassButtonDialogField renderkitClassField;
-
- private RenderKitGeneralAdapter renderKitGeneralAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public RenderkitGeneralSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection()
- .setText(EditorMessages.RenderKitGeneralSection_Name);
- getSection().setDescription(
- EditorMessages.RenderKitGeneralSection_Description);
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- container.setLayout(layout);
- GridData td = new GridData(GridData.FILL_HORIZONTAL);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
- displayNameField = new StringDialogField();
- displayNameField
- .setLabelText(EditorMessages.RenderKitGeneralSection_Label_DisplayName);
- displayNameField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- displayNameField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- String newDisplayNameValue = ((StringDialogField) field)
- .getText().trim();
- Command cmd = null;
- RenderKitType Renderkit = (RenderKitType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (Renderkit.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) Renderkit
- .getDisplayName().get(0);
- cmd = SetCommand.create(editingDomain, displayName,
- FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent(),
- newDisplayNameValue);
- } else {
- DisplayNameType displayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayNameType.setTextContent(newDisplayNameValue);
- displayNameType.eAdapters().add(
- getRenderKitGeneralAdapter());
-
- cmd = AddCommand.create(editingDomain, Renderkit,
- FacesConfigPackage.eINSTANCE
- .getRenderKitType_DisplayName(),
- displayNameType);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- });
-
- descriptionField = new StringDialogField(2);
- descriptionField
- .setLabelText(EditorMessages.RenderKitGeneralSection_Label_Description);
- descriptionField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- descriptionField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String newDescriptionValue = ((StringDialogField) field)
- .getText().trim();
- newDescriptionValue = ModelUtil
- .escapeEntities(newDescriptionValue);
- Command cmd = null;
- RenderKitType Renderkit = (RenderKitType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (Renderkit.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) Renderkit
- .getDescription().get(0);
- cmd = SetCommand.create(editingDomain, description,
- FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent(),
- newDescriptionValue);
- } else {
- DescriptionType description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(newDescriptionValue);
- description.eAdapters().add(
- getRenderKitGeneralAdapter());
-
- cmd = AddCommand.create(editingDomain, Renderkit,
- FacesConfigPackage.eINSTANCE
- .getRenderKitType_Description(),
- description);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
- });
-
- renderkitIdField = new StringDialogField();
- // renderkitIdField.setRequired(true);
- renderkitIdField
- .setLabelText(EditorMessages.RenderKitGeneralSection_Label_RenderKitID);
- renderkitIdField.doFillIntoGrid(toolkit, container, numberOfColumns);
- renderkitIdField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- RenderKitIdType RenderkitId = FacesConfigFactory.eINSTANCE
- .createRenderKitIdType();
- RenderkitId.setTextContent(((StringDialogField) field)
- .getText());
-
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getRenderKitType_RenderKitId(),
- RenderkitId);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
- }
- });
-
- renderkitClassField = new ClassButtonDialogField(null);
- // renderkitClassField.setRequired(true);
- renderkitClassField
- .setLabelText(EditorMessages.RenderKitGeneralSection_Label_RenderKitClass);
- renderkitClassField.doFillIntoGrid(toolkit, container, numberOfColumns);
- renderkitClassField.setProject((IProject) getPage().getEditor()
- .getAdapter(IProject.class));
- LayoutUtil.setHorizontalGrabbing(renderkitClassField.getTextControl(
- toolkit, container));
-
- renderkitClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
-
- RenderKitClassType RenderkitClass = FacesConfigFactory.eINSTANCE
- .createRenderKitClassType();
- RenderkitClass
- .setTextContent(((StringDialogField) field)
- .getText());
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getRenderKitType_RenderKitClass(),
- RenderkitClass);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
-
- }
- });
- renderkitClassField
- .setSuperClassName(IFacesConfigConstants.RENDER_KIT_SUPER_CLASS);
- }
-
- /**
- *
- */
- public void refreshAll() {
- refresh();
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- Object input = this.getInput();
- if (input instanceof RenderKitType) {
- final RenderKitType renderkit = (RenderKitType) input;
- refreshControls(renderkit);
- }
- }
-
- private void refreshControls(RenderKitType renderkit) {
- if (renderkit.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) renderkit
- .getDisplayName().get(0);
- displayNameField.setTextWithoutUpdate(displayName
- .getTextContent());
- } else {
- displayNameField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (renderkit.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) renderkit
- .getDescription().get(0);
- String descriptionString = description.getTextContent();
- descriptionString = ModelUtil
- .unEscapeEntities(descriptionString);
- descriptionField.setTextWithoutUpdate(descriptionString);
- } else {
- descriptionField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (renderkit.getRenderKitId() != null) {
- renderkitIdField.setTextWithoutUpdate(renderkit
- .getRenderKitId().getTextContent());
- } else {
- renderkitIdField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (renderkit.getRenderKitClass() != null) {
- renderkitClassField.setTextWithoutUpdate(renderkit
- .getRenderKitClass().getTextContent());
- } else {
- renderkitClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- }
- /**
- * Add RenderKitGeneralAdapter onto <render-kit> and the first
- * <display-name> and <description> elements.
- */
- protected void addAdaptersOntoInput(Object newInput) {
- RenderKitType renderkit = (RenderKitType) newInput;
- if (EcoreUtil.getExistingAdapter(renderkit,
- RenderkitGeneralSection.class) == null) {
-
- renderkit.eAdapters().add(getRenderKitGeneralAdapter());
- }
-
- if (renderkit.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) renderkit
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- RenderkitGeneralSection.class) == null) {
-
- displayName.eAdapters().add(getRenderKitGeneralAdapter());
- }
- }
-
- if (renderkit.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) renderkit
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- RenderkitGeneralSection.class) == null) {
-
- description.eAdapters().add(getRenderKitGeneralAdapter());
- }
- }
- }
-
- /**
- * Remove RenderKitGeneralAdapter from <render-kit> and the first
- * <display-name> and <description> elements.
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- RenderKitType renderkit = (RenderKitType) oldInput;
- if (EcoreUtil.getExistingAdapter(renderkit,
- RenderkitGeneralSection.class) != null) {
- renderkit.eAdapters().remove(getRenderKitGeneralAdapter());
- }
- if (renderkit.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) renderkit
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- RenderkitGeneralSection.class) != null) {
-
- displayName.eAdapters().remove(getRenderKitGeneralAdapter());
- }
- }
-
- if (renderkit.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) renderkit
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- RenderkitGeneralSection.class) != null) {
-
- description.eAdapters().remove(getRenderKitGeneralAdapter());
- }
- }
- }
-
- /**
- *
- * @return
- */
- private Adapter getRenderKitGeneralAdapter() {
-
- if (renderKitGeneralAdapter == null) {
- renderKitGeneralAdapter = new RenderKitGeneralAdapter();
- }
- return renderKitGeneralAdapter;
- }
-
- /**
- * The adapter that will be added onto <render-kit> element, to listen the
- * events of the children that are displayed in this section, notify the
- * section to refresh.
- *
- * @author sfshi
- *
- */
- class RenderKitGeneralAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == RenderkitGeneralSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getRenderKitType_RenderKitId()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getRenderKitType_RenderKitClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getRenderKitType_Description()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getRenderKitType_DisplayName()) {
- refreshInUIThread();
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent()) {
- refreshInUIThread();
- }
- }
- }
-
- private void refreshInUIThread() {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refresh();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refresh();
- }
- });
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitMasterSection.java
deleted file mode 100644
index 513426c8d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/RenderkitMasterSection.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.RenderKitType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class RenderkitMasterSection extends FacesConfigMasterSection {
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- */
- public RenderkitMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- super(parent, managedForm, toolkit, page, null, null);
- getSection().setText(EditorMessages.RenderKitMasterSection_Name);
- getSection().setDescription(
- EditorMessages.RenderKitMasterSection_Description);
- }
-
- /**
- * Config the table viwer, set a filter for it, only the object of
- * RenderKitType will be selected.
- */
- protected void configViewer(StructuredViewer structuredViewer) {
- super.configViewer(structuredViewer);
- structuredViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getRenderKitType()
- .isInstance(element);
- }
- });
-
- }
-
- /**
- * Create a new render kit.
- */
- protected void addButtonSelected(SelectionEvent e) {
- RenderKitType Renderkit = FacesConfigFactory.eINSTANCE
- .createRenderKitType();
-
- Command command = AddCommand.create(getEditingDomain(),
- this.getInput(), FacesConfigPackage.eINSTANCE
- .getFacesConfigType_RenderKit(), Renderkit);
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- IStructuredSelection selection = new StructuredSelection(Renderkit);
- getStructuredViewer().refresh();
- getStructuredViewer().setSelection(selection);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorGeneralSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorGeneralSection.java
deleted file mode 100644
index 3b478ec78..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorGeneralSection.java
+++ /dev/null
@@ -1,416 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.common.notify.Adapter;
-import org.eclipse.emf.common.notify.Notification;
-import org.eclipse.emf.common.notify.impl.AdapterImpl;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.emf.edit.command.SetCommand;
-import org.eclipse.emf.edit.domain.EditingDomain;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldApplyListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.StringDialogField;
-import org.eclipse.jst.jsf.facesconfig.emf.DescriptionType;
-import org.eclipse.jst.jsf.facesconfig.emf.DisplayNameType;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ValidatorClassType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValidatorIdType;
-import org.eclipse.jst.jsf.facesconfig.emf.ValidatorType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.page.IFacesConfigPage;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ModelUtil;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ValidatorGeneralSection extends AbstractFacesConfigSection {
-
- private StringDialogField displayNameField;
-
- private StringDialogField descriptionField;
-
- private StringDialogField validatorIDField;
-
- private ClassButtonDialogField validatorClassField;
-
- private ValidatorGeneralAdapter validatorGeneralAdapter;
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param page
- * @param toolkit
- */
- public ValidatorGeneralSection(Composite parent, IManagedForm managedForm,
- IFacesConfigPage page, FormToolkit toolkit) {
- super(parent, managedForm, page, toolkit, null, null);
- getSection()
- .setText(EditorMessages.ValidatorGeneralSection_Name);
- getSection().setDescription(
- EditorMessages.ValidatorGeneralSection_Description);
- }
-
- /**
- *
- */
- protected void createContents(Composite container, FormToolkit toolkit) {
- int numberOfColumns = 4;
- GridLayout layout = new GridLayout(numberOfColumns, false);
- container.setLayout(layout);
- GridData td = new GridData(GridData.FILL_HORIZONTAL);
- container.setLayoutData(td);
-
- toolkit.paintBordersFor(container);
- displayNameField = new StringDialogField();
- displayNameField
- .setLabelText(EditorMessages.ValidatorGeneralSection_Label_DisplayName);
- displayNameField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- displayNameField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
-
- public void dialogFieldApplied(DialogField field) {
- String newDisplayNameValue = ((StringDialogField) field)
- .getText().trim();
- Command cmd = null;
- ValidatorType validator = (ValidatorType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (validator.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) validator
- .getDisplayName().get(0);
- cmd = SetCommand.create(editingDomain, displayName,
- FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent(),
- newDisplayNameValue);
- } else {
- DisplayNameType displayNameType = FacesConfigFactory.eINSTANCE
- .createDisplayNameType();
- displayNameType.setTextContent(newDisplayNameValue);
- displayNameType.eAdapters().add(
- getValidatorGeneralAdapter());
-
- cmd = AddCommand.create(editingDomain, validator,
- FacesConfigPackage.eINSTANCE
- .getValidatorType_DisplayName(),
- displayNameType);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
-
- });
-
- descriptionField = new StringDialogField(2);
- descriptionField
- .setLabelText(EditorMessages.ValidatorGeneralSection_Label_Description);
- descriptionField.doFillIntoGrid(toolkit, container, numberOfColumns);
-
- descriptionField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- String newDescriptionValue = ((StringDialogField) field)
- .getText().trim();
- newDescriptionValue = ModelUtil
- .escapeEntities(newDescriptionValue);
- Command cmd = null;
- ValidatorType validator = (ValidatorType) getInput();
- EditingDomain editingDomain = getEditingDomain();
- if (validator.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) validator
- .getDescription().get(0);
- cmd = SetCommand.create(editingDomain, description,
- FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent(),
- newDescriptionValue);
- } else {
- DescriptionType description = FacesConfigFactory.eINSTANCE
- .createDescriptionType();
- description.setTextContent(newDescriptionValue);
- description.eAdapters().add(
- getValidatorGeneralAdapter());
-
- cmd = AddCommand.create(editingDomain, validator,
- FacesConfigPackage.eINSTANCE
- .getValidatorType_Description(),
- description);
- }
- if (cmd.canExecute()) {
- editingDomain.getCommandStack().execute(cmd);
- }
- }
- });
-
- validatorIDField = new StringDialogField();
- // validatorIDField.setRequired(true);
- validatorIDField
- .setLabelText(EditorMessages.ValidatorGeneralSection_Label_ValidatorID);
- validatorIDField.doFillIntoGrid(toolkit, container, numberOfColumns);
- validatorIDField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
- ValidatorIdType ValidatorType = FacesConfigFactory.eINSTANCE
- .createValidatorIdType();
- ValidatorType
- .setTextContent(((StringDialogField) field)
- .getText());
-
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getValidatorType_ValidatorId(),
- ValidatorType);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
- }
- });
-
- validatorClassField = new ClassButtonDialogField(null);
- // validatorClassField.setRequired(true);
- validatorClassField
- .setLabelText(EditorMessages.ValidatorGeneralSection_Label_ValidatorClass);
- validatorClassField.setProject((IProject) getPage().getEditor()
- .getAdapter(IProject.class));
- validatorClassField.doFillIntoGrid(toolkit, container, numberOfColumns);
- LayoutUtil.setHorizontalGrabbing(validatorClassField.getTextControl(
- toolkit, container));
-
- validatorClassField
- .setDialogFieldApplyListener(new IDialogFieldApplyListener() {
- public void dialogFieldApplied(DialogField field) {
-
- ValidatorClassType ValidatorClass = FacesConfigFactory.eINSTANCE
- .createValidatorClassType();
- ValidatorClass
- .setTextContent(((StringDialogField) field)
- .getText());
- EditingDomain editingDomain = getEditingDomain();
- if (editingDomain != null) {
- Command command = SetCommand.create(editingDomain,
- getInput(), FacesConfigPackage.eINSTANCE
- .getValidatorType_ValidatorClass(),
- ValidatorClass);
- if (command.canExecute()) {
- editingDomain.getCommandStack()
- .execute(command);
- }
- }
-
- }
- });
- validatorClassField
- .setInterface(IFacesConfigConstants.VALIDATOR_INTERFACE);
- }
-
- /**
- *
- */
- public void refreshAll() {
- refresh();
- }
-
- /**
- *
- */
- public void refresh() {
- super.refresh();
- Object input = this.getInput();
- if (input instanceof ValidatorType) {
- final ValidatorType validator = (ValidatorType) input;
- refreshControls(validator);
- }
- }
-
- private void refreshControls(final ValidatorType validator) {
- if (validator.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) validator
- .getDisplayName().get(0);
- displayNameField.setTextWithoutUpdate(displayName
- .getTextContent());
- } else {
- displayNameField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (validator.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) validator
- .getDescription().get(0);
- String descriptionString = description.getTextContent();
- descriptionString = ModelUtil
- .unEscapeEntities(descriptionString);
- descriptionField.setTextWithoutUpdate(descriptionString);
- } else {
- descriptionField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (validator.getValidatorId() != null) {
- validatorIDField.setTextWithoutUpdate(validator
- .getValidatorId().getTextContent());
- } else {
- validatorIDField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- if (validator.getValidatorClass() != null) {
- validatorClassField.setTextWithoutUpdate(validator
- .getValidatorClass().getTextContent());
- } else {
- validatorClassField.setTextWithoutUpdate(""); //$NON-NLS-1$
- }
-
- }
-
- /**
- * Add ValidatorGeneralAdapter onto <validator> and the first <display-name>
- * and <description> elements.
- */
- protected void addAdaptersOntoInput(Object newInput) {
- ValidatorType validator = (ValidatorType) newInput;
- if (EcoreUtil.getExistingAdapter(validator,
- ValidatorGeneralSection.class) == null) {
-
- validator.eAdapters().add(getValidatorGeneralAdapter());
- }
-
- if (validator.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) validator
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ValidatorGeneralSection.class) == null) {
-
- displayName.eAdapters().add(getValidatorGeneralAdapter());
- }
- }
-
- if (validator.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) validator
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ValidatorGeneralSection.class) == null) {
-
- description.eAdapters().add(getValidatorGeneralAdapter());
- }
- }
- }
-
- /**
- * Remove ValidatorGeneralAdapter from <validator> and the first
- * <display-name> and <description> elements.
- */
- protected void removeAdaptersFromInput(Object oldInput) {
- ValidatorType validator = (ValidatorType) oldInput;
- if (EcoreUtil.getExistingAdapter(validator,
- ValidatorGeneralSection.class) != null) {
- validator.eAdapters().remove(getValidatorGeneralAdapter());
- }
- if (validator.getDisplayName().size() > 0) {
- DisplayNameType displayName = (DisplayNameType) validator
- .getDisplayName().get(0);
- if (EcoreUtil.getExistingAdapter(displayName,
- ValidatorGeneralSection.class) != null) {
-
- displayName.eAdapters().remove(getValidatorGeneralAdapter());
- }
- }
-
- if (validator.getDescription().size() > 0) {
- DescriptionType description = (DescriptionType) validator
- .getDescription().get(0);
- if (EcoreUtil.getExistingAdapter(description,
- ValidatorGeneralSection.class) != null) {
-
- description.eAdapters().remove(getValidatorGeneralAdapter());
- }
- }
- }
-
- /**
- *
- * @return
- */
- private Adapter getValidatorGeneralAdapter() {
-
- if (validatorGeneralAdapter == null) {
- validatorGeneralAdapter = new ValidatorGeneralAdapter();
- }
- return validatorGeneralAdapter;
- }
-
- /**
- * The adapter that will be added onto <validator> element, to listen the
- * events of the children that are displayed in this section, notify the
- * section to refresh.
- *
- * @author sfshi
- *
- */
- class ValidatorGeneralAdapter extends AdapterImpl {
-
- public boolean isAdapterForType(Object type) {
- if (type == ValidatorGeneralSection.class)
- return true;
- return false;
- }
-
- public void notifyChanged(Notification msg) {
-
- if (msg.getEventType() == Notification.ADD
- || msg.getEventType() == Notification.REMOVE
- || msg.getEventType() == Notification.SET) {
- if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getValidatorType_ValidatorId()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getValidatorType_ValidatorClass()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getValidatorType_Description()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getValidatorType_DisplayName()) {
- refreshInUIThread();
- } else if (msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDisplayNameType_TextContent()
- || msg.getFeature() == FacesConfigPackage.eINSTANCE
- .getDescriptionType_TextContent()) {
- refreshInUIThread();
- }
- }
- }
- private void refreshInUIThread() {
- if (Thread.currentThread() == PlatformUI.getWorkbench().getDisplay().getThread()) {
- refresh();
- } else {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() {
- public void run() {
- refresh();
- }
- });
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorMasterSection.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorMasterSection.java
deleted file mode 100644
index 89f3298aa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/section/ValidatorMasterSection.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.section;
-
-import org.eclipse.emf.common.command.Command;
-import org.eclipse.emf.edit.command.AddCommand;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.emf.ValidatorType;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorMessages;
-import org.eclipse.jst.jsf.facesconfig.ui.page.FacesConfigMasterDetailPage;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * @author Bryan Yang
- *
- */
-public class ValidatorMasterSection extends FacesConfigMasterSection {
-
- /**
- *
- * @param parent
- * @param managedForm
- * @param toolkit
- * @param page
- */
- public ValidatorMasterSection(Composite parent, IManagedForm managedForm,
- FormToolkit toolkit, FacesConfigMasterDetailPage page) {
- super(parent, managedForm, toolkit, page, null, null);
- getSection().setText(EditorMessages.ValidatorMasterSection_Name);
- getSection().setDescription(
- EditorMessages.ValidatorMasterSection_Description);
- }
-
- /**
- * Config the table viwer, set a filter for it, only the object of
- * ValidatorType will be selected.
- */
- protected void configViewer(StructuredViewer structuredViewer) {
- super.configViewer(structuredViewer);
- structuredViewer.addFilter(new ViewerFilter() {
- public boolean select(Viewer viewer, Object parentElement,
- Object element) {
- return FacesConfigPackage.eINSTANCE.getValidatorType()
- .isInstance(element);
- }
- });
-
- }
-
- /**
- * Create a new Validator.
- */
- protected void addButtonSelected(SelectionEvent e) {
- ValidatorType Validator = FacesConfigFactory.eINSTANCE
- .createValidatorType();
-
- Command command = AddCommand.create(getEditingDomain(),
- this.getInput(), FacesConfigPackage.eINSTANCE
- .getFacesConfigType_Validator(), Validator);
-
- if (command.canExecute()) {
- getEditingDomain().getCommandStack().execute(command);
- IStructuredSelection selection = new StructuredSelection(Validator);
- getStructuredViewer().refresh();
- getStructuredViewer().setSelection(selection);
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanProperty.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanProperty.java
deleted file mode 100644
index fcd01ca15..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanProperty.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import org.eclipse.jdt.core.IMethod;
-
-/**
- * This class is used to encapsulate the property following the java bean's
- * spec.
- *
- * @author xgzhang
- * @version
- */
-public class JavaBeanProperty {
- private String name;
-
- private String qualifiedType;
-
- private String signatureType;
-
- private IMethod getterMethod;
-
- private IMethod setterMethod;
-
- /**
- * @param name
- * @param signatureType
- * @param getterMethod
- * @param setterMethod
- */
- public JavaBeanProperty(String name, String signatureType,
- IMethod getterMethod, IMethod setterMethod) {
- this.name = name;
- this.signatureType = signatureType;
-
- this.getterMethod = getterMethod;
- this.setterMethod = setterMethod;
- }
-
- /**
- * @return Returns the name.
- */
- public String getName() {
- return name;
- }
-
- /**
- * @return Returns the setterMethod.
- */
- public IMethod getSetterMethod() {
- return setterMethod;
- }
-
- /**
- * @return Returns the setterMethod.
- */
- public IMethod getGetterMethod() {
- return getterMethod;
- }
-
- /**
- * @return Returns the type.
- */
- public String getQualifiedType() {
- if (qualifiedType == null) {
- IMethod getterSetterMethod = getterMethod != null ? getterMethod
- : setterMethod;
-
- qualifiedType = JavaClassUtils.getQualifiedTypeNameInTypeHierarchy(
- getterSetterMethod.getDeclaringType(), signatureType);
- }
- return qualifiedType;
- }
-
- /**
- * @return Returns the signatureType.
- */
- public String getSignatureType() {
- return signatureType;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanUtils.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanUtils.java
deleted file mode 100644
index 83c36cf24..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaBeanUtils.java
+++ /dev/null
@@ -1,775 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import java.beans.Introspector;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.jdt.core.IMethod;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.Signature;
-import org.eclipse.jst.jsf.common.ui.internal.utils.JavaModelUtil;
-
-/**
- * This utility class is used to access java bean class, e.g., get java bean's
- * property
- *
- * @author xgzhang
- * @version
- */
-public final class JavaBeanUtils {
- /**
- * fully qualified name of a List
- */
- private static final String JAVA_UTIL_LIST = "java.util.List"; //$NON-NLS-1$
-
- /**
- * fully qualifed name of a Map
- */
- private static final String JAVA_UTIL_MAP = "java.util.Map"; //$NON-NLS-1$
-
- /**
- *
- */
- private JavaBeanUtils() {
- super();
- }
-
- /**
- * get the getter method according to property name
- *
- * @param type
- * @param propertyName
- * @return - can be <b>null</b>, if not found
- * @throws JavaModelException
- * @throws JavaModelException
- */
- private static IMethod getPropertyGetterMethod(IType type,
- String propertyName) {
- if (type == null || !type.exists() || propertyName == null) {
- return null;
- }
- IMethod getterMethod = null;
-
- String methodBaseName = null;
- // Uppercase 1st letter
- if (propertyName.length() == 1) {
- methodBaseName = propertyName.substring(0, 1).toUpperCase();
- } else {
- methodBaseName = propertyName.substring(0, 1).toUpperCase()
- + propertyName.substring(1);
- }
-
- String getterMethodName = "get" + methodBaseName; //$NON-NLS-1$
-
- getterMethod = type.getMethod(getterMethodName, null);
- if (getterMethod == null || !getterMethod.exists()
- || !JavaClassUtils.isPublicMethod(getterMethod)) {
- getterMethodName = "is" + methodBaseName; //$NON-NLS-1$
- getterMethod = type.getMethod(getterMethodName, null);
-
- if (getterMethod == null || !getterMethod.exists()
- || !JavaClassUtils.isPublicMethod(getterMethod)) {
- getterMethod = null;
- }
- }
- return getterMethod;
- }
-
- /**
- * get the getter method in the type hierarchy according to property name
- *
- * @param type
- * @param propertyName
- * @return - can be <b>null</b>, if not found
- * @throws JavaModelException
- * @throws JavaModelException
- */
- private static IMethod getPropertyGetterMethodInTypeHierarchy(IType type,
- String propertyName) throws JavaModelException {
- if (type == null || !type.exists() || propertyName == null) {
- return null;
- }
- IMethod getterMethod = null;
-
- getterMethod = getPropertyGetterMethod(type, propertyName);
-
- if (getterMethod == null) {
- ITypeHierarchy typeHierarchy = null;
- typeHierarchy = type.newSupertypeHierarchy(null);
-
- if (typeHierarchy == null) {
- return null;
- }
-
- IType[] superTypes = typeHierarchy.getAllSuperclasses(type);
-
- if (superTypes == null || superTypes.length == 0) {
- return null;
- }
- for (int i = 0; i < superTypes.length; i++) {
- if (!superTypes[i].getFullyQualifiedName().equals(
- "java.lang.Object")) { //$NON-NLS-1$
- getterMethod = getPropertyGetterMethod(superTypes[i],
- propertyName);
- if (getterMethod != null) {
- break;
- }
- }
- }
- }
- return getterMethod;
- }
-
- /**
- * get the setter method in the type hierarchy according to property name
- *
- * @param type
- * @param propertyName
- * @return - can be <b>null</b>, if not found
- * @throws JavaModelException
- */
- private static IMethod getPropertySetterMethodInTypeHierarchy(IType type,
- String propertyName) throws JavaModelException {
- if (type == null || !type.exists() || propertyName == null) {
- return null;
- }
- IMethod setterMethod = null;
-
- setterMethod = getPropertySetterMethod(type, propertyName);
-
- if (setterMethod == null) {
- ITypeHierarchy typeHierarchy = null;
- typeHierarchy = type.newSupertypeHierarchy(null);
-
- if (typeHierarchy == null) {
- return null;
- }
-
- IType[] superTypes = typeHierarchy.getAllSuperclasses(type);
-
- if (superTypes == null || superTypes.length == 0) {
- return null;
- }
- for (int i = 0; i < superTypes.length; i++) {
- if (!superTypes[i].getFullyQualifiedName().equals(
- "java.lang.Object")) { //$NON-NLS-1$
- setterMethod = getPropertySetterMethod(superTypes[i],
- propertyName);
- if (setterMethod != null) {
- break;
- }
- }
- }
- }
-
- return setterMethod;
- }
-
- /**
- * get the setter method according to property name
- *
- * @param type
- * @param propertyName
- * @return - can be <b>null</b>, if not found
- * @throws JavaModelException
- */
- private static IMethod getPropertySetterMethod(IType type,
- String propertyName) throws JavaModelException {
- if (type == null || !type.exists() || propertyName == null) {
- return null;
- }
- IMethod setterMethod = null;
-
- String methodBaseName = null;
- // Uppercase 1st letter
- if (propertyName.length() == 1) {
- methodBaseName = propertyName.substring(0, 1).toUpperCase();
- } else {
- methodBaseName = propertyName.substring(0, 1).toUpperCase()
- + propertyName.substring(1);
- }
-
- String setterMethodName = "set" + methodBaseName; //$NON-NLS-1$
-
- IMethod[] methods = null;
-
- methods = type.getMethods();
-
- if (methods == null || methods.length == 0) {
- return null;
- }
-
- for (int i = 0; i < methods.length; i++) {
- if (methods[i].getElementName().equals(setterMethodName)) {
- if (methods[i] == null || !methods[i].exists()
- || !JavaClassUtils.isPublicMethod(methods[i])) {
- continue;
- }
-
- // Method must return void
- String returnType = methods[i].getReturnType();
- if (!returnType.equals(Signature.SIG_VOID)) {
- continue;
- }
-
- String params[] = methods[i].getParameterTypes();
- // method must have only one argument
- if (params.length != 1) {
- continue;
- }
- setterMethod = methods[i];
- }
- }
-
- return setterMethod;
- }
-
- /**
- * Check whether the propertyName is bean's property or not.
- *
- * @param baseType
- * @param propertyName
- *
- * @return - True means the property name is valid bean's property,
- * otherwise, not.
- *
- */
- public static boolean isBeanProperty(IType baseType, String propertyName)
- {
- if (baseType == null || !baseType.exists() || propertyName == null) {
- return false;
- }
-
- return (getBeanPropertyType(baseType, propertyName) != null);
- }
-
- /**
- * get the bean's property type
- *
- * @param baseType
- * @param propertyName
- * @return - can be <b>null</b>, if not found
- *
- */
- public static IType getBeanPropertyType(IType baseType, String propertyName) {
- if (baseType == null || !baseType.exists() || propertyName == null) {
- return null;
- }
-
- String typeSignature = null;
- IMethod getterMethod = null;
- IMethod setterMethod = null;
-
- IType declaredType = baseType;
- try {
- getterMethod = getPropertyGetterMethodInTypeHierarchy(baseType,
- propertyName);
- setterMethod = getPropertySetterMethodInTypeHierarchy(baseType,
- propertyName);
- } catch (JavaModelException e1) {
- // Need not any error handling.
- }
-
- if (getterMethod != null && setterMethod == null) {
- declaredType = getterMethod.getDeclaringType();
- try {
- typeSignature = getterMethod.getReturnType();
- } catch (JavaModelException e2) {
- // Need not any error handling.
- }
- } else if (setterMethod != null && getterMethod == null) {
- declaredType = setterMethod.getDeclaringType();
- typeSignature = setterMethod.getParameterTypes()[0];
- } else if (setterMethod != null && getterMethod != null) {
- declaredType = getterMethod.getDeclaringType();
- try {
- // FIXME: should check the type hierachy
- if (getterMethod.getReturnType().equals(
- setterMethod.getParameterTypes()[0])) {
- typeSignature = getterMethod.getReturnType();
- }
- } catch (JavaModelException e2) {
- // Need not any error handling.
- }
- }
-
- if (typeSignature == null) {
- return null;
- }
-
- IType type = null;
-
- try {
- String typeName = JavaModelUtil.getResolvedTypeName(typeSignature,
- declaredType);
- if (typeName != null) {
- type = baseType.getJavaProject().findType(typeName);
- }
- } catch (JavaModelException e) {
- // Need not any error handling.
- }
- return type;
- }
-
- /**
- * get the bean's property's getter and setter methods.
- *
- * @param baseType
- * @param propertyName
- * @return - IMethod[], the first is getter and the second is setter method,
- * however, both of them can be null.
- */
- public static IMethod[] getBeanPropertyMethods(IType baseType,
- String propertyName) {
- if (baseType == null || !baseType.exists() || propertyName == null) {
- return null;
- }
-
- IMethod[] methods = new IMethod[2];
-
- IMethod getterMethod = null;
- IMethod setterMethod = null;
- try {
- getterMethod = getPropertyGetterMethodInTypeHierarchy(baseType,
- propertyName);
-
- setterMethod = getPropertySetterMethodInTypeHierarchy(baseType,
- propertyName);
- } catch (JavaModelException e) {
- // Need not any error handling.
- }
-
- if (getterMethod != null && setterMethod == null) {
- methods[0] = getterMethod;
- } else if (setterMethod != null && getterMethod == null) {
- methods[1] = setterMethod;
- } else if (setterMethod != null && getterMethod != null) {
- try {
- // FIXME: should check the type hierachy
- if (getterMethod.getReturnType().equals(
- setterMethod.getParameterTypes()[0])) {
- methods[0] = getterMethod;
- methods[1] = setterMethod;
- }
- } catch (JavaModelException e1) {
- // Need not any error handling.
- }
- }
-
- return methods;
- }
-
- /**
- * check whether the type implements <code>java.util.List</code>
- *
- * @param type
- * @return - True if the type is the sub class of
- * <code>java.util.List</code>, otherwise, not.
- */
- public static boolean isListType(IType type) {
- if (type == null) {
- return false;
- }
- if (type.getFullyQualifiedName().equalsIgnoreCase(JAVA_UTIL_LIST)) {
- return true;
- }
-
- return JavaClassUtils.isSubClassOf(type.getJavaProject(), type
- .getFullyQualifiedName(), JAVA_UTIL_LIST);
- }
-
- /**
- * check whether the type implements <code>java.util.Map</code>
- *
- * @param type
- * @return - True if the type is the sub class of <code>java.uitl.Map</code>,
- * otherwise, not.
- */
- public static boolean isMapType(IType type) {
- if (type == null) {
- return false;
- }
- if (type.getFullyQualifiedName().equalsIgnoreCase(JAVA_UTIL_MAP)) {
- return true;
- }
-
- return JavaClassUtils.isSubClassOf(type.getJavaProject(), type
- .getFullyQualifiedName(), JAVA_UTIL_MAP);
- }
-
- /**
- * Test for method inclusion in bindings list.
- * <p>
- * This test has the following conditions:
- * </p>
- * <ul>
- * <li>method starts with <code>get</code></li>
- * <li>method has no arguments</li>
- * <li>method does not return void</li>
- * </ul>
- *
- * @param method -
- * the IMethod to examine
- * @return boolean - true, if method satisfies the condition test
- */
- public static boolean isGetterMethod(IMethod method) {
- try {
- if (!JavaClassUtils.isPublicMethod(method)) {
- return false;
- }
- String params[] = method.getParameterTypes();
- // Has no arguments
- if (params.length > 0) {
- return false;
- }
-
- // Starts with "get"
- if (!(method.getElementName().startsWith("get") || method.getElementName().startsWith("is"))) //$NON-NLS-1$ //$NON-NLS-2$
- {
- return false;
- }
- // Does not return void
- String rtn = method.getReturnType();
- if (!rtn.equals(Signature.SIG_VOID)) {
- return true;
- }
- } catch (JavaModelException e) {
- // Need not any error handling.
- }
- return false;
- }
-
- /**
- * Test for method inclusion in bindings list.
- * <p>
- * This test has the following conditions:
- * </p>
- * <ul>
- * <li>method starts with <code>set</code></li>
- * <li>method returns void</li>
- * </ul>
- *
- * @param method -
- * the IMethod to examine
- * @return boolean - true, if method satisfies the condition test
- */
- public static boolean isSetterMethod(IMethod method) {
- try {
- if (!JavaClassUtils.isPublicMethod(method)) {
- return false;
- }
- // Starts with "set"
- if (!method.getElementName().startsWith("set")) //$NON-NLS-1$
- {
- return false;
- }
-
- // the parameter's number should be one.
- if (method.getParameterTypes().length != 1) {
- return false;
- }
- // Returns void
- String rtn = method.getReturnType();
- if (rtn.equals(Signature.SIG_VOID)) {
- return true;
- }
- } catch (JavaModelException e) {
- // Need not any error handling.
- }
- return false;
- }
-
- /**
- * set the first character into low case.
- *
- * @param str
- * @return str with the first char lower cased
- */
- public static String toLowCaseFirstChar(String str) {
- // change the first alphabet to lowcase.
- if (str != null && str.length() > 0) {
- if (str.length() == 1) {
- str = str.toLowerCase();
- } else {
- str = str.substring(0, 1).toLowerCase() + str.substring(1);
- }
- }
- return str;
- }
-
- /**
- * set the first character into low case.
- *
- * @param str
- * @return str with the first char upper-cased
- */
- public static String toUpperCaseFirstChar(String str) {
- // change the first alphabet to lowcase.
- if (str != null && str.length() > 0) {
- if (str.length() == 1) {
- str = str.toUpperCase();
- } else {
- str = str.substring(0, 1).toUpperCase() + str.substring(1);
- }
- }
- return str;
- }
-
- /**
- * get property name from getter method.
- *
- * @param method
- * @return - can be <b>null</b>, if the method is not a valid getter method
- */
- public static String getPropertyNameFromGetterMethod(IMethod method) {
- if (!isGetterMethod(method)) {
- return null;
- }
- String methodName = method.getElementName();
- String propertyName = null;
- // Starts with "get"
- if (methodName.startsWith("get") && methodName.length() > 3) { //$NON-NLS-1$
- propertyName = methodName.substring(3);
- } else if (methodName.startsWith("is") && methodName.length() > 2) // Starts //$NON-NLS-1$
- // with
- // "is"
- {
- propertyName = methodName.substring(2);
- }
- propertyName = Introspector.decapitalize(propertyName);
- return propertyName;
- }
-
- /**
- * get property name from setter class.
- *
- * @param method
- * @return - can be <b>null</b>, if the method is not a valid setter method
- */
- public static String getPropertyNameFromSetterMethod(IMethod method) {
- if (!isSetterMethod(method)) {
- return null;
- }
- String methodName = method.getElementName();
- String propertyName = null;
- // Starts with "get"
- if (methodName.startsWith("set") && methodName.length() > 3) { //$NON-NLS-1$
- propertyName = methodName.substring(3);
- }
- propertyName = Introspector.decapitalize(propertyName);
- return propertyName;
- }
-
- /**
- * get the method with the same parameters
- *
- * @param methods
- * @param visitedMethods
- * @param foundMethod
- * @param foundMethodName
- * @param foundParamTypes
- * @return
- */
- private static IMethod getMethodWithSameParamters(IMethod[] methods,
- Map visitedMethods, IMethod foundMethod, String foundMethodName,
- String[] foundParamTypes) {
- // get all qualified type name for the found method's parameters.
- String[] foundParamQulifiedTypeNames = null;
- if (foundParamTypes != null && foundParamTypes.length > 0) {
- foundParamQulifiedTypeNames = new String[foundParamTypes.length];
- for (int i = 0; i < foundParamTypes.length; i++) {
- foundParamQulifiedTypeNames[i] = JavaClassUtils
- .getQualifiedTypeNameInTypeHierarchy(foundMethod
- .getDeclaringType(), foundParamTypes[i]);
- }
- }
- for (int i = 0; i < methods.length; i++) {
- if (visitedMethods.get(methods[i]) != null) {
- continue;
- }
-
- if (!methods[i].getElementName().equals(foundMethodName)) {
- continue;
- }
- if (methods[i].getParameterTypes() == null
- && foundParamTypes == null) {
- return methods[i];
- } else if (methods[i].getParameterTypes() != null
- && foundParamTypes != null
- && foundParamTypes.length == methods[i].getParameterTypes().length) {
- boolean bSameParams = true;
- String[] methodParamTypes = methods[i].getParameterTypes();
- for (int j = 0; j < foundParamQulifiedTypeNames.length; j++) {
- String methodParamQualifiedTypeName = JavaClassUtils
- .getQualifiedTypeNameInTypeHierarchy(methods[i]
- .getDeclaringType(), methodParamTypes[j]);
- // if the qualified type name is not same or not subclass or
- // supper class between each other.
- if (!methodParamQualifiedTypeName
- .equals(foundParamQulifiedTypeNames[j])
- && !JavaClassUtils.isSubClassOf(methods[i]
- .getJavaProject(),
- methodParamQualifiedTypeName,
- foundParamQulifiedTypeNames[j])
- && !JavaClassUtils.isSubClassOf(methods[i]
- .getJavaProject(),
- foundParamQulifiedTypeNames[j],
- methodParamQualifiedTypeName)) {
- bSameParams = false;
- break;
- }
- }
- if (bSameParams) {
- return methods[i];
- }
- }
- }
- return null;
- }
-
- /**
- * Creates an array of bean properties
- *
- *
- * @param classType
- * @return it can be <b>null</b>, if property is not found.
- */
- public static JavaBeanProperty[] getBeanProperties(IType classType) {
- IMethod[] methods;
- try {
- methods = JavaClassUtils.getMethods(classType);
- } catch (JavaModelException e2) {
- return null;
- }
-
- return getBeanProperties(classType, methods);
- }
-
- /**
- * Creates an array of bean properties
- *
- * @param type
- * @param methods
- *
- * @return - the array of java bean properties.
- */
- public static JavaBeanProperty[] getBeanProperties(IType type,
- IMethod[] methods) {
- if (methods == null || methods.length == 0) {
- return null;
- }
-
- List properties = new ArrayList();
- Map visitedMethods = new HashMap();
- for (int m = 0; m < methods.length; m++) {
- String propertyName = null;
- // if a property's getter method or setter method already visited,
- // just skip it.
- if (visitedMethods.get(methods[m]) != null) {
- continue;
- }
-
- visitedMethods.put(methods[m], methods[m]);
-
- // Check getter firstly
- propertyName = JavaBeanUtils
- .getPropertyNameFromGetterMethod(methods[m]);
-
- if (propertyName != null && propertyName.length() > 0)
- {
- String setterMethodName = "set" //$NON-NLS-1$
- + JavaBeanUtils.toUpperCaseFirstChar(propertyName);
-
- String getterReturnType = null;
- try {
- getterReturnType = methods[m].getReturnType();
- } catch (JavaModelException e1) {
- continue;
- }
- IMethod setterMethod = getMethodWithSameParamters(methods,
- visitedMethods, methods[m], setterMethodName,
- new String[] { getterReturnType });
- if (setterMethod != null && setterMethod.exists()) {
- visitedMethods.put(setterMethod, setterMethod);
- }
-
- properties.add(new JavaBeanProperty(propertyName,
- getterReturnType, methods[m], setterMethod));
- continue;
- }
-
- // Check setter secondly.
- propertyName = JavaBeanUtils
- .getPropertyNameFromSetterMethod(methods[m]);
-
- if (propertyName != null && propertyName.length() > 0)
- {
- // first form of getter method, "get..."
- String getterMethodName = "get" //$NON-NLS-1$
- + JavaBeanUtils.toUpperCaseFirstChar(propertyName);
- IMethod getterMethod = getMethodWithSameParamters(methods,
- visitedMethods, methods[m], getterMethodName, null);
-
- if (getterMethod != null && getterMethod.exists()) {
- try {
- if (getterMethod.getReturnType().equals(
- methods[m].getParameterTypes()[0])) {
- visitedMethods.put(getterMethod, getterMethod);
- }
- } catch (JavaModelException e) {
- // need not error logging
- }
- } else {
- // another form of getter method, "is...".
- getterMethodName = "is" //$NON-NLS-1$
- + JavaBeanUtils.toUpperCaseFirstChar(propertyName);
- getterMethod = getMethodWithSameParamters(methods,
- visitedMethods, methods[m], getterMethodName, null);
- try {
- if (getterMethod != null
- && getterMethod.exists()
- && getterMethod.getReturnType().equals(
- methods[m].getParameterTypes()[0])) {
- visitedMethods.put(getterMethod, getterMethod);
- }
- } catch (JavaModelException e) {
- // need not error logging
- }
- }
-
- properties.add(new JavaBeanProperty(propertyName, methods[m]
- .getParameterTypes()[0], getterMethod, methods[m]));
- continue;
- }
- }
-
- JavaBeanProperty[] propertyArray = (JavaBeanProperty[]) properties
- .toArray(new JavaBeanProperty[properties.size()]);
-
- Arrays.sort(propertyArray, new Comparator() {
- public int compare(Object o1, Object o2) {
- String name1 = ((JavaBeanProperty) o1).getName();
- String name2 = ((JavaBeanProperty) o2).getName();
- return name1.compareTo(name2);
- }
- });
- return propertyArray;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaClassUtils.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaClassUtils.java
deleted file mode 100644
index 6d24899a8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/JavaClassUtils.java
+++ /dev/null
@@ -1,529 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jdt.core.Flags;
-import org.eclipse.jdt.core.ICompilationUnit;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.IMethod;
-import org.eclipse.jdt.core.IPackageDeclaration;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.ITypeHierarchy;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.core.Signature;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jst.jsf.common.ui.IFileFolderConstants;
-import org.eclipse.jst.jsf.common.ui.internal.utils.JavaModelUtil;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.PartInitException;
-
-/**
- * This utility class defines typical operations on java class, such as check
- * public constructor, and check type is primitive or not, etc.
- *
- * @author Jane Cantz, Xiao-guang Zhang
- */
-public class JavaClassUtils {
- /**
- * Determines if a string contains any illegal characters
- *
- * @param text -
- * the string to test
- * @return boolean - true if an illegal character is found, otherwise false
- */
- public static boolean hasIllegalCharacters(String text) {
- if (text.length() == 0
- || !Character.isJavaIdentifierStart(text.charAt(0))) {
- return true;
- }
- for (int i = 1; i < text.length(); i++) {
- if (!Character.isJavaIdentifierPart(text.charAt(i))) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Test for constructor.
- * <p>
- * This test determines if the class has any constructors
- * </p>
- *
- * @param methods -
- * the IMethod array to examine
- * @return boolean - true, if method has no constructors
- */
- public static boolean hasNoConstructor(IMethod[] methods) {
- for (int m = 0; m < methods.length; m++) {
- try {
- if (methods[m].isConstructor()) {
- return false;
- }
- } catch (JavaModelException e) {
- // suppress: this is possible; fall through
- }
- }
- return true;
- }
-
- /**
- * check whether the method is public or not.
- *
- * @param method
- * @return true if method is public
- */
- public static boolean isPublicMethod(IMethod method) {
- int accessFlags = 0;
-
- try {
- accessFlags = method.getFlags();
- } catch (JavaModelException e) {
- return false;
- }
-
- boolean isPublic = Flags.isPublic(accessFlags);
- if ((!Flags.isPrivate(accessFlags))
- && (!Flags.isProtected(accessFlags))
- && (!Flags.isPublic(accessFlags))) {
- // No specific modifier was set, so assume to be public
- isPublic = true;
- }
- if (!isPublic) {
- return false;
- }
- return true;
- }
-
- /**
- * Test for constructor.
- * <p>
- * This test has the following conditions:
- * </p>
- * <ul>
- * <li>method takes 0 arguments and the method name is the class name:
- * <ul>
- * <li>takes 0 arguments</li>
- * <li>the method name is the class name</li>
- * <li>the method returns void</code></li>
- * </ul>
- * </li>
- * </ul>
- *
- * @param methods -
- * the IMethod array to examine
- * @return boolean - true, if method is a constructor
- */
- public static boolean hasPublicConstructor(IMethod[] methods) {
- for (int m = 0; m < methods.length; m++) {
- try {
- if (methods[m].isConstructor() && isPublicMethod(methods[m])) {
- // Constructor must have the following 0 arguments
- String[] params = methods[m].getParameterTypes();
- if (params.length == 0) {
- // And must return a void
- String rtn = methods[m].getReturnType();
- if (rtn.equals(Signature.SIG_VOID)) {
- return true;
- }
- break;
- }
- }
- } catch (JavaModelException e) {
- // Nothing to do.
- }
- }
- return false;
- }
-
- /**
- * Determines if a datatype is primitive type or part of java.lang or
- * java.util package. If not, it is considered to be a bean reference
- *
- * @param classType -
- * the parent class compilation unit
- * @param signatureName -
- * the datatype of the property
- * @return boolean - true, if the datatype is primitive or part of java.lang
- * or java.util package
- */
- public static boolean isPrimitiveType(IType classType, String signatureName) {
- while (signatureName.startsWith("[")) { //$NON-NLS-1$
- signatureName = signatureName.substring(1);
- }
- int kind = Signature.getTypeSignatureKind(signatureName);
- if (kind == Signature.BASE_TYPE_SIGNATURE
- || signatureName.equals(Signature.SIG_VOID)) {
- // These are true primitive types
- return true;
- }
-
- String qualifiedName = getQualifiedTypeNameInTypeHierarchy(classType,
- signatureName);
-
- if ((qualifiedName.startsWith("java.lang")) || (qualifiedName.startsWith("java.util"))) //$NON-NLS-1$ //$NON-NLS-2$
- {
- return true;
- }
- return false;
- }
-
- /**
- * get the type from the input class name
- *
- * @param project
- * @param className
- * @return - can be null.
- */
- public static IType getType(IProject project, String className) {
- if (project == null) {
- return null;
- }
- IType cunit = null;
- if (className.length() > 0) {
-
- IJavaProject jProject = JavaCore.create(project);
- try {
- cunit = jProject.findType(className);
- } catch (JavaModelException e) {
- // suppress: fall-through and return null
- }
- }
- return cunit;
- }
-
- /**
- * open the type in the editor.
- *
- * @param type
- * @return true if the type could opened in an editor
- */
- public static boolean openType(IType type) {
- if (type == null || !type.exists()) {
- return false;
- }
-
- try {
- IEditorPart editorPart = JavaUI.openInEditor(type
- .getPrimaryElement());
- if (editorPart != null) {
- JavaUI.revealInEditor(editorPart, type.getPrimaryElement());
- return true;
- }
- } catch (PartInitException e) {
- // ignore this error.
- } catch (JavaModelException e) {
- // ignore this error.
- }
- return false;
- }
-
- /**
- * get package name from java source file
- *
- * @param javaFile
- * @return - can be null.
- */
- public static String getPackageName(IFile javaFile) {
- if (javaFile == null) {
- return null;
- }
- String ext = "." + javaFile.getFileExtension(); //$NON-NLS-1$
- // See if the file is a java file
- if (!ext.equalsIgnoreCase(IFileFolderConstants.EXT_JAVA)) {
- return null;
- }
- String packagename = new String();
- ICompilationUnit cunit = JavaCore.createCompilationUnitFrom(javaFile);
- try {
- IPackageDeclaration[] packages = cunit.getPackageDeclarations();
- if (packages.length == 0) {
- packagename = new String();
- } else {
- packagename = packages[0].getElementName();
- }
- } catch (JavaModelException jme) {
- // suppress: fall-through and return an empty string?? TODO:?
- }
- return packagename;
- }
-
- /**
- * copy the array to the list.
- *
- * @param methodList
- * @param methods
- */
- private static void copyToMethodList(List methodList, IMethod[] methods) {
- if (methods != null && methods.length > 0) {
- for (int i = 0; i < methods.length; i++) {
- if (!isDuplicateMethod(methodList, methods[i])) {
- methodList.add(methods[i]);
- }
- }
- }
- }
-
- /**
- * check whether this method is duplicated or not in the existing method
- * list.
- *
- * @param methodList
- * @param method
- * @return
- */
- private static boolean isDuplicateMethod(List methodList, IMethod method) {
- if (method == null || !method.exists()) {
- return false;
- }
-
- String[] paramTypes = method.getParameterTypes();
- String methodName = method.getElementName();
-
- for (Iterator iter = methodList.iterator(); iter.hasNext();) {
- IMethod existedMethod = (IMethod) iter.next();
- if (isSameMethodSignature(methodName, paramTypes, existedMethod)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Tests if a method equals to the given signature. Parameter types are only
- * compared by the simple name, no resolving for the fully qualified type
- * name is done. Constructors are only compared by parameters, not the name.
- *
- * @param name
- * Name of the method
- * @param paramTypes
- * The type signatures of the parameters e.g.
- * <code>{"QString;","I"}</code>
- * @param curr
- * @return Returns <code>true</code> if the method has the given name and
- * parameter types and constructor state.
- */
- public static boolean isSameMethodSignature(String name,
- String[] paramTypes, IMethod curr) {
- if (name.equals(curr.getElementName())) {
- String[] currParamTypes = curr.getParameterTypes();
- if (paramTypes.length == currParamTypes.length) {
- for (int i = 0; i < paramTypes.length; i++) {
- String t1 = Signature.getSimpleName(Signature
- .toString(paramTypes[i]));
- String t2 = Signature.getSimpleName(Signature
- .toString(currParamTypes[i]));
- if (!t1.equals(t2)) {
- return false;
- }
- }
- return true;
- }
- }
- return false;
- }
-
- /**
- * get methods for the class Type including its super class
- *
- * @param classType
- * @return - can be null
- * @throws JavaModelException
- */
- public static IMethod[] getMethods(IType classType)
- throws JavaModelException {
- if (classType == null) {
- return null;
- }
- List methodList = new ArrayList();
- IMethod[] methods = classType.getMethods();
- copyToMethodList(methodList, methods);
-
- ITypeHierarchy typeHierarchy = classType.newSupertypeHierarchy(null);
-
- if (typeHierarchy != null) {
- IType[] superTypes = typeHierarchy.getAllSuperclasses(classType);
-
- if (superTypes != null && superTypes.length > 0) {
- for (int i = 0; i < superTypes.length; i++) {
- if (!superTypes[i].getFullyQualifiedName().equals(
- "java.lang.Object")) { //$NON-NLS-1$
- methods = superTypes[i].getMethods();
-
- copyToMethodList(methodList, methods);
- }
- }
- }
- }
-
- if (methodList != null && methodList.size() > 0) {
- IMethod[] validMethods = (IMethod[]) methodList
- .toArray(new IMethod[methodList.size()]);
-
- Arrays.sort(validMethods, new Comparator() {
- public int compare(Object o1, Object o2) {
- String name1 = ((IMethod) o1).getElementName();
- String name2 = ((IMethod) o2).getElementName();
- return name1.compareTo(name2);
- }
- });
- return validMethods;
- }
- return null;
- }
-
- /**
- * resolve and get the qualified name for the incomplete typename
- *
- * @param classType
- * @param signatureName
- * @return - at least equal to Signature.toString(signatureName).
- */
- public static String getQualifiedTypeNameInTypeHierarchy(IType classType,
- String signatureName) {
- int arrayNum = 0;
- while (signatureName.startsWith("[")) { //$NON-NLS-1$
- arrayNum++;
- signatureName = signatureName.substring(1);
- }
-
- String qualifiedTypeName = Signature.toString(signatureName);
- int kind = Signature.getTypeSignatureKind(signatureName);
- if (kind == Signature.BASE_TYPE_SIGNATURE
- || signatureName.equals(Signature.SIG_VOID)) {
- // Add back array identifiers
- while (arrayNum > 0) {
- qualifiedTypeName = qualifiedTypeName + "[]"; //$NON-NLS-1$
- arrayNum--;
- }
- return qualifiedTypeName;
- }
-
- String typeName = Signature.toString(signatureName);
-
- String foundName = getQualifiedTypeName(classType, typeName);
- // if found in current type
- if (foundName != null) {
- qualifiedTypeName = foundName;
- } else // else found in the type hierachy.
- {
- ITypeHierarchy typeHierarchy = null;
- try {
- typeHierarchy = classType.newSupertypeHierarchy(null);
- } catch (JavaModelException e) {
- // Nothing to do.
- }
- if (typeHierarchy != null) {
- IType[] superTypes = typeHierarchy.getAllSupertypes(classType);
-
- if (superTypes != null && superTypes.length > 0) {
- for (int i = 0; i < superTypes.length; i++) {
- if (!superTypes[i].getFullyQualifiedName().equals(
- "java.lang.Object")) { //$NON-NLS-1$
- foundName = getQualifiedTypeName(superTypes[i],
- typeName);
- if (foundName != null) {
- qualifiedTypeName = foundName;
- break;
- }
- }
- }
- }
- }
- }
-
- // Add back array identifiers
- while (arrayNum > 0) {
- qualifiedTypeName = qualifiedTypeName + "[]"; //$NON-NLS-1$
- arrayNum--;
- }
- return qualifiedTypeName;
- }
-
- /**
- * resolve and get the qualified name for the incomplete typename
- *
- * @param classType
- * @param typeName
- * @return can be null.
- */
- public static String getQualifiedTypeName(IType classType, String typeName) {
- String qualifiedTypeName = null;
-
- try {
- String[][] resolvedNames = classType.resolveType(typeName);
- if (resolvedNames != null && resolvedNames.length > 0) {
- qualifiedTypeName = JavaModelUtil.concatenateName(
- resolvedNames[0][0], resolvedNames[0][1]);
- }
- } catch (JavaModelException e1) {
- // Nothing to do.
- }
-
- return qualifiedTypeName;
- }
-
- /**
- * check whether subclass is sub class of supperclass
- *
- * @param jProject
- * @param subClass -
- * fully qualified name of sub class
- * @param superClass -
- * fully qualified name of super class
- *
- * @return true if subClass is a sub of superClass
- */
- public static boolean isSubClassOf(IJavaProject jProject, String subClass,
- String superClass) {
- if (jProject == null || subClass == null || superClass == null) {
- return false;
- }
-
- try {
- IType subClassType = jProject.findType(subClass);
-
- if (subClassType != null) {
- ITypeHierarchy typeHierarchy = null;
- try {
- typeHierarchy = subClassType.newSupertypeHierarchy(null);
- } catch (JavaModelException e) {
- // Nothing to do.
- }
- IType[] superTypes = typeHierarchy
- .getAllSupertypes(subClassType);
-
- if (superTypes != null && superTypes.length > 0) {
- for (int i = 0; i < superTypes.length; i++) {
- if (superTypes[i].getFullyQualifiedName().equals(
- superClass)) {
- return true;
- }
- }
- }
- }
- } catch (JavaModelException e) {
- // Nothing to do.
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ManagedBeanUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ManagedBeanUtil.java
deleted file mode 100644
index c17cb9faf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ManagedBeanUtil.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jst.jsf.core.jsfappconfig.JSFAppConfigManager;
-import org.eclipse.jst.jsf.facesconfig.emf.ManagedBeanType;
-
-/**
- *
- * @author sfshi
- *
- */
-public class ManagedBeanUtil {
-
- /**
- * Determines if the new bean to be added is already a member of the
- * configuration set.
- * @param project
- *
- * @param beanName -
- * The name of the bean being added
- * @return int - 0 if bean doesn't exist, otherwise the choice from the
- * Duplicate Bean dialog
- */
- public static boolean isBeanDuplicate(IProject project, String beanName)
- {
- JSFAppConfigManager appCfgMgr = JSFAppConfigManager.getInstance(project);
-
- if (appCfgMgr != null)
- {
- List beans = appCfgMgr.getManagedBeans();
-
- // Iterate through the bean list
- for (Iterator i = beans.iterator(); i.hasNext();) {
- Object o = i.next();
- if (o instanceof ManagedBeanType) {
- ManagedBeanType mbti = (ManagedBeanType) o;
- if (mbti.getManagedBeanName() != null) {
- String name = mbti.getManagedBeanName()
- .getTextContent();
- if (name != null && name.equals(beanName)) {
- return true;
- }
- }
- }
- }
-
- }
- return false;
- }
-
- /**
- * get the default managed bean name in the current project according to
- * reference name
- *
- * @param project -
- * current project
- * @param refName -
- * seed reference name
- * @return String - default managed bean name
- */
- public static String getDefaultManagedBeanName(IProject project,
- String refName) {
- String defaultName = refName;
-
- int newRefNameIndex = 1;
- while (isBeanDuplicate(project, defaultName)) {
- defaultName = refName + newRefNameIndex;
- newRefNameIndex++;
- }
- return defaultName;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ModelUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ModelUtil.java
deleted file mode 100644
index a46813653..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/ModelUtil.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigPackage;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-
-/**
- * @author Zhi-peng Zhang
- * @version
- */
-public class ModelUtil {
-
- private static final String ENTITY_NEWLINE = "&#xA;"; //$NON-NLS-1$
- private static final String ENTITY_TAB = "&#x9;"; //$NON-NLS-1$
- private static final String ENTITY_CARRIAGE_RETURN = "&#xD;"; //$NON-NLS-1$
- private static final String ENTITY_AMPERSAND = "&amp;"; //$NON-NLS-1$
- private static final String ENTITY_DOUBLE_QUOTE = "&quot;"; //$NON-NLS-1$
- private static final String ENTITY_SINGLE_QUOTE = "&apos;"; //$NON-NLS-1$
- private static final String ENTITY_GREATER_THAN = "&gt;"; //$NON-NLS-1$
- private static final String ENTITY_LESS_THAN = "&lt;"; //$NON-NLS-1$
-
- /**
- * Get the super class's name of certain element. For example, a class for
- * <action-listener> should implement interface
- * "javax.faces.event.ActionListener".
- *
- *
- *
- * @param key
- * the EClass object of the application child.
- * @return the expected super type for a particular element
- * TODO: could make common with the faces-config validator
- */
- public static String getSuperType(Object key) {
- if (key == FacesConfigPackage.eINSTANCE.getActionListenerType()) {
- return IFacesConfigConstants.ACTION_LISTENER_INTERFACE;
- }
- if (key == FacesConfigPackage.eINSTANCE.getNavigationHandlerType()) {
- return IFacesConfigConstants.NAVIGATION_HANDLE_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getPropertyResolverType()) {
- return IFacesConfigConstants.PROPERTY_RESOLVER_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getStateManagerType()) {
- return IFacesConfigConstants.STATE_MANAGER_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getVariableResolverType()) {
- return IFacesConfigConstants.VARIABLE_RESOLVER_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getViewHandlerType()) {
- return IFacesConfigConstants.VIEW_HANDLER_SUPER_CLASS;
- }
-
- if (key == FacesConfigPackage.eINSTANCE.getApplicationFactoryType()) {
- return IFacesConfigConstants.APPLICATION_FACTORY_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getFacesContextFactoryType()) {
- return IFacesConfigConstants.FACES_CONTEXT_FACTORY_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getLifecycleFactoryType()) {
- return IFacesConfigConstants.LIFECYCLE_FACTORY_SUPER_CLASS;
- }
- if (key == FacesConfigPackage.eINSTANCE.getRenderKitFactoryType()) {
- return IFacesConfigConstants.RENDER_KIT_FACTORY_SUPER_CLASS;
- }
-
- if (key == FacesConfigPackage.eINSTANCE.getPhaseListenerType()) {
- return IFacesConfigConstants.PHASE_LISTENER_INTERFACE;
- }
-
- return null;
- }
-
-
- /**
- * This will take the three pre-defined entities in XML 1.0 (used
- * specifically in XML elements) and convert their character representation
- * to the appropriate entity reference, suitable for XML element content.
- *
- * @param str
- * <code>String</code> input to escape.
- * @return <code>String</code> with escaped content.
- */
- public static String escapeEntities(String str) {
- if (isEmptyString(str)) {
- return ""; //$NON-NLS-1$
- }
-
- StringBuffer buffer;
- char ch;
- String entity;
-
- buffer = null;
- for (int i = 0, n = str.length(); i < n; i++) {
- ch = str.charAt(i);
- switch (ch) {
- case '<':
- entity = ENTITY_LESS_THAN;
- break;
- case '>':
- entity = ENTITY_GREATER_THAN;
- break;
- case '\'':
- entity = ENTITY_SINGLE_QUOTE;
- break;
- case '\"':
- entity = ENTITY_DOUBLE_QUOTE;
- break;
- case '&':
- entity = ENTITY_AMPERSAND;
- break;
- case '\r':
- entity = ENTITY_CARRIAGE_RETURN;
- break;
- case '\t':
- entity = ENTITY_TAB;
- break;
- case '\n':
- entity = ENTITY_NEWLINE;
- break;
- default:
- entity = null;
- break;
- }
- if (buffer == null) {
- if (entity != null) {
- // An entity occurred, so we'll have to use StringBuffer
- // (allocate room for it plus a few more entities).
- buffer = new StringBuffer(str.length() + 20);
- // Copy previous skipped characters and fall through
- // to pickup current character
- buffer.append(str.substring(0, i));
- buffer.append(entity);
- }
- } else {
- if (entity == null) {
- buffer.append(ch);
- } else {
- buffer.append(entity);
- }
- }
- }
-
- // If there were any entities, return the escaped characters
- // that we put in the StringBuffer. Otherwise, just return
- // the unmodified input string.
- return (buffer == null) ? str : buffer.toString();
- }
-
- /**
- * @param str
- * @return removes XML/HTML escaped characters from str.
- */
- public static String unEscapeEntities(String str) {
- if (isEmptyString(str)) {
- return ""; //$NON-NLS-1$
- }
-
- String result = new String(str);
-
- result = result.replaceAll(ENTITY_AMPERSAND, "&"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_LESS_THAN, "<"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_GREATER_THAN, ">"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_SINGLE_QUOTE, "\'"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_DOUBLE_QUOTE, "\""); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_CARRIAGE_RETURN, "\r"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_TAB, "\t"); //$NON-NLS-1$
- result = result.replaceAll(ENTITY_NEWLINE, "\n"); //$NON-NLS-1$
-
- return result;
- }
-
- private static boolean isEmptyString(String value) {
- if (value == null || value.length() == 0) {
- return true;
- }
- return false;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/WebrootUtil.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/WebrootUtil.java
deleted file mode 100644
index 0f3ada6a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/util/WebrootUtil.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.util;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.emf.common.util.URI;
-import org.eclipse.emf.ecore.EObject;
-
-
-/**
- * This utility class is used to make a bridge between the relative path from
- * webroot and physical path in the project.
- *
- * @author Xiao-guang Zhang
- *
- */
-public class WebrootUtil extends
- org.eclipse.jst.jsf.common.ui.internal.utils.WebrootUtil {
-
- /**
- * get the the project path for webpath The project path is something like
- * "/projectname/webroot/filename.jsp", or "/projectname/webroot/folder".
- * The project information should be removed from project path, e.g,
- * "/filename.jsp" or "/folder/*";
- * @param model
- *
- * @param strPath -
- * the web path
- * @return - project path from "/projectname/webroot"
- */
- static public String getProjectPath(EObject model, String strPath) {
-
- IProject project = getProject(model);
-
- String strProjectPath = ""; //$NON-NLS-1$
- if (strPath != null) {
- IPath path = new Path(strPath);
- // jsp file
- if (path.getFileExtension() != null) {
- IPath webContentPath = getWebContentPath(project);
- if (webContentPath != null)
- strProjectPath = webContentPath.toString() + strPath;
-
- } else
- // jsp folder
- {
- strPath = new String(strPath.getBytes(), 0,
- strPath.length() - 1);
- IPath webContentPath = getWebContentPath(project);
- if (webContentPath != null)
- strProjectPath = webContentPath.toString() + strPath;
- }
- }
- return strProjectPath;
- }
-
- /**
- * @param model -
- * emf model
- * @return the current resource according to EMF model
- */
- static public IResource getResource(EObject model) {
- IResource resource = null;
-
- if (model != null && model.eResource() != null) {
- URI uri = model.eResource().getURI();
- IPath path = new Path(URI.decode(uri.devicePath()));
-
- // since the uri format is "platform:/resource/..."
- // we will remove the first part
- path = path.removeFirstSegments(1);
-
- IWorkspaceRoot workspaceRoot = ResourcesPlugin.getWorkspace()
- .getRoot();
- resource = workspaceRoot.findMember(path);
- }
-
- return resource;
- }
-
- /**
- * get the current project according to EMF model
- *
- * @param model -
- * emf model
- * @return the current project according to EMF model
- */
- static public IProject getProject(EObject model) {
- IProject project = null;
-
- IResource resource = getResource(model);
-
- if (resource != null) {
- project = resource.getProject();
- }
-
- return project;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ISummaryDataSource.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ISummaryDataSource.java
deleted file mode 100644
index ae1fa5e24..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ISummaryDataSource.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import java.util.List;
-
-/**
- * Specifies behavior for a datasource that client wizards use to communicate
- * summary information to summary page.
- *
- * @author plevin
- * @version 1.0
- */
-public interface ISummaryDataSource {
- /**
- * Returns key-value summary data.
- *
- * @return List - Summary data.
- */
- public List getSummaryData();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanClassSelectionPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanClassSelectionPage.java
deleted file mode 100644
index c2306cf44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanClassSelectionPage.java
+++ /dev/null
@@ -1,322 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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: Sybase,
- * Inc. - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jdt.core.JavaConventions;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.ClassButtonDialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.DialogField;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.IDialogFieldChangeListener;
-import org.eclipse.jst.jsf.common.ui.internal.dialogfield.LayoutUtil;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.util.JavaClassUtils;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-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.Group;
-import org.eclipse.swt.widgets.Label;
-
-/**
- * This class used to select an existing java class or generate a new one.
- * However, the actural generated new java class is left to other pages.
- *
- * @author Xiao-guang Zhang
- */
-public class ManagedBeanClassSelectionPage extends WizardPage {
- private static final int HORIZONTAL_INDENT_DEFAULT = 25;
-
- /** the class name */
- private String className;
-
- /**
- * Search Section, including radio button, label, text and browser button.
- */
- private Button searchRadioButton;
-
- private ClassButtonDialogField classSearchDialogField;
-
- /** selected type */
- private IType searchedType;
-
- /** Generate radio button */
- private Button createRadioButton;
-
- private IProject currentProject;
-
- /**
- * Constructor.
- *
- * @param project
- * The project.
- */
- public ManagedBeanClassSelectionPage(IProject project) {
- super("JavaSelectionWizardPage"); //$NON-NLS-1$
-
- currentProject = project;
- setTitle(WizardMessages.JavaSelectionWizardPage_Title);
- setDescription(WizardMessages.JavaSelectionWizardPage_Description);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- Composite container = new Composite(parent, SWT.NULL);
- GridLayout layout = new GridLayout();
- layout.marginWidth = 10;
- layout.marginHeight = 5;
- container.setLayout(layout);
- container.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- final Group group = new Group(container, SWT.NONE);
-
- group.setLayout(new GridLayout());
-
- group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- createSearchSection(group);
- createGenerateSection(group);
-
- setControl(container);
- Dialog.applyDialogFont(container);
- setPageComplete(classSearchDialogField.getText().length() > 0);
- EditorPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(
- container,
- WizardMessages.JavaSelectionWizardPage_HelpContextID);
- }
-
- /**
- * enabled or disabled the search section including the labels and texts
- *
- * @param enabled -
- * enabled or disabled the search section
- */
- private void enableSearchSection(boolean enabled) {
- classSearchDialogField.setEnabled(enabled);
- }
-
- /**
- * Create the search section including the labels, texts, and browser
- * buttons
- *
- * @param parent -
- * parent composite control
- */
- private void createSearchSection(Composite parent) {
- searchRadioButton = new Button(parent, SWT.RADIO);
- // JavaSelectionWizardPage.Search = Using an existing Java class
- searchRadioButton
- .setText(WizardMessages.JavaSelectionWizardPage_Search);
- searchRadioButton.setSelection(true);
- searchRadioButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- createRadioButton.setSelection(!searchRadioButton
- .getSelection());
- enableSearchSection(searchRadioButton.getSelection());
- verifyComplete();
- }
- });
-
- Composite searchSection = new Composite(parent, SWT.NULL);
-
- classSearchDialogField = new ClassButtonDialogField(currentProject);
- classSearchDialogField.setHyperLink(null);
- int numberOfControls = classSearchDialogField.getNumberOfControls();
-
- GridLayout layout = new GridLayout();
- layout.numColumns = numberOfControls;
- layout.verticalSpacing = 9;
- searchSection.setLayout(layout);
- searchSection.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- classSearchDialogField.doFillIntoGrid(null, searchSection,
- numberOfControls);
-
- GridData gd = (GridData) classSearchDialogField.getLabelControl(null,
- searchSection).getLayoutData();
- gd.horizontalIndent = HORIZONTAL_INDENT_DEFAULT;
-
- // JavaSelectionWizardPage.Search.ClassName = Qulified class name:
- classSearchDialogField
- .setLabelText(WizardMessages.JavaSelectionWizardPage_Search_ClassName);
-
- LayoutUtil.setHorizontalGrabbing(classSearchDialogField.getTextControl(
- null, searchSection));
-
- classSearchDialogField
- .setDialogFieldChangeListener(new IDialogFieldChangeListener() {
- public void dialogFieldChanged(DialogField field) {
- className = classSearchDialogField.getText();
- verifyComplete();
- }
-
- });
-
- Label searchDesp = new Label(searchSection, SWT.NONE);
- searchDesp
- .setText(WizardMessages.JavaSelectionWizardPage_Search_Description);
-
- gd = new GridData();
- gd.horizontalSpan = numberOfControls;
- gd.horizontalIndent = HORIZONTAL_INDENT_DEFAULT;
- searchDesp.setLayoutData(gd);
- }
-
- /**
- * Create the generation section including the labels, texts, and browser
- * buttons
- *
- * @param parent -
- * parent composite control
- */
- private void createGenerateSection(Composite parent) {
- createRadioButton = new Button(parent, SWT.RADIO);
- createRadioButton
- .setText(WizardMessages.JavaSelectionWizardPage_Create);
- createRadioButton.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- searchRadioButton.setSelection(!createRadioButton
- .getSelection());
- enableSearchSection(!createRadioButton.getSelection());
- verifyComplete();
- }
- });
-
- Composite createSection = new Composite(parent, SWT.NULL);
- GridLayout layout = new GridLayout();
- layout.numColumns = 3;
- layout.verticalSpacing = 9;
- createSection.setLayout(layout);
- createSection.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
- Label createDesp = new Label(createSection, SWT.NONE);
- createDesp
- .setText(WizardMessages.JavaSelectionWizardPage_Create_Description);
-
- GridData gd = new GridData();
- gd.horizontalIndent = HORIZONTAL_INDENT_DEFAULT;
- createDesp.setLayoutData(gd);
- }
-
- /**
- * create a new java class or not
- *
- * @return true if the create new java class radio button is selected
- */
- public boolean isCreateNewJavaClass() {
- return createRadioButton.getSelection();
- }
-
- /**
- * get the selected java type
- *
- * @return - type
- */
- public IType getSelectedType() {
- searchedType = JavaClassUtils.getType(currentProject,
- classSearchDialogField.getText());
-
- return searchedType;
- }
-
- /**
- * @return the class name
- */
- public String getClassName() {
- return className;
- }
-
- /**
- * validate the selected or input java type name
- *
- * @return
- */
- private IStatus validateJavaTypeName() {
- IStatus status = null;
- if (classSearchDialogField.getText().length() == 0) {
- status = new Status(
- IStatus.ERROR,
- EditorPlugin.getPluginId(),
- -1,
- NLS
- .bind(
- WizardMessages.JavaSelectionWizardPage_Error_ClassIsEmpty,
- classSearchDialogField.getText()), null);
- } else {
- // ensure the name follows the java conventsions.
- status = JavaConventions
- .validateJavaTypeName(classSearchDialogField.getText(), JavaCore.VERSION_1_3,JavaCore.VERSION_1_3);
- if (status.getSeverity() != IStatus.ERROR) {
- // ensure the input or selected type is defined in the current
- // project
- if (getSelectedType() == null) {
- status = new Status(
- IStatus.ERROR,
- EditorPlugin.getPluginId(),
- -1,
- NLS
- .bind(
- WizardMessages.JavaSelectionWizardPage_Error_ClassIsNotDefined,
- classSearchDialogField.getText()),
- null);
- }
- }
- }
- return status;
- }
-
- /**
- * verify and update the complete status
- */
- private void verifyComplete() {
- IStatus status = null;
-
- if (isCreateNewJavaClass()) {
- setPageComplete(true);
- setMessage(null);
- setErrorMessage(null);
- } else {
- if (searchRadioButton.getSelection()) {
- status = validateJavaTypeName();
- }
- String errorMessage = null;
- setPageComplete(status.getSeverity() != IStatus.ERROR);
-
- if (status.getSeverity() == IStatus.ERROR) {
- errorMessage = status.getMessage();
- }
-
- if (errorMessage != null) {
- setErrorMessage(errorMessage);
- } else {
- setErrorMessage(null);
- }
-
- if (status.getSeverity() != IStatus.OK) {
- setMessage(status.getMessage());
- } else {
- setMessage(null);
- }
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanPropertyPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanPropertyPage.java
deleted file mode 100644
index cf221a05f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/ManagedBeanPropertyPage.java
+++ /dev/null
@@ -1,321 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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: Sybase,
- * Inc. - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-import org.eclipse.jst.jsf.facesconfig.ui.IFacesConfigConstants;
-import org.eclipse.jst.jsf.facesconfig.ui.util.JavaClassUtils;
-import org.eclipse.jst.jsf.facesconfig.ui.util.ManagedBeanUtil;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-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.Text;
-
-/**
- * ManangedBeanProperty wizard page used to show properties of the previous
- * selected java class, suade services. and set the default values for each
- * property.
- *
- * @author Xiao-guang Zhang, sfshi
- */
-public class ManagedBeanPropertyPage extends WizardPage implements ISummaryDataSource {
- /** Default height of description Text Control */
- private static final int DESCRIPTION_TEXT_HEIGHT = 60;
-
- private static final int DEFAULT_WIDTHHINT = 10;
-
- /** The Text control for managed bean instance name */
- private Text managedBeanNameText;
-
- /** The Combo control for Project Selection */
- private Combo scopeCombo;
-
- /** The Text control for managed bean's description */
- private Text managedBeanDescriptionText;
-
- private String helpID = null;
-
- private IProject currentProject;
-
- private String defaultScope;
-
- /**
- * @param defaultScope
- * the default scope, if be null, then use "session".
- * @param project
- */
- public ManagedBeanPropertyPage(String defaultScope, IProject project) {
- super("ManagedBeanPropertyWizardPage"); //$NON-NLS-1$);
-
- this.defaultScope = defaultScope;
- currentProject = project;
- setTitle(WizardMessages.ManagedBeanPropertyWizardPage_Title);
- setDescription(WizardMessages.ManagedBeanPropertyWizardPage_Description);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see WizardPage#createControl(Composite)
- */
- public void createControl(Composite parent) {
- initializeDialogUnits(parent);
-
- Composite container = new Composite(parent, SWT.NONE);
- GridLayout gl = new GridLayout();
- gl.numColumns = 1;
- container.setLayout(gl);
- GridData gridData = new GridData(GridData.FILL_BOTH);
- container.setLayoutData(gridData);
-
- createGeneralSection(container);
-
- setControl(container);
-
- setPageComplete(false);
-
- if (helpID != null) {
- EditorPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(
- getControl(), helpID);
- }
- }
-
- /**
- * create managed bean 's configuration group
- *
- * @param container
- */
- private void createGeneralSection(Composite container) {
- Group generalSection = new Group(container, SWT.NONE);
-
- // ManagedBeanPropertyWizardPage.General = General
- generalSection
- .setText(WizardMessages.ManagedBeanPropertyWizardPage_General);
-
- GridLayout gl = new GridLayout();
- // gl.marginHeight = 20;
- gl.numColumns = 2;
- generalSection.setLayout(gl);
- GridData gridData = new GridData(GridData.FILL_HORIZONTAL);
- generalSection.setLayoutData(gridData);
-
- SWTUtils
- .createLabel(
- generalSection,
- WizardMessages.ManagedBeanPropertyWizardPage_ManagedBeanName,
- 1);
-
- managedBeanNameText = SWTUtils.createTextBox(generalSection, 1);
- GridData gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = 1;
- gd.widthHint = DEFAULT_WIDTHHINT;
- managedBeanNameText.setLayoutData(gd);
-
- managedBeanNameText.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- // dialogChanged();
- if (isValidManagedBeanName(true)) {
- setPageComplete(true);
- } else {
- setPageComplete(false);
- }
- }
- });
-
- SWTUtils
- .createLabel(
- generalSection,
- WizardMessages.ManagedBeanPropertyWizardPage_ManagedBeanScope,
- 1);
-
- String[] items = {
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_APPLICATION,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_SESSION,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_REQUEST,
- IFacesConfigConstants.MANAGED_BEAN_SCOPE_NONE };
-
- scopeCombo = SWTUtils.createCombo(generalSection, items, 1);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = 1;
- gd.widthHint = DEFAULT_WIDTHHINT;
- scopeCombo.setLayoutData(gd);
-
- Label labelDesp = SWTUtils
- .createLabel(
- generalSection,
- WizardMessages.ManagedBeanPropertyWizardPage_ManagedBeanDescription,
- 1);
-
- gd = new GridData(GridData.VERTICAL_ALIGN_BEGINNING);
- labelDesp.setLayoutData(gd);
-
- managedBeanDescriptionText = SWTUtils.createTextBoxScrollable(
- generalSection, 1, -1, DESCRIPTION_TEXT_HEIGHT);
-
- }
-
- /**
- * Validates the managed bean Name entry
- *
- * @param reportError -
- * true, to report errors.
- * @return boolean - the valid state of the data entered
- */
- private boolean isValidManagedBeanName(boolean reportError) {
- if (managedBeanNameText.getText().length() == 0) {
- if (reportError) {
- setErrorMessage(WizardMessages.ManagedBeanPropertyWizardPage_Warning_MissingManagedBeanName);
- }
- return false;
- } else if (JavaClassUtils.hasIllegalCharacters(managedBeanNameText
- .getText())) {
- if (reportError) {
- setErrorMessage(WizardMessages.ManagedBeanPropertyWizardPage_Warning_InvalidManagedBeanName);
- }
- return false;
- } else {
- if (ManagedBeanUtil.isBeanDuplicate(currentProject,
- managedBeanNameText.getText())) {
- if (reportError) {
- setErrorMessage(WizardMessages.ManagedBeanPropertyWizardPage_Warning_DuplicateManagedBeanName);
- }
- return false;
- }
-
- }
-
- setErrorMessage(null);
- return true;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.wizard.IWizardPage#setPreviousPage(org.eclipse.jface.wizard.IWizardPage)
- */
- public void setPreviousPage(IWizardPage page) {
- super.setPreviousPage(page);
- initialize();
- }
-
- private void initialize() {
- if (defaultScope != null && defaultScope.length() > 0)
- scopeCombo.setText(defaultScope);
- else
- scopeCombo.setText("session"); //$NON-NLS-1$
-
- if (((NewManagedBeanWizard) getWizard()).getSuggestedBeanName() != null) {
- this.managedBeanNameText
- .setText(((NewManagedBeanWizard) getWizard())
- .getSuggestedBeanName());
- } else {
- String beanName;
- if (this.getPreviousPage() instanceof ManagedBeanClassSelectionPage) {
- beanName = ((ManagedBeanClassSelectionPage) this.getPreviousPage())
- .getClassName();
- } else {
- beanName = ((NewJavaClassPage) this.getPreviousPage())
- .getTypeName();
- }
- beanName = beanName.substring(beanName.lastIndexOf(".") + 1); //$NON-NLS-1$
- if (beanName != null && beanName.length() > 0) {
- beanName = (beanName.substring(0, 1)).toLowerCase()
- + (beanName.substring(1));
-
- beanName = ManagedBeanUtil.getDefaultManagedBeanName(
- currentProject, beanName);
-
- } else
- beanName = ""; //$NON-NLS-1$
- managedBeanNameText.setText(beanName);
- }
- }
-
- /**
- * Returns key-value summary data.
- *
- * @return List - Summary data.
- */
- public List getSummaryData() {
- List data = new ArrayList();
-
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_ManagedBeanName,
- getManagedBeanName() });
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_ManagedBeanScope,
- getManagedBeanScope() });
- data.add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_ClassName,
- getManagedBeanClass() });
-
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_Description,
- getManagedBeanDescription() });
- return data;
- }
-
- /**
- * @return the name of the managed bean
- */
- public String getManagedBeanName() {
- return this.managedBeanNameText.getText().trim();
- }
-
- /**
- * @return the managed bean class name
- */
- public String getManagedBeanClass() {
- if (this.getPreviousPage() instanceof ManagedBeanClassSelectionPage) {
- return ((ManagedBeanClassSelectionPage) this.getPreviousPage()).getClassName();
- } else if (this.getPreviousPage() instanceof NewJavaClassPage) {
- NewJavaClassPage newJavaClassPage = (NewJavaClassPage) this.getPreviousPage();
- StringBuffer buffer = new StringBuffer();
- if (newJavaClassPage.getPackageText() != null
- && newJavaClassPage.getPackageText().length() > 0) {
- buffer.append(newJavaClassPage.getPackageText());
- buffer.append("."); //$NON-NLS-1$
- }
- buffer.append(newJavaClassPage.getTypeName());
- return buffer.toString();
- }
-
- return "";//$NON-NLS-1$
- }
-
- /**
- * @return the managed bean scope
- */
- public String getManagedBeanScope() {
- return this.scopeCombo.getText().trim();
- }
-
- /**
- * @return the managed bean description
- */
- public String getManagedBeanDescription() {
- return this.managedBeanDescriptionText.getText().trim();
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewJavaClassPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewJavaClassPage.java
deleted file mode 100644
index 4cc972cb3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewJavaClassPage.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.wizard.IWizardPage;
-
-/**
- * Wizard page to create a new class.
- *
- * @author Xiao-guang Zhang
- *
- */
-public class NewJavaClassPage extends org.eclipse.jdt.ui.wizards.NewClassWizardPage
- implements ISummaryDataSource {
-
- private final IProject currentProject;
-
- /**
- * @param project
- */
- public NewJavaClassPage(IProject project) {
- super();
- currentProject = project;
- setPageComplete(false);
- }
-
- private void initialize() {
- if (getPackageFragmentRoot() == null
- || currentProject != getPackageFragmentRoot().getJavaProject()
- .getProject()) {
- IJavaProject jProject = JavaCore.create(currentProject);
- StructuredSelection selection = new StructuredSelection(jProject);
- init(selection);
- }
- }
-
- private boolean isSkipped() {
- if ((getPreviousPage() instanceof ManagedBeanClassSelectionPage)
- && !((ManagedBeanClassSelectionPage) getPreviousPage()).isCreateNewJavaClass())
- return true;
- return false;
- }
-
- public List getSummaryData() {
- List data = new ArrayList();
-
- if (!isSkipped()) {
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_SourceFolder,
- getPackageFragmentRootText(), });
-
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_PackageName,
- getPackageText(), });
-
- data
- .add(new String[] {
- WizardMessages.NewJavaManagedBeanWizard_Summary_TypeName,
- getTypeName() });
- }
- return data;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.wizard.IWizardPage#setPreviousPage(org.eclipse.jface.wizard.IWizardPage)
- */
- public void setPreviousPage(IWizardPage page) {
- super.setPreviousPage(page);
- initialize();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewManagedBeanWizard.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewManagedBeanWizard.java
deleted file mode 100644
index 4226952ae..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/NewManagedBeanWizard.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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: Sybase,
- * Inc. - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jface.wizard.IWizardPage;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.common.ui.internal.logging.Logger;
-import org.eclipse.jst.jsf.facesconfig.ui.EditorPlugin;
-
-/**
- * The wizard for creating a managed bean on faces config model.
- *
- * @author Xiao-guang Zhang, sfshi
- */
-public class NewManagedBeanWizard extends Wizard implements ISummaryDataSource {
-
- /** log instance */
- private static final Logger log = EditorPlugin
- .getLogger(NewManagedBeanWizard.class);
-
- /**
- * The wizard page where user can select a Java class for the managed bean
- * to be created.
- */
- private ManagedBeanClassSelectionPage managedBeanClassSelectionPage;
-
- /**
- * The wizard page where user can create a new Java class for the managed
- * bean to be created.
- */
- private NewJavaClassPage newJavaClassPage;
-
- private ManagedBeanPropertyPage managedBeanPropertyPage;
-
- private String managedBeanName;
-
- private String managedBeanScope;
-
- private String managedBeanClass;
-
- private String managedBeanDescription;
-
- private IProject project;
-
- /**
- * the suggested name for the managed bean, if setted, then use it in
- * ManagedBeanPropertyWizardPage.
- */
- private String suggestedBeanName;
-
- private String defaultScope;
-
- /**
- * Constructor
- *
- * @param project
- * The project.
- */
- public NewManagedBeanWizard(IProject project) {
- super();
- setWindowTitle(WizardMessages.NewManagedBeanWizardBase_Title);
- this.project = project;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsf.facesconfig.ui.wizards.NewWizard#addPages()
- */
- public void addPages() {
- setDialogSettings(EditorPlugin.getDefault().getDialogSettings());
-
- // add java source selection page.
- managedBeanClassSelectionPage = new ManagedBeanClassSelectionPage(project);
- addPage(managedBeanClassSelectionPage);
-
- // add the class type page
- newJavaClassPage = new NewJavaClassPage(project);
- addPage(newJavaClassPage);
-
- managedBeanPropertyPage = new ManagedBeanPropertyPage(defaultScope, project);
- addPage(managedBeanPropertyPage);
-
- // // add the summary page
- SummaryPage summaryPage = new SummaryPage(this);
- addPage(summaryPage);
- summaryPage
- .setDescription(WizardMessages.NewJavaManagedBeanWizard_SummaryPage_Description);
- }
-
- /**
- * Skip the NewJavaClassPage when user select "Using an existing class" on the
- * ManagedBeanClassSelectionPage.
- */
- public IWizardPage getNextPage(IWizardPage page) {
- IWizardPage nextPage = super.getNextPage(page);
- if (page instanceof ManagedBeanClassSelectionPage
- && !((ManagedBeanClassSelectionPage) page).isCreateNewJavaClass()) {
- ((WizardPage) nextPage).setPageComplete(true);
- return getNextPage(nextPage);
- }
- return nextPage;
- }
-
- public boolean performFinish() {
-
- managedBeanName = managedBeanPropertyPage.getManagedBeanName();
- managedBeanClass = managedBeanPropertyPage.getManagedBeanClass();
- managedBeanScope = managedBeanPropertyPage.getManagedBeanScope();
- managedBeanDescription = managedBeanPropertyPage.getManagedBeanDescription();
- if (managedBeanClassSelectionPage.isCreateNewJavaClass())
- createNewJavaClass();
-
- return true;
- }
-
- /**
- * create a new java class according to current inputs in
- * NewClassWizardPage.
- */
- private void createNewJavaClass() {
- try {
- newJavaClassPage.createType(new NullProgressMonitor());
- } catch (CoreException e) {
- log.info("NewJavaManagedBeanWizard.Error.CreateType", e); //$NON-NLS-1$
-
- EditorPlugin.getAlerts().error(
- "NewJavaManagedBeanWizard.Alert.CreateType.Title", //$NON-NLS-1$
- "NewJavaManagedBeanWizard.Alert.CreateType.Description"); //$NON-NLS-1$
- return;
- } catch (InterruptedException e) {
- log.info("NewJavaManagedBeanWizard.Error.CreateType", e); //$NON-NLS-1$
- EditorPlugin.getAlerts().error(
- "NewJavaManagedBeanWizard.Alert.CreateType.Title", //$NON-NLS-1$
- "NewJavaManagedBeanWizard.Alert.CreateType.Description"); //$NON-NLS-1$
- return;
- }
- newJavaClassPage.getCreatedType();
- }
-
- /**
- * @return the suggested bean name
- */
- public String getSuggestedBeanName() {
- return suggestedBeanName;
- }
-
- /**
- * Set a name for the new managed bean, this name will be shown in the
- * ManagedBeanPropertyWizardPage. If don't set the name, then will get a
- * default bean name from the managed bean class name.
- *
- * @param suggestedBeanName
- */
- public void setSuggestedBeanName(String suggestedBeanName) {
- this.suggestedBeanName = suggestedBeanName;
- }
-
- /**
- * @return the default scope value
- */
- public String getDefaultScope() {
- return defaultScope;
- }
-
- /**
- * set a default scope value for this new managed bean.
- *
- * @param defaultScope
- */
- public void setDefaultScope(String defaultScope) {
- this.defaultScope = defaultScope;
- }
-
- /**
- * @return the class name
- */
- public String getManagedBeanClass() {
- return managedBeanClass;
- }
-
- /**
- * @return the bean description
- */
- public String getManagedBeanDescription() {
- return managedBeanDescription;
- }
-
- /**
- * @return the managed bean's symbolic name
- */
- public String getManagedBeanName() {
- return managedBeanName;
- }
-
- /**
- * @return the managed bean's scope
- */
- public String getManagedBeanScope() {
- return managedBeanScope;
- }
-
- public List getSummaryData() {
- List data = new ArrayList();
- IWizardPage[] pages = getPages();
-
- for (int i = 0; i < pages.length; i++) {
- if (pages[i] instanceof ISummaryDataSource) {
-
- data.addAll(((ISummaryDataSource) pages[i]).getSummaryData());
- }
- }
- return data;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/SummaryPage.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/SummaryPage.java
deleted file mode 100644
index e917466ba..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/SummaryPage.java
+++ /dev/null
@@ -1,147 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2004, 2005 Sybase, Inc. 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: Sybase,
- * Inc. - initial API and implementation
- ******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import org.eclipse.jface.viewers.ColumnPixelData;
-import org.eclipse.jface.viewers.TableLayout;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.common.ui.internal.guiutils.SWTUtils;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-
-/**
- * Common wizard page used to summarize information entered in previous pages.
- *
- * @author plevin
- * @version 1.0
- */
-public class SummaryPage extends WizardPage
-{
- private static final String WIZARD_SUMMARY_PAGE = "WizardSummaryPage"; //$NON-NLS-1$
-
- /** The source of the summary items */
- private ISummaryDataSource source;
-
- /** The table control that displays the summary items */
- private Table table;
-
- /**
- * This Constructor creates the summary page
- */
- public SummaryPage()
- {
- super( WIZARD_SUMMARY_PAGE );
- setTitle( WizardMessages.WizardSummaryPage_Title_WizardSummary );
- setDescription( WizardMessages.WizardSummaryPage_Summary_SummaryDesc );
- }
-
- /**
- * This Constructor initializes the data source.
- *
- * @param source -
- * Summary data source
- */
- public SummaryPage( ISummaryDataSource source )
- {
- this();
- this.source = source;
- }
-
- /**
- * Determines if the wizard can enable the Next button
- *
- * @return boolean - the state of the Next button
- */
- public boolean canFlipToNextPage()
- {
- return false;
- }
-
- /**
- * Creates the page controls
- *
- * @param parent -
- * the wizard composite
- */
- public void createControl( Composite parent )
- {
-
- Composite composite = SWTUtils.createComposite( parent, 1 );
-
- table = new Table( composite, SWT.BORDER );
- table.setLayoutData( new GridData( GridData.FILL_BOTH ) );
- table.setHeaderVisible( true );
- table.setLinesVisible( true );
-
- TableLayout layout = new TableLayout();
- table.setLayout( layout );
-
- layout.addColumnData( new ColumnPixelData( 163 ) );
- layout.addColumnData( new ColumnPixelData( 350 ) );
-
- TableColumn keyCol = new TableColumn( table, SWT.NONE );
- keyCol.setText( WizardMessages.WizardSummaryPage_Label_Field );
-
- TableColumn valueCol = new TableColumn( table, SWT.NONE );
- valueCol
- .setText( WizardMessages.WizardSummaryPage_Label_Value );
-
- setControl( composite );
- setPageComplete( true );
- }
-
- /**
- * Populates the table with summary information.
- */
- public void loadSummaryData()
- {
- if ( source == null )
- {
- return;
- }
- Object[] data = source.getSummaryData().toArray();
- table.removeAll();
- for ( int i = 0; i < data.length; i++ )
- {
- TableItem item = new TableItem( table, SWT.NONE );
- item.setText( (String[]) data[i] );
- }
- return;
- }
-
- /**
- * Sets summary page data source.
- *
- * @param s -
- * Data source.
- */
- public void setSummaryDataSource( ISummaryDataSource s )
- {
- source = s;
- }
-
- /**
- * Populates the table with summary items when the page becomes visible.
- *
- * @param visible -
- * the visible state of the page
- */
- public void setVisible( boolean visible )
- {
- super.setVisible( visible );
-
- if ( visible == true )
- {
- loadSummaryData();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.java b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.java
deleted file mode 100644
index b128bfd3f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.java
+++ /dev/null
@@ -1,461 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.facesconfig.ui.wizard;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Message bundle for wizards
- *
- */
-public final class WizardMessages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.facesconfig.ui.wizard.WizardMessages"; //$NON-NLS-1$
-
- private WizardMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, WizardMessages.class);
- }
-
- /**
- * see WizardMessages.properties
- */
- public static String NewManagedBeanWizardBase_Type;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewManagedBeanWizardBase_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewManagedBeanWizardBase_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewManagedBeanCreationWizard_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String IntroWizardPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String IntroWizardPage_Intro;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanWizardSelectionPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanWizardSelectionPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanWizardSelectionPage_Group;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanWizardSelectionPage_HelpContextID;
-
- /**
- * see WizardMessages.properties
- */
- public static String Registry_LoadWizard_Error;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewWizard_Title_WizardDefault;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_General;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_ManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_ManagedBeanScope;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_ManagedBeanDescription;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_ManagedBeanProperty;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_PropertyName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Type;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Value;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Button_Add;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Button_Edit;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Button_Remove;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Warning_MissingManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Warning_InvalidManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyWizardPage_Warning_DuplicateManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_PropertyName;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_DataType;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_InitialValue;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Title_NewPropertyEntry;
-
- /**
- * see WizardMessages.properties
- */
- public static String ManagedBeanPropertyEditDialog_Title_ExistingPropertyEntry;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Project;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_FacesConfig;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_FacesConfig_Browser;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Warning_MissingProjectName;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Warning_MissingFacesConfigName;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Warning_InvalidFacesConfigName;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Warning_InvalidFacesConfigContent;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_Warning_FacesConfigNotDefinedInWebDotXML;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigSelectionWizardPage_HelpContextID;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigFileSelectionDialog_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String FacesConfigFileSelectionDialog_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Group;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Search;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Search_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Search_ClassName;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Search_ClassName_Browse;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Create;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Create_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_FindType;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_FindType_Filter;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Error_ClassIsEmpty;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_Error_ClassIsNotDefined;
-
- /**
- * see WizardMessages.properties
- */
- public static String JavaSelectionWizardPage_HelpContextID;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_ProjectName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_FacesConfigFileName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_TypeName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_PackageName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_SourceFolder;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_ManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_ManagedBeanScope;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_ClassName;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Summary_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_SummaryPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Task_CreateNewManagedBean;
-
- /**
- * see WizardMessages.properties
- */
- public static String NewJavaManagedBeanWizard_Task_CreateNewJavaClass;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanWizard_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanPage_Title;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanPage_Description;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_Group_Label;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_OverwriteButton_Text;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_NewButton_Text;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_NewNameDialogField_Label;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_Error_EmptyManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_Error_InvalidManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String DuplicateBeanGroup_Error_DuplicatedManagedBeanName;
-
- /**
- * see WizardMessages.properties
- */
- public static String WizardSummaryPage_Title_WizardSummary;
-
- /**
- * see WizardMessages.properties
- */
- public static String WizardSummaryPage_Summary_SummaryDesc;
-
- /**
- * see WizardMessages.properties
- */
- public static String WizardSummaryPage_Label_Field;
-
- /**
- * see WizardMessages.properties
- */
- public static String WizardSummaryPage_Label_Value;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.properties b/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.properties
deleted file mode 100644
index e594ea81b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.facesconfig.ui/src/org/eclipse/jst/jsf/facesconfig/ui/wizard/WizardMessages.properties
+++ /dev/null
@@ -1,128 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-NewManagedBeanWizardBase_Type = ManagedBeanTypeName
-NewManagedBeanWizardBase_Description = ManagedBeanTypeDescription
-NewManagedBeanWizardBase_Title = New Managed Bean Wizard
-
-NewManagedBeanCreationWizard_Title = Create a Managed Bean
-
-IntroWizardPage_Title = Introduction Page
-IntroWizardPage_Intro = This wizard walks through the steps to create a managed bean.
-
-ManagedBeanWizardSelectionPage_Title = Managed Bean Selection Page
-ManagedBeanWizardSelectionPage_Description = Select a managed bean type to proceed
-ManagedBeanWizardSelectionPage_Group = Please select the managed bean type:
-ManagedBeanWizardSelectionPage_HelpContextID = com.sybase.stf.jmt.new_managedbean_wizard
-
-Registry_LoadWizard_Error = Error loading wizard element, couldn't initialize!
-####################################################
-# Resource message for NewWizard
-####################################################
-NewWizard_Title_WizardDefault = call setWindowTitle(String) in your wizard sub-class
-
-##################################################################
-# Resource message for NewJavaManagedBeanWizards and its' pages.
-##################################################################
-ManagedBeanPropertyWizardPage_Title = Managed Bean Configuration
-ManagedBeanPropertyWizardPage_Description = Set managed bean's name and scope, and create or update Managed Bean's properties, their types and default values.
-
-ManagedBeanPropertyWizardPage_General = General
-
-ManagedBeanPropertyWizardPage_ManagedBeanName = Name:
-ManagedBeanPropertyWizardPage_ManagedBeanScope = Scope:
-ManagedBeanPropertyWizardPage_ManagedBeanDescription = Description:
-
-ManagedBeanPropertyWizardPage_ManagedBeanProperty = Properties:
-ManagedBeanPropertyWizardPage_PropertyName = Property Name
-ManagedBeanPropertyWizardPage_Type = Property Type
-ManagedBeanPropertyWizardPage_Value = Value
-ManagedBeanPropertyWizardPage_Button_Add = Add...
-ManagedBeanPropertyWizardPage_Button_Edit = Edit...
-ManagedBeanPropertyWizardPage_Button_Remove = Remove
-
-ManagedBeanPropertyWizardPage_Warning_MissingManagedBeanName = Managed bean name must be entered!
-ManagedBeanPropertyWizardPage_Warning_InvalidManagedBeanName = Managed bean name is not valid!
-ManagedBeanPropertyWizardPage_Warning_DuplicateManagedBeanName = Managed bean name can not be duplicate!
-
-ManagedBeanPropertyEditDialog_PropertyName = Property name:
-ManagedBeanPropertyEditDialog_DataType = Data type:
-ManagedBeanPropertyEditDialog_InitialValue = Initial value:
-
-ManagedBeanPropertyEditDialog_Title_NewPropertyEntry = New Property Entry
-ManagedBeanPropertyEditDialog_Title_ExistingPropertyEntry = Existing Property Entry
-
-FacesConfigSelectionWizardPage_Title = Faces-Config File
-FacesConfigSelectionWizardPage_Description = Select an existing faces-config file, such as faces-config.xml, to save the new managed bean.
-
-FacesConfigSelectionWizardPage_Project = Project name:
-FacesConfigSelectionWizardPage_FacesConfig = Faces-Config file:
-FacesConfigSelectionWizardPage_FacesConfig_Browser = Browse...
-
-FacesConfigSelectionWizardPage_Warning_MissingProjectName = Project name must be entered!
-FacesConfigSelectionWizardPage_Warning_MissingFacesConfigName = Faces-Config file name must be entered!
-FacesConfigSelectionWizardPage_Warning_InvalidFacesConfigName = Faces-config file name does not exist!
-FacesConfigSelectionWizardPage_Warning_InvalidFacesConfigContent = ''{0}'' is not a valid faces-config file!
-FacesConfigSelectionWizardPage_Warning_FacesConfigNotDefinedInWebDotXML = ''{0}'' is not specified in web.xml file!
-FacesConfigSelectionWizardPage_HelpContextID = com.sybase.stf.jmt.select_facesconfig_page
-
-FacesConfigFileSelectionDialog_Title = Faces-config File Selection
-FacesConfigFileSelectionDialog_Description = Select a faces-config file in the current project.
-
-JavaSelectionWizardPage_Title = Java Class Selection
-JavaSelectionWizardPage_Description = Search for an existing class or generate a new one.
-JavaSelectionWizardPage_Group = Source type for Java class
-JavaSelectionWizardPage_Search = Using an existing Java class
-JavaSelectionWizardPage_Search_Description = (This option will use an existing java class as managed bean's type.)
-JavaSelectionWizardPage_Search_ClassName = Qualified class name:
-JavaSelectionWizardPage_Search_ClassName_Browse = Browse...
-JavaSelectionWizardPage_Create = Create a new Java class
-JavaSelectionWizardPage_Create_Description = (This option will create a new java class in the next wizard page.)
-
-JavaSelectionWizardPage_FindType = Find Type
-JavaSelectionWizardPage_FindType_Filter = Choose a type (?=any character, *=any string):
-JavaSelectionWizardPage_Error_ClassIsEmpty = The type name should not be empty.
-JavaSelectionWizardPage_Error_ClassIsNotDefined = The type name ''{0}'' does not exist.
-JavaSelectionWizardPage_HelpContextID = com.sybase.stf.jmt.new_java_managedbean_wizard
-
-NewJavaManagedBeanWizard_Summary_ProjectName = Project name
-NewJavaManagedBeanWizard_Summary_FacesConfigFileName = Faces-Config file name
-NewJavaManagedBeanWizard_Summary_TypeName = Type name
-NewJavaManagedBeanWizard_Summary_PackageName = Package name
-NewJavaManagedBeanWizard_Summary_SourceFolder = Source folder
-NewJavaManagedBeanWizard_Summary_ManagedBeanName = Managed bean name
-NewJavaManagedBeanWizard_Summary_ManagedBeanScope = Managed bean scope
-NewJavaManagedBeanWizard_Summary_ClassName = Managed bean class
-NewJavaManagedBeanWizard_Summary_Description = Description
-NewJavaManagedBeanWizard_SummaryPage_Description = A new java managed bean will be created.
-
-NewJavaManagedBeanWizard_Task_CreateNewManagedBean = Creating a new managed bean
-NewJavaManagedBeanWizard_Task_CreateNewJavaClass = Creating a new java class
-
-DuplicateBeanWizard_Title = Set Duplicated Managed Bean
-DuplicateBeanPage_Title = Set duplicated managed bean
-DuplicateBeanPage_Description = Overwrite the duplicated managed bean or create a new one.
-
-DuplicateBeanGroup_Group_Label = Duplicated Managed Bean Options
-DuplicateBeanGroup_OverwriteButton_Text = Overwrite an existing managed bean using the new one
-
-DuplicateBeanGroup_NewButton_Text = Create a new managed bean
-DuplicateBeanGroup_NewNameDialogField_Label = New managed bean name:
-
-DuplicateBeanGroup_Error_EmptyManagedBeanName = The managed bean name can not be empty.
-DuplicateBeanGroup_Error_InvalidManagedBeanName = The managed bean name ''{0}'' contains invalid string, such as #,!.
-DuplicateBeanGroup_Error_DuplicatedManagedBeanName = The managed bean name ''{0}'' is duplicated.
-
-WizardSummaryPage_Title_WizardSummary = Wizard Summarys
-WizardSummaryPage_Summary_SummaryDesc = A new java managed bean will be created.
-WizardSummaryPage_Label_Field = Field
-WizardSummaryPage_Label_Value = Value
-
-
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.classpath b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.cvsignore
deleted file mode 100644
index 3d95935d6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.cvsignore
+++ /dev/null
@@ -1,5 +0,0 @@
-bin
-build.xml
-javaCompiler...args
-temp.folder
-@dot
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.project b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.project
deleted file mode 100644
index 4246d9b44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.standard.tagsupport</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/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.core.resources.prefs b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index ecfb123e4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Sun May 27 16:04:06 EDT 2007
-eclipse.preferences.version=1
-encoding/<project>=ISO-8859-1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 8f6d80083..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,65 +0,0 @@
-#Mon Jun 30 15:56:32 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.compliance=1.5
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-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=error
-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.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 78bb525d2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 11:56:44 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/META-INF/MANIFEST.MF
deleted file mode 100644
index d5b0848a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,15 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jst.jsf.standard.tagsupport;singleton:=true
-Bundle-Version: 1.1.102.qualifier
-Bundle-Localization: plugin
-Bundle-Activator: org.eclipse.jst.jsf.standard.tagsupport.StandardTagSupportPlugin
-Require-Bundle: org.eclipse.ui;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.core.runtime;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.emf.ecore.xmi;bundle-version="[2.2.0,3.0.0)"
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
-Export-Package: org.eclipse.jst.jsf.standard.tagsupport;x-internal:=true
-Bundle-Vendor: %pluginProvider
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/about.html b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/about.html
deleted file mode 100644
index 8e5605900..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/build.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/build.properties
deleted file mode 100644
index aa99bac66..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/build.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- metadata/,\
- plugin.properties,\
- about.html,\
- icons/
-javacSource=1.5
-javacTarget=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_A.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_A.gif
deleted file mode 100644
index 4c57d0e22..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_A.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_FORM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_FORM.gif
deleted file mode 100644
index cc27deb97..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_FORM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HEAD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HEAD.gif
deleted file mode 100644
index 4bdc052c9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HEAD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HR.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HR.gif
deleted file mode 100644
index 44e283d13..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_HR.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_IMG.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_IMG.gif
deleted file mode 100644
index 776fc8feb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_IMG.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_BUTTON.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_BUTTON.gif
deleted file mode 100644
index 9ead4e44a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_BUTTON.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_CHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_CHECKBOX.gif
deleted file mode 100644
index 4a02dde9c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_CHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_HIDDEN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_HIDDEN.gif
deleted file mode 100644
index d14d09fa9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_HIDDEN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_IMAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_IMAGE.gif
deleted file mode 100644
index b12850f31..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_IMAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_PASSWORD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_PASSWORD.gif
deleted file mode 100644
index 05d5fe549..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_PASSWORD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_RADIO.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_RADIO.gif
deleted file mode 100644
index f6aeac0f5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_RADIO.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_TEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_TEXT.gif
deleted file mode 100644
index 1c8fa1ecd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_INPUT_TEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_OBJECT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_OBJECT.gif
deleted file mode 100644
index cba93bf83..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_OBJECT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_SELECT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_SELECT.gif
deleted file mode 100644
index 3831d9583..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_SELECT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TABLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TABLE.gif
deleted file mode 100644
index 9873b0928..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TABLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TEXTAREA.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TEXTAREA.gif
deleted file mode 100644
index 25f22d860..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/large/HTML_TEXTAREA.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_A.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_A.gif
deleted file mode 100644
index 5fd9c9494..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_A.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_BR.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_BR.gif
deleted file mode 100644
index b46868549..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_BR.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_FORM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_FORM.gif
deleted file mode 100644
index 3081f3235..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_FORM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HEAD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HEAD.gif
deleted file mode 100644
index 4bdc052c9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HEAD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HR.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HR.gif
deleted file mode 100644
index 19ab61434..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_HR.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_IMG.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_IMG.gif
deleted file mode 100644
index 115cbc6fe..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_IMG.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_BUTTON.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_BUTTON.gif
deleted file mode 100644
index 8e721c512..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_BUTTON.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_CHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_CHECKBOX.gif
deleted file mode 100644
index 00da14ec8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_CHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_HIDDEN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_HIDDEN.gif
deleted file mode 100644
index f18865b9a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_HIDDEN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_IMAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_IMAGE.gif
deleted file mode 100644
index 2a7596399..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_IMAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_PASSWORD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_PASSWORD.gif
deleted file mode 100644
index 25c2e2670..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_PASSWORD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_RADIO.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_RADIO.gif
deleted file mode 100644
index 2598367c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_RADIO.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_TEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_TEXT.gif
deleted file mode 100644
index 7f506d902..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_INPUT_TEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_OBJECT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_OBJECT.gif
deleted file mode 100644
index 745f6d914..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_OBJECT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_SELECT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_SELECT.gif
deleted file mode 100644
index 247efe030..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_SELECT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TABLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TABLE.gif
deleted file mode 100644
index d11c996e5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TABLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TEXTAREA.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TEXTAREA.gif
deleted file mode 100644
index a2fa616a9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/HTML/small/HTML_TEXTAREA.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ACTIONLISTENER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ACTIONLISTENER.gif
deleted file mode 100644
index 5dc1abc6c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ACTIONLISTENER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ATTRIBUTE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ATTRIBUTE.gif
deleted file mode 100644
index d99d2eba7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_ATTRIBUTE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTDATETIME.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTDATETIME.gif
deleted file mode 100644
index f9f3409e9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTDATETIME.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTER.gif
deleted file mode 100644
index a8f5d3a78..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTNUMBER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTNUMBER.gif
deleted file mode 100644
index 21b24f031..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_CONVERTNUMBER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_FACET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_FACET.gif
deleted file mode 100644
index 6424c7faf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_FACET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_LOADBUNDLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_LOADBUNDLE.gif
deleted file mode 100644
index e1cd4e1bb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_LOADBUNDLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_PARAM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_PARAM.gif
deleted file mode 100644
index 79e07c22c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_PARAM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEM.gif
deleted file mode 100644
index 3831d9583..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEMS.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEMS.gif
deleted file mode 100644
index b2a1c43df..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SELECTITEMS.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SUBVIEW.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SUBVIEW.gif
deleted file mode 100644
index f37f41273..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_SUBVIEW.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATEDOUBLERANGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATEDOUBLERANGE.gif
deleted file mode 100644
index afee57bcf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATEDOUBLERANGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELENGTH.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELENGTH.gif
deleted file mode 100644
index afee57bcf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELENGTH.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELONGRANGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELONGRANGE.gif
deleted file mode 100644
index afee57bcf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATELONGRANGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATOR.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATOR.gif
deleted file mode 100644
index afee57bcf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALIDATOR.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALUECHANGELISTENER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALUECHANGELISTENER.gif
deleted file mode 100644
index 2fafdebbc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VALUECHANGELISTENER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VERBATIM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VERBATIM.gif
deleted file mode 100644
index d284eb9f5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VERBATIM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VIEW.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VIEW.gif
deleted file mode 100644
index 98294c189..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/large/JSF_VIEW.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ACTIONLISTENER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ACTIONLISTENER.gif
deleted file mode 100644
index 67b2d33f6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ACTIONLISTENER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ATTRIBUTE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ATTRIBUTE.gif
deleted file mode 100644
index b77c75004..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_ATTRIBUTE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTDATETIME.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTDATETIME.gif
deleted file mode 100644
index 779d8205f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTDATETIME.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTER.gif
deleted file mode 100644
index 16466edfd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTNUMBER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTNUMBER.gif
deleted file mode 100644
index 938f364f4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_CONVERTNUMBER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_FACET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_FACET.gif
deleted file mode 100644
index b9cb1485b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_FACET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_LOADBUNDLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_LOADBUNDLE.gif
deleted file mode 100644
index 8f40ee135..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_LOADBUNDLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_PARAM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_PARAM.gif
deleted file mode 100644
index b3e0727e8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_PARAM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEM.gif
deleted file mode 100644
index 247efe030..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEMS.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEMS.gif
deleted file mode 100644
index 7fb0974db..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SELECTITEMS.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SUBVIEW.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SUBVIEW.gif
deleted file mode 100644
index 974801573..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_SUBVIEW.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATEDOUBLERANGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATEDOUBLERANGE.gif
deleted file mode 100644
index 86196e996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATEDOUBLERANGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELENGTH.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELENGTH.gif
deleted file mode 100644
index 86196e996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELENGTH.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELONGRANGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELONGRANGE.gif
deleted file mode 100644
index 86196e996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATELONGRANGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATOR.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATOR.gif
deleted file mode 100644
index 86196e996..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALIDATOR.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALUECHANGELISTENER.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALUECHANGELISTENER.gif
deleted file mode 100644
index a1cd624a9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VALUECHANGELISTENER.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VERBATIM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VERBATIM.gif
deleted file mode 100644
index f12c9df68..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VERBATIM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VIEW.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VIEW.gif
deleted file mode 100644
index c81630a08..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFCORE/small/JSF_VIEW.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COLUMN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COLUMN.gif
deleted file mode 100644
index 381154d55..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COLUMN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDBUTTON.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDBUTTON.gif
deleted file mode 100644
index 9ead4e44a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDBUTTON.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDLINK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDLINK.gif
deleted file mode 100644
index 4c57d0e22..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_COMMANDLINK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_DATATABLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_DATATABLE.gif
deleted file mode 100644
index 9873b0928..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_DATATABLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_FORM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_FORM.gif
deleted file mode 100644
index cc27deb97..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_FORM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_GRAPHICIMAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_GRAPHICIMAGE.gif
deleted file mode 100644
index ad341a5af..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_GRAPHICIMAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTHIDDEN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTHIDDEN.gif
deleted file mode 100644
index d14d09fa9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTHIDDEN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTSECRET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTSECRET.gif
deleted file mode 100644
index 60c0a5d44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTSECRET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXT.gif
deleted file mode 100644
index 4cc147e98..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXTAREA.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXTAREA.gif
deleted file mode 100644
index 25f22d860..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_INPUTTEXTAREA.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGE.gif
deleted file mode 100644
index fb737eb84..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGES.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGES.gif
deleted file mode 100644
index ca050e65f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_MESSAGES.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTFORMAT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTFORMAT.gif
deleted file mode 100644
index ac5920dd5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTFORMAT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLABEL.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLABEL.gif
deleted file mode 100644
index 348aa17b2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLABEL.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLINK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLINK.gif
deleted file mode 100644
index 03b2bf908..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTLINK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTTEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTTEXT.gif
deleted file mode 100644
index 295ecc4e8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_OUTPUTTEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGRID.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGRID.gif
deleted file mode 100644
index a31479c3f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGRID.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGROUP.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGROUP.gif
deleted file mode 100644
index da85fe9e8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_PANELGROUP.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTBOOLEANCHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTBOOLEANCHECKBOX.gif
deleted file mode 100644
index 4a02dde9c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTBOOLEANCHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYCHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYCHECKBOX.gif
deleted file mode 100644
index 31b1f37c5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYCHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYLISTBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYLISTBOX.gif
deleted file mode 100644
index 0ed94433f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYLISTBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYMENU.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYMENU.gif
deleted file mode 100644
index dc1dbbc8b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTMANYMENU.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONELISTBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONELISTBOX.gif
deleted file mode 100644
index a1c257e59..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONELISTBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONEMENU.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONEMENU.gif
deleted file mode 100644
index 3686b5cc1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONEMENU.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONERADIO.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONERADIO.gif
deleted file mode 100644
index f6aeac0f5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/large/JSF_SELECTONERADIO.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COLUMN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COLUMN.gif
deleted file mode 100644
index 5a3db49aa..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COLUMN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDBUTTON.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDBUTTON.gif
deleted file mode 100644
index 8e721c512..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDBUTTON.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDLINK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDLINK.gif
deleted file mode 100644
index 5fd9c9494..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_COMMANDLINK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_DATATABLE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_DATATABLE.gif
deleted file mode 100644
index d11c996e5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_DATATABLE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_FORM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_FORM.gif
deleted file mode 100644
index 3081f3235..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_FORM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_GRAPHICIMAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_GRAPHICIMAGE.gif
deleted file mode 100644
index a988c1d5f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_GRAPHICIMAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTHIDDEN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTHIDDEN.gif
deleted file mode 100644
index f18865b9a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTHIDDEN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTSECRET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTSECRET.gif
deleted file mode 100644
index 13dbf621a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTSECRET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXT.gif
deleted file mode 100644
index 7f506d902..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXTAREA.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXTAREA.gif
deleted file mode 100644
index a2fa616a9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_INPUTTEXTAREA.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGE.gif
deleted file mode 100644
index 7d0c261e2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGES.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGES.gif
deleted file mode 100644
index 6f43980a3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_MESSAGES.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTFORMAT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTFORMAT.gif
deleted file mode 100644
index 29dcd77f4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTFORMAT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLABEL.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLABEL.gif
deleted file mode 100644
index b957bca24..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLABEL.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLINK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLINK.gif
deleted file mode 100644
index 521695662..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTLINK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTTEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTTEXT.gif
deleted file mode 100644
index 084514528..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_OUTPUTTEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGRID.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGRID.gif
deleted file mode 100644
index dd22a9991..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGRID.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGROUP.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGROUP.gif
deleted file mode 100644
index 0a13d8cca..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_PANELGROUP.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTBOOLEANCHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTBOOLEANCHECKBOX.gif
deleted file mode 100644
index 00da14ec8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTBOOLEANCHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYCHECKBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYCHECKBOX.gif
deleted file mode 100644
index 2e2370d31..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYCHECKBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYLISTBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYLISTBOX.gif
deleted file mode 100644
index a20aed559..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYLISTBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYMENU.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYMENU.gif
deleted file mode 100644
index 4cfeaa84b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTMANYMENU.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONELISTBOX.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONELISTBOX.gif
deleted file mode 100644
index f6445ed39..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONELISTBOX.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONEMENU.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONEMENU.gif
deleted file mode 100644
index 04a0d4304..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONEMENU.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONERADIO.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONERADIO.gif
deleted file mode 100644
index 2598367c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSFHTML/small/JSF_SELECTONERADIO.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DECLARATION.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DECLARATION.gif
deleted file mode 100644
index 5403f7229..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DECLARATION.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.INCLUDE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.INCLUDE.gif
deleted file mode 100644
index 592667047..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.INCLUDE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.PAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.PAGE.gif
deleted file mode 100644
index e21e763b9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.PAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.TAGLIB.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.TAGLIB.gif
deleted file mode 100644
index 723a10de7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_DIRECTIVE.TAGLIB.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_EXPRESSION.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_EXPRESSION.gif
deleted file mode 100644
index 53a23e102..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_EXPRESSION.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FALLBACK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FALLBACK.gif
deleted file mode 100644
index 2507aacd0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FALLBACK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FORWARD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FORWARD.gif
deleted file mode 100644
index 774759510..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_FORWARD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_GETPROPERTY.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_GETPROPERTY.gif
deleted file mode 100644
index 4d11f8d44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_GETPROPERTY.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_INCLUDE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_INCLUDE.gif
deleted file mode 100644
index 88e62b4cc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_INCLUDE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAM.gif
deleted file mode 100644
index 79e07c22c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAMS.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAMS.gif
deleted file mode 100644
index 9f517aeb0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PARAMS.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PLUGIN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PLUGIN.gif
deleted file mode 100644
index 2ba7b4b11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_PLUGIN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_ROOT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_ROOT.gif
deleted file mode 100644
index 922b61d03..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_ROOT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SCRIPTLET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SCRIPTLET.gif
deleted file mode 100644
index a1d2e61c8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SCRIPTLET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SETPROPERTY.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SETPROPERTY.gif
deleted file mode 100644
index 4d11f8d44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_SETPROPERTY.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_TEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_TEXT.gif
deleted file mode 100644
index 4cc147e98..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_TEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_USEBEAN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_USEBEAN.gif
deleted file mode 100644
index 9d54e8b0c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/large/JSP_USEBEAN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DECLARATION.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DECLARATION.gif
deleted file mode 100644
index 35f48efff..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DECLARATION.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.INCLUDE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.INCLUDE.gif
deleted file mode 100644
index 1ef9c8fa9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.INCLUDE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.PAGE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.PAGE.gif
deleted file mode 100644
index 37c1e7cd8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.PAGE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.TAGLIB.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.TAGLIB.gif
deleted file mode 100644
index 33ef3d820..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_DIRECTIVE.TAGLIB.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_EXPRESSION.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_EXPRESSION.gif
deleted file mode 100644
index 66fd649da..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_EXPRESSION.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FALLBACK.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FALLBACK.gif
deleted file mode 100644
index 4fb415010..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FALLBACK.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FORWARD.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FORWARD.gif
deleted file mode 100644
index 1d3bafb31..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_FORWARD.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_GETPROPERTY.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_GETPROPERTY.gif
deleted file mode 100644
index af4450a4b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_GETPROPERTY.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_INCLUDE.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_INCLUDE.gif
deleted file mode 100644
index 2584c3185..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_INCLUDE.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAM.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAM.gif
deleted file mode 100644
index b3e0727e8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAM.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAMS.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAMS.gif
deleted file mode 100644
index 40759226c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PARAMS.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PLUGIN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PLUGIN.gif
deleted file mode 100644
index 04bab8e34..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_PLUGIN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_ROOT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_ROOT.gif
deleted file mode 100644
index f6d19d4a0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_ROOT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SCRIPTLET.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SCRIPTLET.gif
deleted file mode 100644
index 1753b9627..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SCRIPTLET.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SETPROPERTY.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SETPROPERTY.gif
deleted file mode 100644
index af4450a4b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_SETPROPERTY.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_TEXT.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_TEXT.gif
deleted file mode 100644
index 7f506d902..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_TEXT.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_USEBEAN.gif b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_USEBEAN.gif
deleted file mode 100644
index ba33db70f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/icons/palette/JSP/small/JSP_USEBEAN.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.properties
deleted file mode 100644
index 6a0ee5502..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.properties
+++ /dev/null
@@ -1,96 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-A.display-label=Link
-A.description=This element allows the user to navigate the content of the document
-
-BR.display-label=Line Break
-BR.description=This element is used to enforce a line break
-
-INPUT.BUTTON.display-label=Button
-INPUT.BUTTON.description=An INPUT element with TYPE=SUBMIT represents an input option, typically a button, that instructs the user agent to submit the form
-
-INPUT.CHECKBOX.display-label=Checkbox
-INPUT.CHECKBOX.description=An INPUT element with TYPE=CHECKBOX represents a boolean choice. A set of such elements with the same name represents an n-of-many choice field
-
-INPUT.HIDDEN.display-label=Hidden Field
-INPUT.HIDDEN.description=An INPUT element with TYPE=HIDDEN represents a hidden field.The user does not interact with this field; instead, the VALUE attribute specifies the value of the field
-
-INPUT.IMAGE.display-label=Image Button
-INPUT.IMAGE.description=An INPUT element with TYPE=IMAGE specifies an image resource to display, and allows input of two form fields: the x and y coordinate of a pixel chosen from the image
-
-INPUT.PASSWORD.display-label=Password Field
-INPUT.PASSWORD.description=An INPUT element with TYPE=PASSWORD is a text field as above, except that the value is obscured as it is entered
-
-INPUT.RADIO.display-label=Radio Button
-INPUT.RADIO.description=An INPUT element with TYPE=RADIO represents a boolean choice. A set of such elements with the same name represents a 1-of-many choice field
-
-INPUT.TEXT.display-label=Text Field
-INPUT.TEXT.description=The default vaule of the TYPE attribute is TEXT, indicating a single line text entry field
-
-FORM.display-label=Form
-FORM.description=The FORM element contains a sequence of input elements, along with document structuring elements
-
-HR.display-label=Horizontal Rule
-HR.description=The HR element is a divider between sections of text; typically a full width horizontal rule or equivalent graphic
-
-IMG.display-label=Image
-IMG.description=The IMG element refers to an image or icon via a hyperlink
-
-SELECT.display-label=Select
-SELECT.description=The SELECT element constrains the form field to an enumerated list of values
-
-TABLE.display-label=Table
-TABLE.description=HTML Tables are contained within a TABLE element. The TABLE element denotes the range of the table, and uses attribute to define properties of it
-
-TEXTAREA.display-label=Text Area
-TEXTAREA.description=The TEXTAREA element represents a multi-line text field
-
-
-any.dir.displayed-values.ltr=ltr (left-to-right)
-any.dir.displayed-values.rtl=rtl (right-to-left)
-
-any.frame.displayed-values.none=none (no sides, default value)
-any.frame.displayed-values.above=above (top side only)
-any.frame.displayed-values.below=below (bottom side only)
-any.frame.displayed-values.hsides=hsides (top and bottom sides only)
-any.frame.displayed-values.vsides=vsides (right and left sides only)
-any.frame.displayed-values.lhs=lhs (left hand side only)
-any.frame.displayed-values.rhs=rhs (right hand side only)
-any.frame.displayed-values.box=box (all four sides)
-any.frame.displayed-values.border=border (all four sides)
-
-any.rules.displayed-values.none=none (no rules, default value)
-any.rules.displayed-values.groups=groups (between row groups)
-any.rules.displayed-values.rows=rows (between rows only)
-any.rules.displayed-values.cols=cols (between columns only)
-any.rules.displayed-values.all=all (between all rows and columns)
-
-any.shape.displayed-values.default=default (entire region)
-any.shape.displayed-values.rect=rect (rectangular region)
-any.shape.displayed-values.circle=circle (circular region)
-any.shape.displayed-values.poly=poly (polygonal region)
-
-#categories
-property.category.event=Event
-property.category.language=Language
-property.category.html=HTML
-property.category.css=CSS
-property.category.general=General
-property.category.accessibility=Accessibility
-property.category.visualProperty=VisualProperty
-property.category.browser.specific=Browser Specific
-property.category.core=Core
-property.category.content=Content
-property.category.data.binding=Data Binding
-property.category.dynamic=Dynamic
-property.category.file=File
-property.category.image=Image
-
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.xml
deleted file mode 100644
index b069be651..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/html.xml
+++ /dev/null
@@ -1,729 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- xmlns:qe="http://org.eclipse.jsf.pagedesigner/quickEditTabSections.ecore"
- id="HTML"
- type="tagFile">
- <trait id="paletteInfos" >
- <value xsi:type="pi:PaletteInfos">
- <item id="BR"/>
- <item id="INPUT.TEXT" tag="INPUT"/>
- <item id="INPUT.BUTTON" tag="INPUT">
- <display-label>%INPUT.BUTTON.display-label</display-label>
- <description>%INPUT.BUTTON.description</description>
- <small-icon>small/HTML_INPUT_BUTTON.gif</small-icon>
- <large-icon>small/HTML_INPUT_BUTTON.gif</large-icon>
- <tag-create>
- <attribute id="type" value="submit"/>
- </tag-create>
- </item>
- <item id="INPUT.CHECKBOX" tag="INPUT">
- <display-label>%INPUT.CHECKBOX.display-label</display-label>
- <description>%INPUT.CHECKBOX.description</description>
- <small-icon>small/HTML_INPUT_CHECKBOX.gif</small-icon>
- <large-icon>small/HTML_INPUT_CHECKBOX.gif</large-icon>
- <tag-create>
- <attribute id="type" value="checkbox"/>
- </tag-create>
- </item>
- <item id="FORM"/>
- <item id="INPUT.HIDDEN" tag="INPUT">
- <display-label>%INPUT.HIDDEN.display-label</display-label>
- <description>%INPUT.HIDDEN.description</description>
- <small-icon>small/HTML_INPUT_HIDDEN.gif</small-icon>
- <large-icon>small/HTML_INPUT_HIDDEN.gif</large-icon>
- <tag-create>
- <attribute id="type" value="hidden"/>
- </tag-create>
- </item>
- <item id="HR"/>
- <item id="IMG"/>
- <item id="INPUT.IMAGE" tag="INPUT">
- <display-label>%INPUT.IMAGE.display-label</display-label>
- <description>%INPUT.IMAGE.description</description>
- <small-icon>small/HTML_INPUT_IMAGE.gif</small-icon>
- <large-icon>small/HTML_INPUT_IMAGE.gif</large-icon>
- <tag-create>
- <attribute id="type" value="image"/>
- </tag-create>
- </item>
- <item id="A"/>
- <item id="INPUT.PASSWORD" tag="INPUT">
- <display-label>%INPUT.PASSWORD.display-label</display-label>
- <description>%INPUT.PASSWORD.description</description>
- <small-icon>small/HTML_INPUT_PASSWORD.gif</small-icon>
- <large-icon>small/HTML_INPUT_PASSWORD.gif</large-icon>
- <tag-create>
- <attribute id="type" value="password"/>
- </tag-create>
- </item>
- <item id="INPUT.RADIO" tag="INPUT">
- <display-label>%INPUT.RADIO.display-label</display-label>
- <description>%INPUT.RADIO.description</description>
- <small-icon>small/HTML_INPUT_RADIO.gif</small-icon>
- <large-icon>small/HTML_INPUT_RADIO.gif</large-icon>
- <tag-create>
- <attribute id="type" value="radio"/>
- </tag-create>
- </item>
- <item id="SELECT"/>
- <item id="TABLE"/>
- <item id="TEXTAREA"/>
- </value>
- </trait>
-
- <trait id="images-base-path">
- <value>$nl$/icons/palette/HTML</value>
- </trait>
-
- <trait id="display-label">
- <value>HTML 4.0</value>
- </trait>
-
- <entity id="A">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%A.display-label</value>
- </trait>
- <trait id="description">
- <value>%A.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_A.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_A.gif</value>
- </trait>
- </entity>
- <entity id="BODY">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="common-html-attributes"/>
- </entity>
- <entity id="BR">
- <include-entity-group id="common-core-attributes"/>
- <trait id="display-label">
- <value>%BR.display-label</value>
- </trait>
- <trait id="description">
- <value>%BR.description</value>
- </trait>
- <trait id="expert">
- <value>true</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_BR.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_BR.gif</value>
- </trait>
- </entity>
- <entity id="INPUT">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%INPUT.TEXT.display-label</value>
- </trait>
- <trait id="description">
- <value>%INPUT.TEXT.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_INPUT_TEXT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_INPUT_TEXT.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="FORM">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <include-entity-group id="form-event-attributes"/>
- <trait id="display-label">
- <value>%FORM.display-label</value>
- </trait>
- <trait id="description">
- <value>%FORM.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_FORM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_FORM.gif</value>
- </trait>
- </entity>
- <entity id="HEAD">
- <include-entity-group id="common-language-attributes"/>
- </entity>
- <entity id="HR">
- <include-entity-group id="common-core-attributes"/>
- <trait id="display-label">
- <value>%HR.display-label</value>
- </trait>
- <trait id="description">
- <value>%HR.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_HR.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_HR.gif</value>
- </trait>
- </entity>
- <entity id="HTML">
- <include-entity-group id="common-language-attributes"/>
- </entity>
- <entity id="IMG">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%IMG.display-label</value>
- </trait>
- <trait id="description">
- <value>%IMG.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_IMG.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_IMG.gif</value>
- </trait>
- </entity>
- <entity id="LINK">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LinkType</value>
- </trait>
- </entity>
- </entity>
- <entity id="META">
- <include-entity-group id="common-language-attributes"/>
- <entity id="content">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ContentType</value>
- </trait>
- </entity>
- </entity>
- <entity id="OBJECT">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="small-icon">
- <value>small/HTML_OBJECT.gif</value>
- </trait>
- </entity>
- <entity id="SELECT">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%SELECT.display-label</value>
- </trait>
- <trait id="description">
- <value>%SELECT.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_SELECT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_SELECT.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="TABLE">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%TABLE.display-label</value>
- </trait>
- <trait id="description">
- <value>%TABLE.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_TABLE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_TABLE.gif</value>
- </trait>
- </entity>
- <entity id="TEXTAREA">
- <include-entity-group id="common-core-attributes"/>
- <include-entity-group id="common-language-attributes"/>
- <include-entity-group id="common-event-attributes"/>
- <trait id="display-label">
- <value>%TEXTAREA.display-label</value>
- </trait>
- <trait id="description">
- <value>%TEXTAREA.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/HTML_TEXTAREA.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/HTML_TEXTAREA.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="TITLE">
- <include-entity-group id="common-language-attributes"/>
- </entity>
- <entityGroup id="common-html-attributes">
- <entity id="align">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>char</item>
- <item>left</item>
- <item>center</item>
- <item>justify</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
-
- <entity id="alt">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="src">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="accesskey">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CharacterType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="accept">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="accept-charset">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="border">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="disabled">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="height">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="ismap">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="longdesc">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.URIType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="maxlength">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="readonly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- </entity>
- <entity id="rel">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LinkType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="rev">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LinkType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="rows">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="shape">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>rect</item>
- <item>circle</item>
- <item>poly</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%any.shape.displayed-values.default</item>
- <item>%any.shape.displayed-values.rect</item>
- <item>%any.shape.displayed-values.circle</item>
- <item>%any.shape.displayed-values.poly</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="size">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="tabindex">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="valid-maximum"><value>32767</value></trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="target">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>_self</item>
- <item>_blank</item>
- <item>_parent</item>
- <item>_top</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="usemap">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="valign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>middle</item>
- <item>top</item>
- <item>baseline</item>
- <item>bottom</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
- <entity id="width">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LengthType</value>
- </trait>
- <trait id="category">
- <value>%property.category.html</value>
- </trait>
- </entity>
-
- </entityGroup>
- <entityGroup id="common-core-attributes">
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="class">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="style">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSStyleType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- <entity id="title">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.core</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-event-attributes">
- <entity id="onclick">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="ondblclick">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmousedown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseup">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseover">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmousemove">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onmouseout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeypress">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeydown">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onkeyup">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <!--almost common events - should be refactored-->
- <entity id="onblur">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onchange">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onfocus">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onselect">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="form-event-attributes">
- <entity id="onsubmit">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- <entity id="onreset">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ScriptType</value>
- </trait>
- <trait id="category">
- <value>%property.category.event</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-language-attributes" >
- <entity id="dir">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>ltr</item>
- <item>rtl</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%any.dir.displayed-values.ltr</item>
- <item>%any.dir.displayed-values.rtl</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.language</value>
- </trait>
- </entity>
- <entity id="lang">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LanguageCodeType</value>
- </trait>
- <trait id="category">
- <value>%property.category.language</value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core.xml
deleted file mode 100644
index 3ca4a9899..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core.xml
+++ /dev/null
@@ -1,509 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore"
- xmlns:cnst="http://org.eclipse.jst.jsf.core/constraints.ecore"
- xmlns:qe="http://org.eclipse.jsf.pagedesigner/QuickEditTabSections.ecore"
- id="http://java.sun.com/jsf/core"
- type="tagFile">
-
- <entity id="actionListener" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="type"/>
- </value>
- </trait>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.JavaClassType
- </value>
- </trait>
- <trait id="valid-interfaces">
- <value>javax.faces.event.ActionListener</value>
- </trait>
- </entity>
- </entity>
- <entity id="attribute" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="name"/>
- <section id="value"/>
- </value>
- </trait>
- </entity>
- <entity id="convertDateTime" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="section.general.convertDateTime" type="SECTION"/>
- </value>
- </trait>
- <entity id="dateStyle">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.StringType
- </value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>short</item>
- <item>medium</item>
- <item>long</item>
- <item>full</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- <entity id="timeStyle">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.StringType
- </value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>default</item>
- <item>short</item>
- <item>medium</item>
- <item>long</item>
- <item>full</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>default</value>
- </trait>
- </entity>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.StringType
- </value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>date</item>
- <item>time</item>
- <item>both</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>both</value>
- </trait>
- </entity>
- <entity id="pattern">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.DateTimePatternType
- </value>
- </trait>
- </entity>
- <entity id="locale">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LocaleType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="convertNumber" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="section.general.convertNumber" type="SECTION"/>
- </value>
- </trait>
- <entity id="groupingUsed">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>true</value>
- </trait>
- </entity>
- <entity id="integerOnly">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- </entity>
- <entity id="maxFractionDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="maxIntegerDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="minFractionDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="minIntegerDigits">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.IntegerType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.StringType
- </value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>number</item>
- <item>currency</item>
- <item>percent</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>number</value>
- </trait>
- </entity>
- <entity id="locale">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LocaleType
- </value>
- </trait>
- </entity>
- <entity id="pattern">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.NumberPatternType
- </value>
- </trait>
- </entity>
- <entity id="currencyCode">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.CurrencyCodeType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="converter" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="converterId"/>
- </value>
- </trait>
- <entity id="converterId">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.FacesConfigConverterIDType
- </value>
- </trait>
- <trait id="config-type">
- <value>javax.faces.convert.Converter</value>
- </trait>
- </entity>
- </entity>
- <entity id="facet" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="name"/>
- </value>
- </trait>
- </entity>
- <entity id="loadBundle" type="tag">
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="basename"/>
- <section id="var"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="var">
- <trait id="contributes-value-binding">
- <value>true</value>
- </trait>
- <trait id="value-binding-scope">
- <value>request</value>
- </trait>
- <trait id="value-binding-symbol-factory">
- <value>org.eclipse.jst.jsf.designtime.core.loadBundle</value>
- </trait>
- </entity>
- <entity id="basename">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.ResourceBundleType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="param" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="name"/>
- <section id="value"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="selectItem" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="itemLabel"/>
- <section id="itemValue"/>
- </value>
- </trait>
- <entity id="itemDisabled">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.ValueBindingType
- </value>
- </trait>
- <trait id="runtime-return-type">
- <value>javax.faces.model.SelectItem</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectItems" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="binding"/>
- </value>
- </trait>
- </entity>
- <entity id="subview" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- </value>
- </trait>
- <entity id="rendered">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="validateDoubleRange" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="minimum"/>
- <section id="maximum"/>
- </value>
- </trait>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.DoubleType
- </value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.DoubleType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="validateLength" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="minimum"/>
- <section id="maximum"/>
- </value>
- </trait>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LongType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LongType
- </value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- </entity>
- </entity>
- <entity id="validateLongRange" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="minimum"/>
- <section id="maximum"/>
- </value>
- </trait>
- <entity id="maximum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LongType
- </value>
- </trait>
- </entity>
- <entity id="minimum">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.LongType
- </value>
- </trait>
- </entity>
- </entity>
- <entity id="validator" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="validatorId"/>
- </value>
- </trait>
- <entity id="validatorId">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.FacesConfigValidatorIDType
- </value>
- </trait>
- <trait id="config-type">
- <value>javax.faces.validator.Validator</value>
- </trait>
- </entity>
- </entity>
- <entity id="valueChangeListener" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="type"/>
- </value>
- </trait>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.JavaClassType
- </value>
- </trait>
- <trait id="valid-interfaces">
- <value>javax.faces.event.ValueChangeListener</value>
- </trait>
- </entity>
- </entity>
- <entity id="verbatim" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="escape"/>
- </value>
- </trait>
- <entity id="escape">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.BooleanType
- </value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- </entity>
- </entity>
- <entity id="view" type="tag">
- <include-entity-group id="common-core-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="locale"/>
- </value>
- </trait>
- <entity id="locale">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LocaleType </value>
- </trait>
- </entity>
- </entity>
-
- <entityGroup id="common-core-attributes" type="tag">
- <entity id="binding">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.ComponentBindingType
- </value>
- </trait>
- <trait id="runtime-return-type">
- <value>javax.faces.component.UIComponent</value>
- </trait>
- </entity>
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.ComponentIDType
- </value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>
- org.eclipse.jst.jsf.core.attributevalues.ValueBindingType
- </value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_dti.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_dti.xml
deleted file mode 100644
index 975d15382..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_dti.xml
+++ /dev/null
@@ -1,306 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:dti="http://org.eclipse.jsf.pagedesigner/dtinfo.ecore"
- id="http://java.sun.com/jsf/core"
- type="tagFile">
-
- <entity id="actionListener" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_ACTIONLISTENER.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="attribute" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_ATTRIBUTE.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="convertDateTime" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_CONVERTDATETIME.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="converter" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_CONVERTER.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="convertNumber" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_CONVERTNUMBER.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="facet" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- minHeight="10"
- minWidth="10"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="loadBundle" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.LoadBundleOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_LOADBUNDLE.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="param" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_PARAM.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectItem" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_SELECTITEM.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectItems" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_SELECTITEMS.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="subview" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_SUBVIEW.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="validateDoubleRange" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_VALIDATEDOUBLERANGE.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="validateLength" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_VALIDATELENGTH.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="validateLongRange" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_VALIDATELONGRANGE.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="validator" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_VALIDATOR.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="valueChangeListener" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFCORE/small/JSF_VALUECHANGELISTENER.gif"
- widget="true"
-
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="verbatim" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- minHeight="10"
- minWidth="10"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="view" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.properties
deleted file mode 100644
index 1faabda84..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.properties
+++ /dev/null
@@ -1,11 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-JSFCORE.display-label=JSF Core \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.xml
deleted file mode 100644
index 227a40e91..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_core_pi.xml
+++ /dev/null
@@ -1,188 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- id="http://java.sun.com/jsf/core"
- type="tagFile">
-
- <trait id="is-jsf-component-library">
- <value>true</value>
- </trait>
-
- <trait id="paletteInfos" >
- <value xsi:type="pi:PaletteInfos">
- <item id="view"/>
- <item id="validator"/>
- <item id="valueChangeListener"/>
- <item id="actionListener"/>
- <item id="convertDateTime"/>
- <item id="converter"/>
- <item id="convertNumber"/>
- <item id="facet"/>
- <item id="attribute"/>
- <item id="loadBundle"/>
- <item id="param"/>
- <item id="selectItem"/>
- <item id="selectItems"/>
- <item id="subview"/>
- <item id="validateDoubleRange"/>
- <item id="validateLength"/>
- <item id="validateLongRange"/>
- <item id="verbatim"/>
- </value>
- </trait>
-
- <trait id="images-base-path">
- <value>icons/palette/JSFCORE</value>
- </trait>
-
- <trait id="display-label">
- <value>%JSFCORE.display-label</value>
- </trait>
-
- <entity id="actionListener" type="tag">
- <trait id="small-icon">
- <value>small/JSF_ACTIONLISTENER.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_ACTIONLISTENER.gif</value>
- </trait>
- </entity>
- <entity id="attribute" type="tag">
- <trait id="small-icon">
- <value>small/JSF_ATTRIBUTE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_ATTRIBUTE.gif</value>
- </trait>
- </entity>
- <entity id="convertDateTime" type="tag">
- <trait id="small-icon">
- <value>small/JSF_CONVERTDATETIME.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_CONVERTDATETIME.gif</value>
- </trait>
- </entity>
- <entity id="convertNumber" type="tag">
- <trait id="small-icon">
- <value>small/JSF_CONVERTNUMBER.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_CONVERTNUMBER.gif</value>
- </trait>
- </entity>
- <entity id="converter" type="tag">
- <trait id="small-icon">
- <value>small/JSF_CONVERTER.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_CONVERTER.gif</value>
- </trait>
- </entity>
- <entity id="facet" type="tag">
- <trait id="small-icon">
- <value>small/JSF_FACET.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_FACET.gif</value>
- </trait>
- </entity>
- <entity id="loadBundle" type="tag">
- <trait id="small-icon">
- <value>small/JSF_LOADBUNDLE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_LOADBUNDLE.gif</value>
- </trait>
- </entity>
- <entity id="param" type="tag">
- <trait id="small-icon">
- <value>small/JSF_PARAM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_PARAM.gif</value>
- </trait>
- </entity>
- <entity id="selectItem" type="tag">
- <trait id="small-icon">
- <value>small/JSF_SELECTITEM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTITEM.gif</value>
- </trait>
- </entity>
- <entity id="selectItems" type="tag">
- <trait id="small-icon">
- <value>small/JSF_SELECTITEMS.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTITEMS.gif</value>
- </trait>
- </entity>
- <entity id="subview" type="tag">
- <trait id="small-icon">
- <value>small/JSF_SUBVIEW.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SUBVIEW.gif</value>
- </trait>
- </entity>
- <entity id="validateDoubleRange" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VALIDATEDOUBLERANGE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VALIDATEDOUBLERANGE.gif</value>
- </trait>
- </entity>
- <entity id="validateLength" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VALIDATELENGTH.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VALIDATELENGTH.gif</value>
- </trait>
- </entity>
- <entity id="validateLongRange" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VALIDATELONGRANGE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VALIDATELONGRANGE.gif</value>
- </trait>
- </entity>
- <entity id="validator" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VALIDATOR.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VALIDATOR.gif</value>
- </trait>
- </entity>
- <entity id="valueChangeListener" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VALUECHANGELISTENER.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VALUECHANGELISTENER.gif</value>
- </trait>
- </entity>
- <entity id="verbatim" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VERBATIM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VERBATIM.gif</value>
- </trait>
- </entity>
- <entity id="view" type="tag">
- <trait id="small-icon">
- <value>small/JSF_VIEW.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_VIEW.gif</value>
- </trait>
- </entity>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.properties
deleted file mode 100644
index 7279b8b88..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.properties
+++ /dev/null
@@ -1,50 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-messages.layout.displayed-values.list=list (an HTML list)
-messages.layout.displayed-values.table=table (an HTML table)
-
-selectManyCheckbox.layout.displayed-values.pageDirection=pageDirection (list is laid out vertically)
-selectManyCheckbox.layout.displayed-values.lineDirection=lineDirection (list is laid out horizontally)
-
-selectOneRadio.layout.displayed-values.pageDirection=pageDirection (list is laid out vertically)
-selectOneRadio.layout.displayed-values.lineDirection=lineDirection (list is laid out horizontally)
-
-any.frame.displayed-values.none=none (no sides, default value)
-any.frame.displayed-values.above=above (top side only)
-any.frame.displayed-values.below=below (bottom side only)
-any.frame.displayed-values.hsides=hsides (top and bottom sides only)
-any.frame.displayed-values.vsides=vsides (right and left sides only)
-any.frame.displayed-values.lhs=lhs (left hand side only)
-any.frame.displayed-values.rhs=rhs (right hand side only)
-any.frame.displayed-values.box=box (all four sides)
-any.frame.displayed-values.border=border (all four sides)
-
-any.rules.displayed-values.none=none (no rules, default value)
-any.rules.displayed-values.groups=groups (between row groups)
-any.rules.displayed-values.rows=rows (between rows only)
-any.rules.displayed-values.cols=cols (between columns only)
-any.rules.displayed-values.all=all (between all rows and columns)
-
-property.category.event=Event
-property.category.language=Language
-property.category.html=HTML
-property.category.css=CSS
-property.category.jsf=JSF
-property.category.general=General
-property.category.accessibility=Accessibility
-property.category.visualProperty=VisualProperty
-property.category.browser.specific=Browser Specific
-property.category.core=Core
-property.category.content=Content
-property.category.data.binding=Data Binding
-property.category.dynamic=Dynamic
-property.category.file=File
-property.category.image=Image
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.xml
deleted file mode 100644
index 53054127a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html.xml
+++ /dev/null
@@ -1,1244 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore"
- xmlns:cnst="http://org.eclipse.jst.jsf.core/constraints.ecore"
- xmlns:qe="http://org.eclipse.jsf.pagedesigner/QuickEditTabSections.ecore"
- id="http://java.sun.com/jsf/html"
- type="tagFile">
-
- <entity id="column" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- </value>
- </trait>
- </entity>
- <entity id="commandButton" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="action"/>
- <section id="type"/>
- <section id="style"/>
- <section id="section.general.commandButton.listener" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- <tagId>
- <uri>http://java.sun.com/jsf/html</uri>
- <name>form</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="type">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>button</item>
- <item>reset</item>
- <item>submit</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>submit</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="image">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.WebPathType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- </entity>
- <entity id="commandLink" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="action"/>
- <section id="style"/>
- <section id="section.general.commandLink.listener" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- <tagId>
- <uri>http://java.sun.com/jsf/html</uri>
- <name>form</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- </entity>
- <entity id="dataTable" type="tag">
- <include-entity-group id="jsf-table-attributes"/>
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="var"/>
- <section id="width"/>
- <section id="border"/>
- <section id="bgcolor"/>
- <section id="style"/>
- <section id="section.general.dataTable.columns" type="SECTION"/>
- </value>
- </trait>
- <entity id="bgcolor">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ColorType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="var">
- <trait id="contributes-value-binding">
- <value>true</value>
- </trait>
- <trait id="value-binding-scope">
- <value>request</value>
- </trait>
- <trait id="value-binding-symbol-factory">
- <value>org.eclipse.jst.jsf.designtime.core.loadBundle</value>
- </trait>
- <trait id="category"><value>%property.category.jsf</value></trait>
- </entity>
- </entity>
- <entity id="form" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <include-entity-group id="form-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="graphicImage" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="url"/>
- <section id="binding"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="inputHidden" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <!-- <section id="section.general.inputHidden.type" type="SECTION"/> -->
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputSecret" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <!-- <section id="section.general.inputSecret.type" type="SECTION"/> -->
- <section id="section.general.inputText.others" type="SECTION"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputText" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <!-- <section id="section.general.inputText.type" type="SECTION"/> -->
- <section id="section.general.inputText.others" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="inputTextarea" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <!-- <section id="section.general.inputTextarea.type" type="SECTION"/> -->
- <section id="section.general.inputTextarea.others" type="SECTION"/>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="message" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="for-entity"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="for"/>
- </value>
- </trait>
- </entity>
- <entity id="messages" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="layout"/>
- <section id="style"/>
- </value>
- </trait>
- <entity id="layout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>list</item>
- <item>table</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%messages.layout.displayed-values.list</item>
- <item>%messages.layout.displayed-values.table</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>list</value>
- </trait>
- </entity>
- </entity>
- <entity id="outputFormat" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <section id="section.general.outputFormat.params" type="SECTION"/>
- </value>
- </trait>
- </entity>
- <entity id="outputLabel" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <include-entity-group id="for-entity"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="for"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="outputLink" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="outputText" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="binding"/>
- <section id="style"/>
- <section id="section.general.outputText.converter" type="SECTION"/>
- </value>
- </trait>
- </entity>
- <entity id="panelGrid" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="jsf-table-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="columns"/>
- <section id="border"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="panelGroup" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- </value>
- </trait>
- </entity>
- <entity id="selectBooleanCheckbox" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectManyCheckbox" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="layout"/>
- <section id="style"/>
- <section id="section.general.selectManyCheckbox.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="layout">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>pageDirection</item>
- <item>lineDirection</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%selectManyCheckbox.layout.displayed-values.pageDirection</item>
- <item>%selectManyCheckbox.layout.displayed-values.lineDirection</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>lineDirection</value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectManyListbox" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="size"/>
- <section id="style"/>
- <section id="section.general.selectManyListbox.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectManyMenu" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <section id="section.general.selectManyMenu.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectOneListbox" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="size"/>
- <section id="style"/>
- <section id="section.general.selectOneListbox.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectOneMenu" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="style"/>
- <section id="section.general.selectOneMenu.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- </entity>
- <entity id="selectOneRadio" type="tag">
- <include-entity-group id="basic-jsf-html-attributes"/>
- <include-entity-group id="common-jsf-html-attributes"/>
- <include-entity-group id="common-html-attributes" uri="HTML"/>
- <include-entity-group id="common-language-attributes" uri="HTML"/>
- <include-entity-group id="common-core-attributes" uri="HTML"/>
- <include-entity-group id="common-event-attributes" uri="HTML"/>
- <trait id="quick-edit-tab">
- <value xsi:type="qe:QuickEditTabSections">
- <section id="id"/>
- <section id="value"/>
- <section id="layout"/>
- <section id="style"/>
- <section id="section.general.selectOneRadio.choices" type="SECTION"/>
- </value>
- </trait>
- <trait id="containment-constraint">
- <value xsi:type="cnst:ContainsTagConstraint">
- <set-generator>
- <algorithm>xpath</algorithm>
- <expression>ancestor::*</expression>
- </set-generator>
- <satisfies-set>
- <tagId>
- <uri>http://java.sun.com/jsf/core</uri>
- <name>view</name>
- </tagId>
- </satisfies-set>
- </value>
- </trait>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueType</value>
- </trait>
- <trait id="runtime-type-setter-required">
- <value>true</value>
- </trait>
- </entity>
- <entity id="layout">
- <include-entity-group>common-attributes</include-entity-group>
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>pageDirection</item>
- <item>lineDirection</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%selectOneRadio.layout.displayed-values.pageDirection</item>
- <item>%selectOneRadio.layout.displayed-values.lineDirection</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>lineDirection</value>
- </trait>
- </entity>
- </entity>
- <entityGroup id="basic-jsf-html-attributes">
- <entity id="id">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentIDType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="binding">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ComponentBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>javax.faces.component.UIComponent</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="converter">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.FacesConfigConverterIDType</value>
- </trait>
- <trait id="config-type">
- <value>javax.faces.convert.Converter</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="rendered">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="required">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="styleClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="value">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ValueBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="valueChangeListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ValueChangeEvent</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="validator">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value xsi:type="mdt:ListOfValues">
- <item>javax.faces.context.FacesContext</item>
- <item>javax.faces.component.UIComponent</item>
- <item>java.lang.Object</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="common-jsf-html-attributes">
- <!-- This group will be refactored -->
- <entity id="action">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.ActionType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>java.lang.String</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="actionListener">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.MethodBindingType</value>
- </trait>
- <trait id="runtime-return-type">
- <value>void</value>
- </trait>
- <trait id="runtime-param-types">
- <value>javax.faces.event.ActionEvent</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="cols">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="escape">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="default-value">
- <value>true</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="globalOnly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="immediate">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="readonly">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="redisplay">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
-
- <entity id="showDetail">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="default-value">
- <value>true</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="dalign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>right</item>
- <item>left</item>
- <item>center</item>
- <item>justify</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="ialign">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>bottom</item>
- <item>middle</item>
- <item>top</item>
- <item>right</item>
- <item>left</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="linktype">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.LinkType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>index</item>
- <item>subsection</item>
- <item>bookmark</item>
- <item>start</item>
- <item>next</item>
- <item>stylesheet</item>
- <item>chapter</item>
- <item>help</item>
- <item>alternate</item>
- <item>appendix</item>
- <item>contents</item>
- <item>section</item>
- <item>prev</item>
- <item>previous</item>
- <item>glossary</item>
- <item>copyright</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="media">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>tv</item>
- <item>braille</item>
- <item>tty</item>
- <item>print</item>
- <item>all</item>
- <item>projection</item>
- <item>handheld</item>
- <item>screen</item>
- <item>aural</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="scope">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>row</item>
- <item>col</item>
- <item>rowgroup</item>
- <item>colgroup</item>
- </value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="jsf-table-attributes">
- <entity id="bgcolor">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="border">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="cellpadding">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="cellspacing">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum"><value>0</value></trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="columns">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="columnClasses">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="first">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.IntegerType</value>
- </trait>
- <trait id="valid-minimum">
- <value>0</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="footerClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="frame">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>above</item>
- <item>below</item>
- <item>hsides</item>
- <item>vsides</item>
- <item>lhs</item>
- <item>rhs</item>
- <item>box</item>
- <item>border</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%any.frame.displayed-values.none</item>
- <item>%any.frame.displayed-values.above</item>
- <item>%any.frame.displayed-values.below</item>
- <item>%any.frame.displayed-values.hsides</item>
- <item>%any.frame.displayed-values.vsides</item>
- <item>%any.frame.displayed-values.lhs</item>
- <item>%any.frame.displayed-values.rhs</item>
- <item>%any.frame.displayed-values.box</item>
- <item>%any.frame.displayed-values.border</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>none</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="headerClass">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="rowClasses">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.CSSClassType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="rules">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="valid-values">
- <value xsi:type="mdt:ListOfValues">
- <item>none</item>
- <item>groups</item>
- <item>rows</item>
- <item>cols</item>
- <item>all</item>
- </value>
- </trait>
- <trait id="displayed-values">
- <value xsi:type="mdt:ListOfValues">
- <item>%any.rules.displayed-values.none</item>
- <item>%any.rules.displayed-values.groups</item>
- <item>%any.rules.displayed-values.rows</item>
- <item>%any.rules.displayed-values.cols</item>
- <item>%any.rules.displayed-values.all</item>
- </value>
- </trait>
- <trait id="default-value">
- <value>none</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="showSummary">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.BooleanType</value>
- </trait>
- <trait id="default-value">
- <value>false</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- <entity id="summary">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- </entityGroup>
- <entityGroup id="for-entity">
- <entity id="for">
- <trait id="attribute-value-runtime-type">
- <value>org.eclipse.jst.jsf.core.attributevalues.StringType</value>
- </trait>
- <trait id="category">
- <value>%property.category.jsf</value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_dti.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_dti.xml
deleted file mode 100644
index 8841c0b11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_dti.xml
+++ /dev/null
@@ -1,842 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:dti="http://org.eclipse.jsf.pagedesigner/dtinfo.ecore"
- id="http://java.sun.com/jsf/html"
- type="tagFile">
-
- <entity id="column" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.ColumnOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="commandButton" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="input"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <!-- if image attribute exists -->
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@image"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="image"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="image"/>
- <parameter value="src"/>
- </operation>
- </operation>
- <!-- if image attribute does not exist -->
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@image"/>
- <!-- create default type attribute (submit) -->
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="submit"/>
- </operation>
- <!-- override default if type attribute is set (e.g. reset) -->
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="type"/>
- </operation>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="value"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="commandLink" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="dataTable" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.DataTableOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- needTableDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="form" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="form"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="graphicImage" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="img"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="url"/>
- <parameter value="src"/>
- </operation>
- <!--
- if both "value" and "url" source attributes exist,
- "value" overrides "url" as destination "src" attribute
- -->
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="value"/>
- <parameter value="src"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- >
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="src"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputHidden" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFHTML/small/JSF_INPUTHIDDEN.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="inputSecret" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="input"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="password"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="value"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputText" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="input"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="text"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview">
- <resolve-attribute-value attributeName="value"/>
- </tag-decorate-info>
- </value>
- </trait>
- </entity>
-
- <entity id="inputTextarea" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="textarea"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="message" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFHTML/small/JSF_MESSAGE.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="messages" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-decorate-info id="vpd-decorate-design"
- nonVisual="true"
- nonVisualImagePath="icons/palette/JSFHTML/small/JSF_MESSAGES.gif"
- widget="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- nonVisual="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputFormat" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputLabel" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="label"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputLink" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="a"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="href"/>
- <parameter value="#"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="value"/>
- <parameter value="href"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="outputText" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="span"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.ConvertAttributeToTextOperation">
- <parameter value="value"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- needBorderDecorator="true"
- multiLevel="true"
- widget="true"
- setNonVisualChildElements="true"
- />
- <tag-decorate-info id="vpd-decorate-preview"
- resolveChildText="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelGrid" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.PanelGridOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- needTableDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="panelGroup" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="div"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyChildrenOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectBooleanCheckbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="input"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="type"/>
- <parameter value="checkbox"/>
- </operation>
- <!-- if value attribute exists and is "true" -->
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="self::node()[@value='true']"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="checked"/>
- <parameter value="checked"/>
- </operation>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyCheckbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.SelectManyCheckboxOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyListbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="select"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="id"/>
- <parameter value="name"/>
- </operation>
- <!-- multiple select allowed -->
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="multiple"/>
- <parameter value="multiple"/>
- </operation>
- <!-- if no "size" attribute -->
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@size"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeFromXPathOperation">
- <parameter value="size"/>
- <parameter value="count(selectItem)"/>
- </operation>
- </operation>
- <!-- iterate over "selectItem" children -->
- <operation id="org.eclipse.jst.pagedesigner.IterateOverElementsOperation">
- <parameter value="selectItem"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="itemValue"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="itemValue"/>
- <parameter value="value"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemLabel"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@value"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemValue"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="selectItem"/>
- </operation>
- </operation>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectManyMenu" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="select"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="id"/>
- <parameter value="name"/>
- </operation>
- <!-- multiple select allowed -->
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="multiple"/>
- <parameter value="multiple"/>
- </operation>
- <!-- size fixed at 1 -->
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="size"/>
- <parameter value="1"/>
- </operation>
- <!-- iterate over "selectItem" children -->
- <operation id="org.eclipse.jst.pagedesigner.IterateOverElementsOperation">
- <parameter value="selectItem"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="itemValue"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="itemValue"/>
- <parameter value="value"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemLabel"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@value"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemValue"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="selectItem"/>
- </operation>
- </operation>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneListbox" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="select"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="id"/>
- <parameter value="name"/>
- </operation>
- <!-- if no "size" attribute -->
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@size"/>
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeFromXPathOperation">
- <parameter value="size"/>
- <parameter value="count(selectItem)"/>
- </operation>
- </operation>
- <!-- iterate over "selectItem" children -->
- <operation id="org.eclipse.jst.pagedesigner.IterateOverElementsOperation">
- <parameter value="selectItem"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="itemValue"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="itemValue"/>
- <parameter value="value"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemLabel"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@value"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemValue"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="selectItem"/>
- </operation>
- </operation>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneMenu" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.CreateElementOperation">
- <parameter value="select"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAllAttributesOperation"/>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="styleClass"/>
- <parameter value="class"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="id"/>
- <parameter value="name"/>
- </operation>
- <!-- size fixed at 1 -->
- <operation id="org.eclipse.jst.pagedesigner.CreateAttributeOperation">
- <parameter value="size"/>
- <parameter value="1"/>
- </operation>
- <!-- iterate over "selectItem" children -->
- <operation id="org.eclipse.jst.pagedesigner.IterateOverElementsOperation">
- <parameter value="selectItem"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildElementOperation">
- <parameter value="option"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.CopyAttributeOperation">
- <parameter value="itemValue"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.RenameAttributeOperation">
- <parameter value="itemValue"/>
- <parameter value="value"/>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemLabel"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemLabel"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@value"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@value"/>
- <operation id="org.eclipse.jst.pagedesigner.IfOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextFromXPathOperation">
- <parameter value="@itemValue"/>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.IfNotOperation">
- <parameter value="@itemValue"/>
- <operation id="org.eclipse.jst.pagedesigner.AppendChildTextOperation">
- <parameter value="selectItem"/>
- </operation>
- </operation>
- </operation>
- </operation>
- <operation id="org.eclipse.jst.pagedesigner.MakeParentElementCurrentOperation"/>
- </operation>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- />
- </value>
- </trait>
- </entity>
-
- <entity id="selectOneRadio" type="tag">
- <trait id="dt-info">
- <value xsi:type="dti:DTInfo">
- <tag-convert-info>
- <operation id="org.eclipse.jst.pagedesigner.jsf.ui.SelectOneRadioOperation"/>
- </tag-convert-info>
- <tag-decorate-info id="vpd-decorate-design"
- multiLevel="true"
- widget="true"
- needBorderDecorator="true"
- />
- </value>
- </trait>
- </entity>
-
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.properties
deleted file mode 100644
index eb6947479..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-JSFHTML.display-label=JSF HTML
-commandButton.display-label=Command Button
-commandLink.display-label=Command Link
-dataTable.display-label=Data Table
-form.display-label=Form
-graphicImage.display-label=Graphic Image
-inputHidden.display-label=Hidden Input
-inputSecret.display-label=Secret Input
-inputText.display-label=Text Input
-inputTextarea.display-label=Textarea Input
-message.display-label=Message
-messages.display-label=Messages
-outputFormat.display-label=Output Format
-outputLabel.display-label=Output Label
-outputLink.display-label=Output Link
-outputText.display-label=Output Text
-panelGrid.display-label=Panel Grid
-panelGroup.display-label=Panel Group
-selectBooleanCheckbox.display-label=Select Boolean Checkbox
-selectManyCheckbox.display-label=Select Many Checkbox
-selectManyListbox.display-label=Select Many Listbox
-selectManyMenu.display-label=Select Many Menu
-selectOneListbox.display-label=Select One Listbox
-selectOneMenu.display-label=Select One Menu
-selectOneRadio.display-label=Select One Radio
-column.display-label=Column \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.xml
deleted file mode 100644
index d4b216e58..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsf_html_pi.xml
+++ /dev/null
@@ -1,443 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- id="http://java.sun.com/jsf/html"
- type="tagFile">
-
- <trait id="is-jsf-component-library">
- <value>true</value>
- </trait>
-
- <trait id="paletteInfos" >
- <value xsi:type="pi:PaletteInfos">
- <item id="outputLabel"/>
- <item id="inputText"/>
- <item id="commandButton"/>
- <item id="inputTextarea"/>
- <item id="outputText"/>
- <item id="form"/>
- <item id="inputHidden"/>
- <item id="inputSecret"/>
- <item id="column"/>
- <item id="commandLink"/>
- <item id="message"/>
- <item id="messages"/>
- <item id="outputFormat"/>
- <item id="panelGrid"/>
- <item id="panelGroup"/>
- <item id="selectBooleanCheckbox"/>
- <item id="selectManyCheckbox"/>
- <item id="selectManyListbox"/>
- <item id="selectManyMenu"/>
- <item id="selectOneListbox"/>
- <item id="selectOneMenu"/>
- <item id="selectOneRadio"/>
- <item id="dataTable"/>
- <item id="graphicImage"/>
- </value>
- </trait>
-
- <trait id="images-base-path">
- <value>/icons/palette/JSFHTML/</value>
- </trait>
-
- <trait id="display-label">
- <value>%JSFHTML.display-label</value>
- </trait>
-
- <entity id="commandButton" type="tag">
- <trait id="display-label">
- <value>%commandButton.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_COMMANDBUTTON.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_COMMANDBUTTON.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="commandLink" type="tag">
- <trait id="display-label">
- <value>%commandLink.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_COMMANDLINK.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_COMMANDLINK.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <outputText value="CommandLink"
- _uri_="http://java.sun.com/jsf/html" />
- ]]></template>
- </value>
- </trait>
- </entity>
- <entity id="dataTable" type="tag">
- <trait id="display-label">
- <value>%dataTable.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_DATATABLE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_DATATABLE.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <column id="column1"
- _uri_="http://java.sun.com/jsf/html">
- <facet name="header"
- _uri_="http://java.sun.com/jsf/core">
- <outputText value="column1"
- _uri_="http://java.sun.com/jsf/html" />
- </facet>
- </column>
- <column id="column2"
- _uri_="http://java.sun.com/jsf/html">
- <facet name="header"
- _uri_="http://java.sun.com/jsf/core">
- <outputText value="column2"
- _uri_="http://java.sun.com/jsf/html" />
- </facet>
- </column>
- ]]></template>
- <attribute id="border" value="1" />
- </value>
- </trait>
- </entity>
- <entity id="form" type="tag">
- <trait id="display-label">
- <value>%form.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_FORM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_FORM.gif</value>
- </trait>
- </entity>
-
- <entity id="graphicImage" type="tag">
- <trait id="display-label">
- <value>%graphicImage.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_GRAPHICIMAGE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_GRAPHICIMAGE.gif</value>
- </trait>
- </entity>
- <entity id="inputHidden" type="tag">
- <trait id="display-label">
- <value>%inputHidden.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_INPUTHIDDEN.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_INPUTHIDDEN.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="inputSecret" type="tag">
- <trait id="display-label">
- <value>%inputSecret.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_INPUTSECRET.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_INPUTSECRET.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="inputText" type="tag">
- <trait id="display-label">
- <value>%inputText.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_INPUTTEXT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_INPUTTEXT.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="inputTextarea" type="tag">
- <trait id="display-label">
- <value>%inputTextarea.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_INPUTTEXTAREA.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_INPUTTEXTAREA.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="message" type="tag">
- <trait id="display-label">
- <value>%message.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_MESSAGE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_MESSAGE.gif</value>
- </trait>
- </entity>
- <entity id="messages" type="tag">
- <trait id="display-label">
- <value>%messages.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_MESSAGES.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_MESSAGES.gif</value>
- </trait>
- </entity>
- <entity id="outputFormat" type="tag">
- <trait id="display-label">
- <value>%outputFormat.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_OUTPUTFORMAT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_OUTPUTFORMAT.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <param value=""
- _uri_="http://java.sun.com/jsf/core" />
- ]]>
- </template>
- <attribute id="value" value="outputFormat" />
- </value>
- </trait>
- </entity>
- <entity id="outputLabel" type="tag">
- <trait id="display-label">
- <value>%outputLabel.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_OUTPUTLABEL.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_OUTPUTLABEL.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <attribute id="value" value="outputLabel" />
- </value>
- </trait>
- </entity>
- <entity id="outputLink" type="tag">
- <trait id="display-label">
- <value>%outputLink.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_OUTPUTLINK.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_OUTPUTLINK.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <outputText value="outputLink"
- _$uri$="http://java.sun.com/jsf/html" />
- ]]></template>
-
- </value>
- </trait>
- </entity>
- <entity id="outputText" type="tag">
- <trait id="display-label">
- <value>%outputText.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_OUTPUTTEXT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_OUTPUTTEXT.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <attribute id="value" value="outputText" />
- </value>
- </trait>
- </entity>
- <entity id="panelGrid" type="tag">
- <trait id="display-label">
- <value>%panelGrid.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_PANELGRID.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_PANELGRID.gif</value>
- </trait>
- <trait id="tag-create">
- <value xsi:type="pi:TagCreationInfo">
- <template><![CDATA[
- <outputText value="item1"
- _uri_="http://java.sun.com/jsf/html" />
- <outputText value="item2"
- _uri_="http://java.sun.com/jsf/html" />
- <outputText value="item3"
- _uri_="http://java.sun.com/jsf/html" />
- <outputText value="item4"
- _uri_="http://java.sun.com/jsf/html" />
- ]]></template>
- <attribute id="border" value="1" />
- <attribute id="columns" value="2" />
- </value>
- </trait>
- </entity>
- <entity id="panelGroup" type="tag">
- <trait id="display-label">
- <value>%panelGroup.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_PANELGROUP.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_PANELGROUP.gif</value>
- </trait>
- </entity>
- <entity id="selectBooleanCheckbox" type="tag">
- <trait id="display-label">
- <value>%selectBooleanCheckbox.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTBOOLEANCHECKBOX.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTBOOLEANCHECKBOX.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectManyCheckbox" type="tag">
- <trait id="display-label">
- <value>%selectManyCheckbox.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTMANYCHECKBOX.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTMANYCHECKBOX.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectManyListbox" type="tag">
- <trait id="display-label">
- <value>%selectManyListbox.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTMANYLISTBOX.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTMANYLISTBOX.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectManyMenu" type="tag">
- <trait id="display-label">
- <value>%selectManyMenu.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTMANYMENU.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTMANYMENU.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectOneListbox" type="tag">
- <trait id="display-label">
- <value>%selectOneListbox.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTONELISTBOX.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTONELISTBOX.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectOneMenu" type="tag">
- <trait id="display-label">
- <value>%selectOneMenu.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTONEMENU.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTONEMENU.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="selectOneRadio" type="tag">
- <trait id="display-label">
- <value>%selectOneRadio.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_SELECTONERADIO.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_SELECTONERADIO.gif</value>
- </trait>
- <trait id="requires-html-form">
- <value>true</value>
- </trait>
- </entity>
- <entity id="column" type="tag">
- <trait id="display-label">
- <value>%column.display-label</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSF_COLUMN.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSF_COLUMN.gif</value>
- </trait>
- </entity>
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.properties
deleted file mode 100644
index 33b2269a4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.properties
+++ /dev/null
@@ -1,60 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-plugin.display-label=Plugin
-plugin.description=Causes the execution of an applet or bean. The applet or bean executes in the specified plugin. If the plugin is not available, displays a dialog to initiate the download of the plugin software
-
-fallback.display-label=Fallback
-fallback.description=The element provides a message for the user if the plugin does not start
-
-root.display-label=Root
-root.description=Defines standard elements and namespace attributes of tag libraries
-
-text.display-label=Text
-text.description=Encloses template data
-
-expression.display-label=Expression
-expression.description=Contains an expression valid in the scripting language used in the page
-
-scriptlet.display-label=Scriptlet
-scriptlet.description=Contains a code fragment valid in the scripting language used in the page
-
-declaration.display-label=Declaration
-declaration.description=Declares a variable or method valid in the scripting language used in the page
-
-forward.display-label=Forward
-forward.description=Forwards a request to an HTML file, JSP page, or servlet
-
-param.display-label=Param
-param.description=The element passes the name and value of a parameter to the resource
-
-params.display-label=Params
-params.description=The element sends parameter names and values to an applet or Bean at startup
-
-include.display-label=Include
-include.description=Includes a static resource or the result from another web component
-
-useBean.display-label=UseBean
-useBean.description=Instantiates or references a bean with a specific name and scope
-
-getProperty.display-label=GetProperty
-getProperty.description=Inserts the value of a bean property into the response
-
-setProperty.display-label=SetProperty
-setProperty.description=Sets a bean property value or values
-
-directive.include.display-label=Directive.Include
-directive.include.description=Includes a resource of text or code when the JSP page is translated
-
-directive.page.display-label=Directive.Page
-directive.page.description=Defines attributes that apply to an entire JSP page
-
-directive.taglib.display-label=Directive.Taglib
-directive.taglib.description=Defines a tag library and prefix for the custom tags used in the JSP page
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.xml
deleted file mode 100644
index 1cd7345a7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/jsp11.xml
+++ /dev/null
@@ -1,282 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:pi="http://org.eclipse.jsf.pagedesigner/paletteInfos.ecore"
- id="jsp11"
- type="tagFile">
-
- <trait id="paletteInfos">
- <value xsi:type="pi:PaletteInfos">
- <item id="jsp:directive.include"/>
- <item id="jsp:directive.taglib"/>
- <item id="jsp:expression"/>
- <item id="jsp:declaration"/>
- <item id="jsp:useBean"/>
- <item id="jsp:getProperty"/>
- <item id="jsp:setProperty"/>
- <item id="jsp:include"/>
- <item id="jsp:text"/>
- <item id="jsp:root"/>
- <item id="jsp:forward"/>
- <item id="jsp:param"/>
- <item id="jsp:params"/>
- <item id="jsp:plugin"/>
- <item id="jsp:fallback"/>
- <item id="jsp:scriptlet"/>
- <item id="jsp:directive.page"/>
- </value>
- </trait>
-
- <trait id="images-base-path">
- <value>$nl$/icons/palette/JSP</value>
- </trait>
-
- <trait id="display-label">
- <value>JSP</value>
- </trait>
-
- <entity id="jsp:directive.include">
- <trait id="display-label">
- <value>%directive.include.display-label</value>
- </trait>
- <trait id="description">
- <value>%directive.include.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_DIRECTIVE.INCLUDE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_DIRECTIVE.INCLUDE.gif</value>
- </trait>
- </entity>
- <entity id="jsp:directive.page">
- <trait id="display-label">
- <value>%directive.page.display-label</value>
- </trait>
- <trait id="description">
- <value>%directive.page.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_DIRECTIVE.PAGE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_DIRECTIVE.PAGE.gif</value>
- </trait>
- </entity>
-
- <entity id="jsp:directive.taglib">
- <trait id="display-label">
- <value>%directive.taglib.display-label</value>
- </trait>
- <trait id="description">
- <value>%directive.taglib.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_DIRECTIVE.TAGLIB.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_DIRECTIVE.TAGLIB.gif</value>
- </trait>
- </entity>
- <entity id="jsp:expression">
- <trait id="display-label">
- <value>%expression.display-label</value>
- </trait>
- <trait id="description">
- <value>%expression.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_EXPRESSION.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_EXPRESSION.gif</value>
- </trait>
- </entity>
- <entity id="jsp:declaration">
- <trait id="display-label">
- <value>%declaration.display-label</value>
- </trait>
- <trait id="description">
- <value>%declaration.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_DECLARATION.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_DECLARATION.gif</value>
- </trait>
- </entity>
- <entity id="jsp:useBean">
- <trait id="display-label">
- <value>%useBean.display-label</value>
- </trait>
- <trait id="description">
- <value>%useBean.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_USEBEAN.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_USEBEAN.gif</value>
- </trait>
- </entity>
-
- <entity id="jsp:getProperty">
- <trait id="display-label">
- <value>%getProperty.display-label</value>
- </trait>
- <trait id="description">
- <value>%getProperty.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_GETPROPERTY.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_GETPROPERTY.gif</value>
- </trait>
- </entity>
-
- <entity id="jsp:setProperty">
- <trait id="display-label">
- <value>%setProperty.display-label</value>
- </trait>
- <trait id="description">
- <value>%setProperty.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_SETPROPERTY.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_SETPROPERTY.gif</value>
- </trait>
- </entity>
- <entity id="jsp:include">
- <trait id="display-label">
- <value>%include.display-label</value>
- </trait>
- <trait id="description">
- <value>%include.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_INCLUDE.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_INCLUDE.gif</value>
- </trait>
- </entity>
-
- <entity id="jsp:text">
- <trait id="display-label">
- <value>%text.display-label</value>
- </trait>
- <trait id="description">
- <value>%text.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_TEXT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_TEXT.gif</value>
- </trait>
- </entity>
- <entity id="jsp:root">
- <trait id="display-label">
- <value>%root.display-label</value>
- </trait>
- <trait id="description">
- <value>%root.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_ROOT.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_ROOT.gif</value>
- </trait>
- </entity>
- <entity id="jsp:forward">
- <trait id="display-label">
- <value>%forward.display-label</value>
- </trait>
- <trait id="description">
- <value>%forward.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_FORWARD.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_FORWARD.gif</value>
- </trait>
- </entity>
-
- <entity id="jsp:param">
- <trait id="display-label">
- <value>%param.display-label</value>
- </trait>
- <trait id="description">
- <value>%param.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_PARAM.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_PARAM.gif</value>
- </trait>
- </entity>
- <entity id="jsp:params">
- <trait id="display-label">
- <value>%params.display-label</value>
- </trait>
- <trait id="description">
- <value>%params.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_PARAMS.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_PARAMS.gif</value>
- </trait>
- </entity>
- <entity id="jsp:plugin">
- <trait id="display-label">
- <value>%plugin.display-label</value>
- </trait>
- <trait id="description">
- <value>%plugin.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_PLUGIN.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_PLUGIN.gif</value>
- </trait>
- </entity>
- <entity id="jsp:fallback">
- <trait id="display-label">
- <value>%fallback.display-label</value>
- </trait>
- <trait id="description">
- <value>%fallback.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_FALLBACK.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_FALLBACK.gif</value>
- </trait>
- </entity>
- <entity id="jsp:scriptlet">
- <trait id="display-label">
- <value>%scriptlet.display-label</value>
- </trait>
- <trait id="description">
- <value>%scriptlet.description</value>
- </trait>
- <trait id="small-icon">
- <value>small/JSP_SCRIPTLET.gif</value>
- </trait>
- <trait id="large-icon">
- <value>large/JSP_SCRIPTLET.gif</value>
- </trait>
- </entity>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/symbolInfoMetadata.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/symbolInfoMetadata.xml
deleted file mode 100644
index 5c6686aa5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/symbolInfoMetadata.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
- xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore"
- xmlns:mdt="http://org.eclipse.jst.jsf.common.metadata/metadataTraitTypes.ecore"
- id="http://java.sun.com/jsf/core"
- type="tagFile">
-
-
- <entity id="view" type="tag">
- <entity id="locale">
- <trait id="sets-locale">
- <value>true</value>
- </trait>
- </entity>
- </entity>
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_core.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_core.xml
deleted file mode 100644
index f32d1335b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_core.xml
+++ /dev/null
@@ -1,188 +0,0 @@
-<?xml version="1.0" encoding="ASCII"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:viewMap="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xsi:noNamespaceSchemaLocation="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore" id="http://java.sun.com/jsf/core" type="tagFile">
- <entity id="view" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UIViewRoot</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.ViewRoot</componentType>
- <componentFamily>javax.faces.ViewRoot</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateDoubleRange" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>javax.faces.validator.DoubleRangeValidator</className>
- <validatorId>javax.faces.DoubleRange</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="subview" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UINamingContainer</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <componentType>javax.faces.NamingContainer</componentType>
- <componentFamily>javax.faces.NamingContainer</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="converter" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_"/>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="convertNumber" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_">
- <className>javax.faces.convert.NumberConverter</className>
- <converterId>javax.faces.Number</converterId>
- <forClass>java.lang.Number</forClass>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateLongRange" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>javax.faces.validator.LongRangeValidator</className>
- <validatorId>javax.faces.LongRange</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validateLength" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_">
- <className>javax.faces.validator.LengthValidator</className>
- <validatorId>javax.faces.Length</validatorId>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="convertDateTime" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ConverterTypeInfo_">
- <className>javax.faces.convert.DateTimeConverter</className>
- <converterId>javax.faces.DateTime</converterId>
- <forClass>java.util.Date</forClass>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="validator" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ValidatorTypeInfo_"/>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="verbatim" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UIOutput</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <componentType>javax.faces.Output</componentType>
- <componentFamily>javax.faces.Output</componentFamily>
- <renderType>javax.faces.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectItem" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UISelectItem</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.SelectItem</componentType>
- <componentFamily>javax.faces.SelectItem</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectItems" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UISelectItems</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.SelectItems</componentType>
- <componentFamily>javax.faces.SelectItems</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="param" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UIParameter</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.Parameter</componentType>
- <componentFamily>javax.faces.Parameter</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
-</md:metadatamodel> \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_html.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_html.xml
deleted file mode 100644
index 9c94c712f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/metadata/viewMappings_html.xml
+++ /dev/null
@@ -1,558 +0,0 @@
-<?xml version="1.0" encoding="ASCII"?>
-<md:metadatamodel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:viewMap="http://org.eclipse.jst.jsf.core/componentMapping.ecore" xmlns:md="http://org.eclipse.jst.jsf.common.metadata/metadata.ecore" xsi:noNamespaceSchemaLocation="http://org.eclipse.jst.jsf.core/componentMapping.ecore" id="http://java.sun.com/jsf/html" type="tagFile">
- <entity id="selectOneMenu" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectOneMenu</className>
- <superClasses>javax.faces.component.UISelectOne</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectOneMenu</componentType>
- <componentFamily>javax.faces.SelectOne</componentFamily>
- <renderType>javax.faces.Menu</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyListbox" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectManyListbox</className>
- <superClasses>javax.faces.component.UISelectMany</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectManyListbox</componentType>
- <componentFamily>javax.faces.SelectMany</componentFamily>
- <renderType>javax.faces.Listbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="form" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlForm</className>
- <superClasses>javax.faces.component.UIForm</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlForm</componentType>
- <componentFamily>javax.faces.Form</componentFamily>
- <renderType>javax.faces.Form</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="message" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlMessage</className>
- <superClasses>javax.faces.component.UIMessage</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlMessage</componentType>
- <componentFamily>javax.faces.Message</componentFamily>
- <renderType>javax.faces.Message</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="graphicImage" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlGraphicImage</className>
- <superClasses>javax.faces.component.UIGraphic</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlGraphicImage</componentType>
- <componentFamily>javax.faces.Graphic</componentFamily>
- <renderType>javax.faces.Image</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="column" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.UIColumn</className>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.Column</componentType>
- <componentFamily>javax.faces.Column</componentFamily>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputFormat" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <beanMappedProperties>value</beanMappedProperties>
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlOutputFormat</className>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlOutputFormat</componentType>
- <componentFamily>javax.faces.Output</componentFamily>
- <renderType>javax.faces.Format</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyMenu" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectManyMenu</className>
- <superClasses>javax.faces.component.UISelectMany</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectManyMenu</componentType>
- <componentFamily>javax.faces.SelectMany</componentFamily>
- <renderType>javax.faces.Menu</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOneRadio" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectOneRadio</className>
- <superClasses>javax.faces.component.UISelectOne</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectOneRadio</componentType>
- <componentFamily>javax.faces.SelectOne</componentFamily>
- <renderType>javax.faces.Radio</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelGroup" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlPanelGroup</className>
- <superClasses>javax.faces.component.UIPanel</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlPanelGroup</componentType>
- <componentFamily>javax.faces.Panel</componentFamily>
- <renderType>javax.faces.Group</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectOneListbox" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectOneListbox</className>
- <superClasses>javax.faces.component.UISelectOne</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectOneListbox</componentType>
- <componentFamily>javax.faces.SelectOne</componentFamily>
- <renderType>javax.faces.Listbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="commandButton" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlCommandButton</className>
- <superClasses>javax.faces.component.UICommand</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlCommandButton</componentType>
- <componentFamily>javax.faces.Command</componentFamily>
- <renderType>javax.faces.Button</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputText" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlInputText</className>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlInputText</componentType>
- <componentFamily>javax.faces.Input</componentFamily>
- <renderType>javax.faces.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="dataTable" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlDataTable</className>
- <superClasses>javax.faces.component.UIData</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.NamingContainer</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlDataTable</componentType>
- <componentFamily>javax.faces.Data</componentFamily>
- <renderType>javax.faces.Table</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectBooleanCheckbox" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectBooleanCheckbox</className>
- <superClasses>javax.faces.component.UISelectBoolean</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectBooleanCheckbox</componentType>
- <componentFamily>javax.faces.SelectBoolean</componentFamily>
- <renderType>javax.faces.Checkbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputText" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlOutputText</className>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlOutputText</componentType>
- <componentFamily>javax.faces.Output</componentFamily>
- <renderType>javax.faces.Text</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="selectManyCheckbox" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlSelectManyCheckbox</className>
- <superClasses>javax.faces.component.UISelectMany</superClasses>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlSelectManyCheckbox</componentType>
- <componentFamily>javax.faces.SelectMany</componentFamily>
- <renderType>javax.faces.Checkbox</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputSecret" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlInputSecret</className>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlInputSecret</componentType>
- <componentFamily>javax.faces.Input</componentFamily>
- <renderType>javax.faces.Secret</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="panelGrid" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlPanelGrid</className>
- <superClasses>javax.faces.component.UIPanel</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlPanelGrid</componentType>
- <componentFamily>javax.faces.Panel</componentFamily>
- <renderType>javax.faces.Grid</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="commandLink" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlCommandLink</className>
- <superClasses>javax.faces.component.UICommand</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ActionSource</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlCommandLink</componentType>
- <componentFamily>javax.faces.Command</componentFamily>
- <renderType>javax.faces.Link</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputHidden" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlInputHidden</className>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlInputHidden</componentType>
- <componentFamily>javax.faces.Input</componentFamily>
- <renderType>javax.faces.Hidden</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="inputTextarea" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlInputTextarea</className>
- <superClasses>javax.faces.component.UIInput</superClasses>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.EditableValueHolder</interfaces>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlInputTextarea</componentType>
- <componentFamily>javax.faces.Input</componentFamily>
- <renderType>javax.faces.Textarea</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputLabel" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlOutputLabel</className>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlOutputLabel</componentType>
- <componentFamily>javax.faces.Output</componentFamily>
- <renderType>javax.faces.Label</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="outputLink" type="tag">
- <include-entity-group id="common-valueholder-attributes"/>
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlOutputLink</className>
- <superClasses>javax.faces.component.UIOutput</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.ValueHolder</interfaces>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlOutputLink</componentType>
- <componentFamily>javax.faces.Output</componentFamily>
- <renderType>javax.faces.Link</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entity id="messages" type="tag">
- <trait id="viewElementMapping">
- <md:value xsi:type="viewMap:TagMapping">
- <versionedTagToViewMappings>
- <typeInfo xsi:type="viewMap:ComponentTypeInfo_">
- <className>javax.faces.component.html.HtmlMessages</className>
- <superClasses>javax.faces.component.UIMessages</superClasses>
- <superClasses>javax.faces.component.UIComponentBase</superClasses>
- <superClasses>javax.faces.component.UIComponent</superClasses>
- <superClasses>java.lang.Object</superClasses>
- <interfaces>javax.faces.component.StateHolder</interfaces>
- <componentType>javax.faces.HtmlMessages</componentType>
- <componentFamily>javax.faces.Messages</componentFamily>
- <renderType>javax.faces.Messages</renderType>
- </typeInfo>
- </versionedTagToViewMappings>
- </md:value>
- </trait>
- </entity>
- <entityGroup id="common-valueholder-attributes">
- <entity id="value">
- <trait id="attributeMapping">
- <md:value xsi:type="viewMap:AttributeToPropertyMapping">
- <propertyName>value</propertyName>
- <elAllowed>true</elAllowed>
- </md:value>
- </trait>
- </entity>
- <entity id="converter">
- <trait id="attributeMapping">
- <md:value xsi:type="viewMap:AttributeToPropertyMapping">
- <customConversionFactoryId>org.eclipse.jst.jsf.core.valueHolderAttributeMapper</customConversionFactoryId>
- <elAllowed>true</elAllowed>
- </md:value>
- </trait>
- </entity>
- </entityGroup>
-</md:metadatamodel>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.properties
deleted file mode 100644
index 4ab821a20..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-
-
-# ====================================================================
-# To code developer:
-# Do NOT change the properties between this line and the
-# "%%% END OF TRANSLATED PROPERTIES %%%" line.
-# Make a new property name, append to the end of the file and change
-# the code to use the new property.
-# ====================================================================
-
-# ====================================================================
-# %%% END OF TRANSLATED PROPERTIES %%%
-# ====================================================================
-
-pluginName = JavaServer Faces Tools - Taglibrary Metadata
-pluginProvider = Eclipse.org
-
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.xml
deleted file mode 100644
index d68e875d4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/plugin.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.2"?>
-<plugin>
- <extension
- point="org.eclipse.jst.jsf.common.standardMetaDataFiles">
- <standardMetaDataFile
- location="$nl$/metadata/html.xml"
- uri="HTML"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsp11.xml"
- uri="JSP11"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_html.xml"
- uri="http://java.sun.com/jsf/html"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_html_pi.xml"
- uri="http://java.sun.com/jsf/html"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_html_dti.xml"
- uri="http://java.sun.com/jsf/html"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_core.xml"
- uri="http://java.sun.com/jsf/core"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_core_pi.xml"
- uri="http://java.sun.com/jsf/core"/>
- <standardMetaDataFile
- location="$nl$/metadata/jsf_core_dti.xml"
- uri="http://java.sun.com/jsf/core"/>
- <standardMetaDataFile
- location="$nl$/metadata/symbolInfoMetadata.xml"
- uri="http://java.sun.com/jsf/core"/>
- <standardMetaDataFile
- location="$nl$/metadata/viewMappings_core.xml"
- uri="http://java.sun.com/jsf/core">
- </standardMetaDataFile>
- <standardMetaDataFile
- location="$nl$/metadata/viewMappings_html.xml"
- uri="http://java.sun.com/jsf/html">
- </standardMetaDataFile>
- </extension>
-
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/src/org/eclipse/jst/jsf/standard/tagsupport/StandardTagSupportPlugin.java b/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/src/org/eclipse/jst/jsf/standard/tagsupport/StandardTagSupportPlugin.java
deleted file mode 100644
index ed631da6d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.standard.tagsupport/src/org/eclipse/jst/jsf/standard/tagsupport/StandardTagSupportPlugin.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.standard.tagsupport;
-
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class StandardTagSupportPlugin extends AbstractUIPlugin {
-
- /**
- * the plugin id
- */
- public static final String PLUGIN_ID = "org.eclipse.jst.jsf.standard.tagsupport"; //$NON-NLS-1$
-
- // The shared instance
- private static StandardTagSupportPlugin plugin;
-
- /**
- * The constructor
- */
- public StandardTagSupportPlugin() {
- // do nothing
- }
-
- /*
- * (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 StandardTagSupportPlugin getDefault() {
- return plugin;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.classpath b/jsf/plugins/org.eclipse.jst.jsf.ui/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.cvsignore b/jsf/plugins/org.eclipse.jst.jsf.ui/.cvsignore
deleted file mode 100644
index 117a1fe6b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.cvsignore
+++ /dev/null
@@ -1,5 +0,0 @@
-bin
-@dot*
-temp.folder
-build.xml
-javaCompiler...args
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.options b/jsf/plugins/org.eclipse.jst.jsf.ui/.options
deleted file mode 100644
index 9b3610198..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.options
+++ /dev/null
@@ -1,6 +0,0 @@
-# Debugging options for the org.eclipse.jst.jsf.core
-
-# Turn on general debugging for the org.eclipse.jsf.ui plugin.
-org.eclipse.jst.jsf.ui/debug=false
-
-org.eclipse.jst.jsf.ui/metadatagen=false
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.project b/jsf/plugins/org.eclipse.jst.jsf.ui/.project
deleted file mode 100644
index 45f845d24..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.jsf.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/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.core.resources.prefs b/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index c8e6e652e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,4 +0,0 @@
-#Sun May 27 16:04:34 EDT 2007
-eclipse.preferences.version=1
-encoding//src/org/eclipse/jst/jsf/ui/internal/messages.properties=8859_1
-encoding/<project>=ISO-8859-1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index e644043de..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,82 +0,0 @@
-#Mon Jun 30 15:56:47 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-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.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=warning
-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=ignore
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
-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=warning
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-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=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
-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=ignore
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=error
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.ui.prefs b/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 39df0950a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Tue Apr 10 09:49:42 PDT 2007
-eclipse.preferences.version=1
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates/>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 93451e5a7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 11:57:15 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.jsf.ui/META-INF/MANIFEST.MF
deleted file mode 100644
index 2070af376..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,46 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %plugin.name
-Bundle-SymbolicName: org.eclipse.jst.jsf.ui; singleton:=true
-Bundle-Version: 1.1.102.qualifier
-Bundle-Activator: org.eclipse.jst.jsf.ui.internal.JSFUiPlugin
-Bundle-Vendor: %plugin.provider
-Bundle-Localization: plugin
-Require-Bundle: org.eclipse.jst.jsf.core;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.wst.common.project.facet.ui;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.core.resources;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.jst.j2ee;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.common.frameworks.ui;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.jface.text;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.xml.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.xml.ui;bundle-version="[1.0.100,1.2.0)",
- org.eclipse.wst.sse.ui;bundle-version="[1.0.101,1.2.0)",
- org.eclipse.emf.ecore;bundle-version="[2.2.0,3.0.0)",
- org.eclipse.jst.jsp.ui;bundle-version="[1.1.0,1.3.0)",
- org.eclipse.ui.forms;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.wst.sse.core;bundle-version="[1.0.101,1.2.0)",
- org.eclipse.ui.forms;bundle-version="[3.2.0,4.0.0)",
- org.eclipse.jst.jsf.common.runtime;bundle-version="[1.0.0,2.0.0)",
- org.eclipse.jst.jsp.core;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.wst.validation;bundle-version="[1.1.0,2.0.0)",
- org.eclipse.jst.jsf.common.ui;bundle-version="[1.0.1,2.0.0)",
- org.eclipse.ui.ide;bundle-version="[3.4.0,4.0.0)",
- org.eclipse.jst.common.project.facet.ui;bundle-version="[1.3.1,2.0.0)",
- org.eclipse.jst.common.project.facet.core;bundle-version="[1.3.100,2.0.0)"
-Bundle-ActivationPolicy: lazy
-Export-Package: org.eclipse.jst.jsf.ui.internal;x-friends:="org.eclipse.jst.jsf.ui.tests",
- org.eclipse.jst.jsf.ui.internal.classpath;x-friends:="org.eclipse.jst.jsf.ui.tests",
- org.eclipse.jst.jsf.ui.internal.common;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.component;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.contentassist;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.contentassist.el;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.jspeditor;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.preferences;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.project.facet;x-friends:="org.eclipse.jst.jsf.ui.tests",
- org.eclipse.jst.jsf.ui.internal.tagregistry;x-internal:=true,
- org.eclipse.jst.jsf.ui.internal.validation;x-internal:=true
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/about.html b/jsf/plugins/org.eclipse.jst.jsf.ui/about.html
deleted file mode 100644
index 8e5605900..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/build.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/build.properties
deleted file mode 100644
index 15be5d249..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/build.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2005 Oracle Corporation.
-# 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:
-# Gerry Kessler - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- plugin.xml,\
- icons/,\
- plugin.properties,\
- about.html,\
- .options
-javacSource=1.5
-javacTarget=1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/attr_val.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/attr_val.gif
deleted file mode 100644
index d4cb4254d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/attr_val.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/full/wizban/addlibrary_wiz.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/full/wizban/addlibrary_wiz.gif
deleted file mode 100644
index 128c9d190..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/full/wizban/addlibrary_wiz.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_l_obj.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_l_obj.gif
deleted file mode 100644
index 6cb185cff..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_l_obj.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_obj.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_obj.gif
deleted file mode 100644
index 2fa1d777b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/jar_obj.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/library_obj.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/library_obj.gif
deleted file mode 100644
index cb55e33b5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/obj16/library_obj.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/sample.gif b/jsf/plugins/org.eclipse.jst.jsf.ui/icons/sample.gif
deleted file mode 100644
index 34fb3c9d8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/icons/sample.gif
+++ /dev/null
Binary files differ
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.properties
deleted file mode 100644
index 37755207f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.properties
+++ /dev/null
@@ -1,44 +0,0 @@
-###############################################################################
-# Copyright (c) 2005, 2006 Oracle Corporation.
-# 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:
-# Gerry Kessler - initial API and implementation
-###############################################################################
-plugin.name=JavaServer Faces Tools - UI
-plugin.provider=Eclipse.org
-EL_Hyperlinkdetector_name=JSF EL Symbol
-
-jsf.library.reference=JSF Library References
-jsf.library.wizard.name=JSF Library
-
-preferencepage.jsfvalidation.name=Validation
-preferencepage.jsf.name=JavaServer Faces Tools
-
-jsf.ui.views.category.name=JavaServer Faces
-
-jsf.ui.views.componentview.name=JSF Component Tree
-jsf.ui.views.jsftagregistry.name=Tag Registry
-
-JSFNonELAttributeValueValidator=JSF View Validator
-JSFAppConfigValidator=JSF Application Configuration Validator
-JSPSemanticsValidatorMarker=JSF Problem
-
-View_Preference_Root=Views
-JSP_Tag_Registry_Preferences=JSP Tag Registry
-
-NewJSFPage_html=New JavaServer Faces (JSF) Page (html)
-NewJSFPage_xhtml=New JavaServer Faces (JSF) Page (xhtml)
-NewJSFPage_xhtml_xmlsyntax=New JavaServer Faces (JSF) Page (xhtml, xml syntax)
-
-NewJSFPage_html_description=JSP with html markup and default view setup
-NewJSFPage_xhtml_description=JSP with xhtml markup and default view setup
-NewJSFPage_xhtml_xmlsyntax_description=JSP with xhtml markup, xml style syntax and default view setup
-
-NewELExpression=New JSF EL Expression
-NewELExpression_description=Create a new attribute value with #{}
-
-jsf.library.property.page = Java Server Faces
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.xml b/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.xml
deleted file mode 100644
index ff6fa97ba..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/plugin.xml
+++ /dev/null
@@ -1,320 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin>
- <!-- JSF Project Facet -->
- <extension
- point="org.eclipse.ui.preferencePages">
- <page
- category="org.eclipse.jst.jsf.ui.JSFRootPage"
- class="org.eclipse.jst.jsf.ui.internal.validation.JSFValidationPreferencePage"
- id="org.eclipse.jst.jsf.ui.JSFValidationPage"
- name="%preferencepage.jsfvalidation.name"/>
- <page
- category="org.eclipse.wst.html.ui.preferences.web"
- class="org.eclipse.jst.jsf.ui.internal.preferences.EmptyRootPreferencePage"
- id="org.eclipse.jst.jsf.ui.JSFRootPage"
- name="%preferencepage.jsf.name">
- </page>
- <page
- category="org.eclipse.jst.jsf.ui.viewRoot"
- class="org.eclipse.jst.jsf.ui.internal.preferences.JSPTagRegistryPreferencePage"
- id="org.eclipse.jst.jsf.ui.jspTagRegistry"
- name="%JSP_Tag_Registry_Preferences">
- </page>
- <page
- category="org.eclipse.jst.jsf.ui.JSFRootPage"
- class="org.eclipse.jst.jsf.ui.internal.preferences.EmptyRootPreferencePage"
- id="org.eclipse.jst.jsf.ui.viewRoot"
- name="%View_Preference_Root">
- </page>
- </extension>
-
- <extension point="org.eclipse.ui.propertyPages">
- <page
- adaptable="true"
- category="org.eclipse.wst.common.project.facet.ui.FacetsPropertyPage"
- class="org.eclipse.jst.jsf.ui.internal.project.facet.JSFLibraryPropertyPage"
- id="org.eclipse.jst.jsf.ui.internal.project.facet.JSFLibraryPropertyPage"
- name="%jsf.library.property.page"
- objectClass="org.eclipse.core.resources.IProject">
- <enabledWhen>
- <adapt type="org.eclipse.core.resources.IProject">
- <test
- forcePluginActivation="true"
- property="org.eclipse.wst.common.project.facet.core.projectFacet"
- value="jst.jsf"/>
- </adapt>
- </enabledWhen>
- </page>
- </extension>
-
- <extension
- point="org.eclipse.wst.common.project.facet.ui.wizardPages">
- <wizard-pages action="jst.jsf.v11.install">
- <page class="org.eclipse.jst.jsf.ui.internal.project.facet.JSFFacetInstallPage"/>
- </wizard-pages>
- <wizard-pages action="jst.jsf.v12.install">
- <page class="org.eclipse.jst.jsf.ui.internal.project.facet.JSFFacetInstallPage"/>
- </wizard-pages>
- </extension>
-
- <extension point="org.eclipse.wst.sse.ui.editorConfiguration">
- <sourceViewerConfiguration
- class="org.eclipse.jst.jsp.ui.StructuredTextViewerConfigurationJSP"
- target="org.eclipse.jst.jsp.core.jspsource"/>
- <provisionalConfiguration
- type="contentassistprocessor"
- class="org.eclipse.jst.jsf.ui.internal.contentassist.el.JSFELContentAssistProcessor"
- target="org.eclipse.jst.jsp.SCRIPT.JSP_EL2" />
- <provisionalConfiguration
- type="contentassistprocessor"
- class="org.eclipse.jst.jsf.ui.internal.contentassist.JSFContentAssistProcessor"
- target="org.eclipse.jst.jsp.JSP_DEFAULT,org.eclipse.jst.jsp.JSP_DIRECTIVE" />
- <documentationTextHover
- class="org.eclipse.jst.jsf.ui.internal.jspeditor.JSFELHover"
- target="org.eclipse.jst.jsp.SCRIPT.JSP_EL2">
- </documentationTextHover>
- </extension>
- <extension point="org.eclipse.wst.sse.ui.sourcevalidation">
- <validator
- scope="total"
- class="org.eclipse.jst.jsf.ui.internal.validation.JSFValidator"
- id="org.eclipse.jst.jsf.validation.JSFAttributeValueValidator">
- <contentTypeIdentifier
- id="org.eclipse.jst.jsp.core.jspsource">
- <partitionType id="org.eclipse.jst.jsp.DEFAULT_JSP">
- </partitionType>
- <partitionType id="org.eclipse.jst.jsp.JSP_DIRECTIVE">
- </partitionType>
- <partitionType id="org.eclipse.jst.jsp.SCRIPT.JSP_EL2">
- </partitionType>
- </contentTypeIdentifier>
- </validator>
- </extension>
- <extension
- point="org.eclipse.ui.workbench.texteditor.hyperlinkDetectors">
- <hyperlinkDetector
- class="org.eclipse.jst.jsf.ui.internal.jspeditor.ELHyperlinkDetector"
- id="org.eclipse.jst.jsf.ui.elhyperlinkdetector"
- name="%EL_Hyperlinkdetector_name"
- targetId="org.eclipse.jst.jsp.core.jspsource">
- </hyperlinkDetector>
- </extension>
-
- <extension
- point="org.eclipse.ui.views">
- <category
- name="%jsf.ui.views.category.name"
- id="org.eclipse.jst.jsf.ui.view.category">
- </category>
- <view
- name="%jsf.ui.views.componentview.name"
- category="org.eclipse.jst.jsf.ui.view.category"
- class="org.eclipse.jst.jsf.ui.internal.component.ComponentTreeView"
- id="org.eclipse.jst.jsf.ui.component.ComponentTreeView">
- </view>
- <view
- category="org.eclipse.jst.jsf.ui.view.category"
- class="org.eclipse.jst.jsf.ui.internal.tagregistry.TagRegistryView"
- icon="icons/obj16/library_obj.gif"
- id="org.eclipse.jst.jsf.ui.tagregistry.TagRegistryView"
- name="%jsf.ui.views.jsftagregistry.name">
- </view>
- </extension>
-
- <extension
- id="JSPSemanticsValidatorMarker"
- name="%JSPSemanticsValidatorMarker"
- point="org.eclipse.core.resources.markers">
- <super
- type="org.eclipse.wst.validation.problemmarker">
- </super>
- </extension>
-
- <extension
- id="JSFNonELAttributeValueValidator"
- name="%JSFNonELAttributeValueValidator"
- point="org.eclipse.wst.validation.validatorV2">
- <validator
- build="true"
- class="org.eclipse.jst.jsf.ui.internal.validation.JSFValidator"
- manual="true"
- markerId="org.eclipse.jst.jsf.ui.JSPSemanticsValidatorMarker"
- sourceid="org.eclipse.jst.jsf.validation.JSFAttributeValueValidator"
- version="1">
- <include>
- <rules>
- <facet
- id="jst.java">
- </facet>
- </rules>
- </include>
- <include>
- <rules>
- <facet
- id="jst.web">
- </facet>
- </rules>
- </include>
- <include>
- <rules>
- <facet
- id="jst.jsf">
- </facet>
- </rules>
- </include>
- <include>
- <rules>
- <projectNature
- id="org.eclipse.wst.common.modulecore.ModuleCoreNature">
- </projectNature>
- </rules>
- </include>
- <include>
- <rules>
- <projectNature
- id="org.eclipse.jdt.core.javanature">
- </projectNature>
- </rules>
- </include>
- <include>
- <rules>
- <contentType
- exactMatch="false"
- id="org.eclipse.jst.jsp.core.jspsource">
- </contentType>
- <contentType
- exactMatch="true"
- id="org.eclipse.jst.jsp.core.jspfragmentsource">
- </contentType>
- </rules>
- </include>
- <group
- id="org.eclipse.wst.sse.core.structuredModelGroup">
- </group>
- </validator>
- </extension>
-
- <extension id="JSFAppConfigValidator" name="%JSFAppConfigValidator" point="org.eclipse.wst.validation.validatorV2">
- <validator
- build="true"
- class="org.eclipse.jst.jsf.validation.internal.appconfig.AppConfigValidator"
- manual="true"
- markerId="org.eclipse.jst.jsf.ui.JSPSemanticsValidatorMarker"
- version="1">
- <include>
- <rules>
- <projectNature id="org.eclipse.wst.common.modulecore.ModuleCoreNature"/>
- </rules>
- </include>
- <include>
- <rules>
- <projectNature id="org.eclipse.jdt.core.javanature"/>
- </rules>
- </include>
- <include>
- <rules>
- <contentType id="org.eclipse.jst.jsf.facesconfig.facesConfigFile" exactMatch="true" />
- </rules>
- </include>
- </validator>
- </extension>
-
- <extension
- point="org.eclipse.ui.editors.templates">
- <template
- autoinsert="true"
- contextTypeId="jsp_new"
- description="%NewJSFPage_html_description"
- id="org.eclipse.jst.jsf.ui.new_jsf_page_html"
- name="%NewJSFPage_html">
- <pattern>
- &lt;%@ page language=&quot;java&quot; contentType=&quot;text/html; charset=${encoding}&quot; pageEncoding=&quot;${encoding}&quot;%&gt;
-&lt;%@ taglib prefix=&quot;f&quot; uri=&quot;http://java.sun.com/jsf/core&quot;%&gt;
-&lt;%@ taglib prefix=&quot;h&quot; uri=&quot;http://java.sun.com/jsf/html&quot;%&gt;
-&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot; &quot;http://www.w3.org/TR/html4/loose.dtd&quot;&gt;
-&lt;html&gt;
-&lt;head&gt;
-&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=${encoding}&quot;&gt;
-&lt;title&gt;Insert title here&lt;/title&gt;
-&lt;/head&gt;
-&lt;body&gt;
-&lt;f:view&gt;
-${cursor}
-&lt;/f:view&gt;
-&lt;/body&gt;
-&lt;/html&gt;
- </pattern>
- </template>
-
- <template
- autoinsert="true"
- contextTypeId="jsp_new"
- description="%NewJSFPage_xhtml_xmlsyntax_description"
- id="org.eclipse.jst.jsf.ui.new_jsf_page_html_xhtml_xmllsyntax"
- name="%NewJSFPage_xhtml_xmlsyntax">
- <pattern>
- &lt;?xml version=&quot;1.0&quot; encoding=&quot;ISO-8859-1&quot; ?&gt;
-&lt;jsp:root xmlns:jsp=&quot;http://java.sun.com/JSP/Page&quot; xmlns:f=&quot;http://java.sun.com/jsf/core&quot; xmlns:h=&quot;http://java.sun.com/jsf/html&quot; version=&quot;2.0&quot;&gt;
- &lt;jsp:directive.page language=&quot;java&quot;
- contentType=&quot;text/html; charset=ISO-8859-1&quot; pageEncoding=&quot;ISO-8859-1&quot; /&gt;
- &lt;jsp:text&gt;
- &lt;![CDATA[ &lt;?xml version=&quot;1.0&quot; encoding=&quot;ISO-8859-1&quot; ?&gt; ]]&gt;
- &lt;/jsp:text&gt;
- &lt;jsp:text&gt;
- &lt;![CDATA[ &lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt; ]]&gt;
- &lt;/jsp:text&gt;
-&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;
-&lt;head&gt;
-&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=ISO-8859-1&quot; /&gt;
-&lt;title&gt;Insert title here&lt;/title&gt;
-&lt;/head&gt;
-&lt;body&gt;
-&lt;f:view&gt;
-${cursor}
-&lt;/f:view&gt;
-&lt;/body&gt;
-&lt;/html&gt;
-&lt;/jsp:root&gt;
-
-
-
- </pattern>
- </template>
- <template
- autoinsert="true"
- contextTypeId="jsp_new"
- description="%NewJSFPage_xhtml_description"
- id="org.eclipse.jst.jsf.ui.new_jsf_page_xhtml"
- name="%NewJSFPage_xhtml">
- <pattern>
- &lt;?xml version=&quot;1.0&quot; encoding=&quot;${encoding}&quot; ?&gt;
-&lt;%@ page language=&quot;java&quot; contentType=&quot;text/html; charset=${encoding}&quot;
- pageEncoding=&quot;${encoding}&quot;%&gt;
-&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;
-&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xmlns:f=&quot;http://java.sun.com/jsf/core&quot; xmlns:h=&quot;http://java.sun.com/jsf/html&quot;&gt;
-&lt;head&gt;
-&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=${encoding}&quot; /&gt;
-&lt;title&gt;Insert title here&lt;/title&gt;
-&lt;/head&gt;
-&lt;body&gt;
-&lt;f:view&gt;
-${cursor}
-&lt;/f:view&gt;
-&lt;/body&gt;
-&lt;/html&gt;
- </pattern>
- </template>
- <template
- autoinsert="true"
- contextTypeId="jsp_attribute_value"
- description="%NewELExpression_description"
- id="org.eclipse.jst.jsf.ui.newelexpression"
- name="%NewELExpression">
- <pattern>
- "#{${cursor}}"
- </pattern>
- </template>
- </extension>
-
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUITraceOptions.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUITraceOptions.java
deleted file mode 100644
index 8c78cd5bf..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUITraceOptions.java
+++ /dev/null
@@ -1,72 +0,0 @@
-package org.eclipse.jst.jsf.ui.internal;
-
-import org.eclipse.osgi.framework.debug.FrameworkDebugOptions;
-import org.eclipse.osgi.service.debug.DebugOptions;
-
-/**
- * Defines that standard runtime trace options for debugging. See .options file
- * for definitions.
- *
- * @author cbateman
- *
- */
-public final class JSFUITraceOptions
-{
- /**
- * True if debug tracing is enabled. Other tracing cannot be enabled unless
- * this is enabled.
- */
- public static final boolean ENABLED;
-
- /**
- * True if development mode for meta-data generation is enabled
- */
- public static final boolean TRACE_METADATAGEN;
-
- private static final String KEY_DEBUG_ENABLED = "/debug"; //$NON-NLS-1$
- private static final String KEY_DESIGNTIME = "/metadatagen"; //$NON-NLS-1$
-
-
- static
- {
- final DebugOptions debugOptions = FrameworkDebugOptions.getDefault();
-
- ENABLED = debugOptions != null
- && debugOptions.getBooleanOption(JSFUiPlugin.PLUGIN_ID
- + KEY_DEBUG_ENABLED, false);
-
- if (ENABLED)
- {
- TRACE_METADATAGEN = debugOptions.getBooleanOption(
- JSFUiPlugin.PLUGIN_ID + KEY_DESIGNTIME, false);
- }
- else
- {
- TRACE_METADATAGEN = false;
- }
- }
-
- /**
- * @param message
- */
- public static void log(final String message)
- {
- System.out.println(message);
- }
-
- /**
- * @param msg A short label placed before the trace of t to show the source
- * @param t
- */
- public static void log(final String msg, final Throwable t)
- {
- System.out.printf("%s: Exception Trace:\n\n",msg); //$NON-NLS-1$
- t.printStackTrace(System.out);
- System.out.print("\n\n\n"); //$NON-NLS-1$
- }
-
- private JSFUITraceOptions()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUiPlugin.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUiPlugin.java
deleted file mode 100644
index 31977d4d7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/JSFUiPlugin.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 Oracle Corporation.
- * 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:
- * Gerry Kessler - initial API and implementation
- * Ian Trimble - added logging methods
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * JSF UI plugin.
- *
- * @author Gerry Kessler - Oracle, Ian Trimble - Oracle
- */
-public class JSFUiPlugin extends AbstractUIPlugin {
-
- /**
- * The plugin id
- */
- public static final String PLUGIN_ID = "org.eclipse.jst.jsf.ui"; //$NON-NLS-1$
- //The shared instance.
- private static JSFUiPlugin plugin;
-
- /**
- * The constructor.
- */
- public JSFUiPlugin() {
- 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.
- * @return the default plugin instance
- */
- public static JSFUiPlugin 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) {
- path = "icons/" + path; //$NON-NLS-1$
- return AbstractUIPlugin.imageDescriptorFromPlugin("org.eclipse.jst.jsf.ui", path); //$NON-NLS-1$
- }
-
- /**
- * Returns a shared image for the given name
- * <p>
- * Note: Images returned from this method will be automitically disposed of
- * when this plug-in shuts down. Callers must not dispose of these images
- * themselves.
- * </p>
- *
- * @param name
- * the image name found in /icons (with extension)
- * @return the image, null on error or not found.
- */
- public Image getImage(String name) {
- if (name == null) {
- return null;
- }
-
- ImageRegistry images = getImageRegistry();
- Image image = images.get(name);
- if (image == null) {
- try {
- final URL pluginBase= getBundle().getEntry("/");; //$NON-NLS-1$
- ImageDescriptor id = ImageDescriptor.createFromURL(new URL(
- pluginBase, "icons/" + name)); //$NON-NLS-1$
- images.put(name, id);
-
- image = images.get(name);
- } catch (MalformedURLException ee) {
- // log.CommonPlugin.image.error=Image {0} not found.
- //.error("log.msg", "log.CommonPlugin.image.error", name, ee);
- log(IStatus.ERROR, "Loading image", ee); //$NON-NLS-1$
- }
- }
- return image;
- }
- /**
- * @return the plugin id
- */
- public String getPluginID() {
- return PLUGIN_ID;
- }
-
- /**
- * Logs using the default ILog implementation provided by getLog().
- *
- * @param severity Severity (IStatus constant) of log entry
- * @param message Human-readable message describing log entry
- * @param ex Throwable instance (can be null)
- */
- public static void log(int severity, String message, Throwable ex) {
- getDefault().getLog().log(new Status(severity, PLUGIN_ID, IStatus.OK, message, ex));
- }
-
- /**
- * Logs using the default ILog implementation provided by getLog().
- *
- * @param severity Severity (IStatus constant) of log entry
- * @param message Human-readable message describing log entry
- */
- public static void log(int severity, String message) {
- log(severity, message, null);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/Messages.java
deleted file mode 100644
index 1fd9d71ee..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/Messages.java
+++ /dev/null
@@ -1,331 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 Oracle Corporation.
- * 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:
- * Gerry Kessler - initial API and implementation
- * Ian Trimble - changed to work correctly with org.eclipse.osgi.util.NLS
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler.
- *
- * @author Gerry Kessler - Oracle, Ian Trimble - Oracle
- */
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.messages"; //$NON-NLS-1$
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFImplementationLibrariesFrame;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFComponentLibrariesFrame;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_title;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_description;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFImplLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_Add1;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_Add2;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_DeployJarsLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFConfigLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFServletNameLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFServletClassNameLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_JSFURLMappingLabel;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_PatternDialogTitle;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_PatternDialogDesc;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_Remove;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_PatternEmptyMsg;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_PatternSpecifiedMsg;
- /**
- * see messages.properties
- */
- public static String JSFFacetInstallPage_ErrorNoWebAppDataModel;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_DEFAULT_IMPL_DESC;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_DefinedJSFLibraries;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_IMPL_DESC;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_MISSING_DESC;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_New;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_Edit;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_Remove;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_CannotRemovePluginProvidedTitle;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_CannotRemovePluginProvidedMessage;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_MakeDefault;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_Description;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_CannotModifyPluginProvidedTitle;
- /**
- * see messages.properties
- */
- public static String JSFLibrariesPreferencePage_CannotModifyPluginProvidedMessage;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_Add;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_AddAll;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_ImplementationLibrary;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_NewComponentLibrary;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_NullProject;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_DeployJAR;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_Remove;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_RemoveAll;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_TH_Deploy;
- /**
- * see messages.properties
- */
- public static String JSFLibraryConfigControl_TH_LibraryName;
-
-
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_PageName;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_Title;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_Description;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_WarningNoJSFFacet;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_JSFLibraries;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_Add;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_Edit;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_ErrorInitializing;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_ImplAlreadyPresent;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_SelectOneImpl;
- /**
- * see messages.properties
- */
- public static String JSFLibraryContainerWizardPage_EditLibrary_DescriptionText;
- /**
- * see messages.properties
- */
- public static String JSFLibraryPropertyPage_No_JSF_Facet_Installed;
- /**
- * see messages.properties
- */
- public static String JSFLibraryPropertyPage_No_JSF_Implementation_Lib_Selected;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_DESCRIPTION;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_CreateJSFLibrary;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_EditJSFLibrary;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_JSFLibrary;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_JSFLibraryWizard_DontShowThisAgain_CheckBoxLabel;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_LibraryName;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_VersionSupported;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_LibraryJars;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_DeployJars;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_Add;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_Remove;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_ExtJarFileDialogTitle;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_ValidateNoJars;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_ValidateNoLibraryName;
- /**
- * see messages.properties
- */
- public static String JSFLibraryWizard_ValidateExistingLibraryName;
-
- /**
- * Title set on the el validation preference panel
- */
- public static String JSFValidationPreferencePage_ELPrefPanel_Title;
- /**
- * Title set on the checkbox that enables/disables build validation for EL
- */
- public static String JSFValidationPreferencePage_ELPrefPanel_BuildValidationCheckBoxTitle;
- /**
- * Title set on the checkbox that enables/disables incremental (as you type)
- * validation for EL
- */
- public static String JSFValidationPreferencePage_ELPrefPanel_IncrementalValidationCheckBoxTitle;
-
- /**
- * see messages.properties
- */
- public static String JSFLibraryEditControl_ImplVersion_UNKNOWN;
-
- /**
- * see messages.properties
- */
- public static String JSFPreferences_RootPage_Description;
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryContainerWizardPage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryContainerWizardPage.java
deleted file mode 100644
index c8468c2f7..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryContainerWizardPage.java
+++ /dev/null
@@ -1,558 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 2007 Oracle Corporation.
- * 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:
- * Gerry Kessler - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.core.IClasspathEntry;
-import org.eclipse.jdt.core.IJavaProject;
-import org.eclipse.jdt.core.JavaCore;
-import org.eclipse.jdt.ui.wizards.IClasspathContainerPage;
-import org.eclipse.jdt.ui.wizards.IClasspathContainerPageExtension;
-import org.eclipse.jdt.ui.wizards.IClasspathContainerPageExtension2;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTableViewer;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerComparator;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.PluginProvidedJSFLibrary;
-import org.eclipse.jst.jsf.core.jsfappconfig.JSFAppConfigUtils;
-import org.eclipse.jst.jsf.core.jsflibraryconfiguration.JSFLibraryConfigurationHelper;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.swt.SWT;
-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.Composite;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchWizard;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Provides a classpath container wizard page for JSF Libraries.
- *
- * @author Gerry Kessler - Oracle
- * @deprecated
- */
-public class JSFLibraryContainerWizardPage extends WizardPage implements
- IClasspathContainerPage, IClasspathContainerPageExtension, IClasspathContainerPageExtension2{
-
- private CheckboxTableViewer lv;
- private JSFLibrariesTableViewerAdapter lvAdapter;
- private JSFLibrariesListLabelProvider lvLabelProvider;
-
- private boolean isJSFProject = false;
- private IClasspathEntry containerEntry;
- private IClasspathEntry[] currentEntries;
- private Map _currentLibs;
- private JSFLibrary currentLib;
-
- private IProject _iproject;
-
- /**
- * Zero arg constructor
- */
- public JSFLibraryContainerWizardPage(){
- super(Messages.JSFLibraryContainerWizardPage_PageName);
- setTitle(Messages.JSFLibraryContainerWizardPage_Title);
- setDescription(Messages.JSFLibraryContainerWizardPage_Description);
- // TODO: Replace with a custom image.
- setImageDescriptor( JSFUiPlugin.getImageDescriptor("full/wizban/addlibrary_wiz.gif")); //$NON-NLS-1$
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPageExtension#initialize(org.eclipse.jdt.core.IJavaProject, org.eclipse.jdt.core.IClasspathEntry[])
- */
- public void initialize(IJavaProject project, IClasspathEntry[] currentEntries_) {
- this.currentEntries = currentEntries_;
-
- _iproject = project.getProject();
- this.isJSFProject = JSFAppConfigUtils.isValidJSFProject(_iproject);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPage#finish()
- */
- public boolean finish() {
- return true;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPageExtension2#getNewContainers()
- */
- public IClasspathEntry[] getNewContainers() {
- IPath cp = new Path(JSFLibraryConfigurationHelper.JSF_LIBRARY_CP_CONTAINER_ID);
- List res = new ArrayList();
- Object[] items = lv.getCheckedElements();
- for (int i=0;i<items.length;i++){
- JSFLibrary jsfLib = (JSFLibrary)items[i];
- if (getSelectedJSFLibariesForProject().get(jsfLib.getID()) == null){
- IPath path = cp.append(new Path(jsfLib.getID()));
- IClasspathEntry entry = JavaCore.newContainerEntry(path);
- // need to update wtp dependency in j2ee mod dependency ui
- res.add(entry);
- }
- }
- return (IClasspathEntry[])res.toArray(new IClasspathEntry[]{});
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.wizard.WizardPage#isPageComplete()
- */
- public boolean isPageComplete() {
- if (!isJSFProject) {
- return false;
- }
- if (isEditReference() && ! selectionHasChanged())
- return false;
-
- return isValid();
- }
-
- private boolean isValid() {
- return isCheckedItems() && getErrorMessage() == null;
- }
-
- //to be used to know whether the selected library has changed when in "edit" mode
- private boolean selectionHasChanged() {
- JSFLibrary lib = getCurrentLibrarySelection();
- if (lib == null)
- return false;
-
- return (getJSFLibraryForEdit(containerEntry) != lib) ;
-
- }
-
- private JSFLibrary getCurrentLibrarySelection() {
- JSFLibrary lib = null;
- StructuredSelection ssel = (StructuredSelection)lv.getSelection();
- if (ssel != null && !ssel.isEmpty()){
- lib = (JSFLibrary)ssel.getFirstElement();
- }
- return lib;
- }
-
- private boolean isCheckedItems() {
- return lv.getCheckedElements().length > 0;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPage#getSelection()
- */
- public IClasspathEntry getSelection() {
- IClasspathEntry entry = null;
- if (isEditReference()){
- if (lv.getCheckedElements().length == 0)
- return containerEntry;
-
- JSFLibrary lib = (JSFLibrary)lv.getCheckedElements()[0];
- if (lib != null){
- if (lib == getJSFLibraryForEdit(containerEntry))
- {
- return containerEntry;
- }
- IPath path = new Path(JSFLibraryConfigurationHelper.JSF_LIBRARY_CP_CONTAINER_ID).append(new Path(lib.getID()));
- entry = JavaCore.newContainerEntry(path, containerEntry.getAccessRules(), containerEntry.getExtraAttributes(),containerEntry.isExported());
- }
- }
- return entry;
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPage#setSelection(org.eclipse.jdt.core.IClasspathEntry)
- */
- public void setSelection(IClasspathEntry containerEntry) {
- //this is signalling that this is an "edit"
- this.containerEntry = containerEntry;
- }
-
- public void createControl(Composite parent) {
- //Build UI to display JSF Lib components from registry
- Composite c = new Composite(parent, SWT.NONE);
- c.setLayout(new GridLayout(2, false));
- c.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- //disable wizard if this is not a valid JSF project
- if (!isJSFProject){
- Label warning = new Label(c , SWT.NONE);
- warning.setText(Messages.JSFLibraryContainerWizardPage_WarningNoJSFFacet);
- setControl(c);
- return;
- }
-
- Label lblViewer = new Label(c, SWT.NONE);
- lblViewer.setText(Messages.JSFLibraryContainerWizardPage_JSFLibraries);
- GridData gd1 = new GridData(GridData.BEGINNING);
- gd1.horizontalSpan = 2;
- lblViewer.setLayoutData(gd1);
-
- lv = createTableViewer(c);
- lv.getControl().setLayoutData(new GridData(GridData.FILL_BOTH));
-
- lvAdapter = new JSFLibrariesTableViewerAdapter();
- lvLabelProvider = new JSFLibrariesListLabelProvider();
- lv.setContentProvider(lvAdapter);
- lv.setLabelProvider(lvLabelProvider);
- lv.addSelectionChangedListener(lvAdapter);
- lv.addDoubleClickListener(lvAdapter);
- lv.setComparator(lvAdapter);
-
- Composite buttons = new Composite(c, SWT.NONE);
- buttons.setLayout(new GridLayout(1, false));
- buttons.setLayoutData(new GridData(GridData.FILL_VERTICAL));
-
- final Button addButton = new Button(buttons, SWT.NONE);
- addButton.setText(Messages.JSFLibraryContainerWizardPage_Add);
- addButton.setLayoutData(new GridData(GridData.END | GridData.VERTICAL_ALIGN_BEGINNING));
- addButton.addSelectionListener(new SelectionAdapter(){
- public void widgetSelected(SelectionEvent e){
- openJSFLibraryWizard(null);
- }
- });
-
- final Button editButton = new Button(buttons, SWT.NONE);
- editButton.setText(Messages.JSFLibraryContainerWizardPage_Edit);
- editButton.setLayoutData(new GridData(GridData.END | GridData.VERTICAL_ALIGN_BEGINNING));
- editButton.addSelectionListener(new SelectionAdapter(){
- public void widgetSelected(SelectionEvent e){
- StructuredSelection sel = (StructuredSelection)lv.getSelection();
- if ((sel == null || sel.isEmpty()) && containerEntry != null){
- JSFLibrary jsfLib = getJSFLibraryForEdit(containerEntry);
- sel = new StructuredSelection(jsfLib);
- }
- openJSFLibraryWizard(sel);
- }
-
- });
- editButton.setVisible(false);
- lv.addSelectionChangedListener(new ISelectionChangedListener(){
- public void selectionChanged(SelectionChangedEvent event) {
- setEditButton(event.getSelection());
- }
-
- private void setEditButton(final ISelection selection) {
- IStructuredSelection sel = (IStructuredSelection)selection;
- editButton.setVisible(sel.size()==1);
- if (sel.size() == 1){
- JSFLibrary lib = (JSFLibrary)sel.getFirstElement();
- boolean pp = lib instanceof PluginProvidedJSFLibrary;
- editButton.setEnabled(! pp);
- if (isEditReference()){
- lv.setAllChecked(false);
- lv.setChecked(lib, true);
- }
- }
-
- }
- });
- setControl(c);
-
- if (isEditReference()){
- JSFLibrary lib = getJSFLibraryForEdit(containerEntry);
- lv.setInput(getAllUnselectedJSFLibrariesExceptReferencedLib(lib));
- selectAndCheckCurrentLib(lib);
- setDescription(Messages.JSFLibraryContainerWizardPage_EditLibrary_DescriptionText);
- }
- else {
- lv.setInput(getAllJSFLibraries());
- lv.setCheckedElements(getSelectedJSFLibariesForProject().values().toArray(new Object[0]));
- }
- }
-
- private void selectAndCheckCurrentLib(final JSFLibrary lib) {
- if (lib != null){
- StructuredSelection ssel = new StructuredSelection(lib);
- lv.setSelection(ssel);
- lv.setChecked(lib, true);
- }
- }
-
- private Object getAllUnselectedJSFLibrariesExceptReferencedLib(JSFLibrary referenceLib) {
- List allLibs = getAllJSFLibraries();
- Collection selLibs = getSelectedJSFLibariesForProject().values();
- for (Iterator it=selLibs.iterator();it.hasNext();){
- JSFLibrary aLib = (JSFLibrary)it.next();
- int i= allLibs.indexOf(aLib);
- //remove from allLibs unless it is the selected reference
- if (i >= 0 && ((referenceLib == null) || (aLib != null && ! aLib.getID().equals(referenceLib.getID())))){
- allLibs.remove(i);
- }
- }
- return allLibs;
- }
-
- private List getJSFLibraryEntries(IClasspathEntry[] entries) {
- List jsfLibs = new ArrayList();
- for (int i=0;i<entries.length;i++){
- IClasspathEntry entry = entries[i];
- if (JSFLibraryConfigurationHelper.isJSFLibraryContainer(entry)){
- JSFLibrary lib = JSFLibraryRegistryUtil.getInstance().getJSFLibraryRegistry(). getJSFLibraryByID(getLibraryId(entry));
- if (lib != null){
- jsfLibs.add(lib);
- }
- }
- }
-
- return jsfLibs;
- }
-
- private String getLibraryId(IClasspathEntry entry) {
- return entry.getPath().segment(1);
- }
-
- private void openJSFLibraryWizard(IStructuredSelection element){
- IWorkbenchWizard wizard = new JSFLibraryWizard();
- IWorkbench wb = PlatformUI.getWorkbench();
- wizard.init(wb, element);
- WizardDialog dialog = new WizardDialog(wb.getActiveWorkbenchWindow().getShell(), wizard);
- int ret = dialog.open();
- if (ret == Window.OK){
- //FIXME: select returned object
- if (containerEntry == null){
- lv.setInput(getAllJSFLibraries());
- }
- else {
- lv.setInput(getAllUnselectedJSFLibrariesExceptReferencedLib(getJSFLibraryForEdit(containerEntry)));
- lv.refresh(true);
- }
- lv.refresh();
- }
- }
-
- private CheckboxTableViewer createTableViewer(Composite parent) {
- Table table= new Table(parent, SWT.CHECK | SWT.BORDER | SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
- table.setFont(parent.getFont());
- CheckboxTableViewer tableViewer= new CheckboxTableViewer(table);
- tableViewer.addCheckStateListener(new ICheckStateListener() {
- public void checkStateChanged(CheckStateChangedEvent e) {
- if (! isEditReference()){
- //ensure that existing CP entries cannot be unchecked
- if (getSelectedJSFLibariesForProject().get(((JSFLibrary)e.getElement()).getID()) != null){
- if (containerEntry == null)
- e.getCheckable().setChecked(e.getElement(), true);
- else
- lv.setAllChecked(true);
- }
- }
- else {
- //select only one
- lv.setAllChecked(false);
- lv.setChecked(e.getElement(), true);
- if (isEditReference())
- lv.setSelection(new StructuredSelection(e.getElement()));
- }
- validate();
- }
- });
- return tableViewer;
- }
-
- private Map getSelectedJSFLibariesForProject(){
- if (_currentLibs == null){
- List allLibs = getAllJSFLibraries();
- List curLibs = getJSFLibraryEntries(currentEntries);
- _currentLibs = new HashMap(curLibs.size());
- for (Iterator it=curLibs.iterator();it.hasNext();){
- JSFLibrary lib = (JSFLibrary)it.next();
- int index = getIndex(allLibs, lib);
- if (index >=0)
- _currentLibs.put(lib.getID(), allLibs.get(index));
- }
-
- }
- return _currentLibs;
- }
-
- private List getAllJSFLibraries() {
- List allLibs = JSFLibraryRegistryUtil.getInstance().getJSFLibraryRegistry().getAllJSFLibraries();
-
- return allLibs;
- }
-
-
- private JSFLibrary getJSFLibraryForEdit(
- IClasspathEntry containerEntry_) {
- if (currentLib == null){
- String id = getLibraryId(containerEntry_);
- currentLib = JSFLibraryRegistryUtil.getInstance().getJSFLibraryRegistry().getJSFLibraryByID(id);
- }
- return currentLib;
-
- }
-
- private int getIndex(List libs, JSFLibrary lib) {
- for (int i=0;i<libs.size();i++){
- if (lib.getID().equals(((JSFLibrary)libs.get(i)).getID()))
- return i;
- }
- return -1;
- }
-
- private class JSFLibrariesTableViewerAdapter extends ViewerComparator implements IStructuredContentProvider, ISelectionChangedListener, IDoubleClickListener {
-
- private Object input;
-
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- input = newInput;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.IContentProvider#dispose()
- */
- public void dispose() {
- // do nothing
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object)
- */
- public Object[] getElements(Object inputElement) {
- return ((List)input).toArray();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ISelectionChangedListener#selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent)
- */
- public void selectionChanged(SelectionChangedEvent event) {
- if (isEditReference()){
- setPageComplete(isPageComplete());
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.IDoubleClickListener#doubleClick(org.eclipse.jface.viewers.DoubleClickEvent)
- */
- public void doubleClick(DoubleClickEvent event) {
- doDoubleClick(event);
- }
-
- public int compare(Viewer viewer, Object e1, Object e2) {
- JSFLibrary lib1 = (JSFLibrary)e1;
- JSFLibrary lib2 = (JSFLibrary)e2;
-
- //sort first by in selection already and then by name
- boolean lib1Sel = getSelectedJSFLibariesForProject().get(lib1.getID())!=null;
- boolean lib2Sel = getSelectedJSFLibariesForProject().get(lib2.getID())!= null;
-
- if ((lib1Sel && lib2Sel) || (!lib1Sel && !lib2Sel) ){
- return getComparator().compare(lib1.getLabel(), lib2.getLabel());
- }
- else if (lib1Sel)
- return -1;
- else
- return 1;
- }
- }
-
- private static class JSFLibrariesListLabelProvider implements ILabelProvider{
- Image libImg;
- public Image getImage(Object element) {
- if (libImg == null){
- ImageDescriptor libImgDesc = JSFUiPlugin.getImageDescriptor("obj16/library_obj.gif"); //$NON-NLS-1$
- libImg = libImgDesc.createImage();
- }
- return libImg;
- }
-
- public String getText(Object element) {
- if (element instanceof JSFLibrary) {
- JSFLibrary lib = (JSFLibrary)element;
- if (lib.isImplementation()) {
- return lib.getLabel() + " " + Messages.JSFLibrariesPreferencePage_IMPL_DESC; //$NON-NLS-1$
- }
- return lib.getLabel();
- }
- return null;
- }
-
- public void dispose() {
- if (libImg != null)
- libImg.dispose();
- }
-
- public void addListener(ILabelProviderListener listener) {
- // no listener support
- }
-
- public boolean isLabelProperty(Object element, String property) {
- return false;
- }
-
- public void removeListener(ILabelProviderListener listener) {
- // no listener support
- }
- }
-
- private void validate() {
- setErrorMessage(null);
- int implChosenCount = implSelectedCount();
- if (implChosenCount>1){
- setErrorMessage(Messages.JSFLibraryContainerWizardPage_ImplAlreadyPresent);
- }
- setPageComplete(isPageComplete());
- }
-
-
- private boolean isEditReference() {
- return (containerEntry != null);
- }
-
- private int implSelectedCount() {
- int count = 0;
- for (int i=0;i<lv.getCheckedElements().length;i++){
- JSFLibrary lib = (JSFLibrary)lv.getCheckedElements()[i];
- if (lib.isImplementation())
- count++;
- }
- return count;
- }
-
- private void doDoubleClick(DoubleClickEvent event) {
- StructuredSelection ssel = (StructuredSelection)event.getSelection();
- if (ssel != null &&
- (! ((JSFLibrary)ssel.getFirstElement() instanceof PluginProvidedJSFLibrary)))
- openJSFLibraryWizard((IStructuredSelection)event.getSelection());
- }
-
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryEditControl.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryEditControl.java
deleted file mode 100644
index 5b456c2c0..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryEditControl.java
+++ /dev/null
@@ -1,465 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Set;
-
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.ArchiveFile;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibraryRegistryFactory;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFVersion;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-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.events.SelectionListener;
-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.Composite;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Common control for adding JSF library instances
- * @deprecated
- */
-public class JSFLibraryEditControl extends Composite implements ModifyListener, SelectionListener
-{
- private Text txtName;
- private Label lblName;
- private CCombo cboVersions;
- private Label lblVersions;
- private Button chkDeploy;
- private Composite btnBar;
- private Button btnAdd;
- private Button btnRemove;
- private TableViewer jars;
-
- private boolean initing = false;
-
- private JSFLibrary workingCopyLibrary;
-
- private String validationMsg;
- private Set _listeners;
- private int _isNew = -1;//use isNew() method.. not this variable directly
-
- /**
- * @param workingCopyLibrary working copy of the JSF library
- * @param parent parent SWT control
- */
- public JSFLibraryEditControl(JSFLibrary workingCopyLibrary, Composite parent){
- super(parent, SWT.NONE);
- this.workingCopyLibrary = workingCopyLibrary;
- _listeners = new HashSet(1);
- createControl(parent);
- }
-
- /**
- * @param listener
- */
- public void addValidationListener(JSFLibraryValidationListener listener){
- removeValidationListener(listener);
- _listeners.add(listener);
- }
-
- /**
- * @param listener
- */
- public void removeValidationListener(JSFLibraryValidationListener listener){
- _listeners.remove(listener);
- }
-
- /**
- * @param parent
- */
- public void createControl(Composite parent) {
- initing = true;
-
-// this = new Composite(parent, SWT.NONE);
- this.setLayout(new GridLayout(2, false));
- this.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- lblName = new Label(this, SWT.NONE);
- lblName.setText(Messages.JSFLibraryWizard_LibraryName);
- lblName.setLayoutData(new GridData(GridData.BEGINNING));
-
- txtName = new Text(this, SWT.BORDER);
- txtName.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- txtName.addModifyListener(this);
-
- lblVersions = new Label(this, SWT.NONE);
- lblVersions.setText(Messages.JSFLibraryWizard_VersionSupported);
-
- cboVersions = new CCombo(this, SWT.SINGLE | SWT.READ_ONLY | SWT.BORDER);
- cboVersions.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- cboVersions.addModifyListener(this);
-
- Group jarsComp = new Group(this, SWT.NONE);
- jarsComp.setText(Messages.JSFLibraryWizard_LibraryJars);
- GridLayout gl1 = new GridLayout(2, false);
- jarsComp.setLayout(gl1);
- GridData gd2 = new GridData(GridData.FILL_HORIZONTAL
- | GridData.FILL_VERTICAL);
- gd2.horizontalSpan = 2;
- jarsComp.setLayoutData(gd2);
-
- createJarsViewer(jarsComp);
-
- createButtons(jarsComp);
-
- chkDeploy = new Button(this, SWT.CHECK);
- chkDeploy.setText(Messages.JSFLibraryWizard_DeployJars);
- GridData gd4 = new GridData();
- gd4.horizontalSpan = 2;
- chkDeploy.setLayoutData(gd4);
-// chkDeploy.addSelectionListener(this);
- chkDeploy.setVisible(false);
-
- loadVersions();
-
- if (!isNew()) {
- txtName.setText(workingCopyLibrary.getName());
- if (workingCopyLibrary.getJSFVersion().getName().equals(JSFVersion.UNKNOWN_LITERAL.getName())) {
- cboVersions.setText(Messages.JSFLibraryEditControl_ImplVersion_UNKNOWN);
- } else {
- cboVersions.setText(workingCopyLibrary.getJSFVersion().getName());
- }
- chkDeploy.setSelection(workingCopyLibrary.isDeployed());
- }
- jars.setInput(workingCopyLibrary);
-
- initing = false;
-
- txtName.setFocus();
- }
-
- private void createJarsViewer(Group jarsComp) {
- jars = new TableViewer(jarsComp, SWT.BORDER | SWT.MULTI);
- jars.setContentProvider(new IStructuredContentProvider() {
- public Object[] getElements(Object inputElement) {
- if (inputElement instanceof JSFLibrary)
- return ((JSFLibrary) inputElement).getArchiveFiles()
- .toArray();
- return new Object[0];
- }
-
- public void dispose() {
- // do nothing
- }
-
- public void inputChanged(Viewer viewer, Object oldInput,
- Object newInput) {
- // won't happen
- }
- });
- jars.setLabelProvider(new ILabelProvider() {
- private Image jarImg = null;
- public Image getImage(Object element) {
- if (jarImg == null){
- ImageDescriptor desc = JSFUiPlugin.getImageDescriptor("obj16/jar_obj.gif"); //$NON-NLS-1$
- jarImg = desc.createImage();
- }
- return jarImg;
- }
-
- public String getText(Object element) {
- StringBuffer labelBuf = new StringBuffer();
- if (element instanceof ArchiveFile) {
- ArchiveFile archive = (ArchiveFile) element;
- labelBuf.append(archive.getName());
- if (!archive.exists())
- labelBuf.append(Messages.JSFLibrariesPreferencePage_MISSING_DESC);
- labelBuf.append(" - ").append(archive.getPath()); //$NON-NLS-1$
- }
- return labelBuf.toString();
- }
-
- public void addListener(ILabelProviderListener listener) {
- // no listeners supported
- }
-
- public void dispose() {
- if (jarImg != null)
- jarImg.dispose();
- }
-
- public boolean isLabelProperty(Object element, String property) {
- return false;
- }
-
- public void removeListener(ILabelProviderListener listener) {
- // no listeners supported
- }
- });
-
- jars.addSelectionChangedListener(new ISelectionChangedListener(){
- public void selectionChanged(SelectionChangedEvent event){
- updateButtons();
- }
- });
-
- GridData gd = new GridData(GridData.FILL_BOTH);
-// gd.widthHint = convertWidthInCharsToPixels(30);
-// gd.heightHint = convertHeightInCharsToPixels(10);
- jars.getControl().setLayoutData(gd);
- }
-
- private void updateButtons() {
- btnRemove.setEnabled(!((StructuredSelection)jars.getSelection()).isEmpty());
- // getButton(IDialogConstants.OK_ID).setEnabled(modified);
- }
-
- private void createButtons(Composite c) {
- btnBar = new Composite(c, SWT.NONE);
- GridLayout gl = new GridLayout(1, false);
- gl.marginHeight = 0;
- gl.marginTop = 0;
- gl.marginWidth = 0;
- btnBar.setLayout(gl);
- btnBar.setLayoutData(new GridData(GridData.END));
-
- btnAdd = new Button(btnBar, SWT.NONE);
- btnAdd.setText(Messages.JSFLibraryWizard_Add);
- btnAdd.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- btnAdd.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- String cur = null;
- String[] chosenJars = openExtJarFileDialog(cur);
- if (chosenJars != null) {
- for (int i = 0; i < chosenJars.length; i++) {
- String jar = chosenJars[i];
- if (!workingCopyLibrary.containsArchiveFile(jar)) {
- ArchiveFile archive = JSFLibraryRegistryFactory.eINSTANCE
- .createArchiveFile();
- archive.setSourceLocation(jar);
- archive.setRelativeDestLocation("WEB-INF/lib"); //$NON-NLS-1$
- workingCopyLibrary.getArchiveFiles().add(archive);
- }
- }
- jars.refresh();
- validate();
- }
- }
- });
-
- btnRemove = new Button(btnBar, SWT.NONE);
- btnRemove.setEnabled(false);
- btnRemove.setText(Messages.JSFLibraryWizard_Remove);
- btnRemove.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- btnRemove.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- if (jars.getSelection() instanceof StructuredSelection){
- StructuredSelection objs = (StructuredSelection)jars.getSelection();
- if (objs != null){
- Iterator it = objs.iterator();
- while (it.hasNext()){
- Object obj = it.next();
- ArchiveFile jar = (ArchiveFile)obj;
- workingCopyLibrary.getArchiveFiles().remove(jar);
- }
- }
- jars.refresh();
- validate();
- }
- }
- });
- }
-
- private void loadVersions() {
- cboVersions.removeAll();
- Iterator it = JSFVersion.VALUES.iterator();
- while (it.hasNext()) {
- JSFVersion ver = (JSFVersion) it.next();
- if (ver.getName().equals(JSFVersion.UNKNOWN_LITERAL.getName())) {
- cboVersions.add(Messages.JSFLibraryEditControl_ImplVersion_UNKNOWN);
- } else {
- cboVersions.add(ver.getName());
- }
- }
- }
-
- private String[] openExtJarFileDialog(String existing) {
- String title = Messages.JSFLibraryWizard_ExtJarFileDialogTitle;
-
- FileDialog dialog = new FileDialog(getShell(),
- existing == null ? SWT.MULTI : SWT.SINGLE);
- dialog.setText(title);
- dialog.setFilterExtensions(new String[] { "*.jar;*.zip" }); //$NON-NLS-1$
- // FIXME: remember and use last path chosen??
- String filterPath = ResourcesPlugin.getWorkspace().getRoot()
- .getFullPath().toString();
- dialog.setFilterPath(filterPath);
- // if (existing != null) {
- // dialog.setFileName(existing.getPath().lastSegment());
- // }
-
- String res = dialog.open();
- if (res == null) {
- return null;
- }
- String[] fileNames = dialog.getFileNames();
- String[] elems = new String[fileNames.length];
- IPath file = new Path(res);
- IPath apath = file.removeLastSegments(1);
- for (int i = 0; i < fileNames.length; i++) {
- elems[i] = apath.append(fileNames[i]).toString();
- }
- return elems;
- }
-
- public void modifyText(ModifyEvent e) {
- validate();
- updateButtons();
- }
-
- private void fireValidateEvent(final JSFLibraryValidationEvent jSFLibraryValidationEvent) {
- new Runnable(){
- public void run() {
- for (Iterator it=_listeners.iterator();it.hasNext();){
- JSFLibraryValidationListener listener = (JSFLibraryValidationListener)it.next();
- listener.notifyValidation(jSFLibraryValidationEvent);
- }
- }
- }.run();
- }
-
-
- public void widgetSelected(SelectionEvent e) {
- validate();
- updateButtons();
- }
-
- public void widgetDefaultSelected(SelectionEvent e) {
- // no handling for default selection
- }
-
- private void validate() {
- if (initing)
- return;
- validationMsg = null;
-// setPageComplete(true);
- if (!validateName() || !validateJars() || !validateVersion()) {
-// setPageComplete(false);
- }
- fireValidateEvent(new JSFLibraryValidationEvent(validationMsg));
- }
-
- private boolean validateJars() {
- if (workingCopyLibrary.getArchiveFiles().isEmpty()) {
- validationMsg = Messages.JSFLibraryWizard_ValidateNoJars;
- return false;
- }
- return true;
- }
-
- private boolean validateVersion() {
- //FIXME: why isn't selection indesx correct???
- // if (cboVersions.getSelectionIndex() < 0) {
- // setErrorMessage("Choose the maximum JSF version supported if known.");
- // return false;
- // }
- return true;
- }
-
- private boolean validateName() {
- if (txtName.getText() == null
- || txtName.getText().trim().equals("")) { //$NON-NLS-1$
- validationMsg = Messages.JSFLibraryWizard_ValidateNoLibraryName;
- return false;
- }
- String aName = txtName.getText().trim();
- if (isNew() || (!isNew() && !getCurrentLibraryName().equals(aName))) {
- if (isNameInRegistry(JSFLibraryRegistryUtil.getInstance()
- .getJSFLibraryRegistry().getAllJSFLibraries(), aName)) {
- validationMsg = Messages.JSFLibraryWizard_ValidateExistingLibraryName;
- return false;
- }
- }
- return true;
- }
-
- private boolean isNew() {
- if (_isNew == -1){
- _isNew = workingCopyLibrary.getName() == null ? 1 : 0;
- }
- return _isNew == 1;
- }
-
- private String getCurrentLibraryName() {
- return workingCopyLibrary.getName();
- }
-
- private boolean isNameInRegistry(Collection c, String name) {
- Iterator it = c.iterator();
- while (it.hasNext()) {
- JSFLibrary lib = (JSFLibrary) it.next();
- if (lib.getName().equals(name)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * @return the trimmed name of the user input for jsf library name
- */
- public String getJSFLibraryName() {
- return txtName.getText().trim();
- }
-
-
- /**
- * @return the value of the user input for the isDeployed checkbox
- */
- public boolean getIsDeployed() {
- return chkDeploy.getSelection();
- }
-
-
- /**
- * @return the jsf version selected in the version dropping
- */
- public JSFVersion getJSFVersion() {
- if (cboVersions.getSelectionIndex() >= 0) {
- JSFVersion ver = (JSFVersion) JSFVersion.VALUES.get(cboVersions
- .getSelectionIndex());
- return ver;
- }
- return JSFVersion.UNKNOWN_LITERAL;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationEvent.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationEvent.java
deleted file mode 100644
index 71855c585..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationEvent.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import org.eclipse.core.runtime.IStatus;
-
-/**
- * Validation event used by JSFLibraryControl to notify containers of updates
- * @deprecated
- */
-public class JSFLibraryValidationEvent {
- private String msg;
- private int severity;
-
- /**
- * Constructor
- * @param msg
- * @param severity - IStatus int value
- */
- public JSFLibraryValidationEvent(String msg, int severity) {
- this.msg = msg;
- this.severity = severity;
- }
-
- /**
- * Constructs event with severity of IStatus.ERROR
- * @param msg
- */
- public JSFLibraryValidationEvent(String msg) {
- this(msg, IStatus.ERROR);
- }
-
- /**
- * @return validation message
- */
- public String getMessage(){
- return msg;
- }
-
- /**
- * @return IStatus int value
- */
- public int getSeverity(){
- return severity;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationListener.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationListener.java
deleted file mode 100644
index 8dd1a4f10..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryValidationListener.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-/**
- * Listeners of {@link JSFLibraryValidationEvent}s should implement
- * @deprecated
- */
-public interface JSFLibraryValidationListener {
- /**
- * Callback
- * @param e
- */
- public void notifyValidation(JSFLibraryValidationEvent e);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryWizard.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryWizard.java
deleted file mode 100644
index 81d0e2e11..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibraryWizard.java
+++ /dev/null
@@ -1,162 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 Oracle Corporation.
- * 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:
- * Gerry Kessler - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.jface.wizard.WizardPage;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibraryRegistryFactory;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFVersion;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.INewWizard;
-import org.eclipse.ui.IWorkbench;
-
-/**
- * Dialog for creating or editing a JSF Library or Implementation.
- * <br>
- * If the selection passed in init is not null then the item will be edit mode.
- *
- * @author Gerry Kessler - Oracle
- * @deprecated
- */
-public class JSFLibraryWizard extends Wizard implements INewWizard {
-
- private JSFLibraryEditControl jsfLibraryEditControl;
-
- private boolean isNew = false;
- private boolean modified = false;
-
- private JSFLibrary curLibrary;
- private JSFLibrary workingCopyLibrary;
-
- private JSFLibraryWizardPage page;
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection)
- */
- public void init(IWorkbench workbench, IStructuredSelection selection)
- {
- if (selection != null
- && selection.getFirstElement() instanceof JSFLibrary) {
- curLibrary = (JSFLibrary) selection.getFirstElement();
- workingCopyLibrary = curLibrary.getWorkingCopy();
- } else {
- isNew = true;
- workingCopyLibrary = JSFLibraryRegistryFactory.eINSTANCE.createJSFLibrary();
- }
- setWindowTitle(isNew ? Messages.JSFLibraryWizard_CreateJSFLibrary : Messages.JSFLibraryWizard_EditJSFLibrary);
- }
-
- /**
- * Updates the JSF Library instance with the values from the working copy and
- * persists the registry.
- *
- * If editing a library reference, referencing java models will be updated.
- *
- * @see org.eclipse.jface.wizard.Wizard#performFinish()
- */
- public boolean performFinish()
- {
- final String name = jsfLibraryEditControl.getJSFLibraryName();
- final boolean isDeployed = jsfLibraryEditControl.getIsDeployed();
- final JSFVersion version = jsfLibraryEditControl.getJSFVersion();
-
- workingCopyLibrary.setName(name);
- workingCopyLibrary.setDeployed(isDeployed);
- workingCopyLibrary.setJSFVersion(version);
-
- final String originalID = curLibrary != null ? curLibrary.getID() :workingCopyLibrary.getID();
-
- if (isNew){
- JSFLibraryRegistryUtil.getInstance().getJSFLibraryRegistry().addJSFLibrary(workingCopyLibrary);
- }
- else {
- curLibrary.updateValues(workingCopyLibrary);
- try {
- JSFLibraryRegistryUtil.rebindClasspathContainerEntries(originalID, workingCopyLibrary.getID(), null);
- } catch (JavaModelException e) {
- JSFUiPlugin.log(IStatus.ERROR, "Exception while updating JSF Library containers", e); //$NON-NLS-1$
- }
- }
- JSFLibraryRegistryUtil.getInstance().saveJSFLibraryRegistry();
- return true;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.wizard.Wizard#addPages()
- */
- public void addPages() {
- page = new JSFLibraryWizardPage(Messages.JSFLibraryWizard_JSFLibrary);
- super.addPage(page);
- page.setWizard(this);
- }
-
- /**
- * @return the JSFLibrary being modified by this wizard
- */
- public JSFLibrary getJSFLibrary() {
- return workingCopyLibrary;
- }
-
- private class JSFLibraryWizardPage extends WizardPage {
-
- /**
- * @param pageName
- */
- protected JSFLibraryWizardPage(String pageName) {
- super(pageName);
- setDescription(Messages.JSFLibraryWizard_DESCRIPTION);
- setTitle(Messages.JSFLibraryWizard_JSFLibrary);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.wizard.WizardPage#isPageComplete()
- */
- public boolean isPageComplete() {
- if (modified == false) {
- return false;
- }
- return super.isPageComplete();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite)
- */
- public void createControl(Composite parent) {
- initializeDialogUnits(parent);
-
- jsfLibraryEditControl = new JSFLibraryEditControl(workingCopyLibrary, parent);
- jsfLibraryEditControl.setLayout(new GridLayout(2, false));
- jsfLibraryEditControl.setLayoutData(new GridData(GridData.FILL_BOTH));
-
- jsfLibraryEditControl.addValidationListener(new JSFLibraryValidationListener(){
- public void notifyValidation(JSFLibraryValidationEvent e) {
- setErrorMessage(e.getMessage());
- modified = true;
- setPageComplete(getErrorMessage()==null);
- }
- });
-
- setControl(jsfLibraryEditControl);
- setPageComplete(false);
- }
-
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialog.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialog.java
deleted file mode 100644
index ff08f6b7d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialog.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.layout.GridDataFactory;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.accessibility.AccessibleAdapter;
-import org.eclipse.swt.accessibility.AccessibleEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Customized warning dialog for JSF Library Upgrade warnings.
- *
- * @author cbateman
- * @deprecated
- */
-class WarningMessageDialog extends MessageDialog
-{
- private Text _messageLabel;
-
- /**
- * @param parent
- * @param title
- * @param message
- * @return true if the user hit OK
- *
- * Overriden to set the default button to CANCEL and use this dialog.
- */
- public static boolean openConfirm(Shell parent, String title, String message) {
- MessageDialog dialog = new WarningMessageDialog(parent, title, null, // accept
- // the
- // default
- // window
- // icon
- message, QUESTION, new String[] { IDialogConstants.OK_LABEL,
- IDialogConstants.CANCEL_LABEL }, 1); // CANCEL is the
- // default
- return dialog.open() == 0;
- }
-
- WarningMessageDialog(Shell parentShell, String dialogTitle,
- Image dialogTitleImage, String dialogMessage, int dialogImageType,
- String[] dialogButtonLabels, int defaultIndex) {
- super(parentShell, dialogTitle, dialogTitleImage, dialogMessage,
- dialogImageType, dialogButtonLabels, defaultIndex);
- }
-
- @Override
- protected Control createMessageArea(Composite composite)
- {
- // create composite
- // create image
- Image image = getImage();
- if (image != null) {
- imageLabel = new Label(composite, SWT.NULL);
- image.setBackground(imageLabel.getBackground());
- imageLabel.setImage(image);
- addAccessibleListeners(imageLabel, image);
- GridDataFactory.fillDefaults().align(SWT.CENTER, SWT.BEGINNING)
- .applyTo(imageLabel);
- }
- // create message
- if (message != null) {
- _messageLabel = new Text(composite, getMessageLabelStyle()|SWT.READ_ONLY);
- _messageLabel.setText(message);
- GridDataFactory
- .fillDefaults()
- .align(SWT.FILL, SWT.BEGINNING)
- .grab(true, false)
- .hint(
- convertHorizontalDLUsToPixels(IDialogConstants.MINIMUM_MESSAGE_AREA_WIDTH),
- SWT.DEFAULT).applyTo(_messageLabel);
- }
- return composite;
- }
-
- /**
- * NOTE: copied from IconAndMessageDialog
- * Add an accessible listener to the label if it can be inferred from the
- * image.
- *
- * @param label
- * @param image
- */
- private void addAccessibleListeners(Label label, final Image image) {
- label.getAccessible().addAccessibleListener(new AccessibleAdapter() {
- public void getName(AccessibleEvent event) {
- final String accessibleMessage = getAccessibleMessageFor(image);
- if (accessibleMessage == null) {
- return;
- }
- event.result = accessibleMessage;
- }
- });
- }
-
- /**
- * NOTE: copied from IconAndMessageDialog
- * @param image
- * @return an accesible string
- */
- private String getAccessibleMessageFor(Image image) {
- if (image.equals(getErrorImage())) {
- return JFaceResources.getString("error");//$NON-NLS-1$
- }
-
- if (image.equals(getWarningImage())) {
- return JFaceResources.getString("warning");//$NON-NLS-1$
- }
-
- if (image.equals(getInfoImage())) {
- return JFaceResources.getString("info");//$NON-NLS-1$
- }
-
- if (image.equals(getQuestionImage())) {
- return JFaceResources.getString("question"); //$NON-NLS-1$
- }
-
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialogWithToggle.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialogWithToggle.java
deleted file mode 100644
index f86700bfc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/WarningMessageDialogWithToggle.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.classpath;
-
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialogWithToggle;
-import org.eclipse.jface.layout.GridDataFactory;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.accessibility.AccessibleAdapter;
-import org.eclipse.swt.accessibility.AccessibleEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-
-/**
- * Customized warning dialog for JSF Library Upgrade warnings.
- *
- * @author cbateman
- * @deprecated
- */
-class WarningMessageDialogWithToggle extends MessageDialogWithToggle
-{
- private Text _messageLabel;
-
- /**
- * @param parent
- * @param title
- * @param message
- * @param toggleMessage
- * @param toggleState
- * @param store
- * @param key
- * @return the dialog.
- *
- * Overriden to make default button CANCEL and use this dialog
- */
- public static MessageDialogWithToggle openOkCancelConfirm(Shell parent,
- String title, String message, String toggleMessage,
- boolean toggleState, IPreferenceStore store, String key) {
- MessageDialogWithToggle dialog = new WarningMessageDialogWithToggle(parent,
- title, null, // accept the default window icon
- message, QUESTION, new String[] { IDialogConstants.OK_LABEL,
- IDialogConstants.CANCEL_LABEL }, 1, // CANCEL is the default
- toggleMessage, toggleState);
- dialog.open();
- return dialog;
- }
-
- WarningMessageDialogWithToggle(Shell parentShell, String dialogTitle,
- Image image, String message, int dialogImageType,
- String[] dialogButtonLabels, int defaultIndex,
- String toggleMessage, boolean toggleState) {
- super(parentShell, dialogTitle, image, message, dialogImageType,
- dialogButtonLabels, defaultIndex, toggleMessage, toggleState);
- }
-
- @Override
- protected Control createMessageArea(Composite composite)
- {
- // create composite
- // create image
- Image image = getImage();
- if (image != null) {
- imageLabel = new Label(composite, SWT.NULL);
- image.setBackground(imageLabel.getBackground());
- imageLabel.setImage(image);
- addAccessibleListeners(imageLabel, image);
- GridDataFactory.fillDefaults().align(SWT.CENTER, SWT.BEGINNING)
- .applyTo(imageLabel);
- }
- // create message
- if (message != null) {
- _messageLabel = new Text(composite, getMessageLabelStyle()|SWT.READ_ONLY);
- _messageLabel.setText(message);
- GridDataFactory
- .fillDefaults()
- .align(SWT.FILL, SWT.BEGINNING)
- .grab(true, false)
- .hint(
- convertHorizontalDLUsToPixels(IDialogConstants.MINIMUM_MESSAGE_AREA_WIDTH),
- SWT.DEFAULT).applyTo(_messageLabel);
- }
- return composite;
- }
-
- /**
- * NOTE: copied from IconAndMessageDialog
- * Add an accessible listener to the label if it can be inferred from the
- * image.
- *
- * @param label
- * @param image
- */
- private void addAccessibleListeners(Label label, final Image image) {
- label.getAccessible().addAccessibleListener(new AccessibleAdapter() {
- public void getName(AccessibleEvent event) {
- final String accessibleMessage = getAccessibleMessageFor(image);
- if (accessibleMessage == null) {
- return;
- }
- event.result = accessibleMessage;
- }
- });
- }
-
- /**
- * NOTE: copied from IconAndMessageDialog
- * @param image
- * @return an accesible string
- */
- private String getAccessibleMessageFor(Image image) {
- if (image.equals(getErrorImage())) {
- return JFaceResources.getString("error");//$NON-NLS-1$
- }
-
- if (image.equals(getWarningImage())) {
- return JFaceResources.getString("warning");//$NON-NLS-1$
- }
-
- if (image.equals(getInfoImage())) {
- return JFaceResources.getString("info");//$NON-NLS-1$
- }
-
- if (image.equals(getQuestionImage())) {
- return JFaceResources.getString("question"); //$NON-NLS-1$
- }
-
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/Messages.java
deleted file mode 100644
index 30e0e9eed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/Messages.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.common;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * @author cbateman
- *
- */
-public class Messages extends NLS
-{
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.common.messages"; //$NON-NLS-1$
- /**
- * see messages.properties
- */
- public static String ViewObjectPresenter_ComponentClass;
- /**
- * see messages.properties
- */
- public static String ViewObjectPresenter_ComponentFamily;
- /**
- * see messages.properties
- */
- public static String ViewObjectPresenter_ComponentType;
- /**
- * see messages.properties
- */
- public static String ViewObjectPresenter_RenderType;
- static
- {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-
- private Messages()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/MetadataTagImageManager.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/MetadataTagImageManager.java
deleted file mode 100644
index dd15ad5ef..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/MetadataTagImageManager.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.common;
-
-import java.util.Iterator;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.common.metadata.Entity;
-import org.eclipse.jst.jsf.common.metadata.Model;
-import org.eclipse.jst.jsf.common.metadata.Trait;
-import org.eclipse.jst.jsf.common.metadata.internal.IImageDescriptorProvider;
-import org.eclipse.jst.jsf.common.metadata.internal.IMetaDataSourceModelProvider;
-import org.eclipse.jst.jsf.common.metadata.internal.TraitValueHelper;
-import org.eclipse.jst.jsf.common.metadata.query.ITaglibDomainMetaDataModelContext;
-import org.eclipse.jst.jsf.common.metadata.query.TaglibDomainMetaDataQueryHelper;
-import org.eclipse.jst.jsf.tagdisplay.internal.paletteinfos.PaletteInfo;
-import org.eclipse.jst.jsf.tagdisplay.internal.paletteinfos.PaletteInfos;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.swt.graphics.Image;
-
-/**
- * @author cbateman
- *
- */
-public class MetadataTagImageManager
-{
- private static final String TRAIT_ICON_SMALL = "small-icon"; //$NON-NLS-1$
-
- private static final String TRAIT_ICON_LARGE = "large-icon"; //$NON-NLS-1$
-
- /**
- * @param project
- * @param tagId
- * @return small image using metadata. May be null.
- */
- public Image getSmallIconImage(final IProject project, final TagIdentifier tagId)
- {
- return getSmallIconImage(project, tagId.getUri(), tagId.getTagName());
- }
-
- /**
- * Returns small image using metadata and may be null. Caller should NOT
- * dispose the image, but should call TagImageManager's dispose(image)
- *
- * @param project
- * @param nsUri
- * @param tagName
- * @return small image using metadata. May be null.
- */
- public Image getSmallIconImage(final IProject project, final String nsUri,
- final String tagName)
- {
- Image image = null;
- final Model model = getModel(project, nsUri);
- if (model != null)
- {
- final ImageDescriptor imgDesc = getIconImageDescriptor(model,
- tagName, true);
- image = getOrCreateImage(imgDesc);
- }
-
- return image;
- }
-
- private Image getOrCreateImage(final ImageDescriptor imgDesc)
- {
- Image image = null;
- if (imgDesc != null)
- {
- image = JSFUiPlugin.getDefault().getImageRegistry().get(
- imgDesc.toString());
- if (image == null)
- {
- image = imgDesc.createImage();
- JSFUiPlugin.getDefault().getImageRegistry().put(
- imgDesc.toString(), image);
- }
- else if (image.isDisposed())
- { // should not occur, but handling just in case
- JSFUiPlugin.getDefault().getImageRegistry().remove(
- imgDesc.toString());
- image = imgDesc.createImage();
- JSFUiPlugin.getDefault().getImageRegistry().put(
- imgDesc.toString(), image);
- }
- }
- return image;
- }
-
- private Model getModel(final IProject project, final String nsUri)
- {
- final ITaglibDomainMetaDataModelContext modelContext = TaglibDomainMetaDataQueryHelper
- .createMetaDataModelContext(project, nsUri);
- final Model model = TaglibDomainMetaDataQueryHelper
- .getModel(modelContext);
- // no caching at this time so there is no need to listen to model
- // notifications
- // if (model != null && !hasAdapter(model))
- // addAdapter(model);
- return model;
- }
-
- private ImageDescriptor getIconImageDescriptor(final Model model,
- final String tagName, final boolean small)
- {
- ImageDescriptor icon = null;
-
- // use palette infos if available
- final Trait trait = TaglibDomainMetaDataQueryHelper.getTrait(model,
- "paletteInfos"); //$NON-NLS-1$
- if (trait != null)
- {
- final PaletteInfos tags = (PaletteInfos) trait.getValue();
- for (final Iterator it = tags.getInfos().iterator(); it.hasNext();)
- {
- final PaletteInfo tag = (PaletteInfo) it.next();
- if (tag.getId().equalsIgnoreCase(tagName))
- {
- final IMetaDataSourceModelProvider sourceProvider = ((Trait) tag
- .eContainer().eContainer())
- .getSourceModelProvider();
- if (small)
- {
- icon = getImageDescriptorFromString(sourceProvider, tag
- .getSmallIcon());
- }
- else
- {
- icon = getImageDescriptorFromString(sourceProvider, tag
- .getLargeIcon());
- }
-
- break;
- }
- }
- }
- else
- {
- for (final Iterator it = model.getChildEntities().iterator(); it
- .hasNext();)
- {
- final Entity tagAsEntity = (Entity) it.next();
- if (tagAsEntity.getId().equalsIgnoreCase(tagName))
- {
- if (small)
- {
- icon = getImageDescriptorFromTagTraitValueAsString(
- tagAsEntity, TRAIT_ICON_SMALL, ImageDescriptor
- .getMissingImageDescriptor());
- }
- else
- {
- icon = getImageDescriptorFromTagTraitValueAsString(
- tagAsEntity, TRAIT_ICON_LARGE, ImageDescriptor
- .getMissingImageDescriptor());
- }
-
- break;
- }
- }
-
- }
-
- return icon;
- }
-
- private ImageDescriptor getImageDescriptorFromString(
- IMetaDataSourceModelProvider sourceModelProvider, String imgDesc)
- {
- ImageDescriptor image = null;
- IImageDescriptorProvider imageProvider = (IImageDescriptorProvider) sourceModelProvider
- .getAdapter(IImageDescriptorProvider.class);
- if (imageProvider != null)
- {
- image = imageProvider.getImageDescriptor(imgDesc);
- }
- return image;
- }
-
- private ImageDescriptor getImageDescriptorFromTagTraitValueAsString(
- Entity entity, String key, ImageDescriptor defaultValue)
- {
- Trait t = TaglibDomainMetaDataQueryHelper.getTrait(entity, key);
- if (t != null)
- {
- String imgDesc = TraitValueHelper.getValueAsString(t);
- return getImageDescriptorFromString(t.getSourceModelProvider(),
- imgDesc);
- }
- return defaultValue;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/ViewObjectPresenter.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/ViewObjectPresenter.java
deleted file mode 100644
index 20734edba..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/ViewObjectPresenter.java
+++ /dev/null
@@ -1,244 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.common;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.IDesigntimeAdapter;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentTypeInfo;
-
-/**
- * Generates UI form text strings for certain view objects.
- *
- * @author cbateman
- *
- */
-public final class ViewObjectPresenter
-{
- /**
- * @param typeInfo
- * @return a presentation string containing all the summary information for
- * a typeInfo. Excludes interfaces and superclasses.
- */
- public static String present(final ComponentTypeInfo typeInfo)
- {
- final String formatText = "<form>%s</form>"; //$NON-NLS-1$
- final String componentType = typeInfo.getComponentType();
- final String componentFamily = typeInfo.getComponentFamily();
- final String renderType = typeInfo.getRenderFamily();
- final String componentClass = typeInfo.getClassName();
- final List<TitleValuePair> values = new ArrayList<TitleValuePair>();
-
- values.add(new TitleValuePair(Messages.ViewObjectPresenter_ComponentType,
- componentType == null ? "" : componentType)); //$NON-NLS-1$
- values.add(new TitleValuePair(Messages.ViewObjectPresenter_ComponentClass,
- componentClass == null ? "" : componentClass)); //$NON-NLS-1$
- values.add(new TitleValuePair(Messages.ViewObjectPresenter_ComponentFamily,
- componentFamily == null ? "" : componentFamily)); //$NON-NLS-1$
- values.add(new TitleValuePair(Messages.ViewObjectPresenter_RenderType,
- renderType == null ? "" : renderType)); //$NON-NLS-1$
- return String.format(formatText, ViewObjectPresenter.createLines(values));
- }
-
- /**
- * @param compInfo
- * @param typeInfo
- * @return a presentation string containing all the interfaces in compInfo
- * including adapters.
- */
- public static String presentCompInterfaces(final ComponentTypeInfo typeInfo, final ComponentInfo compInfo)
- {
- final Set<String> interfaces = new HashSet<String>();
-
- interfaces.addAll(Arrays.asList(typeInfo.getInterfaces()));
-
- if (compInfo != null)
- {
- for (final Map.Entry entry : (Set<Map.Entry>) compInfo.getAllAdapters()
- .entrySet())
- {
- final Object infObject = entry.getValue();
- if (infObject instanceof IDesigntimeAdapter)
- {
- interfaces.addAll(Arrays.asList(((IDesigntimeAdapter)infObject).getInterfaces()));
- }
- }
- }
- final List<String> sortedInterfaceNames = new ArrayList<String>(
- interfaces);
- Collections.sort(sortedInterfaceNames);
-
- String text = ""; //$NON-NLS-1$
- for (final String name : sortedInterfaceNames)
- {
- text += ViewObjectPresenter.createLine(null, name);
- }
- return String.format("<form>%s</form>", text); //$NON-NLS-1$
- }
-
- /**
- * @param values
- * @return a grouping of createLine style lines using the key/value pairs in
- * values for the title and value.
- */
- public static String createLines(final List<TitleValuePair> values)
- {
- String lines = ""; //$NON-NLS-1$
- for (final TitleValuePair valueEntry : values)
- {
- final String title = valueEntry.getTitle();
- final String value = valueEntry.getValue();
-
- lines += createLine(title, value);
- }
- return lines;
- }
-
- /**
- * @param title
- * may be null
- * @param value
- * @return a single paragraphed line containing value with title preceding
- * in bold if not null
- */
- public static String createLine(final String title, final String value)
- {
- if (title == null)
- {
- return String.format("<p>%s</p>", value); //$NON-NLS-1$
- }
- return String.format("<p><b>%s</b>: %s</p>", title, value); //$NON-NLS-1$
- }
-
- /**
- * A title/value pair. Title may be null. Comparable canonically based title
- * (ascending).
- *
- * @author cbateman
- *
- */
- public final static class TitleValuePair implements
- Comparable<TitleValuePair>
- {
- private final String _title;
- private final String _value;
-
- /**
- * @param title
- * @param value
- */
- public TitleValuePair(String title, String value)
- {
- super();
- if (value == null)
- {
- throw new IllegalArgumentException("Value must not be null"); //$NON-NLS-1$
- }
-
- _title = title;
- _value = value;
- }
-
- /**
- * @return the title
- */
- protected final String getTitle()
- {
- return _title;
- }
-
- /**
- * @return the value
- */
- protected final String getValue()
- {
- return _value;
- }
-
- public int compareTo(TitleValuePair other)
- {
- if (this == other)
- {
- return 0;
- }
-
- if (other == null)
- {
- return 1;
- }
-
- if (_title == null)
- {
- return other.getTitle() == null ? 0 : 1;
- }
- else if (other.getTitle() == null)
- {
- // _title is not null
- return 1;
- }
-
- return _title.compareTo(other.getTitle());
- }
-
- @Override
- public boolean equals(Object obj)
- {
- if (this == obj)
- {
- return true;
- }
-
- if (obj instanceof TitleValuePair)
- {
-
- final TitleValuePair other = (TitleValuePair) obj;
- final String otherValue = other.getValue();
-
- if (!otherValue.equals(_value))
- {
- return false;
- }
-
- final String otherTitle = other.getTitle();
- if (_title == null)
- {
- return otherTitle == null;
- }
- else if (otherTitle == null)
- {
- return _title == null;
- }
- return _title.equals(otherTitle);
- }
- return false;
- }
-
- @Override
- public int hashCode()
- {
- return getTitle().hashCode();
- }
-
-
- }
-
- private ViewObjectPresenter()
- {
- // no instantiation
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/messages.properties
deleted file mode 100644
index 6afee6828..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/common/messages.properties
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-ViewObjectPresenter_ComponentClass=Component Class
-ViewObjectPresenter_ComponentFamily=Component Family
-ViewObjectPresenter_ComponentType=Component Type
-ViewObjectPresenter_RenderType=Render Type
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentInstanceDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentInstanceDetailsForm.java
deleted file mode 100644
index 73818099d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentInstanceDetailsForm.java
+++ /dev/null
@@ -1,224 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jdt.core.Signature;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentTypeInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo.ComponentBeanProperty;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ComponentDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.FacetDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.jst.jsf.ui.internal.common.ViewObjectPresenter;
-import org.eclipse.jst.jsf.ui.internal.common.ViewObjectPresenter.TitleValuePair;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Detail section for a component instance.
- *
- * @author cbateman
- *
- */
-/* package */class ComponentInstanceDetailsForm extends
- AbstractXMLSectionsDetailsForm
-{
-
- private static final String COMPONENT_SECTION_KEY = "componentSection"; //$NON-NLS-1$
- private final static String COMPONENT_TYPE_SECTION_KEY = "componentTypeSection"; //$NON-NLS-1$
- private static final String COMPONENT_INTERFACES_KEY = "componentInterfacesSection"; //$NON-NLS-1$
- private static final String COMPONENT_DECORATORS_KEY = "componentDecorators"; //$NON-NLS-1$
- private static final String COMPONENT_PROPERTIES_KEY = "componentProperties"; //$NON-NLS-1$
- private final LabelProvider _labelProvider = new MyLabelProvider();
-
- private XMLTextSection _componentTypeSection;
- private XMLTextSection _componentSection;
- private XMLTextSection _componentInterfacesSection;
- private XMLTextSection _componentDecoratorsSection;
- private XMLTextSection _componentPropertiesSection;
-
- @Override
- protected void doUpdateSelection(final Object newSelection)
- {
- if (newSelection instanceof ComponentInfo)
- {
- final ComponentInfo compInfo = (ComponentInfo) newSelection;
- updateComponentSection(compInfo);
- updateComponentDecoratorsSection(compInfo);
- updateComponentPropertiesSection(compInfo);
- final ComponentTypeInfo typeInfo = compInfo.getComponentTypeInfo();
- if (typeInfo != null)
- {
- updateComponentTypeSection(typeInfo);
- updateComponentInterfacesSection(compInfo, typeInfo);
- }
- }
- }
-
- private void updateComponentSection(final ComponentInfo compInfo)
- {
- final String formatText = "<form>%s</form>"; //$NON-NLS-1$
- final String className = compInfo.getComponentTypeInfo().getClassName();
- final String id = compInfo.getId();
- final ComponentInfo parent = compInfo.getParent();
- final List<TitleValuePair> values = new ArrayList<TitleValuePair>();
- values.add(new TitleValuePair(Messages.ComponentInstanceDetailsForm_Name, className != null ? Signature
- .getSimpleName(className) : "")); //$NON-NLS-1$
- values.add(new TitleValuePair(Messages.ComponentInstanceDetailsForm_Id, id != null ? id : Messages.ComponentInstanceDetailsForm_None));
- values
- .add(new TitleValuePair(Messages.ComponentInstanceDetailsForm_ParentId, (parent != null && parent.getId() != null)
- ? parent.getId()
- : Messages.ComponentInstanceDetailsForm_None));
-
- _componentSection.setText(String
- .format(formatText, ViewObjectPresenter.createLines(values)), true, false);
- _componentSection.refresh();
- }
-
- private void updateComponentTypeSection(final ComponentTypeInfo typeInfo)
- {
- _componentTypeSection.setText(ViewObjectPresenter.present(typeInfo),
- true, false);
- _componentTypeSection.refresh();
- }
-
- private void updateComponentInterfacesSection(final ComponentInfo compInfo,
- final ComponentTypeInfo typeInfo)
- {
- _componentInterfacesSection.setText(ViewObjectPresenter
- .presentCompInterfaces(typeInfo, compInfo), true, false);
- _componentInterfacesSection.refresh();
- }
-
- private void updateComponentDecoratorsSection(final ComponentInfo compInfo)
- {
- List<TitleValuePair> decoratorLines = new ArrayList<TitleValuePair>();
- String text = ""; //$NON-NLS-1$
- for (final ComponentDecorator decorator : (List<ComponentDecorator>) compInfo
- .getAllDecorators())
- {
- String labelText = _labelProvider.getText(decorator);
-
- if (labelText != null)
- {
- //text += ViewObjectPresenter.createLine(null, labelText);
- decoratorLines.add(new TitleValuePair(null, labelText));
- }
- }
- Collections.sort(decoratorLines);
- text = ViewObjectPresenter.createLines(decoratorLines);
- _componentDecoratorsSection.setText(String.format("<form>%s</form>", //$NON-NLS-1$
- text), true, false);
- _componentDecoratorsSection.refresh();
-
- }
-
- private void updateComponentPropertiesSection(final ComponentInfo compInfo)
- {
- List<TitleValuePair> propertyLines = new ArrayList<TitleValuePair>();
- String text = ""; //$NON-NLS-1$
- Set<String> propNames = compInfo.getAttributeNames();
-
- for (final String propName : propNames)
- {
- final ComponentBeanProperty propValue = compInfo
- .getAttribute(propName);
- if (propValue != null)
- {
- Object value = propValue.getValue();
- if (value != null)
- {
- propertyLines.add(new TitleValuePair(propName, value.toString()));
- }
- }
- }
- Collections.sort(propertyLines);
- text = ViewObjectPresenter.createLines(propertyLines);
- _componentPropertiesSection.setText(String.format("<form>%s</form>", //$NON-NLS-1$
- text), true, false);
- _componentPropertiesSection.refresh();
-
- }
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(
- final Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _componentSection = new XMLTextSection(getToolkit(), parent,
- Messages.ComponentInstanceDetailsForm_InstanceInfo);
- sections.put(COMPONENT_SECTION_KEY, _componentSection);
-
- _componentTypeSection = new XMLTextSection(getToolkit(), parent,
- Messages.ComponentInstanceDetailsForm_TypeInstanceInfo);
- sections.put(COMPONENT_TYPE_SECTION_KEY, _componentTypeSection);
-
- _componentInterfacesSection = new XMLTextSection(getToolkit(), parent,
- Messages.ComponentInstanceDetailsForm_Interfaces);
- sections.put(COMPONENT_INTERFACES_KEY, _componentInterfacesSection);
-
- _componentDecoratorsSection = new XMLTextSection(getToolkit(), parent,
- Messages.ComponentInstanceDetailsForm_Decorators);
- sections.put(COMPONENT_DECORATORS_KEY, _componentDecoratorsSection);
-
- _componentPropertiesSection = new XMLTextSection(getToolkit(), parent,
- Messages.ComponentInstanceDetailsForm_Properties);
- sections.put(COMPONENT_PROPERTIES_KEY, _componentPropertiesSection);
-
- return sections;
- }
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- final Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_componentSection);
- }
-
- private static class MyLabelProvider extends LabelProvider
- {
- @Override
- public String getText(Object element)
- {
- if (element instanceof ComponentDecorator)
- {
- if (element instanceof ConverterDecorator)
- {
- final ConverterDecorator converter = (ConverterDecorator) element;
- return NLS.bind(Messages.ComponentInstanceDetailsForm_Converter, converter.getTypeInfo().getConverterId(), converter.getTypeInfo().getClassName());
- }
- else if (element instanceof ValidatorDecorator)
- {
- final ValidatorDecorator validator = (ValidatorDecorator) element;
- return NLS.bind(Messages.ComponentInstanceDetailsForm_Validator, validator.getTypeInfo().getValidatorId(), validator.getTypeInfo().getClassName());
- }
- else if (element instanceof FacetDecorator)
- {
- final FacetDecorator decorator = (FacetDecorator) element;
- return NLS.bind(Messages.ComponentInstanceDetailsForm_Facet, decorator.getName(), decorator.getDecorates().getId());
- }
- }
-
- return null;
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterDetailBlock.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterDetailBlock.java
deleted file mode 100644
index 4c846c883..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterDetailBlock.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractDetailsForm;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterDetailBlock;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterForm;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/*package*/ class ComponentMasterDetailBlock extends AbstractMasterDetailBlock
-{
- private final DTJSFViewModel _model;
- private AbstractXMLSectionsDetailsForm _componentInstanceDetailsForm;
-
- public ComponentMasterDetailBlock(final DTJSFViewModel model)
- {
- _model = model;
- }
-
- @Override
- protected List<AbstractDetailsForm> createDetailPages()
- {
- final List<AbstractDetailsForm> pages =
- new ArrayList<AbstractDetailsForm>();
-
- _componentInstanceDetailsForm = new ComponentInstanceDetailsForm();
- pages.add(_componentInstanceDetailsForm);
-
- return pages;
- }
-
- @Override
- protected AbstractMasterForm createMasterPart(final FormToolkit toolkit)
- {
- return new ComponentMasterForm(toolkit, _model);
- }
-
- @Override
- protected AbstractXMLSectionsDetailsForm doSelectPage(final Object forModel)
- {
- if (forModel instanceof ComponentInfo)
- {
- return _componentInstanceDetailsForm;
- }
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterForm.java
deleted file mode 100644
index 568edbab1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentMasterForm.java
+++ /dev/null
@@ -1,307 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.viewers.IInputProvider;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.common.dom.TagIdentifier;
-import org.eclipse.jst.jsf.common.runtime.internal.model.ViewObject;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterDecorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.Decorator;
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorDecorator;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterForm;
-import org.eclipse.jst.jsf.common.ui.internal.utils.JSFSharedImages;
-import org.eclipse.jst.jsf.designtime.internal.view.DTUIViewRoot;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewObjectMappingService;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewObjectMappingService.ElementData;
-import org.eclipse.jst.jsf.ui.internal.common.MetadataTagImageManager;
-import org.eclipse.jst.jsf.ui.internal.component.ComponentTreeViewProvider.TreePlaceHolder;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-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.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/*package*/class ComponentMasterForm extends AbstractMasterForm
-{
- private final DTJSFViewModel _model;
- private TreeViewer _treeViewer;
- private Action _refreshAction;
-
- protected ComponentMasterForm(final FormToolkit toolkit,
- final DTJSFViewModel model)
- {
- super(toolkit);
- _model = model;
- }
-
- @Override
- public Control createClientArea(final Composite parent)
- {
- final Tree tree = getToolkit().createTree(parent,
- SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
- final GridData gridData = new GridData(SWT.FILL, SWT.FILL, true, true);
- tree.setLayoutData(gridData);
-
- _treeViewer = new TreeViewer(tree);
- _treeViewer.getTree().setLayoutData(gridData);
- _treeViewer.setContentProvider(new ComponentTreeViewProvider());
- _treeViewer.setLabelProvider(new TreeViewLabelProvider(_treeViewer));
- _treeViewer.setSorter(new ComponentTreeSorter());
- _treeViewer.addSelectionChangedListener(new ISelectionChangedListener()
- {
- public void selectionChanged(final SelectionChangedEvent event)
- {
- getListener().selectionChanged(event);
- }
-
- });
-
- _model.init(new Runnable()
- {
- public void run()
- {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable()
- {
- public void run()
- {
- final Object[] expanded = _treeViewer
- .getExpandedElements();
- _treeViewer.refresh();
- _treeViewer.setExpandedElements(expanded);
- }
- });
- }
- });
-
- _treeViewer.setInput(_model);
-
- makeActions();
- return tree;
- }
-
- @Override
- protected void contributeActions(final IToolBarManager formManager,
- final IToolBarManager localManager)
- {
- // contribute to local tool bar
- localManager.add(_refreshAction);
- localManager.update(false);
- }
-
- private void makeActions()
- {
- _refreshAction = new Action()
- {
- @Override
- public void run()
- {
- _model.update();
- }
- };
- _refreshAction.setText(Messages.ComponentMasterForm_RefreshView);
- _refreshAction.setToolTipText(Messages.ComponentMasterForm_RefreshView);
- _refreshAction.setImageDescriptor(JSFUICommonPlugin.getDefault()
- .getImageDescriptor("refresh_nav_16.gif")); //$NON-NLS-1$
- }
-
- @Override
- protected void contributeToHeadArea(final FormToolkit toolkit,
- final Composite container)
- {
- final Text label = new Text(container
- , SWT.READ_ONLY | SWT.SINGLE | SWT.LEFT);
-
- String viewId = _model.getViewId();
- viewId = viewId == null ? Messages.ComponentMasterForm_Unknown : viewId;
- label.setText(NLS.bind(Messages.ComponentMasterForm_HeadAreaText, viewId,
- _model.getProject().getName()));
- }
-
- private static class TreeViewLabelProvider extends LabelProvider
- {
- private final IInputProvider _inputProvider;
- private final MetadataTagImageManager _metadataIconManager;
-
- /**
- * @param inputProvider
- */
- private TreeViewLabelProvider(final IInputProvider inputProvider)
- {
- super();
- _inputProvider = inputProvider;
- _metadataIconManager = new MetadataTagImageManager();
- }
-
- @Override
- public String getText(final Object obj)
- {
- if (obj instanceof ComponentInfo)
- {
- String text = ""; //$NON-NLS-1$
- final ComponentInfo compInfo = (ComponentInfo) obj;
- String className = compInfo.getComponentTypeInfo()
- .getClassName();
- final int dotIdx = className.lastIndexOf('.');
- if (dotIdx > -1 && dotIdx + 1 < className.length())
- {
- className = className.substring(dotIdx + 1);
- }
- text = className;
-
- final String id = compInfo.getId();
-
- if (id != null)
- {
- text += " (id=" + id + ")"; //$NON-NLS-1$ //$NON-NLS-2$
- }
- return text;
- }
- else if (obj instanceof TreePlaceHolder)
- {
- return Messages.ComponentMasterForm_CalculatingView;
- }
- return obj.toString();
- }
-
- @Override
- public Image getImage(final Object obj)
- {
- Image image = null;
- if (obj instanceof ViewObject)
- {
- final XMLViewObjectMappingService mappingService = getMappingService();
-
- if (mappingService != null)
- {
- final ElementData elementData = mappingService
- .findElementData((ViewObject) obj);
-
- if (elementData != null)
- {
- final TagIdentifier tagId = elementData.getTagId();
- final DTJSFViewModel model = getModel();
- if (model != null)
- {
- image = _metadataIconManager.getSmallIconImage(
- model.getProject(), tagId);
- }
- }
- }
- if (image == null)
- {
- image = getDefaultImage((ViewObject) obj);
- }
- }
- else if (obj instanceof TreePlaceHolder)
- {
- return JSFUICommonPlugin.getDefault().getImage("configs.gif"); //$NON-NLS-1$
- }
- if (image == null)
- {
- final String imageKey = ISharedImages.IMG_OBJ_ELEMENT;
- image = PlatformUI.getWorkbench().getSharedImages().getImage(
- imageKey);
- }
-
- return image;
- }
-
- private XMLViewObjectMappingService getMappingService()
- {
- final DTJSFViewModel model = getModel();
-
- if (model != null)
- {
- final DTUIViewRoot root = model.getRoot();
-
- if (root != null)
- {
- return (XMLViewObjectMappingService) root.getServices()
- .getAdapter(XMLViewObjectMappingService.class);
- }
- }
- return null;
- }
-
- private DTJSFViewModel getModel()
- {
- final Object input = _inputProvider.getInput();
-
- if (input instanceof DTJSFViewModel)
- {
- return (DTJSFViewModel) input;
- }
- return null;
- }
-
- private Image getDefaultImage(final ViewObject obj)
- {
- if (obj instanceof DTUIViewRoot)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_VIEWROOT_IMG);
- }
- if (obj instanceof ComponentInfo)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_OBJECT_IMG);
- }
- else if (obj instanceof ConverterDecorator)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_CONVERTER_IMG);
- }
- else if (obj instanceof ValidatorDecorator)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_VALIDATOR_IMG);
- }
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.DEFAULT_PALETTE_TAG_IMG);
- }
- }
-
- private static class ComponentTreeSorter extends ViewerSorter
- {
- @Override
- public int compare(final Viewer viewer, final Object e1, final Object e2)
- {
- return 0;
- }
-
- @Override
- public int category(final Object element)
- {
- // sort decorators first into their own category
- if (element instanceof Decorator)
- {
- return 0;
- }
- return 1;
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeView.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeView.java
deleted file mode 100644
index 9a146b442..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeView.java
+++ /dev/null
@@ -1,175 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.utils.JSFSharedImages;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.internal.ResolverUtil;
-import org.eclipse.jst.jsf.designtime.DesignTimeApplicationManager;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.forms.widgets.Form;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.part.IPage;
-import org.eclipse.ui.part.MessagePage;
-import org.eclipse.ui.part.Page;
-import org.eclipse.ui.part.PageBook;
-import org.eclipse.ui.part.PageBookView;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-
-/**
- * A basic page-based view, similar to outline, that shows the design-time
- * component tree for a JSF view definition.
- */
-
-public class ComponentTreeView extends PageBookView
-{
-
- private FormToolkit _toolkit;
-
- @Override
- public void init(IViewSite site) throws PartInitException
- {
- super.init(site);
- setTitleImage(JSFUICommonPlugin.getDefault().getImage(JSFSharedImages.GENERIC_VIEWROOT_IMG));
- }
-
- @Override
- protected IPage createDefaultPage(final PageBook book)
- {
- final MessagePage page = new MessagePage();
- initPage(page);
- page.createControl(book);
- page.setMessage(Messages.ComponentTreeView_NothingToDisplayMessage);
- return page;
- }
-
- @Override
- protected PageRec doCreatePage(final IWorkbenchPart part)
- {
- _toolkit = new FormToolkit(getPageBook().getDisplay());
- final ComponentPage page = new ComponentPage(getDocumentFromPart(part),
- _toolkit);
- initPage(page);
- page.createControl(getPageBook());
- return new PageRec(part, page);
- }
-
- @Override
- protected void doDestroyPage(final IWorkbenchPart part,
- final PageRec pageRecord)
- {
- pageRecord.page.dispose();
- pageRecord.dispose();
- }
-
- private IDocument getDocumentFromPart(final IWorkbenchPart part)
- {
- return (IDocument) part.getAdapter(IDocument.class);
- }
-
- /**
- * The view shows the palette associated with the active editor.
- *
- * @see PageBookView#getBootstrapPart()
- */
- @Override
- protected IWorkbenchPart getBootstrapPart()
- {
- final IWorkbenchPage page = getSite().getPage();
- if (page != null)
- {
- return page.getActiveEditor();
- }
- return null;
- }
-
- @Override
- protected boolean isImportant(final IWorkbenchPart part)
- {
- final IDocument document = getDocumentFromPart(part);
-
- if (document != null)
- {
- final IFile file = ResolverUtil.getFileForDocument(document);
-
- if (file != null)
- {
- final DesignTimeApplicationManager manager = DesignTimeApplicationManager
- .getInstance(file.getProject());
-
- if (manager != null)
- {
- return manager.hasDTFacesContext(file);
- }
- }
- }
-
- // fall through, then no, not important.
- return false;
- }
-
- private static class ComponentPage extends Page
- {
- private final IDocument _document;
- private final FormToolkit _toolkit;
- private ComponentMasterDetailBlock _masterDetailBlock;
- private Form _form;
- private DTJSFViewModel _model;
-
- public ComponentPage(final IDocument document, final FormToolkit toolkit)
- {
- _document = document;
- _toolkit = toolkit;
- }
-
- @Override
- public void createControl(final Composite parent)
- {
- _model = new DTJSFViewModel(
- (IStructuredDocument) _document);
-
- _form = _toolkit.createForm(parent);
- _form.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
- _masterDetailBlock = new ComponentMasterDetailBlock(_model);
- _masterDetailBlock.createContent(_toolkit, _form);
- }
-
- @Override
- public void dispose()
- {
- super.dispose();
- _model.dispose();
- }
-
- @Override
- public Control getControl()
- {
- return _form;
- }
-
- @Override
- public void setFocus()
- {
- // do nothing
- }
-
-
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeViewProvider.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeViewProvider.java
deleted file mode 100644
index c1bec1078..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/ComponentTreeViewProvider.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentInfo;
-import org.eclipse.jst.jsf.designtime.internal.view.DTUIViewRoot;
-
-/**
- * A tree view adapter for a design time component tree rooted at a design time
- * view root.
- *
- * @author cbateman
- *
- */
-/* package */class ComponentTreeViewProvider implements
- IStructuredContentProvider, ITreeContentProvider
-{
- private final static Object[] NO_CHILDREN = new Object[0];
-
- public Object[] getElements(final Object inputElement)
- {
- if (inputElement instanceof DTJSFViewModel)
- {
- final DTUIViewRoot root = ((DTJSFViewModel) inputElement).getRoot();
-
- if (root != null)
- {
- return new Object[]
- { root };
- }
- return new Object[] {new TreePlaceHolder()};
- }
- return NO_CHILDREN;
- }
-
- public void dispose()
- {
- // nothing to dispose
- }
-
- public void inputChanged(final Viewer viewer, final Object oldInput,
- final Object newInput)
- {
- // do nothing
- }
-
- public Object[] getChildren(final Object parentElement)
- {
- if (parentElement instanceof ComponentInfo)
- {
- final List<Object> children = new ArrayList<Object>();
- children.addAll(((ComponentInfo) parentElement).getChildren());
-// children.addAll(((ComponentInfo) parentElement).getAllDecorators());
- return children.toArray();
- }
- return NO_CHILDREN;
- }
-
- public Object getParent(final Object element)
- {
- if (element instanceof ComponentInfo)
- {
- return ((ComponentInfo)element).getParent();
- }
- // no parent
- return null;
- }
-
- public boolean hasChildren(final Object element)
- {
- return getChildren(element).length > 0;
- }
-
- static final class TreePlaceHolder
- {
- // place holder object used when recalculation is in progress
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/DTJSFViewModel.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/DTJSFViewModel.java
deleted file mode 100644
index a39d44598..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/DTJSFViewModel.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import java.util.concurrent.atomic.AtomicBoolean;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.IJobChangeEvent;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.core.runtime.jobs.JobChangeAdapter;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.IStructuredDocumentContextResolverFactory;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.IWorkspaceContextResolver;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.designtime.DTAppManagerUtil;
-import org.eclipse.jst.jsf.designtime.DesignTimeApplicationManager;
-import org.eclipse.jst.jsf.designtime.context.DTFacesContext;
-import org.eclipse.jst.jsf.designtime.internal.view.DTUIViewRoot;
-import org.eclipse.jst.jsf.designtime.internal.view.IDTViewHandler;
-import org.eclipse.jst.jsf.designtime.internal.view.IViewRootHandle;
-import org.eclipse.jst.jsf.designtime.internal.view.DTUIViewRoot.StalenessEvent;
-import org.eclipse.jst.jsf.designtime.internal.view.DTUIViewRoot.StalenessListener;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-
-/**
- * The top-level input model for a design time component tree
- *
- * @author cbateman
- *
- */
-/* package */class DTJSFViewModel
-{
- private final IStructuredDocument _document;
- private final IProject _project;
- private final IFile _file;
- private final IStructuredDocumentContext _context;
- private final AtomicBoolean _alreadyUpdating = new AtomicBoolean(
- false);
- private Runnable _runnable;
- private final IViewRootHandle _viewRootHandle;
- private StalenessListener _stalenessListener;
-
- /**
- * @param document
- * @throws IllegalArgumentException
- * if document cannot be used to initialize a component tree.
- */
- public DTJSFViewModel(final IStructuredDocument document)
- {
- _document = document;
- _context = IStructuredDocumentContextFactory.INSTANCE.getContext(
- _document, -1);
-
- final IWorkspaceContextResolver resolver = IStructuredDocumentContextResolverFactory.INSTANCE
- .getWorkspaceContextResolver(_context);
-
- if (resolver == null)
- {
- throw new IllegalArgumentException();
- }
-
- _project = resolver.getProject();
- _file = (IFile) resolver.getResource();
-
- if (_project == null || _file == null)
- {
- throw new IllegalArgumentException();
- }
-
- final DTFacesContext facesContext = getFacesContext();
- _viewRootHandle = facesContext.getViewRootHandle();
- }
-
- /**
- * Acquire and initialize the component tree root for the document
- *
- * @param runnable
- */
- public void init(final Runnable runnable)
- {
- _runnable = runnable;
- _viewRootHandle.addListener(getOrCreateListener());
- }
-
- public void dispose()
- {
- if (_stalenessListener != null)
- {
- _viewRootHandle.removeListener(_stalenessListener);
- }
-
- synchronized(this)
- {
- _runnable = null;
- }
- }
-
- /**
- * @return the structured document that this view model was created for.
- */
- public final IStructuredDocument getDocument()
- {
- return _document;
- }
-
- public final IProject getProject()
- {
- return _project;
- }
-
- public final String getViewId()
- {
- final DTFacesContext facesContext = getFacesContext();
- final IDTViewHandler viewHandler = DTAppManagerUtil
- .getViewHandler(_project);
- if (facesContext != null && viewHandler != null)
- {
- return viewHandler.getViewId(facesContext, _file);
- }
- return null;
- }
-
- private DTFacesContext getFacesContext()
- {
- final DesignTimeApplicationManager manager = DesignTimeApplicationManager
- .getInstance(_project);
-
- if (manager != null)
- {
- return manager.getFacesContext(_file);
- }
- return null;
- }
-
- public void update()
- {
- final DTFacesContext facesContext = getFacesContext();
-
- if (facesContext != null)
- {
- // latch the alreadyRunning flag; job will unset to false
- if (_alreadyUpdating.compareAndSet(false, true))
- {
- final Job job = new UpdateRootAndRefreshJob(_viewRootHandle);
-
- job.addJobChangeListener(new JobChangeAdapter()
- {
- @Override
- public void done(final IJobChangeEvent event)
- {
- // always reset the updating flag
- _alreadyUpdating.set(false);
- if (event.getResult().isOK())
- {
- synchronized(DTJSFViewModel.this)
- {
- if (_runnable != null)
- {
- _runnable.run();
- }
- }
- }
- }
- });
-
- job.schedule();
- }
- }
- }
-
- /**
- * @return the design time view root or null
- */
- public DTUIViewRoot getRoot()
- {
- final DTFacesContext facesContext = getFacesContext();
-
- if (facesContext != null)
- {
- final DTUIViewRoot viewRoot = _viewRootHandle.getCachedViewRoot();
-
- // if our copy is uninit or null, kick off an update
- if (viewRoot == null || viewRoot.isStale())
- {
- update();
- }
-
- return viewRoot;
- }
- return null;
- }
-
- private StalenessListener getOrCreateListener()
- {
- if (_stalenessListener == null)
- {
- _stalenessListener = new StalenessListener()
- {
- @Override
- protected void stalenessChanged(StalenessEvent event)
- {
- switch (event.getChangeType())
- {
- case VIEW_DEFN_CHANGED:
- case PROJECT_CLEANED:
- {
- update();
- }
- case VIEW_DEFN_DELETED:
- case VIEW_DEFN_PROJECT_CLOSED:
- {
- DTUIViewRoot root = _viewRootHandle
- .getCachedViewRoot();
- if (root != null)
- {
- root.removeListener(_stalenessListener);
- }
- }
- }
- }
- };
- }
- return _stalenessListener;
- }
-
- private static class UpdateRootAndRefreshJob extends Job
- {
- private final IViewRootHandle _viewRootHandle;
-
- public UpdateRootAndRefreshJob(final IViewRootHandle viewRootHandle)
- {
- super(Messages.DTJSFViewModel_JobDesc);
- _viewRootHandle = viewRootHandle;
- }
-
- @Override
- protected IStatus run(final IProgressMonitor monitor)
- {
- _viewRootHandle.updateViewRoot();
- return Status.OK_STATUS;
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/Messages.java
deleted file mode 100644
index e85ee630b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/Messages.java
+++ /dev/null
@@ -1,134 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.component;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler
- *
- */
-public class Messages extends NLS {
-
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.component.messages"; //$NON-NLS-1$
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_ComponentClass;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_ComponentFamily;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_ComponentType;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Decorators;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Id;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_InstanceInfo;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Interfaces;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Name;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_None;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_ParentId;
-
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Properties;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_RenderType;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_TypeInstanceInfo;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Converter;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Validator;
- /**
- * see messages.properties
- */
- public static String ComponentInstanceDetailsForm_Facet;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_CalculatingView;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_RefreshView;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_TreePlaceHolderText;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_Unknown;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_UnknownViewIdString;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_View;
- /**
- * see messages.properties
- */
- public static String ComponentMasterForm_HeadAreaText;
- /**
- * see messages.properties
- */
- public static String ComponentTreeView_NothingToDisplayMessage;
- /**
- * see messages.properties
- */
- public static String DTJSFViewModel_JobDesc;
-
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/messages.properties
deleted file mode 100644
index 0ca929f44..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/component/messages.properties
+++ /dev/null
@@ -1,25 +0,0 @@
-ComponentInstanceDetailsForm_ComponentClass=Component Class:
-ComponentInstanceDetailsForm_ComponentFamily=Component Family:
-ComponentInstanceDetailsForm_ComponentType=Component Type:
-ComponentInstanceDetailsForm_Decorators=Decorators
-ComponentInstanceDetailsForm_Id=Id
-ComponentInstanceDetailsForm_InstanceInfo=Instance Info
-ComponentInstanceDetailsForm_Interfaces=Interfaces
-ComponentInstanceDetailsForm_Name=Name
-ComponentInstanceDetailsForm_None=<i>none</i>
-ComponentInstanceDetailsForm_ParentId=Parent Id
-ComponentInstanceDetailsForm_Properties=Properties
-ComponentInstanceDetailsForm_RenderType=Render Type:
-ComponentInstanceDetailsForm_TypeInstanceInfo=Type Info Information
-ComponentMasterForm_CalculatingView=Calculating view...
-ComponentMasterForm_RefreshView=Refresh View
-ComponentMasterForm_TreePlaceHolderText=Calculating view...
-ComponentMasterForm_Unknown=<unknown>
-ComponentMasterForm_UnknownViewIdString=<unknown>
-ComponentMasterForm_View=View:
-ComponentTreeView_NothingToDisplayMessage=Nothing to display
-DTJSFViewModel_JobDesc=Updating view root
-ComponentInstanceDetailsForm_Converter=Converter: id=''{0}'', converter-class=''{1}''
-ComponentInstanceDetailsForm_Validator=Validator: id=''{0}'', validator-class=''{1}''
-ComponentInstanceDetailsForm_Facet=Facet: ''{0}'', component=''{1}''
-ComponentMasterForm_HeadAreaText=View: {0} (Project: {1})
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/JSFContentAssistProcessor.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/JSFContentAssistProcessor.java
deleted file mode 100644
index a786371a1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/JSFContentAssistProcessor.java
+++ /dev/null
@@ -1,296 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Gerry Kessler/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.contentassist;
-
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.IDOMContextResolver;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.IStructuredDocumentContextResolverFactory;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.ITaglibContextResolver;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.internal.IStructuredDocumentContextResolverFactory2;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.internal.ITextRegionContextResolver;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.metadataprocessors.MetaDataEnabledProcessingFactory;
-import org.eclipse.jst.jsf.metadataprocessors.features.IPossibleValue;
-import org.eclipse.jst.jsf.metadataprocessors.features.IPossibleValues;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.wst.sse.ui.internal.contentassist.CustomCompletionProposal;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMAttributeDeclaration;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMElementDeclaration;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMNamedNodeMap;
-import org.eclipse.wst.xml.core.internal.contentmodel.modelquery.ModelQuery;
-import org.eclipse.wst.xml.core.internal.modelquery.ModelQueryUtil;
-import org.eclipse.wst.xml.core.internal.regions.DOMRegionContext;
-import org.eclipse.wst.xml.ui.internal.contentassist.XMLRelevanceConstants;
-import org.eclipse.wst.xml.ui.internal.taginfo.MarkupTagInfoProvider;
-import org.osgi.framework.Bundle;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * The content assist processor for non-EL attribute values.
- *
- * @author Gerry Kessler - Oracle
- *
- */
-public class JSFContentAssistProcessor implements IContentAssistProcessor {
- private ITextRegionContextResolver resolver;
- private ITaglibContextResolver tlResolver;
- private String defaultAdditionalInfo;
-
- private String defaultIconPath = "/icons/attr_val.gif"; //$NON-NLS-1$
-
- private ImageDescriptor defaultAttrValImgDesc;
-
- private MarkupTagInfoProvider fInfoProvider;
-
- /**
- * @see org.eclipse.jface.text.contentassist.IContentAssistProcessor#computeCompletionProposals(org.eclipse.jface.text.ITextViewer,
- * int)
- */
- public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer,
- int documentPosition) {
- List proposals = new ArrayList();
- IStructuredDocumentContext context = IStructuredDocumentContextFactory.INSTANCE
- .getContext(viewer, documentPosition);
-
- if (context != null) {
- resolver = IStructuredDocumentContextResolverFactory.INSTANCE
- .getTextRegionResolver(context);
-
- if (resolver != null) {
- final String regionType = resolver.getRegionType();
-
- if (regionType != null
- && regionType.equals(DOMRegionContext.XML_TAG_ATTRIBUTE_VALUE)) {
-
- tlResolver = IStructuredDocumentContextResolverFactory2.INSTANCE
- .getTaglibContextResolverFromDelegates(context);
-
- if (tlResolver != null) {
-
- Attr attr = getAttribute(context);
- if (attr != null) {
- Node tagElement = attr.getOwnerElement();
- if (tagElement != null) {
- String uri = tlResolver.getTagURIForNodeName(tagElement);
- if (uri != null) {
- proposals = createProposals(context, uri, tagElement, attr);
- }
- }
- }
- }
- }
- }
- }
-
- return (ICompletionProposal[]) proposals
- .toArray(new ICompletionProposal[0]);
- }
-
- private String getDefaultAdditionalInfo(Node tagElement, Attr attr) {
- if (defaultAdditionalInfo == null){
- CMElementDeclaration elementNode = getCMElementDeclaration(tagElement);
- if (elementNode != null){
- CMAttributeDeclaration attrNode = getCMAttributeDeclaration(elementNode, attr);
- if (attrNode != null)
- defaultAdditionalInfo = getInfoProvider().getInfo(attrNode);
- }
- }
- return defaultAdditionalInfo;
- }
-
- private CMElementDeclaration getCMElementDeclaration(Node node) {
- CMElementDeclaration result = null;
- if (node.getNodeType() == Node.ELEMENT_NODE) {
- ModelQuery modelQuery = ModelQueryUtil.getModelQuery(node.getOwnerDocument());
- if (modelQuery != null)
- result = modelQuery.getCMElementDeclaration((Element) node);
- }
- return result;
- }
-
- private CMAttributeDeclaration getCMAttributeDeclaration(CMElementDeclaration tagElement, Attr attr) {
- CMNamedNodeMap attrs = tagElement.getAttributes();
- for (Iterator it = attrs.iterator();it.hasNext();){
- CMAttributeDeclaration CMAttr = (CMAttributeDeclaration)it.next();
- if (CMAttr.getAttrName().equals(attr.getName()))
- return CMAttr;
- }
- return null;
- }
-
- private MarkupTagInfoProvider getInfoProvider() {
- if (fInfoProvider == null) {
- fInfoProvider = new MarkupTagInfoProvider();
- }
- return fInfoProvider;
- }
-
- private List createProposals(IStructuredDocumentContext context, String uri, Node tagElement, Attr attr) {
- List ret = new ArrayList();
- List processors = MetaDataEnabledProcessingFactory.getInstance()
- .getAttributeValueRuntimeTypeFeatureProcessors(
- IPossibleValues.class, context, uri,
- tagElement.getLocalName(), attr.getLocalName());
-
- if (processors != null) {
- for (int i = 0; i < processors.size(); i++) {
- IPossibleValues p = (IPossibleValues) processors.get(i);
- ret.addAll(createProposals(p, tagElement, attr));
- }
- }
- return ret;
- }
-
- private List createProposals(IPossibleValues p, Node tagElement, Attr attr) {
- List ret = new ArrayList();
- defaultAdditionalInfo = null;
- Iterator it = p.getPossibleValues().iterator();
- while (it.hasNext()) {
- IPossibleValue val = (IPossibleValue) it.next();
- if (val != null){ //just in case...
- ICompletionProposal proposal = new CustomCompletionProposal(
- val.getValue(), //replacement text
- getReplacementOffset(), //replacementOffset
- getReplacementLength(), //replacementLength
- getCursorPosition(val), //cursor pos
- getImage(val), //image
- val.getDisplayValue(), //display value
- null, //IContextInformation
- getAdditionalInfo(val,tagElement,attr), //addditional info
- XMLRelevanceConstants.R_JSP_ATTRIBUTE_VALUE, //relevance
- true); //updateReplace
-
- ret.add(proposal);
- }
- }
- return ret;
- }
-
-
- private String getAdditionalInfo(IPossibleValue val, Node tagElement, Attr attr) {
- if (val.getAdditionalInformation() != null)
- return val.getAdditionalInformation();
-
- return getDefaultAdditionalInfo(tagElement, attr);
- }
-
- private int getReplacementLength() {
- return resolver.getRegionText().length() - 2;
- }
-
- private int getCursorPosition(IPossibleValue val) {
- //Something changed in 1.5RC2 CustomCompletionProposal
- //it appears that the cursor position is now relative to where it is currently
- //rather than relative to document
-
- //return getReplacementOffset() + val.getValue().length();
- return val.getValue().length();
- }
-
- private int getReplacementOffset() {
- return resolver.getStartOffset() + 1;
- }
-
- private Image getImage(IPossibleValue val) {
- ImageDescriptor icon = val.getIcon();
- if (icon == null || icon.equals("")){ //$NON-NLS-1$
- return getDefaultAttributeValueImage();
- }
-
- return getOrCreateImage(icon);
- }
-
- private Image getOrCreateImage(ImageDescriptor icon) {
- if (icon == null)
- return null;
-
- Image img = JSFUiPlugin.getDefault().getImageRegistry().get(icon.toString());
- if (img == null){
- try {
- img = icon.createImage();
- JSFUiPlugin.getDefault().getImageRegistry().put(icon.toString(), img);
- } catch (RuntimeException e) {
- // empty block; C.B: handle exception?
- }
- }
- return img;
- }
-
- private Image getDefaultAttributeValueImage() {
- if (defaultAttrValImgDesc == null){
- Bundle bundle = Platform.getBundle(JSFUiPlugin.PLUGIN_ID);
- URL url= FileLocator.find(bundle,new Path(defaultIconPath ), null);
- defaultAttrValImgDesc = ImageDescriptor.createFromURL(url);
- }
- return getOrCreateImage(defaultAttrValImgDesc);
- }
-
- private Attr getAttribute(IStructuredDocumentContext context) {
- final IDOMContextResolver domResolver = IStructuredDocumentContextResolverFactory.INSTANCE
- .getDOMContextResolver(context);
-
- if (domResolver != null) {
- final Node curNode = domResolver.getNode();
-
- if (curNode instanceof Attr) {
- return (Attr) curNode;
- }
- }
- return null;
-
- }
-
- public IContextInformation[] computeContextInformation(ITextViewer viewer,
- int offset) {
- // no context info
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters() {
- // auto activate when user hits a '.'
- return new char[] { '.' };
- }
-
- public char[] getContextInformationAutoActivationCharacters() {
- // no auto-activation for context info
- return null;
- }
-
- public String getErrorMessage() {
- // don't flag errors
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator() {
- // don't validate context information
- return null;
- }
-
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/el/JSFELContentAssistProcessor.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/el/JSFELContentAssistProcessor.java
deleted file mode 100644
index e99cb228c..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/contentassist/el/JSFELContentAssistProcessor.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Cameron Bateman/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.contentassist.el;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.contentassist.ICompletionProposal;
-import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.jface.text.contentassist.IContextInformation;
-import org.eclipse.jface.text.contentassist.IContextInformationValidator;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.ContentAssistParser;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.ContentAssistStrategy;
-import org.eclipse.jst.jsf.designtime.DTAppManagerUtil;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewDefnAdapter;
-import org.eclipse.jst.jsf.designtime.internal.view.IDTViewHandler.ViewHandlerException;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewDefnAdapter.DTELExpression;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.wst.xml.ui.internal.contentassist.ProposalComparator;
-
-/**
- * The content assist processor for JSF EL partitions on attribute values.
- *
- * @author cbateman
- *
- */
-public class JSFELContentAssistProcessor implements IContentAssistProcessor
-{
- /**
- * @see org.eclipse.jface.text.contentassist.IContentAssistProcessor#computeCompletionProposals(org.eclipse.jface.text.ITextViewer,
- * int)
- */
- public ICompletionProposal[] computeCompletionProposals(
- final ITextViewer viewer, final int documentPosition)
- {
- final List<ICompletionProposal> proposals =
- new ArrayList<ICompletionProposal>();
- final IStructuredDocumentContext context =
- IStructuredDocumentContextFactory.INSTANCE.getContext(viewer,
- documentPosition);
- if (context != null)
- {
- final XMLViewDefnAdapter viewAdapter =
- DTAppManagerUtil.getXMLViewDefnAdapter(context);
-
- if (viewAdapter != null)
- {
- try
- {
- final DTELExpression elExpression =
- viewAdapter.getELExpression(context);
-
- if (elExpression != null)
- {
- final ContentAssistStrategy strategy =
- ContentAssistParser.getPrefix(documentPosition
- - elExpression.getDocumentContext()
- .getDocumentPosition() + 1,
- elExpression.getText().trim());
-
- if (strategy != null)
- {
- proposals.addAll(strategy.getProposals(context));
- }
- Collections.sort(proposals, new ProposalComparator());
- }
- }
- catch (ViewHandlerException e)
- {
- JSFUiPlugin.log(IStatus.ERROR, "During el resolution", e); //$NON-NLS-1$
- }
- }
- }
-
- return proposals.toArray(new ICompletionProposal[0]);
- }
-
- public IContextInformation[] computeContextInformation(
- final ITextViewer viewer, final int offset)
- {
- // no context info
- return null;
- }
-
- public char[] getCompletionProposalAutoActivationCharacters()
- {
- // auto activate when user hits a '.'
- return new char[]
- { '.' };
- }
-
- public char[] getContextInformationAutoActivationCharacters()
- {
- // no auto-activation for context info
- return null;
- }
-
- public String getErrorMessage()
- {
- // don't flag errors
- return null;
- }
-
- public IContextInformationValidator getContextInformationValidator()
- {
- // don't validate context information
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/IJSFImplLibraryCreationListener.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/IJSFImplLibraryCreationListener.java
deleted file mode 100644
index d579d520d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/IJSFImplLibraryCreationListener.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Justin Chen - development check in
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;
-
-/**
- * Listener interface when a new JSF implementation library is created.
- *
- * @author Justin Chen - Oracle
- * @deprecated
- */
-public interface IJSFImplLibraryCreationListener extends java.util.EventListener {
- /**
- * Ok button is pressed in JSF Library dialog.
- *
- * @param event
- */
- public void okClicked(JSFImplLibraryCreationEvent event);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFImplLibraryCreationEvent.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFImplLibraryCreationEvent.java
deleted file mode 100644
index 524e4591b..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFImplLibraryCreationEvent.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Justin Chen - development check in
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;
-
-import java.util.EventObject;
-
-/**
- * JSF Implementation library creation event.
- *
- * @author Justin Chen - Oracle
- * @deprecated
- */
-public class JSFImplLibraryCreationEvent extends EventObject {
-
- private static final long serialVersionUID = 6390319185522362453L;
- private boolean isLibCreated;
-
- /**
- * @param source
- * @param okClicked
- */
- public JSFImplLibraryCreationEvent(Object source, boolean okClicked) {
- super(source);
- this.isLibCreated = okClicked;
- }
-
- /**
- * Ok button pressed.
- *
- * @return boolean
- */
- public boolean isLibraryCreated() {
- return isLibCreated;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControl.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControl.java
deleted file mode 100644
index b3bd76746..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControl.java
+++ /dev/null
@@ -1,690 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2007 Oracle Corporation.
- * 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:
- * Justin Chen
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.EventObject;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import java.util.Vector;
-
-import org.eclipse.core.runtime.ISafeRunnable;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.util.SafeRunnable;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTableViewer;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ILabelProviderListener;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigDialogSettingData;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigModel;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryInternalReference;
-import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.ArchiveFile;
-import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary;
-import org.eclipse.jst.jsf.core.internal.project.facet.IJSFFacetInstallDataModelProperties;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.jst.jsf.ui.internal.classpath.JSFLibraryWizard;
-import org.eclipse.swt.SWT;
-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.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.wst.common.frameworks.datamodel.IDataModel;
-import org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelSynchHelper;
-
-/**
- * A custom control used in wizard and property pages.
- *
- * @author Justin Chen
- * @deprecated
- */
-public class JSFLibraryConfigControl extends Composite {
-
- final static private int COLUMN_DEPLOY = 0;
- final static private int COLUMN_LIB_NAME = 1;
-
- private JSFLibraryConfigModel workingCopyModel = null;
-
- private CheckboxTableViewer ctvSelCompLib;
- private TreeViewer tvCompLib;
- private TreeViewerAdapter tvAdapter;
- private TreeLabelProvider tvLabelProvider;
- private Button btnAddAll;
- private Button btnRemoveAll;
-
- private Vector newJSFLibCreatedListeners = new Vector();
- private Set _changeListeners;
- private boolean _initing;
- private IDataModel model;
-
- /**
- * @param listener
- */
- public void addOkClickedListener(IJSFImplLibraryCreationListener listener) {
- newJSFLibCreatedListeners.addElement(listener);
- }
- /**
- * @param listener
- */
- public void removeOkClickedListener(IJSFImplLibraryCreationListener listener) {
- newJSFLibCreatedListeners.removeElement(listener);
- }
-
- /**
- * @param listener
- */
- public void addChangeListener(JSFLibraryConfigControlChangeListener listener){
- getChangeListeners().add(listener);
- }
-
- /**
- * @param listener
- */
- public void removeChangeListener(JSFLibraryConfigControlChangeListener listener){
- if (getChangeListeners().contains(listener))
- getChangeListeners().remove(listener);
- }
-
- private Set getChangeListeners() {
- if (_changeListeners == null){
- _changeListeners = new HashSet();
- }
- return _changeListeners;
- }
-
- private void fireChangedEvent(final EventObject e){
- if (_initing) return;
- SafeRunnable.run(new ISafeRunnable(){
- public void handleException(Throwable exception) {
- // TODO: should we perhaps do something here?
- JSFUiPlugin.log(IStatus.ERROR, exception.getLocalizedMessage());
- }
- public void run() throws Exception {
- for (Iterator it=getChangeListeners().iterator();it.hasNext();){
- ((JSFLibraryConfigControlChangeListener)it.next()).changed(new JSFLibraryConfigControlChangeEvent(e));
- }
- }
- });
- }
-
- /**
- * Create the composite
- * @param parent
- * @param style
- */
- public JSFLibraryConfigControl(Composite parent, int style) {
- super(parent, style);
- _initing = true;
- createControls();
- }
-
- /**
- * set control values from provided model.
- *
- * @param source
- */
- public void loadControlValuesFromModel(JSFLibraryConfigDialogSettingData source) {
- if (source != null) {
- // never read persistentModel = source;
- workingCopyModel = JSFLibraryConfigModel.JSFLibraryConfigModelFactory.createInstance(source);
- initializeControlValues();
- _initing = false;
- } else {
- JSFUiPlugin.log(IStatus.ERROR, Messages.JSFLibraryConfigControl_NullProject);
- }
-
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.swt.widgets.Widget#dispose()
- */
- public void dispose() {
- super.dispose();
- }
-
- /**
- * Return a list of selected JSF Component Libraries.
- * Otherwise, return an empty list.
- *
- * @return a list of selected JSF Component Libraries
- */
- public List getSelectedJSFLibComponents() {
- return workingCopyModel.getCurrentJSFComponentLibrarySelection();
- }
-
- /**
- *
- * @return JSFLibraryConfigModelAdapter
- */
- public JSFLibraryConfigModel getWorkingModel() {
- return workingCopyModel;
- }
-
- private void initializeControlValues() {
- loadJSFCompList();
-
- JSFLibraryInternalReference savedCompLib = null;
- JSFLibraryInternalReference selected = null;
- //Iterator it = persistentModel.getJSFComponentLibraries().iterator();
- Iterator it = workingCopyModel.getJSFComponentLibraries().iterator();
- while (it.hasNext()) {
- savedCompLib = (JSFLibraryInternalReference) it.next();
- selected = JSFLibraryRegistryUtil.getInstance().getJSFLibraryReferencebyID(savedCompLib.getID());
- if (selected != null) {
- ctvSelCompLib.setChecked(selected, selected.isCheckedToBeDeployed());
- }
- }
-
- setCompListModelProperty();
-
- redraw();
- }
-
- private void loadJSFCompList() {
- tvCompLib.setInput(workingCopyModel.getJSFComponentLibraries());
- ctvSelCompLib.setInput(workingCopyModel.getJSFComponentLibraries());
- }
-
- private void createCompLibControls(Composite parent) {
- final Composite cmpCompLibs = new Composite(parent, SWT.NONE);
- final GridLayout gridLayoutCompLibs = new GridLayout();
- gridLayoutCompLibs.numColumns = 4;
- gridLayoutCompLibs.marginWidth = 0;
- gridLayoutCompLibs.marginHeight = 0;
- cmpCompLibs.setLayout(gridLayoutCompLibs);
- GridData gdComp = new GridData();
- gdComp.horizontalAlignment = SWT.FILL;
- gdComp.grabExcessHorizontalSpace = true;
- cmpCompLibs.setLayoutData(gdComp);
-
- tvCompLib = new TreeViewer(cmpCompLibs, SWT.BORDER | SWT.H_SCROLL | SWT.V_SCROLL);
- tvAdapter = new TreeViewerAdapter();
- tvLabelProvider = new TreeLabelProvider();
- tvCompLib.setContentProvider(tvAdapter);
- tvCompLib.setLabelProvider(tvLabelProvider);
- tvCompLib.addDoubleClickListener(new IDoubleClickListener(){
- public void doubleClick(DoubleClickEvent event) {
- resetComponentLibSelection((StructuredSelection)event.getSelection(),
- tvCompLib,
- ctvSelCompLib,
- true);
- fireChangedEvent(event);
- }
- });
- tvCompLib.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
- tvCompLib.addFilter(new TreeViewerFilter());
-
- final Composite composite_buttons = new Composite(cmpCompLibs, SWT.NONE);
- composite_buttons.setLayoutData(new GridData(SWT.FILL, SWT.FILL, false, false));
- composite_buttons.setLayout(new GridLayout());
-
- final Composite composite_Single = new Composite(composite_buttons, SWT.None);
- composite_Single.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- final GridLayout gl_Single = new GridLayout();
- gl_Single.marginHeight = 4;
- composite_Single.setLayout(new GridLayout());
-
- final Button btnAdd = new Button(composite_Single, SWT.NONE);
- btnAdd.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false));
- btnAdd.setText(Messages.JSFLibraryConfigControl_Add);
- btnAdd.setEnabled(false);
-
- final Button btnRemove = new Button(composite_Single, SWT.NONE);
- btnRemove.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false));
- btnRemove.setText(Messages.JSFLibraryConfigControl_Remove);
- btnRemove.setEnabled(false);
-
- final Composite composite_All = new Composite(composite_buttons, SWT.None);
- composite_All.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- final GridLayout gl_All = new GridLayout();
- gl_Single.marginHeight = 4;
- composite_All.setLayout(gl_All);
-
- btnAddAll = new Button(composite_All, SWT.NONE);
- btnAddAll.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false));
- btnAddAll.setText(Messages.JSFLibraryConfigControl_AddAll);
-
- btnRemoveAll = new Button(composite_All, SWT.NONE);
- btnRemoveAll.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false));
- btnRemoveAll.setText(Messages.JSFLibraryConfigControl_RemoveAll);
-
- final Composite composite_New = new Composite(composite_buttons, SWT.None);
- composite_New.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- final GridLayout gl_New = new GridLayout();
- gl_Single.marginHeight = 4;
- composite_New.setLayout(gl_New);
-
- final Button btnNewCompLib = new Button(composite_New, SWT.NONE);
- btnNewCompLib.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, false, false));
- btnNewCompLib.setText(Messages.JSFLibraryConfigControl_NewComponentLibrary);
- btnNewCompLib.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- JSFLibraryWizard wizard = new JSFLibraryWizard();
- IWorkbench wb = PlatformUI.getWorkbench();
- wizard.init(wb, null);
- WizardDialog dialog = new WizardDialog(wb
- .getActiveWorkbenchWindow().getShell(), wizard);
- int ret = dialog.open();
- if (ret == Window.OK) {
- JSFLibraryInternalReference lib = new JSFLibraryInternalReference(
- wizard.getJSFLibrary(),
- true,
- true);
- JSFLibraryRegistryUtil.getInstance().addJSFLibrary(lib);
- workingCopyModel.getJSFComponentLibraries().add(lib);
-
- loadJSFCompList();
- setCompListModelProperty();
- ctvSelCompLib.setChecked(lib, true);
- }
- }
- });
-
- ctvSelCompLib = CheckboxTableViewer.newCheckList(cmpCompLibs, SWT.MULTI | SWT.FULL_SELECTION | SWT.BORDER);
- ctvSelCompLib.addFilter(new CheckedTableViewerFilter());
- final Table table = ctvSelCompLib.getTable();
- table.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, true));
- table.setHeaderVisible(true);
- final TableColumn tcDeploy = new TableColumn(table, SWT.LEFT);
- tcDeploy.setWidth(50);
- tcDeploy.setText(Messages.JSFLibraryConfigControl_TH_Deploy);
- tcDeploy.setToolTipText(Messages.JSFLibraryConfigControl_DeployJAR);
- final TableColumn tcLibName = new TableColumn(table, SWT.LEFT);
- tcLibName.setWidth(150);
- tcLibName.setText(Messages.JSFLibraryConfigControl_TH_LibraryName);
-
- //ctvSelCompLib.setCellModifier(new CellModifierCTVSelCompLib());
- ctvSelCompLib.setSorter(new SelectedCompLibCTVSorter());
- ctvSelCompLib.setLabelProvider(new SelectedCompLibCTVLabelProvider());
- ctvSelCompLib.setContentProvider(new CompLibCTVContentProvider());
- ctvSelCompLib.addDoubleClickListener(new IDoubleClickListener(){
- public void doubleClick(DoubleClickEvent event) {
- resetComponentLibSelection((StructuredSelection)event.getSelection(),
- tvCompLib,
- ctvSelCompLib,
- false);
- fireChangedEvent(event);
- }
- });
- ctvSelCompLib.addCheckStateListener(new ICheckStateListener() {
- public void checkStateChanged(CheckStateChangedEvent event) {
- JSFLibraryInternalReference changedItem = (JSFLibraryInternalReference) event.getElement();
- boolean isChecked4Deploy = event.getChecked();
-
- List list = workingCopyModel.getJSFComponentLibraries();
- Iterator it = list.iterator();
- JSFLibraryInternalReference crtjsflib = null;
- while (it.hasNext()) {
- crtjsflib = (JSFLibraryInternalReference) it.next();
- if (crtjsflib.getID().equals(changedItem.getID())) {
- crtjsflib.setToBeDeployed(isChecked4Deploy);
- fireChangedEvent(event);
- break;
- }
- }
- }
- });
-
- btnAdd.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- resetComponentLibSelection((StructuredSelection)tvCompLib.getSelection(),
- tvCompLib,
- ctvSelCompLib,
- true);
- fireChangedEvent(e);
- }
- });
-
- btnAddAll.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- resetCompontLibSelectionAll(tvCompLib, ctvSelCompLib, true);
- fireChangedEvent(e);
- }
- });
- btnRemove.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- resetComponentLibSelection((StructuredSelection)ctvSelCompLib.getSelection(),
- tvCompLib,
- ctvSelCompLib,
- false);
- fireChangedEvent(e);
- }
- });
-
- btnRemoveAll.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- resetCompontLibSelectionAll(tvCompLib, ctvSelCompLib, false);
- fireChangedEvent(e);
- }
- });
-
- tvCompLib.addSelectionChangedListener(new ISelectionChangedListener(){
- public void selectionChanged(SelectionChangedEvent event) {
- StructuredSelection sel= (StructuredSelection)event.getSelection();
- btnAdd.setEnabled(!sel.isEmpty() && sel.getFirstElement() instanceof JSFLibraryInternalReference);
- btnAddAll.setEnabled(tvCompLib.getTree().getItemCount() > 0);
- }
- });
-
- ctvSelCompLib.addSelectionChangedListener(new ISelectionChangedListener(){
- public void selectionChanged(SelectionChangedEvent event) {
- StructuredSelection sel= (StructuredSelection)event.getSelection();
- btnRemove.setEnabled(!sel.isEmpty());
- btnRemoveAll.setEnabled(ctvSelCompLib.getTable().getItemCount() > 0);
- }
- });
-
- }
- private void createControls() {
- setRedraw(true);
- final GridLayout gridLayout = new GridLayout();
- gridLayout.numColumns = 1;
- gridLayout.marginLeft = 0;
- gridLayout.marginRight = 0;
- gridLayout.marginWidth = 0;
- gridLayout.marginTop = 0;
- this.setLayout(gridLayout);
-
- createCompLibControls(this);
- }
-
- /*
- * Event handling helper methods
- */
-
- // Set selected item to the given state on model and update viewers.
- private void resetComponentLibSelection(StructuredSelection item,
- TreeViewer srcViewer,
- CheckboxTableViewer destViewer,
- boolean state) {
- if (item != null && !item.isEmpty()) {
- List selected = new ArrayList(item.size());
- for (Iterator sel=item.iterator();sel.hasNext();){
- JSFLibraryInternalReference jsfLibDctr = (JSFLibraryInternalReference)sel.next();
- selected.add(jsfLibDctr);
- List list = workingCopyModel.getJSFComponentLibraries();
- Iterator it = list.iterator();
- JSFLibraryInternalReference crtjsfLibDctr = null;
- while(it.hasNext()) {
- crtjsfLibDctr = (JSFLibraryInternalReference)it.next();
- if (crtjsfLibDctr.getID().equals(jsfLibDctr.getID())) {
- crtjsfLibDctr.setToBeDeployed(state);
- crtjsfLibDctr.setSelected(state);
- }
- }
- }
-
- loadJSFCompList();
-
- srcViewer.refresh();
- destViewer.refresh();
- for (Iterator it=selected.iterator();it.hasNext();){
- destViewer.setChecked(it.next(), state);
- }
-
- setCompListModelProperty();
- }
- }
-
- // Reset all component library from given state to model and update viewers.
- private void resetCompontLibSelectionAll(TreeViewer srcViewer,
- CheckboxTableViewer destViewer,
- boolean state) {
-
- List list = workingCopyModel.getJSFComponentLibraries();
- Iterator it = list.iterator();
- JSFLibraryInternalReference jsfLibDctr;
- while(it.hasNext()) {
- jsfLibDctr = (JSFLibraryInternalReference)it.next();
- jsfLibDctr.setSelected(state);
- jsfLibDctr.setToBeDeployed(state);
- }
-
- loadJSFCompList();
-
- srcViewer.refresh();
- destViewer.refresh();
- destViewer.setAllChecked(state);
-
- btnAddAll.setEnabled(! state);
- btnRemoveAll.setEnabled(state);
-
- setCompListModelProperty();
- }
-
- //synchHelper is not able to track changes to data elements in tableviewer... manual set of property
- private void setCompListModelProperty() {
- TableItem[] tableItems = ctvSelCompLib.getTable().getItems();
- List compLibs = new ArrayList(tableItems.length);
- for (int i=0;i<tableItems.length;i++){
- compLibs.add(tableItems[i].getData());
- }
- JSFLibraryInternalReference[] libs = (JSFLibraryInternalReference[])compLibs.toArray(new JSFLibraryInternalReference[0]);
- model.setProperty(IJSFFacetInstallDataModelProperties.COMPONENT_LIBRARIES, libs);
- }
-
-
- /**
- * Configure the JSFLibraryConfigControl elements to used the containers synchHelper
- * @param synchHelper
- */
- public void setSynchHelper(DataModelSynchHelper synchHelper) {
- model = synchHelper.getDataModel();
- }
-
- /**
- * Inner Classes for filtering.
- *
- */
- private static class CheckedTableViewerFilter extends ViewerFilter {
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (element instanceof JSFLibraryInternalReference) {
- return ((JSFLibraryInternalReference)element).isSelected();
- }
- return false;
- }
- }
- private static class TreeViewerFilter extends ViewerFilter {
-
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- if (element instanceof JSFLibraryInternalReference) {
- return !((JSFLibraryInternalReference)element).isSelected();
- }
- return true;
- }
- }
-
- private static class CompLibCTVContentProvider implements IStructuredContentProvider {
- private List jsfComplLibs = new ArrayList(0);
-
- public Object[] getElements(Object inputElement) {
- return jsfComplLibs.toArray();
- }
- public void dispose() {
- // do nothing
- }
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- if (newInput == null) {
- jsfComplLibs = Collections.EMPTY_LIST;
- } else {
- jsfComplLibs = (List)newInput;
- }
- }
- }
- // Label Provider
- private static class SelectedCompLibCTVLabelProvider extends LabelProvider implements ITableLabelProvider {
- public String getColumnText(Object element, int columnIndex) {
- if (element instanceof JSFLibraryInternalReference){
-
- switch(columnIndex) {
- case COLUMN_DEPLOY:
- return " "; //$NON-NLS-1$
- case COLUMN_LIB_NAME:
- return ((JSFLibraryInternalReference)element).getLabel();
- }
- }
- return ""; //$NON-NLS-1$
-
- }
- public Image getColumnImage(Object element, int columnIndex) {
- return null;
- }
- }
- // Sorter
- private static class SelectedCompLibCTVSorter extends ViewerSorter {
- public int compare(Viewer viewer, Object e1, Object e2) {
- if (e1 instanceof JSFLibraryInternalReference &&
- e2 instanceof JSFLibraryInternalReference) {
- JSFLibraryInternalReference item1 = (JSFLibraryInternalReference)e1;
- JSFLibraryInternalReference item2 = (JSFLibraryInternalReference)e2;
- return item1.getLabel().compareToIgnoreCase(item2.getLabel());
- }
- return 0;
- }
- }
-
- /*
- * Content provider Adapter for TreeViewer
- */
- private class TreeViewerAdapter implements ITreeContentProvider {
- private final Object[] NO_ELEMENTS= new Object[0];
-
- // ------- ITreeContentProvider Interface ------------
-
- public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
- // will never happen
- }
-
- public void dispose() {
- // do nothing
- }
-
- public Object[] getElements(Object obj) {
- return workingCopyModel.getJSFComponentLibraries().toArray();
- }
-
- public Object[] getChildren(Object element) {
- if (element instanceof JSFLibraryInternalReference) {
- return ((JSFLibraryInternalReference)element).getArchiveFiles().toArray();
- }
- return NO_ELEMENTS;
- }
-
- public Object getParent(Object element) {
- return null;
- }
-
- public boolean hasChildren(Object element) {
- if (element instanceof JSFLibraryInternalReference) {
- return true;
- }
- return false;
- }
-
- }
-
- private static class TreeLabelProvider implements ILabelProvider {
- private final Image libImg;
- private final Image jarImg;
-
- TreeLabelProvider()
- {
- ImageDescriptor jarImgDesc = JSFUiPlugin.getImageDescriptor("obj16/jar_obj.gif"); //$NON-NLS-1$
- jarImg = jarImgDesc.createImage();
- ImageDescriptor libImgDesc = JSFUiPlugin.getImageDescriptor("obj16/library_obj.gif"); //$NON-NLS-1$
- libImg = libImgDesc.createImage();
- }
-
- public Image getImage(Object element) {
- if (element instanceof JSFLibraryInternalReference)
- {
- return libImg;
- }
- return jarImg;
- }
-
- public String getText(Object element) {
- StringBuffer labelBuf = new StringBuffer();
- if (element instanceof JSFLibraryInternalReference) {
- JSFLibraryInternalReference libWrapper = (JSFLibraryInternalReference)element;
- JSFLibrary lib = libWrapper.getLibrary();
- labelBuf.append(lib.getLabel());
- if (lib.isImplementation()) {
- labelBuf.append(" "); //$NON-NLS-1$
- if (lib == JSFLibraryRegistryUtil.getInstance().getJSFLibraryRegistry().getDefaultImplementation()) {
- labelBuf.append(Messages.JSFLibrariesPreferencePage_DEFAULT_IMPL_DESC);
- } else {
- labelBuf.append(Messages.JSFLibrariesPreferencePage_IMPL_DESC);
- }
- }
- }
- if (element instanceof ArchiveFile) {
- ArchiveFile jar = (ArchiveFile)element;
- labelBuf.append(jar.getName());
- if (!jar.exists())
- labelBuf.append(Messages.JSFLibrariesPreferencePage_MISSING_DESC);
- labelBuf.append(" - ").append(((ArchiveFile)element).getSourceLocation()); //$NON-NLS-1$
- }
- return labelBuf.toString();
- }
-
- public void addListener(ILabelProviderListener listener) {
- // not handling listeners
- }
-
- public void dispose() {
- if (libImg != null){
- libImg.dispose();
- }
- if (jarImg != null){
- jarImg.dispose();
- }
- }
-
- public boolean isLabelProperty(Object element, String property) {
- return false;
- }
-
- public void removeListener(ILabelProviderListener listener) {
- // not handling listeners
- }
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeEvent.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeEvent.java
deleted file mode 100644
index 3ebbb691e..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeEvent.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;
-
-import java.util.EventObject;
-
-/**
- * Event that something has changed in the JSFLibraryConfigControl
- * @deprecated
- */
-public class JSFLibraryConfigControlChangeEvent {
- private EventObject event;
-
- /**
- * Constructor
- * @param ev
- */
- public JSFLibraryConfigControlChangeEvent(EventObject ev){
- this.event = ev;
- }
-
- /**
- * @return java.util.EventObject
- */
- public EventObject getEvent(){
- return event;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeListener.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeListener.java
deleted file mode 100644
index 6cf386aed..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryConfigControlChangeListener.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jsflibraryconfig;
-
-
-/**
- * Interface to be implemented to listen to changes in the JSFLibraryConfigControl object
- * @deprecated
- */
-public interface JSFLibraryConfigControlChangeListener {
- /**
- * Callback method
- * @param e
- */
- public void changed(JSFLibraryConfigControlChangeEvent e);
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/BeanSuffixHyperlink.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/BeanSuffixHyperlink.java
deleted file mode 100644
index 798503fd4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/BeanSuffixHyperlink.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.core.IMethod;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.hyperlink.IHyperlink;
-import org.eclipse.jst.jsf.common.util.JDTBeanProperty;
-import org.eclipse.jst.jsf.context.symbol.IBeanMethodSymbol;
-import org.eclipse.jst.jsf.context.symbol.IBeanPropertySymbol;
-import org.eclipse.jst.jsf.context.symbol.ISymbol;
-import org.eclipse.jst.jsf.context.symbol.internal.impl.JavaUtil;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.ui.IEditorPart;
-
-/**
- * Hyperlink for IBeanPropertySymbol and IBeanMethodSymbol el symbols. This Class only exists
- * in order to defer determining the (access) method to link to until user actually clicks
- * on the link, since determining takes too long.
- */
-class BeanSuffixHyperlink implements IHyperlink,ITestHyperlink {
- private final IRegion _fRegion;
- private final ISymbol _symbol;
-
- /**
- * Creates a BeanSuffixHyperlink for a symbol
- * @param region - the region of the hyperlink
- * @param symbol
- */
- public BeanSuffixHyperlink(final IRegion region, final ISymbol symbol) {
- _fRegion = region;
- _symbol = symbol;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getHyperlinkRegion()
- */
- public IRegion getHyperlinkRegion() {
- return _fRegion;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getTypeLabel()
- */
- public String getTypeLabel() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getHyperlinkText()
- */
- public String getHyperlinkText() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#open()
- */
- public void open() {
- final IJavaElement element = determineJavaElement();
- if (element != null) {
- try {
- final IEditorPart editor = JavaUI.openInEditor(element);
- if (editor != null) {
- JavaUI.revealInEditor(editor, element);
- }
- }
- catch (final Exception e) {
- JSFUiPlugin.log(IStatus.WARNING, e.getMessage(), e);
- }
- }
- }
-
- public IJavaElement determineJavaElement() {
- if (_symbol instanceof IBeanPropertySymbol) {
- return determinePropertyElement((IBeanPropertySymbol) _symbol);
- }
- if (_symbol instanceof IBeanMethodSymbol) {
- return JavaUtil.findCorrespondingMethod((IBeanMethodSymbol) _symbol);
- }
- return null;
- }
-
- private IMethod determinePropertyElement(final IBeanPropertySymbol propertySymbol) {
- final JDTBeanProperty property = JavaUtil.findCorrespondingJDTProperty(propertySymbol);
- if (property != null) {
- if (property.getGetter() != null) {
- return property.getGetter();
- }
- if (property.getSetter() != null) {
- return property.getSetter();
- }
- }
- return null;
- }
-
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ELHyperlinkDetector.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ELHyperlinkDetector.java
deleted file mode 100644
index 8201802ac..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ELHyperlinkDetector.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.jdt.core.IType;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Region;
-import org.eclipse.jface.text.hyperlink.AbstractHyperlinkDetector;
-import org.eclipse.jface.text.hyperlink.IHyperlink;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.context.symbol.IBeanInstanceSymbol;
-import org.eclipse.jst.jsf.context.symbol.IBeanMethodSymbol;
-import org.eclipse.jst.jsf.context.symbol.IBeanPropertySymbol;
-import org.eclipse.jst.jsf.context.symbol.ISymbol;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.SymbolInfo;
-
-/**
- * This HyperlinkDetector creates hyperlinks for symbols in JSF EL expressions
- * inside jsp files.
- */
-public class ELHyperlinkDetector extends AbstractHyperlinkDetector {
-
- public final IHyperlink[] detectHyperlinks(final ITextViewer textViewer,
- final IRegion region, final boolean canShowMultipleHyperlinks) {
- final IStructuredDocumentContext context = IStructuredDocumentContextFactory.INSTANCE
- .getContext(textViewer, region.getOffset());
- return detectHyperlinks(context, region);
- }
-
- /**
- * Broken out for testing.
- * @param context
- * @param region
- * @return the hyperlinks
- */
- protected IHyperlink[] detectHyperlinks(
- final IStructuredDocumentContext context, final IRegion region) {
- final Region elRegion = JSPSourceUtil.findELRegion(context);
- if (elRegion != null) {
- final SymbolInfo symbolInfo = JSPSourceUtil.determineSymbolInfo(
- context, elRegion, region.getOffset());
- if (symbolInfo != null) {
- IHyperlink link = null;
- final Region linkRegion = new Region(symbolInfo
- .getRelativeRegion().getOffset()
- + elRegion.getOffset(), symbolInfo.getRelativeRegion()
- .getLength());
- final ISymbol symbol = symbolInfo.getSymbol();
- if (symbol instanceof IBeanInstanceSymbol) {
- link = createBeanInstanceLink(linkRegion,
- (IBeanInstanceSymbol) symbol);
- } else if (symbol instanceof IBeanPropertySymbol) {
- link = createBeanPropertyLink(linkRegion,
- (IBeanPropertySymbol) symbol);
- } else if (symbol instanceof IBeanMethodSymbol) {
- link = createMethodLink(linkRegion,
- (IBeanMethodSymbol) symbol);
- }
- if (link != null) {
- return new IHyperlink[] { link };
- }
- }
- }
- return null;
- }
-
- private IHyperlink createBeanInstanceLink(final Region region,
- final IBeanInstanceSymbol symbol) {
- if (symbol.isTypeResolved()) {
- final IType type = symbol.getJavaTypeDescriptor().getType();
- return new JavaElementHyperlink(region, type);
- }
- return null;
- }
-
- private IHyperlink createBeanPropertyLink(final Region region,
- final IBeanPropertySymbol symbol) {
- // defer calculation of access method until user click on link (takes
- // too long otherwise):
- return new BeanSuffixHyperlink(region, symbol);
- }
-
- private IHyperlink createMethodLink(final Region region,
- final IBeanMethodSymbol symbol) {
- // defer calculation of access method until user click on link (takes
- // too long otherwise):
- return new BeanSuffixHyperlink(region, symbol);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ITestHyperlink.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ITestHyperlink.java
deleted file mode 100644
index 9fc86e7d6..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/ITestHyperlink.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.jdt.core.IJavaElement;
-
-/**
- * Test-only interface. Not for normal use.
- *
- * @author cbateman
- *
- */
-public interface ITestHyperlink {
- /**
- * @return the java element for symbol2 or null if none.
- */
- public IJavaElement determineJavaElement();
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSFELHover.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSFELHover.java
deleted file mode 100644
index 639cee731..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSFELHover.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.ITextHover;
-import org.eclipse.jface.text.ITextViewer;
-import org.eclipse.jface.text.Region;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContextFactory;
-import org.eclipse.jst.jsf.context.symbol.IDescribedInDetail;
-import org.eclipse.jst.jsf.context.symbol.ISymbol;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.SymbolInfo;
-
-/** This class creates hovers for ISymbols in an el expression that have a detailedDescription.
- */
-public class JSFELHover implements ITextHover {
-
- private ISymbol hoveredSymbol = null;
-
- public final String getHoverInfo(final ITextViewer textViewer, final IRegion hoverRegion) {
- return getHoverInfo();
- }
-
- /**
- * For testing
- *
- * @return the hover info
- */
- protected String getHoverInfo()
- {
- // hoveredSymbol set by getHoverRegion, which is called first
- if (hoveredSymbol instanceof IDescribedInDetail) {
- return ((IDescribedInDetail) hoveredSymbol).getDetailedDescription();
- }
- return null;
- }
-
- public final IRegion getHoverRegion(final ITextViewer textViewer, final int documentPosition) {
- final IStructuredDocumentContext context = IStructuredDocumentContextFactory.INSTANCE.getContext(textViewer,
- documentPosition);
- return getHoverRegion(context, documentPosition);
- }
-
- /**
- * For testing
- *
- * @param context
- * @param documentPosition
- * @return the hover region
- */
- protected IRegion getHoverRegion(final IStructuredDocumentContext context, final int documentPosition)
- {
- hoveredSymbol = null;
- final Region elRegion = JSPSourceUtil.findELRegion(context);
- if (elRegion != null) {
- final SymbolInfo symbolInfo = JSPSourceUtil.determineSymbolInfo(context, elRegion, documentPosition);
- if (symbolInfo == null) {
- return null;
- }
- final Region relativeRegion = symbolInfo.getRelativeRegion();
- final Region symbolRegion = new Region(elRegion.getOffset()
- + relativeRegion.getOffset(), relativeRegion.getLength());
- hoveredSymbol = symbolInfo.getSymbol();
- return symbolRegion;
- }
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSPSourceUtil.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSPSourceUtil.java
deleted file mode 100644
index 654f42fa1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JSPSourceUtil.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.jface.text.Region;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.IStructuredDocumentContextResolverFactory;
-import org.eclipse.jst.jsf.context.resolver.structureddocument.internal.ITextRegionContextResolver;
-import org.eclipse.jst.jsf.context.structureddocument.IStructuredDocumentContext;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.ContentAssistParser;
-import org.eclipse.jst.jsf.core.internal.contentassist.el.SymbolInfo;
-import org.eclipse.jst.jsf.designtime.DTAppManagerUtil;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewDefnAdapter;
-import org.eclipse.jst.jsf.designtime.internal.view.IDTViewHandler.ViewHandlerException;
-import org.eclipse.jst.jsf.designtime.internal.view.XMLViewDefnAdapter.DTELExpression;
-import org.eclipse.wst.xml.core.internal.regions.DOMRegionContext;
-
-/**
- * Utility class to access EL symbols in jsp file.
- */
-public final class JSPSourceUtil
-{
-
- private JSPSourceUtil()
- {
- // utility class, no instances.
- }
-
- /**
- * Find the Region
- *
- * @param context -
- * the IStructuredDocumentContext
- * @return region of el expression, null if context doesn't point to an el
- * expression
- */
- public static Region findELRegion(final IStructuredDocumentContext context)
- {
- if (context != null)
- {
- final DTELExpression expression = getELExpression(context);
- if (expression != null)
- {
- final ITextRegionContextResolver resolver = IStructuredDocumentContextResolverFactory.INSTANCE
- .getTextRegionResolver(expression.getDocumentContext());
-
- if (resolver != null)
- {
- final String regionType = resolver.getRegionType();
-
- if (regionType != null)
- {
-
- if (regionType == DOMRegionContext.XML_TAG_ATTRIBUTE_VALUE)
- {
- return new Region(expression.getDocumentContext()
- .getDocumentPosition(), expression
- .getText().length());
- }
- else if (resolver.matchesRelative(new String[]
- { DOMRegionContext.XML_TAG_ATTRIBUTE_VALUE }))
- {
- return new Region(resolver.getStartOffset(),
- resolver.getLength());
- }
- }
- }
- }
- }
- return null;
- }
-
- /**
- * Determines symbol and symbol region at a given document position
- *
- * @param context -
- * the IStructuredDocumentContext
- * @param elRegion -
- * the region of the el expression to consider
- * @param documentPosition -
- * the document position to get the symbol for
- * @return SymbolInfo
- */
- public static SymbolInfo determineSymbolInfo(
- final IStructuredDocumentContext context, final Region elRegion,
- final int documentPosition)
- {
- if (context != null && elRegion != null)
- {
- final DTELExpression elExpression = getELExpression(context);
-
- final String elText = elExpression.getText().trim();
-// context.getStructuredDocument().get(
-// elRegion.getOffset(), elRegion.getLength());
- final SymbolInfo symbolInfo =
- ContentAssistParser.getSymbolInfo(context,
- documentPosition - elRegion.getOffset() + 1,
- elText);
- return symbolInfo;
- }
- return null;
- }
-
- private static DTELExpression getELExpression(
- final IStructuredDocumentContext context)
- {
- final XMLViewDefnAdapter adapter = DTAppManagerUtil
- .getXMLViewDefnAdapter(context);
- DTELExpression expression = null;
- if (adapter != null)
- {
- try
- {
- expression = adapter.getELExpression(context);
- }
- catch (ViewHandlerException e)
- {
- expression = null;
- }
- }
- return expression;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JavaElementHyperlink.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JavaElementHyperlink.java
deleted file mode 100644
index 7d77ce805..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jspeditor/JavaElementHyperlink.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2007 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.jspeditor;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jdt.core.IJavaElement;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jface.text.hyperlink.IHyperlink;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.ui.IEditorPart;
-
-/**
- * Hyperlink for a IJavaElement to the corresponding java source
- */
-class JavaElementHyperlink implements IHyperlink, ITestHyperlink {
- private final IRegion fRegion;
- private final IJavaElement fElement;
-
- /**Creates a new hyperlink for a given IJavaElement
- * @param region - region of the hyperlink
- * @param element - hyperlink links to the source of <code>element</code>
- */
- public JavaElementHyperlink(final IRegion region, final IJavaElement element) {
- fRegion = region;
- fElement = element;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getHyperlinkRegion()
- */
- public IRegion getHyperlinkRegion() {
- return fRegion;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getTypeLabel()
- */
- public String getTypeLabel() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#getHyperlinkText()
- */
- public String getHyperlinkText() {
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jface.text.hyperlink.IHyperlink#open()
- */
- public void open() {
- try {
- final IEditorPart editor = JavaUI.openInEditor(fElement);
- if (editor != null) {
- JavaUI.revealInEditor(editor, fElement);
- }
- }
- catch (final Exception e) {
- JSFUiPlugin.log(IStatus.WARNING, e.getMessage(), e);
- }
- }
-
- public IJavaElement determineJavaElement() {
- return fElement;
- }
-
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/messages.properties
deleted file mode 100644
index ba5b6e2fe..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/messages.properties
+++ /dev/null
@@ -1,91 +0,0 @@
-###############################################################################
-# Copyright (c) 2005 Oracle Corporation.
-# 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:
-# Gerry Kessler - initial API and implementation
-# Ian Trimble - change key names for use with org.eclipse.osgi.util.NLS
-###############################################################################
-JSFFacetInstallPage_title=JSF Capabilities
-JSFFacetInstallPage_description=Add JSF capabilities to this Web Project
-JSFFacetInstallPage_JSFImplLabel=JSF &Implementation:
-JSFFacetInstallPage_Add1=A&dd...
-JSFFacetInstallPage_Add2=&Add...
-JSFFacetInstallPage_DeployJarsLabel=&Deploy jars to WEB-INF/lib
-JSFFacetInstallPage_JSFConfigLabel=JSF &Configuration File:
-JSFFacetInstallPage_JSFServletNameLabel=JSF &Servlet Name:
-JSFFacetInstallPage_JSFServletClassNameLabel=JSF Servlet C&lassname:
-JSFFacetInstallPage_JSFURLMappingLabel=&URL Mapping Patterns:
-JSFFacetInstallPage_JSFImplementationLibrariesFrame=JSF Implementation Library
-JSFFacetInstallPage_JSFComponentLibrariesFrame=Component Libraries
-JSFFacetInstallPage_PatternDialogTitle=Specify URL Pattern
-JSFFacetInstallPage_PatternDialogDesc=URL Pattern
-JSFFacetInstallPage_Remove=&Remove
-JSFFacetInstallPage_PatternEmptyMsg=Pattern must not be empty
-JSFFacetInstallPage_PatternSpecifiedMsg=Pattern is already specified
-JSFFacetInstallPage_ErrorNoWebAppDataModel=Unable to locate WebApp datamodel
-
-JSFLibrariesPreferencePage_DefinedJSFLibraries=Defined JSF Libraries:
-JSFLibrariesPreferencePage_DEFAULT_IMPL_DESC=[implementation - default]
-JSFLibrariesPreferencePage_New=New...
-JSFLibrariesPreferencePage_Edit=Edit...
-JSFLibrariesPreferencePage_Remove=Remove
-JSFLibrariesPreferencePage_CannotRemovePluginProvidedTitle=Cannot Remove
-JSFLibrariesPreferencePage_CannotRemovePluginProvidedMessage=Plugin provided libraries cannot be removed from the registry
-JSFLibrariesPreferencePage_MakeDefault=Make Default
-JSFLibrariesPreferencePage_MISSING_DESC=[missing]
-JSFLibrariesPreferencePage_Description=JSF Libraries contain jars with JSF components and tag libraries. Some JSF Libraries can be specially marked as implementations so that the WebApp can be executed.
-JSFLibrariesPreferencePage_IMPL_DESC=[implementation]
-JSFLibrariesPreferencePage_CannotModifyPluginProvidedTitle=Cannot Modify
-JSFLibraryPropertyPage_No_JSF_Implementation_Lib_Selected=No JSF implementation library selected.
-JSFLibrariesPreferencePage_CannotModifyPluginProvidedMessage=Plugin provided libraries cannot be edited
-
-JSFLibraryContainerWizardPage_PageName=Add JSF Library
-JSFLibraryContainerWizardPage_Title=JSF Library
-JSFLibraryContainerWizardPage_Description=Select JavaServer Face Libraries to add to the classpath
-JSFLibraryContainerWizardPage_WarningNoJSFFacet=JavaServer Face Libraries can only be configured for Dynamic Web projects with the JSF facet installed.
-JSFLibraryContainerWizardPage_JSFLibraries=JSF Libraries:
-JSFLibraryContainerWizardPage_Add=Add...
-JSFLibraryWizard_JSFLibraryWizard_DontShowThisAgain_CheckBoxLabel=Do not show this message again (affects all listed projects)
-JSFLibraryContainerWizardPage_EditLibrary_DescriptionText=Select JSF Library for this reference to use. Choose 'Edit...' to modify contents of the selected library.
-JSFLibraryContainerWizardPage_Edit=Edit...
-JSFLibraryContainerWizardPage_ImplAlreadyPresent=An implementation has already been chosen. Please remove before adding different one
-JSFLibraryContainerWizardPage_ErrorInitializing=Error during initialization
-JSFLibraryContainerWizardPage_SelectOneImpl=Choose only one implementation
-
-JSFLibraryWizard_DESCRIPTION=Create a library of jars that make up a JSF component library.
-JSFLibraryWizard_CreateJSFLibrary=Create JSF Library
-JSFLibraryWizard_EditJSFLibrary=Edit JSF Library
-JSFLibraryWizard_JSFLibrary=JSF Library
-JSFLibraryWizard_LibraryName=Library &Name:
-JSFLibraryWizard_VersionSupported=&Version Supported:
-JSFLibraryWizard_LibraryJars=Library &Jars
-JSFLibraryWizard_DeployJars=&Deploy Jars
-JSFLibraryWizard_Add=&Add...
-JSFLibraryWizard_Remove=&Remove
-JSFLibraryWizard_ExtJarFileDialogTitle=Browse for Jars/Zips
-JSFLibraryWizard_ValidateNoJars=The library must contain at least one jar.
-JSFLibraryWizard_ValidateNoLibraryName=A library name must be supplied.
-JSFLibraryWizard_ValidateExistingLibraryName=A library or implementation by this name already exists.
-JSFLibraryConfigControl_ImplementationLibrary=Implementation Library
-JSFLibraryPropertyPage_No_JSF_Facet_Installed=JSF Facet not installed.
-JSFLibraryConfigControl_DeployJAR=Deploy jars to WEB-INF/lib
-JSFLibraryConfigControl_Add=\ \ >
-JSFLibraryConfigControl_Remove=\ \ <
-JSFLibraryConfigControl_AddAll=\ \ >>
-JSFLibraryConfigControl_RemoveAll=\ \ <<
-JSFLibraryConfigControl_NewComponentLibrary=New...
-JSFLibraryConfigControl_TH_Deploy=Deploy
-JSFLibraryConfigControl_NullProject=No project specified.
-JSFLibraryConfigControl_TH_LibraryName=Library Name
-
-JSFValidationPreferencePage_ELPrefPanel_Title=Expression Language (EL) Validation
-JSFValidationPreferencePage_ELPrefPanel_BuildValidationCheckBoxTitle=Validate EL on &Build/Run Validation
-JSFValidationPreferencePage_ELPrefPanel_IncrementalValidationCheckBoxTitle= Validate EL as &you type (may be slow on some pages)
-
-JSFLibraryEditControl_ImplVersion_UNKNOWN=UNKNOWN
-
-JSFPreferences_RootPage_Description=Expand the tree to edit preferences for a specific feature. \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/EmptyRootPreferencePage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/EmptyRootPreferencePage.java
deleted file mode 100644
index d269dd275..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/EmptyRootPreferencePage.java
+++ /dev/null
@@ -1,109 +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
- * Jens Lukowski/Innoopract - initial renaming/restructuring
- * Oracle - adapted for JSF tooling
- *
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.preferences;
-
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.ScrolledComposite;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * The empty pref page used as the root of all other JSF feature preference pages
- * under the Web&XML top-level pref page
- *
- * @author cbateman
- *
- */
-public class EmptyRootPreferencePage extends PreferencePage implements IWorkbenchPreferencePage {
-
- private Composite createComposite(Composite parent, int numColumns) {
- noDefaultAndApplyButton();
-
- Composite composite = new Composite(parent, SWT.NULL);
-
- // GridLayout
- GridLayout layout = new GridLayout();
- layout.numColumns = numColumns;
- composite.setLayout(layout);
-
- // GridData
- GridData data = new GridData(GridData.FILL);
- data.horizontalIndent = 0;
- data.verticalAlignment = GridData.FILL;
- data.horizontalAlignment = GridData.FILL;
- composite.setLayoutData(data);
-
- return composite;
- }
-
- protected Control createContents(Composite parent) {
- Composite composite = createScrolledComposite(parent);
-
- String description = Messages.JSFPreferences_RootPage_Description;
- Text text = new Text(composite, SWT.READ_ONLY);
- // some themes on GTK have different background colors for Text and Labels
- text.setBackground(composite.getBackground());
- text.setText(description);
-
- setSize(composite);
- return composite;
- }
-
- private Composite createScrolledComposite(Composite parent) {
- // create scrollbars for this parent when needed
- final ScrolledComposite sc1 = new ScrolledComposite(parent, SWT.H_SCROLL | SWT.V_SCROLL);
- sc1.setLayoutData(new GridData(GridData.FILL_BOTH));
- Composite composite = createComposite(sc1, 1);
- sc1.setContent(composite);
-
- // not calling setSize for composite will result in a blank composite,
- // so calling it here initially
- // setSize actually needs to be called after all controls are created,
- // so scrolledComposite
- // has correct minSize
- setSize(composite);
- return composite;
- }
-
- public void init(IWorkbench workbench) {
- // do nothing
- }
-
- private void setSize(Composite composite) {
- if (composite != null) {
- // Note: The font is set here in anticipation that the class inheriting
- // this base class may add widgets to the dialog. setSize
- // is assumed to be called just before we go live.
- applyDialogFont(composite);
- Point minSize = composite.computeSize(SWT.DEFAULT, SWT.DEFAULT);
- composite.setSize(minSize);
- // set scrollbar composite's min size so page is expandable but
- // has scrollbars when needed
- if (composite.getParent() instanceof ScrolledComposite) {
- ScrolledComposite sc1 = (ScrolledComposite) composite.getParent();
- sc1.setMinSize(minSize);
- sc1.setExpandHorizontal(true);
- sc1.setExpandVertical(true);
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/JSPTagRegistryPreferencePage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/JSPTagRegistryPreferencePage.java
deleted file mode 100644
index c0cc32379..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/JSPTagRegistryPreferencePage.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.preferences;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.dialogs.MessageDialogWithToggle;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.jsf.common.internal.policy.OrderedListProvider;
-import org.eclipse.jst.jsf.common.internal.policy.OrderedListProvider.OrderableObject;
-import org.eclipse.jst.jsf.common.ui.internal.preferences.StrategyOrderingPanel;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.jst.jsf.designtime.internal.view.model.ITagRegistry;
-import org.eclipse.jst.jsf.designtime.internal.view.model.TagRegistryFactory;
-import org.eclipse.jst.jsf.designtime.internal.view.model.TagRegistryFactory.TagRegistryFactoryException;
-import org.eclipse.jst.jsf.designtime.internal.view.model.jsp.registry.TLDRegistryManager;
-import org.eclipse.jst.jsf.designtime.internal.view.model.jsp.registry.TLDRegistryPreferences;
-import org.eclipse.jst.jsf.designtime.internal.view.model.jsp.registry.TLDRegistryPreferences.StrategyIdentifier;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * Preferences for the JSP tag registry.
- *
- * @author cbateman
- *
- */
-public class JSPTagRegistryPreferencePage extends PreferencePage implements
- IWorkbenchPreferencePage
-{
- private final TLDRegistryPreferences _tldRegistryPreferences;
- private StrategyOrderingPanel _panel;
- private OrderedListProvider _provider;
-
- /**
- * Default constructor: required by the preference page
- */
- public JSPTagRegistryPreferencePage()
- {
- _tldRegistryPreferences = new TLDRegistryPreferences(
- getPreferenceStore());
- _tldRegistryPreferences.load();
- }
-
- @Override
- protected Control createContents(final Composite parent)
- {
- _provider = _tldRegistryPreferences.getOrderedListProvider();
- _panel = new StrategyOrderingPanel(
- _provider,
- new MyLabelProvider(),
- Messages.JSPTagRegistryPreferencePage_PanelDescription);
- final Control contents = _panel.createContents(parent);
- _panel.refresh();
- return contents;
- }
-
- public void init(final IWorkbench workbench)
- {
- // do nothing
- }
-
- protected void performApply()
- {
- if (_tldRegistryPreferences.isDirty())
- {
- final MessageDialogWithToggle dialog =
- MessageDialogWithToggle.openOkCancelConfirm(getShell(),
- Messages.JSPTagRegistryPreferencePage_0,
- Messages.JSPTagRegistryPreferencePage_1,
- Messages.JSPTagRegistryPreferencePage_2, false, null, null);
-
- if (dialog.getReturnCode() == Window.OK)
- {
- _tldRegistryPreferences.commit(getPreferenceStore());
- final TagRegistryFactory myRegistryFactory = new TLDRegistryManager.MyRegistryFactory();
- for (final IProject project : ResourcesPlugin.getWorkspace().getRoot().getProjects())
- {
- if (project.isAccessible()
- && myRegistryFactory.isInstance(project))
- {
- try
- {
- final ITagRegistry tagRegistry =
- myRegistryFactory.createTagRegistry(project);
- tagRegistry.refresh(null, dialog.getToggleState());
- }
- catch (TagRegistryFactoryException e)
- {
- JSFUiPlugin.log(IStatus.ERROR, "Error getting JSP tag registry on project: "+project.getName(), e); //$NON-NLS-1$
- }
- }
- }
- }
- }
- }
-
- protected void performDefaults()
- {
- _tldRegistryPreferences.setDefaults();
- //_provider.setStrategies(_tldRegistryPreferences.getStrategyIdOrdering());
- _panel.refresh();
- super.performDefaults();
- }
-
- public boolean performOk()
- {
- performApply();
- return true;
- }
-
- @Override
- protected IPreferenceStore doGetPreferenceStore()
- {
- return JSFCorePlugin.getDefault().getPreferenceStore();
- }
-
-
- private static class MyLabelProvider extends LabelProvider implements
- ITableLabelProvider
- {
- public Image getColumnImage(final Object element, final int columnIndex)
- {
- // no image.
- return null;
- }
-
- public String getColumnText(final Object element, final int columnIndex)
- {
- switch (columnIndex)
- {
- case 0:
- if (element instanceof OrderableObject)
- {
- return ((StrategyIdentifier)(((OrderableObject) element).getObject())).getDisplayName();
- }
- default:
- Assert.isTrue(false);
- return null;
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/Messages.java
deleted file mode 100644
index adde4c60a..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/Messages.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.preferences;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * NLS messages
- * @author cbateman
- *
- */
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.preferences.messages"; //$NON-NLS-1$
- /**
- * see messages.properties
- */
- public static String JSPTagRegistryPreferencePage_0;
- /**
- * see messages.properties
- */
- public static String JSPTagRegistryPreferencePage_1;
- /**
- * see messages.properties
- */
- public static String JSPTagRegistryPreferencePage_2;
- /**
- * see messages.properties
- */
- public static String JSPTagRegistryPreferencePage_PanelDescription;
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/messages.properties
deleted file mode 100644
index 1cc72c580..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/preferences/messages.properties
+++ /dev/null
@@ -1,4 +0,0 @@
-JSPTagRegistryPreferencePage_0=Registry must be refreshed
-JSPTagRegistryPreferencePage_1=Committing this changes will require that the TLD tag registry is refreshed
-JSPTagRegistryPreferencePage_2=Flush caches
-JSPTagRegistryPreferencePage_PanelDescription=Set the order in which tag resolvers are consulted when constructing the JSP tag registry
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFFacetInstallPage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFFacetInstallPage.java
deleted file mode 100644
index 6b4057540..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFFacetInstallPage.java
+++ /dev/null
@@ -1,467 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 Oracle Corporation.
- * 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:
- * Gerry Kessler - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.project.facet;
-
-import java.util.Iterator;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.dialogs.DialogSettings;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.jface.dialogs.IInputValidator;
-import org.eclipse.jface.dialogs.InputDialog;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jst.common.project.facet.core.libprov.LibraryInstallDelegate;
-import org.eclipse.jst.common.project.facet.ui.libprov.LibraryProviderFrameworkUi;
-import org.eclipse.jst.j2ee.project.facet.IJ2EEModuleFacetInstallDataModelProperties;
-import org.eclipse.jst.jsf.core.internal.project.facet.IJSFFacetInstallDataModelProperties;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.swt.SWT;
-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.Label;
-import org.eclipse.swt.widgets.List;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelProvider;
-import org.eclipse.wst.common.frameworks.datamodel.DataModelEvent;
-import org.eclipse.wst.common.frameworks.datamodel.DataModelFactory;
-import org.eclipse.wst.common.frameworks.datamodel.IDataModel;
-import org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage;
-import org.eclipse.wst.common.project.facet.core.IFacetedProject;
-import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
-import org.eclipse.wst.common.project.facet.ui.IFacetWizardPage;
-import org.eclipse.wst.common.project.facet.ui.IWizardContext;
-
-/**
- * JSF Facet installation wizard page.
- *
- * @author Gerry Kessler - Oracle
- */
-public class JSFFacetInstallPage extends DataModelWizardPage implements
- IJSFFacetInstallDataModelProperties, IFacetWizardPage {
- // UI
- private Label lblJSFConfig;
- private Text txtJSFConfig;
- private Label lblJSFServletName;
- private Text txtJSFServletName;
- private Label lblJSFServletClassName;
- private Text txtJSFServletClassName;
- private Label lblJSFServletURLPatterns;
- private List lstJSFServletURLPatterns;
- private Button btnAddPattern;
- private Button btnRemovePattern;
-
- private IDialogSettings dialogSettings;
- private IDataModel webAppDataModel;
- private static final String SETTINGS_ROOT = JSFUiPlugin.PLUGIN_ID
- + ".jsfFacetInstall"; //$NON-NLS-1$
- private static final String SETTINGS_CONFIG = "configPath"; //$NON-NLS-1$
- private static final String SETTINGS_SERVLET = "servletName"; //$NON-NLS-1$
- private static final String SETTINGS_SERVLET_CLASSNAME = "servletClassname"; //$NON-NLS-1$
- private static final String SETTINGS_URL_MAPPINGS = "urlMappings"; //$NON-NLS-1$
- private static final String SETTINGS_URL_PATTERN = "pattern"; //$NON-NLS-1$
-
- // private String projectName = null;
- private Composite composite = null;
-
- /**
- * Zero argument constructor
- */
- public JSFFacetInstallPage() {
- // FIXME: following WebFacetInstallPage pattern which will be fixed at somepoint
- super(DataModelFactory.createDataModel(new AbstractDataModelProvider() {/*
- * do
- * nothing
- */
- }), "jsf.facet.install.page"); //$NON-NLS-1$
- setTitle(Messages.JSFFacetInstallPage_title);
- setDescription(Messages.JSFFacetInstallPage_description);
- dialogSettings = JSFUiPlugin.getDefault().getDialogSettings();
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#createTopLevelComposite(org.eclipse.swt.widgets.Composite)
- */
- protected Composite createTopLevelComposite(final Composite parent) {
- initializeDialogUnits(parent);
- composite = new Composite(parent, SWT.NONE);
- final GridLayout jsfCompositeLayout = new GridLayout(3, false);
- jsfCompositeLayout.marginTop = 0;
- jsfCompositeLayout.marginBottom = 0;
- jsfCompositeLayout.marginRight = 0;
- jsfCompositeLayout.marginLeft = 0;
- composite.setLayout(jsfCompositeLayout);
-
- final LibraryInstallDelegate librariesInstallDelegate
- = (LibraryInstallDelegate) getDataModel().getProperty( LIBRARY_PROVIDER_DELEGATE );
-
- final Control librariesComposite
- = LibraryProviderFrameworkUi.createInstallLibraryPanel( composite, librariesInstallDelegate,
- Messages.JSFFacetInstallPage_JSFImplementationLibrariesFrame );
-
- GridData gd = new GridData( GridData.FILL_HORIZONTAL );
- gd.horizontalSpan = 3;
-
- librariesComposite.setLayoutData( gd );
-
- final Label spacer = new Label( composite, SWT.NONE );
- spacer.setText( "" ); //$NON-NLS-1$
-
- gd = new GridData( GridData.FILL_HORIZONTAL );
- gd.horizontalSpan = 3;
-
- spacer.setLayoutData( gd );
-
- lblJSFConfig = new Label(composite, SWT.NONE);
- lblJSFConfig.setText(Messages.JSFFacetInstallPage_JSFConfigLabel);
- lblJSFConfig.setLayoutData(new GridData(GridData.BEGINNING));
-
- txtJSFConfig = new Text(composite, SWT.BORDER);
- GridData gd1 = new GridData(GridData.FILL_HORIZONTAL);
- gd1.horizontalSpan = 2;
- txtJSFConfig.setLayoutData(gd1);
-
- lblJSFServletName = new Label(composite, SWT.NONE);
- lblJSFServletName
- .setText(Messages.JSFFacetInstallPage_JSFServletNameLabel);
- lblJSFServletName.setLayoutData(new GridData(GridData.BEGINNING));
-
- txtJSFServletName = new Text(composite, SWT.BORDER);
- GridData gd2 = new GridData(GridData.FILL_HORIZONTAL);
- gd2.horizontalSpan = 2;
- txtJSFServletName.setLayoutData(gd2);
-
- lblJSFServletClassName = new Label(composite, SWT.NONE);
- lblJSFServletClassName
- .setText(Messages.JSFFacetInstallPage_JSFServletClassNameLabel);
- lblJSFServletClassName.setLayoutData(new GridData(GridData.BEGINNING));
-
- txtJSFServletClassName = new Text(composite, SWT.BORDER);
- GridData gd2c = new GridData(GridData.FILL_HORIZONTAL);
- gd2c.horizontalSpan = 2;
- txtJSFServletClassName.setLayoutData(gd2c);
-
- lblJSFServletURLPatterns = new Label(composite, SWT.NULL);
- lblJSFServletURLPatterns
- .setText(Messages.JSFFacetInstallPage_JSFURLMappingLabel);
- lblJSFServletURLPatterns.setLayoutData(new GridData(GridData.BEGINNING
- | GridData.VERTICAL_ALIGN_BEGINNING));
- lstJSFServletURLPatterns = new List(composite, SWT.BORDER);
- GridData gd3 = new GridData(GridData.FILL_HORIZONTAL);
- gd3.heightHint = convertHeightInCharsToPixels(5);
- lstJSFServletURLPatterns.setLayoutData(gd3);
- lstJSFServletURLPatterns.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- btnRemovePattern.setEnabled(lstJSFServletURLPatterns
- .getSelectionCount() > 0);
- }
- });
-
- Composite btnComposite = new Composite(composite, SWT.NONE);
- GridLayout gl = new GridLayout(1, false);
- // gl.marginBottom = 0;
- // gl.marginTop = 0;
- // gl.marginRight = 0;
- gl.marginLeft = 0;
- btnComposite.setLayout(gl);
- btnComposite.setLayoutData(new GridData(GridData.END
- | GridData.VERTICAL_ALIGN_FILL));
-
- btnAddPattern = new Button(btnComposite, SWT.NONE);
- btnAddPattern.setText(Messages.JSFFacetInstallPage_Add2);
- btnAddPattern.setLayoutData(new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- btnAddPattern.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- InputDialog dialog = new InputDialog(getShell(),
- Messages.JSFFacetInstallPage_PatternDialogTitle,
- Messages.JSFFacetInstallPage_PatternDialogDesc, null,
- new IInputValidator() {
-
- public String isValid(String newText) {
- return isValidPattern(newText);
- }
-
- });
- dialog.open();
- if (dialog.getReturnCode() == Window.OK) {
- addItemToList(dialog.getValue(), true);
- }
- }
- });
-
- btnRemovePattern = new Button(btnComposite, SWT.NONE);
- btnRemovePattern.setText(Messages.JSFFacetInstallPage_Remove);
- btnRemovePattern.setLayoutData(new GridData(GridData.FILL_HORIZONTAL
- | GridData.VERTICAL_ALIGN_BEGINNING));
- btnRemovePattern.setEnabled(false);
- btnRemovePattern.addSelectionListener(new SelectionAdapter() {
- public void widgetSelected(SelectionEvent e) {
- removeItemFromList(lstJSFServletURLPatterns.getSelection());
- btnRemovePattern.setEnabled(false);
- }
- });
-
- addModificationListeners();
-
- this.getContainer().getShell().pack();
-
- return composite;
- }
-
- private void initializeValues() {
- IDialogSettings root = dialogSettings.getSection(SETTINGS_ROOT);
-
- initJSFCfgCtrlValues(root);
-
- String conf = null;
- if (root != null)
- conf = root.get(SETTINGS_CONFIG);
- if (conf == null || conf.equals("")) { //$NON-NLS-1$
- conf = (String) model
- .getDefaultProperty(IJSFFacetInstallDataModelProperties.CONFIG_PATH);
- }
- txtJSFConfig.setText(conf);
-
- String servletName = null;
- if (root != null)
- servletName = root.get(SETTINGS_SERVLET);
- if (servletName == null || servletName.equals("")) { //$NON-NLS-1$
- servletName = (String) model
- .getDefaultProperty(IJSFFacetInstallDataModelProperties.SERVLET_NAME);
- }
- txtJSFServletName.setText(servletName);
-
- String servletClassname = null;
- if (root != null)
- servletClassname = root.get(SETTINGS_SERVLET_CLASSNAME);
- if (servletClassname == null || servletClassname.equals("")) { //$NON-NLS-1$
- servletClassname = (String) model
- .getDefaultProperty(IJSFFacetInstallDataModelProperties.SERVLET_CLASSNAME);
- }
- txtJSFServletClassName.setText(servletClassname);
-
- loadURLMappingPatterns(root);
- }
-
- private void initJSFCfgCtrlValues(IDialogSettings root) {
- /*IDialogSettings complibs = null;
- if (root != null) {
- complibs = root.getSection(SETTINGS_COMPLIB);
- }
-
- String[] selection = null;
- if (complibs != null) {
- selection = complibs.getArray(SETTINGS_COMPLIB_SELECT_DEPLOY);
- }
-
- JSFLibraryConfigDialogSettingData source = new JSFLibraryConfigDialogSettingData(selection);
- jsfLibCfgComp.loadControlValuesFromModel(source);*/
- }
-
-
- private void saveSettings() {
- DialogSettings root = new DialogSettings(SETTINGS_ROOT);
- dialogSettings.addSection(root);
-
- root.put(SETTINGS_CONFIG, getJSFConfig());
- root.put(SETTINGS_SERVLET, getJSFServletName());
- root.put(SETTINGS_SERVLET_CLASSNAME, getJSFServletClassname());
- DialogSettings mappings = new DialogSettings(SETTINGS_URL_MAPPINGS);
- root.addSection(mappings);
- mappings.put(SETTINGS_URL_PATTERN, getJSFPatterns());
- }
-
- private String getJSFConfig() {
- return txtJSFConfig.getText().trim();
- }
-
- private String getJSFServletName() {
- return txtJSFServletName.getText().trim();
- }
-
- private String getJSFServletClassname() {
- return txtJSFServletClassName.getText().trim();
- }
-
- private String[] getJSFPatterns() {
- return lstJSFServletURLPatterns.getItems();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.project.facet.ui.IFacetWizardPage#setConfig(java.lang.Object)
- */
- public void setConfig(Object config) {
- model.removeListener(this);
- synchHelper.dispose();
-
- model = (IDataModel) config;
- model.addListener(this);
- synchHelper = initializeSynchHelper(model);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.common.project.facet.ui.IFacetWizardPage#transferStateToConfig()
- */
- public void transferStateToConfig() {
- saveSettings(); // convenient place for this. don't want to save if user
- // cancelled.
- }
-
- private void addModificationListeners() {
- synchHelper.synchText(txtJSFConfig, CONFIG_PATH, null);
- synchHelper.synchText(txtJSFServletName, SERVLET_NAME, null);
- synchHelper.synchText(txtJSFServletClassName, SERVLET_CLASSNAME, null);
- synchHelper.synchList(lstJSFServletURLPatterns, SERVLET_URL_PATTERNS, null);
- }
-
- private String isValidPattern(String value) {
- if (value == null || value.trim().equals("")) //$NON-NLS-1$
- return Messages.JSFFacetInstallPage_PatternEmptyMsg;
- if (lstJSFServletURLPatterns.indexOf(value) >= 0)
- return Messages.JSFFacetInstallPage_PatternSpecifiedMsg;
-
- return null;
- }
-
- private void loadURLMappingPatterns(IDialogSettings root) {
- lstJSFServletURLPatterns.removeAll();
- IDialogSettings mappings = null;
- if (root != null)
- mappings = root.getSection(SETTINGS_URL_MAPPINGS);
- String[] patterns = null;
- if (mappings != null)
- patterns = mappings.getArray(SETTINGS_URL_PATTERN);
-
- if (patterns == null || patterns.length == 0) {
- patterns = (String[]) model
- .getDefaultProperty(IJSFFacetInstallDataModelProperties.SERVLET_URL_PATTERNS);
- }
- for (int i = 0; i < patterns.length; i++) {
- addItemToList(patterns[i], false);
- }
- }
-
- private void addItemToList(String pattern, boolean selectMe) {
- lstJSFServletURLPatterns.add(pattern == null ? "" : pattern); //$NON-NLS-1$
- if (pattern == null && selectMe)
- lstJSFServletURLPatterns.setSelection(lstJSFServletURLPatterns
- .getItemCount() - 1);
- // When 119321 is fixed - remove code below
- updateModelForURLPattern();
- }
-
- private void removeItemFromList(String[] selection) {
- for (int i = 0; i < selection.length; i++) {
- String sel = selection[i];
- lstJSFServletURLPatterns.remove(sel);
- }
- // When 119321 is fixed - remove code below
- updateModelForURLPattern();
- }
-
- private void updateModelForURLPattern() {
- model.setProperty(
- IJSFFacetInstallDataModelProperties.SERVLET_URL_PATTERNS,
- lstJSFServletURLPatterns.getItems());
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#getValidationPropertyNames()
- */
- protected String[] getValidationPropertyNames() {
- return new String[] { CONFIG_PATH, SERVLET_NAME, SERVLET_CLASSNAME, COMPONENT_LIBRARIES, LIBRARY_PROVIDER_DELEGATE };
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.project.facet.ui.IFacetWizardPage#setWizardContext(org.eclipse.wst.common.project.facet.ui.IWizardContext)
- */
- public void setWizardContext(IWizardContext context) {
- // hook into web datamodel if new project wizard.
- Iterator it = context.getSelectedProjectFacets().iterator();
- IProjectFacetVersion webFacetVersion = null;
- while (it.hasNext()) {
- // find Web facet
- IProjectFacetVersion pfv = (IProjectFacetVersion) it.next();
- if (pfv.getProjectFacet().getId().equals("jst.web")) { //$NON-NLS-1$
- webFacetVersion = pfv;
- break;
- }
- }
- if (webFacetVersion != null) {
- try {
- webAppDataModel = (IDataModel) context.getConfig(
- webFacetVersion, IFacetedProject.Action.Type.INSTALL,
- context.getProjectName());
- if (webAppDataModel != null) {
- webAppDataModel.addListener(this);
- }
- } catch (CoreException e) {
- JSFUiPlugin.log(IStatus.ERROR,
- Messages.JSFFacetInstallPage_ErrorNoWebAppDataModel, e);
- }
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#propertyChanged(org.eclipse.wst.common.frameworks.datamodel.DataModelEvent)
- */
- public void propertyChanged(DataModelEvent event) {
- if (webAppDataModel != null) {
- String propertyName = event.getPropertyName();
- if (propertyName
- .equals(IJ2EEModuleFacetInstallDataModelProperties.CONFIG_FOLDER)) {
- model.setStringProperty(WEBCONTENT_DIR, event.getProperty()
- .toString());
- }
- }
- super.propertyChanged(event);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#dispose()
- */
- public void dispose() {
- if (webAppDataModel != null)
- webAppDataModel.removeListener(this);
-
- //jsfLibCfgComp.dispose();
- super.dispose();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#restoreDefaultSettings()
- */
- protected void restoreDefaultSettings() {
- initializeValues();
- }
- /* (non-Javadoc)
- * @see org.eclipse.wst.common.frameworks.internal.datamodel.ui.DataModelWizardPage#showValidationErrorsOnEnter()
- */
- protected boolean showValidationErrorsOnEnter() {
- return true;
- }
-
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFLibraryPropertyPage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFLibraryPropertyPage.java
deleted file mode 100644
index f366a58fb..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/project/facet/JSFLibraryPropertyPage.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package org.eclipse.jst.jsf.ui.internal.project.facet;
-
-import org.eclipse.jst.common.project.facet.ui.libprov.FacetLibraryPropertyPage;
-import org.eclipse.wst.common.project.facet.core.IFacetedProject;
-import org.eclipse.wst.common.project.facet.core.IProjectFacet;
-import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
-import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
-
-public final class JSFLibraryPropertyPage
-
- extends FacetLibraryPropertyPage
-
-{
- @Override
- public IProjectFacetVersion getProjectFacetVersion()
- {
- final IProjectFacet jsfFacet = ProjectFacetsManager.getProjectFacet( "jst.jsf" ); //$NON-NLS-1$
- final IFacetedProject fproj = getFacetedProject();
- return fproj.getInstalledVersion( jsfFacet );
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ComponentDetailSubForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ComponentDetailSubForm.java
deleted file mode 100644
index cc072c6ab..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ComponentDetailSubForm.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.component.ComponentTypeInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IComponentTagElement;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.jst.jsf.ui.internal.common.ViewObjectPresenter;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Details page for component details.
- *
- * @author cbateman
- *
- */
-public class ComponentDetailSubForm extends AbstractXMLSectionsDetailsForm
-{
- private final static String COMPONENT_TYPE_SECTION_KEY = "componentSection"; //$NON-NLS-1$
- private static final String INTERFACES_SECTION_KEY = "interfacesSection"; //$NON-NLS-1$
- private XMLTextSection _componentTypeSection;
- private XMLTextSection _interfacesSection;
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _componentTypeSection = new XMLTextSection(getToolkit(), parent, Messages.ComponentDetailSubForm_TypeInfo);
- sections.put(COMPONENT_TYPE_SECTION_KEY, _componentTypeSection);
-
- _interfacesSection = new XMLTextSection(getToolkit(), parent, Messages.ComponentDetailSubForm_InterfaceInfo);
- sections.put(INTERFACES_SECTION_KEY, _interfacesSection);
- return sections;
- }
-
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_componentTypeSection);
- }
-
-
- @Override
- protected void doUpdateSelection(final Object newSelection)
- {
- if (newSelection instanceof IComponentTagElement)
- {
- final IComponentTagElement curTagElement = (IComponentTagElement) newSelection;
- final ComponentTypeInfo typeInfo = curTagElement.getComponent();
- if (typeInfo != null)
- {
- _componentTypeSection.setText(ViewObjectPresenter.present(typeInfo), true, false);
- _interfacesSection.setText(ViewObjectPresenter.presentCompInterfaces(typeInfo, null), true, false);
- _componentTypeSection.refresh();
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ConverterDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ConverterDetailsForm.java
deleted file mode 100644
index 6a97504c3..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ConverterDetailsForm.java
+++ /dev/null
@@ -1,78 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ConverterTypeInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IConverterTagElement;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Details form for a converter tag.
- *
- * @author cbateman
- *
- */
-public class ConverterDetailsForm extends AbstractXMLSectionsDetailsForm
-{
- private final static String CONVERTER_TYPE_SECTION_KEY = "converterSection"; //$NON-NLS-1$
- private XMLTextSection _converterTypeSection;
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _converterTypeSection = new XMLTextSection(getToolkit(), parent, Messages.ConverterDetailsForm_ConverterInfo);
- sections.put(CONVERTER_TYPE_SECTION_KEY, _converterTypeSection);
- return sections;
- }
-
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_converterTypeSection);
- }
-
- @Override
- protected void doUpdateSelection(Object newSelection)
- {
- if (newSelection instanceof IConverterTagElement)
- {
- IConverterTagElement converterTagElement = (IConverterTagElement) newSelection;
- final ConverterTypeInfo typeInfo = converterTagElement.getConverter();
-
- if (typeInfo != null)
- {
- final String className = typeInfo.getClassName();
- final String converterId = typeInfo.getConverterId();
-
- final String formatText = "<form><p><b>{0}</b> {1}</p> <p><b>{2}</b> {3}</p></form>"; //$NON-NLS-1$
- Object[] bindings = new String[4];
- bindings[0] = Messages.ConverterDetailsForm_Class;
- bindings[1] = className == null ? "" : className; //$NON-NLS-1$
- bindings[2] = Messages.ConverterDetailsForm_Converterid;
- bindings[3] = converterId == null ? "" : converterId; //$NON-NLS-1$
- String text = NLS.bind(formatText, bindings);
- _converterTypeSection.setText(text, true, false);
-
- _converterTypeSection.refresh();
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/GenerateMetadataAction.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/GenerateMetadataAction.java
deleted file mode 100644
index 4374873e1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/GenerateMetadataAction.java
+++ /dev/null
@@ -1,100 +0,0 @@
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.io.IOException;
-import java.util.Collection;
-
-import org.eclipse.jface.action.Action;
-import org.eclipse.jst.jsf.common.runtime.internal.model.types.ClassTypeInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IComponentTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IConverterTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.ITagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IValidatorTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.Namespace;
-import org.eclipse.jst.jsf.designtime.internal.view.mapping.ViewMetadataGenerator;
-
-/**
- * @author cbateman
- *
- */
-class GenerateMetadataAction extends Action
-{
- private Namespace _ns;
-
- public GenerateMetadataAction()
- {
- super("Generate metadata"); //$NON-NLS-1$
- }
-
- public void setNamespace(final Namespace ns)
- {
- _ns = ns;
- }
-
- @Override
- public void run()
- {
- if (_ns != null)
- {
- // create resource set and resource
- final ViewMetadataGenerator generator = new ViewMetadataGenerator(_ns
- .getNSUri());
- for (final ITagElement element : (Collection<? extends ITagElement>) _ns
- .getViewElements())
- {
- final String tagName = element.getName();
- final ClassTypeInfo typeInfo = getTypeInfo(element);
- if (typeInfo != null)
- {
- generator.addTagToViewObjectMapping(tagName, typeInfo, null, null);
- }
- }
-
- try
- {
- generator.save(System.out);
- }
- catch (final IOException e)
- {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- // final IProject project = (IProject) _viewer.getInput();
- // final ITaglibDomainMetaDataModelContext modelContext =
- // TaglibDomainMetaDataQueryHelper.createMetaDataModelContext(project,
- // "http://java.sun.com/jsf/html");
- // final Entity entity = TaglibDomainMetaDataQueryHelper.getEntity(
- // modelContext, "outputText");
- // if (entity != null)
- // {
- // final Trait trait = TaglibDomainMetaDataQueryHelper.getTrait(
- // entity, "viewElementMapping");
- // if (trait != null)
- // {
- // final TagToViewObjectMapping tagConstraint =
- // (TagToViewObjectMapping) trait.getValue();
- // System.err.println(tagConstraint.toString());
- // }
- // }
-
- }
- }
-
- private ClassTypeInfo getTypeInfo(final ITagElement element)
- {
- ClassTypeInfo typeInfo = null;
- if (element instanceof IComponentTagElement)
- {
- typeInfo = ((IComponentTagElement) element).getComponent();
- }
- else if (element instanceof IConverterTagElement)
- {
- typeInfo = ((IConverterTagElement) element).getConverter();
- }
- else if (element instanceof IValidatorTagElement)
- {
- typeInfo = ((IValidatorTagElement) element).getValidator();
- }
-
- return typeInfo;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/Messages.java
deleted file mode 100644
index 085209379..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/Messages.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler
- *
- */
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.tagregistry.messages"; //$NON-NLS-1$
- /**
- * see message.properties
- */
- public static String ComponentDetailSubForm_InterfaceInfo;
- /**
- * see message.properties
- */
- public static String ComponentDetailSubForm_TypeInfo;
- /**
- * see message.properties
- */
- public static String ConverterDetailsForm_Class;
- /**
- * see message.properties
- */
- public static String ConverterDetailsForm_Converterid;
- /**
- * see message.properties
- */
- public static String ConverterDetailsForm_ConverterInfo;
- /**
- * see message.properties
- */
- public static String NamespaceDetailsForm_SectionLabel;
- /**
- * see message.properties
- */
- public static String NamespaceDetailsForm_SectionText;
- /**
- * see message.properties
- */
- public static String TaglibContentProvider_Calculating;
- /**
- * see message.properties
- */
- public static String TaglibContentProvider_JobDesc;
- /**
- * see message.properties
- */
- public static String TaglibContentProvider_NamespaceErrorDescription;
- /**
- * see message.properties
- */
- public static String TaglibContentProvider_NamespaceErrorTitle;
- /**
- * see message.properties
- */
- public static String TaglibContentProvider_TagCalculatingWaitMessage;
- /**
- * see message.properties
- */
- public static String TagRegistryDetailsForm_SectionText;
- /**
- * see message.properties
- */
- public static String TagRegistryDetailsForm_Namespace;
- /**
- * see message.properties
- */
- public static String TagRegistryMasterForm_FlushCacheMessage;
- /**
- * see message.properties
- */
- public static String TagRegistryMasterForm_FlushCacheQuestion;
- /**
- * see message.properties
- */
- public static String TagRegistryMasterForm_Project;
- /**
- * see message.properties
- */
- public static String TagRegistryMasterForm_RefreshRegistry;
- /**
- * see message.properties
- */
- public static String ValidatorDetailsForm_SectionLabel;
- /**
- * see message.properties
- */
- public static String ValidatorDetailsForm_SectionText;
-
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/NamespaceDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/NamespaceDetailsForm.java
deleted file mode 100644
index a53b31c09..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/NamespaceDetailsForm.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.Namespace;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.widgets.Composite;
-
-
-/**
- * Details form for a namespace
- *
- * @author cbateman
- *
- */
-public class NamespaceDetailsForm extends AbstractXMLSectionsDetailsForm
-{
- private final static String NAMESPACE_SECTION_KEY = "namespaceSection"; //$NON-NLS-1$
- private XMLTextSection _namespaceSection;
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _namespaceSection = new XMLTextSection(getToolkit(), parent, Messages.NamespaceDetailsForm_SectionLabel);
- sections.put(NAMESPACE_SECTION_KEY, _namespaceSection);
- return sections;
- }
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_namespaceSection);
- }
-
- @Override
- protected void doUpdateSelection(Object newSelection)
- {
- if (newSelection instanceof Namespace)
-
- {
- Namespace namespace = (Namespace) newSelection;
-
- final String displayName = namespace.getDisplayName();
- final String uri = namespace.getNSUri();
-
- String namespaceSectionText = NLS.bind(Messages.NamespaceDetailsForm_SectionText, displayName == null ? "" : displayName, uri == null ? "" : uri ); //$NON-NLS-1$ //$NON-NLS-2$
-
- _namespaceSection.setText(namespaceSectionText, true, false);
- _namespaceSection.refresh();
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ProjectTracker.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ProjectTracker.java
deleted file mode 100644
index ea2f5b816..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ProjectTracker.java
+++ /dev/null
@@ -1,207 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.HashSet;
-import java.util.Set;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.jst.jsf.common.internal.resource.IResourceLifecycleListener;
-import org.eclipse.jst.jsf.common.internal.resource.LifecycleListener;
-import org.eclipse.jst.jsf.common.internal.resource.ResourceLifecycleEvent;
-import org.eclipse.jst.jsf.common.internal.resource.ResourceLifecycleEvent.EventType;
-import org.eclipse.jst.jsf.common.internal.resource.ResourceLifecycleEvent.ReasonType;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.ProjectTracker.ProjectTrackingListener.Reason;
-
-/**
- * Tracks the active JSF projects in the workspace, maintaining a list of valid
- * projects and firing events when it changes
- *
- * @author cbateman
- *
- */
-class ProjectTracker
-{
- private final IWorkspaceRoot _root;
- private final LifecycleListener _lifecycleListener;
- private final CopyOnWriteArrayList<ProjectTrackingListener> _myListeners;
- private Set<IProject> _validProjects;
- private final ResourceChangeListener _resourceChangeListener;
- private ProjectAdvisor _projectAdvisor;
-
- public ProjectTracker(final IWorkspaceRoot root, final ProjectAdvisor projectAdvisor)
- {
- _root = root;
- _lifecycleListener = new LifecycleListener();
- _resourceChangeListener = new ResourceChangeListener();
- _myListeners = new CopyOnWriteArrayList<ProjectTrackingListener>();
- if (projectAdvisor != null)
- {
- _projectAdvisor = projectAdvisor;
- }
- else
- {
- _projectAdvisor = DEFAULT_ADVISOR;
- }
- }
-
- public void startTracking()
- {
- _lifecycleListener.addResource(_root);
-
- _validProjects = new HashSet<IProject>();
-
- for (final IProject project : _root.getProjects())
- {
- if (_projectAdvisor.shouldTrack(project))
- {
- _validProjects.add(project);
- _lifecycleListener.addResource(project);
- }
- }
- // do this last, to ensure that any "simulataneous" events are handled
- // by our listener only after everything is initialized.
- _lifecycleListener.addListener(_resourceChangeListener);
- }
-
- public Set<IProject> getProjects()
- {
- final Set<IProject> projects = new HashSet<IProject>();
- synchronized (this)
- {
- projects.addAll(_validProjects);
- }
- return projects;
- }
-
- private synchronized void addProject(final IProject project)
- {
- if (_projectAdvisor.shouldTrack(project))
- {
- synchronized (this)
- {
- _validProjects.add(project);
- _lifecycleListener.addResource(project);
- }
- fireChangeEvent(project, Reason.ADDED);
- }
- }
-
- private void removeProject(final IProject project)
- {
- synchronized (this)
- {
- _validProjects.remove(project);
- _lifecycleListener.removeResource(project);
- }
- fireChangeEvent(project, Reason.REMOVED);
- }
-
- public void addListener(ProjectTrackingListener listener)
- {
- _myListeners.addIfAbsent(listener);
- }
-
- public void removeListener(ProjectTrackingListener listener)
- {
- _myListeners.remove(listener);
- }
-
- private void fireChangeEvent(final IProject project,
- ProjectTrackingListener.Reason reason)
- {
- for (final ProjectTrackingListener listener : _myListeners)
- {
- listener.projectsChanged(project, reason);
- }
- }
-
- public void dispose()
- {
- _lifecycleListener.dispose();
- _validProjects.clear();
- _myListeners.clear();
- }
-
- private class ResourceChangeListener implements IResourceLifecycleListener
- {
- public EventResult acceptEvent(final ResourceLifecycleEvent event)
- {
- final IResource res = event.getAffectedResource();
-
- // only interested if is affecting one of my resources
-
- // if the root is the source, check if a projected has been added
- // or opened
- // EventType eventType = event.getEventType();
- if (event.getEventType() == EventType.RESOURCE_ADDED
- && event.getReasonType() == ReasonType.PROJECT_OPENED
- && res instanceof IProject)
- {
- handleNewProject((IProject) res);
- }
- else if (_validProjects.contains(res)
- && event.getEventType() == EventType.RESOURCE_INACCESSIBLE)
- {
- handleProjectClosed((IProject) res);
- }
- return EventResult.getDefaultEventResult();
- }
-
- private void handleNewProject(final IProject project)
- {
- addProject(project);
- }
-
- private void handleProjectClosed(final IProject project)
- {
- removeProject(project);
- }
- }
-
- public static class ProjectTrackingListener
- {
- public enum Reason
- {
- /**
- * Reason for change is a project added
- */
- ADDED,
- /**
- * Reason for change is a project removed
- */
- REMOVED
- }
-
- protected void projectsChanged(final IProject project, Reason reason)
- {
- // do nothing by default
- }
- }
-
- private static final ProjectAdvisor DEFAULT_ADVISOR = new ProjectAdvisor()
- {
- @Override
- public boolean shouldTrack(
- IProject project)
- {
- return true;
- }
- };
-
- public abstract static class ProjectAdvisor
- {
- public abstract boolean shouldTrack(final IProject project);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/SetInputRunnable.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/SetInputRunnable.java
deleted file mode 100644
index 251e11e81..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/SetInputRunnable.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-/**
- *
- */
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.ui.PlatformUI;
-
-class SetInputRunnable implements Runnable
-{
- private final Viewer _viewer;
- private final IProject _project;
-
- public SetInputRunnable(IProject project, Viewer viewer)
- {
- super();
- _project = project;
- _viewer = viewer;
- }
-
- public void run()
- {
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable()
- {
- public void run()
- {
- _viewer.setInput(_project);
- }
- });
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryDetailsForm.java
deleted file mode 100644
index 851a05db5..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryDetailsForm.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.core.runtime.content.IContentType;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.jst.jsf.core.internal.TagRegistryFactoryInfo;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.TaglibContentProvider.TagRegistryInstance;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Details form for a tag registry
- *
- * @author cbateman
- *
- */
-public class TagRegistryDetailsForm extends AbstractXMLSectionsDetailsForm
-{
- private final static String TAGREGISTRY_SECTION_KEY = "tagRegistrySection"; //$NON-NLS-1$
- private XMLTextSection _tagRegistrySection;
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(
- final Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _tagRegistrySection = new XMLTextSection(getToolkit(), parent,
- Messages.TagRegistryDetailsForm_Namespace);
- sections.put(TAGREGISTRY_SECTION_KEY, _tagRegistrySection);
- return sections;
- }
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- final Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_tagRegistrySection);
- }
-
- @Override
- protected void doUpdateSelection(final Object newSelection)
- {
- if (newSelection instanceof TagRegistryInstance)
- {
- final TagRegistryInstance tagRegistry = (TagRegistryInstance) newSelection;
- final TagRegistryFactoryInfo info = tagRegistry.getInfo();
-
- if (info != null)
- {
- final String description = info.getDescription();
- final String id = info.getId();
- final Set<IContentType> contentTypes = info.getContentTypes();
- String contentTypeLabel = ""; //$NON-NLS-1$
- final Iterator<IContentType> it = contentTypes.iterator();
- for (int i = 0; i < contentTypes.size() - 1 && it.hasNext(); i++)
- {
- final IContentType ctype = it.next();
- contentTypeLabel += ctype.getName() + ","; //$NON-NLS-1$
- }
-
- if (it.hasNext())
- {
- final IContentType ctype = it.next();
- contentTypeLabel += ctype.getName();
- }
-
- String[] bindings = new String[3];
- bindings[0] = description;
- bindings[1] = id;
- bindings[2] = contentTypeLabel;
- String text = NLS.bind(Messages.TagRegistryDetailsForm_SectionText, bindings);
- _tagRegistrySection.setText(text, true, false);
-
- _tagRegistrySection.refresh();
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterDetailBlock.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterDetailBlock.java
deleted file mode 100644
index 3b91c75d9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterDetailBlock.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IComponentTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IConverterTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IValidatorTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.Namespace;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractDetailsForm;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterDetailBlock;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterForm;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.TaglibContentProvider.TagRegistryInstance;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-
-/**
- * A master-detail block for selecting items in a tag registry and examining
- * their details.
- *
- * @author cbateman
- *
- */
-public class TagRegistryMasterDetailBlock extends AbstractMasterDetailBlock
-{
- ComponentDetailSubForm _componentDetails;
- TagRegistryDetailsForm _tagRegistryDetails;
- NamespaceDetailsForm _namespaceDetails;
- ConverterDetailsForm _converterDetails;
- ValidatorDetailsForm _validatorDetails;
-
-
- @Override
- protected AbstractMasterForm createMasterPart(final FormToolkit toolkit)
- {
- return new TagRegistryMasterForm(toolkit);
- }
-
-
- @Override
- protected final List<AbstractDetailsForm> createDetailPages()
- {
- final List<AbstractDetailsForm> detailForms = new ArrayList<AbstractDetailsForm>();
- _componentDetails = new ComponentDetailSubForm();
- detailForms.add(_componentDetails);
-
- _tagRegistryDetails = new TagRegistryDetailsForm();
- detailForms.add(_tagRegistryDetails);
-
- _namespaceDetails = new NamespaceDetailsForm();
- detailForms.add(_namespaceDetails);
-
- _converterDetails = new ConverterDetailsForm();
- detailForms.add(_converterDetails);
-
- _validatorDetails = new ValidatorDetailsForm();
- detailForms.add(_validatorDetails);
-
- return detailForms;
- }
-
-
- @Override
- protected AbstractXMLSectionsDetailsForm doSelectPage(final Object forModel)
- {
- if (forModel instanceof IComponentTagElement)
- {
- return _componentDetails;
- }
- else if (forModel instanceof IConverterTagElement)
- {
- return _converterDetails;
- }
- else if (forModel instanceof IValidatorTagElement)
- {
- return _validatorDetails;
- }
- else if (forModel instanceof TagRegistryInstance)
- {
- return _tagRegistryDetails;
- }
- else if (forModel instanceof Namespace)
- {
- return _namespaceDetails;
- }
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterForm.java
deleted file mode 100644
index 50a792089..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryMasterForm.java
+++ /dev/null
@@ -1,501 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Set;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.action.Action;
-import org.eclipse.jface.action.IMenuListener;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.ComboViewer;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IComponentTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IConverterTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.ITagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IValidatorTagElement;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.Namespace;
-import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractMasterForm;
-import org.eclipse.jst.jsf.common.ui.internal.utils.JSFSharedImages;
-import org.eclipse.jst.jsf.core.jsfappconfig.JSFAppConfigUtils;
-import org.eclipse.jst.jsf.designtime.internal.view.model.ITagRegistry;
-import org.eclipse.jst.jsf.ui.internal.JSFUITraceOptions;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.ProjectTracker.ProjectAdvisor;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.ProjectTracker.ProjectTrackingListener;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.TaglibContentProvider.TagRegistryInstance;
-import org.eclipse.jst.jsf.ui.internal.tagregistry.TaglibContentProvider.TreePlaceholder;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.model.BaseWorkbenchContentProvider;
-import org.eclipse.ui.model.IWorkbenchAdapter;
-import org.eclipse.ui.model.WorkbenchAdapter;
-import org.eclipse.ui.model.WorkbenchViewerComparator;
-
-/**
- * The master form in the master/detail block for tag registry. Used to display
- * a tree view of each tag registy on the currently selected project and its
- * contents.
- *
- * @author cbateman
- *
- */
-public class TagRegistryMasterForm extends AbstractMasterForm
-{
- private static final String REFRESH_NAV_IMAGE_FILE = "refresh_nav_16.gif"; //$NON-NLS-1$
-
- private TreeViewer _registryTreeViewer;
- // private Action _selectProjectAction;
- private Action _refreshAction;
-
- private final ProjectTracker _projectTracker;
- private final ProjectAdvisor _advisor;
- private GenerateMetadataAction _generateMetadataAction;
-
- /**
- * @param toolkit
- */
- public TagRegistryMasterForm(final FormToolkit toolkit)
- {
- super(toolkit);
- _advisor = new ProjectAdvisor()
- {
- @Override
- public boolean shouldTrack(final IProject project)
- {
- return JSFAppConfigUtils.isValidJSFProject(project);
- }
- };
-
- _projectTracker = new ProjectTracker(ResourcesPlugin.getWorkspace()
- .getRoot(), _advisor);
- }
-
- /**
- * @param parent
- * @return the contents main control
- */
- @Override
- public Control createClientArea(final Composite parent)
- {
- final Tree tree = getToolkit().createTree(parent,
- SWT.SINGLE | SWT.H_SCROLL | SWT.V_SCROLL);
-
- final GridData gridData = new GridData(SWT.FILL, SWT.CENTER, true, true);
- tree.setLayoutData(gridData);
- _registryTreeViewer = new TreeViewer(tree);
- // _drillDownAdapter = new DrillDownAdapter(_viewer);
- _registryTreeViewer.setContentProvider(new TaglibContentProvider());
- _registryTreeViewer.setLabelProvider(new CommonLabelProvider());
- _registryTreeViewer.setSorter(new NameSorter());
-
- PlatformUI.getWorkbench().getHelpSystem()
- .setHelp(_registryTreeViewer.getControl(),
- "ViewHandlerPrototype.viewer"); //$NON-NLS-1$
-
- _projectTracker.addListener(new ProjectTrackingListener()
- {
- @Override
- protected void projectsChanged(final IProject project,
- final Reason reason)
- {
- switch (reason)
- {
- case ADDED:
- {
- // nothing to do, since new project can't be selected
- // yet
- }
- case REMOVED:
- {
- // if the removed project is the one that is current
- // update the treeviewer
- if (project.equals(_registryTreeViewer.getInput()))
- {
- updateProjects();
- }
- }
- }
- }
- });
-
- _registryTreeViewer
- .addSelectionChangedListener(new ISelectionChangedListener()
- {
-
- public void selectionChanged(
- final SelectionChangedEvent event)
- {
- getListener().selectionChanged(event);
- updateActions(event.getSelection());
- }
- });
- makeActions();
- createContextMenuManager(_registryTreeViewer.getControl());
- return tree;
- }
-
- /**
- * dispose of the master form
- */
- @Override
- public void dispose()
- {
- _projectTracker.dispose();
- }
-
- private void updateProjects()
- {
- final Set<IProject> projects = _projectTracker.getProjects();
-
- for (final IProject project : projects)
- {
- new SetInputRunnable(project, _registryTreeViewer).run();
- break;
- }
- }
-
- @Override
- protected final void contributeActions(IToolBarManager formManager,
- IToolBarManager localManager)
- {
- // do nothing to the manager; we have our own toolbar
-
- // contribute to local tool bar
- localManager.add(_refreshAction);
- localManager.update(false);
- }
-
- /**
- */
- @Override
- protected void contributeToHeadArea(final FormToolkit toolkit,
- final Composite container)
- {
- final Label label = new Label(container, SWT.NONE);
- label.setText(Messages.TagRegistryMasterForm_Project);
- final ComboViewer combo = new ComboViewer(container, SWT.FLAT
- | SWT.READ_ONLY);
- getToolkit().adapt(combo.getControl(), true, false);
- combo.addSelectionChangedListener(new ISelectionChangedListener()
- {
- public void selectionChanged(SelectionChangedEvent event)
- {
- IStructuredSelection selection = (IStructuredSelection) event
- .getSelection();
-
- final IProject selectedProject = (IProject) selection
- .getFirstElement();
- _registryTreeViewer.setInput(selectedProject);
- }
- });
- combo.setLabelProvider(new CommonLabelProvider());
- combo.setContentProvider(new ProjectContentProvider());
- combo.setComparator(new WorkbenchViewerComparator());
- combo.setInput(_projectTracker);
- _projectTracker.addListener(new ProjectTrackingListener()
- {
- @Override
- protected void projectsChanged(IProject project, Reason reason)
- {
- combo.getControl().getDisplay().asyncExec(new Runnable()
- {
- public void run()
- {
- combo.refresh();
- }
- });
- }
- });
- }
-
- /**
- */
- @Override
- public void doInitialize()
- {
- _projectTracker.startTracking();
- }
-
- private void makeActions()
- {
- if (_registryTreeViewer == null)
- {
- throw new IllegalStateException(
- "_registryTreeViewer must be initialized before calling makeActions"); //$NON-NLS-1$
- }
- _refreshAction = new RefreshAction(_registryTreeViewer);
- _refreshAction.setText(Messages.TagRegistryMasterForm_RefreshRegistry);
- _refreshAction.setToolTipText(Messages.TagRegistryMasterForm_RefreshRegistry);
- _refreshAction.setImageDescriptor(JSFUICommonPlugin.getDefault()
- .getImageDescriptor(REFRESH_NAV_IMAGE_FILE));
-
- if (JSFUITraceOptions.TRACE_METADATAGEN)
- {
- _generateMetadataAction = new GenerateMetadataAction();
- }
- }
-
- private void createContextMenuManager(final Control control)
- {
- // Create menu manager.
- MenuManager menuMgr = new MenuManager();
- menuMgr.setRemoveAllWhenShown(true);
- menuMgr.addMenuListener(new IMenuListener() {
- public void menuAboutToShow(IMenuManager mgr) {
- fillContextMenu(mgr);
- }
- });
-
- // Create menu.
- Menu menu = menuMgr.createContextMenu(control);
- control.setMenu(menu);
-
- // Register menu for extension.
- //getSite().registerContextMenu(menuMgr, viewer);
- }
-
- private void fillContextMenu(IMenuManager mgr)
- {
- if (JSFUITraceOptions.TRACE_METADATAGEN)
- {
- mgr.add(_generateMetadataAction);
- }
- }
-
- private void updateActions(final ISelection selection)
- {
- if (JSFUITraceOptions.TRACE_METADATAGEN)
- {
- updateMetadataGenAction(selection);
- }
- }
-
- private void updateMetadataGenAction(final ISelection selection)
- {
- if (selection instanceof IStructuredSelection)
- {
- if (((IStructuredSelection)selection).getFirstElement() instanceof Namespace)
- {
- Namespace ns = (Namespace) ((IStructuredSelection)selection).getFirstElement();
- _generateMetadataAction.setNamespace(ns);
- _generateMetadataAction.setEnabled(true);
- return;
- }
- }
- _generateMetadataAction.setEnabled(false);
- }
-
- private static class RefreshAction extends Action
- {
- private final StructuredViewer _viewer;
-
- /**
- * @param viewer
- */
- private RefreshAction(final StructuredViewer viewer)
- {
- super();
- _viewer = viewer;
- setEnabled(false);
- _viewer.addSelectionChangedListener(new ISelectionChangedListener()
- {
- public void selectionChanged(SelectionChangedEvent event)
- {
- boolean enabled = false;
- final Object selectedObj = getSelected(event.getSelection());
- if (selectedObj instanceof TagRegistryInstance)
- {
- enabled = true;
- }
- setEnabled(enabled);
- }
- });
- }
-
- @Override
- public void run()
- {
- MessageDialog dialog = new MessageDialog(_viewer.getControl().getShell(), Messages.TagRegistryMasterForm_FlushCacheQuestion, null, // accept
- // the
- // default
- // window
- // icon
- Messages.TagRegistryMasterForm_FlushCacheMessage
- , MessageDialog.QUESTION, new String[] { IDialogConstants.YES_LABEL,
- IDialogConstants.NO_LABEL }, 1); // no is the
- // default
- final boolean flushCaches = (dialog.open() == 0);
- final Object selectedObj = getSelected(_viewer.getSelection());
-
- if (selectedObj instanceof TagRegistryInstance)
- {
- final TagRegistryInstance registryInstance = (TagRegistryInstance) selectedObj;
- final ITagRegistry registry = registryInstance.getRegistry();
- if (registry != null)
- {
- // need a non-null runnable so that refresh won't block,
- // but don't need to fire events, since the registry will
- // fire events on change.
- final Runnable nullRunnable = new Runnable()
- {
- public void run()
- {/* do nothing */
- }
- };
-
- registry.refresh(nullRunnable, flushCaches);
- }
- }
- }
-
- private Object getSelected(ISelection selection)
- {
- if (selection instanceof IStructuredSelection)
- {
- final IStructuredSelection structuredSel = (IStructuredSelection) selection;
- if (structuredSel.size() == 1)
- {
- return structuredSel.getFirstElement();
- }
- }
- return null;
- }
- }
-
- private static class ProjectContentProvider extends
- BaseWorkbenchContentProvider
- {
- @Override
- protected IWorkbenchAdapter getAdapter(final Object element)
- {
- return new WorkbenchAdapter()
- {
- @Override
- public Object[] getChildren(final Object object)
- {
- if (object instanceof ProjectTracker)
- {
- return ((ProjectTracker) object).getProjects()
- .toArray();
- }
- return new Object[0];
- }
- };
- }
- }
-
- private static class CommonLabelProvider extends LabelProvider
- {
- private static final String CONFIGS_IMAGE_FILE = "configs.gif"; //$NON-NLS-1$
-
- @Override
- public String getText(final Object obj)
- {
- if (obj instanceof TagRegistryInstance)
- {
- return ((TagRegistryInstance) obj).getInfo().getDescription();
- }
- else if (obj instanceof Namespace)
- {
- if (((Namespace) obj).getDisplayName() != null)
- {
- return ((Namespace) obj).getDisplayName();
- }
- return ((Namespace) obj).getNSUri();
- }
- else if (obj instanceof ITagElement)
- {
- return ((ITagElement) obj).getName();
- }
- else if (obj instanceof TreePlaceholder)
- {
- return ((TreePlaceholder) obj).getText();
- }
- else if (obj instanceof IProject)
- {
- return ((IProject) obj).getName();
- }
- return obj.toString();
- }
-
- @Override
- public Image getImage(final Object obj)
- {
- if (obj instanceof Namespace)
- {
- return JavaUI.getSharedImages().getImage(
- org.eclipse.jdt.ui.ISharedImages.IMG_OBJS_LIBRARY);
- }
- else if (obj instanceof TagRegistryInstance)
- {
- final String imageKey = ISharedImages.IMG_OBJ_FOLDER;
- return PlatformUI.getWorkbench().getSharedImages().getImage(
- imageKey);
- }
- else if (obj instanceof ITagElement)
- {
- if (obj instanceof IComponentTagElement)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_OBJECT_IMG);
- }
- else if (obj instanceof IConverterTagElement)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_CONVERTER_IMG);
- }
- else if (obj instanceof IValidatorTagElement)
- {
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.GENERIC_VALIDATOR_IMG);
- }
- return JSFUICommonPlugin.getDefault().getImage(
- JSFSharedImages.DEFAULT_PALETTE_TAG_IMG);
- }
- else if (obj instanceof TreePlaceholder)
- {
- return JSFUICommonPlugin.getDefault().getImage(CONFIGS_IMAGE_FILE);
- }
-
- final String imageKey = ISharedImages.IMG_OBJ_ELEMENT;
- return PlatformUI.getWorkbench().getSharedImages().getImage(
- imageKey);
- }
- }
-
- class NameSorter extends ViewerSorter
- {
- // do nothing
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryView.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryView.java
deleted file mode 100644
index 83d733990..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TagRegistryView.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.forms.widgets.Form;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.part.ViewPart;
-
-/**
- * This sample class demonstrates how to plug-in a new workbench view. The view
- * shows data obtained from the model. The sample creates a dummy model on the
- * fly, but a real implementation would connect to the model available either in
- * this or another plug-in (e.g. the workspace). The view is connected to the
- * model using a content provider.
- * <p>
- * The view uses a label provider to define how model objects should be
- * presented in the view. Each view can present the same model objects using
- * different labels and icons, if needed. Alternatively, a single label provider
- * can be shared between views in order to ensure that objects of the same type
- * are presented in the same way everywhere.
- * <p>
- */
-
-public class TagRegistryView extends ViewPart
-{
- private static final String LIBRARY_OBJ_IMAGE_FILE = "obj16/library_obj.gif"; //$NON-NLS-1$
- private FormToolkit _toolkit;
- private Form _form;
- private TagRegistryMasterDetailBlock _masterDetailBlock;
-
- /**
- * The constructor.
- */
- public TagRegistryView()
- {
- // do nothing
- }
-
- @Override
- public void init(IViewSite site) throws PartInitException
- {
- super.init(site);
- setTitleImage(JSFUiPlugin.getDefault().getImage(LIBRARY_OBJ_IMAGE_FILE));
- }
-
- /**
- * This is a callback that will allow us to create the viewer and initialize
- * it.
- */
- @Override
- public void createPartControl(final Composite parent)
- {
- _toolkit = new FormToolkit(parent.getDisplay());
-
- _form = _toolkit.createForm(parent);
- _form.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true,true));
- _masterDetailBlock =
- new TagRegistryMasterDetailBlock();
- _masterDetailBlock.createContent(_toolkit,_form);
- }
-
-
-
- @Override
- public void dispose()
- {
- if (_masterDetailBlock != null)
- {
- _masterDetailBlock.dispose();
- _masterDetailBlock = null;
- }
- super.dispose();
- }
-
- /**
- * Passing the focus request to the viewer's control.
- */
- @Override
- public void setFocus()
- {
- _form.setFocus();
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TaglibContentProvider.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TaglibContentProvider.java
deleted file mode 100644
index 8cf53203f..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/TaglibContentProvider.java
+++ /dev/null
@@ -1,451 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.atomic.AtomicLong;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.IStructuredContentProvider;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.StructuredViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.Namespace;
-import org.eclipse.jst.jsf.core.internal.CompositeTagRegistryFactory;
-import org.eclipse.jst.jsf.core.internal.TagRegistryFactoryInfo;
-import org.eclipse.jst.jsf.designtime.internal.view.model.ITagRegistry;
-import org.eclipse.jst.jsf.designtime.internal.view.model.TagRegistryFactory;
-import org.eclipse.jst.jsf.designtime.internal.view.model.ITagRegistry.TagRegistryChangeEvent;
-import org.eclipse.jst.jsf.designtime.internal.view.model.ITagRegistry.TagRegistryChangeEvent.EventType;
-import org.eclipse.jst.jsf.designtime.internal.view.model.TagRegistryFactory.TagRegistryFactoryException;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Structured content provider for tag libraries.
- *
- * @author cbateman
- *
- */
-public class TaglibContentProvider implements IStructuredContentProvider,
- ITreeContentProvider, ITagRegistry.ITagRegistryListener
-{
- private final static Object[] NO_CHILDREN = new Object[0];
- private IProject _curInput;
- private Map<ITagRegistry, TagRegistryInstance> _curTagRegistries =
- new HashMap<ITagRegistry, TagRegistryInstance>();
- private Viewer _curViewer;
- private final AtomicLong _changeStamp = new AtomicLong(
- 0);
-
- public Object[] getElements(final Object inputElement)
- {
-
- if (inputElement instanceof IProject)
- {
- return _curTagRegistries.values().toArray();
- // return _rootNamespaces.values().toArray();
- }
-
- return NO_CHILDREN;
- }
-
- public void dispose()
- {
- // nothing to do
- }
-
- public void inputChanged(final Viewer viewer, final Object oldInput,
- final Object newInput)
- {
- // update our change stamp to invalid outstanding update tasks
- _changeStamp.incrementAndGet();
- _curViewer = viewer;
-
- if (oldInput instanceof IProject)
- {
- for (final TagRegistryInstance tagRegistry : _curTagRegistries.values())
- {
- tagRegistry.getRegistry().removeListener(this);
- }
- }
-
- if (newInput instanceof IProject)
- {
- _curInput = (IProject) newInput;
-
- final Set<TagRegistryFactoryInfo> factories = CompositeTagRegistryFactory
- .getInstance().getAllTagRegistryFactories();
-
- _curTagRegistries.clear();
-
- for (TagRegistryFactoryInfo factoryInfo : factories)
- {
- TagRegistryFactory factory = factoryInfo
- .getTagRegistryFactory();
- ITagRegistry registry;
- try
- {
- registry = factory.createTagRegistry(_curInput);
- if (registry != null)
- {
- final TagRegistryInstance registryInstance =
- new TagRegistryInstance(factoryInfo, registry);
- _curTagRegistries.put(registry, registryInstance);
- registry.addListener(this);
-
- new UpdateNamespacesListJob(_curInput, _changeStamp.get(),
- registryInstance).schedule();
- }
- }
- catch (TagRegistryFactoryException e)
- {
- JSFUiPlugin.log(IStatus.ERROR,
- "Problem getting tag registry", e); //$NON-NLS-1$
- }
- }
- }
- else
- {
- _curInput = null;
- _curTagRegistries.clear();
- }
- }
-
- public Object[] getChildren(final Object parentElement)
- {
- if (parentElement instanceof IProject)
- {
- return _curTagRegistries.values().toArray();
- }
- else if (parentElement instanceof TagRegistryInstance)
- {
- final TagRegistryInstance regInstance = (TagRegistryInstance) parentElement;
-
- if (!regInstance.isUpToDate())
- {
- return new Object[] {new TreePlaceholder(Messages.TaglibContentProvider_Calculating, null)};
- }
- return regInstance.getNamespaces().values().toArray();
- }
- else if (parentElement instanceof Namespace)
- {
- final Namespace ns = (Namespace) parentElement;
-
- // this could be very expensive if not initialized
- if (ns.isInitialized())
- {
- return ((Namespace) parentElement).getViewElements().toArray();
- }
-
- // fire up a job that ensures the namespace is initialized
- // and then fires refresh again on this element
- final Job updateNamespaceJob = new Job(Messages.TaglibContentProvider_JobDesc)
- {
- @Override
- protected IStatus run(final IProgressMonitor monitor)
- {
- ns.getViewElements();
- PlatformUI.getWorkbench().getDisplay().asyncExec(
- new Runnable()
- {
- public void run()
- {
- // avoid infinite recursion
- if (ns.isInitialized())
- {
- TaglibContentProvider.this
- .viewerRefresh(ns);
- }
- else
- {
- MessageDialog
- .openError(
- Display
- .getCurrent()
- .getActiveShell(),
- Messages.TaglibContentProvider_NamespaceErrorTitle,
- Messages.TaglibContentProvider_NamespaceErrorDescription);
- }
- }
- });
- return Status.OK_STATUS;
- }
- };
-
- updateNamespaceJob.schedule();
-
- return new Object[]
- { new TreePlaceholder(Messages.TaglibContentProvider_TagCalculatingWaitMessage, null) };
- }
-// else if (parentElement instanceof IJSFTagElement)
-// {
-// return new Object[]
-// { ((IJSFTagElement) parentElement).toString() };
-// }
-
- return NO_CHILDREN;
- }
-
- public Object getParent(final Object element)
- {
- // no support for parent traversal right now
- return null;
- }
-
- public boolean hasChildren(final Object element)
- {
- // avoid an infinite refresh loop on the namespaces in the tag registry
- if (element instanceof TagRegistryInstance)
- {
- return true;
- }
- // finding all children of a namespace can be expensive
- else if (element instanceof Namespace)
- {
- return ((Namespace) element).hasViewElements();
- }
- return getChildren(element).length > 0;
- }
-
- public void registryChanged(final TagRegistryChangeEvent changeEvent)
- {
- if (_curViewer != null)
- {
- TagRegistryInstance registryInstance =
- _curTagRegistries.get(changeEvent.getSource());
-
- if (registryInstance != null)
- {
- _curViewer.getControl().getDisplay().asyncExec(
- new RegistryChangeTask(changeEvent.getType(), changeEvent
- .getAffectedObjects(), _changeStamp.get(),registryInstance));
- }
- }
- }
-
- private final class RegistryChangeTask implements Runnable
- {
- private final EventType _eventType;
- private final long _timestamp;
- private final List<? extends Namespace> _affectedObjects;
- private final TagRegistryInstance _registryInstance;
-
- RegistryChangeTask(final TagRegistryChangeEvent.EventType eventType,
- final List<? extends Namespace> affectedObjects,
- final long timestamp, final TagRegistryInstance registryInstance)
- {
- _eventType = eventType;
- _timestamp = timestamp;
- _affectedObjects = affectedObjects;
- _registryInstance = registryInstance;
- }
-
- public void run()
- {
- // if changes have been made since this task was queued, then abort
- // since we don't know if our data is still valid
- if (_timestamp != TaglibContentProvider.this._changeStamp.get())
- {
- return;
- }
-
- switch (_eventType)
- {
- case ADDED_NAMESPACE:
- case CHANGED_NAMESPACE:
- {
- for (final Namespace ns : _affectedObjects)
- {
- _registryInstance.getNamespaces().put(ns.getNSUri(), ns);
- }
-
- viewerRefresh(_curInput);
- }
- break;
-
- case REMOVED_NAMESPACE:
- {
- for (final Namespace ns : _affectedObjects)
- {
- _registryInstance.getNamespaces().remove(ns.getNSUri());
- }
- viewerRefresh(_curInput);
- }
- break;
-
- case REGISTRY_DISPOSED:
- {
- _registryInstance.getRegistry().removeListener(TaglibContentProvider.this);
- _curTagRegistries.remove(_registryInstance);
- viewerRefresh(_curInput);
- }
- }
- }
- }
-
- private void viewerRefresh(final Object parentElement)
- {
- if (_curViewer instanceof StructuredViewer)
- {
- final StructuredViewer viewer = (StructuredViewer) _curViewer;
- viewer.refresh(parentElement);
- }
- else
- {
- _curViewer.refresh();
- }
- }
-
- private class UpdateNamespacesListJob extends Job
- {
-
- private final long _timestamp;
- private final IProject _project;
- private final TagRegistryInstance _registry;
-
- public UpdateNamespacesListJob(final IProject project,
- final long timestamp, final TagRegistryInstance registry)
- {
- super("Updating available namespaces for project " //$NON-NLS-1$
- + project.getName());
- _project = project;
- _timestamp = timestamp;
- _registry = registry;
- }
-
- @Override
- protected IStatus run(final IProgressMonitor monitor)
- {
- if (!_project.isAccessible()
- || _registry.isUpToDate())
- {
- return new Status(IStatus.CANCEL, JSFUiPlugin.PLUGIN_ID, ""); //$NON-NLS-1$
- }
-
- final Collection<? extends Namespace> libs = _registry.getRegistry()
- .getAllTagLibraries();
- _registry.getNamespaces().clear();
-
- for (Namespace ns : libs)
- {
- if (ns.getNSUri() != null)
- {
- _registry.getNamespaces().put(ns.getNSUri(), ns);
-
- }
- }
-
- _registry.setUpToDate(true);
- PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable()
- {
- public void run()
- {
- // only bother if the provider hasn't changed asynchronously
- if (_timestamp == TaglibContentProvider.this._changeStamp
- .get())
- {
- viewerRefresh(_curInput);
- }
- }
- });
-
- return Status.OK_STATUS;
- }
- }
-
- static class TagRegistryInstance
- {
- private final TagRegistryFactoryInfo _info;
- private final ITagRegistry _registry;
- private final Map<String, Namespace> _namespaces;
- private boolean _isUpToDate;
-
- public TagRegistryInstance(final TagRegistryFactoryInfo info,
- ITagRegistry registry)
- {
- _info = info;
- _registry = registry;
- _namespaces = new ConcurrentHashMap<String, Namespace>();
- }
-
- public TagRegistryFactoryInfo getInfo()
- {
- return _info;
- }
-
- public ITagRegistry getRegistry()
- {
- return _registry;
- }
-
- public Map<String, Namespace> getNamespaces()
- {
- return _namespaces;
- }
-
- public synchronized boolean isUpToDate()
- {
- return _isUpToDate;
- }
-
- public synchronized void setUpToDate(boolean isUpToDate)
- {
- _isUpToDate = isUpToDate;
- }
- }
-
- /**
- * Takes the place of a real tree model object while the real object is
- * being retrieved.
- *
- */
- public static class TreePlaceholder
- {
- private final String _text;
- private final Image _image;
-
- TreePlaceholder(final String text, final Image image)
- {
- _text = text;
- _image = image;
- }
-
- /**
- * @return the placeholder text or null if none
- */
- public String getText()
- {
- return _text;
- }
-
- /**
- * @return the image or null if none
- */
- public Image getImage()
- {
- return _image;
- }
-
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ValidatorDetailsForm.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ValidatorDetailsForm.java
deleted file mode 100644
index f6d69aeb8..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/ValidatorDetailsForm.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.tagregistry;
-
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import org.eclipse.jst.jsf.common.runtime.internal.model.decorator.ValidatorTypeInfo;
-import org.eclipse.jst.jsf.common.runtime.internal.view.model.common.IValidatorTagElement;
-import org.eclipse.jst.jsf.common.ui.internal.form.AbstractXMLSectionsDetailsForm;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.widgets.Composite;
-
-/**
- * Details form for validator tags.
- * @author cbateman
- *
- */
-public class ValidatorDetailsForm extends AbstractXMLSectionsDetailsForm
-{
- private final static String VALIDATOR_TYPE_SECTION_KEY = "validatorSection"; //$NON-NLS-1$
- private XMLTextSection _validatorTypeSection;
-
- @Override
- protected Map<? extends Object, XMLTextSection> createXMLTextSections(Composite parent)
- {
- final Map<String, XMLTextSection> sections = new HashMap<String, XMLTextSection>();
- _validatorTypeSection = new XMLTextSection(getToolkit(), parent, Messages.ValidatorDetailsForm_SectionLabel);
- sections.put(VALIDATOR_TYPE_SECTION_KEY, _validatorTypeSection);
- return sections;
- }
-
-
- @Override
- protected Set<XMLTextSection> getInitiallyExpanded(
- Map<Object, XMLTextSection> sections)
- {
- return Collections.singleton(_validatorTypeSection);
- }
-
- @Override
- protected void doUpdateSelection(Object newSelection)
- {
- if (newSelection instanceof IValidatorTagElement)
- {
- IValidatorTagElement validatorTagElement = (IValidatorTagElement) newSelection;
- final ValidatorTypeInfo typeInfo = validatorTagElement.getValidator();
-
- if (typeInfo != null)
- {
- final String className = typeInfo.getClassName();
- final String validatorId = typeInfo.getValidatorId();
-
- String text = NLS.bind(Messages.ValidatorDetailsForm_SectionText, className == null ? "" : className, validatorId == null ? "" : validatorId); //$NON-NLS-1$ //$NON-NLS-2$
- _validatorTypeSection.setText(text, true, false);
-
- _validatorTypeSection.refresh();
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/messages.properties
deleted file mode 100644
index 6ce15e2c4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/tagregistry/messages.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-ComponentDetailSubForm_InterfaceInfo=Interface Information
-ComponentDetailSubForm_TypeInfo=Component Type Information
-ConverterDetailsForm_Class=Class:
-ConverterDetailsForm_Converterid=Converter Id:
-ConverterDetailsForm_ConverterInfo=Converter Type Information
-NamespaceDetailsForm_SectionLabel=Namespace
-NamespaceDetailsForm_SectionText=<form><p><b>Name: </b> {0}</p> <p><b>Uri: </b> {1}</p></form>
-TaglibContentProvider_Calculating=Calculating...
-TaglibContentProvider_JobDesc=Updating namespace
-TaglibContentProvider_NamespaceErrorDescription=There was a problem initializing the namespace
-TaglibContentProvider_NamespaceErrorTitle=Error updating namespace
-TaglibContentProvider_TagCalculatingWaitMessage=Calculating tags, please wait...
-TagRegistryDetailsForm_SectionText=<form><p><b>Description: </b> {0}</p> <p><b>Id: </b> {1}</p> <p><b>Content-Types:</b> {2}</p></form>
-TagRegistryDetailsForm_Namespace=Namespace
-TagRegistryMasterForm_FlushCacheMessage=Flushing cached data may cause some operations to slow until cached information is regenerated. If you answer no, the view will refresh but NOT flush cached data
-TagRegistryMasterForm_FlushCacheQuestion=Also flush cached data?
-TagRegistryMasterForm_Project=Project:
-TagRegistryMasterForm_RefreshRegistry=Refresh Registry
-ValidatorDetailsForm_SectionLabel=Validator Type Information
-ValidatorDetailsForm_SectionText=<form><p><b>Class: </b> {0}</p> <p><b>Validator Id: </b> {1}</p></form>
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ELPrefPanel.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ELPrefPanel.java
deleted file mode 100644
index b81fa6afd..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ELPrefPanel.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Cameron Bateman/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.jsf.core.internal.CompositeJSFPreferenceModel;
-import org.eclipse.jst.jsf.core.internal.IJSFPreferenceModel;
-import org.eclipse.jst.jsf.ui.internal.Messages;
-import org.eclipse.jst.jsf.validation.internal.ValidationPreferences;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.RowLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
-
-/**
- * Creates and manages a panel for configuring
- *
- * @author cbateman
- */
-/*package*/ class ELPrefPanel
-{
- /* view */
- private final Group _container;
- private final Button _chkBuildValidation;
- private final Button _chkIncrementalValidation;
- private final ProblemSeveritiesConfigurationBlock _problemSeverities;
-
- /* model */
- private final ValidationPreferences _prefs;
-
- /**
- * Allocates new container in parent.
- * @param parent
- * @param container
- * @param prefs
- */
- public ELPrefPanel(Composite parent, IWorkbenchPreferenceContainer container, ValidationPreferences prefs)
- {
- _prefs = prefs;
-
- _container = new Group(parent, SWT.NONE);
- _container.setText(Messages.JSFValidationPreferencePage_ELPrefPanel_Title);
- RowLayout rowLayout = new RowLayout(SWT.VERTICAL);
- rowLayout.marginTop = 5;
- rowLayout.marginLeft = 5;
- _container.setLayout(rowLayout);
-
- _chkBuildValidation = new Button(_container, SWT.CHECK);
- _chkBuildValidation.setText(Messages.JSFValidationPreferencePage_ELPrefPanel_BuildValidationCheckBoxTitle);
- _chkBuildValidation.addSelectionListener(new SelectionAdapter()
- {
- public void widgetSelected(SelectionEvent e)
- {
- _prefs.getElPrefs().setEnableBuildValidation(_chkBuildValidation.getSelection());
- refresh();
- }
- });
-
- _chkIncrementalValidation = new Button(_container, SWT.CHECK);
- _chkIncrementalValidation.setText(Messages.JSFValidationPreferencePage_ELPrefPanel_IncrementalValidationCheckBoxTitle);
- _chkIncrementalValidation.addSelectionListener(new SelectionAdapter()
- {
- public void widgetSelected(SelectionEvent e)
- {
- _prefs.getElPrefs().setEnableIncrementalValidation(_chkIncrementalValidation.getSelection());
- refresh();
- }
- });
-
- new Label(_container, SWT.NONE);
-
- final List<IJSFPreferenceModel> models = new ArrayList<IJSFPreferenceModel>();
- models.add(_prefs.getElPrefs());
- models.add(_prefs.getTypeComparatorPrefs());
- final IJSFPreferenceModel compositeModel = new CompositeJSFPreferenceModel(
- models);
-
- _problemSeverities = new ProblemSeveritiesConfigurationBlock(compositeModel, null, container);
- _problemSeverities.createContents(_container);
- }
-
- /**
- * @return the top-level container managed by this panel
- */
- public Control getControl()
- {
- return _container;
- }
-
-
- /**
- * Refreshes the UI from the model
- */
- public void refresh()
- {
- _chkBuildValidation.setSelection(_prefs.getElPrefs().isEnableBuildValidation());
- _chkIncrementalValidation.
- setSelection(_prefs.getElPrefs().isEnableIncrementalValidation());
- _problemSeverities.updateControls();
- }
-
- /**
- *
- */
- public void processChanges() {
- _problemSeverities.performOk();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidationPreferencePage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidationPreferencePage.java
deleted file mode 100644
index 4200f7935..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidationPreferencePage.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Cameron Bateman/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.PreferencePage;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.jst.jsf.validation.internal.ValidationPreferences;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
-
-/**
- * Workbench preference page for configuring JSF validation
- *
- * @author cbateman
- *
- */
-public class JSFValidationPreferencePage extends PreferencePage implements
- IWorkbenchPreferencePage
-{
- private final ValidationPreferences _prefs;
-
- private ELPrefPanel _elPrefPanel;
-
- /**
- * Constructor
- */
- public JSFValidationPreferencePage()
- {
- super(/* TODO: title*/);
- _prefs = new ValidationPreferences(getPreferenceStore());
- _prefs.load();
- }
-
- protected Control createContents(Composite parent)
- {
- _elPrefPanel = new ELPrefPanel(parent,
- (IWorkbenchPreferenceContainer) getContainer(), _prefs);
- _elPrefPanel.refresh();
- return _elPrefPanel.getControl();
- }
-
- public void init(IWorkbench workbench)
- {
- // do nothing
- }
-
- protected void performApply()
- {
- // process changes before committing to pref store
- _elPrefPanel.processChanges();
- _prefs.commit(getPreferenceStore());
- }
-
- protected void performDefaults()
- {
- _prefs.setDefaults();
- _elPrefPanel.refresh();
- super.performDefaults();
- }
-
- public boolean performOk()
- {
- performApply();
- return true;
- }
-
- protected IPreferenceStore doGetPreferenceStore()
- {
- // load the validation pref store
- return JSFCorePlugin.getDefault().getPreferenceStore();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidator.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidator.java
deleted file mode 100644
index ebd74bbcc..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/JSFValidator.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IWorkspaceRoot;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jface.text.IDocument;
-import org.eclipse.jface.text.IRegion;
-import org.eclipse.jst.jsf.common.internal.JSPUtil;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.jst.jsf.core.jsfappconfig.JSFAppConfigUtils;
-import org.eclipse.jst.jsf.validation.internal.IJSFViewValidator;
-import org.eclipse.jst.jsf.validation.internal.JSFValidatorFactory;
-import org.eclipse.jst.jsf.validation.internal.ValidationPreferences;
-import org.eclipse.jst.jsp.core.internal.validation.JSPValidator;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.ui.internal.reconcile.validator.ISourceValidator;
-import org.eclipse.wst.validation.internal.provisional.core.IReporter;
-import org.eclipse.wst.validation.internal.provisional.core.IValidationContext;
-
-/**
- * @author cbateman
- *
- */
-public class JSFValidator extends JSPValidator implements ISourceValidator
-{
- // TODO: should the source validator be a separate class in jsp.ui?
- // problem with simple split off is that preference must also be split off
- static final boolean DEBUG;
- static
- {
- final String value = Platform
- .getDebugOption("org.eclipse.jst.jsf.ui/validation"); //$NON-NLS-1$
- DEBUG = value != null && value.equalsIgnoreCase("true"); //$NON-NLS-1$
- }
-
- private IDocument fDocument;
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.ui.internal.reconcile.validator.ISourceValidator#connect(org.eclipse.jface.text.IDocument)
- */
- public void connect(final IDocument document)
- {
- fDocument = document;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.ui.internal.reconcile.validator.ISourceValidator#disconnect(org.eclipse.jface.text.IDocument)
- */
- public void disconnect(final IDocument document)
- {
- // finished
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.ui.internal.reconcile.validator.ISourceValidator#validate(org.eclipse.jface.text.IRegion,
- * org.eclipse.wst.validation.internal.provisional.core.IValidationContext,
- * org.eclipse.wst.validation.internal.provisional.core.IReporter)
- */
- public void validate(final IRegion dirtyRegion,
- final IValidationContext helper, final IReporter reporter)
- {
- if (DEBUG)
- {
- System.out.println("exec JSPSemanticsValidator.validateRegion"); //$NON-NLS-1$
- }
-
- final IFile file = getFile(helper);
-
- if (fDocument instanceof IStructuredDocument)
- {
- final IStructuredDocument sDoc = (IStructuredDocument) fDocument;
- final IStructuredDocumentRegion[] regions = sDoc
- .getStructuredDocumentRegions(dirtyRegion.getOffset(),
- dirtyRegion.getLength());
- if (regions != null)
- {
- final IJSFViewValidator validator = JSFValidatorFactory
- .createDefaultXMLValidator();
- final ValidationPreferences prefs = new ValidationPreferences(
- JSFCorePlugin.getDefault().getPreferenceStore());
- prefs.load();
-
- final ValidationReporter jsfReporter = new ValidationReporter(
- this, reporter, file, prefs);
- validator.validateView(file, regions, jsfReporter);
- }
- }
- }
-
- private IFile getFile(final IValidationContext helper)
- {
- final String[] uris = helper.getURIs();
- final IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot();
- if (uris.length > 0)
- {
- return wsRoot.getFile(new Path(uris[0]));
- }
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.jsp.core.internal.validation.JSPValidator#validateFile(org.eclipse.core.resources.IFile,
- * org.eclipse.wst.validation.internal.provisional.core.IReporter)
- */
- @Override
- protected void validateFile(final IFile file, final IReporter reporter)
- {
- if (shouldValidate(file))
- {
- final IJSFViewValidator validator = JSFValidatorFactory
- .createDefaultXMLValidator();
- final ValidationPreferences prefs = new ValidationPreferences(
- JSFCorePlugin.getDefault().getPreferenceStore());
- prefs.load();
-
- final ValidationReporter jsfReporter = new ValidationReporter(this,
- reporter, file, prefs);
- validator.validateView(file, jsfReporter);
- }
- }
-
- private boolean shouldValidate(final IFile file)
- {
- return (JSPUtil.isJSPContentType(file)
- && JSFAppConfigUtils.isValidJSFProject(file.getProject()));
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/Messages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/Messages.java
deleted file mode 100644
index 6b77b25f2..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/Messages.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * String resource handler
- *
- */
-public class Messages extends NLS {
- private static final String BUNDLE_NAME = "org.eclipse.jst.jsf.ui.internal.validation.messages"; //$NON-NLS-1$
- /**
- * see messages.properties
- */
- public static String ValidationMessageFactory_DefaultElSeverityDisplayName;
- /**
- * see messages.properties
- */
- public static String ValidationMessageFactory_DefaultTypeComparatorDisplayName;
- static {
- // initialize resource bundle
- NLS.initializeMessages(BUNDLE_NAME, Messages.class);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/MyLocalizedMessage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/MyLocalizedMessage.java
deleted file mode 100644
index f479a0f53..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/MyLocalizedMessage.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Cameron Bateman/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import java.util.Locale;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.wst.validation.internal.core.Message;
-
-/**
- * EL customized localizable validation message
- * @author cbateman
- *
- */
-class MyLocalizedMessage extends Message
-{
- private final String _message;
- private final int _errorCode;
-
- /**
- * @param severity
- * @param messageText
- * @param targetObject
- * @param errorCode
- */
- public MyLocalizedMessage(int severity, String messageText, IResource targetObject, int errorCode) {
- this(severity, messageText, (Object) targetObject, errorCode);
- }
-
- /**
- * @param severity
- * @param messageText
- * @param targetObject
- * @param errorCode
- */
- private MyLocalizedMessage(int severity, String messageText, Object targetObject, int errorCode) {
- super(JSFCorePlugin.getDefault().getBundle().getSymbolicName(), severity,
- messageText);
- _message = messageText;
- setTargetObject(targetObject);
- _errorCode = errorCode;
- }
-
- /**
- * @return the localized message
- */
- public String getLocalizedMessage() {
- return _message;
- }
-
- /**
- * @see org.eclipse.wst.validation.internal.core.Message#getText()
- */
- public String getText() {
- return getLocalizedMessage();
- }
-
- /**
- * @see org.eclipse.wst.validation.internal.core.Message#getText(java.lang.ClassLoader)
- */
- public String getText(ClassLoader cl) {
- return getLocalizedMessage();
- }
-
- /**
- * @see org.eclipse.wst.validation.internal.core.Message#getText(java.util.Locale)
- */
- public String getText(Locale l) {
- return getLocalizedMessage();
- }
-
- public String getText(Locale l, ClassLoader cl) {
- return getLocalizedMessage();
- }
-
- /**
- * @return the error code related to this message
- */
- public int getErrorCode() {
- return _errorCode;
- }
-
-
- /**
- * @param offset
- * @return true if this message applies to document offset
- */
- public boolean appliesTo(int offset)
- {
- return (offset >= getOffset() && offset < getOffset()+getLength());
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/OptionsConfigurationBlock.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/OptionsConfigurationBlock.java
deleted file mode 100644
index 6824b36e4..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/OptionsConfigurationBlock.java
+++ /dev/null
@@ -1,979 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 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
- * Cameron Bateman/Oracle - adapted for use in JSF validation tooling
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.IdentityHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.StringTokenizer;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.ProjectScope;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.preferences.DefaultScope;
-import org.eclipse.core.runtime.preferences.IScopeContext;
-import org.eclipse.core.runtime.preferences.InstanceScope;
-import org.eclipse.jdt.ui.JavaUI;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.jface.dialogs.MessageDialogWithToggle;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.resource.JFaceResources;
-import org.eclipse.jst.jsf.core.internal.IJSFPreferenceModel;
-import org.eclipse.jst.jsf.core.internal.JSFCorePlugin;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.validation.internal.Severity;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-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.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Link;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.Widget;
-import org.eclipse.ui.forms.events.ExpansionAdapter;
-import org.eclipse.ui.forms.events.ExpansionEvent;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
-import org.eclipse.ui.preferences.IWorkingCopyManager;
-import org.eclipse.ui.preferences.WorkingCopyManager;
-import org.osgi.service.prefs.BackingStoreException;
-
-/**
- * Abstract options configuration block providing a general implementation for setting up
- * an options configuration page.
- *
- * @since 2.1
- */
-abstract class OptionsConfigurationBlock
-{
- /**
- * The preference model to be used
- */
- protected final IJSFPreferenceModel _prefs;
-
- static final class Key
- {
- private String fQualifier;
- private String fKey;
-
- Key(String qualifier, String key) {
- fQualifier= qualifier;
- fKey= key;
- }
-
- /**
- * @return the key name
- */
- public String getName() {
- return fKey;
- }
-
-// private IEclipsePreferences getNode(IScopeContext context, IWorkingCopyManager manager) {
-// IEclipsePreferences node= context.getNode(fQualifier);
-// if (manager != null) {
-// return manager.getWorkingCopy(node);
-// }
-// return node;
-//
-// }
-
- /**
- * @param prefModel
- * @param context
- * @param manager
- * @return the value stored for the key
- */
- public Object getStoredValue(IJSFPreferenceModel prefModel, IScopeContext context, IWorkingCopyManager manager)
- {
- return prefModel.getStoredValueByKey(context, fKey);
- }
-
- /**
- * @param prefModel
- * @param context
- * @param manager
- * @return the stored value in prefModel under context for
- * this key
- */
- public Object getCurValue(IJSFPreferenceModel prefModel, IScopeContext context, IWorkingCopyManager manager) {
- //return getNode(context, manager).get(fKey, null);
- return prefModel.getValueByKey(context, fKey);
- }
-
- /**
- * @param prefModel
- * @param lookupOrder
- * @param ignoreTopScope
- * @param manager
- * @return the stored value in the prefModelunder context
- * using the list of lookupOrder for precedence of scopes
- * in which to look. Return first found based on order in lookupOrder
- */
- public Object getCurValue(IJSFPreferenceModel prefModel, IScopeContext[] lookupOrder, boolean ignoreTopScope, IWorkingCopyManager manager) {
- for (int i= ignoreTopScope ? 1 : 0; i < lookupOrder.length; i++) {
- Object value= getCurValue(prefModel, lookupOrder[i], manager);
- if (value != null) {
- return value;
- }
- }
- return null;
- }
-
- /**
- * Set the stored value
- * @param prefModel
- * @param context
- * @param value
- * @param manager
- * @return the old value or null if none
- */
- public Object setCurValue(IJSFPreferenceModel prefModel, IScopeContext context, Object value, IWorkingCopyManager manager) {
- return prefModel.setValueByKey(context, fKey, value);
-// if (value != null) {
-// getNode(context, manager).put(fKey, value);
-// } else {
-// getNode(context, manager).remove(fKey);
-// }
- }
-
- /* (non-Javadoc)
- * @see java.lang.Object#toString()
- */
- public String toString() {
- return fQualifier + '/' + fKey;
- }
-
- /**
- * @return the plugin qualifier
- */
- public String getQualifier() {
- return fQualifier;
- }
-
- }
-
-
- static class ControlData {
- private Key fKey;
- private String[] fValues;
-
- ControlData(Key key, String[] values) {
- fKey= key;
- fValues= values;
- }
-
- Key getKey() {
- return fKey;
- }
-
- String getValue(boolean selection) {
- int index= selection ? 0 : 1;
- return fValues[index];
- }
-
- String getValue(int index) {
- return fValues[index];
- }
-
- int getSelection(String value) {
- if (value != null) {
- for (int i= 0; i < fValues.length; i++) {
- if (value.equals(fValues[i])) {
- return i;
- }
- }
- }
- return fValues.length -1; // assume the last option is the least severe
- }
- }
-
- private static final String REBUILD_COUNT_KEY= "preferences_build_requested"; //$NON-NLS-1$
-
- private static final String SETTINGS_EXPANDED= "expanded"; //$NON-NLS-1$
-
- private final ArrayList fCheckBoxes;
- private final ArrayList fComboBoxes;
- private final ArrayList fTextBoxes;
- private final HashMap fLabels;
- private final ArrayList fExpandedComposites;
-
- private SelectionListener fSelectionListener;
- private ModifyListener fTextModifyListener;
-
- // TODO: protected IStatusChangeListener fContext;
- private final IProject fProject; // project or null
- private final Key[] fAllKeys;
-
- private IScopeContext[] fLookupOrder;
-
- private Shell fShell;
-
- private final IWorkingCopyManager fManager;
- private IWorkbenchPreferenceContainer fContainer;
-
- private Map fDisabledProjectSettings; // null when project specific settings are turned off
-
- private int fRebuildCount; /// used to prevent multiple dialogs that ask for a rebuild
-
- OptionsConfigurationBlock(/*IStatusChangeListener context,*/IJSFPreferenceModel prefs, IProject project, Key[] allKeys, IWorkbenchPreferenceContainer container) {
- //fContext= context;
- fProject= project;
- fAllKeys= allKeys;
- fContainer= container;
- _prefs = prefs;
-
- if (container == null) {
- fManager= new WorkingCopyManager();
- } else {
- fManager= container.getWorkingCopyManager();
- }
-
- if (fProject != null) {
- fLookupOrder= new IScopeContext[] {
- new ProjectScope(fProject),
- new InstanceScope(),
- new DefaultScope()
- };
- } else {
- fLookupOrder= new IScopeContext[] {
- new InstanceScope(),
- new DefaultScope()
- };
- }
-
- testIfOptionsComplete(allKeys);
- if (fProject == null || hasProjectSpecificOptions(fProject)) {
- fDisabledProjectSettings= null;
- } else {
- fDisabledProjectSettings= new IdentityHashMap();
- for (int i= 0; i < allKeys.length; i++) {
- Key curr= allKeys[i];
- fDisabledProjectSettings.put(curr, curr.getCurValue(_prefs, fLookupOrder, false, fManager));
- }
- }
-
- fCheckBoxes= new ArrayList();
- fComboBoxes= new ArrayList();
- fTextBoxes= new ArrayList(2);
- fLabels= new HashMap();
- fExpandedComposites= new ArrayList();
-
- fRebuildCount= getRebuildCount();
- }
-
- /**
- * @return the preference container
- */
- protected final IWorkbenchPreferenceContainer getPreferenceContainer() {
- return fContainer;
- }
-
- /**
- * @param plugin
- * @param key
- * @return construct a new Key based on the on the plugin id and
- * preference key
- */
- protected static Key getKey(String plugin, String key) {
- return new Key(plugin, key);
- }
-
- /**
- * @param key
- * @return construct a new Key for a JSF core plugin preference
- */
- protected final static Key getJSFCoreKey(String key) {
- return getKey(JSFCorePlugin.PLUGIN_ID, key);
- }
-
- private void testIfOptionsComplete(Key[] allKeys) {
- for (int i= 0; i < allKeys.length; i++) {
- if (allKeys[i].getCurValue(_prefs, fLookupOrder, false, fManager) == null) {
- JSFUiPlugin.log(IStatus.ERROR, "preference option missing: " + allKeys[i] + " (" + this.getClass().getName() +')'); //$NON-NLS-1$//$NON-NLS-2$
- }
- }
- }
-
- private int getRebuildCount() {
- return fManager.getWorkingCopy(new DefaultScope().getNode(JavaUI.ID_PLUGIN)).getInt(REBUILD_COUNT_KEY, 0);
- }
-
- private void incrementRebuildCount() {
- fRebuildCount++;
- fManager.getWorkingCopy(new DefaultScope().getNode(JavaUI.ID_PLUGIN)).putInt(REBUILD_COUNT_KEY, fRebuildCount);
- }
-
-// public void selectOption(String key, String qualifier) {
-// for (int i= 0; i < fAllKeys.length; i++) {
-// Key curr= fAllKeys[i];
-// if (curr.getName().equals(key) && curr.getQualifier().equals(qualifier)) {
-// selectOption(curr);
-// }
-// }
-// }
-//
-// public void selectOption(Key key) {
-// Control control= findControl(key);
-// if (control != null) {
-// if (!fExpandedComposites.isEmpty()) {
-// ExpandableComposite expandable= getParentExpandableComposite(control);
-// if (expandable != null) {
-// for (int i= 0; i < fExpandedComposites.size(); i++) {
-// ExpandableComposite curr= (ExpandableComposite) fExpandedComposites.get(i);
-// curr.setExpanded(curr == expandable);
-// }
-// expandedStateChanged(expandable);
-// }
-// }
-// control.setFocus();
-// }
-// }
-
-
- /**
- * @param project
- * @return true if there are project specific overrides in the
- * preferences for 'project'
- */
- public final boolean hasProjectSpecificOptions(IProject project) {
- if (project != null) {
- IScopeContext projectContext= new ProjectScope(project);
- Key[] allKeys= fAllKeys;
- for (int i= 0; i < allKeys.length; i++) {
- if (allKeys[i].getCurValue(_prefs, projectContext, fManager) != null) {
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * @return the shell hosting the UI
- */
- protected Shell getShell() {
- return fShell;
- }
-
- /**
- * Set the shell hosting the UI.
- * @param shell
- */
- protected void setShell(Shell shell) {
- fShell= shell;
- }
-
- /**
- * @param parent
- * @return the parent of the UI control to be created
- */
- protected abstract Control createContents(Composite parent);
-
-// protected Button addCheckBox(Composite parent, String label, Key key, String[] values, int indent) {
-// ControlData data= new ControlData(key, values);
-//
-// GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
-// gd.horizontalSpan= 3;
-// gd.horizontalIndent= indent;
-//
-// Button checkBox= new Button(parent, SWT.CHECK);
-// checkBox.setFont(JFaceResources.getDialogFont());
-// checkBox.setText(label);
-// checkBox.setData(data);
-// checkBox.setLayoutData(gd);
-// checkBox.addSelectionListener(getSelectionListener());
-//
-// makeScrollableCompositeAware(checkBox);
-//
-// String currValue= getValue(key);
-// checkBox.setSelection(data.getSelection(currValue) == 0);
-//
-// fCheckBoxes.add(checkBox);
-//
-// return checkBox;
-// }
-
- /**
- * @param parent
- * @param label
- * @param key
- * @param values
- * @param indent
- * @param widthHint
- * @param listener
- * @return a check box styled button with a related link
- */
- protected Button addCheckBoxWithLink(Composite parent, String label, Key key, String[] values, int indent, int widthHint, SelectionListener listener) {
- ControlData data= new ControlData(key, values);
-
- GridData gd= new GridData(GridData.FILL, GridData.FILL, true, false);
- gd.horizontalSpan= 3;
- gd.horizontalIndent= indent;
-
- Composite composite= new Composite(parent, SWT.NONE);
- GridLayout layout= new GridLayout();
- layout.marginHeight= 0;
- layout.marginWidth= 0;
- layout.numColumns= 2;
- composite.setLayout(layout);
- composite.setLayoutData(gd);
-
- Button checkBox= new Button(composite, SWT.CHECK);
- checkBox.setFont(JFaceResources.getDialogFont());
- checkBox.setData(data);
- checkBox.setLayoutData(new GridData(GridData.FILL, GridData.BEGINNING, false, false));
- checkBox.addSelectionListener(getSelectionListener());
-
- gd= new GridData(GridData.FILL, GridData.CENTER, true, false);
- gd.widthHint= widthHint;
-
- Link link= new Link(composite, SWT.NONE);
- link.setText(label);
- link.setLayoutData(gd);
- if (listener != null) {
- link.addSelectionListener(listener);
- }
-
- makeScrollableCompositeAware(link);
- makeScrollableCompositeAware(checkBox);
-
- String currValue= getValue(key);
- checkBox.setSelection(data.getSelection(currValue) == 0);
-
- fCheckBoxes.add(checkBox);
-
- return checkBox;
- }
-
- /**
- * @param parent
- * @param label
- * @param key
- * @param values
- * @param valueLabels
- * @param indent
- * @return a Combo box added to parent with the label and key
- */
- protected Combo addComboBox(Composite parent, String label, Key key, String[] values, String[] valueLabels, int indent) {
- GridData gd= new GridData(GridData.FILL, GridData.CENTER, true, false, 2, 1);
- gd.horizontalIndent= indent;
-
- Label labelControl= new Label(parent, SWT.LEFT);
- labelControl.setFont(JFaceResources.getDialogFont());
-
- labelControl.setText(label);
- labelControl.setLayoutData(gd);
-
- Combo comboBox= newComboControl(parent, key, values, valueLabels);
- comboBox.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
-
- fLabels.put(comboBox, labelControl);
-
- return comboBox;
- }
-
- Combo addInversedComboBox(Composite parent, String label, Key key, String[] values, String[] valueLabels, int indent) {
- GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
- gd.horizontalIndent= indent;
- gd.horizontalSpan= 3;
-
- Composite composite= new Composite(parent, SWT.NONE);
- GridLayout layout= new GridLayout();
- layout.marginHeight= 0;
- layout.marginWidth= 0;
- layout.numColumns= 2;
- composite.setLayout(layout);
- composite.setLayoutData(gd);
-
- Combo comboBox= newComboControl(composite, key, values, valueLabels);
- comboBox.setFont(JFaceResources.getDialogFont());
- comboBox.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
-
- Label labelControl= new Label(composite, SWT.LEFT | SWT.WRAP);
- labelControl.setText(label);
- labelControl.setLayoutData(new GridData());
-
- fLabels.put(comboBox, labelControl);
- return comboBox;
- }
-
- Combo newComboControl(Composite composite, Key key, String[] values, String[] valueLabels) {
- ControlData data= new ControlData(key, values);
-
- Combo comboBox= new Combo(composite, SWT.READ_ONLY);
- comboBox.setItems(valueLabels);
- comboBox.setData(data);
- comboBox.addSelectionListener(getSelectionListener());
- comboBox.setFont(JFaceResources.getDialogFont());
-
- makeScrollableCompositeAware(comboBox);
-
- String currValue= getValue(key);
- comboBox.select(data.getSelection(currValue));
-
- fComboBoxes.add(comboBox);
- return comboBox;
- }
-
- Text addTextField(Composite parent, String label, Key key, int indent, int widthHint) {
- Label labelControl= new Label(parent, SWT.WRAP);
- labelControl.setText(label);
- labelControl.setFont(JFaceResources.getDialogFont());
- labelControl.setLayoutData(new GridData());
-
- Text textBox= new Text(parent, SWT.BORDER | SWT.SINGLE);
- textBox.setData(key);
- textBox.setLayoutData(new GridData());
-
- makeScrollableCompositeAware(textBox);
-
- fLabels.put(textBox, labelControl);
-
- String currValue= getValue(key);
- if (currValue != null) {
- textBox.setText(currValue);
- }
- textBox.addModifyListener(getTextModifyListener());
-
- GridData data= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
- if (widthHint != 0) {
- data.widthHint= widthHint;
- }
- data.horizontalIndent= indent;
- data.horizontalSpan= 2;
- textBox.setLayoutData(data);
-
- fTextBoxes.add(textBox);
- return textBox;
- }
-
- ScrolledPageContent getParentScrolledComposite(Control control) {
- Control parent= control.getParent();
- while (!(parent instanceof ScrolledPageContent) && parent != null) {
- parent= parent.getParent();
- }
- if (parent instanceof ScrolledPageContent) {
- return (ScrolledPageContent) parent;
- }
- return null;
- }
-
- ExpandableComposite getParentExpandableComposite(Control control) {
- Control parent= control.getParent();
- while (!(parent instanceof ExpandableComposite) && parent != null) {
- parent= parent.getParent();
- }
- if (parent instanceof ExpandableComposite) {
- return (ExpandableComposite) parent;
- }
- return null;
- }
-
- private void makeScrollableCompositeAware(Control control) {
- ScrolledPageContent parentScrolledComposite= getParentScrolledComposite(control);
- if (parentScrolledComposite != null) {
- parentScrolledComposite.adaptChild(control);
- }
- }
-
- ExpandableComposite createStyleSection(Composite parent, String label, int nColumns) {
- ExpandableComposite excomposite= new ExpandableComposite(parent, SWT.NONE, ExpandableComposite.TWISTIE | ExpandableComposite.CLIENT_INDENT);
- excomposite.setText(label);
- excomposite.setExpanded(false);
- excomposite.setFont(JFaceResources.getFontRegistry().getBold(JFaceResources.DIALOG_FONT));
- excomposite.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, false, nColumns, 1));
- excomposite.addExpansionListener(new ExpansionAdapter() {
- public void expansionStateChanged(ExpansionEvent e) {
- expandedStateChanged((ExpandableComposite) e.getSource());
- }
- });
- fExpandedComposites.add(excomposite);
- makeScrollableCompositeAware(excomposite);
- return excomposite;
- }
-
- final void expandedStateChanged(ExpandableComposite expandable) {
- ScrolledPageContent parentScrolledComposite= getParentScrolledComposite(expandable);
- if (parentScrolledComposite != null) {
- parentScrolledComposite.reflow(true);
- }
- }
-
- void restoreSectionExpansionStates(IDialogSettings settings) {
- for (int i= 0; i < fExpandedComposites.size(); i++) {
- ExpandableComposite excomposite= (ExpandableComposite) fExpandedComposites.get(i);
- if (settings == null) {
- excomposite.setExpanded(i == 0); // only expand the first node by default
- } else {
- excomposite.setExpanded(settings.getBoolean(SETTINGS_EXPANDED + String.valueOf(i)));
- }
- }
- }
-
- void storeSectionExpansionStates(IDialogSettings settings) {
- for (int i= 0; i < fExpandedComposites.size(); i++) {
- ExpandableComposite curr= (ExpandableComposite) fExpandedComposites.get(i);
- settings.put(SETTINGS_EXPANDED + String.valueOf(i), curr.isExpanded());
- }
- }
-
- SelectionListener getSelectionListener() {
- if (fSelectionListener == null) {
- fSelectionListener= new SelectionListener() {
- public void widgetDefaultSelected(SelectionEvent e) {/*do nothing*/}
-
- public void widgetSelected(SelectionEvent e) {
- controlChanged(e.widget);
- }
- };
- }
- return fSelectionListener;
- }
-
- ModifyListener getTextModifyListener() {
- if (fTextModifyListener == null) {
- fTextModifyListener= new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- textChanged((Text) e.widget);
- }
- };
- }
- return fTextModifyListener;
- }
-
- void controlChanged(Widget widget) {
- ControlData data= (ControlData) widget.getData();
- String newValue= null;
- if (widget instanceof Button) {
- newValue= data.getValue(((Button)widget).getSelection());
- } else if (widget instanceof Combo) {
- newValue= data.getValue(((Combo)widget).getSelectionIndex());
- } else {
- return;
- }
- String oldValue= setValue(data.getKey(), newValue);
- validateSettings(data.getKey(), oldValue, newValue);
- }
-
- void textChanged(Text textControl) {
- Key key= (Key) textControl.getData();
- String number= textControl.getText();
- String oldValue= setValue(key, number);
- validateSettings(key, oldValue, number);
- }
-
- boolean checkValue(Key key, String value) {
- return value.equals(getValue(key));
- }
-
- String getValue(Key key) {
- if (fDisabledProjectSettings != null) {
- return (String) fDisabledProjectSettings.get(key);
- }
- return key.getCurValue(_prefs, fLookupOrder, false, fManager).toString();
- }
-
-
- boolean getBooleanValue(Key key) {
- return Boolean.valueOf(getValue(key)).booleanValue();
- }
-
- String setValue(Key key, String value) {
- if (fDisabledProjectSettings != null) {
- return (String) fDisabledProjectSettings.put(key, value);
- }
- Object newValue = key.setCurValue(_prefs, fLookupOrder[0], Severity.valueOfString(value), fManager);
- return newValue != null ? newValue.toString() : ""; //$NON-NLS-1$
- }
-
- String setValue(Key key, boolean value) {
- return setValue(key, String.valueOf(value));
- }
-
- /**
- * Returns the value as actually stored in the preference store.
- * @param key
- * @return the value as actually stored in the preference store.
- */
- Object getStoredValue(Key key) {
- return key.getCurValue(_prefs, fLookupOrder, false, fManager);
- }
-
- /**
- * Update fields and validate.
- * @param changedKey Key that changed, or null, if all changed.
- * @param oldValue
- * @param newValue
- */
- protected abstract void validateSettings(Key changedKey, String oldValue, String newValue);
-
-
- String[] getTokens(String text, String separator) {
- StringTokenizer tok= new StringTokenizer(text, separator);
- int nTokens= tok.countTokens();
- String[] res= new String[nTokens];
- for (int i= 0; i < res.length; i++) {
- res[i]= tok.nextToken().trim();
- }
- return res;
- }
-
- private boolean getChanges(IScopeContext currContext, List changedSettings) {
- boolean needsBuild= false;
- for (int i= 0; i < fAllKeys.length; i++) {
- Key key= fAllKeys[i];
- Object oldVal= key.getStoredValue(_prefs, currContext, null);
- Object val= key.getCurValue(_prefs, currContext, fManager);
- if (val == null) {
- if (oldVal != null) {
- changedSettings.add(key);
- needsBuild |= !oldVal.equals(key.getCurValue(_prefs, fLookupOrder, true, fManager));
- }
- } else if (!val.equals(oldVal)) {
- changedSettings.add(key);
- needsBuild |= oldVal != null || !val.equals(key.getCurValue(_prefs, fLookupOrder, true, fManager));
- }
- }
- return needsBuild;
- }
-
- void useProjectSpecificSettings(boolean enable) {
- boolean hasProjectSpecificOption= fDisabledProjectSettings == null;
- if (enable != hasProjectSpecificOption && fProject != null) {
- if (enable) {
- for (int i= 0; i < fAllKeys.length; i++) {
- Key curr= fAllKeys[i];
- String val= (String) fDisabledProjectSettings.get(curr);
- curr.setCurValue(_prefs, fLookupOrder[0], Severity.valueOfString(val), fManager);
- }
- fDisabledProjectSettings= null;
- updateControls();
- validateSettings(null, null, null);
- } else {
- fDisabledProjectSettings= new IdentityHashMap();
- for (int i= 0; i < fAllKeys.length; i++) {
- Key curr= fAllKeys[i];
- Object oldSetting= curr.getCurValue(_prefs, fLookupOrder, false, fManager);
- fDisabledProjectSettings.put(curr, oldSetting);
- curr.setCurValue(_prefs, fLookupOrder[0], null, fManager); // clear project settings
- }
- }
- }
- }
-
- boolean areSettingsEnabled() {
- return fDisabledProjectSettings == null || fProject == null;
- }
-
-
- boolean performOk() {
- return processChanges(fContainer);
- }
-
-// public boolean performApply() {
-// return processChanges(null); // apply directly
-// }
-
- boolean processChanges(IWorkbenchPreferenceContainer container) {
- IScopeContext currContext= fLookupOrder[0];
-
- List /* <Key>*/ changedOptions= new ArrayList();
- boolean needsBuild= getChanges(currContext, changedOptions);
- if (changedOptions.isEmpty()) {
- return true;
- }
- if (needsBuild) {
- int count= getRebuildCount();
- if (count > fRebuildCount) {
- needsBuild= false; // build already requested
- fRebuildCount= count;
- }
- }
-
- boolean doBuild= false;
-
- final String showBuildWarningKey = JSFCorePlugin.PLUGIN_ID + "." + "buildwarning_dont_show_again"; //$NON-NLS-1$ //$NON-NLS-2$
- final IPreferenceStore prefStore = JSFCorePlugin.getDefault().getPreferenceStore();
- final boolean showDialog = !MessageDialogWithToggle.ALWAYS.equals(prefStore.getString(showBuildWarningKey));
-
- if (needsBuild && showDialog) {
- String[] strings= getFullBuildDialogStrings(fProject == null);
- if (strings != null) {
- MessageDialogWithToggle.openInformation
- (getShell(), strings[0], strings[1],
- PreferencesMessages.ProblemSeveritiesConfigurationBlock_buildwarning_dont_show_again
- , false, prefStore, showBuildWarningKey);
-// int res= dialog.open();
-// if (res == 0) {
-// doBuild= true;
-// } else if (res != 1) {
-// return false; // cancel pressed
-// }
- }
- }
- if (container != null) {
- // no need to apply the changes to the original store: will be done by the page container
- if (doBuild) { // post build
- incrementRebuildCount();
- // TODO: container.registerUpdateJob(CoreUtility.getBuildJob(fProject));
- }
- } else {
- // apply changes right away
- try {
- fManager.applyChanges();
- } catch (BackingStoreException e) {
- JSFUiPlugin.log(IStatus.ERROR, "Error applying changes", e); //$NON-NLS-1$
- return false;
- }
- if (doBuild) {
- //CoreUtility.getBuildJob(fProject).schedule();
- }
-
- }
- return true;
- }
-
- abstract String[] getFullBuildDialogStrings(boolean workspaceSettings);
-
-
-// public void performDefaults() {
-// for (int i= 0; i < fAllKeys.length; i++) {
-// Key curr= fAllKeys[i];
-// String defValue= curr.getStoredValue(fLookupOrder, true, fManager);
-// setValue(curr, defValue);
-// }
-//
-// settingsUpdated();
-// updateControls();
-// validateSettings(null, null, null);
-// }
-
- /**
- * @since 3.1
- */
- void performRevert() {
- for (int i= 0; i < fAllKeys.length; i++) {
- Key curr= fAllKeys[i];
- String origValue= curr.getCurValue(_prefs, fLookupOrder, false, null).toString();
- setValue(curr, origValue);
- }
-
- updateControls();
- validateSettings(null, null, null);
- }
-
- void dispose() {
- // do nothing; sub-class should override
- }
-
- void updateControls() {
- // update the UI
- for (int i= fCheckBoxes.size() - 1; i >= 0; i--) {
- updateCheckBox((Button) fCheckBoxes.get(i));
- }
- for (int i= fComboBoxes.size() - 1; i >= 0; i--) {
- updateCombo((Combo) fComboBoxes.get(i));
- }
- for (int i= fTextBoxes.size() - 1; i >= 0; i--) {
- updateText((Text) fTextBoxes.get(i));
- }
- }
-
- void updateCombo(Combo curr) {
- ControlData data= (ControlData) curr.getData();
-
- String currValue= getValue(data.getKey());
- curr.select(data.getSelection(currValue));
- }
-
- void updateCheckBox(Button curr) {
- ControlData data= (ControlData) curr.getData();
-
- String currValue= getValue(data.getKey());
- curr.setSelection(data.getSelection(currValue) == 0);
- }
-
- void updateText(Text curr) {
- Key key= (Key) curr.getData();
-
- String currValue= getValue(key);
- if (currValue != null) {
- curr.setText(currValue);
- }
- }
-
- Button getCheckBox(Key key) {
- for (int i= fCheckBoxes.size() - 1; i >= 0; i--) {
- Button curr= (Button) fCheckBoxes.get(i);
- ControlData data= (ControlData) curr.getData();
- if (key.equals(data.getKey())) {
- return curr;
- }
- }
- return null;
- }
-
- Combo getComboBox(Key key) {
- for (int i= fComboBoxes.size() - 1; i >= 0; i--) {
- Combo curr= (Combo) fComboBoxes.get(i);
- ControlData data= (ControlData) curr.getData();
- if (key.equals(data.getKey())) {
- return curr;
- }
- }
- return null;
- }
-
- Text getTextControl(Key key) {
- for (int i= fTextBoxes.size() - 1; i >= 0; i--) {
- Text curr= (Text) fTextBoxes.get(i);
- ControlData data= (ControlData) curr.getData();
- if (key.equals(data.getKey())) {
- return curr;
- }
- }
- return null;
- }
-
- Control findControl(Key key) {
- Combo comboBox= getComboBox(key);
- if (comboBox != null) {
- return comboBox;
- }
- Button checkBox= getCheckBox(key);
- if (checkBox != null) {
- return checkBox;
- }
- Text text= getTextControl(key);
- if (text != null) {
- return text;
- }
- return null;
- }
-
- void setComboEnabled(Key key, boolean enabled) {
- Combo combo= getComboBox(key);
- Label label= (Label) fLabels.get(combo);
- combo.setEnabled(enabled);
- label.setEnabled(enabled);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PixelConverter.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PixelConverter.java
deleted file mode 100644
index a5ed50309..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PixelConverter.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2005 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
- * Oracle - copied for use in JSF validation tooling
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.swt.graphics.Font;
-import org.eclipse.swt.graphics.FontMetrics;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.widgets.Control;
-
-import org.eclipse.jface.dialogs.Dialog;
-
-/**
- * Copied from JDT. Used by OptionsConfigurationBlock
- *
- */
-class PixelConverter {
-
- private final FontMetrics fFontMetrics;
-
- /**
- * @param control
- */
- PixelConverter(Control control) {
- this(control.getFont());
- }
-
- /**
- * @param font
- */
- PixelConverter(Font font) {
- GC gc = new GC(font.getDevice());
- gc.setFont(font);
- fFontMetrics= gc.getFontMetrics();
- gc.dispose();
- }
-
- /*
- * see org.eclipse.jface.dialogs.DialogPage#convertHeightInCharsToPixels(int)
- */
- int convertHeightInCharsToPixels(int chars) {
- return Dialog.convertHeightInCharsToPixels(fFontMetrics, chars);
- }
-
- /*
- * see org.eclipse.jface.dialogs.DialogPage#convertHorizontalDLUsToPixels(int)
- */
- int convertHorizontalDLUsToPixels(int dlus) {
- return Dialog.convertHorizontalDLUsToPixels(fFontMetrics, dlus);
- }
-
- /*
- * see org.eclipse.jface.dialogs.DialogPage#convertVerticalDLUsToPixels(int)
- */
- int convertVerticalDLUsToPixels(int dlus) {
- return Dialog.convertVerticalDLUsToPixels(fFontMetrics, dlus);
- }
-
- /*
- * see org.eclipse.jface.dialogs.DialogPage#convertWidthInCharsToPixels(int)
- */
- int convertWidthInCharsToPixels(int chars) {
- return Dialog.convertWidthInCharsToPixels(fFontMetrics, chars);
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PreferencesMessages.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PreferencesMessages.java
deleted file mode 100644
index 2148c52e1..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/PreferencesMessages.java
+++ /dev/null
@@ -1,237 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 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
- * John Kaplan, johnkaplantech@gmail.com - 108071 [code templates] template for body of newly created class
- * Oracle - adapted for JSF tooling
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * NLS messages for validation severity preferences
- *
- * @author cbateman
- *
- */
-public final class PreferencesMessages extends NLS {
-
- private static final String BUNDLE_NAME= "org.eclipse.jst.jsf.ui.internal.validation.messages";//$NON-NLS-1$
-
- private PreferencesMessages() {
- // Do not instantiate
- }
-
- static {
- NLS.initializeMessages(BUNDLE_NAME, PreferencesMessages.class);
- }
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesPreferencePage_title;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_warning;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_ignore;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_id_resolution;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_general;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_type_coercion_problems;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_constant_folding_and_unused_code;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_programming_errors;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_section_type_comparison;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_needsbuild_title;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_needsfullbuild_message;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_needsprojectbuild_message;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_buildwarning_dont_show_again;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_common_description;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_general_syntax_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_empty_el_expression;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_missing_closing_expr_bracket;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_cannot_apply_operator_to_method_binding;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_dotted_property_key_should_use_array;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_variable_not_found;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_member_not_found;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_binary_op_numeric_coercion_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_binary_op_boolean_coercion_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_binary_op_no_coercion_available;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_binary_op_literal_to_number_coercion_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_unary_op_numeric_coercion_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_unary_op_boolean_coercion_error;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_unary_op_string_coercion_not_guaranteed;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_both_binary_operands_null;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_binary_expression_always_evaluates_same;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_equality_with_null_always_same;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_unary_expression_always_evaluates_same;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_empty_expression_always_false;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_enumeration_comparision_always_same;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_minus_on_null_always_zero;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_first_argument_short_circuits_expression;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_second_argument_always_evaluates_same;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_apply_dot_operator_with_null;
-
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_possible_division_by_zero;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_possible_array_index_out_of_bounds;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_incompatible_enumeration_comparison;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_member_is_intermediate;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_method_expression_expected;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_incompatible_type_assignment;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_value_expression_expected;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_incompatible_method_types;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_property_not_readable;
- /**
- * see messages.properties
- */
- public static String ProblemSeveritiesConfigurationBlock_pb_property_not_writable;
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ProblemSeveritiesConfigurationBlock.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ProblemSeveritiesConfigurationBlock.java
deleted file mode 100644
index 48941b897..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ProblemSeveritiesConfigurationBlock.java
+++ /dev/null
@@ -1,470 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 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
- * Oracle - adapted for use in JSF Tooling
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.jst.jsf.core.internal.IJSFPreferenceModel;
-import org.eclipse.jst.jsf.ui.internal.JSFUiPlugin;
-import org.eclipse.jst.jsf.validation.internal.ELValidationPreferences;
-import org.eclipse.jst.jsf.validation.internal.JSFTypeComparatorPreferences;
-import org.eclipse.jst.jsf.validation.internal.Severity;
-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.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
-
-
-/**
- */
-/*package*/ class ProblemSeveritiesConfigurationBlock extends OptionsConfigurationBlock {
-
- private static final String SETTINGS_SECTION_NAME= "ProblemSeveritiesConfigurationBlock"; //$NON-NLS-1$
-
- /**
- * preference key. Match to DiagnosticFactory constants
- */
- private final static Key PREF_BINARY_OP_BOTH_OPERANDS_NULL =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_BOTH_OPERANDS_NULL);
- private final static Key PREF_BINARY_OP_POSSIBLE_DIVISION_BY_ZERO =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_POSSIBLE_DIVISION_BY_ZERO);
- private final static Key PREF_BINARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION);
- private final static Key PREF_BINARY_OP_CONSTANT_EXPRESSION_ALWAYS_EVAL_SAME =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_CONSTANT_EXPRESSION_ALWAYS_EVAL_SAME);
- private final static Key PREF_BINARY_OP_EQUALITY_COMP_WITH_NULL_ALWAYS_EVAL_SAME =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_EQUALITY_COMP_WITH_NULL_ALWAYS_EVAL_SAME);
- private final static Key PREF_BINARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN);
- private final static Key PREF_BINARY_OP_FIRST_ARGUMENT_SHORT_CIRCUITS =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_FIRST_ARGUMENT_SHORT_CIRCUITS);
- private final static Key PREF_BINARY_OP_SECOND_ARGUMENT_ALWAYS_EVAL_SAME =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_SECOND_ARGUMENT_ALWAYS_EVAL_SAME);
- private final static Key PREF_BINARY_OP_NO_AVAILABLE_TYPE_COERCION =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_NO_AVAILABLE_TYPE_COERCION);
- private final static Key PREF_BINARY_OP_COULD_NOT_COERCE_LITERALS_TO_NUMBERS =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_COULD_NOT_COERCE_LITERALS_TO_NUMBERS);
- private final static Key PREF_UNARY_OP_CONSTANT_EXPRESSION_EVAL_SAME =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_CONSTANT_EXPRESSION_EVAL_SAME);
- private final static Key PREF_UNARY_OP_EMPTY_ALWAYS_FALSE_ON_TYPE =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_EMPTY_ALWAYS_FALSE_ON_TYPE);
- private final static Key PREF_UNARY_OP_MINUS_ON_NULL_ALWAYS_ZERO =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_MINUS_ON_NULL_ALWAYS_ZERO);
- private final static Key PREF_UNARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION);
- private final static Key PREF_UNARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN);
-// private final static Key PREF_TERNARY_OP_CHOICE_IS_ALWAYS_SAME =
-// getJSFCoreKey(ELValidationPreferences.TERNARY_OP_CHOICE_IS_ALWAYS_SAME);
-// private final static Key PREF_TERNARY_OP_CANNOT_COERCE_CHOICE_TO_BOOLEAN =
-// getJSFCoreKey(ELValidationPreferences.TERNARY_OP_CANNOT_COERCE_CHOICE_TO_BOOLEAN);
- private final static Key PREF_UNARY_OP_STRING_CONVERSION_NOT_GUARANTEED =
- getJSFCoreKey(ELValidationPreferences.UNARY_OP_STRING_CONVERSION_NOT_GUARANTEED);
- private final static Key PREF_CANNOT_APPLY_OPERATOR_TO_METHOD_BINDING =
- getJSFCoreKey(ELValidationPreferences.CANNOT_APPLY_OPERATOR_TO_METHOD_BINDING);
- private final static Key PREF_MEMBER_NOT_FOUND =
- getJSFCoreKey(ELValidationPreferences.MEMBER_NOT_FOUND);
- private final static Key PREF_VARIABLE_NOT_FOUND =
- getJSFCoreKey(ELValidationPreferences.VARIABLE_NOT_FOUND);
- private final static Key PREF_MISSING_CLOSING_EXPR_BRACKET =
- getJSFCoreKey(ELValidationPreferences.MISSING_CLOSING_EXPR_BRACKET);
- private final static Key PREF_GENERAL_SYNTAX_ERROR =
- getJSFCoreKey(ELValidationPreferences.GENERAL_SYNTAX_ERROR);
- private final static Key PREF_EMPTY_EL_EXPRESSION =
- getJSFCoreKey(ELValidationPreferences.EMPTY_EL_EXPRESSION);
- private final static Key PREF_BINARY_OP_DOT_WITH_VALUEB_NULL =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_DOT_WITH_VALUEB_NULL);
- private final static Key PREF_BINARY_OP_DOT_WITH_DOTTED_KEY_SHOULD_USE_ARRAY =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_DOT_WITH_DOTTED_KEY_SHOULD_USE_ARRAY);
- private final static Key PREF_POSSIBLE_ARRAY_INDEX_OUT_OF_BOUNDS =
- getJSFCoreKey(ELValidationPreferences.POSSIBLE_ARRAY_INDEX_OUT_OF_BOUNDS);
- private final static Key PREF_BINARY_COMPARISON_WITH_ENUM_ALWAYS_SAME =
- getJSFCoreKey(ELValidationPreferences.BINARY_COMPARISON_WITH_ENUM_ALWAYS_SAME);
- private final static Key PREF_BINARY_OP_COMPARISON_OF_ENUMS_INCOMPATIBLE =
- getJSFCoreKey(ELValidationPreferences.BINARY_OP_COMPARISON_OF_ENUMS_INCOMPATIBLE);
- private final static Key PREF_MEMBER_IS_INTERMEDIATE =
- getJSFCoreKey(ELValidationPreferences.MEMBER_IS_INTERMEDIATE);
-
- // TypeComparator keys
- private final static Key PREF_INCOMPATIBLE_METHOD_TYPES =
- getJSFCoreKey(JSFTypeComparatorPreferences.INCOMPATIBLE_METHOD_TYPES);
- private final static Key PREF_INCOMPATIBLE_TYPES =
- getJSFCoreKey(JSFTypeComparatorPreferences.INCOMPATIBLE_TYPES);
- private final static Key PREF_METHOD_EXPRESSION_EXPECTED =
- getJSFCoreKey(JSFTypeComparatorPreferences.METHOD_EXPRESSION_EXPECTED);
- private final static Key PREF_PROPERTY_NOT_READABLE =
- getJSFCoreKey(JSFTypeComparatorPreferences.PROPERTY_NOT_READABLE);
- private final static Key PREF_PROPERTY_NOT_WRITABLE =
- getJSFCoreKey(JSFTypeComparatorPreferences.PROPERTY_NOT_WRITABLE);
- private final static Key PREF_VALUE_EXPRESSION_EXPECTED =
- getJSFCoreKey(JSFTypeComparatorPreferences.VALUE_EXPRESSION_EXPECTED);
-
-
- private final static int EXPECTED_PREFS = 34;
-
- private PixelConverter fPixelConverter;
-
- /**
- * @param prefs
- * @param project
- * @param container
- */
- public ProblemSeveritiesConfigurationBlock(/*TODO:IStatusChangeListener context,*/ IJSFPreferenceModel prefs, IProject project, IWorkbenchPreferenceContainer container) {
- super(prefs, project, getKeys(), container);
- }
-
- private static Key[] getKeys()
- {
- Key[] keys = new Key[] {
- PREF_BINARY_OP_BOTH_OPERANDS_NULL
- , PREF_BINARY_OP_POSSIBLE_DIVISION_BY_ZERO
- , PREF_BINARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION
- , PREF_BINARY_OP_CONSTANT_EXPRESSION_ALWAYS_EVAL_SAME
- , PREF_BINARY_OP_EQUALITY_COMP_WITH_NULL_ALWAYS_EVAL_SAME
- , PREF_BINARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN
- , PREF_BINARY_OP_FIRST_ARGUMENT_SHORT_CIRCUITS
- , PREF_BINARY_OP_SECOND_ARGUMENT_ALWAYS_EVAL_SAME
- , PREF_BINARY_OP_NO_AVAILABLE_TYPE_COERCION
- , PREF_BINARY_OP_COULD_NOT_COERCE_LITERALS_TO_NUMBERS
- , PREF_UNARY_OP_CONSTANT_EXPRESSION_EVAL_SAME
- , PREF_UNARY_OP_EMPTY_ALWAYS_FALSE_ON_TYPE
- , PREF_UNARY_OP_MINUS_ON_NULL_ALWAYS_ZERO
- , PREF_UNARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION
- , PREF_UNARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN
- , PREF_UNARY_OP_STRING_CONVERSION_NOT_GUARANTEED
- , PREF_CANNOT_APPLY_OPERATOR_TO_METHOD_BINDING
- , PREF_MEMBER_NOT_FOUND
- , PREF_VARIABLE_NOT_FOUND
- , PREF_MISSING_CLOSING_EXPR_BRACKET
- , PREF_GENERAL_SYNTAX_ERROR
- , PREF_EMPTY_EL_EXPRESSION
- , PREF_BINARY_OP_DOT_WITH_VALUEB_NULL
- , PREF_BINARY_OP_DOT_WITH_DOTTED_KEY_SHOULD_USE_ARRAY
- , PREF_POSSIBLE_ARRAY_INDEX_OUT_OF_BOUNDS
- , PREF_BINARY_COMPARISON_WITH_ENUM_ALWAYS_SAME
- , PREF_BINARY_OP_COMPARISON_OF_ENUMS_INCOMPATIBLE
- , PREF_MEMBER_IS_INTERMEDIATE
- , PREF_INCOMPATIBLE_METHOD_TYPES
- , PREF_INCOMPATIBLE_TYPES
- , PREF_METHOD_EXPRESSION_EXPECTED
- , PREF_PROPERTY_NOT_READABLE
- , PREF_PROPERTY_NOT_WRITABLE
- , PREF_VALUE_EXPRESSION_EXPECTED
- };
-
- if (EXPECTED_PREFS != keys.length)
- {
- JSFUiPlugin.log(IStatus.WARNING, "Expected "+EXPECTED_PREFS+" preferences but was "+keys.length, new Throwable()); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- return keys;
- }
-
- /*
- * @see org.eclipse.jface.preference.PreferencePage#createContents(Composite)
- */
- protected Control createContents(Composite parent) {
- fPixelConverter= new PixelConverter(parent);
- setShell(parent.getShell());
-
- Group mainComp= new Group(parent, SWT.NONE);
- mainComp.setFont(parent.getFont());
- GridLayout layout= new GridLayout();
- layout.marginHeight= 0;
- layout.marginWidth= 0;
- mainComp.setLayout(layout);
- mainComp.setText(PreferencesMessages.ProblemSeveritiesConfigurationBlock_common_description);
-
- Composite commonComposite= createStyleTabContent(mainComp);
- GridData gridData= new GridData(GridData.FILL, GridData.FILL, true, true);
- gridData.heightHint= fPixelConverter.convertHeightInCharsToPixels(20);
- commonComposite.setLayoutData(gridData);
-
- validateSettings(null, null, null);
-
- return mainComp;
- }
-
- private Composite createStyleTabContent(Composite folder) {
- String[] errorWarningIgnore= new String[] { Severity.ERROR.toString(), Severity.WARNING.toString(), Severity.IGNORE.toString() };
-
- String[] errorWarningIgnoreLabels= new String[] {
- PreferencesMessages.ProblemSeveritiesConfigurationBlock_error,
- PreferencesMessages.ProblemSeveritiesConfigurationBlock_warning,
- PreferencesMessages.ProblemSeveritiesConfigurationBlock_ignore
- };
-
- //String[] enabledDisabled= new String[] { ENABLED, DISABLED };
-
- int nColumns= 3;
-
- final ScrolledPageContent sc1 = new ScrolledPageContent(folder);
-
- Composite composite= sc1.getBody();
- GridLayout layout= new GridLayout(nColumns, false);
- layout.marginHeight= 0;
- layout.marginWidth= 0;
- composite.setLayout(layout);
-
-// Label description= new Label(composite, SWT.LEFT | SWT.WRAP);
-// description.setFont(description.getFont());
-// description.setText(PreferencesMessages.ProblemSeveritiesConfigurationBlock_common_description);
-// description.setLayoutData(new GridData(GridData.BEGINNING, GridData.CENTER, true, false, nColumns - 1, 1));
-
- int indentStep= fPixelConverter.convertWidthInCharsToPixels(1);
-
- int defaultIndent= indentStep * 0;
- //int extraIndent= indentStep * 2;
- String label;
- ExpandableComposite excomposite;
- Composite inner;
-
- // -- general errors
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_general;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_general_syntax_error;
- addComboBox(inner, label, PREF_GENERAL_SYNTAX_ERROR, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_empty_el_expression;
- addComboBox(inner, label, PREF_EMPTY_EL_EXPRESSION, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_missing_closing_expr_bracket;
- addComboBox(inner, label, PREF_MISSING_CLOSING_EXPR_BRACKET, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_cannot_apply_operator_to_method_binding;
- addComboBox(inner, label, PREF_CANNOT_APPLY_OPERATOR_TO_METHOD_BINDING, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_dotted_property_key_should_use_array;
- addComboBox(inner, label, PREF_BINARY_OP_DOT_WITH_DOTTED_KEY_SHOULD_USE_ARRAY, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- // --- id resolution
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_id_resolution;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_variable_not_found;
- addComboBox(inner, label, PREF_VARIABLE_NOT_FOUND, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_member_not_found;
- addComboBox(inner, label, PREF_MEMBER_NOT_FOUND, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_member_is_intermediate;
- addComboBox(inner, label, PREF_MEMBER_IS_INTERMEDIATE, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- // --- type coercion problems
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_type_coercion_problems;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_binary_op_numeric_coercion_error;
- addComboBox(inner, label, PREF_BINARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_binary_op_boolean_coercion_error;
- addComboBox(inner, label, PREF_BINARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_binary_op_no_coercion_available;
- addComboBox(inner, label, PREF_BINARY_OP_NO_AVAILABLE_TYPE_COERCION, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_binary_op_literal_to_number_coercion_error;
- addComboBox(inner, label, PREF_BINARY_OP_COULD_NOT_COERCE_LITERALS_TO_NUMBERS, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_unary_op_numeric_coercion_error;
- addComboBox(inner, label, PREF_UNARY_OP_COULD_NOT_MAKE_NUMERIC_COERCION, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_unary_op_boolean_coercion_error;
- addComboBox(inner, label, PREF_UNARY_OP_CANNOT_COERCE_ARGUMENT_TO_BOOLEAN, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_unary_op_string_coercion_not_guaranteed;
- addComboBox(inner, label, PREF_UNARY_OP_STRING_CONVERSION_NOT_GUARANTEED, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- // --- constant folder and unused code
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_constant_folding_and_unused_code;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_both_binary_operands_null;
- addComboBox(inner, label, PREF_BINARY_OP_BOTH_OPERANDS_NULL, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_binary_expression_always_evaluates_same;
- addComboBox(inner, label, PREF_BINARY_OP_CONSTANT_EXPRESSION_ALWAYS_EVAL_SAME, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_equality_with_null_always_same;
- addComboBox(inner, label, PREF_BINARY_OP_EQUALITY_COMP_WITH_NULL_ALWAYS_EVAL_SAME, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_enumeration_comparision_always_same;
- addComboBox(inner, label, PREF_BINARY_COMPARISON_WITH_ENUM_ALWAYS_SAME, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_unary_expression_always_evaluates_same;
- addComboBox(inner, label, PREF_UNARY_OP_CONSTANT_EXPRESSION_EVAL_SAME, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_empty_expression_always_false;
- addComboBox(inner, label, PREF_UNARY_OP_EMPTY_ALWAYS_FALSE_ON_TYPE, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_minus_on_null_always_zero;
- addComboBox(inner, label, PREF_UNARY_OP_MINUS_ON_NULL_ALWAYS_ZERO, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_first_argument_short_circuits_expression;
- addComboBox(inner, label, PREF_BINARY_OP_FIRST_ARGUMENT_SHORT_CIRCUITS, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_second_argument_always_evaluates_same;
- addComboBox(inner, label, PREF_BINARY_OP_SECOND_ARGUMENT_ALWAYS_EVAL_SAME, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_apply_dot_operator_with_null;
- addComboBox(inner, label, PREF_BINARY_OP_DOT_WITH_VALUEB_NULL, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- // --- possible programming errors
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_programming_errors;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_possible_division_by_zero;
- addComboBox(inner, label, PREF_BINARY_OP_POSSIBLE_DIVISION_BY_ZERO, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_possible_array_index_out_of_bounds;
- addComboBox(inner, label, PREF_POSSIBLE_ARRAY_INDEX_OUT_OF_BOUNDS, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_incompatible_enumeration_comparison;
- addComboBox(inner, label, PREF_BINARY_OP_COMPARISON_OF_ENUMS_INCOMPATIBLE, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- // --- type comparison with expected
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_section_type_comparison;
- excomposite= createStyleSection(composite, label, nColumns);
-
- inner= new Composite(excomposite, SWT.NONE);
- inner.setFont(composite.getFont());
- inner.setLayout(new GridLayout(nColumns, false));
- excomposite.setClient(inner);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_method_expression_expected;
- addComboBox(inner, label, PREF_METHOD_EXPRESSION_EXPECTED, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_incompatible_type_assignment;
- addComboBox(inner, label, PREF_INCOMPATIBLE_TYPES, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_value_expression_expected;
- addComboBox(inner, label, PREF_VALUE_EXPRESSION_EXPECTED, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_incompatible_method_types;
- addComboBox(inner, label, PREF_INCOMPATIBLE_METHOD_TYPES, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_property_not_readable;
- addComboBox(inner, label, PREF_PROPERTY_NOT_READABLE, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- label= PreferencesMessages.ProblemSeveritiesConfigurationBlock_pb_property_not_writable;
- addComboBox(inner, label, PREF_PROPERTY_NOT_WRITABLE, errorWarningIgnore, errorWarningIgnoreLabels, defaultIndent);
-
- new Label(composite, SWT.NONE);
-
- IDialogSettings section= JSFUiPlugin.getDefault().getDialogSettings().getSection(SETTINGS_SECTION_NAME);
- restoreSectionExpansionStates(section);
-
- return sc1;
- }
-
- /* (non-javadoc)
- * Update fields and validate.
- * @param changedKey Key that changed, or null, if all changed.
- */
- protected void validateSettings(Key changedKey, String oldValue, String newValue) {
- if (!areSettingsEnabled()) {
- return;
- }
-
-// if (changedKey != null) {
-// if (PREF_PB_UNUSED_PARAMETER.equals(changedKey) ||
-// PREF_PB_DEPRECATION.equals(changedKey) ||
-// PREF_PB_LOCAL_VARIABLE_HIDING.equals(changedKey) ||
-// PREF_PB_UNUSED_DECLARED_THROWN_EXCEPTION.equals(changedKey)) {
-// updateEnableStates();
-// } else if (PREF_PB_SIGNAL_PARAMETER_IN_OVERRIDING.equals(changedKey)) {
-// // merging the two options
-// setValue(PREF_PB_SIGNAL_PARAMETER_IN_ABSTRACT, newValue);
-// } else {
-// return;
-// }
-// } else {
- updateEnableStates();
-// }
- // TODO: fContext.statusChanged(new StatusInfo());
- }
-
- private void updateEnableStates() {
-// boolean enableUnusedParams= !checkValue(PREF_PB_UNUSED_PARAMETER, Severity.IGNORE.toString());
-// getCheckBox(PREF_PB_SIGNAL_PARAMETER_IN_OVERRIDING).setEnabled(enableUnusedParams);
-// getCheckBox(PREF_PB_UNUSED_PARAMETER_INCLUDE_DOC_COMMENT_REFERENCE).setEnabled(enableUnusedParams);
-//
-// boolean enableDeprecation= !checkValue(PREF_PB_DEPRECATION, Severity.IGNORE.toString());
-// getCheckBox(PREF_PB_DEPRECATION_IN_DEPRECATED_CODE).setEnabled(enableDeprecation);
-// getCheckBox(PREF_PB_DEPRECATION_WHEN_OVERRIDING).setEnabled(enableDeprecation);
-//
-// boolean enableThrownExceptions= !checkValue(PREF_PB_UNUSED_DECLARED_THROWN_EXCEPTION, Severity.IGNORE.toString());
-// getCheckBox(PREF_PB_UNUSED_DECLARED_THROWN_EXCEPTION_WHEN_OVERRIDING).setEnabled(enableThrownExceptions);
-//
-// boolean enableHiding= !checkValue(PREF_PB_LOCAL_VARIABLE_HIDING, Severity.IGNORE.toString());
-// getCheckBox(PREF_PB_SPECIAL_PARAMETER_HIDING_FIELD).setEnabled(enableHiding);
- }
-
- protected String[] getFullBuildDialogStrings(boolean workspaceSettings) {
- String title= PreferencesMessages.ProblemSeveritiesConfigurationBlock_needsbuild_title;
- String message;
- if (workspaceSettings) {
- message= PreferencesMessages.ProblemSeveritiesConfigurationBlock_needsfullbuild_message;
- } else {
- message= PreferencesMessages.ProblemSeveritiesConfigurationBlock_needsprojectbuild_message;
- }
- return new String[] { title, message };
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jdt.internal.ui.preferences.OptionsConfigurationBlock#dispose()
- */
- public void dispose() {
- IDialogSettings section= JSFUiPlugin.getDefault().getDialogSettings().addNewSection(SETTINGS_SECTION_NAME);
- storeSectionExpansionStates(section);
- super.dispose();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ScrolledPageContent.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ScrolledPageContent.java
deleted file mode 100644
index 5cc17717d..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ScrolledPageContent.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2000, 2005 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
- * Oracle - updated for JSF tools
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.forms.FormColors;
-import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.eclipse.ui.forms.widgets.SharedScrolledComposite;
-
-
-/**
- * Customized SharedScrolledComposite
- */
-/*package*/ class ScrolledPageContent extends SharedScrolledComposite {
-
- private FormToolkit fToolkit;
-
- /**
- * @param parent
- */
- public ScrolledPageContent(Composite parent) {
- this(parent, SWT.V_SCROLL | SWT.H_SCROLL);
- }
-
- /**
- * @param parent
- * @param style
- */
- public ScrolledPageContent(Composite parent, int style) {
- super(parent, style);
-
- setFont(parent.getFont());
-
- initDialogsFormToolkit();
-
- setExpandHorizontal(true);
- setExpandVertical(true);
-
- Composite body= new Composite(this, SWT.NONE);
- body.setFont(parent.getFont());
- setContent(body);
- }
-
- private FormToolkit initDialogsFormToolkit()
- {
- if (fToolkit == null) {
- FormColors colors= new FormColors(Display.getCurrent());
- colors.setBackground(null);
- colors.setForeground(null);
- fToolkit= new FormToolkit(colors);
- }
- return fToolkit;
- }
-
- /**
- * @param childControl
- */
- public void adaptChild(Control childControl) {
- fToolkit.adapt(childControl, true, true);
- }
-
- /**
- * @return the content composite
- */
- public Composite getBody() {
- return (Composite) getContent();
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/SeverityOverrideStrategy.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/SeverityOverrideStrategy.java
deleted file mode 100644
index 18cd3ca73..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/SeverityOverrideStrategy.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.emf.common.util.Diagnostic;
-import org.eclipse.jst.jsf.common.internal.strategy.IIdentifiableStrategy;
-
-/**
- * A strategy for overriding the severity of diagnostics.
- */
-abstract class SeverityOverrideStrategy implements IIdentifiableStrategy<Diagnostic, Integer, String>
-{
- private final String _id;
-
- public SeverityOverrideStrategy(final String id)
- {
- _id = id;
- }
-
- public abstract Integer override(Diagnostic diagnostic);
-
- public abstract String getDisplayName();
-
- public Integer getNoResult()
- {
- return Integer.valueOf(-1);
- }
-
- public final Integer perform(Diagnostic diagnostic) throws Exception
- {
- return override(diagnostic);
- }
-
- public final String getId()
- {
- return _id;
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationMessageFactory.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationMessageFactory.java
deleted file mode 100644
index 1d05ae855..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationMessageFactory.java
+++ /dev/null
@@ -1,159 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Oracle Corporation.
- * 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:
- * Cameron Bateman/Oracle - initial API and implementation
- *
- ********************************************************************************/
-
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.emf.common.util.Diagnostic;
-import org.eclipse.jst.jsf.common.internal.types.TypeComparatorDiagnosticFactory;
-import org.eclipse.jst.jsf.validation.internal.ELValidationPreferences;
-import org.eclipse.jst.jsf.validation.internal.JSFTypeComparatorPreferences;
-import org.eclipse.jst.jsf.validation.internal.ValidationPreferences;
-import org.eclipse.jst.jsf.validation.internal.el.diagnostics.DiagnosticFactory;
-import org.eclipse.wst.validation.internal.core.Message;
-import org.eclipse.wst.validation.internal.provisional.core.IMessage;
-
-/**
- * Creates configured validation Message objects.
- *
- * @author cbateman
- *
- */
-public final class ValidationMessageFactory
-{
- private final Map<String, SeverityOverrideStrategy> _strategies;
-
- /**
- * @param prefs
- *
- */
- public ValidationMessageFactory(final ValidationPreferences prefs)
- {
- _strategies = new HashMap<String, SeverityOverrideStrategy>();
- _strategies.put(DiagnosticFactory.SOURCE_ID,
- new ELSeverityOverrideStrategy(prefs));
- _strategies.put(TypeComparatorDiagnosticFactory.SOURCE_IDENTIFIER,
- new TypeComparatorOverrideStrategy(prefs));
- }
-
- /**
- * @param diagnostic
- * @param offset
- * @param length
- * @param file
- * @return a configured message
- */
- public Message createFromDiagnostic(final Diagnostic diagnostic,
- final int offset, final int length, final IFile file)
- {
- int severity = diagnostic.getSeverity();
- final String sourceId = diagnostic.getSource();
- final SeverityOverrideStrategy strategy = _strategies.get(sourceId);
-
- // only override if there's a strategy to do so
- if (strategy != null)
- {
- final Integer value = strategy.override(diagnostic);
- if (value != null)
- {
- severity = value.intValue();
- }
- }
-
- final Message message = new MyLocalizedMessage(
- convertSeverity(severity), diagnostic.getMessage(), file,
- diagnostic.getCode());
-
- message.setOffset(offset);
- message.setLength(length);
-
- return message;
- }
-
- /**
- * @param severity
- * @return a Message severity equivilent to diagnostic.getSeverity()
- */
- private int convertSeverity(final int severity)
- {
- switch (severity)
- {
- case Diagnostic.ERROR:
- return IMessage.HIGH_SEVERITY;
- case Diagnostic.WARNING:
- return IMessage.NORMAL_SEVERITY;
- case Diagnostic.INFO:
- return IMessage.LOW_SEVERITY;
- case Diagnostic.OK:
- default:
- // no bits set
- return 0;
- }
- }
-
- private static class ELSeverityOverrideStrategy extends
- SeverityOverrideStrategy
- {
- private final ValidationPreferences _prefs;
-
- public ELSeverityOverrideStrategy(final ValidationPreferences prefs)
- {
- super(DiagnosticFactory.SOURCE_ID);
- _prefs = prefs;
- }
-
- @Override
- public Integer override(final Diagnostic diagnostic)
- {
- final int code = diagnostic.getCode();
- final ELValidationPreferences elPrefs = _prefs.getElPrefs();
- return Integer.valueOf(elPrefs.getDiagnosticSeverity(code));
- }
-
- @Override
- public String getDisplayName()
- {
- return Messages.ValidationMessageFactory_DefaultElSeverityDisplayName;
- }
- }
-
- private static class TypeComparatorOverrideStrategy extends
- SeverityOverrideStrategy
- {
- private final ValidationPreferences _prefs;
-
- public TypeComparatorOverrideStrategy(final ValidationPreferences prefs)
- {
- super(TypeComparatorDiagnosticFactory.SOURCE_IDENTIFIER);
- _prefs = prefs;
- }
-
- @Override
- public Integer override(final Diagnostic diagnostic)
- {
- final int code = diagnostic.getCode();
- final JSFTypeComparatorPreferences jsfTypeCompPrefs = _prefs
- .getTypeComparatorPrefs();
- return Integer
- .valueOf(jsfTypeCompPrefs.getDiagnosticSeverity(code));
- }
-
- @Override
- public String getDisplayName()
- {
- return Messages.ValidationMessageFactory_DefaultTypeComparatorDisplayName;
- }
- }
-} \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationReporter.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationReporter.java
deleted file mode 100644
index e5f041189..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/ValidationReporter.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2008 Oracle 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:
- * Oracle Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.jsf.ui.internal.validation;
-
-import org.eclipse.core.resources.IFile;
-import org.eclipse.emf.common.util.Diagnostic;
-import org.eclipse.jst.jsf.validation.internal.IJSFViewValidator;
-import org.eclipse.jst.jsf.validation.internal.ValidationPreferences;
-import org.eclipse.wst.validation.internal.provisional.core.IMessage;
-import org.eclipse.wst.validation.internal.provisional.core.IReporter;
-import org.eclipse.wst.validation.internal.provisional.core.IValidator;
-
-/*package*/class ValidationReporter implements
- IJSFViewValidator.IValidationReporter
-{
- private final IValidator _validator;
- private final IReporter _reporter;
- private final IFile _file;
- private final ValidationMessageFactory _factory;
-
- public ValidationReporter(final IValidator validator,
- final IReporter reporter, final IFile file,
- final ValidationPreferences prefs)
- {
- _validator = validator;
- _reporter = reporter;
- _file = file;
- _factory = new ValidationMessageFactory(prefs);
- }
-
- public void report(final Diagnostic problem, final int start,
- final int length)
- {
- final IMessage message = _factory.createFromDiagnostic(
- problem, start, length, _file);
-
- if ((message.getSeverity() & IMessage.ALL_MESSAGES) != 0)
- {
- _reporter.addMessage(_validator, message);
- }
- }
-
- public void report(IMessage message)
- {
- if ((message.getSeverity() & IMessage.ALL_MESSAGES) != 0)
- {
- _reporter.addMessage(_validator, message);
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/messages.properties b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/messages.properties
deleted file mode 100644
index 9339a4ff9..000000000
--- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/validation/messages.properties
+++ /dev/null
@@ -1,74 +0,0 @@
-###############################################################################
-# Copyright (c) 2000, 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
-# John Kaplan, johnkaplantech@gmail.com - 108071 [code templates] template for body of newly created class
-# Cameron Bateman/Oracle - adapted for use in JSF validation tooling
-###############################################################################
-
-ProblemSeveritiesPreferencePage_title=Problem Severities
-
-ProblemSeveritiesConfigurationBlock_error=Error
-ProblemSeveritiesConfigurationBlock_warning=Warning
-ProblemSeveritiesConfigurationBlock_ignore=Ignore
-
-ProblemSeveritiesConfigurationBlock_section_id_resolution=&Identifier Resolution
-ProblemSeveritiesConfigurationBlock_section_general=&General Problems
-ProblemSeveritiesConfigurationBlock_section_type_coercion_problems=&Type Coercion Problems
-ProblemSeveritiesConfigurationBlock_section_constant_folding_and_unused_code=&Constant folding and unused code
-ProblemSeveritiesConfigurationBlock_section_programming_errors=&Possible programming errors
-ProblemSeveritiesConfigurationBlock_section_type_comparison=Type &Assignment Problems
-
-ProblemSeveritiesConfigurationBlock_needsbuild_title=Error/Warning Settings Changed
-ProblemSeveritiesConfigurationBlock_needsfullbuild_message=The Error/Warning settings have changed. You will need to rebuild or revalidate for these changes to take effect.
-ProblemSeveritiesConfigurationBlock_needsprojectbuild_message=The Error/Warning settings have changed. A rebuild of the project is required for changes to take effect. Build the project now?
-ProblemSeveritiesConfigurationBlock_buildwarning_dont_show_again=Don't show this dialog again
-
-ProblemSeveritiesConfigurationBlock_common_description=Select the severity level for the following problems
-
-ProblemSeveritiesConfigurationBlock_pb_general_syntax_error=General Syntax Error
-ProblemSeveritiesConfigurationBlock_pb_empty_el_expression=Empty EL expression
-ProblemSeveritiesConfigurationBlock_pb_missing_closing_expr_bracket=Missing closing bracket on expression
-ProblemSeveritiesConfigurationBlock_pb_cannot_apply_operator_to_method_binding=Applying operator to method binding
-ProblemSeveritiesConfigurationBlock_pb_dotted_property_key_should_use_array=Dotted property names should use array ([]) syntax
-
-ProblemSeveritiesConfigurationBlock_pb_variable_not_found=Variable not found
-ProblemSeveritiesConfigurationBlock_pb_member_not_found=Member not found
-ProblemSeveritiesConfigurationBlock_pb_member_is_intermediate=Member is intermediate
-
-ProblemSeveritiesConfigurationBlock_pb_binary_op_numeric_coercion_error=Binary operation number coercion problems
-ProblemSeveritiesConfigurationBlock_pb_binary_op_boolean_coercion_error=Binary operation boolean coercion problems
-ProblemSeveritiesConfigurationBlock_pb_binary_op_no_coercion_available=Binary operation no available coercions
-ProblemSeveritiesConfigurationBlock_pb_binary_op_literal_to_number_coercion_error=Binary coercion of literal to number
-ProblemSeveritiesConfigurationBlock_pb_unary_op_numeric_coercion_error=Unary operation number coercion problems
-ProblemSeveritiesConfigurationBlock_pb_unary_op_boolean_coercion_error=Unary operation boolean coercion problems
-ProblemSeveritiesConfigurationBlock_pb_unary_op_string_coercion_not_guaranteed=Unary operation string coercion not guaranteed
-
-ProblemSeveritiesConfigurationBlock_pb_both_binary_operands_null=Both operands null
-ProblemSeveritiesConfigurationBlock_pb_binary_expression_always_evaluates_same=Binary expression always evaluates to same value
-ProblemSeveritiesConfigurationBlock_pb_equality_with_null_always_same=Equality comparison with null always evaluates to same value
-ProblemSeveritiesConfigurationBlock_pb_unary_expression_always_evaluates_same=Unary expression always evaluates to same value
-ProblemSeveritiesConfigurationBlock_pb_empty_expression_always_false=Empty operator always resolves to false on type
-ProblemSeveritiesConfigurationBlock_pb_enumeration_comparision_always_same=Enumeration comparison always evaluates to same value
-ProblemSeveritiesConfigurationBlock_pb_minus_on_null_always_zero=Minus applied to null always evaluates to zero
-ProblemSeveritiesConfigurationBlock_pb_first_argument_short_circuits_expression=First argument short-circuits expression
-ProblemSeveritiesConfigurationBlock_pb_second_argument_always_evaluates_same=Second argument always evaluates the same
-ProblemSeveritiesConfigurationBlock_pb_apply_dot_operator_with_null=Applying the dot ('.') operator with null always returns null
-
-ProblemSeveritiesConfigurationBlock_pb_possible_division_by_zero=Possible division by zero
-ProblemSeveritiesConfigurationBlock_pb_possible_array_index_out_of_bounds=Possible array index out of bounds
-ProblemSeveritiesConfigurationBlock_pb_incompatible_enumeration_comparison=Incompatible enumeration comparison
-
-ProblemSeveritiesConfigurationBlock_pb_method_expression_expected=Method expression expected
-ProblemSeveritiesConfigurationBlock_pb_incompatible_type_assignment=Value expression type incompatibility
-ProblemSeveritiesConfigurationBlock_pb_value_expression_expected= Value expression expected
-ProblemSeveritiesConfigurationBlock_pb_incompatible_method_types=Method expression signature incompatibility
-ProblemSeveritiesConfigurationBlock_pb_property_not_readable=Property expected to be readable but has no getter
-ProblemSeveritiesConfigurationBlock_pb_property_not_writable=Property expected to be writable but has no setter
-ValidationMessageFactory_DefaultElSeverityDisplayName=EL Preference Severities
-ValidationMessageFactory_DefaultTypeComparatorDisplayName=Type Comparison Preference Severities
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.classpath b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.classpath
deleted file mode 100644
index 304e86186..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.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.5"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.cvsignore b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.cvsignore
deleted file mode 100644
index f9eb27a99..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.cvsignore
+++ /dev/null
@@ -1,3 +0,0 @@
-build.xml
-@dot
-javaCompiler...args
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.project b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.project
deleted file mode 100644
index 9685725db..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.jst.pagedesigner.jsp.core</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/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.core.resources.prefs b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index 1c9084e5b..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Sun May 27 16:05:25 EDT 2007
-eclipse.preferences.version=1
-encoding/<project>=ISO-8859-1
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index d8bc1cd51..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,82 +0,0 @@
-#Mon Jun 30 15:58:19 PDT 2008
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
-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.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=warning
-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=ignore
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=warning
-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=warning
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-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=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
-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=ignore
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=error
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-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=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.5
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.ui.prefs b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 82eb6c152..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Fri Apr 06 18:25:15 PDT 2007
-eclipse.preferences.version=1
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates/>
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.pde.prefs b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 851c0c387..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Fri May 30 12:00:06 PDT 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=0
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=0
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/META-INF/MANIFEST.MF b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/META-INF/MANIFEST.MF
deleted file mode 100644
index 3a76efc26..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,27 +0,0 @@
-Manifest-Version: 1.0
-Bundle-Name: %pluginName
-Bundle-SymbolicName: org.eclipse.jst.pagedesigner.jsp.core;singleton:=true
-Bundle-Version: 1.1.1.qualifier
-Bundle-ClassPath: .
-Bundle-Activator: org.eclipse.jst.pagedesigner.jsp.core.JSPCorePlugin
-Bundle-Vendor: %providerName
-Bundle-Localization: plugin
-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.wst.sse.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.wst.xml.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.jst.jsp.core;bundle-version="[1.1.0,1.3.0)",
- org.eclipse.wst.html.core;bundle-version="[1.1.0,1.2.0)",
- org.eclipse.jst.jsf.common;bundle-version="[1.0.0,2.0.0)",
- javax.servlet;bundle-version="[2.4.0,3.0.0)",
- javax.servlet.jsp;bundle-version="[2.0.0,3.0.0)",
- org.apache.commons.el;bundle-version="[1.0.0,2.0.0)"
-Bundle-ActivationPolicy: lazy
-Bundle-ManifestVersion: 2
-Export-Package: org.eclipse.jst.pagedesigner.jsp.core;x-internal:=true,
- org.eclipse.jst.pagedesigner.jsp.core.el;x-internal:=true,
- org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;x-internal:=true,
- org.eclipse.jst.pagedesigner.jsp.core.pagevar;x-internal:=true,
- org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter;x-internal:=true,
- org.eclipse.jst.pagedesigner.jsp.core.util;x-internal:=true
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/about.html b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/about.html
deleted file mode 100644
index 90bd74d4d..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/about.html
+++ /dev/null
@@ -1,22 +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>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>June, 2008</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/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>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.</p>
-
-</body>
-</html>
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/build.properties b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/build.properties
deleted file mode 100644
index 6429d84cb..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/build.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2008 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = plugin.xml,\
- META-INF/,\
- .,\
- schema/,\
- about.html,\
- plugin.properties\
-javacSource=1.5
-javacTarget=1.5 \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.properties b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.properties
deleted file mode 100644
index 3c3f9a1ea..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-###############################################################################
-# Copyright (c) 2001, 2007 Oracle 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:
-# Oracle Corporation - initial API and implementation
-###############################################################################
-####################################################
-# Plugin XML information.
-####################################################
-pluginName=JavaServer Faces Tools - JSP Core Pagedesigner
-providerName=Eclipse.org
-
-extension-point.name.0 = page variable \ No newline at end of file
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.xml b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.xml
deleted file mode 100644
index ea261e8fd..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/plugin.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.0"?>
-<plugin>
- <extension-point id="pageVar" name="%extension-point.name.0" schema="schema/pageVar.exsd"/>
-</plugin>
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/schema/pageVar.exsd b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/schema/pageVar.exsd
deleted file mode 100644
index 962bf34c1..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/schema/pageVar.exsd
+++ /dev/null
@@ -1,172 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.jst.pagedesigner.jsp.core">
-<annotation>
- <appInfo>
- <meta.schema plugin="org.eclipse.jst.pagedesigner.jsp.core" id="pageVar" name="page variable"/>
- </appInfo>
- <documentation>
- [Enter description of this extension point.]
- </documentation>
- </annotation>
-
- <element name="extension">
- <complexType>
- <sequence>
- <element ref="taglib" minOccurs="0" 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>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="tag">
- <complexType>
- <attribute name="varName" type="string" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="varTypeMode" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- <simpleType>
- <restriction base="string">
- <enumeration value="CLASSNAME">
- </enumeration>
- <enumeration value="EXPRESSION">
- </enumeration>
- <enumeration value="EXPRESSION_COLLECTION_ITEM">
- </enumeration>
- <enumeration value="BUNDLE">
- </enumeration>
- </restriction>
- </simpleType>
- </attribute>
- <attribute name="varTypeString" type="string">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="varNameIsAttr" type="boolean" use="default" value="true">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="varTypeStringIsAttr" type="boolean" use="default" value="true">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- <attribute name="tagName" type="string" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
- </complexType>
- </element>
-
- <element name="taglib">
- <complexType>
- <sequence>
- <element ref="tag" minOccurs="0" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="uri" type="string" use="required">
- <annotation>
- <documentation>
-
- </documentation>
- </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>
- /*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-
- </documentation>
- </annotation>
-
-</schema>
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/IJSPCoreConstants.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/IJSPCoreConstants.java
deleted file mode 100644
index e49064680..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/IJSPCoreConstants.java
+++ /dev/null
@@ -1,279 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface IJSPCoreConstants
-{
- /**
- * JSP tag name
- */
- final static public String TAG_ATTRIBUTE = "attribute"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_BODY = "body"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_ELEMENT = "element"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_EXPRESSION = "expression"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_DECLARATION = "declaration"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_DIRECTIVE_INCLUDE = "directive.include"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_DIRECTIVE_PAGE = "directive.page"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_DIRECTIVE_TAGLIB = "directive.taglib"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_DOBODY = "doBody"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_FORWARD = "forward"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_GETPROPERTY = "getProperty"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_INCLUDE = "include"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_INVOKE = "invoke"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_OUTPUT = "output"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_PLUGIN = "plugin"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_ROOT = "root"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_SCRIPTLET = "scriptlet"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_SETPROPERTY = "setProperty"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_TEXT = "text"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_USEBEAN = "useBean"; //$NON-NLS-1$
-
- /**
- * JSP tag name
- */
- final static public String TAG_LEADING_DIRECTIVE = "directive."; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_ALIGN = "align"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_ARCHIVE = "archive"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_BEANNAME = "beanName"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_CLASS = "class"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_CODE = "code"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_CODEBASE = "codebase"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_DOCTYPEROOTELEMENT = "doctype-root-element"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_DOCTYPESYSTEM = "doctype-system"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_DOCTYPEPUBLIC = "doctype-public"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_FILE = "file"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_FRAGMENT = "fragment"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_HEIGHT = "height"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_HSPACE = "hspace"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_ID = "id"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_IEPLUGINURL = "iepluginurl"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_JREVERSION = "jreversion"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_NAME = "name"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_NSPLUGINURL = "nspluginurl"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_OMITXMLDECLARATION = "omit-xml-declaration"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_PAGE = "page"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_PROPERTY = "property"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_SCOPE = "scope"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_TRIM = "trim"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_TYPE = "type"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_URI = "uri"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_VALUE = "value"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_VAR = "var"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_VARREADER = "varReader"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_VERSION = "version"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_XMLNSJSP = "xmlns:jsp"; //$NON-NLS-1$
-
- /**
- * JSP tag attribute name
- */
- final static public String ATTR_XMLNSTAGLIBPREFIX = "xmlns:taglibPrefix"; //$NON-NLS-1$
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/JSPCorePlugin.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/JSPCorePlugin.java
deleted file mode 100644
index 4ea96745f..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/JSPCorePlugin.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core;
-
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.Plugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class JSPCorePlugin extends Plugin {
- // The shared instance.
- private static JSPCorePlugin plugin;
-
- // Resource bundle.
- private ResourceBundle resourceBundle;
-
- /**
- * The constructor.
- */
- public JSPCorePlugin() {
- super();
- plugin = this;
- try {
- resourceBundle = ResourceBundle
- .getBundle("org.eclipse.jst.pagedesigner.jsp.core.JSPCorePluginResources"); //$NON-NLS-1$
- } catch (MissingResourceException x) {
- resourceBundle = null;
- }
- }
-
- /**
- * 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);
- }
-
- /**
- * Returns the shared instance.
- * @return the default plugin instance
- */
- public static JSPCorePlugin getDefault() {
- return plugin;
- }
-
- /**
- * Returns the string from the plugin's resource bundle, or 'key' if not
- * found.
- * @param key
- * @return the string for key or 'key' if not found in the default resource bundle
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = JSPCorePlugin.getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the plugin's resource bundle,
- * @return the resource bundle
- */
- public ResourceBundle getResourceBundle() {
- return resourceBundle;
- }
-
- /**
- * @return the plugin id
- */
- public static String getPluginId() {
- return getDefault().getBundle().getSymbolicName();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/ListenerList.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/ListenerList.java
deleted file mode 100644
index 9596f97d8..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/ListenerList.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core;
-
-/**
- * Local version of org.eclipse.jface.util.ListenerList (modified)
- * @author mengbo
- * @version 1.5
- */
-public class ListenerList {
- /**
- * The current number of listeners. Maintains invariant: 0 <= fSize <=
- * listeners.length.
- */
- private int _size;
-
- /**
- * The list of listeners. Initially <code>null</code> but initialized to
- * an array of size capacity the first time a listener is added. Maintains
- * invariant: listeners != null if and only if fSize != 0
- */
- private Object[] _listeners = null;
-
- /**
- * The empty array singleton instance, returned by getListeners() when size ==
- * 0.
- */
- private static final Object[] EmptyArray = new Object[0];
-
- /**
- * Creates a listener list with the given initial capacity.
- *
- * @param capacity
- * the number of listeners which this list can initially accept
- * without growing its internal representation; must be at least
- * 1
- */
- public ListenerList(int capacity) {
- if (capacity < 1) {
- throw new IllegalArgumentException();
- }
- _listeners = new Object[capacity];
- _size = 0;
- }
-
- /**
- * Adds a listener to the list. Has no effect if an identical listener is
- * already registered.
- *
- * @param listener
- * a listener
- */
- public synchronized void add(Object listener) {
- if (listener == null) {
- throw new IllegalArgumentException();
- }
- // check for duplicates using identity
- for (int i = 0; i < _size; ++i) {
- if (_listeners[i] == listener) {
- return;
- }
- }
- // grow array if necessary
- if (_size == _listeners.length) {
- Object[] temp = new Object[(_size * 2) + 1];
- System.arraycopy(_listeners, 0, temp, 0, _size);
- _listeners = temp;
- }
- _listeners[_size++] = listener;
- }
-
- /**
- * Returns an array containing all the registered listeners. The resulting
- * array is unaffected by subsequent adds or removes. If there are no
- * listeners registered, the result is an empty array singleton instance (no
- * garbage is created). Use this method when notifying listeners, so that
- * any modifications to the listener list during the notification will have
- * no effect on the notification itself.
- * @return the array of registered listeners
- */
- public synchronized Object[] getListeners() {
- if (_size == 0) {
- return EmptyArray;
- }
- Object[] result = new Object[_size];
- System.arraycopy(_listeners, 0, result, 0, _size);
- return result;
- }
-
- /**
- * Removes a listener from the list. Has no effect if an identical listener
- * was not already registered.
- *
- * @param listener
- * a listener
- */
- public synchronized void remove(Object listener) {
- if (listener == null) {
- throw new IllegalArgumentException();
- }
-
- for (int i = 0; i < _size; ++i) {
- if (_listeners[i] == listener) {
- if (--_size == 0) {
- _listeners = new Object[1];
- } else {
- if (i < _size) {
- _listeners[i] = _listeners[_size];
- }
- _listeners[_size] = null;
- }
- return;
- }
- }
- }
-
- /**
- * Removes all the listeners from the list.
- */
- public void removeAll() {
- _listeners = new Object[0];
- _size = 0;
- }
-
- /**
- * Returns the number of registered listeners
- *
- * @return the number of registered listeners
- */
- public int size() {
- return _size;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/ELParser.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/ELParser.java
deleted file mode 100644
index 9c3ee7f64..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/ELParser.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.el;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.commons.el.ComplexValue;
-import org.apache.commons.el.NamedValue;
-
-/**
- *
- * @author mengbo
- * @version 1.5
- */
-public class ELParser {
- private String _jsfExpression;
-
- private List _expressionList;
-
- /**
- * @param expression
- *
- */
- public ELParser(String expression) {
- super();
- _jsfExpression = expression;
- init();
- }
-
- /**
- *
- */
- private void init() {
- Object parsedExpression = JSFELParserHelper
- .parseExpression(_jsfExpression);
-
- if (parsedExpression instanceof ComplexValue) {
- _expressionList = new ArrayList();
- _expressionList.add(((ComplexValue) parsedExpression).getPrefix());
- _expressionList.addAll(((ComplexValue) parsedExpression)
- .getSuffixes());
- } else if (parsedExpression instanceof NamedValue) {
- _expressionList = new ArrayList();
- _expressionList.add(parsedExpression);
- }
-
- }
-
- /**
- * @return the expression elements of null if none
- */
- public Object[] getElements() {
- if (_expressionList == null) {
- return null;
- }
-
- return _expressionList.toArray();
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/JSFELParserHelper.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/JSFELParserHelper.java
deleted file mode 100644
index b8bca4e18..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/el/JSFELParserHelper.java
+++ /dev/null
@@ -1,267 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.el;
-
-import java.io.StringReader;
-
-import org.apache.commons.el.Expression;
-import org.apache.commons.el.ExpressionString;
-import org.apache.commons.el.parser.ELParser;
-import org.apache.commons.el.parser.ParseException;
-
-/**
- * Utility class to implement support functionality to "morph" JSP EL into JSF
- * EL
- *
- * @author mengbo
- * @version 1.5
- */
-public final class JSFELParserHelper {
- /**
- * an EL left brace
- */
- public static String JSF_EL_LEFT_BRACE = "#{"; //$NON-NLS-1$
-
- /**
- * an EL right brace
- */
- public static String JSF_EL_RIGHT_BRACE = "}"; //$NON-NLS-1$
-
- private JSFELParserHelper() {
- // util class, do not instantiate
- }
-
- /**
- * Gets the parsed form of the given expression string. Returns either an
- * Expression or ExpressionString.
- * @param expressionString
- * @return the result of parsing expressionString
- */
- public static Object parseExpression(String expressionString) {
- expressionString = toJspElExpression(expressionString);
-
- ELParser parser = new ELParser(new StringReader(expressionString));
- try {
- Object expression = parser.ExpressionString();
- if (!(expression instanceof Expression)
- && !(expression instanceof ExpressionString)) {
- return null;
- }
-
- return expression;
- } catch (ParseException e) {
-
- // String msg = "Invalid expression: '" + expressionString + "'";
- // log.debug(msg, e);
- // throw new ReferenceSyntaxException(msg, e);
- }
- return null;
- }
-
- /**
- * @param expressionString
- * @return true if the expression is 'valid'
- */
- public static boolean isValidEL(String expressionString) {
- if (expressionString == null || expressionString.length() == 0) {
- return false;
- }
-
- return expressionString.startsWith(JSF_EL_LEFT_BRACE)
- && expressionString.endsWith(JSF_EL_RIGHT_BRACE);
- }
-
- /**
- * @param expressionString
- * @return expressionString with the left and right braces removed
- * or the original string if isValidEL(expression) == false
- */
- public static String trimELBrace(String expressionString) {
- if (!isValidEL(expressionString)) {
- return expressionString;
- }
- String trimedExpression = null;
-
- trimedExpression = expressionString.substring(JSF_EL_LEFT_BRACE
- .length(), expressionString.length()
- - JSF_EL_RIGHT_BRACE.length());
-
- return trimedExpression;
- }
-
- /**
- * Convert ValueBinding syntax #{ } to JSP EL syntax ${ }
- *
- * @param expressionString
- * <code>ValueBinding</code> reference expression
- *
- * @return JSP EL compatible expression
- */
- public static String toJspElExpression(String expressionString) {
- StringBuffer sb = new StringBuffer(expressionString.length());
- int remainsPos = 0;
-
- for (int posOpenBrace = expressionString.indexOf('{'); posOpenBrace >= 0; posOpenBrace = expressionString
- .indexOf('{', remainsPos)) {
- if (posOpenBrace > 0) {
- if (posOpenBrace - 1 > remainsPos)
- sb.append(expressionString.substring(remainsPos,
- posOpenBrace - 1));
-
- if (expressionString.charAt(posOpenBrace - 1) == '$') {
- sb.append("${'${'}"); //$NON-NLS-1$
- remainsPos = posOpenBrace + 1;
- continue;
- } else if (expressionString.charAt(posOpenBrace - 1) == '#') {
- // TODO: should use \\ as escape for \ always, not just when
- // before #{
- // allow use of '\' as escape symbol for #{ (for
- // compatibility with Sun's extended implementation)
- /*
- * if (isEscaped(expressionString, posOpenBrace - 1)) {
- * escapes: { for (int i = sb.length() - 1; i >= 0; i--) {
- * if (sb.charAt(i) != '\\') { sb.setLength( sb.length() -
- * (sb.length() - i) / 2); break escapes; } }
- * sb.setLength(sb.length() / 2); } sb.append("#{"); } else {
- */
- sb.append("${"); //$NON-NLS-1$
- int posCloseBrace = indexOfMatchingClosingBrace(
- expressionString, posOpenBrace);
- sb.append(expressionString.substring(posOpenBrace + 1,
- posCloseBrace + 1));
- remainsPos = posCloseBrace + 1;
- continue;
- // }
- } else {
- if (posOpenBrace > remainsPos)
- sb.append(expressionString.charAt(posOpenBrace - 1));
- }
- }
-
- // Standalone brace
- sb.append('{');
- remainsPos = posOpenBrace + 1;
- }
-
- sb.append(expressionString.substring(remainsPos));
-
- // Create a new String to shrink mem size since we are caching
- return new String(sb.toString());
- }
-
- private static int findQuote(String expressionString, int start) {
- int indexofSingleQuote = expressionString.indexOf('\'', start);
- int indexofDoubleQuote = expressionString.indexOf('"', start);
- return minIndex(indexofSingleQuote, indexofDoubleQuote);
- }
-
- /**
- * Return the index of the matching closing brace, skipping over quoted text
- *
- * @param expressionString
- * string to search
- * @param indexofOpeningBrace
- * the location of opening brace to match
- *
- * @return the index of the matching closing brace
- *
- * @throws ReferenceSyntaxException
- * if matching brace cannot be found
- */
- private static int indexOfMatchingClosingBrace(String expressionString,
- int indexofOpeningBrace) {
- int len = expressionString.length();
- int i = indexofOpeningBrace + 1;
-
- // Loop through quoted strings
- for (;;) {
- if (i >= len) {
- throw new IllegalStateException(
- "Missing closing brace. Expression: '" //$NON-NLS-1$
- + expressionString + "'"); //$NON-NLS-1$
- }
-
- int indexofClosingBrace = expressionString.indexOf('}', i);
- i = minIndex(indexofClosingBrace, findQuote(expressionString, i));
-
- if (i < 0) {
- // No delimiter found
- throw new IllegalStateException(
- "Missing closing brace. Expression: '" //$NON-NLS-1$
- + expressionString + "'"); //$NON-NLS-1$
- }
-
- // 1. If quoted literal, find closing quote
- if (i != indexofClosingBrace) {
- i = indexOfMatchingClosingQuote(expressionString, i) + 1;
- if (i == 0) {
- // Note: if no match, i==0 because -1 + 1 = 0
- throw new IllegalStateException(
- "Missing closing quote. Expression: '" //$NON-NLS-1$
- + expressionString + "'"); //$NON-NLS-1$
- }
- } else {
- // Closing brace
- return i;
- }
- }
- }
-
- /**
- * Returns the index of the matching closing quote, skipping over escaped
- * quotes
- *
- * @param expressionString
- * string to scan
- * @param indexOfOpeningQuote
- * start from this position in the string
- * @return -1 if no match, the index of closing quote otherwise
- */
- private static int indexOfMatchingClosingQuote(String expressionString,
- int indexOfOpeningQuote) {
- char quote = expressionString.charAt(indexOfOpeningQuote);
- for (int i = expressionString.indexOf(quote, indexOfOpeningQuote + 1); i >= 0; i = expressionString
- .indexOf(quote, i + 1)) {
- if (!isEscaped(expressionString, i)) {
- return i;
- }
- }
-
- // No matching quote found
- return -1;
- }
-
- private static boolean isEscaped(String expressionString, int i) {
- int escapeCharCount = 0;
- while ((--i >= 0) && (expressionString.charAt(i) == '\\')) {
- escapeCharCount++;
- }
-
- return (escapeCharCount % 2) != 0;
- }
-
- /**
- * Returns the minimum index >= 0, if any
- *
- * <p>
- * Use to find the first of two characters in a string:<br>
- * <code>minIndex(s.indexOf('/'), indexOf('\'))</code>
- * </p>
- * @param a
- * @param b
- * @return the minimum index >= 0, if any
- *
- */
- public static int minIndex(int a, int b) {
- return (a < 0) ? b : (b < 0) ? a : (a < b) ? a : b;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/DocumentPageVariableAdapter.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/DocumentPageVariableAdapter.java
deleted file mode 100644
index ebd93fe44..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/DocumentPageVariableAdapter.java
+++ /dev/null
@@ -1,212 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jst.pagedesigner.jsp.core.ListenerList;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IChangeListener;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IDocumentPageVariableAdapter;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IPageVariableAdapter;
-import org.eclipse.wst.sse.core.internal.provisional.INodeNotifier;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMDocument;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * This adapter will be adapted on the JSP document.
- *
- * @author mengbo
- * @version 1.5
- */
-public class DocumentPageVariableAdapter implements
- IDocumentPageVariableAdapter {
- private IDOMDocument _document;
-
- private ListenerList _changeListeners = new ListenerList(2);
-
- private List _variableInfos = new ArrayList();
-
- private boolean _readingInfo = false;
-
- /**
- * @param doc
- *
- */
- public DocumentPageVariableAdapter(IDOMDocument doc) {
- super();
- this._document = doc;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IPageVariablesProvider#getBeanInfos()
- */
- public IVariableInfo[] getBeanInfos() {
- IVariableInfo[] ret = new IVariableInfo[_variableInfos.size()];
- return (IVariableInfo[]) _variableInfos.toArray(ret);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IPageVariablesProvider#addChangeListener(org.eclipse.jst.pagedesigner.jsp.core.pagevar.IChangeListener)
- */
- public void addChangeListener(IChangeListener listener) {
- this.reReadInfo();
- _changeListeners.add(listener);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IPageVariablesProvider#removeChangeListener(org.eclipse.jst.pagedesigner.jsp.core.pagevar.IChangeListener)
- */
- public void removeChangeListener(IChangeListener listener) {
- _changeListeners.remove(listener);
- }
-
- /**
- * fire change events on all listeners
- */
- protected void fireChanged() {
- Object[] listeners = _changeListeners.getListeners();
- for (int i = 0; i < listeners.length; i++) {
- IChangeListener l = (IChangeListener) listeners[i];
- l.changed();
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.core.internal.provisional.INodeAdapter#isAdapterForType(java.lang.Object)
- */
- public boolean isAdapterForType(Object type) {
- return IDocumentPageVariableAdapter.class.equals(type);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.core.internal.provisional.INodeAdapter#notifyChanged(org.eclipse.wst.sse.core.internal.provisional.INodeNotifier,
- * int, java.lang.Object, java.lang.Object, java.lang.Object, int)
- */
- public void notifyChanged(INodeNotifier notifier, int eventType,
- Object changedFeature, Object oldValue, Object newValue, int pos) {
- switch (eventType) {
- case INodeNotifier.STRUCTURE_CHANGED:
- case INodeNotifier.CONTENT_CHANGED:
- case INodeNotifier.CHANGE:
- refresh();
- break;
- default:
- // skip. Ignore other kinds of change.
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IPageVariablesProvider#refresh()
- */
- public void refresh() {
- reReadInfo();
- }
-
- /**
- * re-read page variable info
- */
- protected void reReadInfo() {
- if (this._readingInfo) {
- return;
- }
- try {
- List oldInfo = this._variableInfos;
- this._variableInfos = new ArrayList();
- readNode(_document);
- if (!isSame(oldInfo, this._variableInfos)) {
- fireChanged();
- }
- } finally {
- this._readingInfo = false;
- }
- }
-
- /**
- * compare two variable info list.
- *
- * @param oldInfo
- * @param list
- * @return true if same.
- */
- private boolean isSame(List oldInfo, List list) {
- if (oldInfo.size() != list.size()) {
- return false;
- }
- for (int i = 0, size = oldInfo.size(); i < size; i++) {
- IVariableInfo info1 = (IVariableInfo) oldInfo.get(i);
- IVariableInfo info2 = (IVariableInfo) list.get(i);
- if (info1 == null) {
- return false;// should not happen
- }
- if (!info1.equals(info2)) {
- return false;
- }
- }
- return true;
- }
-
- /**
- * recursively read all element, and see whether they have
- * IPageVariableAdapter, and then get variable info.
- *
- * @param element
- */
- private void readNode(Node node) {
- if (node instanceof INodeNotifier && node instanceof Element) {
- Element element = (Element) node;
- Object obj = ((INodeNotifier) element)
- .getAdapterFor(IPageVariableAdapter.class);
- if (obj instanceof IPageVariableAdapter) {
- IPageVariableAdapter adapter = (IPageVariableAdapter) obj;
- if (adapter.supportMultipleVariable(element)) {
- List infos = ((IPageVariableAdapter) obj)
- .getVariableInfos(element);
- if (infos != null) {
- this._variableInfos.addAll(infos);
- }
- } else {
- // hope not doing addAll could improve some performance.
- IVariableInfo info = adapter.getVariableInfo(element);
- if (info != null) {
- this._variableInfos.add(info);
- }
- }
- }
- }
-
- NodeList childNodes = node.getChildNodes();
- if (childNodes != null) {
- for (int i = 0, length = childNodes.getLength(); i < length; i++) {
- Node childNode = childNodes.item(i);
- readNode(childNode);
- }
- }
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdapter.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdapter.java
deleted file mode 100644
index 40e01b5ab..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdapter.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IDocumentPageVariableAdapter;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IPageVariableAdapter;
-import org.eclipse.wst.sse.core.internal.provisional.INodeNotifier;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMDocument;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
-import org.w3c.dom.Element;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public class PageVariableAdapter implements IPageVariableAdapter {
- static final PageVariableAdapter _instance = new PageVariableAdapter();
-
- /**
- * @return the singleton instance
- */
- public static PageVariableAdapter getInstance() {
- return _instance;
- }
-
- /**
- * no external instatiation
- */
- private PageVariableAdapter() {
- super();
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.core.internal.provisional.INodeAdapter#isAdapterForType(java.lang.Object)
- */
- public boolean isAdapterForType(Object type) {
- return IPageVariableAdapter.class.equals(type);
- }
-
- private IDocumentPageVariableAdapter getDocumentAdapter(
- INodeNotifier notifier) {
- if (notifier instanceof IDOMNode) {
- IDOMModel model = ((IDOMNode) notifier).getModel();
- if (model != null) {
- IDOMDocument document = model.getDocument();
- if (document != null) {
- return (IDocumentPageVariableAdapter) document
- .getAdapterFor(IDocumentPageVariableAdapter.class);
- }
- }
- }
- return null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.wst.sse.core.internal.provisional.INodeAdapter#notifyChanged(org.eclipse.wst.sse.core.internal.provisional.INodeNotifier,
- * int, java.lang.Object, java.lang.Object, java.lang.Object, int)
- */
- public void notifyChanged(INodeNotifier notifier, int eventType,
- Object changedFeature, Object oldValue, Object newValue, int pos) {
- IDocumentPageVariableAdapter docadapter = getDocumentAdapter(notifier);
-
- switch (eventType) {
- case INodeNotifier.STRUCTURE_CHANGED:
- docadapter.refresh();
- break;
- case INodeNotifier.CONTENT_CHANGED:
- case INodeNotifier.CHANGE:
- // only this node changed, only refresh if this node is page
- // variable node
- if (notifier instanceof Element
- && supportVariableInfo((Element) notifier)) {
- docadapter.refresh();
- }
- break;
- default:
- // skip. Ignore other kinds of change.
- }
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IPageVariableAdapter#supportMultipleVariable(org.w3c.dom.Element)
- */
- public boolean supportMultipleVariable(Element element) {
- return false;
- }
-
- /**
- * @param element
- * @return
- */
- private boolean supportVariableInfo(Element element) {
- return PageVariableAdatperRegistry.getInstance().getTagVarDescriptor(
- element) != null;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IPageVariableAdapter#getVariableInfo(org.w3c.dom.Element)
- */
- public IVariableInfo getVariableInfo(Element element) {
- TagVarDescriptor desc = PageVariableAdatperRegistry.getInstance()
- .getTagVarDescriptor(element);
- if (desc == null) {
- return null;
- }
- String name;
- if (desc.isVarNameIsAttr()) {
- name = element.getAttribute(desc.getVarName());
- if (name == null || name.length() == 0) {
- return null; // missing name.
- }
- } else {
- name = desc.getVarName();
- }
- String type;
- if (desc.isVarTypeStringIsAttr()) {
- type = element.getAttribute(desc.getVarTypeString());
- if (type == null || type.length() == 0) {
- return null; // missing type
- }
- } else {
- type = desc.getVarTypeString();
- }
- return new VariableInfo(name, desc.getVarTypeMode(), type);
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter.IPageVariableAdapter#getVariableInfos(org.w3c.dom.Element)
- */
- public List getVariableInfos(Element element) {
- IVariableInfo info = getVariableInfo(element);
- if (info == null) {
- return Collections.EMPTY_LIST;
- }
- List ret = new ArrayList(1);
- ret.add(info);
- return ret;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdatperRegistry.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdatperRegistry.java
deleted file mode 100644
index e64dce637..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/PageVariableAdatperRegistry.java
+++ /dev/null
@@ -1,248 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IExtension;
-import org.eclipse.core.runtime.IExtensionPoint;
-import org.eclipse.core.runtime.Platform;
-import org.eclipse.jst.pagedesigner.jsp.core.IJSPCoreConstants;
-import org.eclipse.jst.pagedesigner.jsp.core.JSPCorePlugin;
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo;
-import org.eclipse.jst.pagedesigner.jsp.core.util.CMUtil;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMElementDeclaration;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMElement;
-import org.w3c.dom.Element;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public class PageVariableAdatperRegistry {
- /**
- * pageVar
- */
- public static final String PAGEVAR = "pageVar"; //$NON-NLS-1$
-
- /**
- * taglib
- */
- public static final String TAGLIB = "taglib"; //$NON-NLS-1$
-
- /**
- * tag
- */
- public static final String TAG = "tag"; //$NON-NLS-1$
-
- /**
- * varName
- */
- public static final String VARNAME = "varName"; //$NON-NLS-1$
-
- /**
- * varNameIsAttr
- */
- public static final String VARNAMEISATTR = "varNameIsAttr"; //$NON-NLS-1$
-
- /**
- * varTypeMode
- */
- public static final String VARTYPEMODE = "varTypeMode"; //$NON-NLS-1$
-
- /**
- * tagName
- */
- public static final String TAGNAME = "tagName"; //$NON-NLS-1$
-
- /**
- * varTypeString
- */
- public static final String VARTYPESTRING = "varTypeString"; //$NON-NLS-1$
-
- /**
- * varTypeStringIsAttr
- */
- public static final String VARTYPESTRINGISATTR = "varTypeStringIsAttr"; //$NON-NLS-1$
-
- /**
- * uri
- */
- public static final String URI = "uri"; //$NON-NLS-1$
-
- private static PageVariableAdatperRegistry _instance = null;
-
- private Map _registry;
-
- private TagVarDescriptor _useBeanDescriptor;
-
- /**
- * @return the singleton instance
- */
- public static PageVariableAdatperRegistry getInstance() {
- if (_instance == null) {
- _instance = new PageVariableAdatperRegistry();
- }
- return _instance;
- }
-
- private PageVariableAdatperRegistry() {
- _registry = readAllDescriptors();
- }
-
- // public IPageVariableAdapter createAdapter(IDOMElement ele, String uri,
- // String tagname)
- // {
- // String key = uri + "#" + tagname;
- // TagVarDescriptor desc = (TagVarDescriptor) _registry.get(key);
- // if (desc != null)
- // {
- // PageVariableAdapter adapter = new PageVariableAdapter(ele);
- // adapter.setVarName(desc.getVarName());
- // adapter.setVarNameAttrName(desc.isVarNameIsAttr());
- // adapter.setVarTypeString(desc.getVarTypeString());
- // adapter.setVarTypeAttrName(desc.isVarTypeStringIsAttr());
- // adapter.setVarTypeMode(desc.getVarTypeMode());
- // return adapter;
- // }
- // else
- // {
- // return null;
- // }
- // }
-
- private Map readAllDescriptors() {
- Map map = new HashMap();
-
- IExtensionPoint extensionPoint = Platform.getExtensionRegistry()
- .getExtensionPoint(JSPCorePlugin.getPluginId(), PAGEVAR);
- IExtension[] extensions = extensionPoint.getExtensions();
-
- for (int i = 0; i < extensions.length; i++) {
- IExtension ext = extensions[i];
- IConfigurationElement[] facs = ext.getConfigurationElements();
-
- for (int j = 0; j < facs.length; j++) {
- if (facs[j].getName().equals(TAGLIB)) {
- String uri = facs[j].getAttribute(URI);
- if (uri == null || uri.length() == 0) {
- continue;
- }
- IConfigurationElement[] tags = facs[j].getChildren(TAG);
- for (int k = 0; k < tags.length; k++) {
- TagVarDescriptor desc = new TagVarDescriptor();
-
- String tag = tags[k].getAttribute(TAGNAME);
- String varName = tags[k].getAttribute(VARNAME);
- boolean varNameIsAttr = "true".equalsIgnoreCase(tags[k] //$NON-NLS-1$
- .getAttribute(VARNAMEISATTR));
- String varTypeString = tags[k]
- .getAttribute(VARTYPESTRING);
- boolean varTypeStringIsAttr = "true" //$NON-NLS-1$
- .equalsIgnoreCase(tags[k]
- .getAttribute(VARTYPESTRINGISATTR));
- String varTypeModeString = tags[k]
- .getAttribute(VARTYPEMODE);
- int varTypeMode = toVarTypeMode(varTypeModeString);
-
- desc.setVarName(varName);
- desc.setVarNameIsAttr(varNameIsAttr);
- desc.setVarTypeMode(varTypeMode);
- desc.setVarTypeString(varTypeString);
- desc.setVarTypeStringIsAttr(varTypeStringIsAttr);
- desc.setTagName(tag);
-
- // Use uri#tag as key.
- map.put(uri + "#" + tag, desc); //$NON-NLS-1$
- }
- }
- }
- }
-
- return map;
- }
-
- /**
- * @param varTypeModeString
- * @return variable typemode
- */
- public static int toVarTypeMode(String varTypeModeString) {
- if ("CLASSNAME".equalsIgnoreCase(varTypeModeString)) { //$NON-NLS-1$
- return IVariableInfo.CLASSNAME;
- } else if ("EXPRESSION".equalsIgnoreCase(varTypeModeString)) { //$NON-NLS-1$
- return IVariableInfo.EXPRESSION;
- } else if ("EXPRESSION_COLLECTION_ITEM" //$NON-NLS-1$
- .equalsIgnoreCase(varTypeModeString)) {
- return IVariableInfo.EXPRESSION_LISTITEM;
- } else if ("BUNDLE".equalsIgnoreCase(varTypeModeString)) { //$NON-NLS-1$
- return IVariableInfo.RESOURCEBUNDLE;
- } else {
- return IVariableInfo.EXPRESSION; // default
- }
- }
-
- /**
- * @param uri
- * @param tagname
- * @return the tag variable descriptor for the given tag (may be null)
- */
- public TagVarDescriptor getTagVarDescriptor(String uri, String tagname) {
- String key = uri + "#" + tagname; //$NON-NLS-1$
- return (TagVarDescriptor) _registry.get(key);
- }
-
- /**
- * @param localName
- * @return
- */
- private TagVarDescriptor getJSPTagVarDescriptor(String localName) {
- if (IJSPCoreConstants.TAG_USEBEAN.equals(localName)) {
- if (_useBeanDescriptor == null) {
- _useBeanDescriptor = new TagVarDescriptor();
- _useBeanDescriptor.setVarName(IJSPCoreConstants.ATTR_ID);
- _useBeanDescriptor.setVarNameIsAttr(true);
- _useBeanDescriptor.setVarTypeMode(IVariableInfo.CLASSNAME);
- _useBeanDescriptor
- .setVarTypeString(IJSPCoreConstants.ATTR_CLASS);
- _useBeanDescriptor.setVarTypeStringIsAttr(true);
- }
-
- return _useBeanDescriptor;
- }
-
- return null;
- }
-
- /**
- * @param target
- * @return the tag variable descriptor for the target
- */
- public TagVarDescriptor getTagVarDescriptor(Element target) {
- if (target instanceof IDOMElement) {
- IDOMElement xmlEle = (IDOMElement) target;
- CMElementDeclaration decl = CMUtil.getElementDeclaration(xmlEle);
- if (decl != null) {
- if (CMUtil.isJSP(decl)) {
- return getJSPTagVarDescriptor(xmlEle.getLocalName());
- }
- String uri = CMUtil.getTagURI(decl);
- if (uri != null) {
- return getTagVarDescriptor(uri, xmlEle.getLocalName());
- }
- }
- }
- return null;
- }
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/TagVarDescriptor.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/TagVarDescriptor.java
deleted file mode 100644
index 8e5b649e2..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/TagVarDescriptor.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public class TagVarDescriptor {
- private String _varName;
-
- private boolean _varNameIsAttr;
-
- private String _varTypeString;
-
- private boolean _varTypeStringIsAttr;
-
- private int _varTypeMode;
-
- private String _tagName;
-
- /**
- * @return the varName
- */
- public String getVarName() {
- return _varName;
- }
-
- /**
- * @param varName
- */
- public void setVarName(String varName) {
- this._varName = varName;
- }
-
- /**
- * @return true if var name is attribute
- */
- public boolean isVarNameIsAttr() {
- return _varNameIsAttr;
- }
-
- /**
- * @param varNameIsAttr
- */
- public void setVarNameIsAttr(boolean varNameIsAttr) {
- this._varNameIsAttr = varNameIsAttr;
- }
-
- /**
- * @return the variable type mode
- */
- public int getVarTypeMode() {
- return _varTypeMode;
- }
-
- /**
- * @param varTypeMode
- */
- public void setVarTypeMode(int varTypeMode) {
- this._varTypeMode = varTypeMode;
- }
-
- /**
- * @return the variable type string
- */
- public String getVarTypeString() {
- return _varTypeString;
- }
-
- /**
- * @param varTypeString
- */
- public void setVarTypeString(String varTypeString) {
- this._varTypeString = varTypeString;
- }
-
- /**
- * @return true if variable type string is attr
- */
- public boolean isVarTypeStringIsAttr() {
- return _varTypeStringIsAttr;
- }
-
- /**
- * @param varTypeStringIsAttr
- */
- public void setVarTypeStringIsAttr(boolean varTypeStringIsAttr) {
- this._varTypeStringIsAttr = varTypeStringIsAttr;
- }
-
- /**
- * @param tag
- */
- public void setTagName(String tag) {
- this._tagName = tag;
- }
-
- /**
- * @return the tag name
- */
- public String getTagName() {
- return this._tagName;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/VariableInfo.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/VariableInfo.java
deleted file mode 100644
index 6b29b9a95..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/internal/pagevar/VariableInfo.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar;
-
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public class VariableInfo implements IVariableInfo {
- private String _typeInfo;
-
- private int _mode;
-
- private String _name;
-
- /**
- * @param name
- * @param mode
- * @param typeInfo
- *
- */
- public VariableInfo(String name, int mode, String typeInfo) {
- this._name = name;
- this._mode = mode;
- this._typeInfo = typeInfo;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo#getName()
- */
- public String getName() {
- return _name;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo#getMode()
- */
- public int getMode() {
- return _mode;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo#getTypeInfoString()
- */
- public String getTypeInfoString() {
- return _typeInfo;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see java.lang.Object#equals(java.lang.Object)
- */
- // TODO: no hashcode override?
- public boolean equals(Object obj) {
- if (this == obj) {
- return true;
- }
- if (obj instanceof VariableInfo) {
- VariableInfo info = (VariableInfo) obj;
- return this._mode == info._mode && equals(this._name, info._name)
- && equals(this._typeInfo, info._typeInfo);
- }
- return false;
- }
-
- private boolean equals(String s1, String s2) {
- if (s1 == null) {
- return s2 == null;
- }
- return s1.equals(s2);
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IChangeListener.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IChangeListener.java
deleted file mode 100644
index 9196d0c13..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IChangeListener.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar;
-
-import java.util.EventListener;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface IChangeListener extends EventListener {
- /**
- * fire a changed indication
- */
- public void changed();
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IPageVariablesProvider.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IPageVariablesProvider.java
deleted file mode 100644
index a538ec83e..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IPageVariablesProvider.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface IPageVariablesProvider {
- /**
- *
- */
- public void refresh();
-
- /**
- * @return the bean infos
- */
- public IVariableInfo[] getBeanInfos();
-
- /**
- * @param listener
- */
- public void addChangeListener(IChangeListener listener);
-
- /**
- * @param listener
- */
- public void removeChangeListener(IChangeListener listener);
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IVariableInfo.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IVariableInfo.java
deleted file mode 100644
index a491de057..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/IVariableInfo.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public interface IVariableInfo {
- /**
- * @return the name
- */
- public String getName();
-
- /**
- * TODO
- */
- public static final int CLASSNAME = 0;
-
- /**
- * TODO
- */
- public static final int EXPRESSION = 1;
-
- /**
- * TODO
- */
- public static final int EXPRESSION_LISTITEM = 2;
-
- /**
- * TODO
- */
- public static final int RESOURCEBUNDLE = 3;
-
- /**
- * @return one of CLASSNAME, EXPRESSION, EXPRESSION_LISTITEM, RESOURCEBUNDLE
- */
- public int getMode();
-
- /**
- * type info string will have different meaning for different mode.
- *
- * @return the type info string
- */
- public String getTypeInfoString();
-
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IDocumentPageVariableAdapter.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IDocumentPageVariableAdapter.java
deleted file mode 100644
index 31979ef9b..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IDocumentPageVariableAdapter.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter;
-
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IPageVariablesProvider;
-import org.eclipse.wst.sse.core.internal.provisional.INodeAdapter;
-
-/**
- * IDocumentPageVariableAdapter will be adapted to the jsp document.
- *
- * @author mengbo
- * @version 1.5
- */
-public interface IDocumentPageVariableAdapter extends IPageVariablesProvider,
- INodeAdapter {
- // TODO: what's this for?
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IPageVariableAdapter.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IPageVariableAdapter.java
deleted file mode 100644
index 158799f86..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/IPageVariableAdapter.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter;
-
-import java.util.List;
-
-import org.eclipse.jst.pagedesigner.jsp.core.pagevar.IVariableInfo;
-import org.eclipse.wst.sse.core.internal.provisional.INodeAdapter;
-import org.w3c.dom.Element;
-
-/**
- * A IPageVariableAdapter normally will be adapted to an JSP tag.
- *
- * @author mengbo
- * @version 1.5
- */
-public interface IPageVariableAdapter extends INodeAdapter {
- /**
- * most JSP tags will only support a single variable.
- * @param element
- *
- * @return true if the tag supports multiple variables
- */
- public boolean supportMultipleVariable(Element element);
-
- /**
- * If only support single variable, this method will return the variable
- * info. This method is provided for better performance.
- *
- * @param element
- * @return null means no variable info provided.
- */
- public IVariableInfo getVariableInfo(Element element);
-
- /**
- * should return a list of IVariableInfo
- * @param element
- *
- * @return the list of variable infos
- */
- public List getVariableInfos(Element element);
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/PageVariableAdapterFactory.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/PageVariableAdapterFactory.java
deleted file mode 100644
index 1c6c64d7c..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/pagevar/adapter/PageVariableAdapterFactory.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.pagevar.adapter;
-
-import org.eclipse.jst.pagedesigner.jsp.core.internal.pagevar.PageVariableAdapter;
-import org.eclipse.wst.sse.core.internal.provisional.AbstractAdapterFactory;
-import org.eclipse.wst.sse.core.internal.provisional.INodeAdapter;
-import org.eclipse.wst.sse.core.internal.provisional.INodeNotifier;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMElement;
-
-/**
- * @author mengbo
- * @version 1.5
- */
-public class PageVariableAdapterFactory extends AbstractAdapterFactory {
- /**
- *
- */
- public PageVariableAdapterFactory() {
- super(IPageVariableAdapter.class, true);
- }
-
- /*
- * (non-Javadoc)
- * @seeorg.eclipse.wst.sse.core.internal.provisional.AbstractAdapterFactory#createAdapter(org.eclipse.wst.sse.core.internal.provisional.INodeNotifier)
- */
- protected INodeAdapter createAdapter(INodeNotifier target) {
- if (target instanceof IDOMElement) {
- return PageVariableAdapter.getInstance();
- }
- return null;
- }
-}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/util/CMUtil.java b/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/util/CMUtil.java
deleted file mode 100644
index fd299aa88..000000000
--- a/jsf/plugins/org.eclipse.jst.pagedesigner.jsp.core/src/org/eclipse/jst/pagedesigner/jsp/core/util/CMUtil.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006 Sybase, Inc. 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:
- * Sybase, Inc. - initial API and implementation
- *******************************************************************************/
-package org.eclipse.jst.pagedesigner.jsp.core.util;
-
-import org.eclipse.jst.jsp.core.internal.contentmodel.tld.provisional.TLDDocument;
-import org.eclipse.jst.jsp.core.internal.contentmodel.tld.provisional.TLDElementDeclaration;
-import org.eclipse.wst.html.core.internal.provisional.HTMLCMProperties;
-import org.eclipse.wst.sse.core.internal.provisional.INodeNotifier;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMDocument;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMElementDeclaration;
-import org.eclipse.wst.xml.core.internal.contentmodel.CMNode;
-import org.eclipse.wst.xml.core.internal.provisional.contentmodel.CMNodeWrapper;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMElement;
-import org.eclipse.wst.xml.core.internal.ssemodelquery.ModelQueryAdapter;
-
-/**
- * Utility class to content model related information.
- *
- * @author mengbo
- */
-public class CMUtil {
- /**
- * If the element is a custom tag, get the URI of it. If the element is a
- * standard JSP tag, return null. If is not jsp tag, then return null
- * @param decl
- * @return the tag uri for decl
- */
- public static String getTagURI(CMElementDeclaration decl) {
- if (decl instanceof CMNodeWrapper) {
- decl = (CMElementDeclaration) ((CMNodeWrapper) decl)
- .getOriginNode();
- }
- if (decl instanceof TLDElementDeclaration) {
- CMDocument doc = ((TLDElementDeclaration) decl).getOwnerDocument();
- if (doc instanceof TLDDocument) {
- return ((TLDDocument) doc).getUri();
- }
- }
- return null;
- }
-
- /**
- * get element declaration of specified element
- *
- * @param element
- * @return null if can't get it.
- */
- public static CMElementDeclaration getElementDeclaration(IDOMElement element) {
- INodeNotifier notifier = (INodeNotifier) element.getOwnerDocument();
- if (notifier == null) {
- return null;
- }
- ModelQueryAdapter mqa = (ModelQueryAdapter) notifier
- .getAdapterFor(ModelQueryAdapter.class);
- if (mqa == null) {
- return null;
- }
- return mqa.getModelQuery().getCMElementDeclaration(element);
- }
-
- /**
- * @param element
- * @return the tld element declaration for element
- */
- public static TLDElementDeclaration getTLDElementDeclaration(
- IDOMElement element) {
- CMNode decl = getElementDeclaration(element);
- if (decl instanceof CMNodeWrapper) {
- decl = ((CMNodeWrapper) decl).getOriginNode();
- }
- if (decl instanceof TLDElementDeclaration) {
- return (TLDElementDeclaration) decl;
- }
- return null;
- }
-
- /**
- * @param decl
- * @return true if decl is a JSP tag
- */
- public static boolean isJSP(CMElementDeclaration decl) {
- if (!decl.supports(HTMLCMProperties.IS_JSP)) {
- return false;
- }
- return ((Boolean) decl.getProperty(HTMLCMProperties.IS_JSP))
- .booleanValue();
- }
-}

Back to the top