Package com.dci.intellij.dbn.data.type

Examples of com.dci.intellij.dbn.data.type.DBNativeDataType


        name = metaData.getColumnName(resultSetColumnIndex);

        String dataTypeName = metaData.getColumnTypeName(resultSetColumnIndex);
        int precision = getPrecision(metaData);
        int scale = metaData.getScale(resultSetColumnIndex);
        DBNativeDataType nativeDataType = objectBundle.getNativeDataType(dataTypeName);
        dataType = new DBDataType(nativeDataType, precision, scale);
    }
View Full Code Here


    }

    public GenericDataType getGenericDataType(int columnIndex) {
        int realColumnIndex = getRealColumnIndex(columnIndex);
        ColumnInfo columnInfo = table.getModel().getColumnInfo(realColumnIndex);
        DBNativeDataType nativeDataType = columnInfo.getDataType().getNativeDataType();

        return nativeDataType == null ?
                GenericDataType.LITERAL :
                nativeDataType.getDataTypeDefinition().getGenericDataType();

    }
View Full Code Here

            typeAttributesPanel.setVisible(false);
        }


        if (argument.isInput() && !dataType.isDeclared() && dataType.getNativeDataType() != null) {
            DBNativeDataType nativeDataType = dataType.getNativeDataType();
            DataTypeDefinition dataTypeDefinition = nativeDataType.getDataTypeDefinition();
            GenericDataType genericDataType = dataTypeDefinition.getGenericDataType();

            if (genericDataType == GenericDataType.DATE_TIME) {
                TextFieldWithPopup inputField = new TextFieldWithPopup(argument.getProject());
                inputField.setPreferredSize(new Dimension(200, -1));
View Full Code Here

            }
        }
    }

    private boolean isBoolean(DBDataType dataType) {
        DBNativeDataType nativeDataType = dataType.getNativeDataType();
        return nativeDataType != null && nativeDataType.getDataTypeDefinition().getGenericDataType() == GenericDataType.BOOLEAN;
    }
View Full Code Here

        columnLabel.setIcon(column.getIcon());
        columnLabel.setText(column.getName());
        dataTypeLabel.setText(dataType.getQualifiedName());
        dataTypeLabel.setForeground(UIUtil.getInactiveTextColor());

        DBNativeDataType nativeDataType = dataType.getNativeDataType();
        if (nativeDataType != null) {
            DataTypeDefinition dataTypeDefinition = nativeDataType.getDataTypeDefinition();
            GenericDataType genericDataType = dataTypeDefinition.getGenericDataType();

            DataEditorSettings dataEditorSettings = DataEditorSettings.getInstance(project);

            long dataLength = dataType.getLength();
View Full Code Here

        attributeLabel.setIcon(typeAttribute.getIcon());
        attributeTypeLabel.setForeground(UIUtil.getInactiveTextColor());
        attributeTypeLabel.setText(typeAttribute.getDataType().getQualifiedName());

        DBDataType dataType = typeAttribute.getDataType();
        DBNativeDataType nativeDataType = dataType.getNativeDataType();
        DataTypeDefinition dataTypeDefinition = nativeDataType.getDataTypeDefinition();
        GenericDataType genericDataType = dataTypeDefinition.getGenericDataType();


        if (genericDataType == GenericDataType.DATE_TIME) {
            TextFieldWithPopup inputField = new TextFieldWithPopup(argument.getProject());
View Full Code Here

    public synchronized List<DBNativeDataType> getNativeDataTypes(){
        if (nativeDataTypes == null) {
            List<DataTypeDefinition> dataTypeDefinitions = connectionHandler.getInterfaceProvider().getNativeDataTypes().list();
            nativeDataTypes = new ArrayList<DBNativeDataType>();
            for (DataTypeDefinition dataTypeDefinition : dataTypeDefinitions) {
                DBNativeDataType dataType = new DBNativeDataType(dataTypeDefinition);
                nativeDataTypes.add(dataType);
            }
            Collections.sort(nativeDataTypes, new Comparator<DBNativeDataType>() {
                @Override
                public int compare(DBNativeDataType o1, DBNativeDataType o2) {
View Full Code Here

        }

        @Override
        public void valueSelected(DBColumn column) {
            if (column != null) {
                DBNativeDataType nativeDataType = column.getDataType().getNativeDataType();
                GenericDataType dataType = nativeDataType == null ? null : nativeDataType.getBasicDataType();
                editorComponent.setPopupEnabled(TextFieldPopupType.CALENDAR, dataType == GenericDataType.DATE_TIME);
            }
            if (basicFilterForm != null) {
                basicFilterForm.updateNameAndPreview();
            }
View Full Code Here

    }

    private TableCellEditor createEditorForNativeType(ColumnInfo columnInfo, DatasetEditorTable table) {
        DataEditorSettings dataEditorSettings = DataEditorSettings.getInstance(table.getDatasetEditor().getProject());
        DBDataType dataType = columnInfo.getDataType();
        DBNativeDataType nativeDataType = dataType.getNativeDataType();
        DataTypeDefinition dataTypeDefinition = nativeDataType.getDataTypeDefinition();
        GenericDataType genericDataType = dataTypeDefinition.getGenericDataType();
        if (genericDataType == GenericDataType.NUMERIC) {
            return new DatasetTableCellEditor(table);
        }
        else if (genericDataType == GenericDataType.DATE_TIME) {
View Full Code Here

TOP

Related Classes of com.dci.intellij.dbn.data.type.DBNativeDataType

Copyright © 2018 www.massapicom. 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.