#include <Windows.h>
#include <shlobj.h>
#include "hyport.h"
#include "portpriv.h"
#include "portnls.h"
#include "ut_hyprt.h"
#include "hyshmem.h"
Functions | |
IDATA VMCALL | hyshmem_open (struct HyPortLibrary *portLibrary, struct hyshmem_handle **handle, const char *rootname, I_32 size, I_32 perm) |
Creates/open a shared memory region. | |
void *VMCALL | hyshmem_attach (struct HyPortLibrary *portLibrary, struct hyshmem_handle *handle) |
Attaches the shared memory represented by the handle. | |
IDATA VMCALL | hyshmem_detach (struct HyPortLibrary *portLibrary, struct hyshmem_handle **handle) |
Detaches the shared memory region from the caller's process address space Use hyshmem_destroy to actually remove the memory region from the Operating system. | |
IDATA VMCALL | hyshmem_destroy (struct HyPortLibrary *portLibrary, struct hyshmem_handle **handle) |
Destroy and removes the shared memory region from OS. | |
void VMCALL | hyshmem_shutdown (struct HyPortLibrary *portLibrary) |
PortLibrary shutdown. | |
I_32 VMCALL | hyshmem_startup (struct HyPortLibrary *portLibrary) |
PortLibrary startup. | |
void VMCALL | hyshmem_close (struct HyPortLibrary *portLibrary, struct hyshmem_handle **handle) |
Detach, Close and remove the shared memory handle. | |
void VMCALL | hyshmem_findclose (struct HyPortLibrary *portLibrary, UDATA findhandle) |
Close the handle returned from hyshmem_findfirst. | |
UDATA VMCALL | hyshmem_findfirst (struct HyPortLibrary *portLibrary, char *resultbuf) |
Find the name of a shared memory region on the system. | |
I_32 VMCALL | hyshmem_findnext (struct HyPortLibrary *portLibrary, UDATA findHandle, char *resultbuf) |
Find the name of the next shared memory region. | |
UDATA VMCALL | hyshmem_stat (struct HyPortLibrary *portLibrary, const char *name, struct HyPortShmemStatistic *statbuf) |
Return the statistic for a shared memory region. |
|
Attaches the shared memory represented by the handle.
|
|
Detach, Close and remove the shared memory handle.
|
|
Destroy and removes the shared memory region from OS. The timing of which OS removes the memory is OS dependent. However when you make a call you can considered that you can no longer access the region through the handle. Memory allocated for handle structure is freed as well.
|
|
Detaches the shared memory region from the caller's process address space Use hyshmem_destroy to actually remove the memory region from the Operating system.
|
|
Close the handle returned from hyshmem_findfirst.
|
|
Find the name of a shared memory region on the system. Answers a handle to be used in subsequent calls to hyshmem_findnext and hyshmem_findclose.
|
|
Find the name of the next shared memory region.
|
|
Creates/open a shared memory region. The rootname will uniquely identify the shared memory region, and is valid across different JVM instance. The shared memory region should persist across process, until OS reboots or destroy call is being made.
|
|
PortLibrary shutdown. This function is called during shutdown of the portLibrary. Any resources that were created by hyshsem_startup should be destroyed here.
|
|
PortLibrary startup. This function is called during startup of the portLibrary. Any resources that are required for the file operations may be created here. All resources created here should be destroyed in hyshsem_shutdown.
|
|
Return the statistic for a shared memory region.
|