Move getDegree and getRelationshipTypes into the kernel.

 o Moves getDegree and getRelationshipTypes into the kernel implementation.
 o Introduces VersionedHashMap, a hashmap lacking certain multi-threading checks.