Big refactoring of the Json handling, I followed what I did from OPDS. It doesn't still feel right but I think it's better.

This commit is contained in:
Sébastien Lucas 2014-01-07 21:22:35 +01:00
parent 3f5dd74361
commit 91aa062860
5 changed files with 219 additions and 216 deletions

View file

@ -337,10 +337,6 @@ class Entry
return "#";
}
public function getContentArray () {
return array ( "title" => $this->title, "content" => $this->content, "navlink" => $this->getNavLink () );
}
public function __construct($ptitle, $pid, $pcontent, $pcontentType, $plinkArray, $pclass = "") {
global $config;
$this->title = $ptitle;
@ -375,12 +371,6 @@ class EntryBook extends Entry
$this->localUpdated = $pbook->timestamp;
}
public function getContentArray () {
$entry = array ( "title" => $this->title);
$entry ["book"] = $this->book->getContentArray ();
return $entry;
}
public function getCoverThumbnail () {
foreach ($this->linkArray as $link) {
if ($link->rel == Link::OPDS_THUMBNAIL_TYPE)