MFC
Class CSharedFile
CObject
|
+--CFile
|
+--CMemFile
|
+--CSharedFile
in AFXADV.H
- class CSharedFile
- extends CMemFile
Shared file support
|
Constructor Summary |
CSharedFile( UINT nAllocFlags = GMEM_DDESHARE| GMEM_MOVEABLE, UINT nGrowBytes = 4096 )
|
virtual ~CSharedFile()
|
|
Method Summary |
protected virtual BYTE* |
Alloc( DWORD nBytes )
|
HGLOBAL |
Detach()
|
protected virtual void |
Free( BYTE* lpMem )
|
protected virtual BYTE* |
Realloc( BYTE* lpMem, DWORD nBytes )
|
void |
SetHandle( HGLOBAL hGlobalMemory, BOOL bAllowGrow = TRUE )
|
| Methods inherited from class CMemFile |
GetRuntimeClass, Attach, Detach, Alloc, Realloc, Memcpy, Free, GrowFile, GetPosition, GetStatus, Seek, SetLength, Read, Write, Abort, Flush, Close, GetBufferPtr, Duplicate, LockRange, UnlockRange |
| Methods inherited from class CFile |
GetRuntimeClass, HFILE, GetPosition, GetStatus, GetFileName, GetFileTitle, GetFilePath, SetFilePath, Open, Rename, Remove, GetStatus, SetStatus, SeekToEnd, SeekToBegin, ReadHuge, WriteHuge, Duplicate, Seek, SetLength, GetLength, Read, Write, LockRange, UnlockRange, Abort, Flush, Close, GetBufferPtr |
m_bAllowGrow
protected BOOL m_bAllowGrow;
m_hGlobalMemory
protected HGLOBAL m_hGlobalMemory;
m_nAllocFlags
protected UINT m_nAllocFlags;
CSharedFile
public CSharedFile( UINT nAllocFlags = GMEM_DDESHARE| GMEM_MOVEABLE, UINT nGrowBytes = 4096 );
~CSharedFile
public virtual ~CSharedFile();
Alloc
protected virtual BYTE* Alloc( DWORD nBytes );
Detach
public HGLOBAL Detach();
Free
protected virtual void Free( BYTE* lpMem );
Realloc
protected virtual BYTE* Realloc( BYTE* lpMem, DWORD nBytes );
SetHandle
public void SetHandle( HGLOBAL hGlobalMemory, BOOL bAllowGrow = TRUE );