Here you can find the source of assertIsEDT()
public static void assertIsEDT()
//package com.java2s; //License from project: Open Source License import javax.swing.SwingUtilities; public class Main { public static void assertIsEDT() { if (!SwingUtilities.isEventDispatchThread()) { throw new RuntimeException("Not in the event dispatch thread"); }//from w w w. j a v a 2 s.c o m } }