Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Hypergraph.h File Reference

Declaration and a partial implementation of a Hypergraph class partly based on the original classes for handling hypergraphs written by Martin Gronemann. More...

#include <ogdf/basic/GraphList.h>
#include <ogdf/basic/Observer.h>
#include <ogdf/basic/RegisteredArray.h>
#include <ogdf/basic/basic.h>
#include <ogdf/basic/memory.h>
#include <iosfwd>
#include <string>

Go to the source code of this file.

Classes

class  ogdf::AdjHypergraphElement
 Class for adjacency list elements. More...
 
class  ogdf::HyperedgeElement
 Class for the representation of hyperedges. More...
 
class  ogdf::Hypergraph
 
class  ogdf::HypergraphRegisteredArray< Key, Value, WithDefault, Registry >
 RegisteredArray for nodes and edges of a hypergraph. More...
 
class  ogdf::HypergraphRegistry< Key >
 Registry for nodes and edges of a hypergraph. More...
 
class  ogdf::HypernodeElement
 Class for the representation of hypernodes. More...
 
class  ogdf::List< E >
 Doubly linked lists (maintaining the length of the list). More...
 

Namespaces

 ogdf
 The namespace for all OGDF objects.
 

Macros

#define forall_adj_elements(adj, ge)   for ((adj) = (v)->firstAdj(); (adj); (adj) = (adj)->succ())
 Iteration over all adjacency list entries adj of a graph element ge. More...
 
#define forall_hyperedges(e, H)   for ((e) = (H).firstHyperedge(); (e); (e) = (e)->succ())
 Iteration over all hyperedges e of hypergraph H. More...
 
#define forall_hypernodes(v, H)   for ((v) = (H).firstHypernode(); (v); (v) = (v)->succ())
 Iteration over all hypernodes v of hypergraph H. More...
 
#define forall_rev_hyperedges(e, H)   for ((e) = (H).lastHyperedge(); (e); (e) = (e)->pred())
 Iteration over all hyperedges e of hypergraph H in reverse order. More...
 
#define forall_rev_hypernodes(v, H)   for ((v) = (H).lastHypernode(); (v); (v) = (v)->pred())
 Iteration over all hypernodes v of hypergraph H in reverse order. More...
 
#define OGDF_DECL_REG_ARRAY_TYPE(v, c)   HypergraphRegisteredArray<HypernodeElement, v, c>
 
#define OGDF_DECL_REG_ARRAY_TYPE(v, c)   HypergraphRegisteredArray<HyperedgeElement, v, c>
 

Typedefs

using ogdf::adjHypergraphEntry = AdjHypergraphElement *
 The type of adjacency entries. More...
 
using ogdf::hyperedge = HyperedgeElement *
 The type of hyperedges. More...
 
template<typename Value , bool WithDefault = true>
using ogdf::HyperedgeArray = HypergraphRegisteredArray< HyperedgeElement, Value, WithDefault >
 Array for labeling the hyperedges in a Hypergraph with an arbitrary Value. More...
 
template<typename Value >
using ogdf::HyperedgeArrayP = HyperedgeArray< std::unique_ptr< Value >, false >
 Shorthand for HyperedgeArray storing std::unique_ptr<Value>. More...
 
using ogdf::hypernode = HypernodeElement *
 The type of hypernodes. More...
 
template<typename Value , bool WithDefault = true>
using ogdf::HypernodeArray = HypergraphRegisteredArray< HypernodeElement, Value, WithDefault >
 Array for labeling the hypernodes in a Hypergraph with an arbitrary Value. More...
 
template<typename Value >
using ogdf::HypernodeArrayP = HypernodeArray< std::unique_ptr< Value >, false >
 Shorthand for HypernodeArray storing std::unique_ptr<Value>. More...
 

Functions

HypergraphRegistry< HyperedgeElement >::iterator ogdf::begin (const HypergraphRegistry< HyperedgeElement > &self)
 
HypergraphRegistry< HypernodeElement >::iterator ogdf::begin (const HypergraphRegistry< HypernodeElement > &self)
 
HypergraphRegistry< HyperedgeElement >::iterator ogdf::end (const HypergraphRegistry< HyperedgeElement > &self)
 
HypergraphRegistry< HypernodeElement >::iterator ogdf::end (const HypergraphRegistry< HypernodeElement > &self)
 

Detailed Description

Declaration and a partial implementation of a Hypergraph class partly based on the original classes for handling hypergraphs written by Martin Gronemann.

Author
Ondrej Moris
License:
This file is part of the Open Graph Drawing Framework (OGDF).
Copyright (C)
See README.md in the OGDF root directory for details.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License Version 2 or 3 as published by the Free Software Foundation; see the file LICENSE.txt included in the packaging of this file for details.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/copyleft/gpl.html

Definition in file Hypergraph.h.

Macro Definition Documentation

◆ forall_adj_elements

#define forall_adj_elements (   adj,
  ge 
)    for ((adj) = (v)->firstAdj(); (adj); (adj) = (adj)->succ())

Iteration over all adjacency list entries adj of a graph element ge.

Definition at line 51 of file Hypergraph.h.

◆ forall_hyperedges

#define forall_hyperedges (   e,
 
)    for ((e) = (H).firstHyperedge(); (e); (e) = (e)->succ())

Iteration over all hyperedges e of hypergraph H.

Definition at line 60 of file Hypergraph.h.

◆ forall_hypernodes

#define forall_hypernodes (   v,
 
)    for ((v) = (H).firstHypernode(); (v); (v) = (v)->succ())

Iteration over all hypernodes v of hypergraph H.

Definition at line 54 of file Hypergraph.h.

◆ forall_rev_hyperedges

#define forall_rev_hyperedges (   e,
 
)    for ((e) = (H).lastHyperedge(); (e); (e) = (e)->pred())

Iteration over all hyperedges e of hypergraph H in reverse order.

Definition at line 63 of file Hypergraph.h.

◆ forall_rev_hypernodes

#define forall_rev_hypernodes (   v,
 
)    for ((v) = (H).lastHypernode(); (v); (v) = (v)->pred())

Iteration over all hypernodes v of hypergraph H in reverse order.

Definition at line 57 of file Hypergraph.h.

◆ OGDF_DECL_REG_ARRAY_TYPE [1/2]

#define OGDF_DECL_REG_ARRAY_TYPE (   v,
 
)    HypergraphRegisteredArray<HypernodeElement, v, c>

Definition at line 402 of file Hypergraph.h.

◆ OGDF_DECL_REG_ARRAY_TYPE [2/2]

#define OGDF_DECL_REG_ARRAY_TYPE (   v,
 
)    HypergraphRegisteredArray<HyperedgeElement, v, c>

Definition at line 402 of file Hypergraph.h.