Sequence Chart Studio  svn HEAD revision
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
AllPaths Class Reference

#include <hmsc_all_paths.h>

Collaboration diagram for AllPaths:
Collaboration graph

Public Member Functions

 AllPaths (HMscPtr hmsc, HMscNodePtr first, HMscNodePtrSet last, int occurence, const std::string &number="AllPathAlg")
 
 ~AllPaths ()
 
void set_number (HMscNodePtr e, int number, SystemState system_state=SystemState())
 
int get_number (HMscNodePtr e, SystemState system_state=SystemState())
 
void traverse ()
 
void all_paths (HMscNodePtr, MscElementPList, std::set< std::string > system_state=std::set< std::string >())
 
void add_path_found_listener (PathFoundListener *l)
 

Static Public Member Functions

static void traverse (HMscPtr hmsc, HMscNodePtr first, HMscNodePtrSet last, int occurence)
 

Private Attributes

HMscNodePtrSet m_nodes_set
 
HMscPtr m_hmsc
 
HMscNodePtr m_first
 
HMscNodePtrSet m_last
 
int m_occurence
 
std::list< PathFoundListener * > m_path_found_listeners
 
SessionAttribute< std::map
< SystemState, int > > 
m_attr_number
 

Detailed Description

Definition at line 16 of file hmsc_all_paths.h.

Constructor & Destructor Documentation

AllPaths::AllPaths ( HMscPtr  hmsc,
HMscNodePtr  first,
HMscNodePtrSet  last,
int  occurence,
const std::string number = "AllPathAlg" 
)
inline

Definition at line 30 of file hmsc_all_paths.h.

AllPaths::~AllPaths ( )
inline

Definition at line 37 of file hmsc_all_paths.h.

References SessionAttribute< Type >::clean_up(), and m_attr_number.

Member Function Documentation

void AllPaths::add_path_found_listener ( PathFoundListener l)
inline
void AllPaths::all_paths ( HMscNodePtr  ,
MscElementPList  ,
std::set< std::string system_state = std::set<std::string>() 
)
int AllPaths::get_number ( HMscNodePtr  e,
SystemState  system_state = SystemState() 
)
inline

Definition at line 49 of file hmsc_all_paths.h.

References SessionAttribute< Type >::get(), and m_attr_number.

Referenced by all_paths().

void AllPaths::set_number ( HMscNodePtr  e,
int  number,
SystemState  system_state = SystemState() 
)
inline
static void AllPaths::traverse ( HMscPtr  hmsc,
HMscNodePtr  first,
HMscNodePtrSet  last,
int  occurence 
)
inlinestatic

Traverses given BMscGraph and calls on_path_found method of every added PathFoundListener on all paths, such:

  • the path starts from node first
  • the path contains one of the nodes from lastand the node is last node of the path
  • the path does not contain more than occurence times of same node.

Definition at line 66 of file hmsc_all_paths.h.

References traverse().

Referenced by AllPathsAllBlocks::all_paths_all_blocks(), HMscConsistencyChecker::check(), and traverse().

void AllPaths::traverse ( )

Definition at line 4 of file hmsc_all_paths.cpp.

References all_paths(), m_first, m_hmsc, m_nodes_set, and set_number().

Member Data Documentation

SessionAttribute<std::map<SystemState, int> > AllPaths::m_attr_number
private

Definition at line 25 of file hmsc_all_paths.h.

Referenced by get_number(), set_number(), and ~AllPaths().

HMscNodePtr AllPaths::m_first
private

Definition at line 21 of file hmsc_all_paths.h.

Referenced by traverse().

HMscPtr AllPaths::m_hmsc
private

Definition at line 20 of file hmsc_all_paths.h.

Referenced by traverse().

HMscNodePtrSet AllPaths::m_last
private

Definition at line 22 of file hmsc_all_paths.h.

Referenced by all_paths().

HMscNodePtrSet AllPaths::m_nodes_set
private

Definition at line 19 of file hmsc_all_paths.h.

Referenced by traverse().

int AllPaths::m_occurence
private

Definition at line 23 of file hmsc_all_paths.h.

Referenced by all_paths().

std::list<PathFoundListener*> AllPaths::m_path_found_listeners
private

Definition at line 24 of file hmsc_all_paths.h.

Referenced by add_path_found_listener(), and all_paths().


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

SourceForge.net Logo
Generated on Fri Jan 15 2016 16:26:57 for Sequence Chart Studio by  doxygen