rename getPrimitive to getTypeOf