Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Kurtakov2017-06-21 08:43:34 -0400
committerAlexander Kurtakov2017-06-21 09:01:46 -0400
commit7f22c5b775e1e0ce90bbf3055fd99b974d1e7414 (patch)
treec720b93e0776396735899f32589feed349dea9d1 /bundles/org.eclipse.equinox.p2.metadata
parentc14ec65184393b6cc1ecd976068b8bdd7938eec1 (diff)
downloadrt.equinox.p2-7f22c5b775e1e0ce90bbf3055fd99b974d1e7414.tar.gz
rt.equinox.p2-7f22c5b775e1e0ce90bbf3055fd99b974d1e7414.tar.xz
rt.equinox.p2-7f22c5b775e1e0ce90bbf3055fd99b974d1e7414.zip
Bug 518574 - Use StandardCharsets
Bump BREE to 1.8 for bundles that were too low to have StandardCharsets. Change-Id: Iac9e9615c5179b970df893182f5f1c6e3dd4d574 Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.metadata')
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/.classpath2
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/.settings/org.eclipse.jdt.core.prefs6
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/META-INF/MANIFEST.MF4
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/pom.xml2
-rw-r--r--bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/internal/p2/metadata/License.java8
5 files changed, 10 insertions, 12 deletions
diff --git a/bundles/org.eclipse.equinox.p2.metadata/.classpath b/bundles/org.eclipse.equinox.p2.metadata/.classpath
index 64c5e31b7..eca7bdba8 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/.classpath
+++ b/bundles/org.eclipse.equinox.p2.metadata/.classpath
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
diff --git a/bundles/org.eclipse.equinox.p2.metadata/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.p2.metadata/.settings/org.eclipse.jdt.core.prefs
index 410dd2a63..47d687a60 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/.settings/org.eclipse.jdt.core.prefs
+++ b/bundles/org.eclipse.equinox.p2.metadata/.settings/org.eclipse.jdt.core.prefs
@@ -14,9 +14,9 @@ org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annota
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.compliance=1.8
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
@@ -118,7 +118,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.5
+org.eclipse.jdt.core.compiler.source=1.8
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
diff --git a/bundles/org.eclipse.equinox.p2.metadata/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.metadata/META-INF/MANIFEST.MF
index 215b638bb..4ab4b7279 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.p2.metadata/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.equinox.p2.metadata;singleton:=true
-Bundle-Version: 2.3.200.qualifier
+Bundle-Version: 2.4.0.qualifier
Bundle-Activator: org.eclipse.equinox.internal.p2.metadata.MetadataActivator
Bundle-Vendor: %providerName
Bundle-Localization: plugin
@@ -86,4 +86,4 @@ Import-Package: org.eclipse.osgi.service.localization;version="1.0.0",
org.eclipse.osgi.util,
org.osgi.framework;version="1.6.0"
Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Bundle-RequiredExecutionEnvironment: JavaSE-1.8
diff --git a/bundles/org.eclipse.equinox.p2.metadata/pom.xml b/bundles/org.eclipse.equinox.p2.metadata/pom.xml
index f6a85e823..d03289596 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/pom.xml
+++ b/bundles/org.eclipse.equinox.p2.metadata/pom.xml
@@ -9,6 +9,6 @@
</parent>
<groupId>org.eclipse.equinox</groupId>
<artifactId>org.eclipse.equinox.p2.metadata</artifactId>
- <version>2.3.200-SNAPSHOT</version>
+ <version>2.4.0-SNAPSHOT</version>
<packaging>eclipse-plugin</packaging>
</project>
diff --git a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/internal/p2/metadata/License.java b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/internal/p2/metadata/License.java
index 7e3d48695..12514599f 100644
--- a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/internal/p2/metadata/License.java
+++ b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/internal/p2/metadata/License.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2008, 2010 Genuitec, LLC and others. All rights reserved. This
+ * Copyright (c) 2008, 2017 Genuitec, LLC and others. All rights reserved. This
* program and the accompanying materials are made available under the terms of
* the Eclipse Public License v1.0 which accompanies this distribution, and is
* available at http://www.eclipse.org/legal/epl-v10.html
@@ -11,9 +11,9 @@
******************************************************************************/
package org.eclipse.equinox.internal.p2.metadata;
-import java.io.UnsupportedEncodingException;
import java.math.BigInteger;
import java.net.URI;
+import java.nio.charset.StandardCharsets;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import org.eclipse.equinox.p2.metadata.ILicense;
@@ -114,13 +114,11 @@ public class License implements ILicense {
try {
MessageDigest algorithm = MessageDigest.getInstance("MD5"); //$NON-NLS-1$
algorithm.reset();
- algorithm.update(message.getBytes("UTF-8")); //$NON-NLS-1$
+ algorithm.update(message.getBytes(StandardCharsets.UTF_8));
byte[] digestBytes = algorithm.digest();
return new BigInteger(1, digestBytes);
} catch (NoSuchAlgorithmException e) {
throw new RuntimeException(e);
- } catch (UnsupportedEncodingException e) {
- throw new RuntimeException(e);
}
}

Back to the top