36#ifndef __YTLIB_PGRAPH_H
37#define __YTLIB_PGRAPH_H
41#include "util/ytIntArray.h"
Interface class for handling graph structure.
Definition: ytPGraph.h:43
void ytPGraph_copy(ytPGraph *this, const ytPGraph *src)
Copies edges to this graph.
Definition: ytPGraph.c:164
int ytPGraph_checkEdge(const ytPGraph *this, int src, int dst)
Checks if the specified edge exists in the graph.
Definition: ytPGraph.c:112
void ytPGraph_clear(ytPGraph *this)
Removes all the edges.
Definition: ytPGraph.c:76
void ytPGraph_copyGraph(ytPGraph *this, const ytGraph *src)
Copies edges to this graph.
Definition: ytPGraph.c:186
void ytPGraph_delete(ytPGraph *this)
Deletes the ytPGraph instance.
Definition: ytPGraph.c:67
int ytPGraph_numNodes(const ytPGraph *this)
Returns the number of nodes in the graph.
Definition: ytPGraph.c:86
int ytPGraph_numParents(const ytPGraph *this, int j)
Returns the number of parents of the specified node.
Definition: ytPGraph.c:127
ytPGraph * ytPGraph_new(int nodes)
Generates the new ytPGraph instance.
Definition: ytPGraph.c:45
int ytPGraph_getParent(const ytPGraph *this, int j, int k)
Returns the parent index of the node.
Definition: ytPGraph.c:137
void ytPGraph_addEdge(ytPGraph *this, int src, int dst)
Adds an edge to the graph.
Definition: ytPGraph.c:151