public function blocks(Collection $blocks = null)
    {
        if ($blocks) {
            $this->_blocks = $blocks;
            $this->homogenize();
        } elseif ($this->_blocks === null) {
            $this->_prepareBlocks();
        }

        return $this->_blocks;
    }
public function blocks(Collection $blocks = null)
    {
        if ($blocks) {
            $this->_blocks = $blocks;
            $this->homogenize();
        } elseif ($this->_blocks === null) {
            $this->_prepareBlocks();
        }

        return $this->_blocks;
    }
public function blocks ( Collection $ blocks = null ) { if ( $ blocks ) { $ this -> _blocks = $ blocks ; $ this -> homogenize ( ) ; } elseif ( $ this -> _blocks === null ) { $ this -> _prepareBlocks ( ) ; } return $ this -> _blocks ; }
Gets or sets the block collection of this region.

When passing a collection of blocks as first argument, all blocks in the
collection will be homogenized, see homogenize() for details.

@param \Cake\Collection\Collection $blocks Blocks collection if you want to
overwrite current collection, leave empty to return current collection
@return \Cake\Collection\Collection
@see \Block\View\Region::homogenize()
Gets or sets the block collection of this region .