atomic_prop.cc 659 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#include "atomic_prop.hh"
#include "visitor.hh"

namespace spot
{
  namespace ltl
  {
 
    atomic_prop::atomic_prop(std::string name)
      : name_(name)
    {
    }

    atomic_prop::~atomic_prop()
    {
    }

    void 
    atomic_prop::accept(visitor& v)
    {
      v.visit(this);
    }
    
    void
    atomic_prop::accept(const_visitor& v) const
    {
      v.visit(this);
    }   

    bool 
    atomic_prop::equals(const formulae* f) const
    {
      const atomic_prop* p = dynamic_cast<const atomic_prop*>(f);
      return p && p->name() == name();
    }

    const std::string&
    atomic_prop::name() const
    {
      return name_;
    }
  }
}