Examples of DatabaseObject


Examples of org.jitterbit.integration.database.info.DatabaseObject

    private void updateTableUsageFields(DatabaseStructure struct, SelectedTables objects) {
        for (DatabaseObject table : objects.getIncludedTables()) {
            int count;
            if (isSchemaNameIncluded) {
                String qualName = quotes.getQualifiedName(table);
                DatabaseObject copy = table.createCopy(qualName);
                count = struct.getUseCount(copy);
            } else {
                count = struct.getUseCount(table);
            }
            if (count == 0) {
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

        @Override
        protected SelectedTables getValueFromUi() {
            SelectedTables value = new SelectedTables();
            for (int row = 0; row < tableModel.getRowCount(); ++row) {
                DatabaseObject o = tableModel.getRowObjectAt(row);
                int count = tableModel.getUseCount(row);
                value.setTableUsage(o, count);
            }
            return value;
        }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

    @Override
    public void setStructureToEdit(StructureToEdit toEdit) {
        // If the user has selected another object than the original one when editing the
        // structure, we do not do anything:
        DatabaseObject o = getObjectToEdit(toEdit);
        if (o != null) {
            ui.setSelectedColumns(toEdit.getStructure(), dbObject);
        }
    }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

    }

    @Override
    protected DatabaseObject translate(DatabaseObject original, BeginEndQuote quotes) {
        String simpleName = quotes.getSimpleName(original);
        DatabaseObject copy = original.createCopy(simpleName);
        return copy;
    }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

        @Override
        public void selectionChanged(SelectionChangedEvent evt) {
            OrderedSelection selection = (OrderedSelection) evt.getSelection();
            SelectedTables tables = new SelectedTables();
            if (!selection.isEmpty()) {
                DatabaseObject table = (DatabaseObject) selection.head();
                tables.setTableUsage(table, 1);
            }
            model.setUsageCount(tables);
        }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

        public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
                        boolean cellHasFocus) {
            super.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
            setForeground(isSelected ? list.getSelectionForeground() : list.getForeground());
            if (value instanceof DatabaseObject) {
                DatabaseObject item = (DatabaseObject) value;
                String text = selectionModel.isSchemaNameIncluded() ? getQualifiedName(item) : item.getName();
                setText(text);
                setToolTipText(text);
                Border border = new BorderBuilder().empty(0, 10, 0, 0).add(getBorder());
                setBorder(border);
                if (disableSelectedItems && selectionModel.isTableIncluded(item)) {
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

    @Override
    public void setStructureToEdit(StructureToEdit toEdit) {
        // If the user has selected another object than the original one when editing the
        // structure, we do not do anything:
        DatabaseObject o = getObjectToEdit(toEdit);
        if (o != null) {
            ui.populateUi(toEdit.getStructure(), o);
        }
    }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

    @Override
    public void setStructureToEdit(StructureToEdit toEdit) {
        // If the user has selected another object than the original one when editing the
        // structure, we do not do anything:
        DatabaseObject o = getObjectToEdit(toEdit);
        if (o != null) {
            SqlScript sql = toEdit.getStructure().getSqlScript();
            ui.setWhereClause(sql.getWhereClause());
            ui.setBeginEndQuotes(toEdit.getStructure().getBeginEndQuote());
        }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

        if (!schemaIncluded) {
            return Maps.newHashMap(usage);
        }
        Map<DatabaseObject, Integer> eff = Maps.newHashMap();
        for (Map.Entry<DatabaseObject, Integer> e : usage.entrySet()) {
            DatabaseObject copy = e.getKey().createCopy(e.getKey().getName());
            eff.put(copy, e.getValue());
        }
        return eff;
    }
View Full Code Here

Examples of org.jitterbit.integration.database.info.DatabaseObject

    }

    public SelectedTables withSchemaName(BeginEndQuote quotes) {
        SelectedTables withSchemaName = new SelectedTables();
        for (Map.Entry<DatabaseObject, Integer> e : usage.entrySet()) {
            DatabaseObject table = e.getKey();
            if (isSchemaNameIncluded(table, quotes)) {
                continue;
            }
            String qualName = quotes.getQualifiedName(table);
            DatabaseObject copy = table.createCopy(qualName);
            int count = e.getValue();
            withSchemaName.setTableUsage(copy, count);
        }
        return withSchemaName;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.