#include <PsNameServer.h>#include <stdlib.h>#include <iostream>#include <sys/types.h>#include <unistd.h>#include <math.h>#include <PsController.h>#include "PsMultiThreadedController.h"#include <PsnTimerControleur.h>#include <PsKernelObjectAbstractFactory.h>#include <PsMonoProcessController.h>#include <stdio.h>#include <string>#include <PsException.h>#include <PsArbreSimul.h>#include <PsString.h>Include dependency graph for mainDemoMonoProc.cxx:

Go to the source code of this file.
Functions | |
| bool | testSG3 (const char *fName) |
| PsString | nomPVM (const PsString fName) |
| void | usage () |
| void | openMaskMain (int argc, char *argv[]) |
Variables | |
| char * | nomExecutable = "rien" |
|
|
Definition at line 109 of file mainDemoMonoProc.cxx. References PsString::getCString(). Referenced by openMaskMain().
00109 {
00110 PsString nom = fName ;
00111 FILE * f = fopen (fName.getCString (), "r") ;
00112 if (f == NULL) {
00113 // en cas d'échec, on se place dans le répertoire qui va bien
00114 //PsString workingDir = ("${HOME}/pvm3/bin/$PVM_ARCH") ;
00115 PsString nomFich = getenv ("HOME") ;
00116 nomFich = nomFich + "/pvm3/bin/" + getenv ("PVM_ARCH") + "/"
00117 + fName ;
00118 f = fopen (nomFich.getCString (), "r") ;
00119 if (f != NULL) {
00120 nom = nomFich ;
00121 } else {
00122 cerr << "nomPVM : impossible d'ouvrir le fichier " << fName << endl ;
00123 }
00124 }
00125 return nom ;
00126 }
|
|
||||||||||||
|
Definition at line 144 of file mainDemoMonoProc.cxx. References map< PsName, typeObjet * >::begin(), map< PsName, typeObjet * >::end(), PsString::findCaracter(), PsString::getCString(), PsController::init(), nomExecutable, nomPVM(), PsDate, PsController::run(), testSG3(), and usage(). |
|
|
Definition at line 80 of file mainDemoMonoProc.cxx. References PsString::getCString(). Referenced by openMaskMain().
00082 {
00083 FILE * f = fopen (fName, "r") ;
00084 if (f == NULL) {
00085 // en cas d'échec, on se place dans le répertoire qui va bien
00086 //PsString workingDir = ("${HOME}/pvm3/bin/$PVM_ARCH") ;
00087 PsString nomFich = getenv ("HOME") ;
00088 nomFich = nomFich + "/pvm3/bin/" + getenv ("PVM_ARCH") + "/"
00089 + PsString (fName) ;
00090 f = fopen (nomFich.getCString (), "r") ;
00091 if (f == NULL) {
00092 cerr << "impossible d'ouvrir le fichier " << fName << " ou " << nomFich << endl ;
00093 exit(-1) ;
00094 }
00095 }
00096 // vérification de l'entête
00097 char tmp[200];
00098 fread(tmp,1,5,f);
00099 tmp[5] = 0x0;
00100 if (strcmp(tmp,"//sG3"))
00101 {
00102 fclose(f);
00103 return false;
00104 }
00105 fclose(f);
00106 return true;
00107 }
|
|
|
Definition at line 128 of file mainDemoMonoProc.cxx. Referenced by openMaskMain().
00129 {
00130 cerr<< "usage: versMonoProc nomFichierConfig [option]"<<endl
00131 << " avec option= GUI | Bench [nomFichier] | PVM [latence]"
00132 #ifdef _REACT
00133 <<"|React [nbProc]"<<endl
00134 <<"avec nbProc entre 1 et nombre de processeur de la machine moins 1"
00135 #endif
00136 <<endl;
00137 exit(1);
00138 }
|
|
|
Definition at line 79 of file mainDemoMonoProc.cxx. Referenced by openMaskMain(). |
| Documentation generated on Mon Nov 25 15:25:03 2002 |
Generated with doxygen 1.2.12 by Dimitri van Heesch , 1997-2001 |