src/extensions/PageSlicesExtension.php
public function getSlices()
    {
        $controllers = ArrayList::create();

        if(
            $this->owner instanceof \VirtualPage
            && ($original = $this->owner->CopyContentFrom())
            && $original->hasExtension(self::class))
        {
            $slices = $original->PageSlices();
        } else {
            $slices = $this->owner->PageSlices();
        }

        if ($slices) {
            /** @var PageSlice $slice */
            foreach ($slices as $slice) {
                $controller = $slice->getController();
                $controller->init();
                $controllers->push($controller);
            }
            return $controllers;
        }

        return $controllers;
    }
public function getSlices()
    {
        $controllers = ArrayList::create();

        if(
            $this->owner instanceof \VirtualPage
            && ($original = $this->owner->CopyContentFrom())
            && $original->hasExtension(self::class))
        {
            $slices = $original->PageSlices();
        } else {
            $slices = $this->owner->PageSlices();
        }

        if ($slices) {
            /** @var PageSlice $slice */
            foreach ($slices as $slice) {
                $controller = $slice->getController();
                $controller->init();
                $controllers->push($controller);
            }
            return $controllers;
        }

        return $controllers;
    }
public function getSlices ( ) { $ controllers = ArrayList :: create ( ) ; if ( $ this -> owner instanceof \ VirtualPage && ( $ original = $ this -> owner -> CopyContentFrom ( ) ) && $ original -> hasExtension ( self :: class ) ) { $ slices = $ original -> PageSlices ( ) ; } else { $ slices = $ this -> owner -> PageSlices ( ) ; } if ( $ slices ) { /** @var PageSlice $slice */ foreach ( $ slices as $ slice ) { $ controller = $ slice -> getController ( ) ; $ controller -> init ( ) ; $ controllers -> push ( $ controller ) ; } return $ controllers ; } return $ controllers ; }
Get the slice controllers

@return ArrayList
Get the slice controllers