Project

General

Profile

Actions

Task #2155

closed

NameTree: enumeration with range-based for

Added by Junxiao Shi about 10 years ago. Updated almost 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Tables
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
1.50 h

Description

Modify NameTree enumeration functions, so that they can be used with range-based for.

The new API shall support the following snippets:

NameTree nt;

auto&& fullEnumerated = nt.fullEnumerate(...);
for (const name_tree::Entry& nte : fullEnumerated) {
  ...
}

auto&& partialEnumerated = nt.partialEnumerate(...);
for (const name_tree::Entry& nte : partialEnumerated) {
  ...
}

auto&& allMatches = nt.findAllMatches(...);
for (const name_tree::Entry& nte : allMatches) {
  ...
}

Related issues 1 (0 open1 closed)

Related to NFD - Task #2100: Simplify tables with C++11 featuresClosedJunxiao Shi

Actions
Actions

Also available in: Atom PDF