Changing version to unsigned ints.
Adding generics to document types.