I added getAllOptions to return all the options set as an associative array. This was important to me as I was replacing getopt, and didn't want to have to change all the places where I check options.
I made parse return $argv, so that if people have normal arguments at the end of their command, they can be retrieved, for example:
./foobar -i 123 abcde
parse will return an array with one element set to "abcde"
Added getAllOptions; made parse return leftover things from