[packagekit] New api?: GetSize

Stanislav Visnovsky visnov at suse.cz
Mon Apr 14 07:46:34 PDT 2008


Dňa Sunday 13 April 2008 11:53:37 Richard Hughes ste napísal:
> I've been thinking of a new API call:
>
> GetSize(b=installed, as=packages)
>
> if installed is TRUE, the package installed size is returned (how much
> space does it take on disk) and if FALSE the download size (how much
> bandwidth will it use).
>
> The packages parameter will be an array of packages.
>
> This new API will tell us exactly the size of the packages that have
> been selected to update, and the installed size of any installed
> packages. This allows us to show the user how many Mb's will be
> downloaded (even my girlfriend understands 100Mb=long time,
> 100kb=instant) and also allows us to check for low disk space _before_
> we try to install something like openarena.
>
> Is this something your backend could support? Easy to add? Comments
> please!

For uninstalled packages you need both download size and the installed size. 
This is cleaner approach as it gives UI a complete picture. In the worst case 
you need downloadsize + installsize for installing a package.

Stano



More information about the PackageKit mailing list