Sha256: 29fa3430f2bbcc0ef16cc4ea0feaf76045bed21982ca45834ade2bf5dbfe315e
Contents?: true
Size: 482 Bytes
Versions: 9
Compression:
Stored size: 482 Bytes
Contents
# Representation of a bar in a composition # Encapsulates meter and key signature changes class HeadMusic::Bar attr_reader :composition attr_accessor :key_signature, :meter def initialize(composition, key_signature: nil, meter: nil) @composition = composition @key_signature = HeadMusic::KeySignature.get(key_signature) if key_signature @meter = HeadMusic::Meter.get(meter) if meter end def to_s ['Bar', key_signature, meter].compact.join(' ') end end
Version data entries
9 entries across 9 versions & 1 rubygems