Context services

Modelio v3

Modelio API context services can be used to get information about the Modelio application itself. Available data is:

  • Modelio’s version
  • Modelio’s current language
  • Modelio’s current workspace path
  • Modelio’s currently opened project path

The following code snippet lists the Modelio Application context available data.

 1IModelioContext ctx = Modelio.getInstance().getContext();
 2
 3System.out.println("About Modelio");
 4System.out.println(" version           = " + ctx.getVersion());
 5System.out.println(" language          = " + ctx.getLanguage());
 6System.out.println(" workspace         = " + ctx.getWorkspacePath());
 7
 8if (ctx.getProjectSpacePath() != null)
 9    System.out.println(" project space     = " + ctx.getProjectSpacePath());

See System.out limitations