public class UIUtilities
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
JAVA_APPLICATION_PATH
This is the folder for storing the exceptions on the local drive.
|
static java.lang.String |
UNKNOWN
Is the reflected 'unknown' description of the reported email message.
|
static java.lang.String |
USER_HOME
Is the reflected 'user home directory ' description of the reported email message.
|
static java.lang.String |
USER_NAME
Is the reflected 'user name ' description of the reported email message.
|
Constructor and Description |
---|
UIUtilities() |
Modifier and Type | Method and Description |
---|---|
static int |
fatalErrorMessage(Version version)
Creates a message dialog box in the middle of the screen.
|
static int |
fatalErrorMessage(Version version,
java.awt.Component parent,
java.lang.String title,
java.lang.String message,
java.lang.Throwable exception)
Creates a modal message dialog box in the middle of the application or
when the application is null in the middle of the screen.
|
static int |
fatalErrorMessage(Version version,
javax.swing.JComponent parent)
Creates a modal message dialog box in the middle of the application or
when the application is null in the middle of the screen.
|
static int |
fatalErrorMessage(Version version,
java.lang.String title,
java.lang.String message,
java.lang.Throwable exception)
Creates a modal message dialog box in the middle of the application or
when the application is null in the middle of the screen.
|
static javax.swing.ImageIcon |
getImageIcon(java.lang.String imageName)
Returns on the delivered image name the icon.
|
static void |
sendMailTo(Version version,
java.lang.Throwable throwable)
This method will send a message to the corresponding developer of the
application with different other information which the developer needs
replicate the error message.
|
public static final java.lang.String JAVA_APPLICATION_PATH
public static final java.lang.String UNKNOWN
public static final java.lang.String USER_NAME
public static final java.lang.String USER_HOME
public static javax.swing.ImageIcon getImageIcon(java.lang.String imageName)
/resources/images/
where the different images can be found.imageName
- Image stringpublic static final void sendMailTo(Version version, java.lang.Throwable throwable)
version
- Version information about the calling application.throwable
- Is the error exception.public static final int fatalErrorMessage(Version version)
version
- Version information about the calling application.#fatalErrorMessage(Component)
public static final int fatalErrorMessage(Version version, javax.swing.JComponent parent)
#FATAL_EXIT
, or FATAL_SEND_EMAIL
.version
- Version information about the calling application.parent
- Is the parent component in which this dialog box should be
centered. If this component is null
it is shown in the
center of the desktop screen.#FATAL_EXIT
,
or FATAL_SEND_EMAIL
, depending on the current input value
of exception_
.public static final int fatalErrorMessage(Version version, java.lang.String title, java.lang.String message, java.lang.Throwable exception)
#FATAL_EXIT
, or FATAL_SEND_EMAIL
.version
- Version information about the calling application.title
- Is the title of the option pane. This can also be null.message
- Is the message of the option pane. This can also be null.exception
- Is the exception by itself. This can also be null.#FATAL_EXIT
,
or FATAL_SEND_EMAIL
, depending on the current input value
of exception_
.#fatalErrorMessage(Component, String, String, Throwable)
public static final int fatalErrorMessage(Version version, java.awt.Component parent, java.lang.String title, java.lang.String message, java.lang.Throwable exception)
#FATAL_EXIT
, or FATAL_SEND_EMAIL
.version
- Version information about the calling application.parent
- Is the parent component in which this dialog box should be
centered. If this component is null
it is shown in the
center of the desktop screen.title
- Is the title of the option pane. This can also be null.message
- Is the message of the option pane. This can also be null.exception
- Is the exception by itself. This can also be null.#FATAL_EXIT
,
or FATAL_SEND_EMAIL
, depending on the current input value
of exception_
.17-November-2016 09:39 Deutsches Elektronen-Synchrotron DESY in der Helmholtz-Gemeinschaft