public class GlobalFacadeBase extends Object implements GlobalFacade, FacadeMessages
| Modifier and Type | Field and Description |
|---|---|
private JRebirthApplication<?> |
application
The application.
|
private CommandFacade |
commandFacade
The facade for Commands components.
|
private ComponentFactory |
componentFactory
The factory used to build all component.
|
private int |
eventSequence
The index of JRebirth events.
|
private JRebirthThreadPoolExecutor |
executorService
The default executor.
|
private JRebirthThreadPoolExecutor |
highPriorityExecutorService
The high priority executor used only for most important runnable.
|
static String |
HPTP_BASE_NAME
The High Priority Thread Pool base name [HPTP].
|
static String |
JTP_BASE_NAME
The JRebirth Thread Pool base name [JTP].
|
private static JRLogger |
LOGGER
The class logger.
|
private Notifier |
notifier
The notifier that dispatch waves.
|
private ServiceFacade |
serviceFacade
The facade for Services components.
|
private UiFacade |
uiFacade
The facade for UI components.
|
COMPONENT_BUILD_ERROR, COMPONENT_CUSTOM_FACTORY_ERROR, COMPONENT_RETRIEVAL_ERROR, JREBIRTH_EVENT, JTP_CREATION| Constructor and Description |
|---|
GlobalFacadeBase(JRebirthApplication<?> application)
Default Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected CommandFacade |
buildCommandFacade()
Build the CommandFacade singleton to use.
|
protected NotifierBase |
buildNotifier()
Build the notifier singleton to use.
|
protected ServiceFacade |
buildServiceFacade()
Build the ServiceFacade singleton to use.
|
protected UiFacade |
buildUiFacade()
Build the UiFacade singleton to use.
|
protected void |
customStop()
Method to override to do some stuff when application stops.
|
JRebirthApplication<?> |
getApplication() |
CommandFacade |
getCommandFacade() |
ComponentFactory |
getComponentFactory() |
JRebirthThreadPoolExecutor |
getExecutorService() |
JRebirthThreadPoolExecutor |
getHighPriorityExecutorService() |
Notifier |
getNotifier() |
ServiceFacade |
getServiceFacade() |
UiFacade |
getUiFacade() |
void |
stop()
Propagate the stop action into the global facade.
|
void |
trackEvent(JRebirthEventType eventType,
Class<?> source,
Class<?> target,
String... eventData)
Track an event.
|
public static final String JTP_BASE_NAME
public static final String HPTP_BASE_NAME
private static final JRLogger LOGGER
private final ComponentFactory componentFactory
private final transient JRebirthApplication<?> application
private final transient Notifier notifier
private final transient UiFacade uiFacade
private final transient ServiceFacade serviceFacade
private final transient CommandFacade commandFacade
private final JRebirthThreadPoolExecutor executorService
private final JRebirthThreadPoolExecutor highPriorityExecutorService
private int eventSequence
public GlobalFacadeBase(JRebirthApplication<?> application)
application - the current application launchedpublic final void trackEvent(JRebirthEventType eventType, Class<?> source, Class<?> target, String... eventData)
trackEvent in interface GlobalFacadeeventType - the type of the eventsource - the source class of the eventtarget - the target class of the eventeventData - the data of the vent (like class name or other)public ComponentFactory getComponentFactory()
getComponentFactory in interface GlobalFacadepublic final JRebirthApplication<?> getApplication()
getApplication in interface GlobalFacadepublic final Notifier getNotifier()
getNotifier in interface GlobalFacadepublic final UiFacade getUiFacade()
getUiFacade in interface GlobalFacadepublic final ServiceFacade getServiceFacade()
getServiceFacade in interface GlobalFacadepublic final CommandFacade getCommandFacade()
getCommandFacade in interface GlobalFacadepublic JRebirthThreadPoolExecutor getExecutorService()
getExecutorService in interface GlobalFacadepublic JRebirthThreadPoolExecutor getHighPriorityExecutorService()
getHighPriorityExecutorService in interface GlobalFacadepublic final void stop()
throws CoreException
stop in interface GlobalFacadeCoreException - if an error occurred while closing a streamprotected void customStop()
protected CommandFacade buildCommandFacade()
protected ServiceFacade buildServiceFacade()
protected UiFacade buildUiFacade()
protected NotifierBase buildNotifier()
Copyright © 2011–2014 JRebirth OSS. All rights reserved.