You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.6 KiB

#include <stdio.h>
#include <string.h>
#include <stdbool.h>
#include <stdlib.h>
//######### Définition des types #############
typedef struct
{
char dept[31];
int nbP;
char respAd[31];
}Departement;
typedef struct maillonDept
{
Departement d;
struct maillonDept *suiv;
}MaillonDept,*ListeDept;
typedef struct
{
char nom[31];
ListeDept lDept;
}VilleIUT;
//########## fonction commune ###############
int chargement(VilleIUT *tiut[],int tMax);
Departement lireDep(FILE *flot);
int login(void);
void globale(void);
void clearpage(void);
//########## fonction affichage ##############
void afficherPlace(Departement d);
void afficherDep(Departement d);
void afficherVilleDep(VilleIUT v);
void afficherTIUT(VilleIUT *tiut[], int tLog);
void afficherVille(VilleIUT v);
//########## fonction de mise à jour ###########
void miseAJourGlobale(VilleIUT *tiut[], int tLog);
void miseAJourNomDept(Departement d,ListeDept l);
void miseAJourResp(Departement d);
void miseAJourPlaces(Departement d);
//########## fonctions d'insertion ##############
ListeDept insererDept(ListeDept lDept, Departement d);
int insererVille(VilleIUT *tiut[], char nomV[], Departement d, int *tLog, int tMax, int pos);
//########## fonction de recherche ##############
ListeDept rechercherDept(ListeDept lDept, char dept[], int *trouve);
int rechercheIUT(VilleIUT *tiut[], int tLog, char ville[], int *trouve);
//########## fonction liste ##############
ListeDept listeDeptNouv(void);
ListeDept insererEntete(ListeDept lDept,Departement d);
ListeDept supprimerEntete(ListeDept lDept);
ListeDept supprimerDept(ListeDept lDept, Departement d);
bool vide(ListeDept lDept);
int longueur(ListeDept lDept);