diff options
author | Michael Vogt <michael.vogt@ubuntu.com> | 2011-07-28 13:57:40 +0200 |
---|---|---|
committer | Michael Vogt <michael.vogt@ubuntu.com> | 2011-07-28 13:57:40 +0200 |
commit | d3d8ed4a439ffaa0cdec7053001f5810016a4c44 (patch) | |
tree | 87c15dc6eee06474f151928f863899cdc0403f97 /apt-pkg/deb | |
parent | c6ec544822a6a5db9f8a507b08381f19c8787761 (diff) | |
parent | b20c16833e20da8e367221b32764889cafe5b4c1 (diff) |
merged from debian-experimental2
Diffstat (limited to 'apt-pkg/deb')
-rw-r--r-- | apt-pkg/deb/debrecords.cc | 9 | ||||
-rw-r--r-- | apt-pkg/deb/debrecords.h | 3 |
2 files changed, 12 insertions, 0 deletions
diff --git a/apt-pkg/deb/debrecords.cc b/apt-pkg/deb/debrecords.cc index 1ca9ae1d2..f323c03c2 100644 --- a/apt-pkg/deb/debrecords.cc +++ b/apt-pkg/deb/debrecords.cc @@ -101,6 +101,15 @@ string debRecordParser::Maintainer() return Section.FindS("Maintainer"); } /*}}}*/ +// RecordParser::RecordField - Return the value of an arbitrary field /*{{*/ +// --------------------------------------------------------------------- +/* */ +string debRecordParser::RecordField(const char *fieldName) +{ + return Section.FindS(fieldName); +} + + /*}}}*/ // RecordParser::ShortDesc - Return a 1 line description /*{{{*/ // --------------------------------------------------------------------- /* */ diff --git a/apt-pkg/deb/debrecords.h b/apt-pkg/deb/debrecords.h index 9692ac94c..7868bfa3d 100644 --- a/apt-pkg/deb/debrecords.h +++ b/apt-pkg/deb/debrecords.h @@ -50,6 +50,9 @@ class debRecordParser : public pkgRecords::Parser virtual string Name(); virtual string Homepage(); + // An arbitrary custom field + virtual string RecordField(const char *fieldName); + virtual void GetRec(const char *&Start,const char *&Stop); debRecordParser(string FileName,pkgCache &Cache); |