Module: Musa::Neumalang::Neumalang::Parser::DeltaVelocityAttribute Private
- Defined in:
- lib/musa-dsl/neumalang/neumalang.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Semantic action for differential velocity attribute.
Parses relative dynamics: "+f" (louder), "-p" (softer).
Instance Method Summary collapse
-
#value ⇒ Hash
private
Builds delta velocity structure.
Instance Method Details
#value ⇒ Hash
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Builds delta velocity structure.
812 813 814 815 816 817 818 819 820 821 822 823 |
# File 'lib/musa-dsl/neumalang/neumalang.rb', line 812 def value d = capture(:delta).value s = capture(:sign).value if /p+/.match?(d) v = -d.length else v = d.length end { delta_velocity: s * v } end |