Sturk 1.0.2
Publish-subscribe C implementation.
|
Vertex. More...
#include <stddef.h>
Go to the source code of this file.
Data Structures | |
struct | Vertegs |
The data type for a graph vertex. More... | |
Macros | |
#define | VX_EXCEPT(reason, file, line) |
Raise an exception. | |
#define | VX_ENSURE_MEM(ptr) |
Raise an exception and return NULL if the pointer is NULL. | |
Functions | |
static struct Vertegs * | vx_4nbor (struct Vertegs **nbor) |
Cast to vertex from its neighbourhood. | |
static struct Vertegs * | vx_walk (struct Vertegs *v, size_t edge, int len) |
For a chain, in which all edges share the same index, find the other end. | |
static struct Vertegs * | vx_inslist (struct Vertegs *list, struct Vertegs *entry, int pos) |
Insert, at a given position, an entry into a list. | |
static struct Vertegs * | vx_remlist (struct Vertegs **listp, int pos) |
Remove, at a given position, an entry from a list. | |
static struct Vertegs * | vx_inscirq (struct Vertegs *cirq, struct Vertegs *entry, int pos) |
Insert, at a given position, an entry into a cirq. | |
static struct Vertegs * | vx_remcirq (struct Vertegs **cirqp, int pos) |
Remove, at a given position, an entry from a cirq. | |
Vertex.
This header file provides data types, functions and macros that define and operate on graph vertices.
#define VX_ENSURE_MEM | ( | ptr | ) |
Raise an exception and return NULL if the pointer is NULL.
[in] | ptr | The pointer. |
Cast to vertex from its neighbourhood.
[in] | nbor | The neighbourhood. |
|
inlinestatic |
Insert, at a given position, an entry into a cirq.
[in] | cirq | The head of the cirq. |
[in] | entry | The new entry. |
[in] | pos | The position. |
|
inlinestatic |
Insert, at a given position, an entry into a list.
[in] | list | The head of the list. |
[in] | entry | The new entry. |
[in] | pos | The position. |
Remove, at a given position, an entry from a cirq.
[in] | cirqp | The pointer to the head of the cirq. |
[in] | pos | The position. |
Remove, at a given position, an entry from a list.
[in] | listp | The pointer to the head of the list. |
[in] | pos | The position. |
For a chain, in which all edges share the same index, find the other end.
[in] | v | The first end of the chain. |
[in] | edge | The index of all edges in the chain. |
[in] | len | The length of the chain - the number of edges. |