コード例 #1
0
ファイル: GuiLauncher.java プロジェクト: Chlara/DPFManager
 private EmbeddedFXWorkbench createWorkbench(
     final Launcher<ClassPathXmlApplicationContext> launcher,
     final Class<? extends FXWorkbench> workbenchHandler) {
   final Workbench annotation = workbenchHandler.getAnnotation(Workbench.class);
   final String id = annotation.id();
   if (id.isEmpty())
     throw new AttributeNotFoundException("no workbench id found for: " + workbenchHandler);
   final FXWorkbench handler = launcher.registerAndGetBean(workbenchHandler, id, Scope.SINGLETON);
   return new EmbeddedFXWorkbench(handler, getWorkbenchDecorator());
 }
コード例 #2
0
 private String[] getPerspectiveAnnotations() {
   org.jacpfx.api.annotations.workbench.Workbench annotations =
       WorkbenchCheckComponentsAndPerspectives.class.getAnnotation(
           org.jacpfx.api.annotations.workbench.Workbench.class);
   return annotations.perspectives();
 }