Generic time-based scheduler. More...
#include <scheduler.hpp>
Public Member Functions | |
Scheduler (DummyIoService &ioService) | |
~Scheduler () | |
EventId | schedule (time::nanoseconds after, EventCallback callback) |
Schedule a one-time event after the specified delay. More... | |
void | cancelAllEvents () |
Cancel all scheduled events. More... | |
Generic time-based scheduler.
Definition at line 132 of file scheduler.hpp.
|
explicit |
Definition at line 86 of file scheduler.cpp.
ndn::scheduler::Scheduler::~Scheduler | ( | ) |
Definition at line 90 of file scheduler.cpp.
EventId ndn::scheduler::Scheduler::schedule | ( | time::nanoseconds | after, |
EventCallback | callback | ||
) |
Schedule a one-time event after the specified delay.
Definition at line 96 of file scheduler.cpp.
References info, and nonstd::optional_lite::std11::move().
Referenced by ndn::Face::Impl::asyncRemovePendingInterest(), ndn::Face::Impl::asyncUnregisterPrefix(), ndn::Face::Impl::asyncUnsetInterestFilter(), ndn::Face::Impl::Impl(), ndn::PendingInterest::invokeNackCallback(), ndn::net::NetworkMonitorImplOsx::listNetworkInterfaces(), ndn::security::v2::CertificateFetcherFromNetwork::nackCallback(), ndn::InMemoryStorageEntry::scheduleMarkStale(), and ndn::util::NotificationSubscriberBase::stop().
void ndn::scheduler::Scheduler::cancelAllEvents | ( | ) |
Cancel all scheduled events.
Definition at line 132 of file scheduler.cpp.
References ndn::scheduler::EventInfo::expiresFromNow(), and ndn::time::steady_clock::now().