Skip to content

Commit

Permalink
added ability to list keys of APIData objects
Browse files Browse the repository at this point in the history
  • Loading branch information
beniz committed Mar 8, 2015
1 parent 7ec791b commit 0c2ee82
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/apidata.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,16 @@ namespace dd
else return false;
}

std::vector<std::string> list_keys() const
{
std::vector<std::string> keys;
for (auto kv: _data)
{
keys.push_back(kv.first);
}
return keys;
}

/**
* \brief number of hosted keys at this level of the object
* @return size
Expand Down

0 comments on commit 0c2ee82

Please sign in to comment.