public function getCards($addressbookId)
    {
        $stmt = $this->pdo->prepare('SELECT id, uri, lastmodified, etag, size FROM '.$this->cardsTableName.' WHERE addressbookid = ?');
        $stmt->execute([$addressbookId]);

        $result = [];
        while ($row = $stmt->fetch(\PDO::FETCH_ASSOC)) {
            $row['etag'] = '"'.$row['etag'].'"';
            $row['lastmodified'] = (int) $row['lastmodified'];
            $result[] = $row;
        }

        return $result;
    }
public function getCards($addressbookId)
    {
        $stmt = $this->pdo->prepare('SELECT id, uri, lastmodified, etag, size FROM '.$this->cardsTableName.' WHERE addressbookid = ?');
        $stmt->execute([$addressbookId]);

        $result = [];
        while ($row = $stmt->fetch(\PDO::FETCH_ASSOC)) {
            $row['etag'] = '"'.$row['etag'].'"';
            $row['lastmodified'] = (int) $row['lastmodified'];
            $result[] = $row;
        }

        return $result;
    }
public function getCards ( $ addressbookId ) { $ stmt = $ this -> pdo -> prepare ( 'SELECT id, uri, lastmodified, etag, size FROM ' . $ this -> cardsTableName . ' WHERE addressbookid = ?' ) ; $ stmt -> execute ( [ $ addressbookId ] ) ; $ result = [ ] ; while ( $ row = $ stmt -> fetch ( \ PDO :: FETCH_ASSOC ) ) { $ row [ 'etag' ] = '"' . $ row [ 'etag' ] . '"' ; $ row [ 'lastmodified' ] = ( int ) $ row [ 'lastmodified' ] ; $ result [ ] = $ row ; } return $ result ; }
Returns all cards for a specific addressbook id.

This method should return the following properties for each card:
* carddata - raw vcard data
* uri - Some unique url
* lastmodified - A unix timestamp

It's recommended to also return the following properties:
* etag - A unique etag. This must change every time the card changes.
* size - The size of the card in bytes.

If these last two properties are provided, less time will be spent
calculating them. If they are specified, you can also ommit carddata.
This may speed up certain requests, especially with large cards.

@param mixed $addressbookId

@return array
Returns all cards for a specific addressbook id .