aboutsummaryrefslogtreecommitdiff
path: root/ruby
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-09-04 22:08:23 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-09-04 22:08:23 +0100
commite4445c29bad5f4b6eca307dcb5927ab7ac021df7 (patch)
tree506cf193175dba526c81fbec54469fc7b3c1413c /ruby
parentc90d4dec7920a8d70949d8e2e71e704d2800d2c1 (diff)
downloadpaludis-e4445c29bad5f4b6eca307dcb5927ab7ac021df7.tar.gz
paludis-e4445c29bad5f4b6eca307dcb5927ab7ac021df7.tar.xz
Remove PackageID::contents_key
Diffstat (limited to 'ruby')
-rwxr-xr-xruby/demos/find_unmanaged_files.rb4
-rw-r--r--ruby/package_id.cc10
-rw-r--r--ruby/package_id_TEST.rb6
-rw-r--r--ruby/repository_TEST.rb2
4 files changed, 4 insertions, 18 deletions
diff --git a/ruby/demos/find_unmanaged_files.rb b/ruby/demos/find_unmanaged_files.rb
index 8e0544858..1e752db41 100755
--- a/ruby/demos/find_unmanaged_files.rb
+++ b/ruby/demos/find_unmanaged_files.rb
@@ -11,8 +11,8 @@ Log.instance.program_name = $0
def get_contents(pids, directories, root)
in_contents= []
pids.each do |pid|
- next if pid.contents_key.nil?
- contents = pid.contents_key.parse_value
+ contents = pid.contents
+ next if contents.nil?
contents.each do |entry|
next if entry.kind_of? ContentsOtherEntry
directories.each do |directory|
diff --git a/ruby/package_id.cc b/ruby/package_id.cc
index 10d9fa12f..8b8ddfc2d 100644
--- a/ruby/package_id.cc
+++ b/ruby/package_id.cc
@@ -424,14 +424,6 @@ namespace
* Our long description
*/
/*
- * Document-method: contents_key
- *
- * call-seq:
- * contents_key -> MetadataContentsKey
- *
- * Our Contents
- */
- /*
* Document-method: installed_time_key
*
* call-seq:
@@ -571,8 +563,6 @@ namespace
&PackageID::short_description_key>::fetch)), 0);
rb_define_method(c_package_id, "long_description_key", RUBY_FUNC_CAST((&KeyValue<MetadataValueKey<std::string>,
&PackageID::long_description_key>::fetch)), 0);
- rb_define_method(c_package_id, "contents_key", RUBY_FUNC_CAST((&KeyValue<MetadataValueKey<std::shared_ptr<const Contents> >,
- &PackageID::contents_key>::fetch)), 0);
rb_define_method(c_package_id, "installed_time_key", RUBY_FUNC_CAST((&KeyValue<MetadataTimeKey,&PackageID::installed_time_key>::fetch)), 0);
rb_define_method(c_package_id, "from_repositories_key", RUBY_FUNC_CAST((&KeyValue<MetadataCollectionKey<Set<std::string> >,
&PackageID::from_repositories_key>::fetch)), 0);
diff --git a/ruby/package_id_TEST.rb b/ruby/package_id_TEST.rb
index 4921baab0..cdd0c5907 100644
--- a/ruby/package_id_TEST.rb
+++ b/ruby/package_id_TEST.rb
@@ -107,7 +107,7 @@ module Paludis
{ :name => QualifiedPackageName, :version => VersionSpec, :repository_name => String,
:keywords_key => MetadataKeywordNameSetKey, :choices_key => MetadataChoicesKey,
:short_description_key => MetadataStringKey, :long_description_key => MetadataStringKey,
- :contents_key => MetadataContentsKey, :installed_time_key => MetadataTimeKey,
+ :installed_time_key => MetadataTimeKey,
:from_repositories_key => Array, :masks => Array, :overridden_masks => Array
}.each_pair do | method, type |
@@ -236,10 +236,6 @@ module Paludis
assert_nil pid_testrepo.long_description_key
end
- def test_contents_key
- assert_nil pid_testrepo.contents_key
- end
-
def test_installed_time_key
assert_nil pid_testrepo.installed_time_key
end
diff --git a/ruby/repository_TEST.rb b/ruby/repository_TEST.rb
index 25fa4a24a..13adf5aa0 100644
--- a/ruby/repository_TEST.rb
+++ b/ruby/repository_TEST.rb
@@ -181,7 +181,7 @@ module Paludis
include RepositoryTestCase
def contents
- contents = installed_pid.contents_key.parse_value
+ contents = installed_pid.contents
end
def entries