Class: Atomy::Pattern::Splat
- Inherits:
-
Atomy::Pattern
- Object
- Atomy::Pattern
- Atomy::Pattern::Splat
- Defined in:
- lib/atomy/pattern/splat.rb
Instance Attribute Summary collapse
-
#pattern ⇒ Object
readonly
Returns the value of attribute pattern.
Attributes inherited from Atomy::Pattern
Instance Method Summary collapse
-
#initialize(pattern) ⇒ Splat
constructor
A new instance of Splat.
- #matches?(val) ⇒ Boolean
Methods inherited from Atomy::Pattern
#===, #inline_matches?, #target
Constructor Details
#initialize(pattern) ⇒ Splat
Returns a new instance of Splat.
7 8 9 |
# File 'lib/atomy/pattern/splat.rb', line 7 def initialize(pattern) @pattern = pattern end |
Instance Attribute Details
#pattern ⇒ Object (readonly)
Returns the value of attribute pattern.
5 6 7 |
# File 'lib/atomy/pattern/splat.rb', line 5 def pattern @pattern end |
Instance Method Details
#matches?(val) ⇒ Boolean
11 12 13 |
# File 'lib/atomy/pattern/splat.rb', line 11 def matches?(val) @pattern.matches?(val) end |