Class: Attentive::Phrase
- Inherits:
-
SimpleDelegator
- Object
- SimpleDelegator
- Attentive::Phrase
- Defined in:
- lib/attentive/phrase.rb
Instance Method Summary collapse
- #dup ⇒ Object
-
#initialize(tokens) ⇒ Phrase
constructor
A new instance of Phrase.
- #inspect ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(tokens) ⇒ Phrase
Returns a new instance of Phrase.
6 7 8 |
# File 'lib/attentive/phrase.rb', line 6 def initialize(tokens) super tokens end |
Instance Method Details
#dup ⇒ Object
18 19 20 |
# File 'lib/attentive/phrase.rb', line 18 def dup self.class.new map(&:dup) end |
#inspect ⇒ Object
14 15 16 |
# File 'lib/attentive/phrase.rb', line 14 def inspect map(&:inspect).join("\n") end |
#to_s ⇒ Object
10 11 12 |
# File 'lib/attentive/phrase.rb', line 10 def to_s join end |