added namespace comments
This commit is contained in:
@@ -11,30 +11,30 @@ template <typename T>
|
||||
class LimitedQueueSnapshot
|
||||
{
|
||||
public:
|
||||
LimitedQueueSnapshot(std::shared_ptr<std::vector<T>> ptr, int offset, int length)
|
||||
: vector(ptr)
|
||||
, offset(offset)
|
||||
, length(length)
|
||||
LimitedQueueSnapshot(std::shared_ptr<std::vector<T>> vector, int offset, int size)
|
||||
: _vector(vector)
|
||||
, _offset(offset)
|
||||
, _length(size)
|
||||
{
|
||||
}
|
||||
|
||||
int getLength()
|
||||
int getSize()
|
||||
{
|
||||
return this->length;
|
||||
return _length;
|
||||
}
|
||||
|
||||
T const &operator[](int index) const
|
||||
{
|
||||
return this->vector->at(index + this->offset);
|
||||
return _vector->at(index + _offset);
|
||||
}
|
||||
|
||||
private:
|
||||
std::shared_ptr<std::vector<T>> vector;
|
||||
std::shared_ptr<std::vector<T>> _vector;
|
||||
|
||||
int offset;
|
||||
int length;
|
||||
int _offset;
|
||||
int _length;
|
||||
};
|
||||
}
|
||||
}
|
||||
} // namespace messages
|
||||
} // namespace chatterino
|
||||
|
||||
#endif // LIMITEDQUEUESNAPSHOT_H
|
||||
|
||||
Reference in New Issue
Block a user