spot 2.15
Loading...
Searching...
No Matches
mtdtwa.hh
1// -*- coding: utf-8 -*-
2// Copyright (C) by the Spot authors, see the AUTHORS file for details.
3//
4// This file is part of Spot, a model checking library.
5//
6// Spot is free software; you can redistribute it and/or modify it
7// under the terms of the GNU General Public License as published by
8// the Free Software Foundation; either version 3 of the License, or
9// (at your option) any later version.
10//
11// Spot is distributed in the hope that it will be useful, but WITHOUT
12// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
14// License for more details.
15//
16// You should have received a copy of the GNU General Public License
17// along with this program. If not, see <http://www.gnu.org/licenses/>.
18
19#pragma once
20
21#include <spot/twa/twagraph.hh>
22#include <spot/misc/bddlt.hh>
23#include <unordered_map>
24
25namespace spot
26{
27 typedef std::pair<acc_cond::mark_t, unsigned> terminal_data_t;
28 typedef std::vector<terminal_data_t> terminal_data_map_t;
29
30 struct SPOT_API mtdtwa: public std::enable_shared_from_this<mtdtwa>
31 {
32 public:
33 mtdtwa(const bdd_dict_ptr& dict) noexcept
34 : dict_(dict)
35 {
36 }
37
38 ~mtdtwa()
39 {
40 dict_->unregister_all_my_variables(this);
41 }
42
43 std::vector<bdd> states;
44 acc_cond acc;
45 bdd_dict_ptr dict_;
46 terminal_data_map_t terminal_data_map;
47
48 unsigned num_roots() const
49 {
50 return states.size();
51 }
52
53 // Print the MTBDD.
54 std::ostream& print_dot(std::ostream& os) const;
55
56 // convert to twa
57 twa_graph_ptr as_twa(bool state_based = false, bool labels = true) const;
58 };
59
60
61 typedef std::shared_ptr<mtdtwa> mtdtwa_ptr;
62 typedef std::shared_ptr<const mtdtwa> const_mtdtwa_ptr;
63
64 SPOT_API mtdtwa_ptr dtwa_to_mtdtwa(const twa_graph_ptr& aut);
65}
An acceptance condition.
Definition acc.hh:61
std::ostream & print_dot(std::ostream &os, const const_twa_ptr &g, const char *options=nullptr)
Print reachable states in dot format.
Definition automata.hh:26
Definition mtdtwa.hh:31

Please direct any question, comment, or bug report to the Spot mailing list at spot@lrde.epita.fr.
Generated on Fri Feb 27 2015 10:00:07 for spot by doxygen 1.9.8