protected function getCollection()
    {
        $collection = [];

        $class = $this->getCollectionClassName();
        if ($class) {
            /** @var Collection $collection */
            $collection = new $class();
            $collection->setModel($this->class);
            $collection->setFormatter($this);
        }

        return $collection;
    }
protected function getCollection()
    {
        $collection = [];

        $class = $this->getCollectionClassName();
        if ($class) {
            /** @var Collection $collection */
            $collection = new $class();
            $collection->setModel($this->class);
            $collection->setFormatter($this);
        }

        return $collection;
    }
protected function getCollection ( ) { $ collection = [ ] ; $ class = $ this -> getCollectionClassName ( ) ; if ( $ class ) { /** @var Collection $collection */ $ collection = new $ class ( ) ; $ collection -> setModel ( $ this -> class ) ; $ collection -> setFormatter ( $ this ) ; } return $ collection ; }
Returns a Collection object or a simple array.

@return Collection|array
Returns a Collection object or a simple array .