20 if (_entries[slot].
Index != index)
25 Entry& entry = _entries[slot];
27 entry.Commit = std::move(commit);
33 return IsValidSlot(slot) ? _entries[slot].Index : -1;
38 return index >= 0 &&
Index(slot) == index;
49 Entry taken = std::move(_entries[slot]);
50 _entries[slot] = Entry{};
62 _entries[slot] = Entry{};
bool IsPending(int slot, int index) const
PendingCommit(Timer timer, SlotEvents &slots)
static constexpr int64_t DelayMs
void Hold(int slot, int index, std::function< void()> commit)
int Index(int slot) const
std::function< Subscription(int64_t delayMs, std::function< void()> callback)> Timer
"The occupant of this slot changed" - raised by PlayerManager, consumed below it.
Owns one registration and releases it on destruction.
constexpr bool IsValidSlot(int slot)