From aa1542b6d6a4680088ac715c4ce40f97ada554fb Mon Sep 17 00:00:00 2001
From: lichao <lichao@aiotlink.com>
Date: 星期三, 14 四月 2021 17:52:31 +0800
Subject: [PATCH] add SendQ TrySend() TryRecv(); handle re-register.

---
 src/timed_queue.h |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/timed_queue.h b/src/timed_queue.h
index b2a941b..af77b11 100644
--- a/src/timed_queue.h
+++ b/src/timed_queue.h
@@ -1,7 +1,7 @@
 /*
  * =====================================================================================
  *
- *       Filename:  failed_msg.h
+ *       Filename:  timed_queue.h
  *
  *    Description:  
  *
@@ -35,7 +35,8 @@
 	    expire_(expire), data_(data) {}
 	TimedData(const TimePoint &expire, Data &&data) :
 	    expire_(expire), data_(std::move(data)) {}
-	bool Expired() { return Clock::now() > expire_; }
+	bool Expired() const { return Clock::now() > expire_; }
+	const TimePoint &expire() const { return expire_; }
 	Data &data() { return data_; }
 	Data const &data() const { return data_; }
 

--
Gitblit v1.8.0