diff options
| author | Julian Andres Klode <jak@debian.org> | 2011-04-04 09:56:18 +0200 |
|---|---|---|
| committer | Julian Andres Klode <jak@debian.org> | 2011-04-04 09:56:18 +0200 |
| commit | 71e419a088092a3f6c62836d7bd09f952133fb3f (patch) | |
| tree | 69f33b78b78b94e6c84f56f903e000c2fd579232 /doc/source/library | |
| parent | e12fa9b90458f31b9bc3ceeab7c4c106113cab53 (diff) | |
| download | python-apt-71e419a088092a3f6c62836d7bd09f952133fb3f.tar.gz | |
* python/cache.cc:
- Add Package.get_fullname() and Package.architecture
Diffstat (limited to 'doc/source/library')
| -rw-r--r-- | doc/source/library/apt_pkg.rst | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/doc/source/library/apt_pkg.rst b/doc/source/library/apt_pkg.rst index 81358bac..426cb97e 100644 --- a/doc/source/library/apt_pkg.rst +++ b/doc/source/library/apt_pkg.rst @@ -437,18 +437,35 @@ Resolving Dependencies with :class:`ProblemResolver` ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ .. class:: Package - Represent a package. A package is uniquely identified by its name - and each package can have zero or more versions which can be + Represent a package. A package is uniquely identified by its name and + architecture and each package can have zero or more versions which can be accessed via the :attr:`version_list` property. Packages can be installed and removed by a :class:`DepCache` object. Attributes: + .. attribute: architecture + + The architecture of the package. This is relevant on multi-arch + systems only. Please note that if a package is Architecture: all, + this value is not "all", but the architecture of the package file + it comes from. + + .. versionadded:: 0.7.100.3 + .. attribute:: current_ver The version currently installed as a :class:`Version` object, or None if the package is not installed. + .. method:: get_fullname([pretty: bool = False]) -> str + + Get the full name of the package, including the architecture. If + *pretty* is ``True``, the architecture is omitted for native packages, + that is, an amd64 "apt" package on an amd64 system would give "apt". + + .. versionadded:: 0.7.100.3 + .. attribute:: has_provides A boolean value determining whether the list available via the |
