apt @VERSION@
Public Attributes

pkgCache::Package Struct Reference

contains information for a single unique package More...

#include <pkgcache.h>

List of all members.

Public Attributes

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

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

unsigned int 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 InstState

installation state of the package

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

map_ptrloc Section

indicates the deduced section

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

map_ptrloc 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: