[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#513236: please add access to all package versions via apt.package.Package



On Wed, Jan 28, 2009 at 10:39:23AM +0100, Julian Andres Klode wrote:
> > Yes, I can access all of them using the low-level apt_pkg API, but it
> > is way more cumbersome. I believe it'd make sense to have an iterator
> > over all available versions of the current package, in the high-level
> > API.
>
> Yes of course. I will see if I can do this. My plan would be to create a
> class Version, and add an iterator versions to apt.package.Package.And
> reimplement candidateX()  and installedX() methods to use this class.

Many thanks.

By the way, my intended use case for this is actually not to only
access the version as a string (which AFAICT is the only access you
can get right now from the high-level API), but rather to access the
whole set of information corresponding to a given version
(dependencies and other fields).

Just getting a list of version numbers is kinda useless unless you can
"join" them with their information.

Do you think it would be possible to have that as well?

Cheers.

-- 
Stefano Zacchiroli -o- PhD in Computer Science \ PostDoc @ Univ. Paris 7
zack@{upsilon.cc,pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/
Dietro un grande uomo c'è ..|  .  |. Et ne m'en veux pas si je te tutoie
sempre uno zaino ...........| ..: |.... Je dis tu à tous ceux que j'aime



Reply to: