public static boolean canCreateObject(DBNNode node, Boolean onlySingle) {
        DBPWorkspace workspace = DBWorkbench.getPlatform().getWorkspace();
        if (node instanceof DBNProject && DBWorkbench.isDistributed()) {
            return false;
        }
        if (node instanceof DBNDatabaseNode dbNode){
            if (dbNode.isVirtual() || !workspace.hasRealmPermission(RMConstants.PERMISSION_METADATA_EDITOR)) {
                // Can't create virtual objects
                return false;
            }
            DBPDataSource dataSource = dbNode.getDataSource();
            if (dataSource != null && dataSource.getInfo().isReadOnlyMetaData()) {
                return false;
            }
            if (!(node instanceof DBNDataSource) && isMetadataChangeDisabled(dbNode)) {
                return false;
            }
        }
        if (onlySingle == null) {
            // Just try to find first create handler
            if (node instanceof DBNDataSource || node instanceof DBNLocalFolder) {
                // We always can create datasource
                return node.getOwnerProject().hasRealmPermission(RMConstants.PERMISSION_PROJECT_DATASOURCES_EDIT);
            }

            Class<?> objectType;
            if (!(node instanceof DBNContainer)) {
                if (node.getParentNode() instanceof DBNContainer) {
                    node = node.getParentNode();
                }
            }
            DBNContainer container;
            if (node instanceof DBNContainer) {
                // Try to detect child type
                objectType = ((DBNContainer) node).getChildrenClass();
                container = (DBNContainer) node;
            } else {
                return false;
            }
            if (DBNUtils.isReadOnly(node) || !workspace.hasRealmPermission(RMConstants.PERMISSION_METADATA_EDITOR)) {
                return false;
            }

            if (node instanceof DBSWrapper && DBUtils.isReadOnly(((DBSWrapper) node).getObject())) {
                return false;
            }
            if (objectType == null) {
                return false;
            }
            DBEObjectMaker<?,?> objectMaker = getObjectManager(objectType, DBEObjectMaker.class);
            if (objectMaker == null) {
                return false;
            }
            return objectMaker.canCreateObject(container.getValueObject());
        }
        if (DBNUtils.isReadOnly(node)) {
            return false;
        }

        // Check whether only single object type can be created or multiple ones
        List<IContributionItem> createItems = NavigatorHandlerObjectCreateNew.fillCreateMenuItems(null, node);

        if (onlySingle) {
            return createItems.size() == 1;
        } else {
            return createItems.size() > 1;
        }
    }
Check whether the owner project of the specified node has required permissions
plugins/org.jkiss.dbeaver.ui.navigator/src/org/jkiss/dbeaver/ui/actions/ObjectPropertyTester.java