org.eclipse.actf.util.win32
Class MemoryUtil

java.lang.Object
  extended by org.eclipse.actf.util.win32.MemoryUtil

public class MemoryUtil
extends Object

Utility class to manipulate memory.


Constructor Summary
MemoryUtil()
           
 
Method Summary
static int GlobalAlloc(int dwBytes)
          GlobalAlloc the memory
static int GlobalFree(int hMem)
          GlobalFree target memory
static void MoveMemory(char[] Destination, int SourcePtr, int Length)
          MoveMemory
static void MoveMemory(int[] Destination, int Source, int Length)
          MoveMemory
static void MoveMemory(int DestinationPtr, char[] Source, int Length)
          MoveMemory
static void MoveMemory(int DestinationPtr, int[] Source, int Length)
          MoveMemory
static void MoveMemory(int DestinationPtr, short[] Source, int Length)
          MoveMemory
static void MoveMemory(short[] Destination, int SourcePtr, int Length)
          MoveMemory
static int SysAllocString(char[] sz)
          Allocate OLE String
static void SysFreeString(int bstr)
          Free OLE String
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MemoryUtil

public MemoryUtil()
Method Detail

GlobalAlloc

public static int GlobalAlloc(int dwBytes)
GlobalAlloc the memory

Parameters:
dwBytes - size
Returns:
pointer

GlobalFree

public static int GlobalFree(int hMem)
GlobalFree target memory

Parameters:
hMem - target memory
Returns:
return code

SysAllocString

public static int SysAllocString(char[] sz)
Allocate OLE String

Parameters:
sz - target String as array of char
Returns:
BSTR pointer

SysFreeString

public static void SysFreeString(int bstr)
Free OLE String

Parameters:
bstr - target BSTR pointer

MoveMemory

public static void MoveMemory(int[] Destination,
                              int Source,
                              int Length)
MoveMemory

Parameters:
Destination -
Source -
Length -

MoveMemory

public static void MoveMemory(short[] Destination,
                              int SourcePtr,
                              int Length)
MoveMemory

Parameters:
Destination -
SourcePtr -
Length -

MoveMemory

public static void MoveMemory(char[] Destination,
                              int SourcePtr,
                              int Length)
MoveMemory

Parameters:
Destination -
SourcePtr -
Length -

MoveMemory

public static void MoveMemory(int DestinationPtr,
                              short[] Source,
                              int Length)
MoveMemory

Parameters:
DestinationPtr -
Source -
Length -

MoveMemory

public static void MoveMemory(int DestinationPtr,
                              int[] Source,
                              int Length)
MoveMemory

Parameters:
DestinationPtr -
Source -
Length -

MoveMemory

public static void MoveMemory(int DestinationPtr,
                              char[] Source,
                              int Length)
MoveMemory

Parameters:
DestinationPtr -
Source -
Length -