Enhancement - Record::has

- Implemented Record::has which guarantees no autovivification of
  attributes.
This commit is contained in:
Paul Beckingham
2009-06-11 20:29:53 -04:00
parent 1ff3e73ebc
commit 754b79afb2
3 changed files with 16 additions and 1 deletions

View File

@@ -116,6 +116,16 @@ void Record::parse (const std::string& input)
"Record not recognized as format 4");
}
////////////////////////////////////////////////////////////////////////////////
bool Record::has (const std::string& name) const
{
Record::const_iterator i = this->find (name);
if (i != this->end ())
return true;
return false;
}
////////////////////////////////////////////////////////////////////////////////
std::vector <Att> Record::all ()
{