Here you can find the source of showSuccessMessage(Component parentComponent, String message)
public static void showSuccessMessage(Component parentComponent, String message)
//package com.java2s; //License from project: Open Source License import java.awt.Component; import javax.swing.JOptionPane; public class Main { public static void showSuccessMessage(Component parentComponent, String message, String title) { showMessage(parentComponent, title, message, JOptionPane.INFORMATION_MESSAGE); }// w w w .jav a 2 s .co m public static void showSuccessMessage(Component parentComponent, String message) { showSuccessMessage(parentComponent, message, "Success"); } public static void showSuccessMessage(String message) { showSuccessMessage(null, message); } public static void showMessage(Component parentComponent, String title, String message, int messageType) { JOptionPane.showMessageDialog(parentComponent, message, title, messageType); } }