Cadastro de Estudantes v0.0.1
Gera uma lista ligada de estudantes.

lista.h

Ir para a documentação deste ficheiro.
00001 
00015 /* garanta a nao inclusao recursiva */
00016 #ifndef __LISTA_H__
00017 #define __LISTA_H__     1
00018 
00019 #include "mycommdef.h"                  /* inclusao de definoces comuns a outros modulos */
00020 #include "pilha.h"
00021 
00023 #define TAM_NOME        64
00024 
00025 #define MAX_DISCIPLINAS 5
00026 
00028 struct TipoItem {
00029     char        nome[TAM_NOME];                                 
00030     int         disciplinas[MAX_DISCIPLINAS];   
00031     TipoItem    brinde[TAM_ELEMENTO];                   
00032 };
00033 
00035 struct TipoElementoLista {
00036     struct TipoItem     Elemento;               
00037     struct TipoElementoLista *pProx;    
00038     struct TipoElementoLista *pAnt;             
00039 };
00040 
00042 struct TipoLista {
00043     struct  TipoElementoLista *pHeadNodo;       
00044     UINT    tamanho;                                            
00045 };
00046 
00047 /* prototipos das funcoes */
00048 bool        InicLista(struct TipoLista*);
00049 bool        VaziaLista(struct TipoLista*);
00050 UINT        TamanhoLista(struct TipoLista*);
00051 bool        InsereLista(struct TipoItem*, struct TipoLista*);
00052 void        ImprimeLista(struct TipoLista*);
00053 struct TipoItem RemoveLista(struct TipoElementoLista*, struct TipoLista*);
00054 
00055 #endif /* __LISTA_H__ */
00056 
 Tudo Classes Ficheiros Funções Variáveis Definições de tipos Enumerações Valores da enumeração Macros