- backport forgotten Valid-Until patch from the obsolete experimental
[ntk/apt.git] / apt-pkg / indexrecords.cc
index 3bde743..eb9a368 100644 (file)
@@ -39,6 +39,11 @@ const indexRecords::checkSum *indexRecords::Lookup(const string MetaKey)
    return Entries[MetaKey];
 }
 
+bool indexRecords::Exists(string const &MetaKey) const
+{
+   return Entries.count(MetaKey) == 1;
+}
+
 bool indexRecords::Load(const string Filename)                         /*{{{*/
 {
    FileFd Fd(Filename, FileFd::ReadOnly);