Class AbcParser


  • public class AbcParser
    extends Object
    Reads a score in ABC notation and returns it as a Score. The primary use case is to read just a melody with its accompanying lyrics and chords. As such, this class does not support arbitrary ABC notation, but makes the following assumptions:
    • The song has a single voice.
    • Only T, C, K, Q, and M codes are read; all others are ignored. The K: field must come before all notes.
    • The L: code (base unit of time) is assumed to be 1/8 notes.
    • Every note must have an explicit duration (in 1/8 notes).
    • Adjacent notes are separated by whitespace.
    • Rests are not supported.
    • Chords are supported (enclosed in double quotes), and are spelled as explained in Chord.ChordType.