Lines Matching refs:T
29 template <typename T>
35 void Push(T item);
37 std::vector<T> Pull() const;
39 std::vector<T> Drain();
43 std::deque<T> queue_;
63 template <typename T>
66 T entry;
69 template <typename T>
70 class TimestampedCircularBuffer : public CircularBuffer<TimestampedEntry<T>> {
76 void Push(T item);
77 std::vector<TimestampedEntry<T>> Pull() const;
78 std::vector<TimestampedEntry<T>> Drain();
87 template <typename T>
88 bluetooth::common::CircularBuffer<T>::CircularBuffer(size_t size) : size_(size) {} in CircularBuffer()
90 template <typename T>
91 void bluetooth::common::CircularBuffer<T>::Push(const T item) { in Push()
99 template <typename T>
100 std::vector<T> bluetooth::common::CircularBuffer<T>::Pull() const { in Pull()
102 return std::vector<T>(queue_.cbegin(), queue_.cend()); in Pull()
105 template <typename T>
106 std::vector<T> bluetooth::common::CircularBuffer<T>::Drain() { in Drain()
108 std::vector<T> items(std::make_move_iterator(queue_.begin()), in Drain()
114 template <typename T>
115 bluetooth::common::TimestampedCircularBuffer<T>::TimestampedCircularBuffer( in TimestampedCircularBuffer()
117 : CircularBuffer<TimestampedEntry<T>>(size), timestamper_(std::move(timestamper)) {} in TimestampedCircularBuffer()
119 template <typename T>
120 void bluetooth::common::TimestampedCircularBuffer<T>::Push(const T item) { in Push()
121 TimestampedEntry<T> timestamped_entry{timestamper_->GetTimestamp(), item}; in Push()
122 bluetooth::common::CircularBuffer<TimestampedEntry<T>>::Push(timestamped_entry); in Push()
125 template <typename T>
126 std::vector<struct bluetooth::common::TimestampedEntry<T>>
127 bluetooth::common::TimestampedCircularBuffer<T>::Pull() const { in Pull()
128 return bluetooth::common::CircularBuffer<TimestampedEntry<T>>::Pull(); in Pull()
131 template <typename T>
132 std::vector<struct bluetooth::common::TimestampedEntry<T>>
133 bluetooth::common::TimestampedCircularBuffer<T>::Drain() { in Drain()
134 return bluetooth::common::CircularBuffer<TimestampedEntry<T>>::Drain(); in Drain()