method
get_info_for
v1_8_7_330 -
Show latest stable
-
0 notes -
Class: RiDriver
- 1_8_6_287 (0)
- 1_8_7_72 (0)
- 1_8_7_330 (0)
- 1_9_1_378
- 1_9_2_180
- 1_9_3_125
- 1_9_3_392
- 2_1_10
- 2_2_9
- 2_4_6
- 2_5_5
- 2_6_3
- What's this?
get_info_for(arg)
public
Hide source
# File lib/rdoc/ri/ri_driver.rb, line 84 def get_info_for(arg) desc = NameDescriptor.new(arg) namespaces = @ri_reader.top_level_namespace for class_name in desc.class_names namespaces = @ri_reader.lookup_namespace_in(class_name, namespaces) if namespaces.empty? raise RiError.new("Nothing known about #{arg}") end end # at this point, if we have multiple possible namespaces, but one # is an exact match for our requested class, prune down to just it full_class_name = desc.full_class_name entries = namespaces.find_all {|m| m.full_name == full_class_name} namespaces = entries if entries.size == 1 if desc.method_name.nil? report_class_stuff(namespaces) else methods = @ri_reader.find_methods(desc.method_name, desc.is_class_method, namespaces) if methods.empty? raise RiError.new("Nothing known about #{arg}") else report_method_stuff(desc.method_name, methods) end end end