diff options
author | cbateman | 2006-11-02 23:30:44 +0000 |
---|---|---|
committer | cbateman | 2006-11-02 23:30:44 +0000 |
commit | 500115b3184a45237e064ab6eeefd6831d945094 (patch) | |
tree | 4d9fa669c0e44ebca9c35d9cd022ea74ecf94d35 | |
parent | 566b5426c7718aad8e0666b2bc1557820427cfd8 (diff) | |
download | webtools.jsf-500115b3184a45237e064ab6eeefd6831d945094.tar.gz webtools.jsf-500115b3184a45237e064ab6eeefd6831d945094.tar.xz webtools.jsf-500115b3184a45237e064ab6eeefd6831d945094.zip |
Code warnings cleanup. See https://bugs.eclipse.org/bugs/show_bug.cgi?id=163125.
35 files changed, 468 insertions, 182 deletions
diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/JSFCorePlugin.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/JSFCorePlugin.java index 78a88c60d..08106d6e4 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/JSFCorePlugin.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/JSFCorePlugin.java @@ -40,7 +40,6 @@ import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.util.JSFLibraryRegis import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.util.JSFLibraryRegistryResourceImpl; import org.eclipse.jst.jsf.core.internal.provisional.jsflibraryregistry.PluginProvidedJSFLibraryCreationHelper; import org.eclipse.wst.common.frameworks.internal.WTPPlugin; -import org.osgi.framework.Bundle; import org.osgi.framework.BundleContext; /** @@ -49,8 +48,14 @@ import org.osgi.framework.BundleContext; * @author Gerry Kessler - Oracle, Ian Trimble - Oracle */ public class JSFCorePlugin extends WTPPlugin { + /** + * The plugin id + */ public static final String PLUGIN_ID = "org.eclipse.jst.jsf.core";//org.eclipse.jst.jsf.core.internal.JSFCorePlugin"; //$NON-NLS-1$ + /** + * The JSF facet identifier + */ public static final String FACET_ID = "jst.jsf"; //$NON-NLS-1$ // The shared instance. @@ -64,6 +69,9 @@ public class JSFCorePlugin extends WTPPlugin { // setting on package in Ecore model.) private static final String JSF_LIBRARY_REGISTRY_NSURI = "http://www.eclipse.org/webtools/jsf/schema/jsflibraryregistry.xsd"; //$NON-NLS-1$ + /** + * The id of the library extension point + */ public static final String LIB_EXT_PT = "jsfLibraries"; //$NON-NLS-1$ // The JSF Library Registry EMF resource instance. @@ -81,6 +89,8 @@ public class JSFCorePlugin extends WTPPlugin { /** * This method is called upon plug-in activation + * @param context + * @throws Exception */ public void start(BundleContext context) throws Exception { super.start(context); @@ -89,6 +99,8 @@ public class JSFCorePlugin extends WTPPlugin { /** * This method is called when the plug-in is stopped + * @param context + * @throws Exception */ public void stop(BundleContext context) throws Exception { saveJSFLibraryRegistry(); @@ -98,6 +110,7 @@ public class JSFCorePlugin extends WTPPlugin { /** * Returns the shared instance. + * @return the shared instance */ public static JSFCorePlugin getDefault() { return plugin; @@ -186,6 +199,7 @@ public class JSFCorePlugin extends WTPPlugin { /** * Saves the JSFLibraryRegistry EMF object from plugin-specfic workspace * settings location. (Called from stop(BundleContext).) + * @return true if save is successful */ public boolean saveJSFLibraryRegistry() { boolean saved = false; @@ -202,6 +216,10 @@ public class JSFCorePlugin extends WTPPlugin { return saved; } + /** + * @param e + * @param msg + */ public static void log(final Exception e, final String msg) { final ILog log = getDefault().getLog(); @@ -241,7 +259,7 @@ public class JSFCorePlugin extends WTPPlugin { * fixing 144996. * * @param jsflib - * @return + * @return true if jsflib is in the expanded folder */ private boolean isJSFLibinExpandedFolder(JSFLibrary jsflib) { boolean exists = false; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/J2EEModuleDependencyDelegate.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/J2EEModuleDependencyDelegate.java index 909914358..79da9d001 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/J2EEModuleDependencyDelegate.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/J2EEModuleDependencyDelegate.java @@ -15,7 +15,6 @@ import java.io.IOException; import java.io.InputStream; import java.lang.reflect.InvocationTargetException; import java.util.ArrayList; -import java.util.Collections; import java.util.Iterator; import java.util.List; import java.util.jar.Manifest; @@ -79,17 +78,17 @@ public class J2EEModuleDependencyDelegate { * To update project dependencies including Java buildpath and * web library dependencies from JSFLibraryConfigModel. * - * @param model JSFLibraryConfigModel instance with information to update project dependencies + * @param model_ JSFLibraryConfigModel instance with information to update project dependencies * @param monitor IProgressMonitor progress monitor passed. New instance is creatsed if a null is given */ - public void updateProjectDependencies(final JSFLibraryConfigModel model, + public void updateProjectDependencies(final JSFLibraryConfigModel model_, IProgressMonitor monitor) { if (monitor == null) { monitor = new NullProgressMonitor(); } // update implementation library - JSFProjectLibraryReference newImplLib = model.getCurrentJSFImplementationLibrarySelection(); - JSFProjectLibraryReference savedImplLib = model.getSavedJSFImplementationLibrary(); + JSFProjectLibraryReference newImplLib = model_.getCurrentJSFImplementationLibrarySelection(); + JSFProjectLibraryReference savedImplLib = model_.getSavedJSFImplementationLibrary(); if (savedImplLib != null) { this.removeProjectDependency(savedImplLib.getLibrary(), monitor); this.addProjectDependency(newImplLib.getLibrary(), newImplLib.isCheckedToBeDeployed(), monitor); @@ -100,14 +99,14 @@ public class J2EEModuleDependencyDelegate { // update component libraries // Remove first and then add dependencies from selected libraries currently. JSFProjectLibraryReference compLibDctr = null; - List savedCompLibs = model.getSavedJSFComponentLibraries(); + List savedCompLibs = model_.getSavedJSFComponentLibraries(); Iterator it = savedCompLibs.iterator(); while (it.hasNext()) { compLibDctr = (JSFProjectLibraryReference) it.next(); this.removeProjectDependency(compLibDctr.getLibrary(), monitor); } - List selComponentLibs = model.getCurrentJSFComponentLibrarySelection(); + List selComponentLibs = model_.getCurrentJSFComponentLibrarySelection(); it = selComponentLibs.iterator(); while (it.hasNext()) { compLibDctr = (JSFProjectLibraryReference) it.next(); @@ -270,13 +269,13 @@ public class J2EEModuleDependencyDelegate { } } - private ClasspathModel newClasspathModel(IProject project) { - ClasspathModel model = new ClasspathModel(null); - model.setProject(project); - if( model.getComponent() != null ){ - updateModelManifest(model); + private ClasspathModel newClasspathModel(IProject project_) { + ClasspathModel model_ = new ClasspathModel(null); + model_.setProject(project_); + if( model_.getComponent() != null ){ + updateModelManifest(model_); } - return model; + return model_; } private ClasspathElement createClassPathElement( @@ -305,8 +304,8 @@ public class J2EEModuleDependencyDelegate { return WTPUIPlugin.getRunnableWithProgress(new UpdateJavaBuildPathOperation(javaProject, selection)); } - private void updateModelManifest(ClasspathModel model) { - if (JemProjectUtilities.isBinaryProject(project) || model.getAvailableEARComponents().length == 0) { + private void updateModelManifest(ClasspathModel model_) { + if (JemProjectUtilities.isBinaryProject(project) || model_.getAvailableEARComponents().length == 0) { return; } @@ -328,11 +327,11 @@ public class J2EEModuleDependencyDelegate { try { in = manifestFile.getContents(); ArchiveManifest mf = new ArchiveManifestImpl(new Manifest(in)); - model.primSetManifest(mf); + model_.primSetManifest(mf); } catch (CoreException e) { - model.primSetManifest(new ArchiveManifestImpl()); + model_.primSetManifest(new ArchiveManifestImpl()); } catch (IOException iox) { - model.primSetManifest(new ArchiveManifestImpl()); + model_.primSetManifest(new ArchiveManifestImpl()); } finally { if (in != null) { try { diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigDialogSettingData.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigDialogSettingData.java index d7fbff4b7..6d7e994c8 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigDialogSettingData.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigDialogSettingData.java @@ -11,7 +11,6 @@ package org.eclipse.jst.jsf.core.internal.jsflibraryconfig; import java.util.ArrayList; -import java.util.Collections; import java.util.List; import org.eclipse.core.runtime.IStatus; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigModel.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigModel.java index 955d5181b..d1ca4a168 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigModel.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigModel.java @@ -10,7 +10,6 @@ package org.eclipse.jst.jsf.core.internal.jsflibraryconfig; import java.util.ArrayList; -import java.util.Collections; import java.util.Iterator; import java.util.List; @@ -216,10 +215,10 @@ public class JSFLibraryConfigModel { */ public void saveData(final IProject project) { // Instantiate one to make sure it is for a project. - JSFLibraryConfigProjectData data = new JSFLibraryConfigProjectData(project); + JSFLibraryConfigProjectData data_ = new JSFLibraryConfigProjectData(project); List implLibs = new ArrayList(); implLibs.add(getCurrentJSFImplementationLibrarySelection()); - data.saveData(implLibs, getCurrentJSFComponentLibrarySelection()); + data_.saveData(implLibs, getCurrentJSFComponentLibrarySelection()); } /** diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigProjectData.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigProjectData.java index 5ad8b4034..ca3816f01 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigProjectData.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryConfigProjectData.java @@ -10,7 +10,6 @@ package org.eclipse.jst.jsf.core.internal.jsflibraryconfig; import java.util.ArrayList; -import java.util.Collections; import java.util.Iterator; import java.util.List; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryRegistryUtil.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryRegistryUtil.java index 0207fe808..d2e619b33 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryRegistryUtil.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryconfig/JSFLibraryRegistryUtil.java @@ -10,7 +10,6 @@ package org.eclipse.jst.jsf.core.internal.jsflibraryconfig; import java.util.ArrayList; -import java.util.Collections; import java.util.Iterator; import java.util.List; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/ArchiveFile.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/ArchiveFile.java index bbe4c80cf..01941eae1 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/ArchiveFile.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/ArchiveFile.java @@ -155,6 +155,7 @@ public interface ArchiveFile extends EObject{ * If the meaning of the '<em>Path</em>' attribute isn't clear, * there really should be more of a description here... * </p> + * @return the path * <!-- end-user-doc --> * @model kind="operation" required="true" * @generated @@ -163,6 +164,7 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @return the name * <!-- end-user-doc --> * @model kind="operation" required="true" * @generated @@ -171,6 +173,7 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @return true if exists * <!-- end-user-doc --> * @model required="true" * @generated @@ -179,6 +182,8 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @param object + * @return true if equal * <!-- end-user-doc --> * @model required="true" objectRequired="true" * @generated @@ -187,6 +192,7 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @return the hashCode * <!-- end-user-doc --> * @model required="true" * @generated @@ -195,6 +201,8 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @param baseDestLocation + * @return true if copied succeeds * <!-- end-user-doc --> * @model required="true" baseDestLocationRequired="true" * @generated @@ -203,6 +211,7 @@ public interface ArchiveFile extends EObject{ /** * <!-- begin-user-doc --> + * @return the resolved source location * <!-- end-user-doc --> * @model kind="operation" required="true" * @generated diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibrary.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibrary.java index b664d04bc..f42a414d5 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibrary.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibrary.java @@ -200,6 +200,8 @@ public interface JSFLibrary extends EObject{ /** * <!-- begin-user-doc --> + * @param fullPath + * @return true if fullPath contains archive file * <!-- end-user-doc --> * @model required="true" fullPathRequired="true" * @generated @@ -208,6 +210,7 @@ public interface JSFLibrary extends EObject{ /** * <!-- begin-user-doc --> + * @return the working copy * <!-- end-user-doc --> * @model kind="operation" required="true" * @generated @@ -216,6 +219,7 @@ public interface JSFLibrary extends EObject{ /** * <!-- begin-user-doc --> + * @param otherLibrary * <!-- end-user-doc --> * @model otherLibraryRequired="true" * @generated @@ -224,6 +228,8 @@ public interface JSFLibrary extends EObject{ /** * <!-- begin-user-doc --> + * @param baseDestLocation + * @return true if copy succeeds * <!-- end-user-doc --> * @model required="true" baseDestLocationRequired="true" * @generated diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibraryRegistry.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibraryRegistry.java index dc2912b40..34a85903d 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibraryRegistry.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFLibraryRegistry.java @@ -67,6 +67,9 @@ public interface JSFLibraryRegistry extends EObject{ */ void setDefaultImplementationID(String value); + /** + *The default implementation message string + */ public static final String DEFAULT_IMPL_LABEL = Messages.JSFLibraryRegistry_DEFAULT_IMPL_LABEL; /** @@ -107,6 +110,7 @@ public interface JSFLibraryRegistry extends EObject{ * If the meaning of the '<em>Default Implementation</em>' reference isn't clear, * there really should be more of a description here... * </p> + * @return the default implementation * <!-- end-user-doc --> * @model kind="operation" required="true" * @generated @@ -115,6 +119,7 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @param value * <!-- end-user-doc --> * @model implementationRequired="true" * @generated @@ -123,6 +128,8 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @param ID + * @return the jsf library * <!-- end-user-doc --> * @model required="true" IDRequired="true" * @generated @@ -131,6 +138,8 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @param name + * @return the jsf libraries matching name * <!-- end-user-doc --> * @model required="true" many="false" nameRequired="true" * @generated @@ -139,6 +148,7 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @return the implementation JSF libraries * <!-- end-user-doc --> * @model kind="operation" required="true" many="false" * @generated @@ -147,6 +157,7 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @return the non-implementation JSF libraries * <!-- end-user-doc --> * @model kind="operation" required="true" many="false" * @generated @@ -155,6 +166,7 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @return all the JSF libraries * <!-- end-user-doc --> * @model kind="operation" required="true" many="false" * @generated @@ -163,6 +175,8 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @param library + * @return true if add succeeds * <!-- end-user-doc --> * @model required="true" libraryRequired="true" * @generated @@ -171,6 +185,8 @@ public interface JSFLibraryRegistry extends EObject{ /** * <!-- begin-user-doc --> + * @param library + * @return true if remove succeeds * <!-- end-user-doc --> * @model required="true" libraryRequired="true" * @generated diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFVersion.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFVersion.java index 1f77c4f29..4fdf1bd6b 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFVersion.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/JSFVersion.java @@ -132,6 +132,8 @@ public final class JSFVersion extends AbstractEnumerator { /** * Returns the '<em><b>JSF Version</b></em>' literal with the specified name. * <!-- begin-user-doc --> + * @param name + * @return the JSF version for name value * <!-- end-user-doc --> * @generated */ @@ -148,6 +150,8 @@ public final class JSFVersion extends AbstractEnumerator { /** * Returns the '<em><b>JSF Version</b></em>' literal with the specified value. * <!-- begin-user-doc --> + * @param value + * @return the JSFVersion for the integer 'value' * <!-- end-user-doc --> * @generated */ @@ -175,6 +179,8 @@ public final class JSFVersion extends AbstractEnumerator { * name like the get(String) method does, but will return UNKNOWN instead * of null if the name is not recognized. * <!-- begin-user-doc --> + * @param name + * @return the JSFVersion * <!-- end-user-doc --> * @generated NOT */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/ArchiveFileImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/ArchiveFileImpl.java index 3a4348ff2..dcb10a8af 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/ArchiveFileImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/ArchiveFileImpl.java @@ -22,6 +22,7 @@ import java.net.URL; import org.eclipse.core.resources.IWorkspace; import org.eclipse.core.resources.IWorkspaceRoot; import org.eclipse.core.resources.ResourcesPlugin; +import org.eclipse.core.runtime.FileLocator; import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Path; @@ -138,6 +139,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the static eClass * <!-- end-user-doc --> * @generated */ @@ -147,6 +149,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the source location * <!-- end-user-doc --> * @generated */ @@ -162,6 +165,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { * stored and the relativeToWorkspace property is set to false. To override * this behaviour and set the absolute location as passed regardless, call * setRelativeToWorkspace(false) BEFORE calling this method. + * + * @param newSourceLocation * * <!-- end-user-doc --> * @generated NOT @@ -193,6 +198,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return true if file is relative to workspace * <!-- end-user-doc --> * @generated */ @@ -204,6 +210,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { * <!-- begin-user-doc --> * To override workspace-relative recognition behaviour, be sure to call * this method with a false value BEFORE calling setLocation(String). + * @param newRelativeToWorkspace * <!-- end-user-doc --> * @generated */ @@ -216,6 +223,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the relative destination location * <!-- end-user-doc --> * @generated */ @@ -225,6 +233,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param newRelativeDestLocation * <!-- end-user-doc --> * @generated */ @@ -237,6 +246,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the jsf library instance * <!-- end-user-doc --> * @generated */ @@ -247,6 +257,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param newJSFLibrary * <!-- end-user-doc --> * @generated */ @@ -268,6 +279,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the path * <!-- end-user-doc --> * @generated NOT */ @@ -290,6 +302,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the name * <!-- end-user-doc --> * @generated NOT */ @@ -312,6 +325,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return true if the archive file exists in the bundle * <!-- end-user-doc --> * @generated NOT */ @@ -333,6 +347,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param object + * @return true if equal * <!-- end-user-doc --> * @generated NOT */ @@ -352,6 +368,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return a the resolved source location hash or 0 if it is null * <!-- end-user-doc --> * @generated NOT */ @@ -361,6 +378,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param baseDestLocation + * @return true if the copy is successful * <!-- end-user-doc --> * @generated NOT */ @@ -421,6 +440,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the resolved source location * <!-- end-user-doc --> * @generated NOT */ @@ -440,8 +460,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { //resolvedSourceLocation = appendSeparator(bundleLocation) + sourceLocation; try { Path srcPath = new Path(sourceLocation); - URL fileURL = Platform.find(bundle, srcPath); - URL url = Platform.resolve(fileURL); + URL fileURL = FileLocator.find(bundle, srcPath, null); + URL url = FileLocator.resolve(fileURL); resolvedSourceLocation = url.getPath(); } catch (IOException e) { resolvedSourceLocation = sourceLocation; @@ -499,6 +519,10 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { return workspaceRoot; } + /** + * @param path + * @return the the path string with invalid path separators correctly fixed + */ protected String appendSeparator(String path) { String newPath = null; if (!path.endsWith("\\") && !path.endsWith("/")) { //$NON-NLS-1$ //$NON-NLS-2$ @@ -511,6 +535,11 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the inverse notification chain * <!-- end-user-doc --> * @generated */ @@ -532,6 +561,11 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -549,6 +583,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -566,6 +602,9 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param eFeature + * @param resolve + * @return the request feature value * <!-- end-user-doc --> * @generated */ @@ -585,6 +624,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param eFeature + * @param newValue * <!-- end-user-doc --> * @generated */ @@ -608,6 +649,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param eFeature * <!-- end-user-doc --> * @generated */ @@ -631,6 +673,8 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @param eFeature + * @return true if the feature is set * <!-- end-user-doc --> * @generated */ @@ -650,6 +694,7 @@ public class ArchiveFileImpl extends EObjectImpl implements ArchiveFile { /** * <!-- begin-user-doc --> + * @return the string representation of this archive file * <!-- end-user-doc --> * @generated */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryImpl.java index 298656368..b5dd73066 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryImpl.java @@ -184,6 +184,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the static eClass * <!-- end-user-doc --> * @generated */ @@ -193,6 +194,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the id * <!-- end-user-doc --> * @generated */ @@ -202,6 +204,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param newID * <!-- end-user-doc --> * @generated */ @@ -214,6 +217,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the name * <!-- end-user-doc --> * @generated */ @@ -223,6 +227,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param newName * <!-- end-user-doc --> * @generated */ @@ -235,6 +240,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the jsf version * <!-- end-user-doc --> * @generated */ @@ -244,6 +250,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param newJSFVersion * <!-- end-user-doc --> * @generated */ @@ -256,6 +263,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return true if library is to be deployed * <!-- end-user-doc --> * @generated */ @@ -265,6 +273,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param newDeployed * <!-- end-user-doc --> * @generated */ @@ -277,6 +286,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return true if implementation * <!-- end-user-doc --> * @generated */ @@ -286,6 +296,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param newImplementation * <!-- end-user-doc --> * @generated */ @@ -298,6 +309,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the list of archive files * <!-- end-user-doc --> * @generated */ @@ -310,6 +322,8 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param fullPath + * @return the true if the fullPath contains an archive file * <!-- end-user-doc --> * @generated NOT */ @@ -330,6 +344,8 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param fullPath + * @return the working copy * <!-- end-user-doc --> * @generated NOT */ @@ -354,6 +370,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param otherLibrary * <!-- end-user-doc --> * @generated NOT */ @@ -379,6 +396,8 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param baseDestLocation + * @return the base destination location * <!-- end-user-doc --> * @generated NOT */ @@ -395,6 +414,11 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -414,6 +438,11 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -431,6 +460,9 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param eFeature + * @param resolve + * @return the value of the indicated feature * <!-- end-user-doc --> * @generated */ @@ -454,6 +486,8 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param eFeature + * @param newValue * <!-- end-user-doc --> * @generated */ @@ -484,6 +518,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param eFeature * <!-- end-user-doc --> * @generated */ @@ -513,6 +548,8 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @param eFeature + * @return true if the feature's value is set * <!-- end-user-doc --> * @generated */ @@ -536,6 +573,7 @@ public class JSFLibraryImpl extends EObjectImpl implements JSFLibrary { /** * <!-- begin-user-doc --> + * @return the string representation * <!-- end-user-doc --> * @generated */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryFactoryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryFactoryImpl.java index d7ce56ef5..ea914b530 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryFactoryImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryFactoryImpl.java @@ -48,6 +48,8 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @param eClass + * @return the static eclass * <!-- end-user-doc --> * @generated */ @@ -64,6 +66,9 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @param eDataType + * @param initialValue + * @return an instance of eDataType for initialValue * <!-- end-user-doc --> * @generated */ @@ -81,6 +86,9 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @param eDataType + * @param instanceValue + * @return the string created from instanceValue from eDataType * <!-- end-user-doc --> * @generated */ @@ -95,6 +103,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the jsf library registry * <!-- end-user-doc --> * @generated */ @@ -105,6 +114,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the jsf library * <!-- end-user-doc --> * @generated */ @@ -115,6 +125,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the archive file * <!-- end-user-doc --> * @generated */ @@ -125,6 +136,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the plugin provided JSF library * <!-- end-user-doc --> * @generated */ @@ -135,6 +147,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the registry package * <!-- end-user-doc --> * @generated */ @@ -144,6 +157,7 @@ public class JSFLibraryRegistryFactoryImpl extends EFactoryImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the package * <!-- end-user-doc --> * @deprecated * @generated diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryImpl.java index f460618d6..a3951361f 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryImpl.java @@ -104,6 +104,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the static eClass * <!-- end-user-doc --> * @generated */ @@ -113,6 +114,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the default implementation id * <!-- end-user-doc --> * @generated */ @@ -122,6 +124,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param newDefaultImplementationID * <!-- end-user-doc --> * @generated */ @@ -134,6 +137,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the list of jsf libraries * <!-- end-user-doc --> * @generated */ @@ -146,6 +150,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the list of plugin provided JSF libraries * <!-- end-user-doc --> * @generated */ @@ -158,6 +163,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the default implemention JSF library * <!-- end-user-doc --> * @generated NOT */ @@ -167,6 +173,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param implementation * <!-- end-user-doc --> * @generated NOT */ @@ -180,6 +187,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param ID + * @return the jsf library of ID or null if none * <!-- end-user-doc --> * @generated NOT */ @@ -200,6 +209,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param name + * @return the list of libraries named 'name' * <!-- end-user-doc --> * @generated NOT */ @@ -223,6 +234,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg * that are marked as JSF implementations; while all instances are valid * references, the returned EList should not be used for additions and/or * removals of instances (use the EList returned by getJSFLibraries()). + * @return the list of implemention jsf libraries * <!-- end-user-doc --> * @generated NOT */ @@ -245,6 +257,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg * valid references, the returned EList should not be used for additions * and/or removals of instances (use the EList returned by * getJSFLibraries()). + * @return the non-implemention JSF libraries * <!-- end-user-doc --> * @generated NOT */ @@ -266,6 +279,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg * and PluginProvidedJSFLibrary instances; while all instances are valid * references, the returned EList should not be used for additions and/or * removals of instances (use the EList returned by getJSFLibraries()). + * @return all JSF libraries * <!-- end-user-doc --> * @generated NOT */ @@ -278,6 +292,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param library + * @return true if library is successfully added * <!-- end-user-doc --> * @generated NOT */ @@ -293,6 +309,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param library + * @return true if library is successfully removed * <!-- end-user-doc --> * @generated NOT */ @@ -308,6 +326,11 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -327,6 +350,9 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param eFeature + * @param resolve + * @return the value of the feature * <!-- end-user-doc --> * @generated */ @@ -344,6 +370,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param eFeature + * @param newValue * <!-- end-user-doc --> * @generated */ @@ -366,6 +394,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param eFeature * <!-- end-user-doc --> * @generated */ @@ -386,6 +415,8 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @param eFeature + * @return true if the feature value is set * <!-- end-user-doc --> * @generated */ @@ -403,6 +434,7 @@ public class JSFLibraryRegistryImpl extends EObjectImpl implements JSFLibraryReg /** * <!-- begin-user-doc --> + * @return the string representation * <!-- end-user-doc --> * @generated */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryPackageImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryPackageImpl.java index 6d496c92c..14de3cccd 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryPackageImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/JSFLibraryRegistryPackageImpl.java @@ -117,6 +117,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi * <p>Invocation of this method will not affect any packages that have * already been initialized. * <!-- begin-user-doc --> + * @return the JSF library registry package * <!-- end-user-doc --> * @see #eNS_URI * @see #createPackageContents() @@ -145,6 +146,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eclass * <!-- end-user-doc --> * @generated */ @@ -154,6 +156,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -163,6 +166,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the ereference * <!-- end-user-doc --> * @generated */ @@ -172,6 +176,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the ereference * <!-- end-user-doc --> * @generated */ @@ -181,6 +186,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eclass * <!-- end-user-doc --> * @generated */ @@ -190,6 +196,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -199,6 +206,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -208,6 +216,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -217,6 +226,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -226,6 +236,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -235,6 +246,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the ereference * <!-- end-user-doc --> * @generated */ @@ -244,6 +256,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eclass * <!-- end-user-doc --> * @generated */ @@ -253,6 +266,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -262,6 +276,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -271,6 +286,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -280,6 +296,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the ereference * <!-- end-user-doc --> * @generated */ @@ -289,6 +306,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eclass * <!-- end-user-doc --> * @generated */ @@ -298,6 +316,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eattribute * <!-- end-user-doc --> * @generated */ @@ -307,6 +326,7 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> + * @return the eenum * <!-- end-user-doc --> * @generated */ @@ -316,7 +336,8 @@ public class JSFLibraryRegistryPackageImpl extends EPackageImpl implements JSFLi /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> + * @return the jsf library registry factory + * <!-- end-user-doc --> * @generated */ public JSFLibraryRegistryFactory getJSFLibraryRegistryFactory() { diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/PluginProvidedJSFLibraryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/PluginProvidedJSFLibraryImpl.java index c474714ff..0e42fa1ef 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/PluginProvidedJSFLibraryImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/impl/PluginProvidedJSFLibraryImpl.java @@ -79,6 +79,7 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @return the static eclass * <!-- end-user-doc --> * @generated */ @@ -88,6 +89,7 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @return the plugin id * <!-- end-user-doc --> * @generated */ @@ -97,6 +99,7 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param newPluginID * <!-- end-user-doc --> * @generated */ @@ -109,6 +112,11 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -128,6 +136,11 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param otherEnd + * @param featureID + * @param baseClass + * @param msgs + * @return the notification chain * <!-- end-user-doc --> * @generated */ @@ -145,6 +158,9 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param eFeature + * @param resolve + * @return the value of the feature * <!-- end-user-doc --> * @generated */ @@ -170,6 +186,8 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param eFeature + * @param newValue * <!-- end-user-doc --> * @generated */ @@ -203,6 +221,7 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param eFeature * <!-- end-user-doc --> * @generated */ @@ -235,6 +254,8 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @param eFeature + * @return true if the value of eFeature is set * <!-- end-user-doc --> * @generated */ @@ -260,6 +281,7 @@ public class PluginProvidedJSFLibraryImpl extends JSFLibraryImpl implements Plug /** * <!-- begin-user-doc --> + * @return the string representation * <!-- end-user-doc --> * @generated */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryAdapterFactory.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryAdapterFactory.java index 4002101e2..1b6838253 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryAdapterFactory.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryAdapterFactory.java @@ -59,6 +59,7 @@ public class JSFLibraryRegistryAdapterFactory extends AdapterFactoryImpl { * 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. + * @param object * <!-- end-user-doc --> * @return whether this factory is applicable for the type of the object. * @generated diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryResourceFactoryImpl.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryResourceFactoryImpl.java index e369138b1..10d995511 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryResourceFactoryImpl.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistryResourceFactoryImpl.java @@ -44,6 +44,8 @@ public class JSFLibraryRegistryResourceFactoryImpl extends ResourceFactoryImpl { /** * Creates an instance of the resource. * <!-- begin-user-doc --> + * @param uri + * @return the Resource * <!-- end-user-doc --> * @generated */ diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistrySwitch.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistrySwitch.java index 58863bf42..f1ad73ce3 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistrySwitch.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/jsflibraryregistry/util/JSFLibraryRegistrySwitch.java @@ -61,8 +61,9 @@ public class JSFLibraryRegistrySwitch { /** * 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 --> - * @return the first non-null result returned by a <code>caseXXX</code> call. * @generated */ public Object doSwitch(EObject theEObject) { @@ -72,28 +73,30 @@ public class JSFLibraryRegistrySwitch { /** * 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 --> - * @return the first non-null result returned by a <code>caseXXX</code> call. * @generated */ protected Object doSwitch(EClass theEClass, EObject theEObject) { if (theEClass.eContainer() == modelPackage) { return doSwitch(theEClass.getClassifierID(), theEObject); } - else { - List eSuperTypes = theEClass.getESuperTypes(); - return - eSuperTypes.isEmpty() ? - defaultCase(theEObject) : - doSwitch((EClass)eSuperTypes.get(0), 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 --> - * @return the first non-null result returned by a <code>caseXXX</code> call. * @generated */ protected Object doSwitch(int classifierID, EObject theEObject) { diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/launch/JSFFileURL.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/launch/JSFFileURL.java index 31fae2ef5..10dac8b2b 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/launch/JSFFileURL.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/launch/JSFFileURL.java @@ -95,9 +95,11 @@ public class JSFFileURL implements FileURL { if (ext == null){ String lastSeg = extPath.lastSegment(); if (lastSeg.equals("*")) //$NON-NLS-1$ + { return extPath.removeLastSegments(1).toString(); - else - return extPath.toString(); + } + + return extPath.toString(); } } return null; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/IJSFFacetInstallDataModelProperties.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/IJSFFacetInstallDataModelProperties.java index d697729d7..337aa6e83 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/IJSFFacetInstallDataModelProperties.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/IJSFFacetInstallDataModelProperties.java @@ -7,9 +7,9 @@ * * Contributors: * Gerry Kessler - initial API and implementation - *******************************************************************************/ + *******************************************************************************/ package org.eclipse.jst.jsf.core.internal.project.facet; - + import org.eclipse.wst.common.componentcore.datamodel.properties.IFacetInstallDataModelProperties; /** @@ -17,18 +17,50 @@ import org.eclipse.wst.common.componentcore.datamodel.properties.IFacetInstallDa * * @author Gerry Kessler - Oracle */ -public interface IJSFFacetInstallDataModelProperties extends IFacetInstallDataModelProperties { - public static final String IMPLEMENTATION = "IJSFFacetInstallDataModelProperties.IMPLEMENTATION"; //$NON-NLS-1$ - public static final String DEPLOY_IMPLEMENTATION = "IJSFFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION"; //$NON-NLS-1$ - public static final String CONFIG_PATH = "IJSFFacetInstallDataModelProperties.CONFIG_PATH"; //$NON-NLS-1$ - public static final String SERVLET_NAME = "IJSFFacetInstallDataModelProperties.SERVLET_NAME"; //$NON-NLS-1$ - public static final String SERVLET_URL_PATTERNS = "IJSFFacetInstallDataModelProperties.SERVLET_URL_PATTERNS"; //$NON-NLS-1$ - public static final String WEBCONTENT_DIR = "IJSFFacetInstallDataModelProperties.WEBCONTENT_DIR"; //$NON-NLS-1$ - - public static final String DEFAULT_IMPLEMENTATION_LIBRARY = "IJSFFacetInstallDataModelProperties.DEFAULT_IMPLEMENTATION_LIBRARY"; - public static final String IMPLEMENTATION_LIBRARIES = "IJSFFacetInstallDataModelProperties.IMPLEMENTATION_LIBRARIES"; - public static final String COMPONENT_LIBRARIES = "IJSFFacetInstallDataModelProperties.COMPONENT_LIBRARIES"; //$NON-NLS-1$ - -} +public interface IJSFFacetInstallDataModelProperties extends + IFacetInstallDataModelProperties { + /** + * TODO: + */ + public static final String IMPLEMENTATION = "IJSFFacetInstallDataModelProperties.IMPLEMENTATION"; //$NON-NLS-1$ + + /** + * TODO: + */ + public static final String DEPLOY_IMPLEMENTATION = "IJSFFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION"; //$NON-NLS-1$ + + /** + * TODO: + */ + public static final String CONFIG_PATH = "IJSFFacetInstallDataModelProperties.CONFIG_PATH"; //$NON-NLS-1$ + + /** + * TODO: + */ + public static final String SERVLET_NAME = "IJSFFacetInstallDataModelProperties.SERVLET_NAME"; //$NON-NLS-1$ -
\ No newline at end of file + /** + * TODO: + */ + public static final String SERVLET_URL_PATTERNS = "IJSFFacetInstallDataModelProperties.SERVLET_URL_PATTERNS"; //$NON-NLS-1$ + + /** + * TODO: + */ + public static final String WEBCONTENT_DIR = "IJSFFacetInstallDataModelProperties.WEBCONTENT_DIR"; //$NON-NLS-1$ + + /** + * TODO: + */ + public static final String DEFAULT_IMPLEMENTATION_LIBRARY = "IJSFFacetInstallDataModelProperties.DEFAULT_IMPLEMENTATION_LIBRARY"; + + /** + * TODO: + */ + public static final String IMPLEMENTATION_LIBRARIES = "IJSFFacetInstallDataModelProperties.IMPLEMENTATION_LIBRARIES"; + + /** + * TODO: + */ + public static final String COMPONENT_LIBRARIES = "IJSFFacetInstallDataModelProperties.COMPONENT_LIBRARIES"; //$NON-NLS-1$ +} diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDataModelProvider.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDataModelProvider.java index 743b21845..4cdae49fd 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDataModelProvider.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDataModelProvider.java @@ -11,7 +11,6 @@ package org.eclipse.jst.jsf.core.internal.project.facet; import java.util.ArrayList; -import java.util.Collections; import java.util.List; import java.util.Set; @@ -103,18 +102,18 @@ public class JSFFacetInstallDataModelProvider extends errorMessage = Messages.JSFFacetInstallDataModelProvider_ValidateServletName; return WTPCommonPlugin.createErrorStatus(errorMessage); } - else - return OK_STATUS; + + return OK_STATUS; } private IStatus validateImpl(JSFLibrary impl) { if (impl == null) { errorMessage = Messages.JSFFacetInstallDataModelProvider_ValidateJSFImpl; } - if (errorMessage != null) + if (errorMessage != null) { return WTPCommonPlugin.createErrorStatus(errorMessage); - else - return OK_STATUS; + } + return OK_STATUS; } private IStatus validateConfigLocation(String text) { @@ -173,15 +172,14 @@ public class JSFFacetInstallDataModelProvider extends IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projName); if (project.exists()){ return project.getLocation(); - } else { - IDataModel projModel = (IDataModel)getProperty(MASTER_PROJECT_DM); - if (projModel.getBooleanProperty(IProjectCreationPropertiesNew.USE_DEFAULT_LOCATION)){ - return new Path(projModel.getStringProperty(IProjectCreationPropertiesNew.PROJECT_LOCATION)).append(projName); - } - else { - return new Path(projModel.getStringProperty(IProjectCreationPropertiesNew.USER_DEFINED_LOCATION)).append(projName); - } + } + + IDataModel projModel = (IDataModel)getProperty(MASTER_PROJECT_DM); + if (projModel.getBooleanProperty(IProjectCreationPropertiesNew.USE_DEFAULT_LOCATION)){ + return new Path(projModel.getStringProperty(IProjectCreationPropertiesNew.PROJECT_LOCATION)).append(projName); } + + return new Path(projModel.getStringProperty(IProjectCreationPropertiesNew.USER_DEFINED_LOCATION)).append(projName); } private IPath getWebContentFolder() { @@ -201,11 +199,9 @@ public class JSFFacetInstallDataModelProvider extends webContentPath = JSFUtils.getWebArtifactEditForRead(proj) .getDeploymentDescriptorPath().removeLastSegments(2); return webContentPath; - } else { - webContentPath = new Path(getStringProperty(WEBCONTENT_DIR)); - return webContentPath; } - + webContentPath = new Path(getStringProperty(WEBCONTENT_DIR)); + return webContentPath; } finally { if (webApp != null) { webApp.dispose(); diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDelegate.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDelegate.java index 516201ba5..c428334c6 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDelegate.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFFacetInstallDelegate.java @@ -129,11 +129,11 @@ public class JSFFacetInstallDelegate implements IDelegate { if (!configPath.toFile().exists()) { IWorkspaceRunnable op = new IWorkspaceRunnable(){ - public void run(IProgressMonitor monitor) + public void run(IProgressMonitor monitor_inner) throws CoreException{ JSFUtils.createConfigFile(fv.getVersionString(), configPath); - project.refreshLocal(IResource.DEPTH_INFINITE, monitor); + project.refreshLocal(IResource.DEPTH_INFINITE, monitor_inner); } }; diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFUtils.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFUtils.java index b4a00d281..ed6f4e22d 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFUtils.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/project/facet/JSFUtils.java @@ -16,7 +16,6 @@ import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.PrintWriter; -import java.util.ArrayList; import java.util.Iterator; import java.util.List; @@ -49,24 +48,45 @@ import org.eclipse.wst.common.frameworks.datamodel.IDataModel; * @since M1 */ public class JSFUtils { + /** + * The name of the Faces servlet class + */ public static final String JSF_SERVLET_CLASS = "javax.faces.webapp.FacesServlet"; //$NON-NLS-1$ + /** + * The name of the context parameter used for JSF configuration files + */ public static final String JSF_CONFIG_CONTEXT_PARAM = "javax.faces.CONFIG_FILES"; //$NON-NLS-1$ + /** + * The path to the default application configuration file + */ public static final String JSF_DEFAULT_CONFIG_PATH = "/WEB-INF/faces-config.xml"; //$NON-NLS-1$ - public static final String PP_JSF_FACET_INSTALLED = "is.jsf.project"; //$NON-NLS-1$ - public static final String PP_JSF_DEPLOY_ME = "deploy.jsf.libraries"; //$NON-NLS-1$ - public static final String PP_JSF_IMPL_LIB = "jsf.impl.lib"; //$NON-NLS-1$ - public static final String PP_JSF_NONIMPL_LIB = "jsf.nonimpl.lib"; //$NON-NLS-1$ - public static final String PP_JSF_AVAIL_COMP_LIB = "jsf.comp.lib.avail"; //$NON-NLS-1$ - public static final String PP_JSF_SEL_COMP_LIB = "jsf.comp.lib.selected"; //$NON-NLS-1$ - + /** + * The key that identifies + */ + // TODO: this seem not to be used; dead code? +// public static final String PP_JSF_FACET_INSTALLED = "is.jsf.project"; //$NON-NLS-1$ +// public static final String PP_JSF_DEPLOY_ME = "deploy.jsf.libraries"; //$NON-NLS-1$ +// public static final String PP_JSF_IMPL_LIB = "jsf.impl.lib"; //$NON-NLS-1$ +// public static final String PP_JSF_NONIMPL_LIB = "jsf.nonimpl.lib"; //$NON-NLS-1$ +// public static final String PP_JSF_AVAIL_COMP_LIB = "jsf.comp.lib.avail"; //$NON-NLS-1$ +// public static final String PP_JSF_SEL_COMP_LIB = "jsf.comp.lib.selected"; //$NON-NLS-1$ +// + /** + * the key for implementation libraries in persistent properties + * TODO: should encapsulate the property somewhere and hide the constant + */ public static final String PP_JSF_IMPLEMENTATION_LIBRARIES = "jsf.implementation.libraries"; //$NON-NLS-1$ + /** + * the key for component libraries in persistent properties + * TODO: should encapsulate the property somewhere and hide the constant + */ public static final String PP_JSF_COMPONENT_LIBRARIES = "jsf.component.libraries"; //$NON-NLS-1$ /** * Convenience method for getting writeable WebApp model - * @param IProject + * @param project * @return WebArtifactEdit */ public static WebArtifactEdit getWebArtifactEditForWrite(IProject project) { @@ -75,7 +95,7 @@ public class JSFUtils { /** * Convenience method for getting read-only WebApp model - * @param IProject + * @param project * @return WebArtifactEdit */ public static WebArtifactEdit getWebArtifactEditForRead(IProject project) { @@ -108,8 +128,8 @@ public class JSFUtils { /** * Creates a stubbed JSF configuration file for specified JSF version and path - * @param String jsfVersion - * @param String configPath + * @param jsfVersion + * @param configPath */ public static void createConfigFile(String jsfVersion, IPath configPath) { FileOutputStream os = null; @@ -178,9 +198,9 @@ public class JSFUtils { * Creates servlet reference in WebApp if not present or updates servlet name if found * using the passed configuration. * - * @param WebApp webApp - * @param IDataModel config - * @param Servlet servlet + * @param webApp + * @param config + * @param servlet * @return Servlet servlet - if passed servlet was null, will return created servlet */ public static Servlet createOrUpdateServletRef(WebApp webApp, @@ -211,9 +231,9 @@ public class JSFUtils { /** * Creates servlet-mappings for the servlet * - * @param WebApp webApp - * @param List urlMappingList - list of string values to be used in url-pattern for servlet-mapping - * @param Servlet servlet + * @param webApp + * @param urlMappingList - list of string values to be used in url-pattern for servlet-mapping + * @param servlet */ public static void setUpURLMappings(WebApp webApp, List urlMappingList, Servlet servlet) { @@ -232,8 +252,8 @@ public class JSFUtils { /** * Removes servlet-mappings for servlet using servlet-name. - * @param WebApp webApp - * @param Servlet servlet + * @param webApp + * @param servlet */ public static void removeURLMappings(WebApp webApp, Servlet servlet) { String servletName = servlet.getServletName(); @@ -251,8 +271,8 @@ public class JSFUtils { /** * Creates or updates config file context-param in v 2.3 WebApp if non default configuration file is specified. - * @param WebApp webApp - * @param IDataModel config + * @param webApp + * @param config */ public static void setupConfigFileContextParamForV2_3(WebApp webApp, IDataModel config) { @@ -290,8 +310,8 @@ public class JSFUtils { } /** * Creates or updates config file context-param in v2.4 WebApp if non default configuration file is specified. - * @param WebApp webApp - * @param IDataModel config + * @param webApp + * @param config */ public static void setupConfigFileContextParamForV2_4(WebApp webApp, IDataModel config) { diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsfappconfig/RuntimeClasspathJSFAppConfigLocater.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsfappconfig/RuntimeClasspathJSFAppConfigLocater.java index 0854498a1..41994c27e 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsfappconfig/RuntimeClasspathJSFAppConfigLocater.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsfappconfig/RuntimeClasspathJSFAppConfigLocater.java @@ -101,19 +101,17 @@ public class RuntimeClasspathJSFAppConfigLocater extends AbstractJSFAppConfigLoc ((deltaFlags & IJavaElementDelta.F_ARCHIVE_CONTENT_CHANGED) == IJavaElementDelta.F_ARCHIVE_CONTENT_CHANGED) || ((deltaFlags & IJavaElementDelta.F_REMOVED_FROM_CLASSPATH) == IJavaElementDelta.F_REMOVED_FROM_CLASSPATH)) { return true; - } else { - boolean changed = false; - IJavaElementDelta[] childDeltas = delta.getAffectedChildren(); - if (childDeltas != null) { - for (int i = 0; i < childDeltas.length; i++) { - if (classpathChanged(childDeltas[i])) { - changed = true; - break; - } + } + boolean changed = false; + IJavaElementDelta[] childDeltas = delta.getAffectedChildren(); + if (childDeltas != null) { + for (int i = 0; i < childDeltas.length; i++) { + if (classpathChanged(childDeltas[i])) { + changed = true; + break; } } - return changed; } + return changed; } - } diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/JSFLibraryArchiveFilesDelegate.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/JSFLibraryArchiveFilesDelegate.java index eba6170ab..cbff18734 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/JSFLibraryArchiveFilesDelegate.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/JSFLibraryArchiveFilesDelegate.java @@ -32,8 +32,7 @@ import org.osgi.framework.Bundle; * @author Gerry Kessler - Oracle */ public abstract class JSFLibraryArchiveFilesDelegate { - - protected IConfigurationElement extPtElement; + private IConfigurationElement extPtElement; private String libID = null; private IPath pluginPath = null; private String pluginID; @@ -133,7 +132,7 @@ public abstract class JSFLibraryArchiveFilesDelegate { */ private String getPluginID() { if (pluginID == null){ - pluginID = extPtElement.getDeclaringExtension().getNamespace(); + pluginID = extPtElement.getDeclaringExtension().getContributor().getName(); } return pluginID; } diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/PluginProvidedJSFLibraryCreationHelper.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/PluginProvidedJSFLibraryCreationHelper.java index 55424f109..f3f0c7bdf 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/PluginProvidedJSFLibraryCreationHelper.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/provisional/jsflibraryregistry/PluginProvidedJSFLibraryCreationHelper.java @@ -142,6 +142,6 @@ public final class PluginProvidedJSFLibraryCreationHelper { * @return The plugin's ID */ private String getPluginID() { - return config_element.getDeclaringExtension().getNamespace(); + return config_element.getDeclaringExtension().getContributor().getName(); } } diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/CompositeTypeCoercer.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/CompositeTypeCoercer.java index ea0d32615..fb7fb24ab 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/CompositeTypeCoercer.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/CompositeTypeCoercer.java @@ -103,18 +103,16 @@ public class CompositeTypeCoercer { throw new TypeCoercionException(); } + // otherwise the flag was cleared return what we found - else + if (coercedType != null) { - if (coercedType != null) - { - // need to unbox per JSP.2.8.1 - coercedType = - TypeTransformer.transformUnboxPrimitives(coercedType); - } - - return coercedType; + // need to unbox per JSP.2.8.1 + coercedType = + TypeTransformer.transformUnboxPrimitives(coercedType); } + + return coercedType; } diff --git a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/TypeCoercer.java b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/TypeCoercer.java index 93341ff9e..f2fbc2be0 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/TypeCoercer.java +++ b/jsf/plugins/org.eclipse.jst.jsf.core/src/org/eclipse/jst/jsf/core/internal/types/TypeCoercer.java @@ -40,29 +40,26 @@ public class TypeCoercer { throw new TypeCoercionException("Cannot coerce arrays to numbers"); } - else + // if it's character, pre-coerce to short per step 2 + if (TypeConstants.SIGNATURE_BOXED_CHARACTER.equals(boxedTypeSignature)) { - // if it's character, pre-coerce to short per step 2 - if ("Ljava.lang.Character;".equals(boxedTypeSignature)) - { - boxedTypeSignature = "Ljava.lang.Short;"; - } + boxedTypeSignature = TypeConstants.TYPE_BOXED_SHORT; + } - if (TypeCoercer.typeIsNumeric(boxedTypeSignature) - || TypeCoercer.typeIsNull(boxedTypeSignature)) - { - return boxedTypeSignature; - } - else if (typeIsString(boxedTypeSignature)) - { - // undetermined a string may or not resolve to a number - // depending on its runtime value - return null; - } - else - { - throw new TypeCoercionException(); - } + if (TypeCoercer.typeIsNumeric(boxedTypeSignature) + || TypeCoercer.typeIsNull(boxedTypeSignature)) + { + return boxedTypeSignature; + } + else if (typeIsString(boxedTypeSignature)) + { + // undetermined a string may or not resolve to a number + // depending on its runtime value + return null; + } + else + { + throw new TypeCoercionException(); } } @@ -80,10 +77,7 @@ public class TypeCoercer return true; } // nothing else really convertible besides null - else - { - return false; - } + return false; } /** @@ -117,7 +111,7 @@ public class TypeCoercer */ public static boolean typeIsBoolean(final String typeSignature) { - return ("Ljava.lang.Boolean;".equals(typeSignature)); + return (TypeConstants.TYPE_BOXED_BOOLEAN.equals(typeSignature)); } /** diff --git a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibrariesPreferencePage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibrariesPreferencePage.java index f9821a823..dd3a974c9 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibrariesPreferencePage.java +++ b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/classpath/JSFLibrariesPreferencePage.java @@ -118,7 +118,7 @@ public class JSFLibrariesPreferencePage extends PreferencePage implements IWorkb btnEdit.setEnabled(false); btnEdit.addSelectionListener(new SelectionAdapter(){ public void widgetSelected(SelectionEvent e) { - TreeItem[] element = (TreeItem[]) tv.getTree().getSelection(); + TreeItem[] element = tv.getTree().getSelection(); if (element != null){ openJSFLibraryEditDialog(element[0]); } @@ -212,6 +212,7 @@ public class JSFLibrariesPreferencePage extends PreferencePage implements IWorkb } public void dispose() { + // do nothing } public Object[] getElements(Object obj) { @@ -333,9 +334,10 @@ public class JSFLibrariesPreferencePage extends PreferencePage implements IWorkb public Image getImage(Object element) { if (element instanceof JSFLibrary) + { return libImg; - else - return jarImg; + } + return jarImg; } public String getText(Object element) { @@ -362,6 +364,7 @@ public class JSFLibrariesPreferencePage extends PreferencePage implements IWorkb } public void addListener(ILabelProviderListener listener) { + // no listeners supported } public void dispose() { @@ -378,6 +381,7 @@ public class JSFLibrariesPreferencePage extends PreferencePage implements IWorkb } public void removeListener(ILabelProviderListener listener) { + // no listeners supported } } 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 index 3ba48442f..c1aea6bcd 100644 --- 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 @@ -128,8 +128,9 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPage#getSelection() */ public IClasspathEntry getSelection() { - if (lv.getSelection()!= null){ - } + // TODO: dead code? + // if (lv.getSelection()!= null){ +// } return null; } @@ -137,6 +138,7 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements * @see org.eclipse.jdt.ui.wizards.IClasspathContainerPage#setSelection(org.eclipse.jdt.core.IClasspathEntry) */ public void setSelection(IClasspathEntry containerEntry) { + // getSelection always returns null } public void createControl(Composite parent) { @@ -236,6 +238,7 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements * @see org.eclipse.jface.viewers.IContentProvider#dispose() */ public void dispose() { + // do nothing } /* (non-Javadoc) @@ -275,9 +278,8 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements JSFLibrary lib = (JSFLibrary)element; if (lib.isImplementation()) { return lib.getName() + " [implementation]"; //$NON-NLS-1$ - } else { - return lib.getName(); } + return lib.getName(); } return null; } @@ -287,7 +289,8 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements libImg.dispose(); } - public void addListener(ILabelProviderListener listener) { + public void addListener(ILabelProviderListener listener) { + // no listener support } public boolean isLabelProperty(Object element, String property) { @@ -295,13 +298,16 @@ public class JSFLibraryContainerWizardPage extends WizardPage implements } public void removeListener(ILabelProviderListener listener) { + // no listener support } } private void validate() { + // TODO: what's this for? seems dead } private void doListSelected(SelectionChangedEvent event) { + // what's this for? seems dead. } private void doDoubleClick(DoubleClickEvent event) { 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 index 097043155..d1c6ede76 100644 --- 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 @@ -253,6 +253,7 @@ public class JSFLibraryWizard extends Wizard implements INewWizard { } public void dispose() { + // do nothing } public void inputChanged(Viewer viewer, Object oldInput, @@ -283,6 +284,7 @@ public class JSFLibraryWizard extends Wizard implements INewWizard { } public void addListener(ILabelProviderListener listener) { + // no listeners supported } public void dispose() { @@ -295,6 +297,7 @@ public class JSFLibraryWizard extends Wizard implements INewWizard { } public void removeListener(ILabelProviderListener listener) { + // no listeners supported } }); @@ -419,6 +422,7 @@ public class JSFLibraryWizard extends Wizard implements INewWizard { } public void widgetDefaultSelected(SelectionEvent e) { + // no handling for default selection } private void validate() { 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 index 5da37449f..bc20ec649 100644 --- 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 @@ -40,9 +40,9 @@ 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.JSFCorePlugin; +import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigModel; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfiglModelSource; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryRegistryUtil; -import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigModel; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFProjectLibraryReference; import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.ArchiveFile; import org.eclipse.jst.jsf.core.internal.jsflibraryregistry.JSFLibrary; @@ -55,7 +55,6 @@ 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.graphics.Image; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; @@ -78,7 +77,7 @@ public class JSFLibraryConfigControl extends Composite { final private int COLUMN_LIB_NAME = 1; private JSFLibraryConfigModel workingCopyModel = null; - private JSFLibraryConfiglModelSource persistentModel = null; + // TODO: never read private JSFLibraryConfiglModelSource persistentModel = null; private ComboViewer cvImplLib; private CheckboxTableViewer ctvSelCompLib; @@ -115,7 +114,7 @@ public class JSFLibraryConfigControl extends Composite { */ public void loadControlValuesFromModel(JSFLibraryConfiglModelSource source) { if (source != null) { - persistentModel = source; + // never read persistentModel = source; workingCopyModel = JSFLibraryConfigModel.JSFLibraryConfigModelFactory.createInstance(source); initializeControlValues(); } else { @@ -134,6 +133,7 @@ public class JSFLibraryConfigControl extends Composite { * @see org.eclipse.swt.widgets.Composite#checkSubclass() */ protected void checkSubclass() { + // TODO: overriding sub-class checking? why? } /** @@ -241,9 +241,7 @@ public class JSFLibraryConfigControl extends Composite { btnDeployJars = new Button(this, SWT.CHECK); btnDeployJars.setLayoutData(new GridData(GridData.END, GridData.CENTER, false, false, 2, 1)); btnDeployJars.setText(Messages.JSFLibraryConfigControl_DeployJAR); - btnDeployJars.addSelectionListener(new SelectionListener() { - public void widgetDefaultSelected(SelectionEvent e) { - } + btnDeployJars.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { JSFProjectLibraryReference jsflib = getCurrentSelectedJSFImplLib(); jsflib.setToBeDeployed(btnDeployJars.getSelection()); @@ -538,6 +536,7 @@ public class JSFLibraryConfigControl extends Composite { return jsfComplLibs.toArray(); } public void dispose() { + // do nothing } public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { if (newInput == null) { @@ -554,6 +553,7 @@ public class JSFLibraryConfigControl extends Composite { return jsfImplLibs.toArray(); } public void dispose() { + // do nothing } public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { if (newInput == null) { @@ -637,6 +637,7 @@ public class JSFLibraryConfigControl extends Composite { } public void dispose() { + // do nothing } public Object[] getElements(Object obj) { @@ -664,14 +665,14 @@ public class JSFLibraryConfigControl extends Composite { // ------- ISelectionChangedListener Interface ------------ public void selectionChanged(SelectionChangedEvent event) { - + // do nothing; TODO: what's the point then? } /* (non-Javadoc) * @see org.eclipse.jface.viewers.IDoubleClickListener#doubleClick(org.eclipse.jface.viewers.DoubleClickEvent) */ public void doubleClick(DoubleClickEvent event) { - + // do nothing; TODO: what's the point then? } } @@ -692,16 +693,17 @@ public class JSFLibraryConfigControl extends Composite { public Image getImage(Object element) { if (element instanceof JSFProjectLibraryReference) - return libImg; - else - return jarImg; + { + return libImg; + } + return jarImg; } public String getText(Object element) { StringBuffer labelBuf = new StringBuffer(); if (element instanceof JSFProjectLibraryReference) { JSFProjectLibraryReference libWrapper = (JSFProjectLibraryReference)element; - JSFLibrary lib = (JSFLibrary)libWrapper.getLibrary(); + JSFLibrary lib = libWrapper.getLibrary(); labelBuf.append(lib.getName()); if (lib.isImplementation()) { labelBuf.append(" [implementation"); //$NON-NLS-1$ @@ -722,6 +724,7 @@ public class JSFLibraryConfigControl extends Composite { } public void addListener(ILabelProviderListener listener) { + // not handling listeners } public void dispose() { @@ -738,6 +741,7 @@ public class JSFLibraryConfigControl extends Composite { } 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/JSFLibraryPropertyPage.java b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryPropertyPage.java index 0b3a6c6c9..13afc404a 100644 --- a/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryPropertyPage.java +++ b/jsf/plugins/org.eclipse.jst.jsf.ui/src/org/eclipse/jst/jsf/ui/internal/jsflibraryconfig/JSFLibraryPropertyPage.java @@ -16,11 +16,13 @@ import org.eclipse.core.resources.IProject; import org.eclipse.core.resources.IResource; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IAdaptable; +import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.NullProgressMonitor; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.J2EEModuleDependencyDelegate; -import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfiglModelSource; -import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigProjectData; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigModel; +import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigProjectData; +import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfiglModelSource; +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.widgets.Composite; @@ -129,7 +131,7 @@ public class JSFLibraryPropertyPage extends PropertyPage { try { IFacetedProject fProject = ProjectFacetsManager.create(project); - Iterator it = ((IFacetedProject)fProject).getProjectFacets().iterator(); + Iterator it = fProject.getProjectFacets().iterator(); IProjectFacetVersion fv = null; String facetId = null; while (it.hasNext()) { @@ -141,7 +143,7 @@ public class JSFLibraryPropertyPage extends PropertyPage { } } catch (CoreException e) { - + JSFUiPlugin.log(IStatus.ERROR, "Error creating faceted project", e); } return false; 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 index 7218afb8a..b81c89f34 100644 --- 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 @@ -11,7 +11,6 @@ package org.eclipse.jst.jsf.ui.internal.project.facet; import java.util.ArrayList; -import java.util.Collections; import java.util.Iterator; import org.eclipse.core.runtime.CoreException; @@ -22,15 +21,15 @@ import org.eclipse.jface.dialogs.IInputValidator; import org.eclipse.jface.dialogs.InputDialog; import org.eclipse.jface.window.Window; import org.eclipse.jst.j2ee.project.facet.IJ2EEModuleFacetInstallDataModelProperties; -import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfiglModelSource; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfigDialogSettingData; +import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFLibraryConfiglModelSource; import org.eclipse.jst.jsf.core.internal.jsflibraryconfig.JSFProjectLibraryReference; 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.jsflibraryconfig.IJSFImplLibraryCreationListener; -import org.eclipse.jst.jsf.ui.internal.jsflibraryconfig.JSFLibraryConfigControl; import org.eclipse.jst.jsf.ui.internal.jsflibraryconfig.JSFImplLibraryCreationEvent; +import org.eclipse.jst.jsf.ui.internal.jsflibraryconfig.JSFLibraryConfigControl; import org.eclipse.swt.SWT; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; @@ -91,7 +90,7 @@ public class JSFFacetInstallPage extends DataModelWizardPage implements IJSFFace */ public JSFFacetInstallPage() { //FIXME: following WebFacetInstallPage pattern which will be fixed at somepoint - super(DataModelFactory.createDataModel(new AbstractDataModelProvider(){}), "jsf.facet.install.page"); //$NON-NLS-1$ + 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(); @@ -117,7 +116,7 @@ public class JSFFacetInstallPage extends DataModelWizardPage implements IJSFFace jsfLibCfgComp = new JSFLibraryConfigControl(composite, SWT.NONE); jsfLibCfgComp.addOkClickedListener(new IJSFImplLibraryCreationListener() { public void okClicked(JSFImplLibraryCreationEvent event) { - if (((JSFImplLibraryCreationEvent) event).isLibraryCreated()) { + if (event.isLibraryCreated()) { validatePage(); } } @@ -254,7 +253,7 @@ public class JSFFacetInstallPage extends DataModelWizardPage implements IJSFFace String[] selection = null; if (complibs != null) { - selection = (String[])complibs.getArray(SETTINGS_COMPLIB_SELECT_DEPLOY); + selection = complibs.getArray(SETTINGS_COMPLIB_SELECT_DEPLOY); } JSFLibraryConfiglModelSource source = new JSFLibraryConfigDialogSettingData( |