openMSX
ProbeBreakPoint.hh
Go to the documentation of this file.
1 #ifndef PROBEBREAKPOINT_HH
2 #define PROBEBREAKPOINT_HH
3 
4 #include "BreakPointBase.hh"
5 #include "Observer.hh"
6 
7 namespace openmsx {
8 
9 class Debugger;
10 class ProbeBase;
11 
12 class ProbeBreakPoint final : public BreakPointBase
13  , private Observer<ProbeBase>
14 {
15 public:
16  ProbeBreakPoint(TclObject command,
17  TclObject condition,
18  Debugger& debugger,
19  ProbeBase& probe,
20  bool once,
21  unsigned newId = -1);
23 
24  unsigned getId() const { return id; }
25  const ProbeBase& getProbe() const { return probe; }
26 
27 private:
28  // Observer<ProbeBase>
29  void update(const ProbeBase& subject) override;
30  void subjectDeleted(const ProbeBase& subject) override;
31 
32  Debugger& debugger;
33  ProbeBase& probe;
34  const unsigned id;
35 
36  static unsigned lastId;
37 };
38 
39 } // namespace openmsx
40 
41 #endif
ProbeBreakPoint(TclObject command, TclObject condition, Debugger &debugger, ProbeBase &probe, bool once, unsigned newId=-1)
Base class for CPU break and watch points.
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5
Generic Gang-of-Four Observer class, templatized edition.
Definition: Observer.hh:9
const ProbeBase & getProbe() const