|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavabook.JavaBookDialog
javabook.MessageBox
This dialog is for displaying a single line of text. This dialog is intended for displaying a short warning or error message. The width of this dialog is adjusted to fit the displayed message and the dialog is placed at the center of the screen, unless you change it by using calling the setLocation method.
This class is provided as freeware. You are free to use as provided or modify to your heart's content. But you use it at your own risk. No implied or explicit warranty is given.
Field Summary |
Fields inherited from class javabook.JavaBookDialog |
ERROR_ICON, INFO_ICON, NO_ICON, QUESTION_ICON, WARNING_ICON |
Constructor Summary | |
MessageBox(java.awt.Frame owner)
Default constructor. |
|
MessageBox(java.awt.Frame owner,
boolean modal)
Constructs this dialog with 'owner' as its owner and display this dialog as modal if the parameter is true. |
Method Summary | |
void |
show(double number)
Displays the real number after converting it to a string. |
void |
show(double number,
int icon)
Displays the real number after converting it to a string. |
void |
show(double number,
int x,
int y)
Displays the real number after converting it to a string. |
void |
show(double number,
int x,
int y,
int icon)
Displays the real number after converting it to a string. |
void |
show(long number)
Displays the integer value after converting it to a string. |
void |
show(long number,
int icon)
Displays the integer value after converting it to a string. |
void |
show(long number,
int x,
int y)
Displays the integer value after converting it to a string. |
void |
show(long number,
int x,
int y,
int icon)
Displays the integer value after converting it to a string. |
void |
show(java.lang.String text)
Displays the String value. |
void |
show(java.lang.StringBuffer text)
Displays the StringBuffer value after conveting it to a string. |
void |
show(java.lang.StringBuffer text,
int icon)
Displays the StringBuffer value after conveting it to a string. |
void |
show(java.lang.StringBuffer text,
int x,
int y)
Displays the StringBuffer value after conveting it to a string. |
void |
show(java.lang.StringBuffer text,
int x,
int y,
int icon)
Displays the StringBuffer value after conveting it to a string. |
void |
show(java.lang.String text,
int icon)
Displays the String value. |
void |
show(java.lang.String text,
int x,
int y)
Displays the String value. |
void |
show(java.lang.String text,
int x,
int y,
int icon)
Displays the String value. |
Methods inherited from class javabook.JavaBookDialog |
setIcon, setLocation, setTitle |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MessageBox(java.awt.Frame owner)
owner
- a Frame object owner of this dialogpublic MessageBox(java.awt.Frame owner, boolean modal)
owner
- a Frame object owner of this dialogmodal
- true for modal dialog; false for modeless dialogMethod Detail |
public void show(long number)
number
- the integer value to displaypublic void show(double number)
number
- the real value to displaypublic void show(java.lang.String text)
text
- the String value to displaypublic void show(java.lang.StringBuffer text)
text
- the StringBuffer value to displaypublic void show(long number, int icon)
number
- the integer value to displayicon
- the icon to displaypublic void show(double number, int icon)
number
- the real value to displayicon
- the icon to displaypublic void show(java.lang.String text, int icon)
text
- the String value to displayicon
- the icon to displaypublic void show(java.lang.StringBuffer text, int icon)
text
- the StringBuffer value to displayicon
- the icon to displaypublic void show(long number, int x, int y)
number
- the integer value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originpublic void show(double number, int x, int y)
number
- the real value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originpublic void show(java.lang.String text, int x, int y)
text
- the String value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originpublic void show(java.lang.StringBuffer text, int x, int y)
text
- the StringBuffer value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originpublic void show(long number, int x, int y, int icon)
number
- the integer value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originicon
- the icon to displaypublic void show(double number, int x, int y, int icon)
number
- the real value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originicon
- the icon to displaypublic void show(java.lang.String text, int x, int y, int icon)
text
- the String value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originicon
- the icon to displaypublic void show(java.lang.StringBuffer text, int x, int y, int icon)
text
- the StringBuffer value to displayx
- the x-coordinate of this dialog's originy
- the y-coordiante of this dialog's originicon
- the icon to display
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |