TaskIdList.h File Reference

Definition of data structures of a task id list. More...

#include <stdio.h>

Include dependency graph for TaskIdList.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  TaskIdList
 Task Id List data structure. More...

Defines

#define WRITE_TIDL(outputFile, list)   writeTaskIdList(outputFile, list)
#define READ_TIDL(inputFile)   readTaskIdList(inputFile)

Functions

TaskIdListtaskIdListCreate (int cap_inicial)
 Cria um vetor de documentos.
int taskIdListAdd (TaskIdList *vet, int doc)
 Adiciona um documento ao vetor.
int taskIdListGetSize (TaskIdList *vet)
 Retorna o tamanho de um vetor de documentos.
int taskIdListGet (TaskIdList *vet, int pos)
 Retorna um ponteiro para a posi??o pos do vetor de documentos vet.
int taskIdListGetLast (TaskIdList *vet)
 Retorna um ponteiro para a ?ltima posi??o do vetor de documentos vet.
int * taskIdListToArray (TaskIdList *list, int *listSize)
int taskIdListCompare (TaskIdList *list1, TaskIdList *list2)
 Compares two TaskIdList.
void taskIdListDestroy (TaskIdList *vet)
 Destroy a taskId list.
TaskIdListtaskIdListIntersection (TaskIdList *a, TaskIdList *b)
 This function assume that.
TaskIdListtaskIdListCopy (TaskIdList *list)
void taskIdListSortAscendig (TaskIdList *list)
 Sort the list ids in ascending order.
int writeTaskIdList (FILE *outputFile, void *list)
void * readTaskIdList (FILE *inputFile)
int packTaskIdList (void *list)
void * unpackTaskIdList ()


Detailed Description

Definition of data structures of a task id list.

Definition in file TaskIdList.h.


Define Documentation

#define READ_TIDL inputFile   )     readTaskIdList(inputFile)
 

Definition at line 15 of file TaskIdList.h.

#define WRITE_TIDL outputFile,
list   )     writeTaskIdList(outputFile, list)
 

Definition at line 14 of file TaskIdList.h.


Function Documentation

int packTaskIdList void *  list  ) 
 

void* readTaskIdList FILE *  inputFile  ) 
 

Definition at line 270 of file TaskIdList.c.

References READ_BEGIN, READ_NUM, taskIdListAdd(), and taskIdListCreate().

Referenced by readChildTask(), and readTask().

Here is the call graph for this function:

int taskIdListAdd TaskIdList vet,
int  doc
 

Adiciona um documento ao vetor.

Caso o vetor n?o tenha a capacidade necess?ria, sua capacidade ser? dobrada (de acordo com a pol?tica de realoca??o exponencial).

Parameters:
vet Vetor onde o documento ser? acrescentado.
doc Documento a ser acrescentado.
freq Freq??ncia do documento.
Returns:
Posi??o do documento no vetor.

Definition at line 65 of file TaskIdList.c.

References TaskIdList::capacity, TaskIdList::size, and TaskIdList::vetor.

Referenced by addTaskToDependsOnMe(), cacheEndTask(), cacheRecoverTasks(), getFinishedTasks(), readTaskIdList(), and taskIdListCopy().

int taskIdListCompare TaskIdList list1,
TaskIdList list2
 

Compares two TaskIdList.

Returns -1, 0 or +1 if the list "list1" is found, respectivelly, to be less than, to match, or be greater than "list2". Comparison semantics is the same of strcmp().

Definition at line 133 of file TaskIdList.c.

References TaskIdList::size, and TaskIdList::vetor.

Referenced by compareTasks().

TaskIdList* taskIdListCopy TaskIdList list  ) 
 

Definition at line 182 of file TaskIdList.c.

References taskIdListAdd(), taskIdListCreate(), taskIdListGet(), and taskIdListGetSize().

Referenced by setTaskDependsOnMe(), and setTaskMyDeps().

Here is the call graph for this function:

TaskIdList* taskIdListCreate int  cap_inicial  ) 
 

Cria um vetor de documentos.

Definition at line 45 of file TaskIdList.c.

References TaskIdList::capacity, TaskIdList::size, taskIdListGetMinCpacity(), and TaskIdList::vetor.

Referenced by addTaskToDependsOnMe(), getFinishedTasks(), initCacheStruct(), readTaskIdList(), taskIdListCopy(), and taskIdListIntersection().

Here is the call graph for this function:

void taskIdListDestroy TaskIdList vet  ) 
 

Destroy a taskId list.

Definition at line 172 of file TaskIdList.c.

References TaskIdList::vetor.

Referenced by destroyCache(), destroyTask(), readChildTask(), readTask(), and taskMove().

int taskIdListGet TaskIdList vet,
int  pos
 

Retorna um ponteiro para a posi??o pos do vetor de documentos vet.

Definition at line 95 of file TaskIdList.c.

References TaskIdList::vetor.

Referenced by cacheEndTask(), cacheGetTaskDeps(), cacheRecoverTasks(), taskIdListCopy(), and writeTaskIdList().

int taskIdListGetLast TaskIdList vet  ) 
 

Retorna um ponteiro para a ?ltima posi??o do vetor de documentos vet.

Definition at line 102 of file TaskIdList.c.

References TaskIdList::size, and TaskIdList::vetor.

int taskIdListGetSize TaskIdList vet  ) 
 

Retorna o tamanho de um vetor de documentos.

Definition at line 85 of file TaskIdList.c.

References TaskIdList::size.

Referenced by cacheEndTask(), cacheGetTaskDeps(), cacheRecoverTasks(), compareTasks(), taskIdListCopy(), and writeTaskIdList().

TaskIdList* taskIdListIntersection TaskIdList a,
TaskIdList b
 

This function assume that.

Definition at line 199 of file TaskIdList.c.

References TaskIdList::size, taskIdListCreate(), and TaskIdList::vetor.

Here is the call graph for this function:

void taskIdListSortAscendig TaskIdList list  ) 
 

Sort the list ids in ascending order.

Definition at line 245 of file TaskIdList.c.

References TaskIdList::size, and TaskIdList::vetor.

Referenced by cacheRecoverTasks().

int* taskIdListToArray TaskIdList list,
int *  listSize
 

Definition at line 110 of file TaskIdList.c.

References TaskIdList::size, and TaskIdList::vetor.

Referenced by cacheGetFinishedTasks().

void* unpackTaskIdList  ) 
 

int writeTaskIdList FILE *  outputFile,
void *  list
 

Definition at line 256 of file TaskIdList.c.

References taskIdListGet(), taskIdListGetSize(), and WRITE_NUM.

Referenced by writeChildTask(), and writeTask().

Here is the call graph for this function:


Generated on Tue Jan 17 19:27:45 2006 for Void by  doxygen 1.4.6