Class: HeadMusic::Notation::ABC::VoiceState::PendingNote
- Inherits:
-
Data
- Object
- Data
- HeadMusic::Notation::ABC::VoiceState::PendingNote
- Defined in:
- lib/head_music/notation/abc/voice_state.rb
Overview
A note or chord whose placement is deferred until we know whether a
broken-rhythm mark follows it. The pitches are computed eagerly so
bar-line accidental resets cannot corrupt them. tied_prefix, when
present, is the already-built rhythmic value of everything tied ahead of
this note; its own value is appended at flush time.
Instance Attribute Summary collapse
-
#beam_break ⇒ Object
readonly
Returns the value of attribute beam_break.
-
#length ⇒ Object
readonly
Returns the value of attribute length.
-
#pitches ⇒ Object
readonly
Returns the value of attribute pitches.
-
#scale ⇒ Object
readonly
Returns the value of attribute scale.
-
#tied_prefix ⇒ Object
readonly
Returns the value of attribute tied_prefix.
Instance Method Summary collapse
-
#initialize(pitches:, length:, scale:, tied_prefix: nil, beam_break: nil) ⇒ PendingNote
constructor
A new instance of PendingNote.
Constructor Details
#initialize(pitches:, length:, scale:, tied_prefix: nil, beam_break: nil) ⇒ PendingNote
Returns a new instance of PendingNote.
19 20 21 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 19 def initialize(pitches:, length:, scale:, tied_prefix: nil, beam_break: nil) super end |
Instance Attribute Details
#beam_break ⇒ Object (readonly)
Returns the value of attribute beam_break
18 19 20 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 18 def beam_break @beam_break end |
#length ⇒ Object (readonly)
Returns the value of attribute length
18 19 20 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 18 def length @length end |
#pitches ⇒ Object (readonly)
Returns the value of attribute pitches
18 19 20 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 18 def pitches @pitches end |
#scale ⇒ Object (readonly)
Returns the value of attribute scale
18 19 20 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 18 def scale @scale end |
#tied_prefix ⇒ Object (readonly)
Returns the value of attribute tied_prefix
18 19 20 |
# File 'lib/head_music/notation/abc/voice_state.rb', line 18 def tied_prefix @tied_prefix end |