import { Instrument } from "../Instrument" ; import { VoiceEntry } from "./VoiceEntry" ; /**
 * A [[Voice]] contains all the [[VoiceEntry]]s in a voice in a [[StaffLine]].
 */ export class Voice { private voiceEntries : VoiceEntry [ ] = [ ] ; private parent : Instrument ; private visible : boolean ; private audible : boolean ; private following : boolean ; /**
     * The Id given in the MusicXMl file to distinguish the different voices. It is unique per instrument.
     */ private voiceId : number ; private volume : number = 1 ; constructor ( parent , voiceId ) { this . parent = parent ; this . visible = true ; this . audible = true ; this . following = true ; this . voiceId = voiceId ; } public get VoiceEntries ( ) : VoiceEntry [ ] { return this . voiceEntries ; } public get Parent ( ) : Instrument { return this . parent ; } public get Visible ( ) : boolean { return this . visible ; } public set Visible ( value ) { this . visible = value ; } public get Audible ( ) : boolean { return this . audible ; } public set Audible ( value ) { this . audible = value ; } public get Following ( ) : boolean { return this . following ; } public set Following ( value ) { this . following = value ; } public get VoiceId ( ) : number { return this . voiceId ; } public get Volume ( ) : number { return this . volume ; } public set Volume ( value ) { this . volume = value ; } }