diff --git a/data/bitclust/catalog/ja_JP.UTF-8 b/data/bitclust/catalog/ja_JP.UTF-8 index 3136661f..0ed34441 100644 --- a/data/bitclust/catalog/ja_JP.UTF-8 +++ b/data/bitclust/catalog/ja_JP.UTF-8 @@ -14,6 +14,8 @@ Ancestor Methods 継承しているメソッド Ancestor Methods %s %sから継承しているメソッド +Ancestor Singleton Methods %s +%sから継承している特異メソッド Builtin 組み込み Builtin Library diff --git a/data/bitclust/template.offline/class b/data/bitclust/template.offline/class index 1344d6df..23113b5c 100644 --- a/data/bitclust/template.offline/class +++ b/data/bitclust/template.offline/class @@ -146,17 +146,37 @@ <% _myself, *ancestors = @entry.ancestors.reject { |c| %w[Object Kernel BasicObject].include?(c.name) } -displayed_methods = Set.new(ents.instance_methods.flat_map(&:names)) +displayed_instance_methods = Set.new(ents.instance_methods.flat_map(&:names)) +displayed_singleton_methods = Set.new(ents.singleton_methods.flat_map(&:names)) %> <% unless ancestors.empty? %> <%= headline(_("Ancestor Methods")) %>
+ <% ancestors.each do |c| + undefined_methods = @entry.partitioned_entries.undefined + methods = c.partitioned_entries(@alevel).singleton_methods + .flat_map { |m| m.names.map { |n| [n, m] } } + .reject { |name,| displayed_singleton_methods.include?(name) } + .reject { |name,| undefined_methods.any? { |m| m.names.include?(name) } } + .sort + next if methods.empty? %> +
<%= _('Ancestor Singleton Methods %s', c.name) %>
+
+ +
+ <% end %> + <% ancestors.each do |c| undefined_methods = @entry.partitioned_entries.undefined methods = c.partitioned_entries(@alevel).instance_methods .flat_map { |m| m.names.map { |n| [n, m] } } - .reject { |name,| displayed_methods.include?(name) } + .reject { |name,| displayed_instance_methods.include?(name) } .reject { |name,| undefined_methods.any? { |m| m.names.include?(name) } } .sort next if methods.empty? %> @@ -165,14 +185,13 @@ displayed_methods = Set.new(ents.instance_methods.flat_map(&:names)) -<% - end -end %> + <% end %>
+<% end %> <% items.each do |label, entries|