]> git.saurik.com Git - apt.git/blame - apt-pkg/vendorlist.h
apt-pkg/contrib/configuration.cc: revert Configuration::Set() ABI break
[apt.git] / apt-pkg / vendorlist.h
CommitLineData
b3d44315
MV
1// -*- mode: cpp; mode: fold -*-
2// Description /*{{{*/
3// $Id: vendorlist.h,v 1.1.2.1 2003/12/24 23:09:17 mdz Exp $
4/* ######################################################################
5
6 VendorList - Manage a list of vendors
7
8 The Vendor List class provides access to a list of vendors and
9 attributes associated with them, read from a configuration file.
10
11 ##################################################################### */
12 /*}}}*/
13#ifndef PKGLIB_VENDORLIST_H
14#define PKGLIB_VENDORLIST_H
15
16#include <string>
17#include <vector>
18#include <apt-pkg/vendor.h>
19#include <apt-pkg/configuration.h>
82b6682a 20#include <apt-pkg/macros.h>
b3d44315
MV
21
22using std::string;
23using std::vector;
24
b3d44315 25
82b6682a 26class __deprecated pkgVendorList
b3d44315
MV
27{
28 protected:
29 vector<Vendor const *> VendorList;
30
31 bool CreateList(Configuration& Cnf);
32 const Vendor* LookupFingerprint(string Fingerprint);
33
34 public:
35 typedef vector<Vendor const *>::const_iterator const_iterator;
36 bool ReadMainList();
37 bool Read(string File);
38
39 // List accessors
40 inline const_iterator begin() const {return VendorList.begin();};
41 inline const_iterator end() const {return VendorList.end();};
42 inline unsigned int size() const {return VendorList.size();};
43 inline bool empty() const {return VendorList.empty();};
44
45 const Vendor* FindVendor(const vector<string> GPGVOutput);
46
47 ~pkgVendorList();
48};
49
50#endif