Still working out the structure of this
First pass implementation, including clean roundtripping