Google\Spreadsheet\CellFeed::getEntries PHP Method

getEntries() public method

Get the feed entries
public getEntries ( ) : array
return array \Google\Spreadsheet\CellEntry
    public function getEntries()
    {
        if (count($this->entries) > 0) {
            return $this->entries;
        }
        $postUrl = $this->getPostUrl();
        foreach ($this->xml->entry as $entry) {
            $cell = new CellEntry($entry, $postUrl);
            $this->entries[$cell->getCellIdString()] = $cell;
        }
        return $this->entries;
    }

Usage Example

 public function testGetEntries()
 {
     $feed = new CellFeed($this->getSimpleXMLElement("cell-feed"));
     $this->assertEquals(6, count($feed->getEntries()));
     // The same call needs to be made again to test returning the
     // cached version of the entries. required for 100% coverage
     $this->assertEquals(6, count($feed->getEntries()));
 }
All Usage Examples Of Google\Spreadsheet\CellFeed::getEntries