Return to Snippet

Revision: 63035
at April 2, 2013 02:18 by laurenceosx


Updated Code
// gi(someObj); - groovy inspect obj
def gi = { itObjToInspect ->
    javax.swing.SwingUtilities.invokeAndWait( {
        groovy.inspect.swingui.ObjectBrowser.inspect( itObjToInspect );
    } );
}

// gik(); - kill all groovy inspect windows
def gik = {
    java.awt.Frame.getFrames()
        .findAll { it.visible && it.title == 'Groovy Object Browser' }
        .each { itWin ->
            javax.swing.SwingUtilities.invokeAndWait({ itWin.visible = false; itWin.dispose(); });
        }
}

Revision: 63034
at April 2, 2013 02:15 by laurenceosx


Updated Code
// gi(someObj); - groovy inspect obj
def gi = { itObjToInspect ->
    javax.swing.SwingUtilities.invokeAndWait( {
        groovy.inspect.swingui.ObjectBrowser.inspect( itObjToInspect );
    } );
}

// gik(); - kill all groovy inspect windows
def gik = {
	java.awt.Frame.getFrames()
		.findAll { it.visible && it.title == 'Groovy Object Browser' }
		.each { itWin ->
			javax.swing.SwingUtilities.invokeAndWait({ itWin.visible = false; itWin.dispose(); });
		}
}

Revision: 63033
at April 2, 2013 01:57 by laurenceosx


Updated Code
// gi(someObj); - groovy inspect obj
def gi = { itObjToInspect ->
    javax.swing.SwingUtilities.invokeAndWait( {
        groovy.inspect.swingui.ObjectBrowser.inspect( itObjToInspect );
    } );
}

// gik(); - kill all groovy inspect windows
def gik = {
    java.awt.Frame.getFrames()
        .findAll { it.visible && it.title == 'Groovy Object Browser' }
        .each { 
            javax.swing.SwingUtilities.invokeAndWait({ it.visible = false; it.dispose(); });
        }
}

Revision: 63032
at April 2, 2013 01:52 by laurenceosx


Updated Code
// gi(someObj); - groovy inspect obj
def gi = { itObjToInspect ->
    javax.swing.SwingUtilities.invokeAndWait( {
        groovy.inspect.swingui.ObjectBrowser.inspect( itObjToInspect );
    } );
}

// gik(); - kill all groovy inspect windows
def gik = {
    java.awt.Frame.getFrames()
        .findAll { it.visible && it.title == 'Groovy Object Browser' }
        .each { it.visible = false; it.dispose() }
}

Revision: 63031
at April 2, 2013 01:51 by laurenceosx


Initial Code
// gi(aSomeObj); - groovy inspect obj
def gi = { itObjToInspect ->
    javax.swing.SwingUtilities.invokeAndWait( {
        groovy.inspect.swingui.ObjectBrowser.inspect( itObjToInspect );
    } );
}

// gik(); - kill all groovy inspect windows
def gik = {
    java.awt.Frame.getFrames()
        .findAll { it.visible && it.title == 'Groovy Object Browser' }
        .each { it.visible = false; it.dispose() }
}

Initial URL
http://groovy.codehaus.org/gapi/groovy/inspect/swingui/ObjectBrowser.html

Initial Description
see http://groovy.codehaus.org/gapi/groovy/inspect/swingui/ObjectBrowser.html

Initial Title
Groovy - EDT Inspect and Kill All Inspection Windows

Initial Tags
groovy

Initial Language
Groovy