Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Vogel2019-07-05 06:44:17 +0000
committerLars Vogel2019-07-05 10:25:23 +0000
commit4fd4608546a5276d0e15042faa8b7ec2bde8d686 (patch)
tree8ebd605e5664c7f0b256c947505d441c5cc2d373
parentf3bf3e1e9cdf027ff6a83b9fbac95fef74a1a5bf (diff)
downloadrt.equinox.framework-4fd4608546a5276d0e15042faa8b7ec2bde8d686.tar.gz
rt.equinox.framework-4fd4608546a5276d0e15042faa8b7ec2bde8d686.tar.xz
rt.equinox.framework-4fd4608546a5276d0e15042faa8b7ec2bde8d686.zip
Using indexOf char instead of indexOf String
See https://sourceforge.net/p/findbugs/feature-requests/300/#cb7f for a performance related discussion
-rw-r--r--bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/debug/FrameworkDebugOptions.java22
1 files changed, 17 insertions, 5 deletions
diff --git a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/debug/FrameworkDebugOptions.java b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/debug/FrameworkDebugOptions.java
index c2d7209e3..6f7db2570 100644
--- a/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/debug/FrameworkDebugOptions.java
+++ b/bundles/org.eclipse.osgi/container/src/org/eclipse/osgi/internal/debug/FrameworkDebugOptions.java
@@ -13,13 +13,25 @@
*******************************************************************************/
package org.eclipse.osgi.internal.debug;
-import java.io.*;
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
import java.net.URL;
-import java.util.*;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.Properties;
+import java.util.Set;
import org.eclipse.osgi.internal.framework.EquinoxConfiguration;
import org.eclipse.osgi.internal.location.LocationHelper;
-import org.eclipse.osgi.service.debug.*;
-import org.osgi.framework.*;
+import org.eclipse.osgi.service.debug.DebugOptions;
+import org.eclipse.osgi.service.debug.DebugOptionsListener;
+import org.eclipse.osgi.service.debug.DebugTrace;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.InvalidSyntaxException;
+import org.osgi.framework.ServiceReference;
import org.osgi.util.tracker.ServiceTracker;
import org.osgi.util.tracker.ServiceTrackerCustomizer;
@@ -256,7 +268,7 @@ public class FrameworkDebugOptions implements DebugOptions, ServiceTrackerCustom
}
private String getSymbolicName(String option) {
- int firstSlashIndex = option.indexOf("/"); //$NON-NLS-1$
+ int firstSlashIndex = option.indexOf('/');
if (firstSlashIndex > 0)
return option.substring(0, firstSlashIndex);
return null;

Back to the top