X-Git-Url: http://git.hcoop.net/ntk/apt.git/blobdiff_plain/a1e68c33ac15be454984b00d62c7fc331bd0b32b..1038d077588956448a423ed1c3887524a90d6532:/apt-pkg/tagfile.h diff --git a/apt-pkg/tagfile.h b/apt-pkg/tagfile.h index a5bf5ac9..d5b62e76 100644 --- a/apt-pkg/tagfile.h +++ b/apt-pkg/tagfile.h @@ -20,10 +20,16 @@ #ifndef PKGLIB_TAGFILE_H #define PKGLIB_TAGFILE_H +#include + #include #include +#ifndef APT_8_CLEANER_HEADERS +#include +#endif + class FileFd; class pkgTagSection @@ -55,13 +61,13 @@ class pkgTagSection inline bool operator !=(const pkgTagSection &rhs) {return Section != rhs.Section;}; bool Find(const char *Tag,const char *&Start, const char *&End) const; - bool Find(const char *Tag,unsigned &Pos) const; + bool Find(const char *Tag,unsigned int &Pos) const; std::string FindS(const char *Tag) const; signed int FindI(const char *Tag,signed long Default = 0) const ; unsigned long long FindULL(const char *Tag, unsigned long long const &Default = 0) const; bool FindFlag(const char *Tag,unsigned long &Flags, unsigned long Flag) const; - bool static const FindFlag(unsigned long &Flags, unsigned long Flag, + bool static FindFlag(unsigned long &Flags, unsigned long Flag, const char* Start, const char* Stop); bool Scan(const char *Start,unsigned long MaxLength); inline unsigned long size() const {return Stop - Section;}; @@ -69,7 +75,7 @@ class pkgTagSection virtual void TrimRecord(bool BeforeRecord, const char* &End); inline unsigned int Count() const {return TagCount;}; - inline bool Exists(const char* const Tag) {return AlphaIndexes[AlphaHash(Tag)] != 0;} + bool Exists(const char* const Tag); inline void Get(const char *&Start,const char *&Stop,unsigned int I) const {Start = Section + Indexes[I]; Stop = Section + Indexes[I+1];} @@ -80,7 +86,7 @@ class pkgTagSection Stop = this->Stop; }; - pkgTagSection() : Section(0), TagCount(0), Stop(0) {}; + pkgTagSection(); virtual ~pkgTagSection() {}; }; @@ -89,8 +95,9 @@ class pkgTagFile { pkgTagFilePrivate *d; - bool Fill(); - bool Resize(); + APT_HIDDEN bool Fill(); + APT_HIDDEN bool Resize(); + APT_HIDDEN bool Resize(unsigned long long const newSize); public: