Here you can find the source of excMsg(String msg, Throwable t)
Parameter | Description |
---|---|
msg | a parameter |
t | a parameter |
public static void excMsg(String msg, Throwable t)
//package com.java2s; //License from project: Open Source License import javax.swing.JOptionPane; public class Main { /**//ww w .jav a2 s .co m * Exception message dialog. Displays message plus the exception and * exception message. Actually handles the more general Throwable. * * @param msg * @param t */ public static void excMsg(String msg, Throwable t) { msg += "\n" + "Throwable: " + t + "\n" + t.getMessage(); // Show it in a message box JOptionPane.showMessageDialog(null, msg, "Error", JOptionPane.ERROR_MESSAGE); System.out.println(msg); } }