System.Win32.Mem

Win32-2.3.1.0: A binding to part of the Win32 library

Copyright | (c) Alastair Reid, 1997-2003
License | BSD-style (see the file libraries/base/LICENSE)
Maintainer | Esa Ilari Vuokko <ei@vuokko.info>
Stability | provisional
Portability | portable
Safe Haskell | Safe
Language | Haskell98

System.Win32.Mem

Description

A collection of FFI declarations for interfacing with Win32.

# Documentation

data MEMORY_BASIC_INFORMATION

Constructors

MEMORY_BASIC_INFORMATION |
Fields mbiBaseAddress :: Addr mbiAllocationBase :: Addr mbiAllocationProtect :: DWORD mbiRegionSize :: SIZE_T mbiState :: DWORD mbiProtect :: DWORD mbiType :: DWORD

Instances

Show MEMORY_BASIC_INFORMATION |
Methods showsPrec :: Int -> MEMORY_BASIC_INFORMATION -> ShowS Source show :: MEMORY_BASIC_INFORMATION -> String Source showList :: [MEMORY_BASIC_INFORMATION] -> ShowS Source
Storable MEMORY_BASIC_INFORMATION |
Methods sizeOf :: MEMORY_BASIC_INFORMATION -> Int Source alignment :: MEMORY_BASIC_INFORMATION -> Int Source peekElemOff :: Ptr MEMORY_BASIC_INFORMATION -> Int -> IO MEMORY_BASIC_INFORMATION Source pokeElemOff :: Ptr MEMORY_BASIC_INFORMATION -> Int -> MEMORY_BASIC_INFORMATION -> IO () Source peekByteOff :: Ptr b -> Int -> IO MEMORY_BASIC_INFORMATION Source pokeByteOff :: Ptr b -> Int -> MEMORY_BASIC_INFORMATION -> IO () Source peek :: Ptr MEMORY_BASIC_INFORMATION -> IO MEMORY_BASIC_INFORMATION Source poke :: Ptr MEMORY_BASIC_INFORMATION -> MEMORY_BASIC_INFORMATION -> IO () Source

copyMemory :: Ptr a -> Ptr a -> DWORD -> IO ()

moveMemory :: Ptr a -> Ptr a -> DWORD -> IO ()

fillMemory :: Ptr a -> DWORD -> BYTE -> IO ()

zeroMemory :: Ptr a -> DWORD -> IO ()

memset :: Ptr a -> CInt -> CSize -> IO ()

getProcessHeap :: IO HANDLE

getProcessHeaps :: DWORD -> Addr -> IO DWORD

type HGLOBAL = Addr

type GlobalAllocFlags = UINT

gMEM_INVALID_HANDLE :: GlobalAllocFlags

gMEM_FIXED :: GlobalAllocFlags

gMEM_MOVEABLE :: GlobalAllocFlags

gPTR :: GlobalAllocFlags

gHND :: GlobalAllocFlags

gMEM_DDESHARE :: GlobalAllocFlags

gMEM_SHARE :: GlobalAllocFlags

gMEM_LOWER :: GlobalAllocFlags

gMEM_NOCOMPACT :: GlobalAllocFlags

globalAlloc :: GlobalAllocFlags -> DWORD -> IO HGLOBAL

gMEM_NODISCARD :: GlobalAllocFlags

gMEM_NOT_BANKED :: GlobalAllocFlags

c_GlobalAlloc :: GlobalAllocFlags -> DWORD -> IO HGLOBAL

gMEM_NOTIFY :: GlobalAllocFlags

gMEM_ZEROINIT :: GlobalAllocFlags

globalFlags :: HGLOBAL -> IO GlobalAllocFlags

c_GlobalFlags :: HGLOBAL -> IO GlobalAllocFlags

globalFree :: HGLOBAL -> IO HGLOBAL

c_GlobalFree :: HGLOBAL -> IO HGLOBAL

globalHandle :: Addr -> IO HGLOBAL

c_GlobalHandle :: Addr -> IO HGLOBAL

globalLock :: HGLOBAL -> IO Addr

c_GlobalLock :: HGLOBAL -> IO Addr

globalReAlloc :: HGLOBAL -> DWORD -> GlobalAllocFlags -> IO HGLOBAL

c_GlobalReAlloc :: HGLOBAL -> DWORD -> GlobalAllocFlags -> IO HGLOBAL

globalSize :: HGLOBAL -> IO DWORD

c_GlobalSize :: HGLOBAL -> IO DWORD

globalUnlock :: HGLOBAL -> IO ()

c_GlobalUnlock :: HGLOBAL -> IO Bool

type HeapAllocFlags = DWORD

hEAP_GENERATE_EXCEPTIONS :: HeapAllocFlags

hEAP_NO_SERIALIZE :: HeapAllocFlags

hEAP_ZERO_MEMORY :: HeapAllocFlags

heapAlloc :: HANDLE -> HeapAllocFlags -> DWORD -> IO Addr

c_HeapAlloc :: HANDLE -> HeapAllocFlags -> DWORD -> IO Addr

heapCompact :: HANDLE -> HeapAllocFlags -> IO UINT

c_HeapCompact :: HANDLE -> HeapAllocFlags -> IO UINT

heapCreate :: HeapAllocFlags -> DWORD -> DWORD -> IO HANDLE

c_HeapCreate :: HeapAllocFlags -> DWORD -> DWORD -> IO HANDLE

heapDestroy :: HANDLE -> IO ()

c_HeapDestroy :: HANDLE -> IO Bool

heapFree :: HANDLE -> HeapAllocFlags -> Addr -> IO ()

c_HeapFree :: HANDLE -> HeapAllocFlags -> Addr -> IO Bool

heapLock :: HANDLE -> IO ()

c_HeapLock :: HANDLE -> IO Bool

heapReAlloc :: HANDLE -> HeapAllocFlags -> Addr -> DWORD -> IO Addr

c_HeapReAlloc :: HANDLE -> HeapAllocFlags -> Addr -> DWORD -> IO Addr

heapSize :: HANDLE -> HeapAllocFlags -> Addr -> IO DWORD

c_HeapSize :: HANDLE -> HeapAllocFlags -> Addr -> IO DWORD

heapUnlock :: HANDLE -> IO ()

c_HeapUnlock :: HANDLE -> IO Bool

heapValidate :: HANDLE -> HeapAllocFlags -> Addr -> IO Bool

type VirtualAllocFlags = DWORD

mEM_COMMIT :: VirtualAllocFlags

mEM_RESERVE :: VirtualAllocFlags

type ProtectFlags = DWORD

pAGE_READONLY :: ProtectFlags

pAGE_READWRITE :: ProtectFlags

pAGE_EXECUTE :: ProtectFlags

pAGE_EXECUTE_READ :: ProtectFlags

pAGE_EXECUTE_READWRITE :: ProtectFlags

pAGE_GUARD :: ProtectFlags

type FreeFlags = DWORD

pAGE_NOACCESS :: ProtectFlags

mEM_DECOMMIT :: FreeFlags

pAGE_NOCACHE :: ProtectFlags

mEM_RELEASE :: FreeFlags

virtualAlloc :: Addr -> DWORD -> VirtualAllocFlags -> ProtectFlags -> IO Addr

c_VirtualAlloc :: Addr -> DWORD -> DWORD -> DWORD -> IO Addr

virtualFree :: Addr -> DWORD -> FreeFlags -> IO ()

c_VirtualFree :: Addr -> DWORD -> FreeFlags -> IO Bool

virtualLock :: Addr -> DWORD -> IO ()

c_VirtualLock :: Addr -> DWORD -> IO Bool

virtualProtect :: Addr -> DWORD -> ProtectFlags -> IO ProtectFlags

c_VirtualProtect :: Addr -> DWORD -> DWORD -> Ptr DWORD -> IO Bool

virtualProtectEx :: HANDLE -> Addr -> DWORD -> ProtectFlags -> IO ProtectFlags

c_VirtualProtectEx :: HANDLE -> Addr -> DWORD -> DWORD -> Ptr DWORD -> IO Bool

virtualQueryEx :: HANDLE -> LPVOID -> Ptr MEMORY_BASIC_INFORMATION -> SIZE_T -> IO DWORD

c_VirtualQueryEx :: HANDLE -> LPVOID -> Ptr MEMORY_BASIC_INFORMATION -> SIZE_T -> IO DWORD

virtualUnlock :: Addr -> DWORD -> IO ()

c_VirtualUnlock :: Addr -> DWORD -> IO Bool