gem5  v20.1.0.0
Public Member Functions | Private Attributes | List of all members
ProbeListenerArg< T, Arg > Class Template Reference

ProbeListenerArg generates a listener for the class of Arg and the class type T which is the class containing the function that notify will call. More...

#include <probe.hh>

Inheritance diagram for ProbeListenerArg< T, Arg >:
ProbeListenerArgBase< Arg > ProbeListener

Public Member Functions

 ProbeListenerArg (T *obj, const std::string &name, void(T::*func)(const Arg &))
 
virtual void notify (const Arg &val)
 called when the ProbePoint calls notify. More...
 
- Public Member Functions inherited from ProbeListenerArgBase< Arg >
 ProbeListenerArgBase (ProbeManager *pm, const std::string &name)
 
- Public Member Functions inherited from ProbeListener
 ProbeListener (ProbeManager *manager, const std::string &name)
 
virtual ~ProbeListener ()
 

Private Attributes

T * object
 
void(T::* function )(const Arg &)
 

Additional Inherited Members

- Protected Attributes inherited from ProbeListener
ProbeManager *const manager
 
const std::string name
 

Detailed Description

template<class T, class Arg>
class ProbeListenerArg< T, Arg >

ProbeListenerArg generates a listener for the class of Arg and the class type T which is the class containing the function that notify will call.

Note that the function is passed as a pointer on construction.

Definition at line 215 of file probe.hh.

Constructor & Destructor Documentation

◆ ProbeListenerArg()

template<class T , class Arg >
ProbeListenerArg< T, Arg >::ProbeListenerArg ( T *  obj,
const std::string &  name,
void(T::*)(const Arg &)  func 
)
inline
Parameters
objthe class of type Tcontaining the method to call on notify.
namethe name of the ProbePoint to add this listener to.
funca pointer to the function on obj (called on notify).

Definition at line 227 of file probe.hh.

Member Function Documentation

◆ notify()

template<class T , class Arg >
virtual void ProbeListenerArg< T, Arg >::notify ( const Arg &  val)
inlinevirtual

called when the ProbePoint calls notify.

This is a shim through to the function passed during construction.

Parameters
valthe argument value to pass.

Implements ProbeListenerArgBase< Arg >.

Definition at line 238 of file probe.hh.

References X86ISA::val.

Member Data Documentation

◆ function

template<class T , class Arg >
void(T::* ProbeListenerArg< T, Arg >::function) (const Arg &)
private

Definition at line 219 of file probe.hh.

◆ object

template<class T , class Arg >
T* ProbeListenerArg< T, Arg >::object
private

Definition at line 218 of file probe.hh.


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

Generated on Wed Sep 30 2020 14:02:29 for gem5 by doxygen 1.8.17