]>
git.saurik.com Git - apt.git/blob - apt-pkg/indexrecords.h
1 // -*- mode: cpp; mode: fold -*-
3 // $Id: indexrecords.h,v 1.1.2.1 2003/12/24 23:09:17 mdz Exp $
5 #ifndef PKGLIB_INDEXRECORDS_H
6 #define PKGLIB_INDEXRECORDS_H
9 #include <apt-pkg/pkgcache.h>
10 #include <apt-pkg/hashes.h>
18 bool parseSumData(const char *&Start
, const char *End
, std::string
&Name
,
19 std::string
&Hash
, unsigned long long &Size
);
22 std::string ErrorText
;
27 std::string ExpectedDist
;
30 std::map
<std::string
,checkSum
*> Entries
;
35 indexRecords(const std::string ExpectedDist
);
38 virtual const checkSum
*Lookup(const std::string MetaKey
);
39 /** \brief tests if a checksum for this file is available */
40 bool Exists(std::string
const &MetaKey
) const;
41 std::vector
<std::string
> MetaKeys();
43 virtual bool Load(std::string Filename
);
44 std::string
GetDist() const;
45 time_t GetValidUntil() const;
46 virtual bool CheckDist(const std::string MaybeDist
) const;
47 std::string
GetExpectedDist() const;
48 virtual ~indexRecords(){};
51 struct indexRecords::checkSum
53 std::string MetaKeyFilename
;
55 unsigned long long Size
;