* @author Jean-Pascal MILCENT * @author Delphine CAUQUIL * @copyright 2011 Tela-Botanica * @license http://www.gnu.org/licenses/gpl.html Licence GNU-GPL-v3 * @license http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL-v2 * @version $Id$ */ class FicheMetadonnees extends aControleur { private $projet = ''; private $serviceMetaDonnees; public function __construct($metadonnees = null) { $this->capturerParametres(); $this->serviceMetaDonnees = (is_null($this->serviceMetaDonnees)) ? new MetaDonnees($this->projet) : $metadonnees; } public function executerActionParDefaut() { $this->executerAffichageMetaDonnees(); } public function chargerMetadonneesHtml() { $donnees['metadonnees'] = $this->serviceMetaDonnees->getMetaDonnees(); $html = $this->getVue(dirname(__FILE__).'/squelettes/metadonnees', $donnees); return $html; } public function executerAffichageMetaDonnees($donnees) { header('Content-type: text/html; charset=UTF-8'); $html = $this->chargerMetadonneesHtml(); echo $html; exit; } private function capturerParametres() { if (isset($_GET['projet'])) { $this->projet = $_GET['projet']; } } } ?>