digraph/directed_graph.c
/*
 * Creates and returns a Directed Graph pointer. The int dataSize parameter is
 * the number of bytes of the data type to be stored in the DirectedGraph. The
 * number of bytes can be retrieved from the "sizeof(type)" function where
 * "type" is the data type ot be stored in the DirectedGraph. 
 */
Creates and returns a Directed Graph pointer. The int dataSize parameter is
the number of bytes of the data type to be stored in the DirectedGraph. The
number of bytes can be retrieved from the "sizeof(type)" function where
"type" is the data type ot be stored in the DirectedGraph.
Creates and returns a Directed Graph pointer . The int dataSize parameter is the number of bytes of the data type to be stored in the DirectedGraph . The number of bytes can be retrieved from the " sizeof ( type ) " function where " type " is the data type ot be stored in the DirectedGraph .
DirectedGraph* initialize_digraph(int dataSize, char* dataTypeName)
{
	DirectedGraph* graph = malloc(sizeof(*graph));
	if(graph == NULL)
		return NULL;
	graph->vertexList      = linked_list_initialize(sizeof(Vertex), dataTypeName);
	graph->valueSize       = dataSize;
	graph->adjacencyMatrix = NULL;
	return graph;
}
DirectedGraph * initialize_digraph ( int dataSize , char * dataTypeName ) { DirectedGraph * graph = malloc ( sizeof ( * graph ) ) ; if ( graph == NULL ) return NULL ; graph -> vertexList = linked_list_initialize ( sizeof ( Vertex ) , dataTypeName ) ; graph -> valueSize = dataSize ; graph -> adjacencyMatrix = NULL ; return graph ; }
Creates and returns a Directed Graph pointer.
Creates and returns a Directed Graph pointer .
// If allocation request unsuccessful, then return NULL.	 // Initialize the linkedList struct and assign the valueSize variable.