PandA-2024.02
Public Types | Public Member Functions | Static Public Attributes
DesignFlowGraph Class Reference

#include <design_flow_graph.hpp>

Inheritance diagram for DesignFlowGraph:
Inheritance graph
[legend]
Collaboration diagram for DesignFlowGraph:
Collaboration graph
[legend]

Public Types

enum  Type { ALL }
 The type of view of design flow graph. More...
 

Public Member Functions

 DesignFlowGraph (const DesignFlowGraphsCollectionRef design_flow_graphs_collection, const int _selector)
 Constructor. More...
 
 DesignFlowGraph (const DesignFlowGraphsCollectionRef design_flow_graphs_collection, const int _selector, const CustomUnorderedSet< vertex > &vertices)
 Constructor. More...
 
 ~DesignFlowGraph () override
 Destructor. More...
 
vertex GetDesignFlowStep (const std::string &signature) const
 Return the vertex associated with a design step if exists, NULL_VERTEX otherwise. More...
 
DesignFlowStepInfoRef GetDesignFlowStepInfo (const vertex step)
 
const DesignFlowStepInfoConstRef CGetDesignFlowStepInfo (const vertex step) const
 Return the info associated with a step. More...
 
DesignFlowGraphInfoRef GetDesignFlowGraphInfo ()
 Return the info associated with the graph. More...
 
const DesignFlowGraphInfoConstRef CGetDesignFlowGraphInfo () const
 Return the info associated with the graph. More...
 
void WriteDot (const std::string &file_name, const int detail_level=0) const
 Write this graph in dot format. More...
 
void WriteDot (const std::string &file_name, const CustomMap< size_t, CustomMap< vertex, DesignFlowStep_Status >> &vertex_history, const CustomMap< size_t, CustomUnorderedMapStable< EdgeDescriptor, int >> &edge_history, const CustomMap< vertex, std::string > &vertex_names, const size_t writing_step_counter) const
 Write this graph in dot format considering situation during a given iteration. More...
 
- Public Member Functions inherited from graph
virtual ~graph ()=default
 Destructor. More...
 
bool is_in_subset (const boost::graph_traits< graph >::vertex_descriptor v) const
 return true in case the vertex is a vertex of the subgraph. More...
 
int GetSelector () const
 Return the selector of this graph. More...
 
int GetSelector (const edge_descriptor e) const
 Return the selectors associated with an edge. More...
 
int GetSelector (const boost::graph_traits< graphs_collection >::vertex_descriptor source, const boost::graph_traits< graphs_collection >::vertex_descriptor target) const
 Return the selectors associated with an edge. More...
 
void GetStronglyConnectedComponents (std::map< size_t, UnorderedSetStdStable< boost::graph_traits< graphs_collection >::vertex_descriptor >> &strongly_connected_components) const
 Compute the strongly connected components of the graph. More...
 
void BreadthFirstSearch (const boost::graph_traits< graphs_collection >::vertex_descriptor node, boost::bfs_visitor<> *vis) const
 Compute the breadth first search. More...
 
void ReverseTopologicalSort (std::deque< boost::graph_traits< graphs_collection >::vertex_descriptor > &sorted_vertices) const
 Compute the reverse topological order of the graph. More...
 
void TopologicalSort (std::list< boost::graph_traits< graphs_collection >::vertex_descriptor > &sorted_vertices) const
 Compute the topological order of the graph. More...
 
bool IsReachable (const boost::graph_traits< graphs_collection >::vertex_descriptor x, const boost::graph_traits< graphs_collection >::vertex_descriptor y) const
 Compute if vertex y is reachable from x. More...
 
NodeInfoRef GetNodeInfo (typename boost::graph_traits< graphs_collection >::vertex_descriptor node)
 FIXME: this method should become protected and called by equivalent method in subclasses Get the node property. More...
 
GraphInfoRef GetGraphInfo ()
 FIXME: this method should become protected and called by equivalent method in subclasses Get the graph property. More...
 
const GraphInfoConstRef CGetGraphInfo () const
 FIXME: this method should become protected and called by equivalent method in subclasses Get the graph property. More...
 
template<typename VertexWriterTemplate , typename EdgeWriterTemplate >
void InternalWriteDot (const std::string &file_name, const VertexWriterConstRef vertex_writer, const EdgeWriterConstRef edge_writer) const
 Print the graph in dot format FIXME: this method should become protected and called by WriteDot. More...
 
bool ExistsEdge (const boost::graph_traits< graphs_collection >::vertex_descriptor source, const boost::graph_traits< graphs_collection >::vertex_descriptor target) const
 Check if an edge exists. More...
 
boost::graph_traits< graphs_collection >::edge_descriptor CGetEdge (const boost::graph_traits< graphs_collection >::vertex_descriptor source, const boost::graph_traits< graphs_collection >::vertex_descriptor target) const
 Returns the edge connecting two vertices; throw error if it does not exist. More...
 
 graph (graphs_collection *g, const int _selector)
 Standard constructor. More...
 
 graph (graphs_collection *g, const int _selector, const CustomUnorderedSet< boost::graph_traits< graphs_collection >::vertex_descriptor > &vertices)
 Sub-graph constructor. More...
 

Static Public Attributes

static const int DEPENDENCE_SELECTOR = 1
 The dependence selector. More...
 
static const int PRECEDENCE_SELECTOR = 2
 The condition selector. More...
 
static const int AUX_SELECTOR = 4
 The auxiliary selector. More...
 
static const int DEPENDENCE_FEEDBACK_SELECTOR = 8
 The dependence feedback selector. More...
 

Additional Inherited Members

- Protected Member Functions inherited from graph
const NodeInfoConstRef CGetNodeInfo (typename boost::graph_traits< graphs_collection >::vertex_descriptor node) const
 Get the node property. More...
 
EdgeInfoRef GetEdgeInfo (typename boost::graph_traits< graphs_collection >::vertex_descriptor source, typename boost::graph_traits< graphs_collection >::vertex_descriptor target)
 Get the edge property. More...
 
const EdgeInfoConstRef CGetEdgeInfo (typename boost::graph_traits< graphs_collection >::vertex_descriptor source, typename boost::graph_traits< graphs_collection >::vertex_descriptor target) const
 Get the edge property. More...
 
EdgeInfoRef GetEdgeInfo (typename boost::graph_traits< graphs_collection >::edge_descriptor edge) const
 Get the edge property. More...
 
EdgeInfoConstRef CGetEdgeInfo (typename boost::graph_traits< graphs_collection >::edge_descriptor edge) const
 Get the edge property. More...
 
template<typename VertexWriterTemplate , typename EdgeWriterTemplate , typename GraphWriterTemplate >
void InternalWriteDot (const std::string &file_name, const VertexWriterConstRef vertex_writer, const EdgeWriterConstRef edge_writer, const GraphWriterConstRef graph_writer) const
 Print the graph in dot format. More...
 
- Protected Attributes inherited from graph
graphs_collectioncollection
 The graph collection. More...
 
const int selector
 selector More...
 

Detailed Description

Definition at line 159 of file design_flow_graph.hpp.

Member Enumeration Documentation

◆ Type

The type of view of design flow graph.

Enumerator
ALL 

Graph with all the edges.

Definition at line 177 of file design_flow_graph.hpp.

Constructor & Destructor Documentation

◆ DesignFlowGraph() [1/2]

DesignFlowGraph::DesignFlowGraph ( const DesignFlowGraphsCollectionRef  design_flow_graphs_collection,
const int  _selector 
)

Constructor.

Parameters
design_flow_graphs_collectionis the graph collection
selectoris the selector used in this view

Definition at line 100 of file design_flow_graph.cpp.

◆ DesignFlowGraph() [2/2]

DesignFlowGraph::DesignFlowGraph ( const DesignFlowGraphsCollectionRef  design_flow_graphs_collection,
const int  _selector,
const CustomUnorderedSet< vertex > &  vertices 
)

Constructor.

Parameters
design_flow_graphs_collectionis the graph collection
selectoris the selector used in this view
verticesis the set of vertices to be considered

Definition at line 105 of file design_flow_graph.cpp.

References ~DesignFlowGraph().

Here is the call graph for this function:

◆ ~DesignFlowGraph()

DesignFlowGraph::~DesignFlowGraph ( )
overridedefault

Destructor.

Referenced by DesignFlowGraph().

Here is the caller graph for this function:

Member Function Documentation

◆ CGetDesignFlowGraphInfo()

const DesignFlowGraphInfoConstRef DesignFlowGraph::CGetDesignFlowGraphInfo ( ) const
inline

Return the info associated with the graph.

Returns
the info associated with the graph

Definition at line 241 of file design_flow_graph.hpp.

References graph::CGetGraphInfo().

Here is the call graph for this function:

◆ CGetDesignFlowStepInfo()

const DesignFlowStepInfoConstRef DesignFlowGraph::CGetDesignFlowStepInfo ( const vertex  step) const
inline

Return the info associated with a step.

Parameters
stepis the vertex
Returns
the info associated with the vertex

Definition at line 223 of file design_flow_graph.hpp.

References graph::CGetNodeInfo().

Here is the call graph for this function:

◆ GetDesignFlowGraphInfo()

DesignFlowGraphInfoRef DesignFlowGraph::GetDesignFlowGraphInfo ( )
inline

Return the info associated with the graph.

Returns
the info associated with the graph

Definition at line 232 of file design_flow_graph.hpp.

References graph::GetGraphInfo().

Here is the call graph for this function:

◆ GetDesignFlowStep()

vertex DesignFlowGraph::GetDesignFlowStep ( const std::string &  signature) const

Return the vertex associated with a design step if exists, NULL_VERTEX otherwise.

Parameters
signatureis the signature of the design step

Definition at line 113 of file design_flow_graph.cpp.

References graph::collection.

◆ GetDesignFlowStepInfo()

DesignFlowStepInfoRef DesignFlowGraph::GetDesignFlowStepInfo ( const vertex  step)
inline
Parameters
stepis the vertex
Returns
the info associated with the vertex

Definition at line 213 of file design_flow_graph.hpp.

References graph::GetNodeInfo().

Here is the call graph for this function:

◆ WriteDot() [1/2]

void DesignFlowGraph::WriteDot ( const std::string &  file_name,
const int  detail_level = 0 
) const

Write this graph in dot format.

Parameters
file_nameis the file where the graph has to be printed
detail_levelis the detail level of the printed graph

Definition at line 118 of file design_flow_graph.cpp.

References graph::collection, test_panda::full_name, and graphs_collection::parameters.

Referenced by DesignFlowManager::WriteLoopDot().

Here is the caller graph for this function:

◆ WriteDot() [2/2]

void DesignFlowGraph::WriteDot ( const std::string &  file_name,
const CustomMap< size_t, CustomMap< vertex, DesignFlowStep_Status >> &  vertex_history,
const CustomMap< size_t, CustomUnorderedMapStable< EdgeDescriptor, int >> &  edge_history,
const CustomMap< vertex, std::string > &  vertex_names,
const size_t  writing_step_counter 
) const

Write this graph in dot format considering situation during a given iteration.

Parameters
file_nameis the file where graph has to be printed
vertex_historytells which vertices are present in each iteration
edge_historytells which edges are present in each iteration
vertex_namesis the name of each vertex (name of old vertices could be not more computable)

Definition at line 134 of file design_flow_graph.cpp.

References graph::collection, test_panda::full_name, and graphs_collection::parameters.

Field Documentation

◆ AUX_SELECTOR

const int DesignFlowGraph::AUX_SELECTOR = 4
static

◆ DEPENDENCE_FEEDBACK_SELECTOR

const int DesignFlowGraph::DEPENDENCE_FEEDBACK_SELECTOR = 8
static

◆ DEPENDENCE_SELECTOR

const int DesignFlowGraph::DEPENDENCE_SELECTOR = 1
static

◆ PRECEDENCE_SELECTOR

const int DesignFlowGraph::PRECEDENCE_SELECTOR = 2
static

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

Generated on Mon Feb 12 2024 13:03:49 for PandA-2024.02 by doxygen 1.8.13