protected function _preloadData($stories)
    {
        $node_ids = array();
        $comment_ids = array();
        foreach ($stories as $story) {
            $columns = $story->getRowData();
            $node_ids = array_merge($node_ids,
                    $story->getIds('owner'),
                    $story->getIds('subject'),
                    $story->getIds('target'),
                    $story->getIds('object')
                    );
            $comment_ids = array_merge($comment_ids, $story->getIds('comment'));
        }
        $node_ids = array_unique($node_ids);
        $query = $this->getService('repos://site/base.comment')->getQuery()->where('parent.id', 'IN', $node_ids);
        $author_ids = $query->fetchValues('author.id');
        $node_ids = array_unique(array_merge($node_ids, $author_ids, $comment_ids));

        //we don't any behavior messes around with the fetched stories              
        $query = $this->getService('repos://site/base.node')->getQuery()->id($node_ids)->disableChain();
        $query->columns('*');
        $nodes = $query->fetchSet();
        $nodes = AnHelperArray::indexBy($nodes, 'id');
        $this->_loaded_nodes = $nodes;
    }
protected function _preloadData($stories)
    {
        $node_ids = array();
        $comment_ids = array();
        foreach ($stories as $story) {
            $columns = $story->getRowData();
            $node_ids = array_merge($node_ids,
                    $story->getIds('owner'),
                    $story->getIds('subject'),
                    $story->getIds('target'),
                    $story->getIds('object')
                    );
            $comment_ids = array_merge($comment_ids, $story->getIds('comment'));
        }
        $node_ids = array_unique($node_ids);
        $query = $this->getService('repos://site/base.comment')->getQuery()->where('parent.id', 'IN', $node_ids);
        $author_ids = $query->fetchValues('author.id');
        $node_ids = array_unique(array_merge($node_ids, $author_ids, $comment_ids));

        //we don't any behavior messes around with the fetched stories              
        $query = $this->getService('repos://site/base.node')->getQuery()->id($node_ids)->disableChain();
        $query->columns('*');
        $nodes = $query->fetchSet();
        $nodes = AnHelperArray::indexBy($nodes, 'id');
        $this->_loaded_nodes = $nodes;
    }
protected function _preloadData ( $ stories ) { $ node_ids = array ( ) ; $ comment_ids = array ( ) ; foreach ( $ stories as $ story ) { $ columns = $ story -> getRowData ( ) ; $ node_ids = array_merge ( $ node_ids , $ story -> getIds ( 'owner' ) , $ story -> getIds ( 'subject' ) , $ story -> getIds ( 'target' ) , $ story -> getIds ( 'object' ) ) ; $ comment_ids = array_merge ( $ comment_ids , $ story -> getIds ( 'comment' ) ) ; } $ node_ids = array_unique ( $ node_ids ) ; $ query = $ this -> getService ( 'repos://site/base.comment' ) -> getQuery ( ) -> where ( 'parent.id' , 'IN' , $ node_ids ) ; $ author_ids = $ query -> fetchValues ( 'author.id' ) ; $ node_ids = array_unique ( array_merge ( $ node_ids , $ author_ids , $ comment_ids ) ) ; //we don't any behavior messes around with the fetched stories               $ query = $ this -> getService ( 'repos://site/base.node' ) -> getQuery ( ) -> id ( $ node_ids ) -> disableChain ( ) ; $ query -> columns ( '*' ) ; $ nodes = $ query -> fetchSet ( ) ; $ nodes = AnHelperArray :: indexBy ( $ nodes , 'id' ) ; $ this -> _loaded_nodes = $ nodes ; }
Loads all the necessary objects after each collection fetch.

@param AnDomainEntityset $stories
Loads all the necessary objects after each collection fetch .