Class JavaFxDialogService

java.lang.Object
dev.zemco.codegame.presentation.dialog.JavaFxDialogService
All Implemented Interfaces:
IDialogService

public class JavaFxDialogService extends Object implements IDialogService
Implementation of a service for presenting popup dialogs to the user using JavaFX. They are presented in a separate modal window synchronously by blocking the calling thread until they are closed by the user.

For simple alerts (error and information types), the JavaFX class Alert with appropriate Alert.AlertType was used.

Author:
Erik Zemčík
See Also:
  • Alert
  • Constructor Details

  • Method Details

    • showErrorDialog

      public void showErrorDialog(String title, String message)
      Description copied from interface: IDialogService
      Displays an error alert dialog to the user. Blocks the current thread until it is closed.
      Specified by:
      showErrorDialog in interface IDialogService
      Parameters:
      title - title of the dialog
      message - message of the dialog
    • showInformationDialog

      public void showInformationDialog(String title, String message)
      Description copied from interface: IDialogService
      Displays an information alert dialog to the user. Blocks the current thread until it is closed.
      Specified by:
      showInformationDialog in interface IDialogService
      Parameters:
      title - title of the dialog
      message - message of the dialog