try
{
RentalOperations.getInstance();
MainFrame mainFrame = new MainFrame();
mainFrame.setBounds( 10, 10, 400, 400 );
mainFrame.show();
}
catch ( SeriousErrorException exception )
{
JOptionPane.showMessageDialog( null,
TERMINATION_MESSAGE_HEADER +
exception.getMessage(),
TERMINATION_MESSAGE_TITLE,
JOptionPane.ERROR_MESSAGE );
displayStackTrace( exception );
Throwable imbeddedException =
exception.getCause();
displayStackTrace( imbeddedException );
}
catch ( Exception exception )
{
JOptionPane.showMessageDialog( null,
TERMINATION_MESSAGE_HEADER +
exception.getMessage(),
UNEXCEPTED_TERMINATION_MESSAGE_TITLE,
JOptionPane.ERROR_MESSAGE );
displayStackTrace( exception );
}