public function getCollectionsByStorage(StorageInterface $storage)
    {
        $this->initialize();

        $collections = [];
        foreach ($this->collections as $collectionName => $collection) {
            /** @var CollectionInterface $collection */
            if ($collection->getStorage() === $storage) {
                $collections[$collectionName] = $collection;
            }
        }
        return $collections;
    }
public function getCollectionsByStorage(StorageInterface $storage)
    {
        $this->initialize();

        $collections = [];
        foreach ($this->collections as $collectionName => $collection) {
            /** @var CollectionInterface $collection */
            if ($collection->getStorage() === $storage) {
                $collections[$collectionName] = $collection;
            }
        }
        return $collections;
    }
public function getCollectionsByStorage ( StorageInterface $ storage ) { $ this -> initialize ( ) ; $ collections = [ ] ; foreach ( $ this -> collections as $ collectionName => $ collection ) { /** @var CollectionInterface $collection */ if ( $ collection -> getStorage ( ) === $ storage ) { $ collections [ $ collectionName ] = $ collection ; } } return $ collections ; }
Returns an array of Collection instances which use the given storage

@param StorageInterface $storage
@return array<CollectionInterface>
Returns an array of Collection instances which use the given storage