summaryrefslogtreecommitdiff
path: root/apt-pkg/deb/debrecords.h
diff options
context:
space:
mode:
authorMichael Vogt <mvo@ubuntu.com>2014-04-26 00:00:51 +0200
committerMichael Vogt <mvo@ubuntu.com>2014-04-28 09:59:33 +0200
commit0d29b9d4368284782862c7b507c47002b79ddb27 (patch)
treebcf0fa5d55cce7eba85f20235648d1728b104924 /apt-pkg/deb/debrecords.h
parenta298a1dc595c548e6c10b48b8e69d987e5be1c42 (diff)
WIP local deb install
Diffstat (limited to 'apt-pkg/deb/debrecords.h')
-rw-r--r--apt-pkg/deb/debrecords.h18
1 files changed, 14 insertions, 4 deletions
diff --git a/apt-pkg/deb/debrecords.h b/apt-pkg/deb/debrecords.h
index bdac6c90b..d572bc5c2 100644
--- a/apt-pkg/deb/debrecords.h
+++ b/apt-pkg/deb/debrecords.h
@@ -29,17 +29,16 @@ class debRecordParser : public pkgRecords::Parser
{
/** \brief dpointer placeholder (for later in case we need it) */
void *d;
-
+
+ protected:
FileFd File;
pkgTagFile Tags;
pkgTagSection Section;
- protected:
-
virtual bool Jump(pkgCache::VerFileIterator const &Ver);
virtual bool Jump(pkgCache::DescFileIterator const &Desc);
- public:
+ public:
// These refer to the archive file for the Version
virtual std::string FileName();
@@ -66,4 +65,15 @@ class debRecordParser : public pkgRecords::Parser
virtual ~debRecordParser() {};
};
+// custom record parser that reads deb files directly
+class debDebFileRecordParser : public debRecordParser
+{
+ public:
+ virtual std::string FileName() {
+ return File.Name();
+ }
+ debDebFileRecordParser(std::string FileName,pkgCache &Cache)
+ : debRecordParser(FileName, Cache) {};
+};
+
#endif