Class: MIME::TextMedia
- Inherits:
-
DiscreteMediaType
- Object
- MediaType
- DiscreteMediaType
- MIME::TextMedia
- Defined in:
- lib/mime/discrete_media_type.rb
Overview
TextMedia is intended for content which is principally textual in form.
Instance Attribute Summary
Attributes inherited from MediaType
Attributes included from Headers::MIME
#content_description, #content_disposition, #content_id, #content_transfer_encoding, #content_type, #mime_version
Instance Method Summary collapse
-
#initialize(body, content_type = 'text/plain; charset=us-ascii') ⇒ TextMedia
constructor
Return a new TextMedia object containing
body
with the content type ofcontent_type
.
Methods inherited from MediaType
Constructor Details
#initialize(body, content_type = 'text/plain; charset=us-ascii') ⇒ TextMedia
Return a new TextMedia object containing body
with the content type of content_type
.
To specify the character set of body
, a charset parameter may be appended to content_type
using a semi-colon delimiter.
62 63 64 |
# File 'lib/mime/discrete_media_type.rb', line 62 def initialize body, content_type = 'text/plain; charset=us-ascii' super end |