BoxedAppSDK_SharedMem_CreateStreamOnSharedMem
Description
The function creates and returns an IStream interface whose data resides in memory shared among all attached processes.
This allows multiple processes that share the same virtual environment to read and write to the same stream concurrently, making it convenient for inter-process data exchange.
The stream follows the COM IStream standard interface, enabling the use of familiar methods such as Read, Write, Seek, and SetSize on a shared memory buffer.
Syntax
HRESULT __stdcall BoxedAppSDK_SharedMem_CreateStreamOnSharedMem(LPSTREAM* ppStream);function BoxedAppSDK_SharedMem_CreateStreamOnSharedMem(var stm: IStream): HResult; stdcall;Parameters
ppStream
A pointer to a variable that receives the IStream interface pointer.
After the function returns successfully, this pointer can be used to access data in shared memory.
Remarks
The returned IStream instance operates entirely in shared memory, which is accessible to all processes attached to the same virtual environment. This makes it useful for shared data exchange and emulating in-memory file operations across processes.
After using the stream, release it with the standard COM Release() method to avoid memory leaks.