Class: Musicality::Change

Inherits:
Object
  • Object
show all
Includes:
Packable
Defined in:
lib/musicality/notation/model/change.rb,
lib/musicality/notation/conversion/change_conversion.rb

Direct Known Subclasses

Gradual, Immediate

Defined Under Namespace

Classes: Gradual, Immediate

Constant Summary

Constants included from Packable

Packable::PACKED_CLASS_KEY

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Packable

#class_str, included, #init_params, #pack, pack_val, recover_class, unpack_val

Constructor Details

#initialize(end_value) ⇒ Change

Returns a new instance of Change.



8
9
10
# File 'lib/musicality/notation/model/change.rb', line 8

def initialize end_value
  @end_value = end_value
end

Instance Attribute Details

#end_valueObject (readonly)

Returns the value of attribute end_value.



6
7
8
# File 'lib/musicality/notation/model/change.rb', line 6

def end_value
  @end_value
end

Instance Method Details

#==(other) ⇒ Object



12
13
14
15
# File 'lib/musicality/notation/model/change.rb', line 12

def ==(other)
  self.class == other.class &&
  self.end_value == other.end_value
end