Sfoglia il codice sorgente

rename packageset into cacheset while it is not too late

David Kalnischkies 16 anni fa
parent
commit
7959c5eda8
6 ha cambiato i file con 19 aggiunte e 15 eliminazioni
  1. 3 3
      apt-pkg/packageset.cc
  2. 11 7
      apt-pkg/packageset.h
  3. 2 2
      apt-pkg/makefile
  4. 1 1
      cmdline/apt-cache.cc
  5. 1 1
      cmdline/apt-get.cc
  6. 1 1
      debian/changelog

+ 3 - 3
apt-pkg/packageset.cc

@@ -3,15 +3,15 @@
 /* ######################################################################
 
    Simple wrapper around a std::set to provide a similar interface to
-   a set of packages as to the complete set of all packages in the
-   pkgCache.
+   a set of cache structures as to the complete set of all structures
+   in the pkgCache. Currently only Package is supported.
 
    ##################################################################### */
 									/*}}}*/
 // Include Files							/*{{{*/
 #include <apt-pkg/aptconfiguration.h>
 #include <apt-pkg/error.h>
-#include <apt-pkg/packageset.h>
+#include <apt-pkg/cacheset.h>
 #include <apt-pkg/strutl.h>
 
 #include <apti18n.h>

+ 11 - 7
apt-pkg/packageset.h

@@ -1,14 +1,13 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-/** \class APT::PackageSet
+/** \file cacheset.h
+   Wrappers around std::set to have set::iterators which behave
+   similar to the Iterators of the cache structures.
 
-    Simple wrapper around a std::set to provide a similar interface to
-    a set of packages as to the complete set of all packages in the
-    pkgCache.
-*/
+   Provides also a few helper methods which work with these sets */
 									/*}}}*/
-#ifndef APT_PACKAGESET_H
-#define APT_PACKAGESET_H
+#ifndef APT_CACHESET_H
+#define APT_CACHESET_H
 // Include Files							/*{{{*/
 #include <iostream>
 #include <fstream>
@@ -18,6 +17,11 @@
 #include <apt-pkg/pkgcache.h>
 									/*}}}*/
 namespace APT {
+/** \class APT::PackageSet
+
+    Simple wrapper around a std::set to provide a similar interface to
+    a set of packages as to the complete set of all packages in the
+    pkgCache. */
 class PackageSet : public std::set<pkgCache::PkgIterator> {		/*{{{*/
 public:									/*{{{*/
 	/** \brief smell like a pkgCache::PkgIterator */

+ 2 - 2
apt-pkg/makefile

@@ -35,7 +35,7 @@ SOURCE+= pkgcache.cc version.cc depcache.cc \
 	 srcrecords.cc cachefile.cc versionmatch.cc policy.cc \
 	 pkgsystem.cc indexfile.cc pkgcachegen.cc acquire-item.cc \
 	 indexrecords.cc vendor.cc vendorlist.cc cdrom.cc indexcopy.cc \
-	 aptconfiguration.cc packageset.cc
+	 aptconfiguration.cc cacheset.cc
 HEADERS+= algorithms.h depcache.h pkgcachegen.h cacheiterators.h \
 	  orderlist.h sourcelist.h packagemanager.h tagfile.h \
 	  init.h pkgcache.h version.h progress.h pkgrecords.h \
@@ -43,7 +43,7 @@ HEADERS+= algorithms.h depcache.h pkgcachegen.h cacheiterators.h \
 	  clean.h srcrecords.h cachefile.h versionmatch.h policy.h \
 	  pkgsystem.h indexfile.h metaindex.h indexrecords.h vendor.h \
           vendorlist.h cdrom.h indexcopy.h aptconfiguration.h \
-	  packageset.h
+	  cacheset.h
 
 # Source code for the debian specific components
 # In theory the deb headers do not need to be exported..

+ 1 - 1
cmdline/apt-cache.cc

@@ -29,7 +29,7 @@
 #include <apt-pkg/tagfile.h>
 #include <apt-pkg/algorithms.h>
 #include <apt-pkg/sptr.h>
-#include <apt-pkg/packageset.h>
+#include <apt-pkg/cacheset.h>
 
 #include <config.h>
 #include <apti18n.h>

+ 1 - 1
cmdline/apt-get.cc

@@ -40,7 +40,7 @@
 #include <apt-pkg/sptr.h>
 #include <apt-pkg/md5.h>
 #include <apt-pkg/versionmatch.h>
-#include <apt-pkg/packageset.h>
+#include <apt-pkg/cacheset.h>
 
 #include <config.h>
 #include <apti18n.h>

+ 1 - 1
debian/changelog

@@ -22,7 +22,7 @@ apt (0.7.26~exp6) UNRELEASED; urgency=low
     - correct "Dangerous iterator usage." pointed out by cppcheck
   * ftparchive/writer.h:
     - add a virtual destructor to FTWScanner class (for cppcheck)
-  * apt-pkg/packageset.h:
+  * apt-pkg/cacheset.h:
     - add a simple wrapper around std::set for packages with it
     - move regex magic from apt-get to new FromRegEx method
     - move cmdline parsing from apt-cache to new FromCommandLine method