query(path, details, formats) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File actionpack/lib/action_view/template/resolver.rb, line 131
    def query(path, details, formats)
      query = build_query(path, details)
      templates = []
      sanitizer = Hash.new { |h,k| h[k] = Dir["#{File.dirname(k)}/*"] }

      Dir[query].each do |p|
        next if File.directory?(p) || !sanitizer[p].include?(p)

        handler, format = extract_handler_and_format(p, formats)
        contents = File.open(p, "rb") { |io| io.read }

        templates << Template.new(contents, File.expand_path(p), handler,
          :virtual_path => path.virtual, :format => format, :updated_at => mtime(p))
      end

      templates
    end
Register or log in to add new notes.