diff --git a/src/partie1/saeP1.c b/src/partie1/saeP1.c index b400353..e191900 100644 --- a/src/partie1/saeP1.c +++ b/src/partie1/saeP1.c @@ -7,7 +7,7 @@ //Partie Consultant. -void menuUser(VilleIUT* lvIUT[],int tlogi, int CandidOpen, candidat* tcandidat[]) +void menuUser(VilleIUT* lvIUT[],int tlogi, int CandidOpen, candidat tcandidat[]) { int quit=0, ck=0, act; while(!quit) diff --git a/src/partie1/saeP1.h b/src/partie1/saeP1.h index af6e87e..7d2606a 100644 --- a/src/partie1/saeP1.h +++ b/src/partie1/saeP1.h @@ -47,7 +47,7 @@ typedef struct * \param [in] CandidOpen Entier contenant 1 si la phase de canditatures est ouverte, 0 sinon. * \param [in] tcandidat Tableau contenant les candidats. */ -void menuUser(VilleIUT* lvIUT[],int tlogi, int CandidOpen, candidat *tcandidat[]); +void menuUser(VilleIUT* lvIUT[],int tlogi, int CandidOpen, candidat tcandidat[]); /* Menu pour les utilisateurs du système, les candidats. Entrée : diff --git a/src/partie2/saeP2.h b/src/partie2/saeP2.h index 24cee61..6b8b30a 100644 --- a/src/partie2/saeP2.h +++ b/src/partie2/saeP2.h @@ -1,3 +1,18 @@ +/** +*\file saeP2.h +*\brief Liste des fonctions utilisées dans la partie 2. +*\author Van Brabant.J Champeau.Y +*\date 13 janvier 2023 +* +*Fichier regroupant les prototypes des fonctions utilisées par l'application dans la partie 2 de la SAE. +*/ + + + +/** + * \struct voeu + * \brief Structure correspondant à une candidature pour un département. +*/ typedef struct { char ville[31]; @@ -6,6 +21,12 @@ typedef struct int vcand; }voeu; + + +/** + * \struct candidat + * \brief Structure correspondant à un candidat. +*/ typedef struct { int numcandid; @@ -16,6 +37,14 @@ typedef struct voeu* TabVoeu[20]; }candidat; + + +/** +* \brief fonction chargeant le fichier des IUTs. +* \param [out] CandidOpen Entier contenant 1 si la phase de canditatures est ouverte, 0 sinon. +* \param [out] nbcandidat nombre de candidats enregistrés. +* \return le tableau de candidats. +*/ candidat* LoadCandid(int *CandidOpen,int* nbcandidat); /* Charge le fichier candidature @@ -25,6 +54,15 @@ candidat* LoadCandid(int *CandidOpen,int* nbcandidat); Sortie : tableau des candidats. */ + + + +/** +* \brief sauvegarde le tableau de candidats dans le fichier. +* \param [in] nbcandidat taille logique du tableau et nombre de candidats. +* \param [in] tcandidat Tableau contenant les candidats. +* \param [in] CandidOpen Entier contenant 1 si la phase de canditatures est ouverte, 0 sinon. +*/ void SaveCandid(int nbcandidat,candidat *tcandidat,int CandidOpen); /* Sauvegarde le fichier candidature @@ -34,6 +72,15 @@ void SaveCandid(int nbcandidat,candidat *tcandidat,int CandidOpen); Booléen gérant l'ouverture ou non des candidatures CandidOpen; Sortie : Aucune */ + + + +/** +* \brief recherche et affiche un candidat dans le tableau des candidats. +* \param [in] ID identifiant du candidat à chercher. +* \param [in] nbcandidat taille logique du tableau et nombre de candidats. +* \param [in] tcandidat Tableau contenant les candidats. +*/ void RechercheCandidat(int ID, int nbcandidat,candidat* tcandidat); /* Recherche et affiche un candidat selon son ID @@ -43,6 +90,14 @@ void RechercheCandidat(int ID, int nbcandidat,candidat* tcandidat); tableau des candidats tcandidats. Sortie : Aucune */ + + + +/** +* \brief affiche les candidats. +* \param [in] nbcandidat taille logique du tableau et nombre de candidats. +* \param [in] tcandidat Tableau contenant les candidats. +*/ void ListeCandidat(int nbcandidat,candidat *tcandidat); /* Liste tout les candidats. @@ -51,6 +106,16 @@ void ListeCandidat(int nbcandidat,candidat *tcandidat); tableau des candidats tcandidats. Sortie : Aucune */ + + + +/** +* \brief permet de faire une candidature pour un département. +* \param [in] tiut Tableau contenant les IUTs. +* \param [in] tlogi taille logique du tableau. +* \param [in,out] tcandidat Tableau contenant les candidats. +* \param [in] numcandid numéro du candidat à chercher. +*/ void Candidater(VilleIUT* tiut[],int *tlogi, candidat* tcandidat,int numcandid); /* Permet de candidater dans un IUT