Class: Pslm::Psalm::VersePart
- Inherits:
-
Object
- Object
- Pslm::Psalm::VersePart
- Defined in:
- lib/pslm/psalm.rb
Instance Attribute Summary collapse
-
#pos ⇒ Object
readonly
position in the verse - one of :flex, :first, :second.
-
#src ⇒ Object
readonly
the source text before parsing.
-
#words ⇒ Object
readonly
Array of Words.
Instance Method Summary collapse
- #==(p2) ⇒ Object
-
#initialize(words, src, pos) ⇒ VersePart
constructor
A new instance of VersePart.
Constructor Details
#initialize(words, src, pos) ⇒ VersePart
Returns a new instance of VersePart.
93 94 95 96 97 |
# File 'lib/pslm/psalm.rb', line 93 def initialize(words, src, pos) @words = words @src = src @pos = pos end |
Instance Attribute Details
#pos ⇒ Object (readonly)
position in the verse - one of :flex, :first, :second
106 107 108 |
# File 'lib/pslm/psalm.rb', line 106 def pos @pos end |
#src ⇒ Object (readonly)
the source text before parsing
103 104 105 |
# File 'lib/pslm/psalm.rb', line 103 def src @src end |
#words ⇒ Object (readonly)
Array of Words
100 101 102 |
# File 'lib/pslm/psalm.rb', line 100 def words @words end |
Instance Method Details
#==(p2) ⇒ Object
108 109 110 |
# File 'lib/pslm/psalm.rb', line 108 def ==(p2) p2.is_a?(VersePart) && self.words == p2.words end |