Michael Andres wrote:
On Mon, Apr 21, Duncan Mac-Vicar Prett wrote:
Jan Kupec wrote:
Hi,
I'm just fixing some zypper queries and started to use the following function to print the patch status. Is it right?
string string_ppp_status(const PoolItem & pi) { if (pi.isRelevant()) { if (pi.isSatisfied()) return _("Installed");
Should we call it 'installed'? It is not installed and you can't delete it. Call it 'applied'?
if (pi.isBroken()) return _("Needed"); // can this ever happen? return ""; }
return _("Not Applicable"); }
Q: what should isRelevant() return for patterns/products?
jano
I think isBroken has no meaning now, as the patch is never installed, and
I think you think wrong.
There are 4 mutual exclusive states:
isUndetermined: No validation is performed (for packages).
! isRelevant: Not a single package mentioned by this item is installed.
isSatisfied: A relevant items requirements are met.
isBroken: A relevant items requirements are broken.
Makes sense. One more question: how does this apply to Patterns and Products? I guess isRelevant is not relevant here :O) So is isBroken. The only that we care for the product or patterns is isSatisified()? jano -- To unsubscribe, e-mail: zypp-devel+unsubscribe@opensuse.org For additional commands, e-mail: zypp-devel+help@opensuse.org