# File lib/rack/directory.rb, line 80
 80:     def list_directory
 81:       @files = [['../','Parent Directory','','','']]
 82:       glob = F.join(@path, '*')
 83: 
 84:       Dir[glob].sort.each do |node|
 85:         stat = stat(node)
 86:         next  unless stat
 87:         basename = F.basename(node)
 88:         ext = F.extname(node)
 89: 
 90:         url = F.join(@script_name, @path_info, basename)
 91:         size = stat.size
 92:         type = stat.directory? ? 'directory' : Mime.mime_type(ext)
 93:         size = stat.directory? ? '-' : filesize_format(size)
 94:         mtime = stat.mtime.httpdate
 95:         url << '/'  if stat.directory?
 96:         basename << '/'  if stat.directory?
 97: 
 98:         @files << [ url, basename, size, type, mtime ]
 99:       end
100: 
101:       return [ 200, {'Content-Type'=>'text/html; charset=utf-8'}, self ]
102:     end