Class: YFantasy::Transformations::CollectionTransformer
- Inherits:
-
BaseTransform
- Object
- BaseTransform
- YFantasy::Transformations::CollectionTransformer
- Defined in:
- lib/y_fantasy/transformations/collection_transformer.rb
Instance Method Summary collapse
-
#initialize(collection) ⇒ CollectionTransformer
constructor
A new instance of CollectionTransformer.
Methods inherited from BaseTransform
#>>, #[], #call, #ensure_function_set, #t
Constructor Details
#initialize(collection) ⇒ CollectionTransformer
6 7 8 9 10 |
# File 'lib/y_fantasy/transformations/collection_transformer.rb', line 6 def initialize(collection) @collection = collection.to_sym @resource = T[:singularize].call(collection).to_sym @function = compose_function end |