From 302a5e275fc9e3515a1dac9ff929b537b2c212a3 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Tue, 6 Jan 2009 14:05:35 +0000 Subject: document a "hack" --- URPM.pm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/URPM.pm b/URPM.pm index 87e3906..84ced15 100644 --- a/URPM.pm +++ b/URPM.pm @@ -97,6 +97,7 @@ sub build_listid { (($start || 0) .. (defined($end) ? $end : $#{$urpm->{depslist}})); } +#- this is used when faking a URPM::DB: $urpm can be used as-a $db sub traverse { my ($urpm, $callback) = @_; @@ -109,6 +110,8 @@ sub traverse { scalar @{$urpm->{depslist} || []}; } + +#- this is used when faking a URPM::DB: $urpm can be used as-a $db sub traverse_tag { my ($urpm, $tag, $names, $callback) = @_; my $count = 0; @@ -376,6 +379,8 @@ this $urpm. The behaviour of the search is influenced by several options: Executes the callback for each package in the depslist, passing a C object as argument the callback. +This is used when faking a URPM::DB: $urpm can be used as-a $db + =item $urpm->traverse_tag($tag, $names, $callback) $tag may be one of C, C, C, C, @@ -384,6 +389,8 @@ $names is a reference to an array, holding the acceptable values of the said tag for the searched variables. Then, $callback is called for each matching package in the depslist. +This is used when faking a URPM::DB: $urpm can be used as-a $db + =item URPM::verify_rpm($file, %options) Verifies an RPM file. -- cgit v1.2.1