__construct() public méthode

Constructs a standard page class to represent a wiki page.
public __construct ( string $pagename )
$pagename string The name of the page to represent.
 /**
  * Construct a standard history page class to represent an old
  * version of a wiki page.
  *
  * @param string  $pagename    The name of the page to load.
  * @param integer $version     The version of the page to load.
  *
  * @throws Wicked_Exception
  */
 public function __construct($pagename, $version = null)
 {
     if (empty($version)) {
         parent::__construct($pagename);
         return;
     }
     // Retrieve the version.
     $pages = $GLOBALS['wicked']->retrieveHistory($pagename, $version);
     // If it didnt find one, return an error.
     if (empty($pages[0])) {
         throw new Wicked_Exception(_("History page not found"));
     }
     $this->_page = $pages[0];
 }