Class: ONIX::CodeFromYamlWithMime
- Inherits:
-
CodeFromYaml
- Object
- Subset
- Code
- CodeFromYaml
- ONIX::CodeFromYamlWithMime
- Defined in:
- lib/onix/code.rb
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from Code
Instance Method Summary collapse
-
#mimetype ⇒ Object
main formats.
Methods inherited from CodeFromYaml
Methods inherited from Code
Methods included from CodeHelper
Methods inherited from Subset
parse, #parse, tag_match, #tag_match, #unsupported
Instance Method Details
#mimetype ⇒ Object
main formats
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
# File 'lib/onix/code.rb', line 69 def mimetype case self.human when "Epub" "application/epub" when "Pdf" "application/pdf" when "Mobipocket" "application/x-mobipocket-ebook" when "Gif" "image/gif" when "Jpeg" "image/jpeg" when "Png" "image/png" end end |