Module: ROM::EnumerableDataset
- Extended by:
- DataProxy::ClassMethods
- Includes:
- Enumerable
- Included in:
- ArrayDataset
- Defined in:
- core/lib/rom/enumerable_dataset.rb
Overview
A helper module that adds data-proxy behavior to an enumerable object
This module is intended to be used by gateways
Class that includes this module can define row_proc
class method which
must return a proc-like object which will be used to process each element
in the enumerable
Class Method Summary collapse
-
.forward(*methods) ⇒ undefined
extended
from DataProxy::ClassMethods
Forward provided methods to the underlaying data object.
-
.included(klass) ⇒ Object
private
Included hook which extends a class with DataProxy behavior.
-
.row_proc ⇒ Proc
extended
from DataProxy::ClassMethods
private
Default no-op tuple proc.
Class Method Details
.forward(*methods) ⇒ undefined Originally defined in module DataProxy::ClassMethods
Forward provided methods to the underlaying data object
.included(klass) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Included hook which extends a class with DataProxy behavior
This module can also be included into other modules so we apply the extension only for classes
45 46 47 48 49 50 51 52 53 54 |
# File 'core/lib/rom/enumerable_dataset.rb', line 45 def self.included(klass) return unless klass.is_a?(Class) klass.class_eval do extend Initializer include DataProxy param :data end end |
.row_proc ⇒ Proc Originally defined in module DataProxy::ClassMethods
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Default no-op tuple proc