-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMessageBox.java
25 lines (19 loc) · 940 Bytes
/
MessageBox.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import javax.swing.JOptionPane;
import com.digitalpersona.uareu.Reader;
import com.digitalpersona.uareu.UareUException;
public class MessageBox {
public static void BadQuality(Reader.CaptureQuality q){
JOptionPane.showMessageDialog(null, q.toString(), "Mala Calidad de Captura", JOptionPane.WARNING_MESSAGE);
}
public static void BadStatus(Reader.Status s){
String str = String.format("Reader status: %s", s.toString());
JOptionPane.showMessageDialog(null, str, "Reader status", JOptionPane.ERROR_MESSAGE);
}
public static void DpError(String strFunctionName, UareUException e){
String str = String.format("%s returned DP error %d \n%s", strFunctionName, (e.getCode() & 0xffff), e.toString());
JOptionPane.showMessageDialog(null, str, "Error", JOptionPane.ERROR_MESSAGE);
}
public static void Warning(String strText){
JOptionPane.showMessageDialog(null, strText, "Advertencia", JOptionPane.WARNING_MESSAGE);
}
}