This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information

--Environment information

Documents for the development of and with JVx.

--Environment information

Postby Development@SIB » Tue Oct 01, 2013 3:08 pm



This article is outdated - please use our new system at

https://doc.sibvisions.com




If you want to know the launch environment of your client application, simply ask the launcher. A launcher always is related to a specific environment, e.g. desktop, mobile, web/html.

If your application should behave or look different in different environments, simply check the environment via:

Code: Select all
<launcher>.getEnvironmentName();

This command returns DESKTOP if you are using SwingApplication or SwingApplet as launcher. There's no difference if your application runs as Webstart, Applet or Desktop application. Swing is always Desktop environment.

There are some useful constants in ILauncher:

Code: Select all
ENVIRONMENT_DESKTOP,
ENVIRONMENT_WEB,
ENVIRONMENT_MOBILE,
ENVIRONMENT_HEADLESS

A simple way to check the environment is available via UILauncher, e.g.

Code: Select all
<uilauncher>.isDesktopEnvironment();


Attention

If you use JVx' DBSecurityManager, be aware that it checks ENV_ columns. If your WORKSCREENS table contains the column ENV_DESKTOP (values: Y, N) the security manager ignores all screens that don't fit your client environment. It's very easy to configure one screen for different environments without chaning role assignments.
User avatar
Development@SIB
 
Posts: 313
Joined: Mon Sep 28, 2009 1:54 pm

Return to Documentation