I have no problems implementing the memory mapped file. The question is. Assuming this returns a valid memory view.
void* pBuf = MapViewOfFile(hMapFile,
Probably the easiest approach is to use the boost memory mapped file classes which give the additional benefit of being portable.
You can use the placement new operator or you can cast the address to a structure or class you want to use. The advantage of placement new is that the constructor of the class will be called. If you use from then on that pointer you don't need to copy the data but read and write directly to it.