FDR  4.2.7(6ecbe5a21b71ab020e8fcaeccfe5ebaad0599f4f)
segmented_behaviour.h
1 #pragma once
2 
3 #include <fdr/assertions/behaviour/behaviour.h>
4 
5 namespace FDR
6 {
7 namespace Assertions
8 {
9 class TraceBehaviour;
10 
23 {
24 public:
25  SegmentedBehaviour(const std::shared_ptr<LTS::Machine>& machine,
26  const std::vector<std::shared_ptr<LTS::Node>>& node_path,
27  const std::vector<LTS::CompiledEvent>& trace, const std::shared_ptr<Behaviour>& behaviour,
28  const std::vector<std::shared_ptr<TraceBehaviour>>& prior_sections);
29 
31  std::shared_ptr<Behaviour> last() const;
32 
37  std::vector<std::shared_ptr<TraceBehaviour>> prior_sections() const;
38 
39 private:
40  const std::shared_ptr<Behaviour> last_;
41  const std::vector<std::shared_ptr<TraceBehaviour>> prior_sections_;
42 };
43 
44 } // end Assertions
45 } // end FDR
FDR::Assertions::SegmentedBehaviour::prior_sections
std::vector< std::shared_ptr< TraceBehaviour > > prior_sections() const
The segments that lead up to last().
FDR::Assertions::Behaviour::node_path
const std::vector< std::shared_ptr< LTS::Node > > & node_path() const
The sequence of nodes leading to the behaviour.
FDR::Assertions::Behaviour::trace
const std::vector< LTS::CompiledEvent > & trace() const
Returns the sequence of events that led to this behaviour.
FDR::Assertions::SegmentedBehaviour::last
std::shared_ptr< Behaviour > last() const
The actual erroneous behaviour, which is the very last segment.
FDR::Assertions::SegmentedBehaviour
A behaviour of a machine that has been executed several times.
Definition: segmented_behaviour.h:23
FDR::Assertions::Behaviour
A particular path through a Machine, often leading to an interesting state.
Definition: behaviour.h:22
FDR::Assertions::Behaviour::machine
std::shared_ptr< LTS::Machine > machine() const
The machine in which the behaviour occurs.