Class: ActiveStorage::Reflection::HasAttachedReflection

Inherits:
ActiveRecord::Reflection::MacroReflection
  • Object
show all
Defined in:
lib/active_storage/reflection.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#named_variantsObject



10
11
12
# File 'lib/active_storage/reflection.rb', line 10

def named_variants
  @named_variants ||= {}
end

#variant(name, transformations) ⇒ Object



6
7
8
# File 'lib/active_storage/reflection.rb', line 6

def variant(name, transformations)
  named_variants[name] = NamedVariant.new(transformations)
end