LLVM OpenMP 22.0.0git
omptest::internal::EventBase< Derived > Class Template Reference

CRTP (Curiously Recurring Template Pattern) intermediate class Adding a new event type can be achieved by inheriting from an EventBase template instantiation of the new class' name, like this: struct NewEventType : public EventBase<NewEventType> More...

#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/openmp/tools/omptest/include/InternalEventCommon.h"

Inheritance diagram for omptest::internal::EventBase< Derived >:
[legend]

Public Member Functions

 EventBase ()
virtual ~EventBase ()=default
virtual bool equals (const InternalEvent *o) const override
 Equals method to cast and dispatch to the specific class operator==.
virtual std::string toString () const override
 Basic toString method, which may be overridden with own implementations.
Public Member Functions inherited from omptest::internal::InternalEvent
 InternalEvent ()
 InternalEvent (EventTy T)
virtual ~InternalEvent ()=default

Static Public Attributes

static constexpr EventTy EventType = EventTypeOf<Derived>::Value

Additional Inherited Members

Public Attributes inherited from omptest::internal::InternalEvent
EventTy Type
 Identifying event type.

Detailed Description

template<typename Derived>
class omptest::internal::EventBase< Derived >

CRTP (Curiously Recurring Template Pattern) intermediate class Adding a new event type can be achieved by inheriting from an EventBase template instantiation of the new class' name, like this: struct NewEventType : public EventBase<NewEventType>

Definition at line 102 of file InternalEventCommon.h.

Constructor & Destructor Documentation

◆ EventBase()

template<typename Derived>
omptest::internal::EventBase< Derived >::EventBase ( )
inline

◆ ~EventBase()

template<typename Derived>
virtual omptest::internal::EventBase< Derived >::~EventBase ( )
virtualdefault

Member Function Documentation

◆ equals()

template<typename Derived>
virtual bool omptest::internal::EventBase< Derived >::equals ( const InternalEvent * o) const
inlineoverridevirtual

Equals method to cast and dispatch to the specific class operator==.

Reimplemented from omptest::internal::InternalEvent.

Definition at line 109 of file InternalEventCommon.h.

References omptest::internal::InternalEvent::InternalEvent(), and omptest::internal::operator==().

◆ toString()

Member Data Documentation

◆ EventType

template<typename Derived>
EventTy omptest::internal::EventBase< Derived >::EventType = EventTypeOf<Derived>::Value
staticconstexpr

Definition at line 104 of file InternalEventCommon.h.

Referenced by EventBase().


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