Added Reads and Writes support for Enumerations. Fixes #2050

There's is an implicit writes test in line 185, because its used to build the json. I though about adding one, but I wasn't sure where to put it, the json test aren't super structured.