utilitaires.h 744 B

12345678910111213141516171819202122
  1. #ifndef UTILITAIRES_H_INCLUDED
  2. #define UTILITAIRES_H_INCLUDED
  3. #include "type_def.h"
  4. #include <string>
  5. /// Génère une personne au hasard
  6. Personne genererPersonne(std::string* listNom, std::string* listPrenom, int nbNom, int nbPrenom);
  7. /// Lit les noms d'un fichier, les ajoute dans le tableau passsé en argument et renvoie le cardinal de ce tableau
  8. int initTabNomPrenom(vectNom tab, std::string fichier);
  9. /// Genère 10000 personnes
  10. void genererRepertoire(vectPersonne tab, std::string* listNom, std::string* listPrenom, int nbNom, int nbPrenom);
  11. /// Test d'égalité
  12. bool egalitePersonne(Personne a, Personne b);
  13. /// Test de comparaison : retourne a < b
  14. bool comparerPersonne(Personne a, Personne b);
  15. #endif // UTILITAIRES_H_INCLUDED