Interface ApplicationContext<Config extends ApplicationConfiguration,Context extends ApplicationContext<Config,Context>>
-
- All Superinterfaces:
AutoCloseable,Closeable,JAXXContext
- All Known Implementing Classes:
DefaultApplicationContext
public interface ApplicationContext<Config extends ApplicationConfiguration,Context extends ApplicationContext<Config,Context>> extends JAXXContext, Closeable
Application context (only one instance should exists and it is initialized by theApplicationBoot).Created by tchemit on 26/01/2018.
- Author:
- Tony Chemit - dev@tchemit.fr
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidaddAction(String actionLabel, Runnable action)voidbusy()voidclose()List<ApplicationContextComponent<Config,Context,?>>components()voiddisplayInfo(String startMessage)ApplicationBoot<Config,Context>getBoot()ConfiggetConfig()FramegetMainUI()SwingSessionHelpergetSwingSessionHelper()voidhandlingError(Exception e)voidhandlingError(String message, Exception e)voidinstall(JAXXContext context)Install the application into the givencontext.booleanisClosed()default booleanisClosing()voidlock()FramenewMainUI()voidnotBusy()voidremoveMainUI()default voidsetMainUIVisible(Frame ui, boolean replace)JAXXInitialContexttoInitialContext()voidunlock()List<ApplicationContextComponent<Config,Context,?>>variables()-
Methods inherited from interface org.nuiton.jaxx.runtime.JAXXContext
getContextValue, getContextValue, removeContextValue, removeContextValue, setContextValue, setContextValue
-
-
-
-
Method Detail
-
install
void install(JAXXContext context)
Install the application into the givencontext.- Parameters:
context- where to install application context
-
toInitialContext
JAXXInitialContext toInitialContext()
- Returns:
- a new initial context within this application context.
-
getBoot
ApplicationBoot<Config,Context> getBoot()
- Returns:
- application boot
-
getConfig
Config getConfig()
- Returns:
- application config
-
components
List<ApplicationContextComponent<Config,Context,?>> components()
-
variables
List<ApplicationContextComponent<Config,Context,?>> variables()
-
isClosed
boolean isClosed()
- Returns:
trueif context is closed.- See Also:
ApplicationBoot.isClosed()
-
isClosing
default boolean isClosing()
-
handlingError
void handlingError(Exception e)
-
displayInfo
void displayInfo(String startMessage)
-
close
void close()
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
lock
void lock() throws InterruptedException
- Throws:
InterruptedException
-
unlock
void unlock()
-
busy
void busy()
-
notBusy
void notBusy()
-
getMainUI
Frame getMainUI()
-
newMainUI
Frame newMainUI()
-
removeMainUI
void removeMainUI()
-
getSwingSessionHelper
SwingSessionHelper getSwingSessionHelper()
-
setMainUIVisible
default void setMainUIVisible(Frame ui, boolean replace)
-
-