Module: Assembly
- Defined in:
- lib/assembly-objectfile/version.rb,
lib/assembly-objectfile.rb,
lib/assembly-objectfile/object_file.rb,
lib/assembly-objectfile/object_fileable.rb,
lib/assembly-objectfile/content_metadata.rb,
lib/assembly-objectfile/content_metadata/file.rb,
lib/assembly-objectfile/content_metadata/config.rb,
lib/assembly-objectfile/content_metadata/file_set.rb,
lib/assembly-objectfile/content_metadata/file_set_builder.rb,
lib/assembly-objectfile/content_metadata/nokogiri_builder.rb
Overview
require ‘checksum-tools’
Defined Under Namespace
Modules: ObjectFileable Classes: ContentMetadata, ObjectFile
Constant Summary collapse
- PATH_TO_GEM =
the path to the gem, used to access profiles stored with the gem
File.(File.dirname(__FILE__) + '/..')
- VALID_IMAGE_MIMETYPES =
if input image is not one of these mime types, it will not be regarded as a valid image for the purpose of generating a JP2 derivative
['image/jpeg', 'image/tiff', 'image/tif', 'image/png'].freeze
- VALID_THREE_DIMENSION_EXTENTIONS =
if input file has one of these extensions in a 3D object, it will get the 3d resource type
['.obj'].freeze
- TRUSTED_MIMETYPES =
the list of mimetypes that will be “trusted” by the unix file command; if a mimetype other than one of these is returned
by the file command, then a check will be made to see if exif data exists...if so, the mimetype returned by the exif data will be used if no exif data exists, then the mimetype returned by the unix file command will be used
['text/plain', 'plain/text', 'application/pdf', 'text/html', 'application/xml'].freeze
- FILE_ATTRIBUTES =
default publish/preserve/shelve attributes used in content metadata if no mimetype specific attributes are specified for a given file, define some defaults, and override for specific mimetypes below
{ 'default' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'image/tif' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'image/tiff' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'image/jp2' => { preserve: 'no', shelve: 'yes', publish: 'yes' }, 'image/jpeg' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'audio/wav' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'audio/x-wav' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'audio/mp3' => { preserve: 'no', shelve: 'yes', publish: 'yes' }, 'audio/mpeg' => { preserve: 'no', shelve: 'yes', publish: 'yes' }, 'application/pdf' => { preserve: 'yes', shelve: 'yes', publish: 'yes' }, 'plain/text' => { preserve: 'yes', shelve: 'yes', publish: 'yes' }, 'text/plain' => { preserve: 'yes', shelve: 'yes', publish: 'yes' }, 'image/png' => { preserve: 'yes', shelve: 'yes', publish: 'no' }, 'application/zip' => { preserve: 'yes', shelve: 'no', publish: 'no' }, 'application/json' => { preserve: 'yes', shelve: 'yes', publish: 'yes' } }.freeze
- SPECIAL_DPG_FOLDERS =
these special dpg folders will force any files contained in them into their own resources, regardless of filenaming convention
%w[31 44 50].freeze
- DEPRECATED_STYLES =
these are used when :bundle=>:dpg only
%i[book_with_pdf book_as_image].freeze