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