/// <summary>
        /// Creates a shared memory region view.
        /// </summary>
        /// <param name="sharedMemoryMapName"></param>
        /// <param name="sharedMemorySize"></param>
        /// <returns></returns>
        /// <typeparam name="T">Memory region type.</typeparam>
        public static SharedMemoryRegionView <T> Create <T>(string sharedMemoryMapName, ulong sharedMemorySize)
            where T : ICodegenProxy, new()
        {
            var memoryRegionView = new SharedMemoryRegionView <T>(SharedMemoryMapView.Create(sharedMemoryMapName, sharedMemorySize));

            MlosProxyInternal.MemoryRegionInitializer <T> memoryRegionInitializer = default;
            memoryRegionInitializer.Initalize(memoryRegionView);
            return(memoryRegionView);
        }
        /// <summary>
        /// Creates or opens a shared memory region view.
        /// </summary>
        /// <param name="sharedMemoryMapName"></param>
        /// <param name="sharedMemorySize"></param>
        /// <returns></returns>
        /// <typeparam name="T">Memory region type.</typeparam>
        public static SharedMemoryRegionView <T> CreateOrOpen <T>(string sharedMemoryMapName, ulong sharedMemorySize)
            where T : ICodegenProxy, new()
        {
            try
            {
                return(new SharedMemoryRegionView <T>(SharedMemoryMapView.Open(sharedMemoryMapName, sharedMemorySize)));
            }
            catch (FileNotFoundException)
            {
                var memoryRegionView = new SharedMemoryRegionView <T>(SharedMemoryMapView.Create(sharedMemoryMapName, sharedMemorySize));

                MlosProxyInternal.MemoryRegionInitializer <T> memoryRegionInitializer = default;
                memoryRegionInitializer.Initalize(memoryRegionView);
                return(memoryRegionView);
            }
        }