Search in sources :

Example 1 with DataSourceViewDescriptor

use of org.jkiss.dbeaver.registry.DataSourceViewDescriptor in project dbeaver by serge-rider.

the class EditConnectionWizard method addPages.

/**
     * Adding the page to the wizard.
     */
@Override
public void addPages() {
    DataSourceViewDescriptor view = dataSource.getDriver().getProviderDescriptor().getView(IActionConstants.EDIT_CONNECTION_POINT);
    if (view != null) {
        pageSettings = new ConnectionPageSettings(this, view, dataSource);
        addPage(pageSettings);
    }
    boolean embedded = dataSource.getDriver().isEmbedded();
    pageGeneral = new ConnectionPageGeneral(this, dataSource);
    if (!embedded) {
        pageNetwork = new ConnectionPageNetwork(this);
    }
    pageEvents = new EditShellCommandsDialogPage(dataSource);
    addPage(pageGeneral);
    if (pageSettings != null) {
        if (!embedded) {
            pageSettings.addSubPage(pageNetwork);
        }
        pageSettings.addSubPage(pageEvents);
    }
    addPreferencePage(new PrefPageMetaData(), "Metadata", "Metadata reading preferences");
    WizardPrefPage rsPage = addPreferencePage(new PrefPageResultSetMain(), "Result Sets", "Result Set preferences");
    rsPage.addSubPage(new PrefPageResultSetBinaries(), "Binaries", "Binary data representation");
    rsPage.addSubPage(new PrefPageDataFormat(), "Data Formatting", "Data formatting preferences");
    rsPage.addSubPage(new PrefPageResultSetPresentation(), "Presentation", "ResultSets UI & presentation");
    WizardPrefPage sqlPage = addPreferencePage(new PrefPageSQLEditor(), "SQL Editor", "SQL editor settings");
    sqlPage.addSubPage(new PrefPageSQLExecute(), "SQL Processing", "SQL processing settings");
}
Also used : DataSourceViewDescriptor(org.jkiss.dbeaver.registry.DataSourceViewDescriptor)

Example 2 with DataSourceViewDescriptor

use of org.jkiss.dbeaver.registry.DataSourceViewDescriptor in project dbeaver by serge-rider.

the class NewConnectionWizard method addPages.

/**
     * Adding the page to the wizard.
     */
@Override
public void addPages() {
    pageDrivers = new ConnectionPageDriver(this);
    addPage(pageDrivers);
    List<DataSourceProviderDescriptor> providers = DataSourceProviderRegistry.getInstance().getDataSourceProviders();
    for (DataSourceProviderDescriptor provider : providers) {
        DataSourceViewDescriptor view = provider.getView(IActionConstants.NEW_CONNECTION_POINT);
        availableProvides.add(provider);
        if (view != null) {
            ConnectionPageSettings pageSettings = new ConnectionPageSettings(NewConnectionWizard.this, view);
            settingsPages.put(provider, pageSettings);
            addPage(pageSettings);
        }
    }
    pageGeneral = new ConnectionPageGeneral(this);
    pageNetwork = new ConnectionPageNetwork(this);
    addPage(pageGeneral);
    addPage(pageNetwork);
    // Initial settings
    if (selection != null && !selection.isEmpty()) {
        final Object element = selection.getFirstElement();
        if (element instanceof DBNLocalFolder) {
            pageGeneral.setDataSourceFolder(((DBNLocalFolder) element).getFolder());
        }
    }
}
Also used : DBNLocalFolder(org.jkiss.dbeaver.model.navigator.DBNLocalFolder) DataSourceViewDescriptor(org.jkiss.dbeaver.registry.DataSourceViewDescriptor) DataSourceProviderDescriptor(org.jkiss.dbeaver.registry.DataSourceProviderDescriptor)

Aggregations

DataSourceViewDescriptor (org.jkiss.dbeaver.registry.DataSourceViewDescriptor)2 DBNLocalFolder (org.jkiss.dbeaver.model.navigator.DBNLocalFolder)1 DataSourceProviderDescriptor (org.jkiss.dbeaver.registry.DataSourceProviderDescriptor)1