Skip to content

Commit

Permalink
Added a generic backend monitor for the event loop to monitor user-sp…
Browse files Browse the repository at this point in the history
…ecific events
  • Loading branch information
gansm committed Oct 5, 2023
1 parent 6b7b65e commit 9c24c4c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions final/eventloop/backend_monitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ BackendMonitor::~BackendMonitor() noexcept // destructor

// public methods of BackendMonitor
//----------------------------------------------------------------------
void BackendMonitor::setEvent() noexcept
void BackendMonitor::setEvent() const noexcept
{
// The event loop is notified by write access to the pipe
uint64_t buffer{1U};
Expand All @@ -65,7 +65,7 @@ void BackendMonitor::setEvent() noexcept
}

//----------------------------------------------------------------------
void BackendMonitor::clearEvent() noexcept
void BackendMonitor::clearEvent() const
{
drainPipe(getFileDescriptor());
}
Expand Down
4 changes: 2 additions & 2 deletions final/eventloop/backend_monitor.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class BackendMonitor final : public Monitor
auto getClassName() const -> FString override;

// Mutator
void setEvent() noexcept;
void setEvent() const noexcept;

// Methods
template <typename T>
Expand All @@ -83,7 +83,7 @@ class BackendMonitor final : public Monitor
auto operator = (BackendMonitor&&) noexcept -> BackendMonitor& = delete;

// Mutator
void clearEvent() noexcept;
void clearEvent() const;

// Methods
void init();
Expand Down

0 comments on commit 9c24c4c

Please sign in to comment.