spot  0.9.2
emptiness.hh
Go to the documentation of this file.
1 // Copyright (C) 2011 Laboratoire de Recherche et Developpement de
2 // l'Epita (LRDE).
3 // Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
4 // département Systèmes Répartis Coopératifs (SRC), Université Pierre
5 // et Marie Curie.
6 //
7 // This file is part of Spot, a model checking library.
8 //
9 // Spot is free software; you can redistribute it and/or modify it
10 // under the terms of the GNU General Public License as published by
11 // the Free Software Foundation; either version 2 of the License, or
12 // (at your option) any later version.
13 //
14 // Spot is distributed in the hope that it will be useful, but WITHOUT
15 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16 // or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
17 // License for more details.
18 //
19 // You should have received a copy of the GNU General Public License
20 // along with Spot; see the file COPYING. If not, write to the Free
21 // Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
22 // 02111-1307, USA.
23 
24 #ifndef SPOT_TGBAALGOS_EMPTINESS_HH
25 # define SPOT_TGBAALGOS_EMPTINESS_HH
26 
27 #include <map>
28 #include <list>
29 #include <iosfwd>
30 #include <bdd.h>
31 #include "misc/optionmap.hh"
32 #include "tgba/state.hh"
33 #include "emptiness_stats.hh"
34 
35 namespace spot
36 {
37  class tgba;
38  struct tgba_run;
39 
72 
79  {
80  public:
82  : a_(a), o_(o)
83  {
84  }
85 
86  virtual
88  {
89  }
90 
103  virtual tgba_run* accepting_run();
104 
106  const tgba*
107  automaton() const
108  {
109  return a_;
110  }
111 
113  const option_map&
114  options() const
115  {
116  return o_;
117  }
118 
120  const char* parse_options(char* options);
121 
123  virtual const unsigned_statistics* statistics() const;
124 
125  protected:
127  virtual void options_updated(const option_map& old);
128 
129  const tgba* a_;
131  };
132 
135  {
136  public:
138  : a_(a), o_(o)
139  {
140  }
141  virtual ~emptiness_check();
142 
144  const tgba*
145  automaton() const
146  {
147  return a_;
148  }
149 
151  const option_map&
152  options() const
153  {
154  return o_;
155  }
156 
158  const char* parse_options(char* options);
159 
161  virtual bool safe() const;
162 
177  virtual emptiness_check_result* check() = 0;
178 
180  virtual const unsigned_statistics* statistics() const;
181 
183  virtual std::ostream& print_stats(std::ostream& os) const;
184 
186  virtual void options_updated(const option_map& old);
187 
188  protected:
189  const tgba* a_;
191  };
192 
193 
194  // Dynamically create emptiness checks. Given their name and options.
196  {
197  public:
207  static emptiness_check_instantiator* construct(const char* name,
208  const char** err);
209 
211  emptiness_check* instantiate(const tgba* a) const;
212 
215  const option_map&
216  options() const
217  {
218  return o_;
219  }
220 
221  option_map&
223  {
224  return o_;
225  }
227 
230  unsigned int min_acceptance_conditions() const;
231 
236  unsigned int max_acceptance_conditions() const;
237  private:
240  void *info_;
241  };
242 
243 
245 
248 
249 
253 
255  struct tgba_run
256  {
257  struct step {
258  const state* s;
259  bdd label;
260  bdd acc;
261  };
262 
263  typedef std::list<step> steps;
264 
267 
268  ~tgba_run();
270  {
271  };
272  tgba_run(const tgba_run& run);
273  tgba_run& operator=(const tgba_run& run);
274  };
275 
290  std::ostream& print_tgba_run(std::ostream& os,
291  const tgba* a,
292  const tgba_run* run);
293 
298  tgba* tgba_run_to_tgba(const tgba* a, const tgba_run* run);
299 
301 
304 }
305 
306 #endif // SPOT_TGBAALGOS_EMPTINESS_HH

Please comment this page and report errors about it on the RefDocComments page.
Generated on Mon Jul 2 2012 17:35:47 for spot by doxygen 1.8.1.1