apt  2.2.4
About: Apt (Advanced Package Tool) is a management system for software packages (Debian/Ubuntu). Release series 2.2.
  Fossies Dox: apt-2.2.4.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

pkgSourceList Class Reference

#include <sourcelist.h>

Classes

class  Type
 

Public Types

typedef std::vector< metaIndex * >::const_iterator const_iterator
 

Public Member Functions

bool ReadMainList ()
 
bool Read (std::string const &File)
 
void Reset ()
 
bool ReadAppend (std::string const &File)
 
bool ReadSourceDir (std::string const &Dir)
 
const_iterator begin () const
 
const_iterator end () const
 
unsigned int size () const
 
bool empty () const
 
bool FindIndex (pkgCache::PkgFileIterator File, pkgIndexFile *&Found) const
 
bool GetIndexes (pkgAcquire *Owner, bool GetAll=false) const
 
time_t GetLastModifiedTime ()
 
void AddVolatileFile (pkgIndexFile *const File)
 add file for parsing, but not to the cache More...
 
bool AddVolatileFile (std::string const &File)
 
bool AddVolatileFile (std::string const &File, std::vector< std::string > *const VolatileCmdL)
 
void AddVolatileFiles (CommandLine &CmdL, std::vector< std::string > *const VolatileCmdL)
 
std::vector< pkgIndexFile * > GetVolatileFiles () const
 
 pkgSourceList ()
 
virtual ~pkgSourceList ()
 

Protected Attributes

std::vector< metaIndex * > SrcList
 

Private Member Functions

APT_HIDDEN bool ParseFileDeb822 (std::string const &File)
 
APT_HIDDEN bool ParseFileOldStyle (std::string const &File)
 

Private Attributes

void *const d
 
std::vector< pkgIndexFile * > VolatileFiles
 

Detailed Description

Definition at line 42 of file sourcelist.h.

Member Typedef Documentation

◆ const_iterator

typedef std::vector<metaIndex *>::const_iterator const_iterator

Definition at line 76 of file sourcelist.h.

Constructor & Destructor Documentation

◆ pkgSourceList()

Definition at line 287 of file sourcelist.cc.

◆ ~pkgSourceList()

~pkgSourceList ( )
virtual

Definition at line 294 of file sourcelist.cc.

References I, SrcList, and VolatileFiles.

Member Function Documentation

◆ AddVolatileFile() [1/3]

void AddVolatileFile ( pkgIndexFile *const  File)

add file for parsing, but not to the cache

pkgIndexFiles originating from pkgSourcesList are included in srcpkgcache, the status files added via #AddStatusFiles are included in pkgcache, but these files here are not included in any cache to have the possibility of having a file included just for a single run like a local .deb/.dsc file.

The volatile files do not count as "normal" sourceslist entries, can't be iterated over with begin and end and can't be downloaded, but they can be found via FindIndex.

Parameters
Fileis an index file; pointer-ownership is transferred

Definition at line 535 of file sourcelist.cc.

References VolatileFiles.

Referenced by pkgCacheFile::AddIndexFile(), AddVolatileBinaryFile(), AddVolatileFile(), AddVolatileSourceFile(), and ReadMainList().

◆ AddVolatileFile() [2/3]

bool AddVolatileFile ( std::string const &  File)

Definition at line 607 of file sourcelist.cc.

References AddVolatileFile().

◆ AddVolatileFile() [3/3]

bool AddVolatileFile ( std::string const &  File,
std::vector< std::string > *const  VolatileCmdL 
)

◆ AddVolatileFiles()

void AddVolatileFiles ( CommandLine CmdL,
std::vector< std::string > *const  VolatileCmdL 
)

Definition at line 612 of file sourcelist.cc.

References CommandLine::FileList, CommandLine::FileSize(), and I.

◆ begin()

◆ empty()

bool empty ( ) const
inline

Definition at line 100 of file sourcelist.h.

◆ end()

◆ FindIndex()

bool FindIndex ( pkgCache::PkgFileIterator  File,
pkgIndexFile *&  Found 
) const

◆ GetIndexes()

bool GetIndexes ( pkgAcquire Owner,
bool  GetAll = false 
) const

Definition at line 484 of file sourcelist.cc.

References I, and SrcList.

Referenced by DoUpdate(), and ListUpdate().

◆ GetLastModifiedTime()

time_t GetLastModifiedTime ( )

Definition at line 510 of file sourcelist.cc.

References _config, DirectoryExists(), GetListOfFilesInDir(), and GetModificationTime().

Referenced by CheckValidity().

◆ GetVolatileFiles()

std::vector< pkgIndexFile * > GetVolatileFiles ( ) const
Returns
list of files registered with AddVolatileFile

Definition at line 530 of file sourcelist.cc.

References VolatileFiles.

Referenced by AddIfVolatile(), DoBuildDep(), and pkgCacheGenerator::MakeStatusCache().

◆ ParseFileDeb822()

◆ ParseFileOldStyle()

bool ParseFileOldStyle ( std::string const &  File)
private

◆ Read()

bool Read ( std::string const &  File)

Definition at line 350 of file sourcelist.cc.

References ReadAppend(), and Reset().

◆ ReadAppend()

bool ReadAppend ( std::string const &  File)

Definition at line 359 of file sourcelist.cc.

References flExtension(), ParseFileDeb822(), and ParseFileOldStyle().

Referenced by Read(), ReadMainList(), and ReadSourceDir().

◆ ReadMainList()

◆ ReadSourceDir()

bool ReadSourceDir ( std::string const &  Dir)

Definition at line 497 of file sourcelist.cc.

References GetListOfFilesInDir(), I, and ReadAppend().

Referenced by ReadMainList().

◆ Reset()

void Reset ( )

Definition at line 340 of file sourcelist.cc.

References I, and SrcList.

Referenced by Read(), and ReadMainList().

◆ size()

unsigned int size ( ) const
inline

Definition at line 99 of file sourcelist.h.

Member Data Documentation

◆ d

void* const d
private

Definition at line 44 of file sourcelist.h.

◆ SrcList

std::vector<metaIndex *> SrcList
protected

◆ VolatileFiles

std::vector<pkgIndexFile*> VolatileFiles
private

Definition at line 45 of file sourcelist.h.

Referenced by AddVolatileFile(), FindIndex(), GetVolatileFiles(), and ~pkgSourceList().


The documentation for this class was generated from the following files: