mirror of
https://github.com/KingDuckZ/incredis
synced 2024-11-23 00:33:46 +00:00
Rename replies_requested() into replies_ready().
This commit is contained in:
parent
a6fab83296
commit
7440745ea2
2 changed files with 3 additions and 3 deletions
|
@ -41,7 +41,7 @@ namespace redis {
|
|||
|
||||
ConstReplies replies ( void ) const;
|
||||
Replies replies_nonconst ( void );
|
||||
bool replies_requested ( void ) const;
|
||||
bool replies_ready ( void ) const;
|
||||
void throw_if_failed ( void );
|
||||
|
||||
template <typename... Args>
|
||||
|
|
|
@ -198,12 +198,12 @@ namespace redis {
|
|||
m_async_conn->wakeup_event_thread();
|
||||
}
|
||||
|
||||
bool Batch::replies_requested() const {
|
||||
bool Batch::replies_ready() const {
|
||||
return static_cast<bool>(0 == m_local_data->local_pending_futures);
|
||||
}
|
||||
|
||||
auto Batch::replies() const -> ConstReplies {
|
||||
if (not replies_requested()) {
|
||||
if (not replies_ready()) {
|
||||
if (m_local_data->local_pending_futures > 0) {
|
||||
std::unique_lock<std::mutex> u_lock(m_local_data->pending_futures_mutex);
|
||||
m_local_data->no_more_pending_futures.wait(u_lock, [this]() { return m_local_data->local_pending_futures == 0; });
|
||||
|
|
Loading…
Reference in a new issue