diff options
author | Alexander Kurtakov | 2017-06-21 12:43:34 +0000 |
---|---|---|
committer | Alexander Kurtakov | 2017-06-21 13:01:46 +0000 |
commit | 7f22c5b775e1e0ce90bbf3055fd99b974d1e7414 (patch) | |
tree | c720b93e0776396735899f32589feed349dea9d1 /bundles/org.eclipse.equinox.p2.repository | |
parent | c14ec65184393b6cc1ecd976068b8bdd7938eec1 (diff) | |
download | rt.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.repository')
6 files changed, 17 insertions, 18 deletions
diff --git a/bundles/org.eclipse.equinox.p2.repository/.classpath b/bundles/org.eclipse.equinox.p2.repository/.classpath index 64c5e31b7..eca7bdba8 100644 --- a/bundles/org.eclipse.equinox.p2.repository/.classpath +++ b/bundles/org.eclipse.equinox.p2.repository/.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.repository/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.p2.repository/.settings/org.eclipse.jdt.core.prefs index 731c74549..b3a3226c7 100644 --- a/bundles/org.eclipse.equinox.p2.repository/.settings/org.eclipse.jdt.core.prefs +++ b/bundles/org.eclipse.equinox.p2.repository/.settings/org.eclipse.jdt.core.prefs @@ -13,9 +13,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 @@ -113,7 +113,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.repository/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.repository/META-INF/MANIFEST.MF index 6c8562e53..13023d597 100644 --- a/bundles/org.eclipse.equinox.p2.repository/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.repository/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %pluginName Bundle-SymbolicName: org.eclipse.equinox.p2.repository;singleton:=true -Bundle-Version: 2.3.300.qualifier +Bundle-Version: 2.4.0.qualifier Bundle-Activator: org.eclipse.equinox.internal.p2.repository.Activator Bundle-Vendor: %providerName Bundle-Localization: plugin @@ -39,7 +39,7 @@ Export-Package: org.eclipse.equinox.internal.p2.persistence; org.eclipse.equinox.p2.repository.spi;version="2.0.0" Require-Bundle: org.eclipse.equinox.common, org.eclipse.equinox.registry;bundle-version="3.3.0" -Bundle-RequiredExecutionEnvironment: J2SE-1.5 +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy Import-Package: javax.crypto, javax.xml.parsers, diff --git a/bundles/org.eclipse.equinox.p2.repository/pom.xml b/bundles/org.eclipse.equinox.p2.repository/pom.xml index 44d90c4e4..f6e59cc31 100644 --- a/bundles/org.eclipse.equinox.p2.repository/pom.xml +++ b/bundles/org.eclipse.equinox.p2.repository/pom.xml @@ -9,6 +9,6 @@ </parent> <groupId>org.eclipse.equinox</groupId> <artifactId>org.eclipse.equinox.p2.repository</artifactId> - <version>2.3.300-SNAPSHOT</version> + <version>2.4.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> </project> diff --git a/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/CompositeWriter.java b/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/CompositeWriter.java index c48b7bcdf..fc76aca34 100644 --- a/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/CompositeWriter.java +++ b/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/CompositeWriter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008, 2010 IBM Corporation and others. + * Copyright (c) 2008, 2017 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -10,12 +10,10 @@ *******************************************************************************/ package org.eclipse.equinox.internal.p2.persistence; -import org.eclipse.equinox.p2.metadata.Version; - import java.io.OutputStream; -import java.io.UnsupportedEncodingException; import java.net.URI; import org.eclipse.core.runtime.URIUtil; +import org.eclipse.equinox.p2.metadata.Version; /* * Class used to persist a composite repository. @@ -25,7 +23,7 @@ public class CompositeWriter extends XMLWriter implements XMLConstants { private static final String REPOSITORY_ELEMENT = "repository"; //$NON-NLS-1$ private static final Version CURRENT_VERSION = Version.createOSGi(1, 0, 0); - public CompositeWriter(OutputStream output, String type) throws UnsupportedEncodingException { + public CompositeWriter(OutputStream output, String type) { super(output, new XMLWriter.ProcessingInstruction[] {XMLWriter.ProcessingInstruction.makeTargetVersionInstruction(type, CURRENT_VERSION)}); // TODO: add a processing instruction for the metadata version } diff --git a/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/XMLWriter.java b/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/XMLWriter.java index 69fd8e67f..6973a2f06 100644 --- a/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/XMLWriter.java +++ b/bundles/org.eclipse.equinox.p2.repository/src/org/eclipse/equinox/internal/p2/persistence/XMLWriter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2010 IBM Corporation and others. + * Copyright (c) 2007, 2017 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -10,11 +10,12 @@ *******************************************************************************/ package org.eclipse.equinox.internal.p2.persistence; -import org.eclipse.equinox.p2.metadata.Version; - import java.io.*; -import java.util.*; +import java.nio.charset.StandardCharsets; +import java.util.Map; import java.util.Map.Entry; +import java.util.Stack; +import org.eclipse.equinox.p2.metadata.Version; public class XMLWriter implements XMLConstants { @@ -59,8 +60,8 @@ public class XMLWriter implements XMLConstants { private PrintWriter pw; - public XMLWriter(OutputStream output, ProcessingInstruction[] piElements) throws UnsupportedEncodingException { - this.pw = new PrintWriter(new OutputStreamWriter(output, "UTF8"), false); //$NON-NLS-1$ + public XMLWriter(OutputStream output, ProcessingInstruction[] piElements) { + this.pw = new PrintWriter(new OutputStreamWriter(output, StandardCharsets.UTF_8), false); println(ProcessingInstruction.XML_UTF8); this.elements = new Stack<String>(); this.open = false; |