228 |
jpm |
1 |
<?php
|
233 |
jpm |
2 |
$temps_debut = microtime(true);
|
228 |
jpm |
3 |
// Encodage : UTF-8
|
|
|
4 |
// +-------------------------------------------------------------------------------------------------------------------+
|
|
|
5 |
/**
|
|
|
6 |
* Serveur
|
|
|
7 |
*
|
|
|
8 |
* Description : initialise le chargement et l'exécution des services web.
|
|
|
9 |
*
|
|
|
10 |
//Auteur original :
|
|
|
11 |
* @author Jean-Pascal MILCENT <jpm@tela-botanica.org>
|
|
|
12 |
* @copyright Tela-Botanica 1999-2008
|
|
|
13 |
* @licence GPL v3 & CeCILL v2
|
|
|
14 |
* @version $Id$
|
|
|
15 |
*/
|
|
|
16 |
// +-------------------------------------------------------------------------------------------------------------------+
|
|
|
17 |
|
|
|
18 |
// Le fichier autoload.inc.php du Framework de Tela Botanica doit être appelée avant tout autre chose dans l'application.
|
|
|
19 |
// Sinon, rien ne sera chargé.
|
|
|
20 |
// Chemin du fichier chargeant le framework requis
|
|
|
21 |
$framework = dirname(__FILE__).DIRECTORY_SEPARATOR.'framework.php';
|
|
|
22 |
if (!file_exists($framework)) {
|
|
|
23 |
$e = "Veuillez paramétrer l'emplacement et la version du Framework dans le fichier $framework";
|
|
|
24 |
trigger_error($e, E_USER_ERROR);
|
|
|
25 |
} else {
|
|
|
26 |
// Inclusion du Framework
|
|
|
27 |
require_once $framework;
|
|
|
28 |
// Ajout d'information concernant cette application
|
|
|
29 |
Framework::setCheminAppli(__FILE__);// Obligatoire
|
|
|
30 |
Framework::setInfoAppli(Config::get('info'));
|
233 |
jpm |
31 |
|
228 |
jpm |
32 |
// Initialisation et lancement du serveur
|
|
|
33 |
$Serveur = new Serveur();
|
|
|
34 |
$Serveur->executer();
|
233 |
jpm |
35 |
$temps_fin = microtime(true);
|
|
|
36 |
echo 'Temps d\'execution : '.round($temps_fin - $temps_debut, 4);
|
228 |
jpm |
37 |
}
|
|
|
38 |
?>
|