mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-19 15:58:56 +00:00
Spreadsheet: Implement begin() and end()
This commit is contained in:
parent
f56e240981
commit
8dbb996200
Notes:
sideshowbarker
2024-07-19 17:16:57 +09:00
Author: https://github.com/krkk
Commit: 8dbb996200
Pull-request: https://github.com/SerenityOS/serenity/pull/9576
Reviewed-by: https://github.com/alimpfard
1 changed files with 8 additions and 1 deletions
|
@ -107,7 +107,14 @@ public:
|
|||
size_t index() const { return m_index; }
|
||||
size_t size() const { return m_xsv.headers().size(); }
|
||||
|
||||
// FIXME: Implement begin() and end(), keeping `Field' out of the API.
|
||||
using ConstIterator = AK::SimpleIterator<const Row, const StringView>;
|
||||
using Iterator = AK::SimpleIterator<Row, StringView>;
|
||||
|
||||
constexpr ConstIterator begin() const { return ConstIterator::begin(*this); }
|
||||
constexpr Iterator begin() { return Iterator::begin(*this); }
|
||||
|
||||
constexpr ConstIterator end() const { return ConstIterator::end(*this); }
|
||||
constexpr Iterator end() { return Iterator::end(*this); }
|
||||
|
||||
private:
|
||||
XSV& m_xsv;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue