Examples of DBObjectProperties


Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

    private void processSelectEvent(InputEvent event, TreePath path, boolean deliberate) {
        if (path != null) {
            Object lastPathEntity = path.getLastPathComponent();
            if (lastPathEntity instanceof DBObject) {
                final DBObject object = (DBObject) lastPathEntity;
                DBObjectProperties properties = object.getProperties();
                if (properties.is(DBObjectProperty.EDITABLE)) {
                    DBSchemaObject schemaObject = (DBSchemaObject) object;
                    DatabaseFileSystem.getInstance().openEditor(schemaObject);
                    event.consume();
                } else if (properties.is(DBObjectProperty.NAVIGABLE)) {
                    DatabaseFileSystem.getInstance().openEditor(object);
                    event.consume();
                } else if (deliberate) {
                    new BackgroundTask(getProject(), "Loading Object Reference", false, false) {
                        protected void execute(@NotNull ProgressIndicator progressIndicator) throws InterruptedException {
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

public class ObjectActionGroup extends DefaultActionGroup {

    public ObjectActionGroup(DBObject object) {
        DatabaseCompatibilityInterface compatibilityInterface = DatabaseCompatibilityInterface.getInstance(object);

        DBObjectProperties properties = object.getProperties();
        if(object instanceof DBSchemaObject) {
            DBSchemaObject schemaObject = (DBSchemaObject) object;

            if (properties.is(DBObjectProperty.EDITABLE)) {
                DBContentType contentType = schemaObject.getContentType();
                if (contentType == DBContentType.DATA || contentType == DBContentType.CODE_AND_DATA) {
                    add(new EditObjectDataAction(schemaObject));
                }

                if (contentType == DBContentType.CODE || contentType == DBContentType.CODE_AND_DATA || contentType == DBContentType.CODE_SPEC_AND_BODY) {
                    add(new EditObjectCodeAction(schemaObject));
                }
            }

            if (properties.is(DBObjectProperty.COMPILABLE) && compatibilityInterface.supportsFeature(DatabaseFeature.OBJECT_INVALIDATION)) {
                add(new CompileActionGroup(schemaObject));
            }

            if (properties.is(DBObjectProperty.DISABLEABLE) && compatibilityInterface.supportsFeature(DatabaseFeature.OBJECT_DISABLING)) {
                add(new EnableDisableAction(schemaObject));
            }
        }

        if (object instanceof DBMethod) {
            if (compatibilityInterface.supportsFeature(DatabaseFeature.DEBUGGING)) {
                add(new ExecuteActionGroup((DBSchemaObject) object));
            } else {
                add(new RunMethodAction((DBMethod) object));
            }
        }

        if (object instanceof DBProgram && properties.is(DBObjectProperty.SCHEMA_OBJECT)) {
            if (compatibilityInterface.supportsFeature(DatabaseFeature.DEBUGGING)) {
                add(new ExecuteActionGroup((DBSchemaObject) object));
            } else {
                add(new RunProgramMethodAction((DBProgram) object));
            }
        }

        if (properties.is(DBObjectProperty.SCHEMA_OBJECT)) {
            add(new DropObjectAction((DBSchemaObject) object));

            //add(new TestAction(object));
        }

        if(properties.is(DBObjectProperty.REFERENCEABLE) && compatibilityInterface.supportsFeature(DatabaseFeature.OBJECT_DEPENDENCIES)) {
            addSeparator();
            add (new DependenciesActionGroup((DBSchemaObject) object));
        }

        List<DBObjectNavigationList> navigationLists = object.getNavigationLists();
        if (navigationLists != null && navigationLists.size() > 0) {
            if (!properties.is(DBObjectProperty.REFERENCEABLE)) addSeparator();
            //add(new DbsGoToActionGroup(linkLists));
            for (DBObjectNavigationList navigationList : navigationLists) {
                if (navigationList.isLazy()) {
                    add(new ObjectLazyNavigationListAction(object.getParentObject(), navigationList));
                } else {
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        objectStatus.set(DBObjectStatus.DEBUG, isDebug);
    }

    @Override
    public void initProperties() {
        DBObjectProperties properties = getProperties();
        properties.set(DBObjectProperty.EDITABLE);
        properties.set(DBObjectProperty.DISABLEABLE);
        properties.set(DBObjectProperty.COMPILABLE);
        properties.set(DBObjectProperty.SCHEMA_OBJECT);
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        getStatus().set(DBObjectStatus.ENABLED, enabled);
    }

    @Override
    protected void initProperties() {
        DBObjectProperties properties = getProperties();
        properties.set(DBObjectProperty.SCHEMA_OBJECT);
        properties.set(DBObjectProperty.DISABLEABLE);
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        getStatus().set(DBObjectStatus.VALID, valid);
    }

    @Override
    public void initProperties() {
        DBObjectProperties properties = getProperties();
        properties.set(DBObjectProperty.REFERENCEABLE);
        properties.set(DBObjectProperty.SCHEMA_OBJECT);
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

    public DBSchemaObjectImpl(DBSchemaObject parent, DBContentType contentType, ResultSet resultSet) throws SQLException {
        super(parent, contentType, resultSet);
    }

    protected void initProperties() {
        DBObjectProperties properties = getProperties();
        properties.set(DBObjectProperty.EDITABLE);
        properties.set(DBObjectProperty.REFERENCEABLE);
        properties.set(DBObjectProperty.SCHEMA_OBJECT);
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        properties.set(DBObjectProperty.SCHEMA_OBJECT);
    }

    @Override
    protected void initLists() {
        DBObjectProperties properties = getProperties();
        if (properties.is(DBObjectProperty.REFERENCEABLE)) {
            DBObjectListContainer childObjects = initChildObjects();
            referencedObjects = childObjects.createObjectList(DBObjectType.ANY, this, REFERENCED_OBJECTS_LOADER, false, true);
            referencingObjects = childObjects.createObjectList(DBObjectType.ANY, this, REFERENCING_OBJECTS_LOADER, false, true);
        }
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        name = resultSet.getString("SEQUENCE_NAME");
    }

    @Override
    public void initProperties() {
        DBObjectProperties properties = getProperties();
        properties.set(DBObjectProperty.REFERENCEABLE);
        properties.set(DBObjectProperty.SCHEMA_OBJECT);
    }
View Full Code Here

Examples of com.dci.intellij.dbn.object.common.property.DBObjectProperties

        if (connectionHandler == null) throw DynamicContentLoader.DBN_INTERRUPTED_EXCEPTION;
    }

    public DBObjectProperties getProperties() {
        if (properties == null) {
            properties = new DBObjectProperties();
        }
        return properties;
    }
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.