Returns the workspaces which are visible and are not in the given list.

@return array[Workspace]
354933
public function findDisplayableWorkspacesWithout(array $excludedWorkspaces)
    {
        $dql = '
            SELECT w
            FROM Claroline\CoreBundle\Entity\Workspace\Workspace w
            WHERE w.displayable = true
            AND w NOT IN (:excludedWorkspaces)
            ORDER BY w.name
        ';
        $query = $this->_em->createQuery($dql);
        $query->setParameter('excludedWorkspaces', $excludedWorkspaces);

        return $query->getResult();
    }
153043
public function listWorkspacesByUserForPickerAction()
    {
        $isGranted = $this->authorization->isGranted('ROLE_USER');
        $response = new JsonResponse('', 401);
        if ($isGranted === true) {
            $token = $this->tokenStorage->getToken();
            $user = $token->getUser();

            $workspaces = $this->workspaceManager
                ->getWorkspacesByUser($user);

            $workspacesData = array();
            foreach ($workspaces as $workspace) {
                array_push($workspacesData, $workspace->serializeForWidgetPicker());
            }
            $data = array('items'=>$workspacesData);
            $response->setData($data)->setStatusCode(200);
        }

        return $response;
    }
21428
public function getVisitors()
    {
        $data = $this->memcache->get(self::MEMCACHE_VISITOR_KEY);
        if (!$data) {
            $data = array();
        }
        return (array)$data;
    }
1326990
public List<AbstractPanel> getVisiblePanels() {
        List<AbstractPanel> panels = getPanels();
        for (Iterator<AbstractPanel> it = panels.iterator(); it.hasNext();) {
            if (hiddenTabs.contains(it.next())) {
                it.remove();
            }
        }
        return panels;
    }
1114228
public function getNamespaces()
    {
        $db = Database::getActiveConnection();

        /** @var PDOStatement $results */
        $results = $db->createQueryBuilder()
            ->select('configNamespace')
            ->from('Config', 'c')
            ->where('configNamespace != ""')
            ->groupBy('configNamespace')
            ->execute();

        return array_map('array_shift', $results->fetchAll());
    }
347618
public function _getWishlistItems()
    {
        $wishlist = $this->_getWishlist();
        if ($wishlist && ! empty($wishlist->getItemCollection())) {
            return $wishlist->getItemCollection();
        } else {
            return [];
        }
    }
677907
public function getWishList()
    {
        if ($this->_oWishList === null) {
            $this->_oWishList = false;

            // passing wishlist information
            if ($oUser = $this->getWishUser()) {
                $oWishlistBasket = $oUser->getBasket('wishlist');
                $this->_oWishList = $oWishlistBasket->getArticles();

                if (!$oWishlistBasket->isVisible()) {
                    $this->_oWishList = false;
                }
            }
        }

        return $this->_oWishList;
    }
1364007
public function VisibleFields()
    {
        $visibleFields = new FieldList();

        foreach ($this as $field) {
            if (!($field instanceof HiddenField)) {
                $visibleFields->push($field);
            }
        }

        return $visibleFields;
    }
1069499
protected function collectWorkspaceAndAllBaseWorkspaces(Workspace $workspace)
    {
        $workspaces = [];
        while ($workspace !== null) {
            $workspaces[] = $workspace;
            $workspace = $workspace->getBaseWorkspace();
        }

        return $workspaces;
    }
1371051
public function getShowPromotionList()
    {
        if (isset($this->_blShowPromotions)) {
            return $this->_blShowPromotions;
        }
        $this->_blShowPromotions = false;
        if (oxNew(\OxidEsales\Eshop\Application\Model\ActionList::class)->areAnyActivePromotions()) {
            $this->_blShowPromotions = (count($this->getPromoFinishedList()) + count($this->getPromoCurrentList()) +
                                        count($this->getPromoFutureList())) > 0;
        }

        return $this->_blShowPromotions;
    }
430410
protected function getIgnoredDirs()
    {
        $ignored = [self::LANG_DIR, 'node_modules'];
        if ($this->getOption('ignore_tests')) {
            $ignored[] = self::TESTS_DIR;
        }
        return $ignored;
    }
397396
def space_list(args):
    ''' '''

    r = fapi.list_workspaces()
    fapi._check_response_code(r, 200)

    spaces = []
    project = args.project
    if project:
        project = re.compile('^' + project)

    for space in r.json():
        ns = space['workspace']['namespace']
        if project and not project.match(ns):
            continue
        ws = space['workspace']['name']
        spaces.append(ns + '\t' + ws)

    # Sort for easier downstream viewing, ignoring case
    return sorted(spaces, key=lambda s: s.lower())
834223
public function getSubCatList()
    {
        if ($this->_oSubCatList === null) {
            $this->_oSubCatList = [];
            if ($this->hasVisibleSubCats()) {
                return $this->_oSubCatList;
            }
        }

        return $this->_oSubCatList;
    }
149225
public function getAvailableWorkflowIds()
    {
        $availableWorkflows = $this->workflowContainer->all();

        $availableWorkflowsIds = array();
        foreach ($availableWorkflows as $availableWorkflow) {
            $availableWorkflowsIds[] = $availableWorkflow->getServiceId();
        }

        return $availableWorkflowsIds;
    }
1040083
public function visibleColumnNames()
    {
        $visible = array_filter(explode(',', request(Tools\ColumnSelector::SELECT_COLUMN_NAME)));

        if (empty($visible)) {
            return $this->columnNames;
        }

        array_push($visible, '__row_selector__', '__actions__');

        return collect($this->columnNames)->filter(function ($column) use ($visible) {
            return in_array($column, $visible);
        });
    }
35936
public function emptyListActions()
    {
        $actions = $this->listActions();

        $filteredArray = array_filter($actions, function ($action) {
            return $action['empty'];
        });

        return array_values($filteredArray);
    }
1287364
public function getPublishableNodeInfo(Workspace $workspace)
    {
        $publishableNodes = $this->publishingService->getUnpublishedNodes($workspace);

        $publishableNodes = array_map(function ($node) {
            if ($documentNode = $this->nodeService->getClosestDocument($node)) {
                return [
                    'contextPath' => $node->getContextPath(),
                    'documentContextPath' => $documentNode->getContextPath()
                ];
            }
        }, $publishableNodes);

        return array_values(array_filter($publishableNodes, function ($item) {
            return (bool)$item;
        }));
    }