mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
Extract function getDomReferences
and move it to CLI
Signed-off-by: Thomas Lauf <thomas.lauf@tngtech.com>
This commit is contained in:
parent
29cc9e8a0a
commit
422e49bacb
3 changed files with 25 additions and 11 deletions
16
src/CLI.cpp
16
src/CLI.cpp
|
@ -606,3 +606,19 @@ Duration CLI::getDuration () const
|
|||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
std::vector <std::string> CLI::getDomReferences () const
|
||||
{
|
||||
std::vector<std::string> references;
|
||||
|
||||
for (auto &arg : _args)
|
||||
{
|
||||
if (arg.hasTag ("TAG") &&
|
||||
arg.hasTag ("FILTER"))
|
||||
{
|
||||
references.emplace_back (arg.attribute ("raw"));
|
||||
}
|
||||
}
|
||||
|
||||
return references;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue