Class: Characterize::FeatureSet
- Inherits:
-
Object
- Object
- Characterize::FeatureSet
- Defined in:
- lib/characterize/feature_set.rb
Instance Method Summary collapse
- #add(object_name, **actions_hash) ⇒ Object
- #dig(*args) ⇒ Object
-
#initialize ⇒ FeatureSet
constructor
A new instance of FeatureSet.
Constructor Details
#initialize ⇒ FeatureSet
Returns a new instance of FeatureSet.
7 8 9 |
# File 'lib/characterize/feature_set.rb', line 7 def initialize @object_rules = {} end |
Instance Method Details
#add(object_name, **actions_hash) ⇒ Object
11 12 13 |
# File 'lib/characterize/feature_set.rb', line 11 def add(object_name, **actions_hash) @object_rules[object_name] = ObjectSet.new(object_name, **actions_hash) end |
#dig(*args) ⇒ Object
15 16 17 |
# File 'lib/characterize/feature_set.rb', line 15 def dig(*args) @object_rules.dig(*args) end |