Class: ActiveStorage::Reflection::HasAttachedReflection
- Inherits:
-
ActiveRecord::Reflection::MacroReflection
- Object
- ActiveRecord::Reflection::MacroReflection
- ActiveStorage::Reflection::HasAttachedReflection
show all
- Defined in:
- lib/active_storage/reflection.rb
Overview
Instance Method Summary
collapse
Instance Method Details
#named_variants ⇒ Object
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
|