@@ -0,0 +1,1564 @@
+package keymix;%0A%0Aimport java.util.HashMap;%0Aimport javafx.scene.input.KeyCode;%0Aimport java.io.File;%0A%0A/**%0A * HashMap to map keycodes to the corresponding sound they should produce.%0A */%0Apublic class SoundMap %7B%0A%0A    /* Maps keycodes to string containing the file name of the sound byte. */%0A    HashMap%3CKeyCode, String%3E sounds = new HashMap%3CKeyCode, String%3E();%0A%0A    /* KeyCodes for all valid keys. */%0A    KeyCode%5B%5D codes = new KeyCode%5B%5D%7BKeyCode.A, KeyCode.B, KeyCode.C, KeyCode.D, KeyCode.E, KeyCode.F, KeyCode.G,%0A            KeyCode.H, KeyCode.I, KeyCode.J, KeyCode.K, KeyCode.L, KeyCode.M, KeyCode.N, KeyCode.O, KeyCode.P,%0A            KeyCode.Q, KeyCode.R, KeyCode.S, KeyCode.T, KeyCode.U, KeyCode.V, KeyCode.W, KeyCode.X, KeyCode.Y, KeyCode.Z,%0A            KeyCode.DIGIT0, KeyCode.DIGIT1, KeyCode.DIGIT2, KeyCode.DIGIT3, KeyCode.DIGIT4, KeyCode.DIGIT5,%0A            KeyCode.DIGIT6, KeyCode.DIGIT7, KeyCode.DIGIT8, KeyCode.DIGIT9,%0A            KeyCode.SPACE, KeyCode.SHIFT, KeyCode.CONTROL, KeyCode.BACK_SPACE%7D;%0A%0A    /* Filepaths for all sound bytes to be available. */%0A    String%5B%5D filepaths = new String%5B%5D%7B%0A        // Insert filepaths as Strings%0A    %7D;%0A%0A    /* Given a filepath as a String, return the name of the file. */%0A    public static String name(String filepath) %7B%0A        File f = new File(filepath);%0A        return f.getName();%0A    %7D%0A%0A    public static HashMap%3CKeyCode, String%3E map(KeyCode%5B%5D c, String%5B%5D fp, HashMap%3CKeyCode, String%3E m) %7B%0A        for(int i = 0; i %3C c.length; i += 1) %7B%0A            m.put(c%5Bi%5D, name(fp%5Bi%5D));%0A        %7D%0A        return m;%0A    %7D%0A%7D%0A

Create sound HashMap for KeyCode to file name