create_cache_for(klassname, path)public
No documentation available.
# File lib/rdoc/ri/driver.rb, line 475
def create_cache_for(klassname, path)
klass = class_cache[klassname]
return nil unless klass
method_files = klass["sources"]
cache = OpenStructHash.new
method_files.each do |f|
system_file = f.index(@sys_dir) == 0
Dir[File.join(File.dirname(f), "*")].each do |yaml|
next unless yaml =~ /yaml$/
next if yaml =~ /cdesc-[^\/]+yaml$/
method = read_yaml yaml
if system_file then
method["source_path"] = "Ruby #{RDoc::RI::Paths::VERSION}"
else
if(f =~ %gems/[\d.]+/doc/([^/]+)%) then
ext_path = "gem #{$1}"
else
ext_path = f
end
method["source_path"] = ext_path
end
name = method["full_name"]
cache[name] = method
end
end
write_cache cache, path
end