Interface ScreenController
public interface ScreenController
Opens screens.
Strata.screens() returns the platform's controller, so code that
opens a screen names no engine adapter:
Strata.screens().open(new ExchangeScreen(exchange));
Each engine adapter decides where a screen opens. An engine with screens of its own shows it as one of them, and a screen stack pushes it. The adapter's documentation says which.
Strata and its engine adapters implement this interface. Do not implement it.
-
Method Summary
Modifier and TypeMethodDescriptiondefault ScreenHandleOpens a screen in the platform's default theme, the oneThemeRef.platform()names.Opens a screen in a theme.
-
Method Details
-
open
Opens a screen in the platform's default theme, the oneThemeRef.platform()names. The same asopen(screen, ThemeRef.platform()).- Parameters:
screen- the screen to open- Returns:
- the handle of the new opening; its methods do nothing once the screen closes
- Throws:
ThemeException- if the theme cannot be resolved or lacks keys the screen's tree needs, on platforms that build the screen at once
-
open
Opens a screen in a theme. The screen follows the theme's packs and overrides as long as it is open.- Parameters:
screen- the screen to opentheme- the theme for its components- Returns:
- the handle of the new opening; its methods do nothing once the screen closes
- Throws:
ThemeException- if the theme cannot be resolved or lacks keys the screen's tree needs, on platforms that build the screen at once
-