Class | Mime::Type
In: | lib/action_controller/mime_type.rb
Parent: | Object

Encapsulates the notion of a mime type. Can be used at render time, for example, with:

      class PostsController < ActionController::Base
        def show
          @post = Post.find(params[:id])

          respond_to do |format|
            format.html
            format.ics { render :text => post.to_ics, :mime_type => Mime::Type["text/calendar"]  }
            format.xml { render :xml => @people.to_xml }
          end
        end
      end

### Methods

== === lookup new parse register to_s to_str to_sym

### Public Class methods

lookup(string)
new(string, symbol = nil, synonyms = [])
parse(accept_header)
register(string, symbol, synonyms = [])

### Public Instance methods

==(mime_type)
===(list)
to_s()
to_str()
to_sym()

[Validate]