File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -130,6 +130,24 @@ class filepath {
130130 return bits[i];
131131 }
132132
133+ auto begin () const {
134+ if (bits.empty () && path.length () > 0 ) parse_bits ();
135+ return std::as_const (bits).begin ();
136+ }
137+ auto rbegin () const {
138+ if (bits.empty () && path.length () > 0 ) parse_bits ();
139+ return std::as_const (bits).rbegin ();
140+ }
141+
142+ auto end () const {
143+ if (bits.empty () && path.length () > 0 ) parse_bits ();
144+ return std::as_const (bits).end ();
145+ }
146+ auto rend () const {
147+ if (bits.empty () && path.length () > 0 ) parse_bits ();
148+ return std::as_const (bits).rend ();
149+ }
150+
133151 const std::string& last_dentry () const {
134152 if (bits.empty () && path.length () > 0 ) parse_bits ();
135153 ceph_assert (!bits.empty ());
You can’t perform that action at this time.
0 commit comments