Interface FxLauncherAbstract.AppFactory

All Known Implementing Classes:
FxLauncherAbstract.DefaultAppFactory, MicronautFxLauncher.MicronautAppFactory
Enclosing class:
FxLauncherAbstract

public static interface FxLauncherAbstract.AppFactory
Interface that can be used to create and pre-initialize ApplicationDelegate and BackgroundApp. This interface can be implemented by subclasses (or direct callers of the constructor.) By "pre-initialize" we mean call implementation-dependent methods prior to init() or start(). This interface is designed to support using Dependency Injection frameworks like Micronaut, see MicronautSfxLauncher.
  • Method Details

    • createBackgroundApp

      BackgroundApp createBackgroundApp(Class<? extends BackgroundApp> backgroundAppClass)
      Create the background class instance from a Class object
      Parameters:
      backgroundAppClass - the class to create
      Returns:
      application instance
    • createAppDelegate

      ApplicationDelegate createAppDelegate(Class<? extends ApplicationDelegate> appDelegateClass, javafx.application.Application proxyApplication)
      Create the background class instance from a Class object
      Parameters:
      appDelegateClass - the class to create
      proxyApplication - a reference to the proxy Application created by Supernaut.FX
      Returns:
      application instance