Instantiate and allocate a UObject from class in C++

In Unreal Engine 4 the C++ method for instantiating a new UObject is the NewObject<T>() constructor.

auto myObject = NewObject<MyObjectClass>();