Qua, 2007-06-27 às 14:53 +0200, Katarina Machalkova escreveu:
I don't have any feature request for libzypp; we can work out things pretty easily (say, dependencies listing), and I think it already has enough bloat. :P
Well, the idea steadily evolved into something like 'writing a wrapper over libzypp' (called 'zypp4ui' for the time being) so that an application that needs to call libzypp function doesn't have to use libzypp low-level functions. Example: in your application, instead of doing:
Your example is a bit too simplistic (without knowing the use case, I don't see how you can't write simpler code using the pool instead of the list structure). But okay, I think the Zypp pool is deficient for some purposes, and having more, specific managers could help cut on code, and the usage of auxiliary structures in our part (though it is a bit wasteful...). For instance, to build a tree for the package groups, you would need to iterate the pool, asking each package for their group string (which would be something like "Productivity/Office"). Since they are not sorted, you need an auxiliary structure to map the groups to the node of the interface tree that you create as you iterate the pool. There could be ways to avoid this by either returning a more fit structure, or use better sorting. The first breaks way with the pool, the second asks for it be decentralized. The pool would also be completely bloated if it allowed one to set it possible to only iterate packages of a certain pattern, and other settings in a centralized way. So, having this specific managers would be better. However, I hope this library will be seen as more of a stub to be eventually adopted to libzypp (it's not even like you don't have the resources), rather than a serious, permanent library (a wrapper of a wrapper is undesirable on several accounts). Cheers, Ricardo -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org