Class: DMatch::Or
Instance Attribute Summary collapse
-
#patterns ⇒ Object
readonly
Returns the value of attribute patterns.
Instance Method Summary collapse
-
#initialize(*patterns) ⇒ Or
constructor
A new instance of Or.
Constructor Details
#initialize(*patterns) ⇒ Or
Returns a new instance of Or.
80 81 82 |
# File 'lib/destructure/types.rb', line 80 def initialize(*patterns) @patterns = flatten(patterns) end |
Instance Attribute Details
#patterns ⇒ Object (readonly)
Returns the value of attribute patterns.
79 80 81 |
# File 'lib/destructure/types.rb', line 79 def patterns @patterns end |