Class: Puppet::Pops::UniqueMergeStrategy
- Inherits:
-
MergeStrategy
- Object
- MergeStrategy
- Puppet::Pops::UniqueMergeStrategy
- Defined in:
- lib/puppet/pops/merge_strategy.rb
Overview
Merges two values that must be either scalar or arrays into a unique set of values.
Scalar values will be converted into a one element arrays and array values will be flattened prior to forming the unique set. The order of the elements is preserved with e1 being the first contributor of elements and e2 the second.
Constant Summary
Constants inherited from MergeStrategy
MergeStrategy::NOT_FOUND, MergeStrategy::TypeAsserter, MergeStrategy::TypeParser
Class Method Summary collapse
Instance Method Summary collapse
-
#checked_merge(e1, e2) ⇒ Array<Object>
The unique set of elements.
- #convert_value(e) ⇒ Object
Methods inherited from MergeStrategy
add_strategy, #configuration, #initialize, merge, #merge, #merge_lookup, #options, strategy, strategy_keys
Constructor Details
This class inherits a constructor from Puppet::Pops::MergeStrategy
Class Method Details
.key ⇒ Object
236 237 238 |
# File 'lib/puppet/pops/merge_strategy.rb', line 236 def self.key :unique end |