18 this->data = other.data;
19 this->_notify_size = other._notify_size;
20 this->_is_empty = other._is_empty;
21 this->_is_waitable = other._is_waitable;
26 this->_is_empty = source.empty();
29 bool empty()
const noexcept {
30 return this->_is_empty;
34 return this->data.front();
37 T& operator[](
size_t n) {
41 void push_back(T&& item) {
42 this->data.push_back(std::move(item));
43 this->_is_empty =
false;
46 T pop_front()
noexcept {
47 T item = std::move(data.front());
50 if (this->data.empty()) {
51 this->_is_empty =
true;
57 bool is_waitable()
const noexcept {
58 return this->_is_waitable;
65 size_t size()
const noexcept {
66 return this->data.size();
69 typename std::deque<T>::iterator begin()
noexcept {
70 return this->data.begin();
73 typename std::deque<T>::iterator end()
noexcept {
74 return this->data.end();
78 this->_is_waitable =
true;
82 this->_is_waitable =
false;
86 bool _is_empty =
true;
87 bool _is_waitable =
false;