Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

ogdf::matching_blossom::Cycle Class Reference

#include <ogdf/graphalg/matching_blossom/Cycle.h>

Public Member Functions

 Cycle (edge startEdge)
 
void addEdge (edge e)
 Use this method to add edges in cycle order. More...
 
bool contains (node v)
 Whether the cycle contains the node v or not. More...
 
const std::vector< edge > & edgeOrder ()
 
long indexOf (node u)
 Get the index of the edge before u in edge order. If u is the startNode, size() - 1 is returned. More...
 
std::tuple< long, long > indexOf (node u, node v)
 Get the indices of the edges before u and v in edge order. For the startNode, size() - 1 is returned. More...
 
const std::unordered_set< node > & nodes ()
 
node startNode ()
 The first node of the cycle in edge order. More...
 

Private Member Functions

std::vector< long > indexOf (std::vector< node > nodesToFind)
 Get the indices of the edges before nodesToFind in edge order. For the startNode, size() - 1 is returned. More...
 

Private Attributes

std::vector< edgem_edgeOrder
 
std::unordered_set< nodem_nodes
 

Detailed Description

Definition at line 43 of file Cycle.h.

Constructor & Destructor Documentation

◆ Cycle()

ogdf::matching_blossom::Cycle::Cycle ( edge  startEdge)

Member Function Documentation

◆ addEdge()

void ogdf::matching_blossom::Cycle::addEdge ( edge  e)

Use this method to add edges in cycle order.

◆ contains()

bool ogdf::matching_blossom::Cycle::contains ( node  v)

Whether the cycle contains the node v or not.

◆ edgeOrder()

const std::vector<edge>& ogdf::matching_blossom::Cycle::edgeOrder ( )

◆ indexOf() [1/3]

long ogdf::matching_blossom::Cycle::indexOf ( node  u)

Get the index of the edge before u in edge order. If u is the startNode, size() - 1 is returned.

◆ indexOf() [2/3]

std::tuple<long, long> ogdf::matching_blossom::Cycle::indexOf ( node  u,
node  v 
)

Get the indices of the edges before u and v in edge order. For the startNode, size() - 1 is returned.

◆ indexOf() [3/3]

std::vector<long> ogdf::matching_blossom::Cycle::indexOf ( std::vector< node nodesToFind)
private

Get the indices of the edges before nodesToFind in edge order. For the startNode, size() - 1 is returned.

◆ nodes()

const std::unordered_set<node>& ogdf::matching_blossom::Cycle::nodes ( )

◆ startNode()

node ogdf::matching_blossom::Cycle::startNode ( )

The first node of the cycle in edge order.

Member Data Documentation

◆ m_edgeOrder

std::vector<edge> ogdf::matching_blossom::Cycle::m_edgeOrder
private

Definition at line 47 of file Cycle.h.

◆ m_nodes

std::unordered_set<node> ogdf::matching_blossom::Cycle::m_nodes
private

Definition at line 45 of file Cycle.h.


The documentation for this class was generated from the following file: