Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcbateman2007-04-10 18:51:36 +0000
committercbateman2007-04-10 18:51:36 +0000
commit7a3d08bb73dea2370ed3423e2288fd5614552933 (patch)
treea7788d8db505ebfe0df3563c51177e41c5672995
parent8ee2b410aad8b90a43246e9b5437526a19135bf9 (diff)
downloadwebtools.jsf-7a3d08bb73dea2370ed3423e2288fd5614552933.tar.gz
webtools.jsf-7a3d08bb73dea2370ed3423e2288fd5614552933.tar.xz
webtools.jsf-7a3d08bb73dea2370ed3423e2288fd5614552933.zip
Added Java 5 compile/runtime level. Removed some discouraged access code.
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath2
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs14
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/META-INF/MANIFEST.MF1
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties2
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/JavaClassWizardPage.java9
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/PackageButtonDialogField.java7
-rw-r--r--jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/utils/PathUtil.java5
7 files changed, 26 insertions, 14 deletions
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath
index 751c8f2e5..304e86186 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath
+++ b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.classpath
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <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/.settings/org.eclipse.jdt.core.prefs b/jsf/plugins/org.eclipse.jst.jsf.common.ui/.settings/org.eclipse.jdt.core.prefs
index 3c6f371c7..0f6f7ac44 100644
--- 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
@@ -1,9 +1,9 @@
-#Fri Apr 06 21:12:03 PDT 2007
+#Tue Apr 10 08:59:53 PDT 2007
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.4
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.4
+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
@@ -16,7 +16,7 @@ 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.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
@@ -51,14 +51,14 @@ 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=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=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=warning
+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
@@ -74,4 +74,4 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=di
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.4
+org.eclipse.jdt.core.compiler.source=1.5
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
index f9e7d4417..e9ed944e9 100644
--- 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
@@ -27,3 +27,4 @@ Export-Package: org.eclipse.jst.jsf.common.ui;x-friends:="org.eclipse.jst.pagede
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"
Eclipse-LazyStart: true
Bundle-Vendor: %plugin.provider
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties b/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties
index 5cc5c9c79..588f5a84b 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties
+++ b/jsf/plugins/org.eclipse.jst.jsf.common.ui/build.properties
@@ -14,3 +14,5 @@ bin.includes = META-INF/,\
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/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
index 6d773cefc..a99066659 100644
--- 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
@@ -28,7 +28,6 @@ import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.JavaConventions;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.core.JavaModelException;
-import org.eclipse.jdt.internal.compiler.impl.CompilerOptions;
import org.eclipse.jdt.ui.wizards.NewClassWizardPage;
/**
@@ -45,6 +44,8 @@ public class JavaClassWizardPage extends NewClassWizardPage {
private IStatus _fClassNameStatus, _fPackageNameStatus;
+ private final static String SOURCE_COMPLIANCE_1_3 = JavaCore.VERSION_1_3;
+
class InitialClassProperties {
// populate new wizard page
IType superClassType;
@@ -120,16 +121,16 @@ public class JavaClassWizardPage extends NewClassWizardPage {
}
}
_fClassNameStatus = JavaConventions
- .validateJavaTypeName(_initialValues.className, CompilerOptions.VERSION_1_3,CompilerOptions.VERSION_1_3);
+ .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, CompilerOptions.VERSION_1_3,CompilerOptions.VERSION_1_3);
+ .validateJavaTypeName(_initialValues.packageName, SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
_fClassNameStatus = JavaConventions
- .validateJavaTypeName(_initialValues.className, CompilerOptions.VERSION_1_3,CompilerOptions.VERSION_1_3);
+ .validateJavaTypeName(_initialValues.className, SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
}
if (_javaProject == null) {
return;
diff --git a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/PackageButtonDialogField.java b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/PackageButtonDialogField.java
index 5b3bcb483..223835238 100644
--- a/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/PackageButtonDialogField.java
+++ b/jsf/plugins/org.eclipse.jst.jsf.common.ui/src/org/eclipse/jst/jsf/common/ui/internal/dialogfield/PackageButtonDialogField.java
@@ -17,8 +17,9 @@ import org.eclipse.jdt.core.IJavaElement;
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.internal.compiler.impl.CompilerOptions;
+//import org.eclipse.jdt.internal.compiler.impl.CompilerOptions;
import org.eclipse.jdt.ui.JavaElementLabelProvider;
import org.eclipse.jface.window.Window;
import org.eclipse.jst.jsf.common.ui.JSFUICommonPlugin;
@@ -44,6 +45,8 @@ public class PackageButtonDialogField extends StringButtonDialogField {
private IPackageFragment _fCurrPackage;
+ private final static String SOURCE_COMPLIANCE_1_3 = JavaCore.VERSION_1_3;
+
/**
* @param packageRoot
*/
@@ -189,7 +192,7 @@ public class PackageButtonDialogField extends StringButtonDialogField {
String packName = getPackageText();
if (packName.length() > 0) {
- IStatus val = JavaConventions.validatePackageName(packName, CompilerOptions.VERSION_1_3,CompilerOptions.VERSION_1_3);
+ IStatus val = JavaConventions.validatePackageName(packName,SOURCE_COMPLIANCE_1_3,SOURCE_COMPLIANCE_1_3);
if (val.getSeverity() == IStatus.ERROR) {
status
.setError(DialogFieldResources
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
index fe30dd379..c7c75c876 100644
--- 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
@@ -180,6 +180,11 @@ public class PathUtil {
return uri;
}
+ /**
+ * @param javaProject
+ * @param parent
+ * @return the IPath for a a classpath object (?)
+ */
public static IPath getPathOnClasspath(IJavaProject javaProject,
Object parent) {
IPath result = null;

Back to the top