-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinputOutput.h
More file actions
32 lines (23 loc) · 966 Bytes
/
inputOutput.h
File metadata and controls
32 lines (23 loc) · 966 Bytes
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
#ifndef SEMESTRALKA_INPUTOUTPUT_H
#define SEMESTRALKA_INPUTOUTPUT_H
#define INITIAL_SIZE 10
#define MAXLENGTH 4096
#define NODES_ID "id,WKT\n"
#define EDGES_ID "id,source,target,capacity,isvalid,WKT\n"
#define VALID "True"
#define INVALID "False"
#include "structs.h"
/* ____________________________________________________________________________
Function Prototypes
____________________________________________________________________________
*/
graphNode *createNode(char *input);
void freeGraphNode(graphNode **nodePointer);
void freeGraphEdge(graphEdge **edgePointer);
graphEdge *createEdge(char *input, int workWithInvalid);
hashTable *loadNodes(char *inputName);
hashTable *loadEdges(char *inputName, int workWithInvalid, int tableSize);
int writeToOutputFile(char *fileName, graph *graphPointer);
int compareEdgeById(const void *a, const void *b);
int compareEdgeBySource(const void *a, const void *b);
#endif