/
Note.cs
34 lines (33 loc) · 1.04 KB
/
Note.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
namespace Meadow.Foundation.Audio
{
/// <summary>
/// Represents a musical note, with a specific pitch, octave, and duration
/// </summary>
public class Note
{
/// <summary>
/// The pitch of the note
/// </summary>
public Pitch Pitch { get; }
/// <summary>
/// The octave of the note
/// </summary>
public int Octave { get; }
/// <summary>
/// The duration of the note
/// </summary>
public NoteDuration Duration { get; }
/// <summary>
/// Creates a new instance of the Note class, with the specified pitch, octave, and duration
/// </summary>
/// <param name="pitch">The pitch of the note</param>
/// <param name="octave">The octave of the note</param>
/// <param name="duration">The duration of the note</param>
public Note(Pitch pitch, int octave, NoteDuration duration)
{
Pitch = pitch;
Octave = octave;
Duration = duration;
}
}
}