-
Notifications
You must be signed in to change notification settings - Fork 0
/
Random_data.h
64 lines (45 loc) · 1.47 KB
/
Random_data.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
/*
* Random_data.h
*
* Created on: Mar 16, 2015
* Author: gui
*/
#ifndef RANDOM_DATA_H_
#define RANDOM_DATA_H_
#pragma once
#include "Escola.h"
void generateRandomEntriesByQnt(int qntEntries,int blockSize);
void generateRandomEntriesByQnt2(int qntEntries);
void createIndexTable();
void insert();
void read();
void generateRandomEntriesBlock(int size, int blockSize);
void readRandomEntriesBlock(int blockSize);
void executionTime(clock_t time_start, clock_t time_end);
void printAllEntries();
void randomAluno(ppALUNO ppAluno);
void randomName(char* name);
void randomDate(pDATANASCIMENTO data);
void randomDisciplina(char* place);
void intercalateSort(int blockSize, int k_vias, int cmpKey1, int cmpKey2);
int cmpEncapsulate(void *p1, void *p2, void *typeCmp);
int cmpChar(char *first, char *second);
int cmpDate(pDATANASCIMENTO first, pDATANASCIMENTO second);
void readRandomEntriesBlockSorted(int blockSize);
typedef struct STACK *pSTACK;
typedef struct STACK **ppSTACK;
typedef struct STACK{
pREGISTRO registro;
pSTACK next;
}STACK;
typedef struct QUEUE *pQUEUE;
typedef struct QUEUE **ppQUEUE;
typedef struct QUEUE{
pREGISTRO registro;
pQUEUE next;
}QUEUE;
void pop(ppSTACK stack, ppREGISTRO elem);
void push(ppSTACK stack, ppSTACK newStack, pREGISTRO elem);
void insertQueue(ppQUEUE queue, pREGISTRO elem);
void sortStack(pSTACK first , pSTACK second, ppQUEUE queue,int(* cmp)(void *p1, void *p2, void *typeCmp), int cmpKey1, int cmpKey2);
#endif /* RANDOM_DATA_H_ */