/// <summary> /// Initializes a new instance of the <see cref="Chord"/> with the specified notes names (for example, C E G). /// </summary> /// <param name="notesNames">The set of notes names.</param> /// <exception cref="ArgumentNullException"><paramref name="notesNames"/> is <c>null</c>.</exception> /// <exception cref="InvalidEnumArgumentException"><paramref name="notesNames"/> contains an invalid value.</exception> /// <exception cref="ArgumentException"><paramref name="notesNames"/> is empty collection.</exception> public Chord(ICollection <NoteName> notesNames) { ThrowIfArgument.IsNull(nameof(notesNames), notesNames); ThrowIfArgument.ContainsInvalidEnumValue(nameof(notesNames), notesNames); ThrowIfArgument.IsEmptyCollection(nameof(notesNames), notesNames, "Notes names collection is empty."); NotesNames = notesNames; }