aboutsummaryrefslogtreecommitdiff
path: root/doc/api/ruby
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-11-13 00:01:03 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-11-13 15:42:28 +0000
commit635179144839fa31015fe85cd9226a655d217f03 (patch)
tree3756d05592232534a80d52fcc8e50ee7dc319768 /doc/api/ruby
parent8ae61a8b1335efdaef0208a138b178ba221b4b18 (diff)
downloadpaludis-635179144839fa31015fe85cd9226a655d217f03.tar.gz
paludis-635179144839fa31015fe85cd9226a655d217f03.tar.xz
Add MatchPackageOptions.
Fixes: ticket:655
Diffstat (limited to 'doc/api/ruby')
-rw-r--r--doc/api/ruby/example_action.rb2
-rw-r--r--doc/api/ruby/example_contents.rb2
-rw-r--r--doc/api/ruby/example_environment.rb2
-rw-r--r--doc/api/ruby/example_mask.rb2
-rw-r--r--doc/api/ruby/example_match_package.rb6
-rw-r--r--doc/api/ruby/example_package_id.rb2
-rw-r--r--doc/api/ruby/example_selection.rb8
7 files changed, 12 insertions, 12 deletions
diff --git a/doc/api/ruby/example_action.rb b/doc/api/ruby/example_action.rb
index 79223444c..8cd500f9d 100644
--- a/doc/api/ruby/example_action.rb
+++ b/doc/api/ruby/example_action.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(Generator::Matches.new(
- Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
+ Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, []), []))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_contents.rb b/doc/api/ruby/example_contents.rb
index 2b48be9ea..c748c5ce0 100644
--- a/doc/api/ruby/example_contents.rb
+++ b/doc/api/ruby/example_contents.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for installed 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, []), []) |
Filter::SupportsAction.new(InstalledAction))]
# For each ID:
diff --git a/doc/api/ruby/example_environment.rb b/doc/api/ruby/example_environment.rb
index 00c98ee04..ec313c329 100644
--- a/doc/api/ruby/example_environment.rb
+++ b/doc/api/ruby/example_environment.rb
@@ -41,7 +41,7 @@ end
# And use flags, for which we need package IDs:
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec('sys-apps/paludis', env, [])) |
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec('sys-apps/paludis', env, []), []) |
Filter::SupportsAction.new(InstalledAction))]
if (ids.length > 0)
diff --git a/doc/api/ruby/example_mask.rb b/doc/api/ruby/example_mask.rb
index 0f2f2c1b0..2bb306d2c 100644
--- a/doc/api/ruby/example_mask.rb
+++ b/doc/api/ruby/example_mask.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, []), []))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_match_package.rb b/doc/api/ruby/example_match_package.rb
index e0ac15d9f..293eb7bc3 100644
--- a/doc/api/ruby/example_match_package.rb
+++ b/doc/api/ruby/example_match_package.rb
@@ -28,11 +28,11 @@ world = env.set('world')
# For each ID:
ids.each do | id |
# Is it paludis?
- if match_package(env, parse_user_package_dep_spec('sys-apps/paludis', env, []), id)
+ if match_package(env, parse_user_package_dep_spec('sys-apps/paludis', env, []), id, [])
puts id.to_s.ljust(49) + ': paludis'
- elsif match_package_in_set(env, system, id)
+ elsif match_package_in_set(env, system, id, [])
puts id.to_s.ljust(49) + ': system'
- elsif match_package_in_set(env, world, id)
+ elsif match_package_in_set(env, world, id, [])
puts id.to_s.ljust(49) + ': world'
else
puts id.to_s.ljust(49) + ': nothing'
diff --git a/doc/api/ruby/example_package_id.rb b/doc/api/ruby/example_package_id.rb
index 8420911a8..1f8eb8ac8 100644
--- a/doc/api/ruby/example_package_id.rb
+++ b/doc/api/ruby/example_package_id.rb
@@ -20,7 +20,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for installed 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, []), []))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_selection.rb b/doc/api/ruby/example_selection.rb
index a718fc8ee..67ea70749 100644
--- a/doc/api/ruby/example_selection.rb
+++ b/doc/api/ruby/example_selection.rb
@@ -34,19 +34,19 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# object used determines the number and ordering of results. In the
# simplest form, it takes a Generator as a parameter.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []))))
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []), [])))
# Generators can be passed through a Filter. The Selection optimises
# the code internally to avoid doing excess work.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []), []) |
Filter::SupportsAction.new(InstalledAction)))
# Filters can be combined. Usually Filter::NotMasked should be combined
# with Filter::SupportsAction.new(InstallAction), since installed packages
# aren't masked.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []), []) |
Filter::SupportsAction.new(InstallAction) |
Filter::NotMasked.new))
@@ -54,7 +54,7 @@ show_selection(env, Selection::AllVersionsSorted.new(
# is no metadata cache. Consider using other Selection objects if
# you only need the best matching or some arbitrary matching ID.
show_selection(env, Selection::BestVersionOnly.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []), []) |
Filter::SupportsAction.new(InstallAction) |
Filter::NotMasked.new))