/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
@SuppressWarnings("serial")
private boolean plotterListening = false;
/*
Hierarchy of panels and layouts for this tab:
ThreadTab (BorderLayout)
North: topPanel (BorderLayout)
Center: controlPanel (FlowLayout)
timeComboBox
Center: plotterPanel (BorderLayout)
Center: plotter
*/
}
super(vmPanel, getTabName());
timeComboBox));
textArea.setEditable(false);
firstTabPanel.setOpaque(false);
firstTabToolPanel.setOpaque(false);
messageLabel = new JLabel();
}
if (!plotterListening) {
plotterListening = true;
}
private int tlCount;
private int tpCount;
private long ttCount;
private long[] threads;
private long timeStamp;
public Boolean doInBackground() {
try {
if (overviewPanel != null) {
} else {
ttCount = 0L;
}
}
}
}
}
return true;
} catch (IOException e) {
return false;
} catch (UndeclaredThrowableException e) {
return false;
}
}
protected void done() {
try {
if (!get()) {
return;
}
} catch (InterruptedException ex) {
return;
} catch (ExecutionException ex) {
}
return;
}
if (overviewPanel != null) {
}
for (long t : threads) {
l.add(t);
}
}
}
long[] newThreads = threads;
newThreads = new long[l.size()];
newThreads[i] = l.get(i);
}
}
for (long oldThread : oldThreads) {
boolean found = false;
for (long newThread : newThreads) {
found = true;
break;
}
}
if (!found) {
if (!doFilter) {
}
}
}
// Threads are in reverse chronological order
long newThread = newThreads[i];
boolean found = false;
for (long oldThread : oldThreads) {
found = true;
break;
}
}
if (!found) {
}
}
}
};
}
if (lastSelected != -1) {
}
} else {
}
public void run() {
try {
if (proxyClient.isLockUsageSupported() &&
// VMs that support the monitor usage monitoring
break;
}
}
} else {
// VM doesn't support monitor usage monitoring
}
ti.getThreadName(),
ti.getThreadName(),
ti.getLockName()));
} else {
ti.getThreadName(),
ti.getLockName(),
ti.getLockOwnerName()));
}
ti.getWaitedCount()));
int index = 0;
}
}
}
index++;
}
}
} catch (IOException ex) {
// Ignore
} catch (UndeclaredThrowableException e) {
}
public void run() {
}
});
}
});
}
}
private void doUpdate() {
public void run() {
update();
}
});
}
private void detectDeadlock() {
public void run() {
try {
// Display message for 30 seconds. Do it on a separate thread so
// the sleep won't hold up the worker queue.
// This will be replaced later by separate statusbar logic.
new Thread() {
public void run() {
try {
public void run() {
}
});
} catch (InterruptedException ex) {
// Ignore
} catch (InvocationTargetException ex) {
// Ignore
}
public void run() {
}
});
}
}.start();
return;
}
public void run() {
// Remove old deadlock tabs
}
if (deadlockedThreads != null) {
textArea.setEditable(false);
splitPane.setOneTouchExpandable(true);
} else {
}
for (long t : deadlockedThreads[i]) {
listModel.addElement(t);
}
}
}
}
});
} catch (IOException e) {
// Ignore
} catch (UndeclaredThrowableException e) {
}
}
});
}
// Return deadlocked threads or null
return null;
}
// keep track of which thread is visited
// one thread can only be in one cycle
while (true) {
if (deadlockedThread < 0) {
// a cycle found
}
// start a new cycle from a non-visited thread
if (!visited[j]) {
deadlockedThread = j;
visited[j] = true;
break;
}
}
if (deadlockedThread < 0) {
// done
break;
}
}
if (visited[j]) {
deadlockedThread = -1;
} else {
deadlockedThread = j;
visited[j] = true;
}
break;
}
}
}
}
// ActionListener interface
if (cmd == "detectDeadlock") {
}
}
// DocumentListener interface
doUpdate();
}
doUpdate();
}
doUpdate();
}
super(listModel);
boolean isSelected, boolean cellHasFocus) {
}
}
return this;
}
});
}
Dimension d = super.getPreferredSize();
return d;
}
}
boolean promptRemoved = false;
addFocusListener(this);
setAccessibleName(this, prompt);
}
public void revalidate() {
super.revalidate();
}
private void updateForeground() {
if (promptRemoved) {
} else {
}
}
if (!promptRemoved) {
return "";
} else {
return super.getText();
}
}
if (!promptRemoved) {
setText("");
promptRemoved = true;
}
}
promptRemoved = false;
}
}
}
if (overviewPanel == null) {
overviewPanel = new ThreadOverviewPanel();
}
return new OverviewPanel[] { overviewPanel };
}
}
}
}
}