Example usage for javafx.event ActionEvent getSource

List of usage examples for javafx.event ActionEvent getSource

Introduction

In this page you can find the example usage for javafx.event ActionEvent getSource.

Prototype

public Object getSource() 

Source Link

Document

The object on which the Event initially occurred.

Usage

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXNumberDefListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        LinkedList<CFButton> list = new LinkedList<CFButton>();

        vboxMenuAdd = new CFVBox(10);
        buttonAddNumberType = new CFButton();
        buttonAddNumberType.setMinWidth(200);
        buttonAddNumberType.setText("Add NumberType");
        buttonAddNumberType.setOnAction(new EventHandler<ActionEvent>() {
            @Override/*from  w w w  .j av  a  2s . c  o  m*/
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamNumberTypeObj obj = (ICFBamNumberTypeObj) schemaObj.getNumberTypeTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getNumberTypeFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamNumberTypeEditObj edit = (ICFBamNumberTypeEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXNumberTypePaneCommon jpanelCommon = (ICFBamJavaFXNumberTypePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddNumberType);
        }
        buttonAddNumberCol = new CFButton();
        buttonAddNumberCol.setMinWidth(200);
        buttonAddNumberCol.setText("Add NumberCol");
        buttonAddNumberCol.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamNumberColObj obj = (ICFBamNumberColObj) schemaObj.getNumberColTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getNumberColFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamNumberColEditObj edit = (ICFBamNumberColEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerTable(container);
                    ICFBamJavaFXNumberColPaneCommon jpanelCommon = (ICFBamJavaFXNumberColPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddNumberCol);
        }

        int len = list.size();
        CFButton arr[] = new CFButton[len];
        Iterator<CFButton> iter = list.iterator();
        int idx = 0;
        while (iter.hasNext()) {
            arr[idx++] = iter.next();
        }
        Arrays.sort(arr, new CompareCFButtonByText());
        for (idx = 0; idx < len; idx++) {
            vboxMenuAdd.getChildren().add(arr[idx]);
        }

        buttonCancelAdd = new CFButton();
        buttonCancelAdd.setMinWidth(200);
        buttonCancelAdd.setText("Cancel Add...");
        buttonCancelAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        vboxMenuAdd.getChildren().add(buttonCancelAdd);

        scrollMenuAdd = new ScrollPane();
        scrollMenuAdd.setMinWidth(240);
        scrollMenuAdd.setMaxWidth(240);
        scrollMenuAdd.setFitToWidth(true);
        scrollMenuAdd.setHbarPolicy(ScrollBarPolicy.NEVER);
        scrollMenuAdd.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
        scrollMenuAdd.setContent(vboxMenuAdd);

        buttonAdd = new CFButton();
        buttonAdd.setMinWidth(200);
        buttonAdd.setText("Add...");
        buttonAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(scrollMenuAdd);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAdd);

        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamNumberDefObj selectedInstance = getJavaFXFocusAsNumberDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("NUMD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getNumberDefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMT".equals(classCode)) {
                            ICFBamNumberTypeObj obj = (ICFBamNumberTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberTypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMC".equals(classCode)) {
                            ICFBamNumberColObj obj = (ICFBamNumberColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamNumberDefObj, ICFBamNumberTypeObj, ICFBamNumberColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamNumberDefObj selectedInstance = getJavaFXFocusAsNumberDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("NUMD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getNumberDefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMT".equals(classCode)) {
                            ICFBamNumberTypeObj obj = (ICFBamNumberTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberTypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMC".equals(classCode)) {
                            ICFBamNumberColObj obj = (ICFBamNumberColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXNumberColPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamNumberDefObj, ICFBamNumberTypeObj, ICFBamNumberColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamNumberDefObj selectedInstance = getJavaFXFocusAsNumberDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("NUMD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getNumberDefFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXNumberDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMT".equals(classCode)) {
                            ICFBamNumberTypeObj obj = (ICFBamNumberTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberTypeFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXNumberTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("NUMC".equals(classCode)) {
                            ICFBamNumberColObj obj = (ICFBamNumberColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getNumberColFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXNumberColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamNumberDefObj, ICFBamNumberTypeObj, ICFBamNumberColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXServerMethodListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        LinkedList<CFButton> list = new LinkedList<CFButton>();

        vboxMenuAdd = new CFVBox(10);
        buttonAddServerMethod = new CFButton();
        buttonAddServerMethod.setMinWidth(200);
        buttonAddServerMethod.setText("Add ServerMethod");
        buttonAddServerMethod.setOnAction(new EventHandler<ActionEvent>() {
            @Override/*w w w. jav a  2  s . c o m*/
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamServerMethodObj obj = (ICFBamServerMethodObj) schemaObj.getServerMethodTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getServerMethodFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamServerMethodEditObj edit = (ICFBamServerMethodEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerForTable(container);
                    ICFBamJavaFXServerMethodPaneCommon jpanelCommon = (ICFBamJavaFXServerMethodPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddServerMethod);
        }
        buttonAddServerObjFunc = new CFButton();
        buttonAddServerObjFunc.setMinWidth(200);
        buttonAddServerObjFunc.setText("Add ServerObjFunc");
        buttonAddServerObjFunc.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamServerObjFuncObj obj = (ICFBamServerObjFuncObj) schemaObj.getServerObjFuncTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getServerObjFuncFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamServerObjFuncEditObj edit = (ICFBamServerObjFuncEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerForTable(container);
                    ICFBamJavaFXServerObjFuncPaneCommon jpanelCommon = (ICFBamJavaFXServerObjFuncPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddServerObjFunc);
        }
        buttonAddServerProc = new CFButton();
        buttonAddServerProc.setMinWidth(200);
        buttonAddServerProc.setText("Add ServerProc");
        buttonAddServerProc.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamServerProcObj obj = (ICFBamServerProcObj) schemaObj.getServerProcTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getServerProcFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamServerProcEditObj edit = (ICFBamServerProcEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerForTable(container);
                    ICFBamJavaFXServerProcPaneCommon jpanelCommon = (ICFBamJavaFXServerProcPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddServerProc);
        }
        buttonAddServerListFunc = new CFButton();
        buttonAddServerListFunc.setMinWidth(200);
        buttonAddServerListFunc.setText("Add ServerListFunc");
        buttonAddServerListFunc.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamServerListFuncObj obj = (ICFBamServerListFuncObj) schemaObj
                            .getServerListFuncTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getServerListFuncFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamServerListFuncEditObj edit = (ICFBamServerListFuncEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerForTable(container);
                    ICFBamJavaFXServerListFuncPaneCommon jpanelCommon = (ICFBamJavaFXServerListFuncPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddServerListFunc);
        }

        int len = list.size();
        CFButton arr[] = new CFButton[len];
        Iterator<CFButton> iter = list.iterator();
        int idx = 0;
        while (iter.hasNext()) {
            arr[idx++] = iter.next();
        }
        Arrays.sort(arr, new CompareCFButtonByText());
        for (idx = 0; idx < len; idx++) {
            vboxMenuAdd.getChildren().add(arr[idx]);
        }

        buttonCancelAdd = new CFButton();
        buttonCancelAdd.setMinWidth(200);
        buttonCancelAdd.setText("Cancel Add...");
        buttonCancelAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        vboxMenuAdd.getChildren().add(buttonCancelAdd);

        scrollMenuAdd = new ScrollPane();
        scrollMenuAdd.setMinWidth(240);
        scrollMenuAdd.setMaxWidth(240);
        scrollMenuAdd.setFitToWidth(true);
        scrollMenuAdd.setHbarPolicy(ScrollBarPolicy.NEVER);
        scrollMenuAdd.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
        scrollMenuAdd.setContent(vboxMenuAdd);

        buttonAdd = new CFButton();
        buttonAdd.setMinWidth(200);
        buttonAdd.setText("Add...");
        buttonAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(scrollMenuAdd);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAdd);

        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamServerMethodObj selectedInstance = getJavaFXFocusAsServerMethod();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SRVM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getServerMethodFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerMethodPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVO".equals(classCode)) {
                            ICFBamServerObjFuncObj obj = (ICFBamServerObjFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerObjFuncFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerObjFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVP".equals(classCode)) {
                            ICFBamServerProcObj obj = (ICFBamServerProcObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerProcFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerProcPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVL".equals(classCode)) {
                            ICFBamServerListFuncObj obj = (ICFBamServerListFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerListFuncFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerListFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamServerMethodObj, ICFBamServerObjFuncObj, ICFBamServerProcObj, ICFBamServerListFuncObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamServerMethodObj selectedInstance = getJavaFXFocusAsServerMethod();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SRVM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getServerMethodFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerMethodPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVO".equals(classCode)) {
                            ICFBamServerObjFuncObj obj = (ICFBamServerObjFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerObjFuncFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerObjFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVP".equals(classCode)) {
                            ICFBamServerProcObj obj = (ICFBamServerProcObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerProcFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerProcPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVL".equals(classCode)) {
                            ICFBamServerListFuncObj obj = (ICFBamServerListFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerListFuncFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXServerListFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamServerMethodObj, ICFBamServerObjFuncObj, ICFBamServerProcObj, ICFBamServerListFuncObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamServerMethodObj selectedInstance = getJavaFXFocusAsServerMethod();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SRVM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getServerMethodFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXServerMethodPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVO".equals(classCode)) {
                            ICFBamServerObjFuncObj obj = (ICFBamServerObjFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerObjFuncFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXServerObjFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVP".equals(classCode)) {
                            ICFBamServerProcObj obj = (ICFBamServerProcObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerProcFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXServerProcPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("SRVL".equals(classCode)) {
                            ICFBamServerListFuncObj obj = (ICFBamServerListFuncObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getServerListFuncFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXServerListFuncPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamServerMethodObj, ICFBamServerObjFuncObj, ICFBamServerProcObj, ICFBamServerListFuncObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXInt32DefListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        LinkedList<CFButton> list = new LinkedList<CFButton>();

        vboxMenuAdd = new CFVBox(10);
        buttonAddInt32Type = new CFButton();
        buttonAddInt32Type.setMinWidth(200);
        buttonAddInt32Type.setText("Add Int32Type");
        buttonAddInt32Type.setOnAction(new EventHandler<ActionEvent>() {
            @Override//from www. ja  v  a 2  s  .  c  o m
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt32TypeObj obj = (ICFBamInt32TypeObj) schemaObj.getInt32TypeTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getInt32TypeFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt32TypeEditObj edit = (ICFBamInt32TypeEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXInt32TypePaneCommon jpanelCommon = (ICFBamJavaFXInt32TypePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddInt32Type);
        }
        buttonAddId32Gen = new CFButton();
        buttonAddId32Gen.setMinWidth(200);
        buttonAddId32Gen.setText("Add Id32Gen");
        buttonAddId32Gen.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamId32GenObj obj = (ICFBamId32GenObj) schemaObj.getId32GenTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getId32GenFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamId32GenEditObj edit = (ICFBamId32GenEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXId32GenPaneCommon jpanelCommon = (ICFBamJavaFXId32GenPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddId32Gen);
        }
        buttonAddInt32Col = new CFButton();
        buttonAddInt32Col.setMinWidth(200);
        buttonAddInt32Col.setText("Add Int32Col");
        buttonAddInt32Col.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt32ColObj obj = (ICFBamInt32ColObj) schemaObj.getInt32ColTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getInt32ColFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt32ColEditObj edit = (ICFBamInt32ColEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerTable(container);
                    ICFBamJavaFXInt32ColPaneCommon jpanelCommon = (ICFBamJavaFXInt32ColPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddInt32Col);
        }

        int len = list.size();
        CFButton arr[] = new CFButton[len];
        Iterator<CFButton> iter = list.iterator();
        int idx = 0;
        while (iter.hasNext()) {
            arr[idx++] = iter.next();
        }
        Arrays.sort(arr, new CompareCFButtonByText());
        for (idx = 0; idx < len; idx++) {
            vboxMenuAdd.getChildren().add(arr[idx]);
        }

        buttonCancelAdd = new CFButton();
        buttonCancelAdd.setMinWidth(200);
        buttonCancelAdd.setText("Cancel Add...");
        buttonCancelAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        vboxMenuAdd.getChildren().add(buttonCancelAdd);

        scrollMenuAdd = new ScrollPane();
        scrollMenuAdd.setMinWidth(240);
        scrollMenuAdd.setMaxWidth(240);
        scrollMenuAdd.setFitToWidth(true);
        scrollMenuAdd.setHbarPolicy(ScrollBarPolicy.NEVER);
        scrollMenuAdd.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
        scrollMenuAdd.setContent(vboxMenuAdd);

        buttonAdd = new CFButton();
        buttonAdd.setMinWidth(200);
        buttonAdd.setText("Add...");
        buttonAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(scrollMenuAdd);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAdd);

        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt32DefObj selectedInstance = getJavaFXFocusAsInt32Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I32D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt32DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I32T".equals(classCode)) {
                            ICFBamInt32TypeObj obj = (ICFBamInt32TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG32".equals(classCode)) {
                            ICFBamId32GenObj obj = (ICFBamId32GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId32GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId32GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I32C".equals(classCode)) {
                            ICFBamInt32ColObj obj = (ICFBamInt32ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt32DefObj, ICFBamInt32TypeObj, ICFBamId32GenObj, ICFBamInt32ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt32DefObj selectedInstance = getJavaFXFocusAsInt32Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I32D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt32DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("I32T".equals(classCode)) {
                            ICFBamInt32TypeObj obj = (ICFBamInt32TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("IG32".equals(classCode)) {
                            ICFBamId32GenObj obj = (ICFBamId32GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId32GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId32GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I32C".equals(classCode)) {
                            ICFBamInt32ColObj obj = (ICFBamInt32ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt32ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt32DefObj, ICFBamInt32TypeObj, ICFBamId32GenObj, ICFBamInt32ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt32DefObj selectedInstance = getJavaFXFocusAsInt32Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I32D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt32DefFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXInt32DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I32T".equals(classCode)) {
                            ICFBamInt32TypeObj obj = (ICFBamInt32TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32TypeFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt32TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG32".equals(classCode)) {
                            ICFBamId32GenObj obj = (ICFBamId32GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId32GenFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXId32GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I32C".equals(classCode)) {
                            ICFBamInt32ColObj obj = (ICFBamInt32ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt32ColFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt32ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt32DefObj, ICFBamInt32TypeObj, ICFBamId32GenObj, ICFBamInt32ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXInt64DefListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        LinkedList<CFButton> list = new LinkedList<CFButton>();

        vboxMenuAdd = new CFVBox(10);
        buttonAddInt64Type = new CFButton();
        buttonAddInt64Type.setMinWidth(200);
        buttonAddInt64Type.setText("Add Int64Type");
        buttonAddInt64Type.setOnAction(new EventHandler<ActionEvent>() {
            @Override// w w w. j  a va  2 s  .  co  m
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt64TypeObj obj = (ICFBamInt64TypeObj) schemaObj.getInt64TypeTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getInt64TypeFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt64TypeEditObj edit = (ICFBamInt64TypeEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXInt64TypePaneCommon jpanelCommon = (ICFBamJavaFXInt64TypePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddInt64Type);
        }
        buttonAddId64Gen = new CFButton();
        buttonAddId64Gen.setMinWidth(200);
        buttonAddId64Gen.setText("Add Id64Gen");
        buttonAddId64Gen.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamId64GenObj obj = (ICFBamId64GenObj) schemaObj.getId64GenTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getId64GenFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamId64GenEditObj edit = (ICFBamId64GenEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXId64GenPaneCommon jpanelCommon = (ICFBamJavaFXId64GenPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddId64Gen);
        }
        buttonAddInt64Col = new CFButton();
        buttonAddInt64Col.setMinWidth(200);
        buttonAddInt64Col.setText("Add Int64Col");
        buttonAddInt64Col.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt64ColObj obj = (ICFBamInt64ColObj) schemaObj.getInt64ColTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getInt64ColFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt64ColEditObj edit = (ICFBamInt64ColEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerTable(container);
                    ICFBamJavaFXInt64ColPaneCommon jpanelCommon = (ICFBamJavaFXInt64ColPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddInt64Col);
        }

        int len = list.size();
        CFButton arr[] = new CFButton[len];
        Iterator<CFButton> iter = list.iterator();
        int idx = 0;
        while (iter.hasNext()) {
            arr[idx++] = iter.next();
        }
        Arrays.sort(arr, new CompareCFButtonByText());
        for (idx = 0; idx < len; idx++) {
            vboxMenuAdd.getChildren().add(arr[idx]);
        }

        buttonCancelAdd = new CFButton();
        buttonCancelAdd.setMinWidth(200);
        buttonCancelAdd.setText("Cancel Add...");
        buttonCancelAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        vboxMenuAdd.getChildren().add(buttonCancelAdd);

        scrollMenuAdd = new ScrollPane();
        scrollMenuAdd.setMinWidth(240);
        scrollMenuAdd.setMaxWidth(240);
        scrollMenuAdd.setFitToWidth(true);
        scrollMenuAdd.setHbarPolicy(ScrollBarPolicy.NEVER);
        scrollMenuAdd.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
        scrollMenuAdd.setContent(vboxMenuAdd);

        buttonAdd = new CFButton();
        buttonAdd.setMinWidth(200);
        buttonAdd.setText("Add...");
        buttonAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(scrollMenuAdd);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAdd);

        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt64DefObj selectedInstance = getJavaFXFocusAsInt64Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I64D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt64DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I64T".equals(classCode)) {
                            ICFBamInt64TypeObj obj = (ICFBamInt64TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG64".equals(classCode)) {
                            ICFBamId64GenObj obj = (ICFBamId64GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId64GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId64GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I64C".equals(classCode)) {
                            ICFBamInt64ColObj obj = (ICFBamInt64ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt64DefObj, ICFBamInt64TypeObj, ICFBamId64GenObj, ICFBamInt64ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt64DefObj selectedInstance = getJavaFXFocusAsInt64Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I64D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt64DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("I64T".equals(classCode)) {
                            ICFBamInt64TypeObj obj = (ICFBamInt64TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("IG64".equals(classCode)) {
                            ICFBamId64GenObj obj = (ICFBamId64GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId64GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId64GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I64C".equals(classCode)) {
                            ICFBamInt64ColObj obj = (ICFBamInt64ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt64ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt64DefObj, ICFBamInt64TypeObj, ICFBamId64GenObj, ICFBamInt64ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt64DefObj selectedInstance = getJavaFXFocusAsInt64Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I64D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt64DefFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXInt64DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I64T".equals(classCode)) {
                            ICFBamInt64TypeObj obj = (ICFBamInt64TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64TypeFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt64TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG64".equals(classCode)) {
                            ICFBamId64GenObj obj = (ICFBamId64GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId64GenFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXId64GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I64C".equals(classCode)) {
                            ICFBamInt64ColObj obj = (ICFBamInt64ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt64ColFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt64ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt64DefObj, ICFBamInt64TypeObj, ICFBamId64GenObj, ICFBamInt64ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXInt16DefListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        LinkedList<CFButton> list = new LinkedList<CFButton>();

        vboxMenuAdd = new CFVBox(10);
        buttonAddInt16Type = new CFButton();
        buttonAddInt16Type.setMinWidth(200);
        buttonAddInt16Type.setText("Add Int16Type");
        buttonAddInt16Type.setOnAction(new EventHandler<ActionEvent>() {
            @Override// w ww  . j a  v a2  s  .co m
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt16TypeObj obj = (ICFBamInt16TypeObj) schemaObj.getInt16TypeTableObj()
                            .newInstance();
                    CFBorderPane frame = javafxSchema.getInt16TypeFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt16TypeEditObj edit = (ICFBamInt16TypeEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXInt16TypePaneCommon jpanelCommon = (ICFBamJavaFXInt16TypePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddInt16Type);
        }
        buttonAddId16Gen = new CFButton();
        buttonAddId16Gen.setMinWidth(200);
        buttonAddId16Gen.setText("Add Id16Gen");
        buttonAddId16Gen.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamId16GenObj obj = (ICFBamId16GenObj) schemaObj.getId16GenTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getId16GenFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamId16GenEditObj edit = (ICFBamId16GenEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXId16GenPaneCommon jpanelCommon = (ICFBamJavaFXId16GenPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddId16Gen);
        }
        buttonAddEnumType = new CFButton();
        buttonAddEnumType.setMinWidth(200);
        buttonAddEnumType.setText("Add EnumType");
        buttonAddEnumType.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamEnumTypeObj obj = (ICFBamEnumTypeObj) schemaObj.getEnumTypeTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getEnumTypeFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamEnumTypeEditObj edit = (ICFBamEnumTypeEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    ICFBamJavaFXEnumTypePaneCommon jpanelCommon = (ICFBamJavaFXEnumTypePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamSchemaDefObj) {
            list.add(buttonAddEnumType);
        }
        buttonAddInt16Col = new CFButton();
        buttonAddInt16Col.setMinWidth(200);
        buttonAddInt16Col.setText("Add Int16Col");
        buttonAddInt16Col.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamInt16ColObj obj = (ICFBamInt16ColObj) schemaObj.getInt16ColTableObj().newInstance();
                    CFBorderPane frame = javafxSchema.getInt16ColFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamInt16ColEditObj edit = (ICFBamInt16ColEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamTableObj container = (ICFBamTableObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerTable(container);
                    ICFBamJavaFXInt16ColPaneCommon jpanelCommon = (ICFBamJavaFXInt16ColPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        if (javafxContainer instanceof ICFBamTableObj) {
            list.add(buttonAddInt16Col);
        }

        int len = list.size();
        CFButton arr[] = new CFButton[len];
        Iterator<CFButton> iter = list.iterator();
        int idx = 0;
        while (iter.hasNext()) {
            arr[idx++] = iter.next();
        }
        Arrays.sort(arr, new CompareCFButtonByText());
        for (idx = 0; idx < len; idx++) {
            vboxMenuAdd.getChildren().add(arr[idx]);
        }

        buttonCancelAdd = new CFButton();
        buttonCancelAdd.setMinWidth(200);
        buttonCancelAdd.setText("Cancel Add...");
        buttonCancelAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(null);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        vboxMenuAdd.getChildren().add(buttonCancelAdd);

        scrollMenuAdd = new ScrollPane();
        scrollMenuAdd.setMinWidth(240);
        scrollMenuAdd.setMaxWidth(240);
        scrollMenuAdd.setFitToWidth(true);
        scrollMenuAdd.setHbarPolicy(ScrollBarPolicy.NEVER);
        scrollMenuAdd.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
        scrollMenuAdd.setContent(vboxMenuAdd);

        buttonAdd = new CFButton();
        buttonAdd.setMinWidth(200);
        buttonAdd.setText("Add...");
        buttonAdd.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    setLeft(scrollMenuAdd);
                    adjustListButtons();
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAdd);

        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt16DefObj selectedInstance = getJavaFXFocusAsInt16Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I16D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt16DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I16T".equals(classCode)) {
                            ICFBamInt16TypeObj obj = (ICFBamInt16TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG16".equals(classCode)) {
                            ICFBamId16GenObj obj = (ICFBamId16GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId16GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId16GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMD".equals(classCode)) {
                            ICFBamEnumDefObj obj = (ICFBamEnumDefObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumDefFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXEnumDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMT".equals(classCode)) {
                            ICFBamEnumTypeObj obj = (ICFBamEnumTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumTypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXEnumTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I16C".equals(classCode)) {
                            ICFBamInt16ColObj obj = (ICFBamInt16ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt16DefObj, ICFBamInt16TypeObj, ICFBamId16GenObj, ICFBamEnumDefObj, ICFBamEnumTypeObj, ICFBamInt16ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt16DefObj selectedInstance = getJavaFXFocusAsInt16Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I16D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt16DefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("I16T".equals(classCode)) {
                            ICFBamInt16TypeObj obj = (ICFBamInt16TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16TypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("IG16".equals(classCode)) {
                            ICFBamId16GenObj obj = (ICFBamId16GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId16GenFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXId16GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMD".equals(classCode)) {
                            ICFBamEnumDefObj obj = (ICFBamEnumDefObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumDefFactory().newViewEditForm(cfFormManager,
                                    obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXEnumDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMT".equals(classCode)) {
                            ICFBamEnumTypeObj obj = (ICFBamEnumTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumTypeFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXEnumTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I16C".equals(classCode)) {
                            ICFBamInt16ColObj obj = (ICFBamInt16ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16ColFactory()
                                    .newViewEditForm(cfFormManager, obj, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXInt16ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt16DefObj, ICFBamInt16TypeObj, ICFBamId16GenObj, ICFBamEnumDefObj, ICFBamEnumTypeObj, ICFBamInt16ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamInt16DefObj selectedInstance = getJavaFXFocusAsInt16Def();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("I16D".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getInt16DefFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXInt16DefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I16T".equals(classCode)) {
                            ICFBamInt16TypeObj obj = (ICFBamInt16TypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16TypeFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt16TypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("IG16".equals(classCode)) {
                            ICFBamId16GenObj obj = (ICFBamId16GenObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getId16GenFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXId16GenPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMD".equals(classCode)) {
                            ICFBamEnumDefObj obj = (ICFBamEnumDefObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumDefFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXEnumDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("ENMT".equals(classCode)) {
                            ICFBamEnumTypeObj obj = (ICFBamEnumTypeObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getEnumTypeFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXEnumTypePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else if ("I16C".equals(classCode)) {
                            ICFBamInt16ColObj obj = (ICFBamInt16ColObj) selectedInstance;
                            CFBorderPane frame = javafxSchema.getInt16ColFactory()
                                    .newAskDeleteForm(cfFormManager, obj, getDeleteCallback());
                            ((ICFBamJavaFXInt16ColPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance,
                                    "ICFBamInt16DefObj, ICFBamInt16TypeObj, ICFBamId16GenObj, ICFBamEnumDefObj, ICFBamEnumTypeObj, ICFBamInt16ColObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXSchemaDefListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        buttonAddSchemaDef = new CFButton();
        buttonAddSchemaDef.setMinWidth(200);
        buttonAddSchemaDef.setText("Add SchemaDef");
        buttonAddSchemaDef.setOnAction(new EventHandler<ActionEvent>() {
            @Override//from  w  ww.j ava2 s  .c om
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamSchemaDefObj obj = (ICFBamSchemaDefObj) schemaObj.getSchemaDefTableObj()
                            .newInstance();
                    ICFBamSchemaDefEditObj edit = (ICFBamSchemaDefEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerCTenant(secTenant);
                    ICFBamDomainBaseObj container = (ICFBamDomainBaseObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerDomain(container);
                    CFBorderPane frame = javafxSchema.getSchemaDefFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamJavaFXSchemaDefPaneCommon jpanelCommon = (ICFBamJavaFXSchemaDefPaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAddSchemaDef);
        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamSchemaDefObj selectedInstance = getJavaFXFocusAsSchemaDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SCHM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getSchemaDefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXSchemaDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamSchemaDefObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamSchemaDefObj selectedInstance = getJavaFXFocusAsSchemaDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SCHM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getSchemaDefFactory().newViewEditForm(
                                    cfFormManager, selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXSchemaDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamSchemaDefObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamSchemaDefObj selectedInstance = getJavaFXFocusAsSchemaDef();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("SCHM".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getSchemaDefFactory()
                                    .newAskDeleteForm(cfFormManager, selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXSchemaDefPaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamSchemaDefObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXTablePickerPane.java

public CFBamJavaFXTablePickerPane(ICFFormManager formManager, ICFBamJavaFXSchema argSchema,
        ICFBamTableObj argFocus, ICFBamSchemaDefObj argContainer, Collection<ICFBamTableObj> argDataCollection,
        ICFBamJavaFXTableChosen whenChosen) {
    super();// w w  w . j a va 2 s  .  c  om
    final String S_ProcName = "construct-schema-focus";
    if (formManager == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 1,
                "formManager");
    }
    cfFormManager = formManager;
    if (argSchema == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 2,
                "argSchema");
    }
    if (whenChosen == null) {
        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 6,
                "whenChosen");
    }
    invokeWhenChosen = whenChosen;
    // argFocus is optional; focus may be set later during execution as
    // conditions of the runtime change.
    javafxSchema = argSchema;
    javaFXFocus = argFocus;
    javafxContainer = argContainer;
    setJavaFXDataCollection(argDataCollection);
    dataTable = new TableView<ICFBamTableObj>();
    tableColumnId = new TableColumn<ICFBamTableObj, Long>("Id");
    tableColumnId
            .setCellValueFactory(new Callback<CellDataFeatures<ICFBamTableObj, Long>, ObservableValue<Long>>() {
                public ObservableValue<Long> call(CellDataFeatures<ICFBamTableObj, Long> p) {
                    ICFBamScopeObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        long value = obj.getRequiredId();
                        Long wrapped = new Long(value);
                        ReadOnlyObjectWrapper<Long> observable = new ReadOnlyObjectWrapper<Long>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnId
            .setCellFactory(new Callback<TableColumn<ICFBamTableObj, Long>, TableCell<ICFBamTableObj, Long>>() {
                @Override
                public TableCell<ICFBamTableObj, Long> call(TableColumn<ICFBamTableObj, Long> arg) {
                    return new CFInt64TableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnId);
    tableColumnName = new TableColumn<ICFBamTableObj, String>("Name");
    tableColumnName.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getRequiredName();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnName.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnName);
    tableColumnDbName = new TableColumn<ICFBamTableObj, String>("Db Name");
    tableColumnDbName.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalDbName();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnDbName.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnDbName);
    tableColumnShortName = new TableColumn<ICFBamTableObj, String>("Short Name");
    tableColumnShortName.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalShortName();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnShortName.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnShortName);
    tableColumnLabel = new TableColumn<ICFBamTableObj, String>("Label");
    tableColumnLabel.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalLabel();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnLabel.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLabel);
    tableColumnShortDescription = new TableColumn<ICFBamTableObj, String>("Short Description");
    tableColumnShortDescription.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalShortDescription();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnShortDescription.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnShortDescription);
    tableColumnDescription = new TableColumn<ICFBamTableObj, String>("Description");
    tableColumnDescription.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalDescription();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnDescription.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnDescription);
    tableColumnPageData = new TableColumn<ICFBamTableObj, Boolean>("PageData");
    tableColumnPageData.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredPageData();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnPageData.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnPageData);
    tableColumnTableClassCode = new TableColumn<ICFBamTableObj, String>("Table Class Code");
    tableColumnTableClassCode.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getRequiredTableClassCode();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnTableClassCode.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFStringTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnTableClassCode);
    tableColumnPolyBase = new TableColumn<ICFBamTableObj, Boolean>("Polymorphic Base");
    tableColumnPolyBase.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredPolyBase();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnPolyBase.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnPolyBase);
    tableColumnIsInstantiable = new TableColumn<ICFBamTableObj, Boolean>("Is Instantiable");
    tableColumnIsInstantiable.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredIsInstantiable();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnIsInstantiable.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnIsInstantiable);
    tableColumnHasHistory = new TableColumn<ICFBamTableObj, Boolean>("Has History");
    tableColumnHasHistory.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredHasHistory();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnHasHistory.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnHasHistory);
    tableColumnHasAuditColumns = new TableColumn<ICFBamTableObj, Boolean>("Has Audit Columns");
    tableColumnHasAuditColumns.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredHasAuditColumns();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnHasAuditColumns.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnHasAuditColumns);
    tableColumnLoaderBehaviour = new TableColumn<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum>(
            "Loader Behaviour");
    tableColumnLoaderBehaviour.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum>, ObservableValue<ICFBamSchema.LoaderBehaviourEnum>>() {
                public ObservableValue<ICFBamSchema.LoaderBehaviourEnum> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamSchema.LoaderBehaviourEnum value = obj.getRequiredLoaderBehaviour();
                        ReadOnlyObjectWrapper<ICFBamSchema.LoaderBehaviourEnum> observable = new ReadOnlyObjectWrapper<ICFBamSchema.LoaderBehaviourEnum>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnLoaderBehaviour.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum>, TableCell<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum> call(
                        TableColumn<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum> arg) {
                    return new CFEnumTableCell<ICFBamTableObj, ICFBamSchema.LoaderBehaviourEnum>();
                }
            });
    dataTable.getColumns().add(tableColumnLoaderBehaviour);
    tableColumnSecurityScope = new TableColumn<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum>(
            "Security Scope");
    tableColumnSecurityScope.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum>, ObservableValue<ICFBamSchema.SecurityScopeEnum>>() {
                public ObservableValue<ICFBamSchema.SecurityScopeEnum> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamSchema.SecurityScopeEnum value = obj.getRequiredSecurityScope();
                        ReadOnlyObjectWrapper<ICFBamSchema.SecurityScopeEnum> observable = new ReadOnlyObjectWrapper<ICFBamSchema.SecurityScopeEnum>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnSecurityScope.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum>, TableCell<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum> call(
                        TableColumn<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum> arg) {
                    return new CFEnumTableCell<ICFBamTableObj, ICFBamSchema.SecurityScopeEnum>();
                }
            });
    dataTable.getColumns().add(tableColumnSecurityScope);
    tableColumnJObjMembers = new TableColumn<ICFBamTableObj, String>("JObjMembers");
    tableColumnJObjMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJObjMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJObjMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJObjMembers);
    tableColumnJObjInterface = new TableColumn<ICFBamTableObj, String>("JObjInterface");
    tableColumnJObjInterface.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJObjInterface();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJObjInterface.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJObjInterface);
    tableColumnJObjImport = new TableColumn<ICFBamTableObj, String>("JObjImport");
    tableColumnJObjImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJObjImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJObjImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJObjImport);
    tableColumnJObjImplementation = new TableColumn<ICFBamTableObj, String>("JObjImplementation");
    tableColumnJObjImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJObjImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJObjImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJObjImplementation);
    tableColumnJEditObjMembers = new TableColumn<ICFBamTableObj, String>("JEditObjMembers");
    tableColumnJEditObjMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJEditObjMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJEditObjMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJEditObjMembers);
    tableColumnJEditObjInterface = new TableColumn<ICFBamTableObj, String>("JEditObjInterface");
    tableColumnJEditObjInterface.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJEditObjInterface();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJEditObjInterface.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJEditObjInterface);
    tableColumnJEditObjImport = new TableColumn<ICFBamTableObj, String>("JEditObjImport");
    tableColumnJEditObjImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJEditObjImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJEditObjImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJEditObjImport);
    tableColumnJEditObjImplementation = new TableColumn<ICFBamTableObj, String>("JEditObjImplementation");
    tableColumnJEditObjImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJEditObjImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJEditObjImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJEditObjImplementation);
    tableColumnJTableImport = new TableColumn<ICFBamTableObj, String>("JTableImport");
    tableColumnJTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableImport);
    tableColumnJTableMembers = new TableColumn<ICFBamTableObj, String>("JTableMembers");
    tableColumnJTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableMembers);
    tableColumnJTableInterface = new TableColumn<ICFBamTableObj, String>("JTableInterface");
    tableColumnJTableInterface.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableInterface();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableInterface.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableInterface);
    tableColumnJTableImplementation = new TableColumn<ICFBamTableObj, String>("JTableImplementation");
    tableColumnJTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableImplementation);
    tableColumnJTableObjImport = new TableColumn<ICFBamTableObj, String>("JTableObjImport");
    tableColumnJTableObjImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableObjImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableObjImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableObjImport);
    tableColumnJTableObjMembers = new TableColumn<ICFBamTableObj, String>("JTableObjMembers");
    tableColumnJTableObjMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableObjMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableObjMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableObjMembers);
    tableColumnJTableObjInterface = new TableColumn<ICFBamTableObj, String>("JTableObjInterface");
    tableColumnJTableObjInterface.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableObjInterface();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableObjInterface.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableObjInterface);
    tableColumnJTableObjImplementation = new TableColumn<ICFBamTableObj, String>("JTableObjImplementation");
    tableColumnJTableObjImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJTableObjImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJTableObjImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJTableObjImplementation);
    tableColumnJDb2LUWTableImport = new TableColumn<ICFBamTableObj, String>("JDb2LUWTableImport");
    tableColumnJDb2LUWTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJDb2LUWTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJDb2LUWTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJDb2LUWTableImport);
    tableColumnJDb2LUWTableMembers = new TableColumn<ICFBamTableObj, String>("JDb2LUWTableMembers");
    tableColumnJDb2LUWTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJDb2LUWTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJDb2LUWTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJDb2LUWTableMembers);
    tableColumnJDb2LUWTableImplementation = new TableColumn<ICFBamTableObj, String>(
            "JDb2LUWTableImplementation");
    tableColumnJDb2LUWTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJDb2LUWTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJDb2LUWTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJDb2LUWTableImplementation);
    tableColumnJMSSqlTableImport = new TableColumn<ICFBamTableObj, String>("JMSSqlTableImport");
    tableColumnJMSSqlTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMSSqlTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMSSqlTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMSSqlTableImport);
    tableColumnJMSSqlTableMembers = new TableColumn<ICFBamTableObj, String>("JMSSqlTableMembers");
    tableColumnJMSSqlTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMSSqlTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMSSqlTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMSSqlTableMembers);
    tableColumnJMSSqlTableImplementation = new TableColumn<ICFBamTableObj, String>("JMSSqlTableImplementation");
    tableColumnJMSSqlTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMSSqlTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMSSqlTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMSSqlTableImplementation);
    tableColumnJMySqlTableImport = new TableColumn<ICFBamTableObj, String>("JMySqlTableImport");
    tableColumnJMySqlTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMySqlTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMySqlTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMySqlTableImport);
    tableColumnJMySqlTableMembers = new TableColumn<ICFBamTableObj, String>("JMySqlTableMembers");
    tableColumnJMySqlTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMySqlTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMySqlTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMySqlTableMembers);
    tableColumnJMySqlTableImplementation = new TableColumn<ICFBamTableObj, String>("JMySqlTableImplementation");
    tableColumnJMySqlTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJMySqlTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJMySqlTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJMySqlTableImplementation);
    tableColumnJOracleTableImport = new TableColumn<ICFBamTableObj, String>("JOracleTableImport");
    tableColumnJOracleTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJOracleTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJOracleTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJOracleTableImport);
    tableColumnJOracleTableMembers = new TableColumn<ICFBamTableObj, String>("JOracleTableMembers");
    tableColumnJOracleTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJOracleTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJOracleTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJOracleTableMembers);
    tableColumnJOracleTableImplementation = new TableColumn<ICFBamTableObj, String>(
            "JOracleTableImplementation");
    tableColumnJOracleTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJOracleTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJOracleTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJOracleTableImplementation);
    tableColumnJPgSqlTableImport = new TableColumn<ICFBamTableObj, String>("JPgSqlTableImport");
    tableColumnJPgSqlTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJPgSqlTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJPgSqlTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJPgSqlTableImport);
    tableColumnJPgSqlTableMembers = new TableColumn<ICFBamTableObj, String>("JPgSqlTableMembers");
    tableColumnJPgSqlTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJPgSqlTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJPgSqlTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJPgSqlTableMembers);
    tableColumnJPgSqlTableImplementation = new TableColumn<ICFBamTableObj, String>("JPgSqlTableImplementation");
    tableColumnJPgSqlTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJPgSqlTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJPgSqlTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJPgSqlTableImplementation);
    tableColumnJSybaseTableImport = new TableColumn<ICFBamTableObj, String>("JSybaseTableImport");
    tableColumnJSybaseTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSybaseTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSybaseTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSybaseTableImport);
    tableColumnJSybaseTableMembers = new TableColumn<ICFBamTableObj, String>("JSybaseTableMembers");
    tableColumnJSybaseTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSybaseTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSybaseTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSybaseTableMembers);
    tableColumnJSybaseTableImplementation = new TableColumn<ICFBamTableObj, String>(
            "JSybaseTableImplementation");
    tableColumnJSybaseTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSybaseTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSybaseTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSybaseTableImplementation);
    tableColumnJRamTableImport = new TableColumn<ICFBamTableObj, String>("JRamTableImport");
    tableColumnJRamTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJRamTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJRamTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJRamTableImport);
    tableColumnJRamTableMembers = new TableColumn<ICFBamTableObj, String>("JRamTableMembers");
    tableColumnJRamTableMembers.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJRamTableMembers();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJRamTableMembers.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJRamTableMembers);
    tableColumnJRamTableImplementation = new TableColumn<ICFBamTableObj, String>("JRamTableImplementation");
    tableColumnJRamTableImplementation.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJRamTableImplementation();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJRamTableImplementation.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJRamTableImplementation);
    tableColumnJSaxLoaderImport = new TableColumn<ICFBamTableObj, String>("JSaxLoaderImport");
    tableColumnJSaxLoaderImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSaxLoaderImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSaxLoaderImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSaxLoaderImport);
    tableColumnJSaxLoaderStartElement = new TableColumn<ICFBamTableObj, String>("JSaxLoaderStartElement");
    tableColumnJSaxLoaderStartElement.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSaxLoaderStartElement();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSaxLoaderStartElement.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSaxLoaderStartElement);
    tableColumnJSaxLoaderEndElement = new TableColumn<ICFBamTableObj, String>("JSaxLoaderEndElement");
    tableColumnJSaxLoaderEndElement.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJSaxLoaderEndElement();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJSaxLoaderEndElement.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJSaxLoaderEndElement);
    tableColumnJXMsgTableImport = new TableColumn<ICFBamTableObj, String>("JXMsgTableImport");
    tableColumnJXMsgTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgTableImport);
    tableColumnJXMsgTableFormatters = new TableColumn<ICFBamTableObj, String>("JXMsgTableFormatters");
    tableColumnJXMsgTableFormatters.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgTableFormatters();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgTableFormatters.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgTableFormatters);
    tableColumnJXMsgRqstTableImport = new TableColumn<ICFBamTableObj, String>("JXMsgRqstTableImport");
    tableColumnJXMsgRqstTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgRqstTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgRqstTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgRqstTableImport);
    tableColumnJXMsgRspnTableImport = new TableColumn<ICFBamTableObj, String>("JXMsgRspnTableImport");
    tableColumnJXMsgRspnTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgRspnTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgRspnTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgRspnTableImport);
    tableColumnJXMsgClientTableImport = new TableColumn<ICFBamTableObj, String>("JXMsgClientTableImport");
    tableColumnJXMsgClientTableImport.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgClientTableImport();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgClientTableImport.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgClientTableImport);
    tableColumnJXMsgRqstTableBody = new TableColumn<ICFBamTableObj, String>("JXMsgRqstTableBody");
    tableColumnJXMsgRqstTableBody.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgRqstTableBody();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgRqstTableBody.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgRqstTableBody);
    tableColumnJXMsgRspnTableBody = new TableColumn<ICFBamTableObj, String>("JXMsgRspnTableBody");
    tableColumnJXMsgRspnTableBody.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgRspnTableBody();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgRspnTableBody.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgRspnTableBody);
    tableColumnJXMsgClientTableBody = new TableColumn<ICFBamTableObj, String>("JXMsgClientTableBody");
    tableColumnJXMsgClientTableBody.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, String>, ObservableValue<String>>() {
                public ObservableValue<String> call(CellDataFeatures<ICFBamTableObj, String> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        String value = obj.getOptionalJXMsgClientTableBody();
                        ReadOnlyObjectWrapper<String> observable = new ReadOnlyObjectWrapper<String>();
                        observable.setValue(value);
                        return (observable);
                    }
                }
            });
    tableColumnJXMsgClientTableBody.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, String>, TableCell<ICFBamTableObj, String>>() {
                @Override
                public TableCell<ICFBamTableObj, String> call(TableColumn<ICFBamTableObj, String> arg) {
                    return new CFTextTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnJXMsgClientTableBody);
    tableColumnDefaultVisibility = new TableColumn<ICFBamTableObj, Boolean>("DefaultVisibility");
    tableColumnDefaultVisibility.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, Boolean>, ObservableValue<Boolean>>() {
                public ObservableValue<Boolean> call(CellDataFeatures<ICFBamTableObj, Boolean> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        boolean value = obj.getRequiredDefaultVisibility();
                        Boolean wrapped = new Boolean(value);
                        ReadOnlyObjectWrapper<Boolean> observable = new ReadOnlyObjectWrapper<Boolean>();
                        observable.setValue(wrapped);
                        return (observable);
                    }
                }
            });
    tableColumnDefaultVisibility.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, Boolean>, TableCell<ICFBamTableObj, Boolean>>() {
                @Override
                public TableCell<ICFBamTableObj, Boolean> call(TableColumn<ICFBamTableObj, Boolean> arg) {
                    return new CFBoolTableCell<ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnDefaultVisibility);
    tableColumnLookupDefSchema = new TableColumn<ICFBamTableObj, ICFBamSchemaDefObj>(
            "Defining Schema Definition");
    tableColumnLookupDefSchema.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamSchemaDefObj>, ObservableValue<ICFBamSchemaDefObj>>() {
                public ObservableValue<ICFBamSchemaDefObj> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamSchemaDefObj> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamSchemaDefObj ref = obj.getOptionalLookupDefSchema();
                        ReadOnlyObjectWrapper<ICFBamSchemaDefObj> observable = new ReadOnlyObjectWrapper<ICFBamSchemaDefObj>();
                        observable.setValue(ref);
                        return (observable);
                    }
                }
            });
    tableColumnLookupDefSchema.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamSchemaDefObj>, TableCell<ICFBamTableObj, ICFBamSchemaDefObj>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamSchemaDefObj> call(
                        TableColumn<ICFBamTableObj, ICFBamSchemaDefObj> arg) {
                    return new CFReferenceTableCell<ICFBamTableObj, ICFBamSchemaDefObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLookupDefSchema);
    tableColumnLookupLookupIndex = new TableColumn<ICFBamTableObj, ICFBamIndexObj>("Lookup Index");
    tableColumnLookupLookupIndex.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamIndexObj>, ObservableValue<ICFBamIndexObj>>() {
                public ObservableValue<ICFBamIndexObj> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamIndexObj> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamIndexObj ref = obj.getOptionalLookupLookupIndex();
                        ReadOnlyObjectWrapper<ICFBamIndexObj> observable = new ReadOnlyObjectWrapper<ICFBamIndexObj>();
                        observable.setValue(ref);
                        return (observable);
                    }
                }
            });
    tableColumnLookupLookupIndex.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamIndexObj>, TableCell<ICFBamTableObj, ICFBamIndexObj>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamIndexObj> call(
                        TableColumn<ICFBamTableObj, ICFBamIndexObj> arg) {
                    return new CFReferenceTableCell<ICFBamTableObj, ICFBamIndexObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLookupLookupIndex);
    tableColumnLookupAltIndex = new TableColumn<ICFBamTableObj, ICFBamIndexObj>("Alt Index");
    tableColumnLookupAltIndex.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamIndexObj>, ObservableValue<ICFBamIndexObj>>() {
                public ObservableValue<ICFBamIndexObj> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamIndexObj> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamIndexObj ref = obj.getOptionalLookupAltIndex();
                        ReadOnlyObjectWrapper<ICFBamIndexObj> observable = new ReadOnlyObjectWrapper<ICFBamIndexObj>();
                        observable.setValue(ref);
                        return (observable);
                    }
                }
            });
    tableColumnLookupAltIndex.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamIndexObj>, TableCell<ICFBamTableObj, ICFBamIndexObj>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamIndexObj> call(
                        TableColumn<ICFBamTableObj, ICFBamIndexObj> arg) {
                    return new CFReferenceTableCell<ICFBamTableObj, ICFBamIndexObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLookupAltIndex);
    tableColumnLookupQualTable = new TableColumn<ICFBamTableObj, ICFBamTableObj>("Qualifying Table");
    tableColumnLookupQualTable.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamTableObj>, ObservableValue<ICFBamTableObj>>() {
                public ObservableValue<ICFBamTableObj> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamTableObj> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamTableObj ref = obj.getOptionalLookupQualTable();
                        ReadOnlyObjectWrapper<ICFBamTableObj> observable = new ReadOnlyObjectWrapper<ICFBamTableObj>();
                        observable.setValue(ref);
                        return (observable);
                    }
                }
            });
    tableColumnLookupQualTable.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamTableObj>, TableCell<ICFBamTableObj, ICFBamTableObj>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamTableObj> call(
                        TableColumn<ICFBamTableObj, ICFBamTableObj> arg) {
                    return new CFReferenceTableCell<ICFBamTableObj, ICFBamTableObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLookupQualTable);
    tableColumnLookupPrimaryIndex = new TableColumn<ICFBamTableObj, ICFBamIndexObj>("Primary Index");
    tableColumnLookupPrimaryIndex.setCellValueFactory(
            new Callback<CellDataFeatures<ICFBamTableObj, ICFBamIndexObj>, ObservableValue<ICFBamIndexObj>>() {
                public ObservableValue<ICFBamIndexObj> call(
                        CellDataFeatures<ICFBamTableObj, ICFBamIndexObj> p) {
                    ICFBamTableObj obj = p.getValue();
                    if (obj == null) {
                        return (null);
                    } else {
                        ICFBamIndexObj ref = obj.getOptionalLookupPrimaryIndex();
                        ReadOnlyObjectWrapper<ICFBamIndexObj> observable = new ReadOnlyObjectWrapper<ICFBamIndexObj>();
                        observable.setValue(ref);
                        return (observable);
                    }
                }
            });
    tableColumnLookupPrimaryIndex.setCellFactory(
            new Callback<TableColumn<ICFBamTableObj, ICFBamIndexObj>, TableCell<ICFBamTableObj, ICFBamIndexObj>>() {
                @Override
                public TableCell<ICFBamTableObj, ICFBamIndexObj> call(
                        TableColumn<ICFBamTableObj, ICFBamIndexObj> arg) {
                    return new CFReferenceTableCell<ICFBamTableObj, ICFBamIndexObj>();
                }
            });
    dataTable.getColumns().add(tableColumnLookupPrimaryIndex);
    dataTable.getSelectionModel().selectedItemProperty().addListener(new ChangeListener<ICFBamTableObj>() {
        @Override
        public void changed(ObservableValue<? extends ICFBamTableObj> observable, ICFBamTableObj oldValue,
                ICFBamTableObj newValue) {
            setJavaFXFocus(newValue);
            if (buttonChooseSelected != null) {
                if (newValue != null) {
                    buttonChooseSelected.setDisable(false);
                } else {
                    buttonChooseSelected.setDisable(true);
                }
            }
        }
    });
    hboxMenu = new CFHBox(10);
    buttonCancel = new CFButton();
    buttonCancel.setMinWidth(200);
    buttonCancel.setText("Cancel");
    buttonCancel.setOnAction(new EventHandler<ActionEvent>() {
        @Override
        public void handle(ActionEvent e) {
            final String S_ProcName = "handle";
            try {
                cfFormManager.closeCurrentForm();
            } catch (Throwable t) {
                CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
            }
        }
    });
    hboxMenu.getChildren().add(buttonCancel);
    buttonChooseNone = new CFButton();
    buttonChooseNone.setMinWidth(200);
    buttonChooseNone.setText("ChooseNone");
    buttonChooseNone.setOnAction(new EventHandler<ActionEvent>() {
        @Override
        public void handle(ActionEvent e) {
            final String S_ProcName = "handle";
            try {
                ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                if (schemaObj == null) {
                    throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                            "schemaObj");
                }
                invokeWhenChosen.choseTable(null);
                cfFormManager.closeCurrentForm();
            } catch (Throwable t) {
                CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
            }
        }
    });
    hboxMenu.getChildren().add(buttonChooseNone);
    buttonChooseSelected = new CFButton();
    buttonChooseSelected.setMinWidth(200);
    buttonChooseSelected.setText("ChooseSelected");
    buttonChooseSelected.setOnAction(new EventHandler<ActionEvent>() {
        @Override
        public void handle(ActionEvent e) {
            final String S_ProcName = "handle";
            try {
                ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                if (schemaObj == null) {
                    throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(), S_ProcName, 0,
                            "schemaObj");
                }
                ICFBamTableObj selectedInstance = getJavaFXFocusAsTable();
                invokeWhenChosen.choseTable(selectedInstance);
                cfFormManager.closeCurrentForm();
            } catch (Throwable t) {
                CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
            }
        }
    });
    hboxMenu.getChildren().add(buttonChooseSelected);
    if (argFocus != null) {
        dataTable.getSelectionModel().select(argFocus);
    }
    setTop(hboxMenu);
    setCenter(dataTable);
}

From source file:net.sourceforge.msscodefactory.cfbam.v2_7.CFBamJavaFX.CFBamJavaFXTableListPane.java

public CFHBox getPanelHBoxMenu() {
    if (hboxMenu == null) {
        hboxMenu = new CFHBox(10);
        buttonAddTable = new CFButton();
        buttonAddTable.setMinWidth(200);
        buttonAddTable.setText("Add Table");
        buttonAddTable.setOnAction(new EventHandler<ActionEvent>() {
            @Override// www .j  a  va 2 s .  c o m
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    ICFBamTableObj obj = (ICFBamTableObj) schemaObj.getTableTableObj().newInstance();
                    ICFBamTableEditObj edit = (ICFBamTableEditObj) (obj.beginEdit());
                    if (edit == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "edit");
                    }
                    ICFSecurityTenantObj secTenant = schemaObj.getSecTenant();
                    edit.setRequiredOwnerTenant(secTenant);
                    ICFBamSchemaDefObj container = (ICFBamSchemaDefObj) (getJavaFXContainer());
                    if (container == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "JavaFXContainer");
                    }
                    edit.setRequiredContainerSchemaDef(container);
                    CFBorderPane frame = javafxSchema.getTableFactory().newAddForm(cfFormManager, obj,
                            getViewEditClosedCallback(), true);
                    ICFBamJavaFXTablePaneCommon jpanelCommon = (ICFBamJavaFXTablePaneCommon) frame;
                    jpanelCommon.setJavaFXFocus(obj);
                    jpanelCommon.setPaneMode(CFPane.PaneMode.Add);
                    cfFormManager.pushForm(frame);
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonAddTable);
        buttonViewSelected = new CFButton();
        buttonViewSelected.setMinWidth(200);
        buttonViewSelected.setText("View Selected");
        buttonViewSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamTableObj selectedInstance = getJavaFXFocusAsTable();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("TBLD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getTableFactory().newViewEditForm(cfFormManager,
                                    selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXTablePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamTableObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonViewSelected);

        buttonEditSelected = new CFButton();
        buttonEditSelected.setMinWidth(200);
        buttonEditSelected.setText("Edit Selected");
        buttonEditSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamTableObj selectedInstance = getJavaFXFocusAsTable();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("TBLD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getTableFactory().newViewEditForm(cfFormManager,
                                    selectedInstance, getViewEditClosedCallback(), false);
                            ((ICFBamJavaFXTablePaneCommon) frame).setPaneMode(CFPane.PaneMode.Edit);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamTableObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonEditSelected);

        buttonDeleteSelected = new CFButton();
        buttonDeleteSelected.setMinWidth(200);
        buttonDeleteSelected.setText("Delete Selected");
        buttonDeleteSelected.setOnAction(new EventHandler<ActionEvent>() {
            @Override
            public void handle(ActionEvent e) {
                final String S_ProcName = "handle";
                try {
                    ICFBamSchemaObj schemaObj = (ICFBamSchemaObj) javafxSchema.getSchema();
                    if (schemaObj == null) {
                        throw CFLib.getDefaultExceptionFactory().newNullArgumentException(getClass(),
                                S_ProcName, 0, "schemaObj");
                    }
                    ICFBamTableObj selectedInstance = getJavaFXFocusAsTable();
                    if (selectedInstance != null) {
                        String classCode = selectedInstance.getClassCode();
                        if ("TBLD".equals(classCode)) {
                            CFBorderPane frame = javafxSchema.getTableFactory().newAskDeleteForm(cfFormManager,
                                    selectedInstance, getDeleteCallback());
                            ((ICFBamJavaFXTablePaneCommon) frame).setPaneMode(CFPane.PaneMode.View);
                            cfFormManager.pushForm(frame);
                        } else {
                            throw CFLib.getDefaultExceptionFactory().newUnsupportedClassException(getClass(),
                                    S_ProcName, "selectedInstance", selectedInstance, "ICFBamTableObj");
                        }
                    }
                } catch (Throwable t) {
                    CFConsole.formException(S_FormName, ((CFButton) e.getSource()).getText(), t);
                }
            }
        });
        hboxMenu.getChildren().add(buttonDeleteSelected);

    }
    return (hboxMenu);
}

From source file:editeurpanovisu.EditeurPanovisu.java

private void ajouteFichierHisto(String nomFich) {
    if (nombreHistoFichiers > 10) {
        nombreHistoFichiers = 10;//from   w w  w  .  j av a 2s  .  co  m
    }
    int trouve = -1;
    for (int i = 0; i < nombreHistoFichiers; i++) {
        if (histoFichiers[i].equals(nomFich)) {
            trouve = i;
        }
    }
    if (trouve == -1) {
        for (int i = nombreHistoFichiers; i >= 0; i--) {
            if (i < 9) {
                histoFichiers[i + 1] = histoFichiers[i];
            }
        }
        histoFichiers[0] = nomFich;
        if (nombreHistoFichiers < 10) {
            nombreHistoFichiers++;
        }
    } else {
        for (int i = trouve - 1; i >= 0; i--) {
            if (i < 9) {
                histoFichiers[i + 1] = histoFichiers[i];
            }
        }
        histoFichiers[0] = nomFich;

    }
    derniersProjets.getItems().clear();
    for (int i = 0; i < nombreHistoFichiers; i++) {
        if (histoFichiers[i] != null) {
            MenuItem menuDerniersFichiers = new MenuItem(histoFichiers[i]);
            derniersProjets.getItems().add(menuDerniersFichiers);
            menuDerniersFichiers.setOnAction((ActionEvent e) -> {
                MenuItem mnu = (MenuItem) e.getSource();

                try {
                    try {
                        projetChargeNom(mnu.getText());
                    } catch (InterruptedException ex) {
                        Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
                    }
                } catch (IOException ex) {
                    Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
                }
            });
        }
    }

}

From source file:editeurpanovisu.EditeurPanovisu.java

/**
 *
 * @param primaryStage/*  ww w  .jav a 2 s  .  c om*/
 * @param racine
 * @param taille
 * @throws Exception
 */
private void creeMenu(VBox racine, int taille) throws Exception {
    //Pane myPane = (Pane) FXMLLoader.load(getClass().getResource("menuPrincipal.fxml"));
    VBox myPane = new VBox();
    myPane.setPrefHeight(80);
    myPane.setPrefWidth(3000);
    MenuBar menuPrincipal = new MenuBar();
    menuPrincipal.setMinHeight(25);
    menuPrincipal.setPrefHeight(29);
    menuPrincipal.setPrefWidth(3000);
    /* 
     Menu projets
     */
    Menu menuProjet = new Menu(rb.getString("projets"));
    menuPrincipal.getMenus().add(menuProjet);
    nouveauProjet = new MenuItem(rb.getString("nouveauProjet"));
    nouveauProjet.setAccelerator(KeyCombination.keyCombination("Ctrl+N"));
    menuProjet.getItems().add(nouveauProjet);
    chargeProjet = new MenuItem(rb.getString("ouvrirProjet"));
    chargeProjet.setAccelerator(KeyCombination.keyCombination("Ctrl+O"));
    menuProjet.getItems().add(chargeProjet);
    sauveProjet = new MenuItem(rb.getString("sauverProjet"));
    sauveProjet.setDisable(true);
    sauveProjet.setAccelerator(KeyCombination.keyCombination("Ctrl+S"));
    menuProjet.getItems().add(sauveProjet);
    sauveSousProjet = new MenuItem(rb.getString("sauverProjetSous"));
    sauveSousProjet.setDisable(true);
    sauveSousProjet.setAccelerator(KeyCombination.keyCombination("Shift+Ctrl+S"));
    menuProjet.getItems().add(sauveSousProjet);
    derniersProjets = new Menu(rb.getString("derniersProjets"));
    //        derniersProjets.setDisable(true);
    menuProjet.getItems().add(derniersProjets);
    fichHistoFichiers = new File(repertConfig.getAbsolutePath() + File.separator + "derniersprojets.cfg");
    nombreHistoFichiers = 0;
    if (fichHistoFichiers.exists()) {
        FileReader fr;
        fr = new FileReader(fichHistoFichiers);
        try (BufferedReader br = new BufferedReader(fr)) {
            while ((texteHisto = br.readLine()) != null) {
                MenuItem menuDerniersFichiers = new MenuItem(texteHisto);
                derniersProjets.getItems().add(menuDerniersFichiers);
                histoFichiers[nombreHistoFichiers] = texteHisto;
                nombreHistoFichiers++;
                menuDerniersFichiers.setOnAction((ActionEvent e) -> {
                    MenuItem mnu = (MenuItem) e.getSource();
                    try {
                        try {
                            projetChargeNom(mnu.getText());
                        } catch (InterruptedException ex) {
                            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
                        }
                    } catch (IOException ex) {
                        Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
                    }
                });

            }
        }
    }

    SeparatorMenuItem sep1 = new SeparatorMenuItem();
    menuProjet.getItems().add(sep1);
    fermerProjet = new MenuItem(rb.getString("quitterApplication"));
    fermerProjet.setAccelerator(KeyCombination.keyCombination("Ctrl+Q"));
    menuProjet.getItems().add(fermerProjet);
    /*
     Menu affichage
     */
    Menu menuAffichage = new Menu(rb.getString("affichage"));
    menuPrincipal.getMenus().add(menuAffichage);
    affichageVisite = new MenuItem(rb.getString("main.creationVisite"));
    affichageVisite.setAccelerator(KeyCombination.keyCombination("Ctrl+1"));
    menuAffichage.getItems().add(affichageVisite);
    affichageInterface = new MenuItem(rb.getString("main.creationInterface"));
    affichageInterface.setAccelerator(KeyCombination.keyCombination("Ctrl+2"));
    menuAffichage.getItems().add(affichageInterface);
    affichagePlan = new MenuItem(rb.getString("main.tabPlan"));
    affichagePlan.setAccelerator(KeyCombination.keyCombination("Ctrl+3"));
    affichagePlan.setDisable(true);
    menuAffichage.getItems().add(affichagePlan);
    SeparatorMenuItem sep3 = new SeparatorMenuItem();
    menuAffichage.getItems().add(sep3);
    configTransformation = new MenuItem(rb.getString("affichageConfiguration"));
    menuAffichage.getItems().add(configTransformation);

    /*
     Menu panoramiques
     */
    menuPanoramique = new Menu(rb.getString("panoramiques"));
    menuPanoramique.setDisable(true);
    menuPrincipal.getMenus().add(menuPanoramique);
    ajouterPano = new MenuItem(rb.getString("ajouterPanoramiques"));
    ajouterPano.setAccelerator(KeyCombination.keyCombination("Ctrl+A"));
    menuPanoramique.getItems().add(ajouterPano);
    ajouterPlan = new MenuItem(rb.getString("ajouterPlan"));
    ajouterPlan.setAccelerator(KeyCombination.keyCombination("Ctrl+P"));
    menuPanoramique.getItems().add(ajouterPlan);
    ajouterPlan.setDisable(true);
    SeparatorMenuItem sep2 = new SeparatorMenuItem();
    menuPanoramique.getItems().add(sep2);
    visiteGenere = new MenuItem(rb.getString("genererVisite"));
    visiteGenere.setDisable(true);
    visiteGenere.setAccelerator(KeyCombination.keyCombination("Ctrl+V"));
    menuPanoramique.getItems().add(visiteGenere);
    /*
     Menu Modles 
     */
    menuModeles = new Menu(rb.getString("menuModele"));
    menuPrincipal.getMenus().add(menuModeles);

    chargerModele = new MenuItem(rb.getString("modeleCharger"));
    menuModeles.getItems().add(chargerModele);

    sauverModele = new MenuItem(rb.getString("modeleSauver"));
    menuModeles.getItems().add(sauverModele);

    /*
     Menu transformations 
     */
    menuTransformation = new Menu(rb.getString("outils"));
    menuPrincipal.getMenus().add(menuTransformation);
    equi2CubeTransformation = new MenuItem(rb.getString("outilsEqui2Cube"));
    menuTransformation.getItems().add(equi2CubeTransformation);
    cube2EquiTransformation = new MenuItem(rb.getString("outilsCube2Equi"));
    menuTransformation.getItems().add(cube2EquiTransformation);

    /*
     Menu Aide
     */
    Menu menuAide = new Menu(rb.getString("aide"));
    menuPrincipal.getMenus().add(menuAide);
    aide = new MenuItem(rb.getString("aideAide"));
    aide.setAccelerator(KeyCombination.keyCombination("Ctrl+H"));
    menuAide.getItems().add(aide);
    SeparatorMenuItem sep4 = new SeparatorMenuItem();
    menuAide.getItems().add(sep4);
    aPropos = new MenuItem(rb.getString("aideAPropos"));
    menuAide.getItems().add(aPropos);
    /*
     barre de boutons 
     */
    HBox barreBouton = new HBox();
    barreBouton.getStyleClass().add("menuBarreOutils1");

    barreBouton.setPrefHeight(50);
    barreBouton.setMinHeight(50);
    barreBouton.setPrefWidth(3000);
    /*
     Bouton nouveau Projet
     */
    ScrollPane spBtnNouvprojet = new ScrollPane();
    spBtnNouvprojet.getStyleClass().add("menuBarreOutils");
    spBtnNouvprojet.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnNouvprojet.setPrefHeight(35);
    spBtnNouvprojet.setMaxHeight(35);
    spBtnNouvprojet.setPadding(new Insets(2));
    spBtnNouvprojet.setPrefWidth(35);

    HBox.setMargin(spBtnNouvprojet, new Insets(5, 15, 0, 15));
    imgNouveauProjet = new ImageView(
            new Image("file:" + repertAppli + File.separator + "images/nouveauProjet.png"));
    spBtnNouvprojet.setContent(imgNouveauProjet);
    Tooltip t0 = new Tooltip(rb.getString("nouveauProjet"));
    t0.setStyle(tooltipStyle);
    spBtnNouvprojet.setTooltip(t0);
    barreBouton.getChildren().add(spBtnNouvprojet);
    /*
     Bouton ouvrir Projet
     */
    ScrollPane spBtnOuvrirProjet = new ScrollPane();
    spBtnOuvrirProjet.getStyleClass().add("menuBarreOutils");
    spBtnOuvrirProjet.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnOuvrirProjet.setPrefHeight(35);
    spBtnOuvrirProjet.setMaxHeight(35);
    spBtnOuvrirProjet.setPadding(new Insets(2));
    spBtnOuvrirProjet.setPrefWidth(35);

    HBox.setMargin(spBtnOuvrirProjet, new Insets(5, 15, 0, 0));
    imgChargeProjet = new ImageView(
            new Image("file:" + repertAppli + File.separator + "images/ouvrirProjet.png"));
    spBtnOuvrirProjet.setContent(imgChargeProjet);
    Tooltip t1 = new Tooltip(rb.getString("ouvrirProjet"));
    t1.setStyle(tooltipStyle);
    spBtnOuvrirProjet.setTooltip(t1);
    barreBouton.getChildren().add(spBtnOuvrirProjet);

    /*
     Bouton sauve Projet
     */
    ScrollPane spBtnSauveProjet = new ScrollPane();
    spBtnSauveProjet.getStyleClass().add("menuBarreOutils");
    spBtnSauveProjet.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnSauveProjet.setPrefHeight(35);
    spBtnSauveProjet.setMaxHeight(35);
    spBtnSauveProjet.setPadding(new Insets(2));
    spBtnSauveProjet.setPrefWidth(35);

    HBox.setMargin(spBtnSauveProjet, new Insets(5, 15, 0, 0));
    imgSauveProjet = new ImageView(
            new Image("file:" + repertAppli + File.separator + "images/sauveProjet.png"));
    spBtnSauveProjet.setContent(imgSauveProjet);
    Tooltip t2 = new Tooltip(rb.getString("sauverProjet"));
    t2.setStyle(tooltipStyle);
    spBtnSauveProjet.setTooltip(t2);
    barreBouton.getChildren().add(spBtnSauveProjet);
    Separator sepImages = new Separator(Orientation.VERTICAL);
    sepImages.prefHeight(200);
    barreBouton.getChildren().add(sepImages);
    imgSauveProjet.setDisable(true);
    imgSauveProjet.setOpacity(0.3);
    /*
     Bouton Ajoute Panoramique
     */
    ScrollPane spBtnAjoutePano = new ScrollPane();
    spBtnAjoutePano.getStyleClass().add("menuBarreOutils");
    spBtnAjoutePano.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnAjoutePano.setPrefHeight(35);
    spBtnAjoutePano.setMaxHeight(35);
    spBtnAjoutePano.setPadding(new Insets(2));
    spBtnAjoutePano.setPrefWidth(35);

    HBox.setMargin(spBtnAjoutePano, new Insets(5, 15, 0, 15));
    imgAjouterPano = new ImageView(
            new Image("file:" + repertAppli + File.separator + "images/ajoutePanoramique.png"));
    spBtnAjoutePano.setContent(imgAjouterPano);
    Tooltip t3 = new Tooltip(rb.getString("ajouterPanoramiques"));
    t3.setStyle(tooltipStyle);
    spBtnAjoutePano.setTooltip(t3);
    barreBouton.getChildren().add(spBtnAjoutePano);
    imgAjouterPano.setDisable(true);
    imgAjouterPano.setOpacity(0.3);

    /*
     Bouton Ajoute Panoramique
     */
    ScrollPane spBtnAjoutePlan = new ScrollPane();
    spBtnAjoutePlan.getStyleClass().add("menuBarreOutils");
    spBtnAjoutePlan.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnAjoutePlan.setPrefHeight(35);
    spBtnAjoutePlan.setMaxHeight(35);
    spBtnAjoutePlan.setPadding(new Insets(2));
    spBtnAjoutePlan.setPrefWidth(35);

    HBox.setMargin(spBtnAjoutePlan, new Insets(5, 15, 0, 15));
    imgAjouterPlan = new ImageView(new Image("file:" + repertAppli + File.separator + "images/ajoutePlan.png"));
    spBtnAjoutePlan.setContent(imgAjouterPlan);
    Tooltip t31 = new Tooltip(rb.getString("ajouterPlan"));
    t31.setStyle(tooltipStyle);
    spBtnAjoutePlan.setTooltip(t31);
    barreBouton.getChildren().add(spBtnAjoutePlan);
    imgAjouterPlan.setDisable(true);
    imgAjouterPlan.setOpacity(0.3);

    /*
     Bouton Gnre
     */
    ScrollPane spBtnGenereVisite = new ScrollPane();
    spBtnGenereVisite.getStyleClass().add("menuBarreOutils");
    spBtnGenereVisite.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnGenereVisite.setPrefHeight(35);
    spBtnGenereVisite.setMaxHeight(35);
    spBtnGenereVisite.setPadding(new Insets(2));
    spBtnGenereVisite.setPrefWidth(70);

    HBox.setMargin(spBtnGenereVisite, new Insets(5, 15, 0, 0));
    imgVisiteGenere = new ImageView(
            new Image("file:" + repertAppli + File.separator + "images/genereVisite.png"));
    spBtnGenereVisite.setContent(imgVisiteGenere);
    Tooltip t4 = new Tooltip(rb.getString("genererVisite"));
    t4.setStyle(tooltipStyle);
    spBtnGenereVisite.setTooltip(t4);
    barreBouton.getChildren().add(spBtnGenereVisite);
    imgVisiteGenere.setDisable(true);
    imgVisiteGenere.setOpacity(0.3);
    Separator sepImages1 = new Separator(Orientation.VERTICAL);
    sepImages1.prefHeight(200);
    barreBouton.getChildren().add(sepImages1);
    /*
     Bouton equi -> faces de  Cube
     */
    ScrollPane spBtnEqui2Cube = new ScrollPane();
    spBtnEqui2Cube.getStyleClass().add("menuBarreOutils");
    spBtnEqui2Cube.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnEqui2Cube.setPrefHeight(35);
    spBtnEqui2Cube.setMaxHeight(35);
    spBtnEqui2Cube.setPadding(new Insets(2));
    spBtnEqui2Cube.setPrefWidth(109);

    HBox.setMargin(spBtnEqui2Cube, new Insets(5, 15, 0, 250));
    imgEqui2Cube = new ImageView(new Image("file:" + repertAppli + File.separator + "images/equi2cube.png"));
    spBtnEqui2Cube.setContent(imgEqui2Cube);
    Tooltip t6 = new Tooltip(rb.getString("outilsEqui2Cube"));
    t6.setStyle(tooltipStyle);
    spBtnEqui2Cube.setTooltip(t6);
    barreBouton.getChildren().add(spBtnEqui2Cube);

    /*
     Bouton faces de cube -> equi
     */
    ScrollPane spBtnCube2Equi = new ScrollPane();
    spBtnCube2Equi.getStyleClass().add("menuBarreOutils");
    spBtnCube2Equi.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
    spBtnCube2Equi.setPrefHeight(35);
    spBtnCube2Equi.setMaxHeight(35);
    spBtnCube2Equi.setPadding(new Insets(2));
    spBtnCube2Equi.setPrefWidth(109);

    HBox.setMargin(spBtnCube2Equi, new Insets(5, 25, 0, 0));
    imgCube2Equi = new ImageView(new Image("file:" + repertAppli + File.separator + "images/cube2equi.png"));
    spBtnCube2Equi.setContent(imgCube2Equi);
    Tooltip t5 = new Tooltip(rb.getString("outilsCube2Equi"));
    t5.setStyle(tooltipStyle);
    spBtnCube2Equi.setTooltip(t5);
    barreBouton.getChildren().add(spBtnCube2Equi);

    myPane.getChildren().addAll(menuPrincipal, barreBouton);
    racine.getChildren().add(myPane);
    nouveauProjet.setOnAction((ActionEvent e) -> {
        projetsNouveau();
    });
    chargeProjet.setOnAction((ActionEvent e) -> {
        try {
            try {
                projetCharge();
            } catch (InterruptedException ex) {
                Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
            }

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    sauveProjet.setOnAction((ActionEvent e) -> {
        try {
            projetSauve();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    sauveSousProjet.setOnAction((ActionEvent e) -> {
        try {
            projetSauveSous();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    visiteGenere.setOnAction((ActionEvent e) -> {
        try {
            genereVisite();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    fermerProjet.setOnAction((ActionEvent e) -> {
        try {
            projetsFermer();
        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    ajouterPano.setOnAction((ActionEvent e) -> {
        try {
            panoramiquesAjouter();
        } catch (InterruptedException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    ajouterPlan.setOnAction((ActionEvent e) -> {
        planAjouter();
    });
    aPropos.setOnAction((ActionEvent e) -> {
        aideapropos();
    });
    aide.setOnAction((ActionEvent e) -> {
        AideDialogController.affiche();
    });

    chargerModele.setOnAction((ActionEvent e) -> {
        try {
            modeleCharger();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });

    sauverModele.setOnAction((ActionEvent e) -> {
        try {
            modeleSauver();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });

    cube2EquiTransformation.setOnAction((ActionEvent e) -> {
        transformationCube2Equi();
    });

    equi2CubeTransformation.setOnAction((ActionEvent e) -> {
        transformationEqui2Cube();
    });
    affichageVisite.setOnAction((ActionEvent e) -> {
        tabPaneEnvironnement.getSelectionModel().select(0);
    });
    affichageInterface.setOnAction((ActionEvent e) -> {
        tabPaneEnvironnement.getSelectionModel().select(1);
    });
    affichagePlan.setOnAction((ActionEvent e) -> {
        if (!tabPlan.isDisabled()) {
            tabPaneEnvironnement.getSelectionModel().select(2);
        }
    });

    configTransformation.setOnAction((ActionEvent e) -> {
        try {
            ConfigDialogController cfg = new ConfigDialogController();
            cfg.afficheFenetre();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });

    spBtnNouvprojet.setOnMouseClicked((MouseEvent t) -> {
        projetsNouveau();
    });
    spBtnOuvrirProjet.setOnMouseClicked((MouseEvent t) -> {
        try {
            try {
                projetCharge();
            } catch (InterruptedException ex) {
                Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
            }

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    spBtnSauveProjet.setOnMouseClicked((MouseEvent t) -> {
        try {
            projetSauve();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    spBtnAjoutePano.setOnMouseClicked((MouseEvent t) -> {
        try {
            panoramiquesAjouter();
        } catch (InterruptedException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    spBtnAjoutePlan.setOnMouseClicked((MouseEvent t) -> {
        planAjouter();
    });
    spBtnGenereVisite.setOnMouseClicked((MouseEvent t) -> {
        try {
            genereVisite();

        } catch (IOException ex) {
            Logger.getLogger(EditeurPanovisu.class.getName()).log(Level.SEVERE, null, ex);
        }
    });
    spBtnEqui2Cube.setOnMouseClicked((MouseEvent t) -> {
        transformationEqui2Cube();
    });
    spBtnCube2Equi.setOnMouseClicked((MouseEvent t) -> {
        transformationCube2Equi();
    });

}