Lines 57-62
Link Here
|
57 |
import java.io.IOException; |
57 |
import java.io.IOException; |
58 |
import java.util.Iterator; |
58 |
import java.util.Iterator; |
59 |
import java.util.Vector; |
59 |
import java.util.Vector; |
|
|
60 |
import java.util.logging.Level; |
61 |
import java.util.logging.Logger; |
60 |
import javax.swing.*; |
62 |
import javax.swing.*; |
61 |
|
63 |
|
62 |
|
64 |
|
Lines 107-112
Link Here
|
107 |
public static final int ERROR = 16; |
109 |
public static final int ERROR = 16; |
108 |
private static final boolean DEBUG = System.getProperty("org.netbeans.lib.profiler.common.Profiler") != null; // NOI18N |
110 |
private static final boolean DEBUG = System.getProperty("org.netbeans.lib.profiler.common.Profiler") != null; // NOI18N |
109 |
private static Profiler defaultProfiler; |
111 |
private static Profiler defaultProfiler; |
|
|
112 |
private static final Logger LOG = Logger.getLogger(Profiler.class.getName()); |
110 |
|
113 |
|
111 |
//~ Instance fields ---------------------------------------------------------------------------------------------------------- |
114 |
//~ Instance fields ---------------------------------------------------------------------------------------------------------- |
112 |
|
115 |
|
Lines 117-122
Link Here
|
117 |
|
120 |
|
118 |
public static synchronized Profiler getDefault() { |
121 |
public static synchronized Profiler getDefault() { |
119 |
if (defaultProfiler == null) { |
122 |
if (defaultProfiler == null) { |
|
|
123 |
LOG.info("about to create default profiler"); |
120 |
final Iterator it = Service.providers(Profiler.class); |
124 |
final Iterator it = Service.providers(Profiler.class); |
121 |
|
125 |
|
122 |
if (it.hasNext()) { |
126 |
if (it.hasNext()) { |
Lines 130-135
Link Here
|
130 |
if (defaultProfiler == null) { |
134 |
if (defaultProfiler == null) { |
131 |
throw new InternalError("Should never happen"); // NOI18N |
135 |
throw new InternalError("Should never happen"); // NOI18N |
132 |
} |
136 |
} |
|
|
137 |
LOG.log(Level.INFO, "profiler is here " + defaultProfiler, new Exception("stacktrace")); |
133 |
} |
138 |
} |
134 |
|
139 |
|
135 |
return defaultProfiler; |
140 |
return defaultProfiler; |