libapt-pkg-dev  v0.9.7.5ubuntu5.4
Debian+Ubuntu APT Package Management
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pkgCache::Package Struct Reference

contains information for a single unique package More...

#include <pkgcache.h>

Collaboration diagram for pkgCache::Package:

Public Attributes

map_ptrloc Arch
 Architecture of the package. More...
 
unsigned char CurrentState
 indicates if the package is installed More...
 
map_ptrloc CurrentVer
 index to the installed version More...
 
unsigned long Flags
 some useful indicators of the package's state More...
 
map_ptrloc Group
 index of the group this package belongs to More...
 
unsigned int ID
 unique sequel ID More...
 
unsigned char InstState
 installation state of the package More...
 
map_ptrloc Name
 Name of the package. More...
 
map_ptrloc NextPackage
 Link to the next package in the same bucket. More...
 
map_ptrloc ProvidesList
 List of all "packages" this package provide. More...
 
map_ptrloc RevDepends
 List of all dependencies on this package. More...
 
map_ptrloc Section
 indicates the deduced section More...
 
unsigned char SelectedState
 state that the user wishes the package to be in More...
 
map_ptrloc VersionList
 Base of a singly linked list of versions. More...
 

Detailed Description

contains information for a single unique package

There can be any number of versions of a given package. Package exists in a singly linked list of package records starting at the hash index of the name in the pkgCache::Header::PkgHashTable

A package can be created for every architecture so package names are not unique, but it is garanteed that packages with the same name are sequencel ordered in the list. Packages with the same name can be accessed with the Group.

Member Data Documentation

map_ptrloc pkgCache::Package::Arch

Architecture of the package.

Referenced by pkgCache::PkgIterator::Arch().

unsigned char pkgCache::Package::CurrentState

indicates if the package is installed

Referenced by pkgCache::PkgIterator::Purge().

map_ptrloc pkgCache::Package::CurrentVer

index to the installed version

Referenced by pkgCache::PkgIterator::Purge().

unsigned long pkgCache::Package::Flags

some useful indicators of the package's state

map_ptrloc pkgCache::Package::Group

index of the group this package belongs to

Referenced by pkgCache::PkgIterator::Group().

unsigned int pkgCache::Package::ID

unique sequel ID

ID is a unique value from 0 to Header->PackageCount assigned by the generator. This allows clients to create an array of size PackageCount and use it to store state information for the package map. For instance the status file emitter uses this to track which packages have been emitted already.

unsigned char pkgCache::Package::InstState

installation state of the package

This should be "ok" but in case the installation failed it will be different.

map_ptrloc pkgCache::Package::Name

Name of the package.

Referenced by pkgCache::PkgIterator::Name(), and pkgCache::PrvIterator::Name().

map_ptrloc pkgCache::Package::NextPackage

Link to the next package in the same bucket.

map_ptrloc pkgCache::Package::ProvidesList

List of all "packages" this package provide.

map_ptrloc pkgCache::Package::RevDepends

List of all dependencies on this package.

map_ptrloc pkgCache::Package::Section

indicates the deduced section

Should be the index to the string "Unknown" or to the section of the last parsed item.

Referenced by pkgCache::PkgIterator::Section().

unsigned char pkgCache::Package::SelectedState

state that the user wishes the package to be in

map_ptrloc pkgCache::Package::VersionList

Base of a singly linked list of versions.

Each structure represents a unique version of the package. The version structures contain links into PackageFile and the original text file as well as detailed information about the size and dependencies of the specific package. In this way multiple versions of a package can be cleanly handled by the system. Furthermore, this linked list is guaranteed to be sorted from Highest version to lowest version with no duplicate entries.


The documentation for this struct was generated from the following file: