Module: Card::Set::Abstract::Attachment::Coded
- Extended by:
- Card::Set
- Defined in:
- platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb
Overview
Set: Abstract (Attachment, Coded)
Constant Summary collapse
- MOD_FILE_DIR =
"data/files".freeze
Constants included from Helpers
Helpers::SET_PATTERN_TEST_REGEXP
Constants included from Event::Api
Class Method Summary collapse
Instance Method Summary collapse
-
#event: uncode_attachment_storage ⇒ Object
-
#event: validate_coded_storage_type ⇒ Object
-
#mod ⇒ Object
-
#mod=(value) ⇒ Object
Methods included from Card::Set
Methods included from I18nScope
Methods included from Registrar
#extended, #finalize_load, #process_base_modules, #register_set
Methods included from Helpers
#format_module, #format_modules, #method_missing, #modules, #pattern_code, #respond_to_missing?, #set_name_parts, #shortname, #underscored_name
Methods included from Card::Set::AdvancedApi
#assign_type, #attachment, #define_set_from_error, #ensure_set, #setting_opts, #stage_method
Methods included from Format
#before, #format, layout_method_name, #view, view_method_name, view_setting_method_name, wrapper_method_name
Methods included from Inheritance
#include_set, #include_set_formats
Methods included from Trait
#card_accessor, #card_reader, #card_writer, #require_field
Methods included from Event::Api
Class Method Details
.source_location ⇒ Object
7 |
# File 'platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb', line 7 def self.source_location; "/Users/ethan/dev/decko/gem/mod/carrierwave/set/abstract/attachment/coded.rb"; end |
Instance Method Details
#event: uncode_attachment_storage ⇒ Object
10 11 12 |
# File 'platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb', line 10 event :uncode_attachment_storage, :initialize, on: :update, when: :uncode? do @storage_type = storage_type_from_config unless @explicit_storage_type end |
#event: validate_coded_storage_type ⇒ Object
14 15 16 17 |
# File 'platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb', line 14 event :validate_coded_storage_type, :validate, on: :save, when: :coded? do storage_type_error :mod_argument_needed_to_save unless mod storage_type_error :codename_needed_for_storage if codename.blank? end |
#mod ⇒ Object
23 24 25 |
# File 'platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb', line 23 def mod @mod ||= coded? && mod_from_content end |
#mod=(value) ⇒ Object
19 20 21 |
# File 'platypus/tmp/set/gem-defaults/mod016-carrierwave/abstract/attachment/coded.rb', line 19 def mod= value @mod = value.to_s end |