Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.osgi')
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/framework/FilterImpl.java4
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/ModuleClassLoader.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/log/EquinoxLogWriter.java4
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/permadmin/SecurityRow.java6
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/BERProcessor.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/PKCS7Processor.java4
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/SignatureBlockProcessor.java4
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/ContentHandlerFactoryImpl.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/URLStreamHandlerFactoryImpl.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/Storage.java4
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/bundlefile/NestedDirBundleFile.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/url/BundleResourceHandler.java2
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/util/TextProcessor.java4
-rw-r--r--bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/util/ManifestElement.java4
14 files changed, 23 insertions, 23 deletions
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/framework/FilterImpl.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/framework/FilterImpl.java
index f496852db..dea3620d1 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/framework/FilterImpl.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/framework/FilterImpl.java
@@ -1667,7 +1667,7 @@ public class FilterImpl implements Filter /* since Framework 1.1 */ {
}
private String parse_value() throws InvalidSyntaxException {
- StringBuffer sb = new StringBuffer(filterChars.length - pos);
+ StringBuilder sb = new StringBuilder(filterChars.length - pos);
parseloop: while (true) {
char c = filterChars[pos];
@@ -1703,7 +1703,7 @@ public class FilterImpl implements Filter /* since Framework 1.1 */ {
}
private Object parse_substring() throws InvalidSyntaxException {
- StringBuffer sb = new StringBuffer(filterChars.length - pos);
+ StringBuilder sb = new StringBuilder(filterChars.length - pos);
List<String> operands = new ArrayList<>(10);
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/ModuleClassLoader.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/ModuleClassLoader.java
index 61bfd8927..cfe4b48fb 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/ModuleClassLoader.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/loader/ModuleClassLoader.java
@@ -393,7 +393,7 @@ public abstract class ModuleClassLoader extends ClassLoader implements BundleRef
@Override
public String toString() {
Bundle b = getBundle();
- StringBuffer result = new StringBuffer(super.toString());
+ StringBuilder result = new StringBuilder(super.toString());
if (b == null)
return result.toString();
return result.append('[').append(b.getSymbolicName()).append(':').append(b.getVersion()).append("(id=").append(b.getBundleId()).append(")]").toString(); //$NON-NLS-1$//$NON-NLS-2$
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/log/EquinoxLogWriter.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/log/EquinoxLogWriter.java
index 32fa2ff8d..1fd7dcb6b 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/log/EquinoxLogWriter.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/log/EquinoxLogWriter.java
@@ -410,7 +410,7 @@ class EquinoxLogWriter implements SynchronousLogListener, LogFilter {
private String getDate(Date date) {
Calendar c = Calendar.getInstance();
c.setTime(date);
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
appendPaddedInt(c.get(Calendar.YEAR), 4, sb).append('-');
appendPaddedInt(c.get(Calendar.MONTH) + 1, 2, sb).append('-');
appendPaddedInt(c.get(Calendar.DAY_OF_MONTH), 2, sb).append(' ');
@@ -421,7 +421,7 @@ class EquinoxLogWriter implements SynchronousLogListener, LogFilter {
return sb.toString();
}
- private StringBuffer appendPaddedInt(int value, int pad, StringBuffer buffer) {
+ private StringBuilder appendPaddedInt(int value, int pad, StringBuilder buffer) {
pad = pad - 1;
if (pad == 0)
return buffer.append(Integer.toString(value));
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/permadmin/SecurityRow.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/permadmin/SecurityRow.java
index c00e7728f..64bdc0eb9 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/permadmin/SecurityRow.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/permadmin/SecurityRow.java
@@ -162,7 +162,7 @@ public final class SecurityRow implements ConditionalPermissionInfo {
return result;
}
- private static void escapeString(String str, StringBuffer output) {
+ private static void escapeString(String str, StringBuilder output) {
int len = str.length();
for (int i = 0; i < len; i++) {
char c = str.charAt(i);
@@ -186,7 +186,7 @@ public final class SecurityRow implements ConditionalPermissionInfo {
}
private static String unescapeString(String str) {
- StringBuffer output = new StringBuffer(str.length());
+ StringBuilder output = new StringBuilder(str.length());
int end = str.length();
for (int i = 0; i < end; i++) {
char c = str.charAt(i);
@@ -439,7 +439,7 @@ public final class SecurityRow implements ConditionalPermissionInfo {
}
static String getEncoded(String name, ConditionInfo[] conditionInfos, PermissionInfo[] permissionInfos, boolean deny) {
- StringBuffer result = new StringBuffer();
+ StringBuilder result = new StringBuilder();
if (deny)
result.append(ConditionalPermissionInfo.DENY);
else
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/BERProcessor.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/BERProcessor.java
index 5da9c8e93..5cfb4215b 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/BERProcessor.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/BERProcessor.java
@@ -152,7 +152,7 @@ public class BERProcessor {
*/
@Override
public String toString() {
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
switch (classOfTag) {
case UNIVERSAL_TAGCLASS :
sb.append('U');
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/PKCS7Processor.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/PKCS7Processor.java
index 248a2e471..37bc0ec11 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/PKCS7Processor.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/PKCS7Processor.java
@@ -59,7 +59,7 @@ public class PKCS7Processor implements SignedContentConstants {
private Date signingTime;
private static String oid2String(int oid[]) {
- StringBuffer sb = new StringBuffer();
+ StringBuilder sb = new StringBuilder();
for (int i = 0; i < oid.length; i++) {
if (i > 0)
sb.append('.');
@@ -205,7 +205,7 @@ public class PKCS7Processor implements SignedContentConstants {
// create the appropriate date time string format
// date format could be yyyyMMddHHmmss[.s...]Z or yyyyMMddHHmmssZ
int dotIndex = dateString.indexOf('.');
- StringBuffer dateFormatSB = new StringBuffer("yyyyMMddHHmmss"); //$NON-NLS-1$
+ StringBuilder dateFormatSB = new StringBuilder("yyyyMMddHHmmss"); //$NON-NLS-1$
if (dotIndex != -1) {
// yyyyMMddHHmmss[.s...]Z, find out number of s in the bracket
int noS = dateString.indexOf('Z') - 1 - dotIndex;
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/SignatureBlockProcessor.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/SignatureBlockProcessor.java
index 63bf5522b..04d6abe02 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/SignatureBlockProcessor.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/signedcontent/SignatureBlockProcessor.java
@@ -454,14 +454,14 @@ public class SignatureBlockProcessor implements SignedContentConstants {
private static String stripContinuations(String entry) {
if (entry.indexOf("\n ") < 0 && entry.indexOf("\r ") < 0) //$NON-NLS-1$//$NON-NLS-2$
return entry;
- StringBuffer buffer = new StringBuffer(entry);
+ StringBuilder buffer = new StringBuilder(entry);
removeAll(buffer, "\r\n "); //$NON-NLS-1$
removeAll(buffer, "\n "); //$NON-NLS-1$
removeAll(buffer, "\r "); //$NON-NLS-1$
return buffer.toString();
}
- private static StringBuffer removeAll(StringBuffer buffer, String toRemove) {
+ private static StringBuilder removeAll(StringBuilder buffer, String toRemove) {
int index = buffer.indexOf(toRemove);
int length = toRemove.length();
while (index > 0) {
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/ContentHandlerFactoryImpl.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/ContentHandlerFactoryImpl.java
index 3afa85e77..077ade007 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/ContentHandlerFactoryImpl.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/ContentHandlerFactoryImpl.java
@@ -81,7 +81,7 @@ public class ContentHandlerFactoryImpl extends MultiplexingFactory implements ja
convertedContentType = convertedContentType.replace('-', '_');
StringTokenizer tok = new StringTokenizer(builtInHandlers, "|"); //$NON-NLS-1$
while (tok.hasMoreElements()) {
- StringBuffer name = new StringBuffer();
+ StringBuilder name = new StringBuilder();
name.append(tok.nextToken());
name.append("."); //$NON-NLS-1$
name.append(convertedContentType);
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/URLStreamHandlerFactoryImpl.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/URLStreamHandlerFactoryImpl.java
index 204715ffd..d74f030b9 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/URLStreamHandlerFactoryImpl.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/url/URLStreamHandlerFactoryImpl.java
@@ -66,7 +66,7 @@ public class URLStreamHandlerFactoryImpl extends MultiplexingFactory implements
Class<?> clazz;
StringTokenizer tok = new StringTokenizer(builtInHandlers, "|"); //$NON-NLS-1$
while (tok.hasMoreElements()) {
- StringBuffer name = new StringBuffer();
+ StringBuilder name = new StringBuilder();
name.append(tok.nextToken());
name.append("."); //$NON-NLS-1$
name.append(protocol);
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/Storage.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/Storage.java
index d4d89cd17..8b985cafe 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/Storage.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/Storage.java
@@ -2019,7 +2019,7 @@ public class Storage {
}
public static String sanitizeFilterInput(String filePattern) throws InvalidSyntaxException {
- StringBuffer buffer = null;
+ StringBuilder buffer = null;
boolean foundEscape = false;
for (int i = 0; i < filePattern.length(); i++) {
char c = filePattern.charAt(i);
@@ -2034,7 +2034,7 @@ public class Storage {
case ')' :
if (!foundEscape) {
if (buffer == null) {
- buffer = new StringBuffer(filePattern.length() + 16);
+ buffer = new StringBuilder(filePattern.length() + 16);
buffer.append(filePattern.substring(0, i));
}
// must escape with '\'
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/bundlefile/NestedDirBundleFile.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/bundlefile/NestedDirBundleFile.java
index 4d8fc7c68..1167b9f45 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/bundlefile/NestedDirBundleFile.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/bundlefile/NestedDirBundleFile.java
@@ -108,7 +108,7 @@ public class NestedDirBundleFile extends BundleFile {
private String prependNestedDir(String path) {
if (path.length() > 0 && path.charAt(0) == '/')
path = path.substring(1);
- return new StringBuffer(nestedDirName).append(path).toString();
+ return new StringBuilder(nestedDirName).append(path).toString();
}
@Override
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/url/BundleResourceHandler.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/url/BundleResourceHandler.java
index b0ada55f0..991f0574b 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/url/BundleResourceHandler.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/storage/url/BundleResourceHandler.java
@@ -193,7 +193,7 @@ public abstract class BundleResourceHandler extends URLStreamHandler {
*/
@Override
protected String toExternalForm(URL url) {
- StringBuffer result = new StringBuffer(url.getProtocol());
+ StringBuilder result = new StringBuilder(url.getProtocol());
result.append("://"); //$NON-NLS-1$
String host = url.getHost();
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/util/TextProcessor.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/util/TextProcessor.java
index 4e6224e6f..69f2e910b 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/util/TextProcessor.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/util/TextProcessor.java
@@ -171,7 +171,7 @@ public class TextProcessor {
delimiter = delimiter == null ? getDefaultDelimiters() : delimiter;
- StringBuffer target = new StringBuffer();
+ StringBuilder target = new StringBuilder();
target.append(LRE);
char ch;
@@ -240,7 +240,7 @@ public class TextProcessor {
if (!IS_PROCESSING_NEEDED || str == null || str.length() <= 1)
return str;
- StringBuffer buf = new StringBuffer();
+ StringBuilder buf = new StringBuilder();
for (int i = 0; i < str.length(); i++) {
char c = str.charAt(i);
switch (c) {
diff --git a/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/util/ManifestElement.java b/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/util/ManifestElement.java
index 76833c7ee..51cd39f78 100644
--- a/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/util/ManifestElement.java
+++ b/bundles/org.eclipse.osgi/supplement/src/org/eclipse/osgi/util/ManifestElement.java
@@ -589,7 +589,7 @@ public class ManifestElement {
Enumeration<String> directiveKeys = getDirectiveKeys();
if (attrKeys == null && directiveKeys == null)
return mainValue;
- StringBuffer result = new StringBuffer(mainValue);
+ StringBuilder result = new StringBuilder(mainValue);
if (attrKeys != null) {
while (attrKeys.hasMoreElements()) {
String key = attrKeys.nextElement();
@@ -605,7 +605,7 @@ public class ManifestElement {
return result.toString();
}
- private void addValues(boolean directive, String key, String[] values, StringBuffer result) {
+ private void addValues(boolean directive, String key, String[] values, StringBuilder result) {
if (values == null)
return;
for (String value : values) {

Back to the top