openMSX
Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Friends | List of all members
openmsx::WatchPoint Class Referencefinal

#include <WatchPoint.hh>

Inheritance diagram for openmsx::WatchPoint:
Inheritance graph
[legend]
Collaboration diagram for openmsx::WatchPoint:
Collaboration graph
[legend]

Classes

struct  clone_tag
 

Public Types

enum class  Type { READ_IO , WRITE_IO , READ_MEM , WRITE_MEM }
 

Public Member Functions

 WatchPoint ()=default
 
 WatchPoint (clone_tag, const WatchPoint &wp)
 
Type getType () const
 
void setType (Interpreter &interp, Type t)
 
void setType (Interpreter &interp, const TclObject &t)
 
auto getBeginAddress () const
 
auto getEndAddress () const
 
auto getBeginAddressString () const
 
auto getEndAddressString () const
 
void setBeginAddressString (Interpreter &interp, const TclObject &s)
 
void setEndAddressString (Interpreter &interp, const TclObject &s)
 
void setAddress (Interpreter &interp, const TclObject &a)
 
void evaluateAddress (Interpreter &interp)
 
std::string parseAddressError (Interpreter &interp) const
 
void registerIOWatch (MSXMotherBoard &motherBoard, std::span< MSXDevice *, 256 > devices)
 
void unregisterIOWatch (std::span< MSXDevice *, 256 > devices)
 
- Public Member Functions inherited from openmsx::BreakPointBase< WatchPoint >
unsigned getId () const
 
std::string getIdStr () const
 
TclObject getCondition () const
 
TclObject getCommand () const
 
bool isEnabled () const
 
bool onlyOnce () const
 
void setCondition (const TclObject &c)
 
void setCommand (const TclObject &c)
 
void setEnabled (Interpreter &interp, const TclObject &e)
 
void setEnabled (bool e)
 
void setOnce (Interpreter &interp, const TclObject &o)
 
void setOnce (bool o)
 
bool checkAndExecute (GlobalCliComm &cliComm, Interpreter &interp)
 

Static Public Member Functions

static std::string_view format (Type type)
 
static Type parseType (std::string_view str)
 
static unsigned rangeForType (Type type)
 
static std::pair< TclObject, TclObjectparseAddress (Interpreter &interp, const TclObject &a)
 

Static Public Attributes

static constexpr std::string_view prefix = "wp#"
 

Friends

class MSXWatchIODevice
 

Additional Inherited Members

- Protected Member Functions inherited from openmsx::BreakPointBase< WatchPoint >
 BreakPointBase ()
 
- Protected Attributes inherited from openmsx::BreakPointBase< WatchPoint >
unsigned id
 

Detailed Description

Definition at line 42 of file WatchPoint.hh.

Member Enumeration Documentation

◆ Type

enum class openmsx::WatchPoint::Type
strong
Enumerator
READ_IO 
WRITE_IO 
READ_MEM 
WRITE_MEM 

Definition at line 48 of file WatchPoint.hh.

Constructor & Destructor Documentation

◆ WatchPoint() [1/2]

openmsx::WatchPoint::WatchPoint ( )
default

◆ WatchPoint() [2/2]

openmsx::WatchPoint::WatchPoint ( clone_tag  ,
const WatchPoint wp 
)
inline

Definition at line 89 of file WatchPoint.hh.

References openmsx::BreakPointBase< Derived >::id.

Member Function Documentation

◆ evaluateAddress()

void openmsx::WatchPoint::evaluateAddress ( Interpreter interp)
inline

Definition at line 126 of file WatchPoint.hh.

References parseAddress().

Referenced by setAddress(), setBeginAddressString(), setEndAddressString(), and setType().

◆ format()

static std::string_view openmsx::WatchPoint::format ( Type  type)
inlinestatic

Definition at line 50 of file WatchPoint.hh.

References READ_IO, READ_MEM, UNREACHABLE, WRITE_IO, and WRITE_MEM.

◆ getBeginAddress()

auto openmsx::WatchPoint::getBeginAddress ( ) const
inline

Definition at line 109 of file WatchPoint.hh.

◆ getBeginAddressString()

auto openmsx::WatchPoint::getBeginAddressString ( ) const
inline

Definition at line 111 of file WatchPoint.hh.

◆ getEndAddress()

auto openmsx::WatchPoint::getEndAddress ( ) const
inline

Definition at line 110 of file WatchPoint.hh.

◆ getEndAddressString()

auto openmsx::WatchPoint::getEndAddressString ( ) const
inline

Definition at line 112 of file WatchPoint.hh.

◆ getType()

Type openmsx::WatchPoint::getType ( ) const
inline

Definition at line 100 of file WatchPoint.hh.

Referenced by registerIOWatch(), and unregisterIOWatch().

◆ parseAddress()

static std::pair< TclObject, TclObject > openmsx::WatchPoint::parseAddress ( Interpreter interp,
const TclObject a 
)
inlinestatic

◆ parseAddressError()

std::string openmsx::WatchPoint::parseAddressError ( Interpreter interp) const
inline

Definition at line 137 of file WatchPoint.hh.

References parseAddress().

◆ parseType()

static Type openmsx::WatchPoint::parseType ( std::string_view  str)
inlinestatic

Definition at line 61 of file WatchPoint.hh.

References READ_IO, READ_MEM, WRITE_IO, and WRITE_MEM.

Referenced by setType().

◆ rangeForType()

static unsigned openmsx::WatchPoint::rangeForType ( Type  type)
inlinestatic

Definition at line 70 of file WatchPoint.hh.

References READ_IO, and WRITE_IO.

◆ registerIOWatch()

void openmsx::WatchPoint::registerIOWatch ( MSXMotherBoard motherBoard,
std::span< MSXDevice *, 256 >  devices 
)

◆ setAddress()

void openmsx::WatchPoint::setAddress ( Interpreter interp,
const TclObject a 
)
inline

Definition at line 121 of file WatchPoint.hh.

References evaluateAddress(), and parseAddress().

◆ setBeginAddressString()

void openmsx::WatchPoint::setBeginAddressString ( Interpreter interp,
const TclObject s 
)
inline

Definition at line 113 of file WatchPoint.hh.

References evaluateAddress().

◆ setEndAddressString()

void openmsx::WatchPoint::setEndAddressString ( Interpreter interp,
const TclObject s 
)
inline

Definition at line 117 of file WatchPoint.hh.

References evaluateAddress().

◆ setType() [1/2]

void openmsx::WatchPoint::setType ( Interpreter interp,
const TclObject t 
)
inline

Definition at line 105 of file WatchPoint.hh.

References parseType(), setType(), and t.

◆ setType() [2/2]

void openmsx::WatchPoint::setType ( Interpreter interp,
Type  t 
)
inline

Definition at line 101 of file WatchPoint.hh.

References evaluateAddress(), and t.

Referenced by setType().

◆ unregisterIOWatch()

void openmsx::WatchPoint::unregisterIOWatch ( std::span< MSXDevice *, 256 >  devices)

Friends And Related Symbol Documentation

◆ MSXWatchIODevice

friend class MSXWatchIODevice
friend

Definition at line 177 of file WatchPoint.hh.

Member Data Documentation

◆ prefix

constexpr std::string_view openmsx::WatchPoint::prefix = "wp#"
staticconstexpr

Definition at line 46 of file WatchPoint.hh.


The documentation for this class was generated from the following files: