Next: PKGFSCache
Up: PkgDebian
Previous: extern Configuration *_config
Indice
-
: the constructor configures the object pointed
by
through the functions
and
. They must be invoked before calling
many APT library functions. Both these functions are defined in
;
-
: it returns the pathname of the APT
packages cache;
-
pkgPtr,
buffer
:
it fills the buffer with the metadata of the package identified
by pkgPtr. Currently they are: name, version, section, priority,
dependencies, packages provided, description, maintainer and filename
in the pool of packages repository. We described how to get most
of them in the
class description;
-
pkgPtr,
buffer
and
pkgPtr,
buffer
:
these methods
mainly use a
instance. As we have shown in
section 5.3.4.2, this kind of object can
iterate over lists of version dependencies and package reverse dependencies.
Thus, the only difference between them consists in the set of data
being iterated. If we consider
a
instance, the version dependencies are iterated by
, the package reverse dependencies
by
;
-
pkg_name,
buffer
:
it fills the buffer with the names of the files owned by the package
pkg_name. It slightly differs from the other
functions since the package is not identified by the cache entry pointer,
but by its name. This is due to the Debian particular way in managing
owned files. They are
stored in the files
pkg_name
and
pkg_name
.
Caching of
files content will be the next step
in APT development[Gun03]. Although this facility is not
supported, it does not represent a big problem to PackageFS, since
in the next version our implementation will provide overloading functions
for some PkgManager methods. They will be useful for other package
managers;
-
pkg_name,
options
and
pkg_name,
options
: these methods call respectively the
command apt-get install and apt-get remove.
By default the -qq option is given to make
APT silent and ever assuming positive answers. The other associated
options are retrieved by
methods. While a package
is being installed, it is pre-configured by debconf, which
arises the interactivity problem: we repeat here that the daemon process
has to raise neither input, nor output requests through its standard
communication channels. Thus we check for the
environment value, so that we set the
variable to make debconf using the appropriate frontend. If the debconf
graphical interface can be run, the administrator is able to set the
configuration options, since he is asked for them in a separate window.
If
is not set, the debconf frontend becomes non-interactive
and the administrator has to subsequently run the configuration procedure
by himself (i.e. with the command
pkg_name);
-
: it runs apt-get update;
-
: it runs apt-get upgrade.
Next: PKGFSCache
Up: PkgDebian
Previous: extern Configuration *_config
Indice
2004-11-19