/** * Creates a LibraryBook out of a book instance, if needed. * * @param Book $book Or descendant * @return LibraryBook */ private function libraryBook($book) { if (!$book instanceof LibraryBook) { $book = LibraryBook::createFromBook($book); } return $book; }
function __construct() { self::$tree = array(); $this->treecate = array(); }