Interface DesignerRoot
-
- All Known Implementing Classes:
DesignerRootImpl
public interface DesignerRoot
Provides access to the globals of the app.- Author:
- Clément Fournier
-
-
Field Summary
Fields Modifier and Type Field Description static AppServiceDescriptor<ASTManager>
AST_MANAGER
static AppServiceDescriptor<GlobalDiskManager>
DISK_MANAGER
static AppServiceDescriptor<EventLogger>
LOGGER
Logger of the app.static AppServiceDescriptor<MessageChannel<NodeSelectionSource.NodeSelectionEvent>>
NODE_SELECTION_CHANNEL
Channel used to transmit node selection events to all interested components.static AppServiceDescriptor<PersistenceManager>
PERSISTENCE_MANAGER
Manages settings persistence.static AppServiceDescriptor<RichTextMapper>
RICH_TEXT_MAPPER
Maps a node to its rich text representation.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description javafx.stage.Stage
getMainStage()
Gets the main stage of the application.<T> T
getService(AppServiceDescriptor<T> descriptor)
Gets the instance of a service shared by the app.org.reactfx.value.Val<java.lang.Boolean>
isCtrlDownProperty()
Returns true if the ctrl key is being pressed.boolean
isDeveloperMode()
If true, some more events are pushed to the event log, and console streams are open.<T> void
registerService(AppServiceDescriptor<T> descriptor, T component)
Register a service for the given descriptor.void
shutdownServices()
Shutdown all registered service components that implementCloseableService
.
-
-
-
Field Detail
-
RICH_TEXT_MAPPER
static final AppServiceDescriptor<RichTextMapper> RICH_TEXT_MAPPER
Maps a node to its rich text representation.
-
PERSISTENCE_MANAGER
static final AppServiceDescriptor<PersistenceManager> PERSISTENCE_MANAGER
Manages settings persistence.
-
LOGGER
static final AppServiceDescriptor<EventLogger> LOGGER
Logger of the app.
-
NODE_SELECTION_CHANNEL
static final AppServiceDescriptor<MessageChannel<NodeSelectionSource.NodeSelectionEvent>> NODE_SELECTION_CHANNEL
Channel used to transmit node selection events to all interested components.
-
AST_MANAGER
static final AppServiceDescriptor<ASTManager> AST_MANAGER
-
DISK_MANAGER
static final AppServiceDescriptor<GlobalDiskManager> DISK_MANAGER
-
-
Method Detail
-
getService
<T> T getService(AppServiceDescriptor<T> descriptor)
Gets the instance of a service shared by the app.- Parameters:
descriptor
- Service descriptor
-
registerService
<T> void registerService(AppServiceDescriptor<T> descriptor, T component)
Register a service for the given descriptor.- Throws:
java.lang.IllegalStateException
- if the service was already registered to some other component
-
getMainStage
javafx.stage.Stage getMainStage()
Gets the main stage of the application.- Returns:
- The main stage
-
isDeveloperMode
boolean isDeveloperMode()
If true, some more events are pushed to the event log, and console streams are open. This is enabled by the -v or --verbose option on command line for now.
-
isCtrlDownProperty
org.reactfx.value.Val<java.lang.Boolean> isCtrlDownProperty()
Returns true if the ctrl key is being pressed. Vetoed by any other key press.
-
shutdownServices
void shutdownServices()
Shutdown all registered service components that implementCloseableService
. Called when the app exits.
-
-