Unit Ultibo

From Ultibo.org
Jump to: navigation, search

Return to Unit Reference


Description


Ultibo Interface unit

Constants



64bit constants MAXLONGLONG_*
MAXLONGLONG = $7fffffffffffffff;  


Thread constants CREATE_*
CREATE_SUSPENDED = $00000004;  


Message constants PM_*
PM_NOREMOVE = $0000;  
PM_REMOVE = $0001;  
PM_NOYIELD = $0002;  


Timezone Id TIME_ZONE_ID_*
TIME_ZONE_ID_UNKNOWN = Timezone.TIME_ZONE_ID_UNKNOWN;  
TIME_ZONE_ID_STANDARD = Timezone.TIME_ZONE_ID_STANDARD;  
TIME_ZONE_ID_DAYLIGHT = Timezone.TIME_ZONE_ID_DAYLIGHT;  
TIME_ZONE_ID_INVALID = Timezone.TIME_ZONE_ID_INVALID;  


Shutdown/Restart EWX_*
EWX_LOGOFF = $00000000;  
EWX_SHUTDOWN = $00000001;  
EWX_REBOOT = $00000002;  
EWX_FORCE = $00000004;  
EWX_POWEROFF = $00000008;  
EWX_FORCEIFHUNG = $00000010;  


Drive type DRIVE_*
DRIVE_UNKNOWN = 0;  
DRIVE_NO_ROOT_DIR = 1;  
DRIVE_REMOVABLE = 2;  
DRIVE_FIXED = 3;  
DRIVE_REMOTE = 4;  
DRIVE_CDROM = 5;  
DRIVE_RAMDISK = 6;  


Symbolic link SYMBOLIC_LINK_*
SYMBOLIC_LINK_FLAG_FILE = $00000000; The link target is a file
SYMBOLIC_LINK_FLAG_DIRECTORY = $00000001; The link target is a directory


Local memory LMEM_*
LMEM_FIXED = $0000;  
LMEM_MOVEABLE = $0002;  
LMEM_NOCOMPACT = $0010;  
LMEM_NODISCARD = $0020;  
LMEM_ZEROINIT = $0040;  
LMEM_MODIFY = $0080;  
LMEM_DISCARDABLE = $0F00;  
LMEM_VALID_FLAGS = $0F72;  
LMEM_INVALID_HANDLE = $8000;  
 
LHND = (LMEM_MOVEABLE or LMEM_ZEROINIT);  
LPTR = (LMEM_FIXED or LMEM_ZEROINIT);  
 
NONZEROLHND = (LMEM_MOVEABLE);  
NONZEROLPTR = (LMEM_FIXED);  


Global memory GMEM_*
GMEM_FIXED = $0000;  
GMEM_MOVEABLE = $0002;  
GMEM_NOCOMPACT = $0010;  
GMEM_NODISCARD = $0020;  
GMEM_ZEROINIT = $0040;  
GMEM_MODIFY = $0080;  
GMEM_DISCARDABLE = $0100;  
GMEM_NOT_BANKED = $1000;  
GMEM_SHARE = $2000;  
GMEM_DDESHARE = $2000;  
GMEM_NOTIFY = $4000;  
GMEM_LOWER = GMEM_NOT_BANKED;  
GMEM_VALID_FLAGS = $7F72;  
GMEM_INVALID_HANDLE = $8000;  
 
GHND = (GMEM_MOVEABLE or GMEM_ZEROINIT);  
GPTR = (GMEM_FIXED or GMEM_ZEROINIT);  


Virtual page PAGE_*
PAGE_NOACCESS = $01;  
PAGE_READONLY = $02;  
PAGE_READWRITE = $04;  
PAGE_WRITECOPY = $08;  
PAGE_EXECUTE = $10;  
PAGE_EXECUTE_READ = $20;  
PAGE_EXECUTE_READWRITE = $40;  
PAGE_EXECUTE_WRITECOPY = $80;  
PAGE_GUARD = $100;  
PAGE_NOCACHE = $200;  
PAGE_WRITECOMBINE = $400;  


Virtual memory MEM_*, SEC_*, WRITE_*
MEM_COMMIT = $1000;  
MEM_RESERVE = $2000;  
MEM_DECOMMIT = $4000;  
MEM_RELEASE = $8000;  
MEM_FREE = $10000;  
MEM_PRIVATE = $20000;  
MEM_MAPPED = $40000;  
MEM_RESET = $80000;  
MEM_TOP_DOWN = $100000;  
MEM_WRITE_WATCH = $200000;  
MEM_PHYSICAL = $400000;  
MEM_4MB_PAGES = DWORD($80000000);  
SEC_FILE = $800000;  
SEC_IMAGE = $1000000;  
SEC_RESERVE = $4000000;  
SEC_COMMIT = DWORD($8000000);  
SEC_NOCACHE = $10000000;  
MEM_IMAGE = SEC_IMAGE;  
WRITE_WATCH_FLAG_RESET = $01;  
MEM_LARGE_PAGES = $20000000;  


Processor architecture PROCESSOR_ARCHITECTURE_*
PROCESSOR_ARCHITECTURE_INTEL = 0;  
PROCESSOR_ARCHITECTURE_MIPS = 1;  
PROCESSOR_ARCHITECTURE_ALPHA = 2;  
PROCESSOR_ARCHITECTURE_PPC = 3;  
PROCESSOR_ARCHITECTURE_SHX = 4;  
PROCESSOR_ARCHITECTURE_ARM = 5;  
PROCESSOR_ARCHITECTURE_IA64 = 6;  
PROCESSOR_ARCHITECTURE_ALPHA64 = 7;  
PROCESSOR_ARCHITECTURE_MSIL = 8;  
PROCESSOR_ARCHITECTURE_AMD64 = 9;  
 
PROCESSOR_ARCHITECTURE_UNKNOWN = $FFFF;  


Processor type PROCESSOR_*
PROCESSOR_INTEL_386 = 386;  
PROCESSOR_INTEL_486 = 486;  
PROCESSOR_INTEL_PENTIUM = 586;  
PROCESSOR_INTEL_IA64 = 2200;  
PROCESSOR_ARM_6 = 60999;  
PROCESSOR_ARM_7 = 70999;  
PROCESSOR_ARM_8 = 80999;  


Version information VER_*
VER_PLATFORM_ULTIBO = 10011;  


File attribute FILE_ATTRIBUTE_*
FILE_ATTRIBUTE_READONLY = $00000001;  
FILE_ATTRIBUTE_HIDDEN = $00000002;  
FILE_ATTRIBUTE_SYSTEM = $00000004;  
FILE_ATTRIBUTE_DIRECTORY = $00000010;  
FILE_ATTRIBUTE_ARCHIVE = $00000020;  
FILE_ATTRIBUTE_DEVICE = $00000040;  
FILE_ATTRIBUTE_NORMAL = $00000080;  
FILE_ATTRIBUTE_TEMPORARY = $00000100;  
FILE_ATTRIBUTE_SPARSE_FILE = $00000200;  
FILE_ATTRIBUTE_REPARSE_POINT = $00000400;  
FILE_ATTRIBUTE_COMPRESSED = $00000800;  
FILE_ATTRIBUTE_OFFLINE = $00001000;  
FILE_ATTRIBUTE_NOT_CONTENT_INDEXED = $00002000;  
FILE_ATTRIBUTE_ENCRYPTED = $00004000;  


Volume information FILE_*
FILE_CASE_SENSITIVE_SEARCH = $00000001;  
FILE_CASE_PRESERVED_NAMES = $00000002;  
FILE_UNICODE_ON_DISK = $00000004;  
FILE_PERSISTENT_ACLS = $00000008;  
FILE_FILE_COMPRESSION = $00000010;  
FILE_VOLUME_QUOTAS = $00000020;  
FILE_SUPPORTS_SPARSE_FILES = $00000040;  
FILE_SUPPORTS_REPARSE_POINTS = $00000080;  
FILE_SUPPORTS_REMOTE_STORAGE = $00000100;  
FILE_VOLUME_IS_COMPRESSED = $00008000;  
FILE_SUPPORTS_OBJECT_IDS = $00010000;  
FILE_SUPPORTS_ENCRYPTION = $00020000;  
FILE_NAMED_STREAMS = $00040000;  
FILE_READ_ONLY_VOLUME = $00080000;  


Dos device DDD_*
DDD_RAW_TARGET_PATH = $00000001;  
DDD_REMOVE_DEFINITION = $00000002;  
DDD_EXACT_MATCH_ON_REMOVE = $00000004;  
DDD_NO_BROADCAST_SYSTEM = $00000008;  
DDD_LUID_BROADCAST_DRIVE = $00000010;  


Time null TIME_NULL_*
TIME_NULL_TIME:TFileTime = (dwLowDateTime:$00000000;dwHighDateTime:$00000000);  


Drive constants *_DRIVE
DEFAULT_DRIVE = 0; 0 is Current Drive
INVALID_DRIVE = 0; Where Current is not appropriate
MIN_DRIVE = 1; 1 = A:, 2 = B:, 3 = C:, 26 = Z: etc
MAX_DRIVE = 26;  
NON_DRIVE = 27; 27 for Non Drive (UNC) Path
 
DRIVE_NAMES:array[DEFAULT_DRIVE..NON_DRIVE] of String = (
,'A:\','B:\','C:\','D:\','E:\','F:\','G:\','H:\','I:\','J:\','K:\','L:\','M:\',  
'N:\','O:\','P:\','Q:\','R:\','S:\','T:\','U:\','V:\','W:\','X:\','Y:\','Z:\','\\');  
 
DRIVE_ROOTS:array[DEFAULT_DRIVE..NON_DRIVE] of String = (
,'A:','B:','C:','D:','E:','F:','G:','H:','I:','J:','K:','L:','M:',  
'N:','O:','P:','Q:','R:','S:','T:','U:','V:','W:','X:','Y:','Z:','\\');  
 
DRIVE_MASKS:array[MIN_DRIVE..MAX_DRIVE] of LongWord = (
$00000001,$00000002,$00000004,$00000008,  
$00000010,$00000020,$00000040,$00000080,  
$00000100,$00000200,$00000400,$00000800,  
$00001000,$00002000,$00004000,$00008000,  
$00010000,$00020000,$00040000,$00080000,  
$00100000,$00200000,$00400000,$00800000,  
$01000000,$02000000);  
 
DRIVE_A = 1;  
DRIVE_B = 2;  
DRIVE_C = 3;  


Path and file *_PATH, _FILE*
MAX_FAT_PATH = 64;  
MAX_FAT_FILE = 12;  
MAX_VFAT_PATH = 260;  
MAX_VFAT_FILE = 255;  
 
FAT_PATH_CHAR = '\'; Path separator
FAT_NAME_CHAR = ':'; Stream separator
FAT_FILE_CHAR = '.'; Extension separator
FAT_DRIVE_CHAR = ':'; Drive separator
 
UNIX_PATH_CHAR = '/'; Path separator
UNIX_NAME_CHAR = ':'; Stream separator
UNIX_FILE_CHAR = '.'; Extension separator


Invalid filename chars INVALID_FILENAME_CHARS*
SHORT_FILENAME_SUBST_CHARS:set of Char = ['+','=',',','[',']',';'];  


Wildcard filename chars WILDCARD_FILENAME_CHAR*
MACRO_FILENAME_CHAR:Char = '%';  
WILDCARD_FILENAME_CHAR:Char = '*';  


Type definitions



Signed types

INT = GlobalTypes.INT;
BOOL = GlobalTypes.BOOL; Note: Declared in Windows as LongBool but declared here as ByteBool for GCC compatibility
LONG = GlobalTypes.LONG;

Unsigned types

UINT = GlobalTypes.UINT;
UCHAR = GlobalTypes.UCHAR;
USHORT = GlobalTypes.USHORT;
ULONG = GlobalTypes.ULONG;

Pointer types

PVOID = GlobalTypes.PVOID;
LPVOID = GlobalTypes.LPVOID;
LPCVOID = GlobalTypes.LPCVOID;
LPBOOL = GlobalTypes.LPBOOL; See note above for BOOL declaration
PLONG = GlobalTypes.PLONG;
LPLONG = GlobalTypes.LPLONG;
LPDWORD = GlobalTypes.LPDWORD;
INT_PTR = GlobalTypes.INT_PTR;
UINT_PTR = GlobalTypes.UINT_PTR;
LONG_PTR = GlobalTypes.LONG_PTR;
ULONG_PTR = GlobalTypes.ULONG_PTR;
DWORD_PTR = GlobalTypes.DWORD_PTR;
PDWORD_PTR = GlobalTypes.PDWORD_PTR;

64bit types

LONGLONG = GlobalTypes.LONGLONG;
ULONGLONG = GlobalTypes.ULONGLONG;
DWORDLONG = GlobalTypes.DWORDLONG;

Quad types

QUAD = _QUAD;

TQuad = _QUAD;

UQUAD = QUAD;

PQuad = ^TQuad;

_QUAD = record

Note: QUAD is for those times we want an 8 byte aligned 8 byte long structure which is NOT really a floating point number. Use DOUBLE if you want an FP number.
DoNotUseThisField:Double;  

Locale Id

LCID = Locale.LCID;
PLCID = Locale.PLCID;

Language Id

LANGID = Locale.LANGID;
PLANGID = Locale.PLANGID;

Language group Id

LGRPID = Locale.LGRPID;

Locale type

LCTYPE = Locale.LCTYPE;

Calendar type

CALTYPE = Locale.CALTYPE;

Calendar Id

CALID = Locale.CALID;

Large integer

LARGE_INTEGER = _LARGE_INTEGER;

TLargeInteger = LARGE_INTEGER;

PLARGE_INTEGER = ^LARGE_INTEGER;

PLargeInteger = LPLARGE_INTEGER;

LPLARGE_INTEGER = ^LARGE_INTEGER;

_LARGE_INTEGER = record

case Integer of  
0: (  
LowPart: DWORD;  
HighPart: LONG);  
1: (  
QuadPart: ULONGLONG);  

OS version information

OSVERSIONINFO = _OSVERSIONINFO;

TOsVersionInfo = OSVERSIONINFO;

POsVersionInfo = LPOSVERSIONINFO;

LPOSVERSIONINFO = ^OSVERSIONINFO;

_OSVERSIONINFO = record

dwOSVersionInfoSize:DWORD;  
dwMajorVersion:DWORD;  
dwMinorVersion:DWORD;  
dwBuildNumber:DWORD;  
dwPlatformId:DWORD;  
szCSDVersion:array [0..127] of CHAR;  

System information

SYSTEM_INFO = _SYSTEM_INFO;

TSystemInfo = SYSTEM_INFO;

PSystemInfo = LPSYSTEM_INFO;

LPSYSTEM_INFO = ^SYSTEM_INFO;

_SYSTEM_INFO = record

wProcessorArchitecture:WORD;  
wReserved:WORD;  
dwPageSize:DWORD;  
lpMinimumApplicationAddress:LPVOID;  
lpMaximumApplicationAddress:LPVOID;  
dwActiveProcessorMask:DWORD_PTR;  
dwNumberOfProcessors:DWORD;  
dwProcessorType:DWORD;  
dwAllocationGranularity:DWORD;  
wProcessorLevel:WORD;  
wProcessorRevision:WORD;  

Computer name

COMPUTER_NAME_FORMAT = _COMPUTER_NAME_FORMAT;

TComputerNameFormat = COMPUTER_NAME_FORMAT;

_COMPUTER_NAME_FORMAT = (

ComputerNameNetBIOS,  
ComputerNameDnsHostname,  
ComputerNameDnsDomain,  
ComputerNameDnsFullyQualified,  
ComputerNamePhysicalNetBIOS,  
ComputerNamePhysicalDnsHostname,  
ComputerNamePhysicalDnsDomain,  
ComputerNamePhysicalDnsFullyQualified,  
ComputerNameMax);  

System time

LPSYSTEMTIME = SysUtils.LPSYSTEMTIME;

SYSTEMTIME = SysUtils.SYSTEMTIME;

TSystemTime = SysUtils.TSystemTime;

PSystemTime = SysUtils.PSystemTime;

_SYSTEMTIME = SysUtils.SYSTEMTIME;

wYear:Word;  
wMonth:Word;  
wDayOfWeek:Word;  
wDay:Word;  
wHour:Word;  
wMinute:Word;  
wSecond:Word;  
wMilliseconds:Word;  

Find data

WIN32_FIND_DATAW = _WIN32_FIND_DATAW;

LPWIN32_FIND_DATAW = ^WIN32_FIND_DATAW;

TWin32FindDataW = WIN32_FIND_DATAW;

PWin32FindDataW = PWIN32_FIND_DATAW;

PWIN32_FIND_DATAW = ^WIN32_FIND_DATAW;

_WIN32_FIND_DATAW = record

dwFileAttributes: DWORD;  
ftCreationTime: FILETIME;  
ftLastAccessTime: FILETIME;  
ftLastWriteTime: FILETIME;  
nFileSizeHigh: DWORD;  
nFileSizeLow: DWORD;  
dwReserved0: DWORD;  
dwReserved1: DWORD;  
cFileName: array [0..MAX_PATH - 1] of WCHAR;  
cAlternateFileName: array [0..13] of WCHAR;  

Stream info levels

_STREAM_INFO_LEVELS = (FindStreamInfoStandard, FindStreamInfoMaxInfoLevel);
STREAM_INFO_LEVELS = _STREAM_INFO_LEVELS;
TStreamInfoLevels = STREAM_INFO_LEVELS;

Find stream data

WIN32_FIND_STREAM_DATA = _WIN32_FIND_STREAM_DATA;

PWIN32_FIND_STREAM_DATA = ^WIN32_FIND_STREAM_DATA;

TWin32FindStreamData = WIN32_FIND_STREAM_DATA;

PWin32FindStreamData = PWIN32_FIND_STREAM_DATA;

_WIN32_FIND_STREAM_DATA = record

StreamSize: LARGE_INTEGER;  
cStreamName: array [0..MAX_PATH + 35] of WCHAR;  

Time zone information

PTIME_ZONE_INFORMATION = Timezone.PTIME_ZONE_INFORMATION;
_TIME_ZONE_INFORMATION = Timezone._TIME_ZONE_INFORMATION;
TIME_ZONE_INFORMATION = Timezone.TIME_ZONE_INFORMATION;
LPTIME_ZONE_INFORMATION = Timezone.LPTIME_ZONE_INFORMATION;
TTimeZoneInformation = Timezone.TTimeZoneInformation;
PTimeZoneInformation = Timezone.PTimeZoneInformation;

Memory status

MEMORYSTATUS = _MEMORYSTATUS;

TMemoryStatus = MEMORYSTATUS;

PMemoryStatus = LPMEMORYSTATUS;

LPMEMORYSTATUS = ^MEMORYSTATUS;

_MEMORYSTATUS = record

dwLength:DWORD;  
dwMemoryLoad:DWORD;  
dwTotalPhys:SIZE_T;  
dwAvailPhys:SIZE_T;  
dwTotalPageFile:SIZE_T;  
dwAvailPageFile:SIZE_T;  
dwTotalVirtual:SIZE_T;  
dwAvailVirtual:SIZE_T;  

Memory status extended

MEMORYSTATUSEX = _MEMORYSTATUSEX;

TMemoryStatusEx = MEMORYSTATUSEX;

PMemoryStatusEx = LPMEMORYSTATUSEX;

LPMEMORYSTATUSEX = ^MEMORYSTATUSEX;

_MEMORYSTATUSEX = record

dwLength:DWORD;  
ullTotalPhys:DWORDLONG;  
ullAvailPhys:DWORDLONG;  
ullTotalPageFile:DWORDLONG;  
ullAvailPageFile:DWORDLONG;  
ullTotalVirtual:DWORDLONG;  
ullAvailVirtual:DWORDLONG;  
ullAvailExtendedVirtual:DWORDLONG;  

Security attributes

SECURITY_ATTRIBUTES = _SECURITY_ATTRIBUTES;

LPSECURITY_ATTRIBUTES = ^SECURITY_ATTRIBUTES;

TSecurityAttributes = SECURITY_ATTRIBUTES;

PSecurityAttributes = PSECURITY_ATTRIBUTES;

PSECURITY_ATTRIBUTES = ^SECURITY_ATTRIBUTES;

_SECURITY_ATTRIBUTES = record

nLength:DWORD;  
lpSecurityDescriptor:LPVOID;  
bInheritHandle:BOOL;  

Thread start routine

PTHREAD_START_ROUTINE = function (lpThreadParameter:LPVOID):DWORD;
LPTHREAD_START_ROUTINE = PTHREAD_START_ROUTINE;
TThreadStartRoutine = PTHREAD_START_ROUTINE;

Rectangle types

RECT = tagRECT;

NPRECT = ^tagRect;

LPCRECT = ^tagRect;

TRect = RECT;

PRect = LPRECT;

LPRECT = ^RECT;

tagRECT = record

left:LONG;  
top:LONG;  
right:LONG;  
bottom:LONG;  

Point types

NPPOINT = ^tagPoint;

POINT = tagPOINT;

TPoint = POINT;

PPoint = LPPOINT;

LPPOINT = ^POINT;

tagPOINT = record

x:LONG;  
y:LONG;  

Message types

MSG = tagMSG;

NPMSG = ^MSG;

TMsg = MSG;

PMsg = LPMSG;

LPMSG = ^MSG;

tagMSG = record

hThread:HANDLE;  
message:UINT;  
wParam:WPARAM;  
lParam:LPARAM;  
time:DWORD;  
pt:POINT;  

List entry

LIST_ENTRY = _LIST_ENTRY;

TListEntry = LIST_ENTRY;

PListEntry = PLIST_ENTRY;

PRLIST_ENTRY = ^LIST_ENTRY;

PLIST_ENTRY = ^LIST_ENTRY;

_LIST_ENTRY = record

Flink:PLIST_ENTRY;  
Blink:PLIST_ENTRY;  

RTL critical section debug

RTL_CRITICAL_SECTION_DEBUG = _RTL_CRITICAL_SECTION_DEBUG;

TRtlCriticalSectionDebug = RTL_CRITICAL_SECTION_DEBUG;

PRtlCriticalSectionDebug = PRTL_CRITICAL_SECTION_DEBUG;

PRTL_CRITICAL_SECTION_DEBUG = ^RTL_CRITICAL_SECTION_DEBUG;

_RTL_CRITICAL_SECTION_DEBUG = record

_Type:WORD;  
CreatorBackTraceIndex:WORD;  
CriticalSection:PRTL_CRITICAL_SECTION_DEBUG;  
ProcessLocksList:LIST_ENTRY;  
EntryCount:DWORD;  
ContentionCount:DWORD;  
Spare:array [0..1] of DWORD;  

RTL critical section

RTL_CRITICAL_SECTION = _RTL_CRITICAL_SECTION;

TRtlCriticalSection = RTL_CRITICAL_SECTION;

PRtlCriticalSection = PRTL_CRITICAL_SECTION;

PRTL_CRITICAL_SECTION = ^RTL_CRITICAL_SECTION;

_RTL_CRITICAL_SECTION = record

DebugInfo:PRTL_CRITICAL_SECTION_DEBUG;  
Note: The following three fields control entering and exiting the critical section for the resource
LockCount:LONG;  
RecursionCount:LONG;  
OwningThread:HANDLE; from the thread's ClientId->UniqueThread
LockSemaphore:HANDLE;  
SpinCount:ULONG_PTR; force size on 64-bit systems when packed

Critical section

CRITICAL_SECTION = RTL_CRITICAL_SECTION;
PCRITICAL_SECTION = PRTL_CRITICAL_SECTION;
LPCRITICAL_SECTION = PRTL_CRITICAL_SECTION;
TCriticalSection = CRITICAL_SECTION;
PCriticalSection = PCRITICAL_SECTION;

RTL condition variable

RTL_CONDITION_VARIABLE = _RTL_CONDITION_VARIABLE;

TRtlConditionVariable = RTL_CONDITION_VARIABLE;

PRtlConditionVariable = PRTL_CONDITION_VARIABLE;

CONDITION_VARIABLE = RTL_CONDITION_VARIABLE;

PCONDITION_VARIABLE = PRTL_CONDITION_VARIABLE;

PRTL_CONDITION_VARIABLE = ^RTL_CONDITION_VARIABLE;

_RTL_CONDITION_VARIABLE = record

Ptr:Pointer;  

IO counters

IO_COUNTERS = _IO_COUNTERS;

TIoCounters = IO_COUNTERS;

PIoCounters = PIO_COUNTERS;

PIO_COUNTERS = ^IO_COUNTERS;

_IO_COUNTERS = record

ReadOperationCount:Int64;  
WriteOperationCount:Int64;  
OtherOperationCount:Int64;  
ReadTransferCount:Int64;  
WriteTransferCount:Int64;  
OtherTransferCount:Int64;  

Code page information

LPCPINFO = Locale.LPCPINFO;
_cpinfo = Locale._cpinfo;
CPINFO = Locale.CPINFO;
TCpInfo = Locale.TCpInfo;
PCpInfo = Locale.PCpInfo;

Code page information extended

CPINFOEX = Locale.CPINFOEX;
LPCPINFOEX = Locale.LPCPINFOEX;
TCpInfoEx = Locale.TCpInfoEx;
PCpInfoEx = Locale.PCpInfoEx;

Memory basic information

MEMORY_BASIC_INFORMATION = _MEMORY_BASIC_INFORMATION;

TMemoryBasicInformation = MEMORY_BASIC_INFORMATION;

PMemoryBasicInformation = PMEMORY_BASIC_INFORMATION;

PMEMORY_BASIC_INFORMATION = ^MEMORY_BASIC_INFORMATION;

_MEMORY_BASIC_INFORMATION = record

BaseAddress: Pointer;  
AllocationBase: Pointer;  
AllocationProtect: DWORD;  
RegionSize: SIZE_T;  
State: DWORD;  
Protect: DWORD;  
Type_: DWORD;  

FXPT16 color

FXPT16DOT16 = Longint;
LPFXPT16DOT16 = ^FXPT16DOT16;

FXPT2 color

FXPT2DOT30 = Longint;
LPFXPT2DOT30 = ^FXPT2DOT30;

CIEXYZ color

CIEXYZ = tagCIEXYZ;

LPCIEXYZ = ^CIEXYZ;

TCieXyz = CIEXYZ;

PCieXyz = ^TCieXyz;

tagCIEXYZ = record

ciexyzX: FXPT2DOT30;  
ciexyzY: FXPT2DOT30;  
ciexyzZ: FXPT2DOT30;  

CIEXYZ triple color

CIEXYZTRIPLE = tagCIEXYZTRIPLE;

LPCIEXYZTRIPLE = ^CIEXYZTRIPLE;

TCieXyzTriple = CIEXYZTRIPLE;

PCieXyzTriple = ^TCieXyzTriple;

tagCIEXYZTRIPLE = record

ciexyzRed: CIEXYZ;  
ciexyzGreen: CIEXYZ;  
ciexyzBlue: CIEXYZ;  

Bitmap types

BITMAP = tagBITMAP;

LPBITMAP = ^BITMAP;

NPBITMAP = ^BITMAP;

TBitmap = BITMAP;

PBitmap = ^TBitmap;

tagBITMAP = record

bmType: LONG;  
bmWidth: LONG;  
bmHeight: LONG;  
bmWidthBytes: LONG;  
bmPlanes: WORD;  
bmBitsPixel: WORD;  
bmBits: LPVOID;  

RGB triple color

RGBTRIPLE = tagRGBTRIPLE;

TRgbTriple = RGBTRIPLE;

PRgbTriple = ^TRgbTriple;

tagRGBTRIPLE = packed record

rgbtBlue: BYTE;  
rgbtGreen: BYTE;  
rgbtRed: BYTE;  

RGB quad color

RGBQUAD = tagRGBQUAD;

LPRGBQUAD = ^RGBQUAD;

TRgbQuad = RGBQUAD;

PRgbQuad = ^TRgbQuad;

tagRGBQUAD = record

rgbBlue: BYTE;  
rgbGreen: BYTE;  
rgbRed: BYTE;  
rgbReserved: BYTE;  

Bitmap core header

BITMAPCOREHEADER = tagBITMAPCOREHEADER;

LPBITMAPCOREHEADER = ^BITMAPCOREHEADER;

TBitmapCoreHeader = BITMAPCOREHEADER;

PBitmapCoreHeader = ^TBitmapCoreHeader;

tagBITMAPCOREHEADER = record

bcSize: DWORD;  
bcWidth: WORD;  
bcHeight: WORD;  
bcPlanes: WORD;  
bcBitCount: WORD;  

Bitmap info header

BITMAPINFOHEADER = tagBITMAPINFOHEADER;

LPBITMAPINFOHEADER = ^BITMAPINFOHEADER;

TBitmapInfoHeader = BITMAPINFOHEADER;

PBitmapInfoHeader = ^TBitmapInfoHeader;

tagBITMAPINFOHEADER = record

biSize: DWORD;  
biWidth: LONG;  
biHeight: LONG;  
biPlanes: WORD;  
biBitCount: WORD;  
biCompression: DWORD;  
biSizeImage: DWORD;  
biXPelsPerMeter: LONG;  
biYPelsPerMeter: LONG;  
biClrUsed: DWORD;  
biClrImportant: DWORD;  

Bitmap V4 header

LPBITMAPV4HEADER = ^BITMAPV4HEADER;

TBitmapV4Header = BITMAPV4HEADER;

PBitmapV4Header = ^TBitmapV4Header;

BITMAPV4HEADER = record

bV4Size: DWORD;  
bV4Width: LONG;  
bV4Height: LONG;  
bV4Planes: WORD;  
bV4BitCount: WORD;  
bV4V4Compression: DWORD;  
bV4SizeImage: DWORD;  
bV4XPelsPerMeter: LONG;  
bV4YPelsPerMeter: LONG;  
bV4ClrUsed: DWORD;  
bV4ClrImportant: DWORD;  
bV4RedMask: DWORD;  
bV4GreenMask: DWORD;  
bV4BlueMask: DWORD;  
bV4AlphaMask: DWORD;  
bV4CSType: DWORD;  
bV4Endpoints: CIEXYZTRIPLE;  
bV4GammaRed: DWORD;  
bV4GammaGreen: DWORD;  
bV4GammaBlue: DWORD;  

Bitmap V5 header

LPBITMAPV5HEADER = ^BITMAPV5HEADER;

TBitmapV5Header = BITMAPV5HEADER;

PBitmapV5Header = ^TBitmapV5Header;

BITMAPV5HEADER = record

bV5Size: DWORD;  
bV5Width: LONG;  
bV5Height: LONG;  
bV5Planes: WORD;  
bV5BitCount: WORD;  
bV5Compression: DWORD;  
bV5SizeImage: DWORD;  
bV5XPelsPerMeter: LONG;  
bV5YPelsPerMeter: LONG;  
bV5ClrUsed: DWORD;  
bV5ClrImportant: DWORD;  
bV5RedMask: DWORD;  
bV5GreenMask: DWORD;  
bV5BlueMask: DWORD;  
bV5AlphaMask: DWORD;  
bV5CSType: DWORD;  
bV5Endpoints: CIEXYZTRIPLE;  
bV5GammaRed: DWORD;  
bV5GammaGreen: DWORD;  
bV5GammaBlue: DWORD;  
bV5Intent: DWORD;  
bV5ProfileData: DWORD;  
bV5ProfileSize: DWORD;  
bV5Reserved: DWORD;  

Bitmap information

BITMAPINFO = tagBITMAPINFO;

LPBITMAPINFO = ^BITMAPINFO;

TBitmapInfo = BITMAPINFO;

PBitmapInfo = ^TBitmapInfo;

tagBITMAPINFO = record

bmiHeader: BITMAPINFOHEADER;  
bmiColors: array [0..0] of RGBQUAD;  

Bitmap core information

BITMAPCOREINFO = tagBITMAPCOREINFO;

LPBITMAPCOREINFO = ^BITMAPCOREINFO;

TBitmapCoreInfo = BITMAPCOREINFO;

PBitmapCoreInfo = ^TBitmapCoreInfo;

tagBITMAPCOREINFO = record

bmciHeader: BITMAPCOREHEADER;  
bmciColors: array [0..0] of RGBTRIPLE;  

Bitmap file header

BITMAPFILEHEADER = tagBITMAPFILEHEADER;

LPBITMAPFILEHEADER = ^BITMAPFILEHEADER;

TBitmapFileHeader = BITMAPFILEHEADER;

PBitmapFileHeader = ^TBitmapFileHeader;

tagBITMAPFILEHEADER = packed record

bfType: WORD;  
bfSize: DWORD;  
bfReserved1: WORD;  
bfReserved2: WORD;  
bfOffBits: DWORD;  

Handle file information

BY_HANDLE_FILE_INFORMATION = _BY_HANDLE_FILE_INFORMATION;

LPBY_HANDLE_FILE_INFORMATION = ^BY_HANDLE_FILE_INFORMATION;

TByHandleFileInformation = BY_HANDLE_FILE_INFORMATION;

PByHandleFileInformation = PBY_HANDLE_FILE_INFORMATION;

PBY_HANDLE_FILE_INFORMATION = ^BY_HANDLE_FILE_INFORMATION;

_BY_HANDLE_FILE_INFORMATION = record

dwFileAttributes: DWORD;  
ftCreationTime: FILETIME;  
ftLastAccessTime: FILETIME;  
ftLastWriteTime: FILETIME;  
dwVolumeSerialNumber: DWORD;  
nFileSizeHigh: DWORD;  
nFileSizeLow: DWORD;  
nNumberOfLinks: DWORD;  
nFileIndexHigh: DWORD;  
nFileIndexLow: DWORD;  

Ultibo types

TDriveType = (dtUNKNOWN,dtINVALID,dtFIXED,dtFLOPPY,dtREMOVABLE,dtNETWORK,dtSUBSTITUTED,dtRAMDRIVE,dtCDROM);
TFileSysType = (fsUNKNOWN,fsINVALID,fsFAT12,fsFAT16,fsFAT32,fsEXFAT,fsHPFS,fsNTFS,fsNTFS5,fsNTFS51,fsCDFS,fsUDF,fsEXT2,fsEXT3,fsEXT4);

Drive types

TDriveData = record

Drive:Byte;  
DriveType:TDriveType;  
FileSysType:TFileSysType;  
MaxFile:Integer;  
MaxPath:Integer;  
Attributes:LongWord;  
SystemName:String[32];  
VolumeName:String[32];  
VolumeSerial:LongWord;  

Drive functions (Compatibility)

TUltiboGetDriveTypeA = function(const ARootPath:String):LongWord;
TUltiboGetLogicalDrives = function:LongWord;
TUltiboGetLogicalDriveStringsA = function:String;
TUltiboDefineDosDeviceA = function(const ADeviceName,ATargetPath:String; AFlags:LongWord):Boolean;
TUltiboQueryDosDeviceA = function(const ARootPath:String):String;
TUltiboSetVolumeLabelA = function(const AVolume:String; const ALabel:String):Boolean;
TUltiboGetVolumeInformationA = function(const ARootPath:String; var AVolumeName:String; var VolumeSerialNumber,AMaximumComponentLength,AFileSystemFlags:LongWord; var SystemName:String):Boolean;
TUltiboGetDiskFreeSpaceA = function(const ARootPath:String; var ASectorsPerCluster,ABytesPerSector,ANumberOfFreeClusters,ATotalNumberOfClusters:LongWord):Boolean;
TUltiboGetDiskFreeSpaceExA = function(const APathName:String; var AFreeBytesAvailableToCaller,ATotalNumberOfBytes,ATotalNumberOfFreeBytes:QWord):Boolean;

Drive functions (Ultibo)

TUltiboGetDriveType = function(ADrive:Byte):TDriveType;
TUltiboGetDriveData = function(ADrive:Byte):TDriveData;
TUltiboGetDriveAttr = function(ADrive:Byte):LongWord;
TUltiboGetDriveLabel = function(ADrive:Byte):String;
TUltiboSetDriveLabel = function(ADrive:Byte; const ALabel:String):Boolean;
TUltiboGetDriveSerial = function(ADrive:Byte):LongWord;
TUltiboSetDriveSerial = function(ADrive:Byte; ASerial:LongWord):Boolean;
TUltiboIsDriveValid = function(ADrive:Byte):Boolean;
TUltiboGetValidDrives = function:LongWord;
TUltiboGetValidDriveNames = function:String;
TUltiboGetDriveFreeSpace = function(ADrive:Byte):LongWord;
TUltiboGetDriveFreeSpaceEx = function(ADrive:Byte):Int64;
TUltiboGetDriveTotalSpace = function(ADrive:Byte):LongWord;
TUltiboGetDriveTotalSpaceEx = function(ADrive:Byte):Int64;
 
TUltiboGetDriveInformation = function(const APath:String; var AClusterSize:LongWord; var ATotalClusterCount,AFreeClusterCount:Int64):Boolean;
 
TUltiboGetCurrentDrive = function:Byte;
TUltiboSetCurrentDrive = function(const ADrive:String):Boolean;

File functions (Compatibility)

TUltiboAreFileApisANSI = function:Boolean;
TUltiboSetFileApisToOEM = function:Boolean;
TUltiboSetFileApisToANSI = function:Boolean;
TUltiboCreateFileA = function(const AFileName:AnsiString; AAccessMode,AShareMode,ACreateFlags,AFileAttributes:LongWord):THandle;
TUltiboCloseFile = function(AHandle:THandle):Boolean;
TUltiboSetFileAttributesA = function(const AFileName:String; AFileAttributes:LongWord):Boolean;
TUltiboGetFileAttributesA = function(const AFileName:String):LongWord;
TUltiboDeleteFileA = function(const AFileName:String):Boolean;
TUltiboMoveFileA = function(const AExistingName,ANewName:String):Boolean;
TUltiboFindFirstFileA = function(const AFileName:String; var AFindData:TWin32FindData):THandle;
TUltiboFindNextFileA = function(AHandle:THandle; var AFindData:TWin32FindData):Boolean;
TUltiboFindCloseFile = function(AHandle:THandle):Boolean;
TUltiboGetFileSize = function(AHandle:THandle; var AFileSizeHigh:LongWord):LongWord;
TUltiboGetFileSizeEx = function(AHandle:THandle):Int64;
TUltiboGetFileTime = function(AHandle:THandle; ACreateTime,AAccessTime,AWriteTime:PFileTime):Boolean;
TUltiboSetFileTime = function(AHandle:THandle; ACreateTime,AAccessTime,AWriteTime:PFileTime):Boolean;
TUltiboReadFile = function(AHandle:THandle; var ABuffer; ABytesToRead:LongWord; var ABytesRead:LongWord):Boolean;
TUltiboWriteFile = function(AHandle:THandle; const ABuffer; ABytesToWrite:LongWord; var ABytesWritten:LongWord):Boolean;
TUltiboSetEndOfFile = function(AHandle:THandle):Boolean;
TUltiboSetFilePointer = function(AHandle:THandle; ADistanceToMove:LongInt; var ADistanceToMoveHigh:LongInt; AMoveMethod:LongWord):LongWord;
TUltiboSetFilePointerEx = function(AHandle:THandle; const ADistanceToMove:Int64; var ANewFilePointer:Int64; AMoveMethod:LongWord):Boolean;
TUltiboFlushFileBuffers = function(AHandle:THandle):Boolean;
TUltiboCopyFileA = function(const AExistingName,ANewName:String; AFailIfExists:Boolean):Boolean;
TUltiboSetFileShortNameA = function(AHandle:THandle; const AShortName:String):Boolean;
TUltiboCreateHardLinkA = function(const ALinkName,AFileName:String):Boolean;
TUltiboCreateSymbolicLinkA = function(const ALinkName,ATargetName:String; ADirectory:Boolean):Boolean;
TUltiboGetFileInformationByHandle = function(AHandle:THandle; var AFileInformation:TByHandleFileInformation):Boolean;

Directory functions (Compatibility)

TUltiboCreateDirectoryA = function(const APathName:String):Boolean;
TUltiboRemoveDirectoryA = function(const APathName:String):Boolean;
TUltiboSetCurrentDirectoryA = function(const APathName:String):Boolean;
TUltiboGetCurrentDirectoryA = function:String;
TUltiboGetLongPathNameA = function(const AShortPath:String):String;
TUltiboGetShortPathNameA = function(const ALongPath:String):String;
TUltiboGetFullPathNameA = function(const AFileName:String):String;


Public variables



Compatibility variables

CONDITION_VARIABLE_INIT:CONDITION_VARIABLE = (Ptr:nil);

Drive functions (Compatibility)

UltiboGetDriveTypeAHandler:TUltiboGetDriveTypeA;
UltiboGetLogicalDrivesHandler:TUltiboGetLogicalDrives;
UltiboGetLogicalDriveStringsAHandler:TUltiboGetLogicalDriveStringsA;
UltiboDefineDosDeviceAHandler:TUltiboDefineDosDeviceA;
UltiboQueryDosDeviceAHandler:TUltiboQueryDosDeviceA;
UltiboSetVolumeLabelAHandler:TUltiboSetVolumeLabelA;
UltiboGetVolumeInformationAHandler:TUltiboGetVolumeInformationA;
UltiboGetDiskFreeSpaceAHandler:TUltiboGetDiskFreeSpaceA;
UltiboGetDiskFreeSpaceExAHandler:TUltiboGetDiskFreeSpaceExA;

Drive functions (Ultibo)

UltiboGetDriveTypeHandler:TUltiboGetDriveType;
UltiboGetDriveDataHandler:TUltiboGetDriveData;
UltiboGetDriveAttrHandler:TUltiboGetDriveAttr;
UltiboGetDriveLabelHandler:TUltiboGetDriveLabel;
UltiboSetDriveLabelHandler:TUltiboSetDriveLabel;
UltiboGetDriveSerialHandler:TUltiboGetDriveSerial;
UltiboSetDriveSerialHandler:TUltiboSetDriveSerial;
UltiboIsDriveValidHandler:TUltiboIsDriveValid;
UltiboGetValidDrivesHandler:TUltiboGetValidDrives;
UltiboGetValidDriveNamesHandler:TUltiboGetValidDriveNames;
UltiboGetDriveFreeSpaceHandler:TUltiboGetDriveFreeSpace;
UltiboGetDriveFreeSpaceExHandler:TUltiboGetDriveFreeSpaceEx;
UltiboGetDriveTotalSpaceHandler:TUltiboGetDriveTotalSpace;
UltiboGetDriveTotalSpaceExHandler:TUltiboGetDriveTotalSpaceEx;
UltiboGetDriveInformationHandler:TUltiboGetDriveInformation;
UltiboGetCurrentDriveHandler:TUltiboGetCurrentDrive;
UltiboSetCurrentDriveHandler:TUltiboSetCurrentDrive;

File functions (Compatibility)

UltiboAreFileApisANSIHandler:TUltiboAreFileApisANSI;
UltiboSetFileApisToOEMHandler:TUltiboSetFileApisToOEM;
UltiboSetFileApisToANSIHandler:TUltiboSetFileApisToANSI;
UltiboCreateFileAHandler:TUltiboCreateFileA;
UltiboCloseFileHandler:TUltiboCloseFile;
UltiboSetFileAttributesAHandler:TUltiboSetFileAttributesA;
UltiboGetFileAttributesAHandler:TUltiboGetFileAttributesA;
UltiboDeleteFileAHandler:TUltiboDeleteFileA;
UltiboMoveFileAHandler:TUltiboMoveFileA;
UltiboFindFirstFileAHandler:TUltiboFindFirstFileA;
UltiboFindNextFileAHandler:TUltiboFindNextFileA;
UltiboFindCloseFileHandler:TUltiboFindCloseFile;
UltiboGetFileSizeHandler:TUltiboGetFileSize;
UltiboGetFileSizeExHandler:TUltiboGetFileSizeEx;
UltiboGetFileTimeHandler:TUltiboGetFileTime;
UltiboSetFileTimeHandler:TUltiboSetFileTime;
UltiboReadFileHandler:TUltiboReadFile;
UltiboWriteFileHandler:TUltiboWriteFile;
UltiboSetFilePointerHandler:TUltiboSetFilePointer;
UltiboSetEndOfFileHandler:TUltiboSetEndOfFile;
UltiboSetFilePointerExHandler:TUltiboSetFilePointerEx;
UltiboFlushFileBuffersHandler:TUltiboFlushFileBuffers;
UltiboCopyFileAHandler:TUltiboCopyFileA;
UltiboSetFileShortNameAHandler:TUltiboSetFileShortNameA;
UltiboCreateHardLinkAHandler:TUltiboCreateHardLinkA;
UltiboCreateSymbolicLinkAHandler:TUltiboCreateSymbolicLinkA;
UltiboGetFileInformationByHandleHandler:TUltiboGetFileInformationByHandle;

Directory functions (Compatibility)

UltiboCreateDirectoryAHandler:TUltiboCreateDirectoryA;
UltiboRemoveDirectoryAHandler:TUltiboRemoveDirectoryA;
UltiboSetCurrentDirectoryAHandler:TUltiboSetCurrentDirectoryA;
UltiboGetCurrentDirectoryAHandler:TUltiboGetCurrentDirectoryA;
UltiboGetLongPathNameAHandler:TUltiboGetLongPathNameA;
UltiboGetShortPathNameAHandler:TUltiboGetShortPathNameA;
UltiboGetFullPathNameAHandler:TUltiboGetFullPathNameA;


Function declarations



Initialization functions

procedure UltiboInit;
Description: To be documented
Note None documented


General functions (Compatibility)

function GetVersion:DWORD;
Description: To be documented
Note None documented


function GetVersionEx(lpVersionInformation:LPOSVERSIONINFOA):BOOL; inline;
Description: To be documented
Note None documented


function GetVersionExA(lpVersionInformation:LPOSVERSIONINFOA):BOOL;
Description: To be documented
Note None documented


function GetVersionExW(lpVersionInformation:LPOSVERSIONINFOW):BOOL;
Description: To be documented
Note None documented


procedure GetSystemInfo(var lpSystemInfo:SYSTEM_INFO);
Description: To be documented
Note None documented


procedure GetNativeSystemInfo(lpSystemInfo:LPSYSTEM_INFO);
Description: To be documented
Note None documented


function GetLargePageMinimum:SIZE_T;
Description: To be documented
Note None documented


function GetComputerName(lpBuffer:LPSTR; var nSize:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function GetComputerNameA(lpBuffer:LPSTR; var nSize:DWORD):BOOL;
Description: To be documented
Note None documented


function GetComputerNameW(lpBuffer:LPWSTR; var nSize:DWORD):BOOL;
Description: To be documented
Note None documented


function SetComputerName(lpComputerName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetComputerNameA(lpComputerName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetComputerNameW(lpComputerName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function GetComputerNameEx(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPSTR; var nSize:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function GetComputerNameExA(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPSTR; var nSize:DWORD):BOOL;
Description: To be documented
Note None documented


function GetComputerNameExW(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPWSTR; var nSize:DWORD):BOOL;
Description: To be documented
Note None documented


function SetComputerNameEx(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetComputerNameExA(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetComputerNameExW(NameType:COMPUTER_NAME_FORMAT; lpBuffer:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function ExitUltibo(dwReserved:DWORD; uReserved:UINT):BOOL;
Description: To be documented
Note None documented


function ExitUltiboEx(uFlags:UINT; dwReserved:DWORD):BOOL;
Description: To be documented
Note None documented


General functions (Ultibo)

function RestartComputer(Delay:LongWord):Boolean;
Description: To be documented
Delay Milliseconds to delay before restart


function ShutdownComputer(Delay:LongWord):Boolean;
Description: To be documented
Delay Milliseconds to delay before restart


function Uptime:TFileTime;
Description: Get the current system up time as a FileTime value
Note None documented


Time functions (Compatibility)

function GetTickCount:DWORD;
Description: To be documented
Note None documented


function GetTickCount64:ULONGLONG;
Description: To be documented
Note None documented


procedure GetSystemTime(var lpSystemTime:SYSTEMTIME);
Description: Get the current system time in UTC
Note None documented


procedure GetSystemTimeAsFileTime(var lpSystemTimeAsFileTime:FILETIME);
Description: Get the current system time in UTC as a FileTime value
Note None documented


function SetSystemTime(var lpSystemTime:SYSTEMTIME):BOOL;
Description: Set the current system time in UTC
Note None documented


procedure GetLocalTime(var lpSystemTime:SYSTEMTIME);
Description: Get the current local time
Note None documented


function SetLocalTime(var lpSystemTime:SYSTEMTIME):BOOL;
Description: Set the current local time
Note None documented


function SystemTimeToTzSpecificLocalTime(lpTimeZoneInformation:LPTIME_ZONE_INFORMATION; var lpUniversalTime,lpLocalTime:SYSTEMTIME):BOOL;
Description: To be documented
Note None documented


function TzSpecificLocalTimeToSystemTime(const lpTimeZoneInformation:TIME_ZONE_INFORMATION; const lpLocalTime:SYSTEMTIME; var lpUniversalTime:SYSTEMTIME):BOOL;
Description: To be documented
Note None documented


function GetTimeZoneInformation(var lpTimeZoneInformation:TIME_ZONE_INFORMATION):DWORD;
Description: To be documented
Note None documented


function SetTimeZoneInformation(const lpTimeZoneInformation:TIME_ZONE_INFORMATION):BOOL;
Description: To be documented
Note None documented


function SystemTimeToFileTime(const lpSystemTime:SYSTEMTIME; var lpFileTime:FILETIME):BOOL;
Description: Convert a SystemTime value to a FileTime value
Note lpSystemTime is assumed to be UTC/lpFileTime is returned as UTC


function FileTimeToSystemTime(const lpFileTime:FILETIME; var lpSystemTime:SYSTEMTIME):BOOL;
Description: Convert a FileTime value to a SystemTime value
Note lpFileTime is assumed to be UTC/lpSystemTime is returned as UTC. If lpFileTime is less than 30/12/1899 then SystemTime will be zero.


function FileTimeToLocalFileTime(const lpFileTime:FILETIME; var lpLocalFileTime:FILETIME):BOOL;
Description: Convert a FileTime in UTC to a FileTime in Local time
Note TIMEZONE_TIME_OFFSET is the number of minutes offset from UTC


function LocalFileTimeToFileTime(const lpLocalFileTime:FILETIME; var lpFileTime:FILETIME):BOOL;
Description: Convert a FileTime in Local time to a FileTime in UTC
Note TIMEZONE_TIME_OFFSET is the number of minutes offset from UTC


function CompareFileTime(const lpFileTime1,lpFileTime2:FILETIME):LONG;
Description: To be documented
Note None documented


function FileTimeToDosDateTime(const lpFileTime:FILETIME; var lpFatDate,lpFatTime:WORD):BOOL;
Description: Convert a FileTime value to a DOS date and time value
Note FileTime is assumed to be Local / DOS date and time is returned as Local. If FileTime is less than 1/1/1980 then DOS date and time will be 1/1/1980.


function DosDateTimeToFileTime(wFatDate,wFatTime:WORD; var lpFileTime:FILETIME):BOOL;
Description: Convert a DOS date and time value to a FileTime value
Note DOS date and time is assumed to be Local/FileTime is returned as Local. If DOS date and time is less than 1/1/1980 then FileTime will be 1/1/1980.


function QueryPerformanceCounter(var lpPerformanceCount: LARGE_INTEGER): BOOL;
Description: Retrieves the current value of the performance counter, which is a high resolution (<1us) time stamp that can be used for time-interval measurements
Note None documented


function QueryPerformanceFrequency(var lpFrequency: LARGE_INTEGER): BOOL;
Description: Retrieves the frequency of the performance counter
Note The frequency of the performance counter is fixed at system boot and is consistent across all processors. Therefore, the frequency need only be queried upon application initialization, and the result can be cached.


Time functions (Ultibo)

function GetCurrentTime:TFileTime;
Description: Get the current system time in UTC as a FileTime value
Note None documented


procedure SetCurrentTime(const ATime:TFileTime);
Description: Set the current system time in UTC from a FileTime value
Note None documented


function GetTimeAdjust:LongInt;
Description: Gets the time adjustment used internally
Note None documented


procedure SetTimeAdjust(AAdjust:LongInt);
Description: Sets the time adjustment used internally
Note None documented


function GetCurrentTimezone:String;
Description: Get the name of the current Timezone
Note None documented


function SetCurrentTimezone(const AName:String):Boolean;
Description: Set the current Timezone by name
Note None documented


function GetTimezoneActiveOffset:LongInt;
Description: Gets the Active Offset from the current Timezone
Note None documented


function GetTimezoneStandardOffset:LongInt;
Description: Gets the Standard Offset from the current Timezone
Note None documented


procedure SetTimezoneStandardOffset(AOffset:LongInt);
Description: Sets the Standard Offset for the current Timezone
Note None documented


function GetTimezoneDaylightOffset:LongInt;
Description: Gets the Daylight Offset from the current Timezone
Note None documented


procedure SetTimezoneDaylightOffset(AOffset:LongInt);
Description: Sets the Daylight Offset for the current Timezone
Note None documented


function GetTimezoneStandardStart:String;
Description: Get the description of the standard time start for the current Timezone
Note None documented


function GetTimezoneDaylightStart:String;
Description: Get the description of the daylight time start for the current Timezone
Note None documented


function GetTimezoneStandardDate:TDateTime;
Description: Get the next date of the standard time start for the current Timezone
Note None documented


function GetTimezoneDaylightDate:TDateTime;
Description: Get the next date of the daylight time start for the current Timezone
Note None documented


function FileTimeToDateTime(const AFileTime:TFileTime):TDateTime;
Description: Convert a FileTime value to a DateTime value
Note FileTime is assumed to be UTC/DateTime is returned as Local. If FileTime is less than 30/12/1899 then Result will be zero.


function DateTimeToFileTime(ADateTime:TDateTime):TFileTime;
Description: Convert a DateTime value to a FileTime value
Note DateTime is assumed to be Local/FileTime is returned as UTC


function LocalFileTimeToDateTime(const AFileTime:TFileTime):TDateTime;
Description: Convert a FileTime value to a DateTime value
Note FileTime is assumed to be Local/DateTime is returned as Local. If FileTime is less than 30/12/1899 then Result will be zero.


function DateTimeToLocalFileTime(ADateTime:TDateTime):TFileTime;
Description: Convert a DateTime value to a FileTime value
Note DateTime is assumed to be Local/FileTime is returned as Local


function SystemFileTimeToDateTime(const AFileTime:TFileTime):TDateTime;
Description: Convert a FileTime value to a DateTime value
Note FileTime is assumed to be UTC/DateTime is returned as UTC. If FileTime is less than 30/12/1899 then Result will be zero. Same as LocalFileTimeToDateTime but renamed for clarity.


function DateTimeToSystemFileTime(ADateTime:TDateTime):TFileTime;
Description: Convert a DateTime value to a FileTime value
Note DateTime is assumed to be UTC/FileTime is returned as UTC. Same as DateTimeToLocalFileTime but renamed for clarity.


function FileTimeToUnixTime(const AFileTime:TFileTime):TUnixTime;
Description: Convert a FileTime value to a Unix/Linux time value
Note FileTime is assumed to be Local/UnixTime is returned as Local. If FileTime is less than 1/1/1970 then Result will be zero.


function UnixTimeToFileTime(AUnixTime:TUnixTime):TFileTime;
Description: Convert a Unix/Linux time value to a FileTime value
Note UnixTime is assumed to be Local/FileTime is returned as Local


function UnixTimeToDateTime(AUnixTime:TUnixTime):TDateTime;
Description: Convert a Unix/Linux time value to a DateTime value
Note UnixTime is assumed to be Local/DateTime is returned as Local


function DateTimeToUnixTime(ADateTime:TDateTime):TUnixTime;
Description: Convert a DateTime value to a Unix/Linux time value
Note DateTime is assumed to be Local/UnixTime is returned as Local. If DateTime is less than 1/1/1970 then Result will be zero.


function FileTimeToFileDate(const AFileTime:TFileTime):Integer;
Description: Convert a FileTime value to a DOS date value
Note FileTime is assumed to be UTC/FileDate is returned as Local. If FileTime is less than 1/1/1980 then Result will be zero.


function FileDateToFileTime(AFileDate:Integer):TFileTime;
Description: Convert a DOS date value to a FileTime value
Note FileDate is assumed to be Local/FileTime is returned as UTC. If FileDate is less than 1/1/1980 then Result will be zero.


function FileTimeToAdjustedTime(const AFileTime:TFileTime):TFileTime;
Description: Convert a local FileTime value to a DST adjusted FileTime value
Note TIMEZONE_TIME_ADJUST is the number of minutes difference from TIMEZONE_TIME_OFFSET


function AdjustedTimeToFileTime(const AFileTime:TFileTime):TFileTime;
Description: Convert a DST adjusted FileTime value to a local FileTime value
Note TIMEZONE_TIME_ADJUST is the number of minutes difference from TIMEZONE_TIME_OFFSET


function RoundFileTime(const AFileTime:TFileTime):TFileTime;
Description: Round FileTime to nearest 2 seconds for compatibility with FileDate
Note None documented


function ConvertFileTime(const AFileTime:TFileTime; AOffset:Integer; ALocal:Boolean):TFileTime;
Description: Convert a FileTime value to a specified offset (Local or UTC)
Note Offset is the number of minutes to adjust in conversion. Local indicates whether the source time is Local or UTC.


function ConvertDateTime(ADateTime:TDateTime; AOffset:Integer; ALocal:Boolean):TDateTime;
Description: Convert a DateTime value to a specified offset (Local or UTC)
Note Offset is the number of minutes to adjust in conversion. Local indicates whether the source time is Local or UTC.


Drive functions (Compatibility)

function GetDiskType(lpRootPathName:LPCSTR):UINT; inline;
Description: To be documented
Note None documented


function GetDriveTypeA(lpRootPathName:LPCSTR):UINT;
Description: To be documented
Note None documented


function GetDriveTypeW(lpRootPathName:LPCWSTR):UINT;
Description: To be documented
Note None documented


function GetLogicalDrives:DWORD;
Description: To be documented
Note None documented


function GetLogicalDriveStrings(nBufferLength:DWORD; lpBuffer:LPSTR):DWORD; inline;
Description: To be documented
Note None documented


function GetLogicalDriveStringsA(nBufferLength:DWORD; lpBuffer:LPSTR):DWORD;
Description: To be documented
Note None documented


function GetLogicalDriveStringsW(nBufferLength:DWORD; lpBuffer:LPWSTR):DWORD;
Description: To be documented
Note None documented


function DefineDosDevice(dwFlags:DWORD; lpDeviceName,lpTargetPath:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function DefineDosDeviceA(dwFlags:DWORD; lpDeviceName,lpTargetPath:LPCSTR):BOOL;
Description: To be documented
Note None documented


function DefineDosDeviceW(dwFlags:DWORD; lpDeviceName,lpTargetPath:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function QueryDosDevice(lpDeviceName,lpTargetPath:LPSTR; ucchMax:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function QueryDosDeviceA(lpDeviceName,lpTargetPath:LPSTR; ucchMax:DWORD):DWORD;
Description: To be documented
Note None documented


function QueryDosDeviceW(lpDeviceName,lpTargetPath:LPWSTR; ucchMax:DWORD):DWORD;
Description: To be documented
Note None documented


function SetVolumeLabel(lpRootPathName,lpVolumeName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetVolumeLabelA(lpRootPathName,lpVolumeName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetVolumeLabelW(lpRootPathName,lpVolumeName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function GetVolumeInformation(lpRootPathName:LPCSTR; lpVolumeNameBuffer:LPSTR; nVolumeNameSize:DWORD; lpVolumeSerialNumber:LPDWORD; var lpMaximumComponentLength,lpFileSystemFlags:DWORD; lpFileSystemNameBuffer:LPSTR; nFileSystemNameSize:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function GetVolumeInformationA(lpRootPathName:LPCSTR; lpVolumeNameBuffer:LPSTR; nVolumeNameSize:DWORD; lpVolumeSerialNumber:LPDWORD; var lpMaximumComponentLength,lpFileSystemFlags:DWORD;lpFileSystemNameBuffer:LPSTR; nFileSystemNameSize:DWORD):BOOL;
Description: To be documented
Note None documented


function GetVolumeInformationW(lpRootPathName:LPCWSTR; lpVolumeNameBuffer:LPWSTR; nVolumeNameSize:DWORD; lpVolumeSerialNumber:LPDWORD; var lpMaximumComponentLength,lpFileSystemFlags:DWORD;lpFileSystemNameBuffer:LPWSTR; nFileSystemNameSize:DWORD):BOOL;
Description: To be documented
Note None documented


function GetDiskFreeSpace(lpRootPathName:LPCSTR; var lpSectorsPerCluster,lpBytesPerSector,lpNumberOfFreeClusters,lpTotalNumberOfClusters:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function GetDiskFreeSpaceA(lpRootPathName:LPCSTR; var lpSectorsPerCluster,lpBytesPerSector,lpNumberOfFreeClusters,lpTotalNumberOfClusters:DWORD):BOOL;
Description: To be documented
Note None documented


function GetDiskFreeSpaceW(lpRootPathName:LPCWSTR; var lpSectorsPerCluster,lpBytesPerSector,lpNumberOfFreeClusters,lpTotalNumberOfClusters:DWORD):BOOL;
Description: To be documented
Note None documented


function GetDiskFreeSpaceEx(lpDirectoryName:LPCSTR; var lpFreeBytesAvailableToCaller,lpTotalNumberOfBytes:ULARGE_INTEGER; lpTotalNumberOfFreeBytes:PULARGE_INTEGER):BOOL; inline;
Description: To be documented
Note None documented


function GetDiskFreeSpaceExA(lpDirectoryName:LPCSTR; var lpFreeBytesAvailableToCaller,lpTotalNumberOfBytes:ULARGE_INTEGER; lpTotalNumberOfFreeBytes:PULARGE_INTEGER):BOOL;
Description: To be documented
Note None documented


function GetDiskFreeSpaceExW(lpDirectoryName:LPCWSTR; var lpFreeBytesAvailableToCaller,lpTotalNumberOfBytes:ULARGE_INTEGER; lpTotalNumberOfFreeBytes:PULARGE_INTEGER):BOOL;
Description: To be documented
Note None documented


Drive functions (Ultibo)

function GetPathDrive(const APath:String):Byte;
Description: To be documented
Note None documented


function GetDriveType(ADrive:Byte):TDriveType;
Description: To be documented
Note None documented


function GetDriveData(ADrive:Byte):TDriveData;
Description: To be documented
Note None documented


function GetDriveAttr(ADrive:Byte):LongWord;
Description: To be documented
Note None documented


function GetDriveLabel(ADrive:Byte):String;
Description: To be documented
Note None documented


function SetDriveLabel(ADrive:Byte; const ALabel:String):Boolean;
Description: To be documented
Note None documented


function GetDriveSerial(ADrive:Byte):LongWord;
Description: To be documented
Note None documented


function SetDriveSerial(ADrive:Byte; ASerial:LongWord):Boolean;
Description: To be documented
Note None documented


function IsDriveValid(ADrive:Byte):Boolean;
Description: To be documented
Note None documented


function GetValidDrives:LongWord;
Description: To be documented
Note None documented


function GetValidDriveNames:String;
Description: To be documented
Note None documented


function GetDriveFreeSpace(ADrive:Byte):LongWord;
Description: To be documented
Note None documented


function GetDriveFreeSpaceEx(ADrive:Byte):Int64;
Description: To be documented
Note None documented


function GetDriveTotalSpace(ADrive:Byte):LongWord;
Description: To be documented
Note None documented


function GetDriveTotalSpaceEx(ADrive:Byte):Int64;
Description: To be documented
Note None documented


function GetDriveInformation(const APath:String; var AClusterSize:LongWord; var ATotalClusterCount,AFreeClusterCount:Int64):Boolean;
Description: To be documented
Note None documented


function GetCurrentDrive:Byte;
Description: To be documented
Note None documented


function SetCurrentDrive(const ADrive:String):Boolean;
Description: To be documented
Note None documented


File functions (Compatibility)

function AreFileApisANSI:BOOL;
Description: To be documented
Note None documented


procedure SetFileApisToOEM;
Description: To be documented
Note None documented


procedure SetFileApisToANSI;
Description: To be documented
Note None documented


function CreateFile(lpFileName:LPCSTR; dwDesiredAccess,dwShareMode:DWORD; lpSecurityAttributes:LPSECURITY_ATTRIBUTES; dwCreationDisposition:DWORD; dwFlagsAndAttributes:DWORD; hTemplateFile:HANDLE):HANDLE; inline;
Description: To be documented
Note None documented


function CreateFileA(lpFileName:LPCSTR; dwDesiredAccess,dwShareMode:DWORD; lpSecurityAttributes:LPSECURITY_ATTRIBUTES; dwCreationDisposition:DWORD; dwFlagsAndAttributes:DWORD; hTemplateFile:HANDLE):HANDLE;
Description: To be documented
Note lpSecurityAttributes and hTemplateFile are currently ignored by Ultibo


function CreateFileW(lpFileName:LPCWSTR; dwDesiredAccess,dwShareMode:DWORD; lpSecurityAttributes:LPSECURITY_ATTRIBUTES; dwCreationDisposition:DWORD; dwFlagsAndAttributes:DWORD; hTemplateFile:HANDLE):HANDLE;
Description: To be documented
Note lpSecurityAttributes and hTemplateFile are currently ignored by Ultibo


function SetFileAttributes(lpFileName:LPCSTR; dwFileAttributes:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function SetFileAttributesA(lpFileName:LPCSTR; dwFileAttributes:DWORD):BOOL;
Description: To be documented
Note None documented


function SetFileAttributesW(lpFileName:LPCWSTR; dwFileAttributes:DWORD):BOOL;
Description: To be documented
Note None documented


function GetFileAttributes(lpFileName:LPCSTR):DWORD; inline;
Description: To be documented
Note None documented


function GetFileAttributesA(lpFileName:LPCSTR):DWORD;
Description: To be documented
Note None documented


function GetFileAttributesW(lpFileName:LPCWSTR):DWORD;
Description: To be documented
Note None documented


function DeleteFile(lpFileName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function DeleteFileA(lpFileName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function DeleteFileW(lpFileName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function MoveFile(lpExistingFileName,lpNewFileName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function MoveFileA(lpExistingFileName,lpNewFileName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function MoveFileW(lpExistingFileName,lpNewFileName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function FindFirstFile(lpFileName:LPCSTR; var lpFindFileData:WIN32_FIND_DATAA):HANDLE; inline;
Description: To be documented
Note None documented


function FindFirstFileA(lpFileName:LPCSTR; var lpFindFileData:WIN32_FIND_DATAA):HANDLE;
Description: To be documented
Note None documented


function FindFirstFileW(lpFileName:LPCWSTR; var lpFindFileData:WIN32_FIND_DATAW):HANDLE;
Description: To be documented
Note None documented


function FindNextFile(hFindFile:HANDLE; var lpFindFileData:WIN32_FIND_DATAA):BOOL; inline;
Description: To be documented
Note None documented


function FindNextFileA(hFindFile:HANDLE; var lpFindFileData:WIN32_FIND_DATAA):BOOL;
Description: To be documented
Note None documented


function FindNextFileW(hFindFile:HANDLE; var lpFindFileData:WIN32_FIND_DATAW):BOOL;
Description: To be documented
Note None documented


function FindCloseFile(hFindFile:HANDLE):BOOL;
Description: To be documented
Note None documented


function GetFileSize(hFile:HANDLE;lpFileSizeHigh:LPDWORD):DWORD;
Description: To be documented
Note None documented


function GetFileSizeEx(hFile:HANDLE; var lpFileSize:LARGE_INTEGER):BOOL;
Description: To be documented
Note None documented


function GetFileTime(hFile:HANDLE; lpCreationTime,lpLastAccessTime,lpLastWriteTime:PFILETIME):BOOL;
Description: To be documented
Note None documented


function SetFileTime(hFile:HANDLE; lpCreationTime,lpLastAccessTime,lpLastWriteTime:PFILETIME):BOOL;
Description: To be documented
Note None documented


function ReadFile(hFile:HANDLE; lpBuffer:LPVOID; nNumberOfBytesToRead:DWORD; lpNumberOfBytesRead:LPDWORD; lpOverlapped:LPOVERLAPPED):BOOL;
Description: To be documented
Note None documented


function WriteFile(hFile:HANDLE; lpBuffer:LPCVOID; nNumberOfBytesToWrite:DWORD; lpNumberOfBytesWritten:LPDWORD; lpOverlapped:LPOVERLAPPED):BOOL;
Description: To be documented
Note None documented


function SetEndOfFile(hFile:HANDLE):BOOL;
Description: To be documented
Note None documented


function SetFilePointer(hFile:HANDLE; lDistanceToMove:LONG; lpDistanceToMoveHigh:PLONG; dwMoveMethod:DWORD):DWORD;
Description: To be documented
Note None documented


function SetFilePointerEx(hFile:HANDLE; liDistanceToMove:LARGE_INTEGER; lpNewFilePointer:PLARGE_INTEGER; dwMoveMethod:DWORD):BOOL;
Description: To be documented
Note None documented


function FlushFileBuffers(hFile:HANDLE):BOOL;
Description: To be documented
Note None documented


function CopyFile(lpExistingFileName,lpNewFileName:LPCSTR; bFailIfExists:BOOL):BOOL; inline;
Description: To be documented
Note None documented


function CopyFileA(lpExistingFileName,lpNewFileName:LPCSTR; bFailIfExists:BOOL):BOOL;
Description: To be documented
Note None documented


function CopyFileW(lpExistingFileName,lpNewFileName:LPCWSTR; bFailIfExists:BOOL):BOOL;
Description: To be documented
Note None documented


function SetFileShortName(hFile:HANDLE; lpShortName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetFileShortNameA(hFile:HANDLE; lpShortName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetFileShortNameW(hFile:HANDLE; lpShortName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function CreateHardLink(lpFileName,lpExistingFileName:LPCSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL; inline;
Description: To be documented
Note None documented


function CreateHardLinkA(lpFileName,lpExistingFileName:LPCSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL;
Description: To be documented
Note lpSecurityAttributes is currently ignored by Ultibo


function CreateHardLinkW(lpFileName,lpExistingFileName:LPCWSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL;
Description: To be documented
Note lpSecurityAttributes is currently ignored by Ultibo


function CreateSymbolicLink(lpSymlinkFileName,lpTargetFileName:LPCSTR; dwFlags:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function CreateSymbolicLinkA(lpSymlinkFileName,lpTargetFileName:LPCSTR; dwFlags:DWORD):BOOL;
Description: To be documented
Note None documented


function CreateSymbolicLinkW(lpSymlinkFileName,lpTargetFileName:LPCWSTR; dwFlags:DWORD):BOOL;
Description: To be documented
Note None documented


function GetFileInformationByHandle(hFile:HANDLE; var lpFileInformation:BY_HANDLE_FILE_INFORMATION):BOOL;
Description: To be documented
Note None documented


Directory functions (Compatibility)

function CreateDirectory(lpPathName:LPCSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL; inline;
Description: To be documented
Note None documented


function CreateDirectoryA(lpPathName:LPCSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL;
Description: To be documented
Note lpSecurityAttributes is currently ignored by Ultibo


function CreateDirectoryW(lpPathName:LPCWSTR; lpSecurityAttributes:LPSECURITY_ATTRIBUTES):BOOL;
Description: To be documented
Note lpSecurityAttributes is currently ignored by Ultibo


function RemoveDirectory(lpPathName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function RemoveDirectoryA(lpPathName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function RemoveDirectoryW(lpPathName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function SetCurrentDirectory(lpPathName:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetCurrentDirectoryA(lpPathName:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetCurrentDirectoryW(lpPathName:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function GetCurrentDirectory(nBufferLength:DWORD; lpBuffer:LPSTR):DWORD; inline;
Description: To be documented
Note None documented


function GetCurrentDirectoryA(nBufferLength:DWORD; lpBuffer:LPSTR):DWORD;
Description: To be documented
Note None documented


function GetCurrentDirectoryW(nBufferLength:DWORD; lpBuffer:LPWSTR):DWORD;
Description: To be documented
Note None documented


function GetLongPathName(lpszShortPath:LPCSTR; lpszLongPath:LPSTR; cchBuffer:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function GetLongPathNameA(lpszShortPath:LPCSTR; lpszLongPath:LPSTR; cchBuffer:DWORD):DWORD;
Description: To be documented
Note None documented


function GetLongPathNameW(lpszShortPath:LPCWSTR; lpszLongPath:LPWSTR; cchBuffer:DWORD):DWORD;
Description: To be documented
Note None documented


function GetShortPathName(lpszLongPath:LPCSTR; lpszShortPath:LPSTR; cchBuffer:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function GetShortPathNameA(lpszLongPath:LPCSTR; lpszShortPath:LPSTR; cchBuffer:DWORD):DWORD;
Description: To be documented
Note None documented


function GetShortPathNameW(lpszLongPath:LPCWSTR; lpszShortPath:LPWSTR; cchBuffer:DWORD):DWORD;
Description: To be documented
Note None documented


function GetFullPathName(lpFileName:LPCSTR; nBufferLength:DWORD; lpBuffer:LPSTR; var lpFilePart:LPSTR):DWORD; inline;
Description: To be documented
Note None documented


function GetFullPathNameA(lpFileName:LPCSTR; nBufferLength:DWORD; lpBuffer:LPSTR; var lpFilePart:LPSTR):DWORD;
Description: To be documented
Note lpFilePart is currently ignored by Ultibo


function GetFullPathNameW(lpFileName:LPCWSTR; nBufferLength:DWORD; lpBuffer:LPWSTR; var lpFilePart:LPWSTR):DWORD;
Description: To be documented
Note lpFilePart is currently ignored by Ultibo


Command line functions (RTL)

function SysParamCount:LongInt;
Description: To be documented
Note This should be in System however the implementation there will need to be modified


function SysParamStr(Index:LongInt):String;
Description: To be documented
Note This should be in System however the implementation there will need to be modified


Command line functions (Compatibility)

function GetCommandLine:LPSTR; inline;
Description: To be documented
Note None documented


function GetCommandLineA:LPSTR;
Description: To be documented
Note The returned string must be freed with SysUtils.StrDispose


function GetCommandLineW:LPWSTR;
Description: To be documented
Note The returned string must be freed with SysUtils.StrDispose


Command line functions (Ultibo)

function IsParamPresent(const AParam:String):Boolean;
Description: Check if the specified parameter is present in the command line
Note None documented


function GetParamIndex(const AParam:String):Integer;
Description: Get the index of the specified parameter in the command line
Note None documented


function GetParamValue(const AParam:String):String;
Description: Get the value of the specified parameter from the command line
Note None documented


Environment functions (Compatibility)

function GetEnvironmentStrings:LPSTR; inline;
Description: To be documented
Note None documented


function GetEnvironmentStringsA:LPSTR;
Description: To be documented
Note None documented


function GetEnvironmentStringsW:LPWSTR;
Description: To be documented
Note None documented


function FreeEnvironmentStrings(pstr:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function FreeEnvironmentStringsA(pstr:LPSTR):BOOL;
Description: To be documented
Note None documented


function FreeEnvironmentStringsW(pstr:LPWSTR):BOOL;
Description: To be documented
Note None documented


function GetEnvironmentVariable(lpName:LPCSTR; lpBuffer:LPSTR; nSize:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function GetEnvironmentVariableA(lpName:LPCSTR; lpBuffer:LPSTR; nSize:DWORD):DWORD;
Description: To be documented
Note None documented


function GetEnvironmentVariableW(lpName:LPCWSTR; lpBuffer:LPWSTR; nSize:DWORD):DWORD;
Description: To be documented
Note None documented


function SetEnvironmentVariable(lpName,lpValue:LPCSTR):BOOL; inline;
Description: To be documented
Note None documented


function SetEnvironmentVariableA(lpName,lpValue:LPCSTR):BOOL;
Description: To be documented
Note None documented


function SetEnvironmentVariableW(lpName,lpValue:LPCWSTR):BOOL;
Description: To be documented
Note None documented


function ExpandEnvironmentStrings(lpSrc:LPCSTR; lpDst:LPSTR; nSize:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function ExpandEnvironmentStringsA(lpSrc:LPCSTR; lpDst:LPSTR; nSize:DWORD):DWORD;
Description: To be documented
Note None documented


function ExpandEnvironmentStringsW(lpSrc:LPCWSTR; lpDst:LPWSTR; nSize:DWORD):DWORD;
Description: To be documented
Note None documented


Error functions (Compatibility)

function GetLastError:DWORD; inline;
Description: Get the last error value for the calling thread
Note None documented


procedure SetLastError(dwErrCode:DWORD); inline;
Description: Set the last error value for the calling thread
Note None documented


GUID functions (Ultibo)

function CreateGUID:TGUID;
Description: GUID has the following format DWORD-WORD-WORD-WORD-WORDDWORD | Not Swapped |
Note None documented


function GUIDToString(const Value:TGUID):String;
Description: To be documented
Note None documented


function StringToGUID(const Value:String):TGUID;
Description: To be documented
Note None documented


function NullGUID(const GUID:TGUID):Boolean;
Description: To be documented
Note None documented


function CompareGUID(const GUID1,GUID2:TGUID):Boolean;
Description: To be documented
Note None documented


SID functions (Ultibo)

function SIDToString(ASID:PSID):String;
Description: To be documented
Note None documented


function StringToSID(const Value:String):PSID;
Description: To be documented
Note None documented


Numeric functions (Ultibo)

function Min(A,B:Integer):Integer; inline;
Description: To be documented
Note None documented


function Max(A,B:Integer):Integer; inline;
Description: To be documented
Note None documented


function MinEx(A,B:LongWord):LongWord; inline;
Description: To be documented
Note None documented


function MaxEx(A,B:LongWord):LongWord; inline;
Description: To be documented
Note None documented


function Min64(const A,B:Int64):Int64; inline;
Description: To be documented
Note None documented


function Max64(const A,B:Int64):Int64; inline;
Description: To be documented
Note None documented


function Or64(const Value1,Value2:Int64):Int64; inline;
Description: To be documented
Note None documented


function And64(const Value1,Value2:Int64):Int64; inline;
Description: To be documented
Note None documented


function Xor64(const Value1,Value2:Int64):Int64; inline;
Description: To be documented
Note None documented


function Not64(const Value:Int64):Int64; inline;
Description: To be documented
Note None documented


function Rol32(Value:LongWord; Count:Byte):LongWord; inline;
Description: To be documented
Note None documented


function Ror32(Value:LongWord; Count:Byte):LongWord; inline;
Description: To be documented
Note None documented


function WordSwap(AValue:Word):Word; inline;
Description: To be documented
Note None documented


function LongSwap(AValue:LongWord):LongWord; inline;
Description: To be documented
Note None documented


function Int64Swap(const AValue:Int64):Int64; inline;
Description: To be documented
Note None documented


function BufferSwap(ABuffer:Pointer; ASize:LongWord):Boolean;
Description: Swap each word in the buffer supplied up to size
Note Size is the number of Bytes in the buffer to swap


Hash functions (Ultibo)

function GenerateNameHash(const Name:String; Size:Integer):LongWord;
Description: Sum of (byte value + 1) * (position + 257) for all bytes in uppercase string
Note Case Insensitive Hash


function GeneratePasswordHash(const Password:String):LongWord;
Description: Deprecated function, use GenerateStringHash instead
Note None documented


function GenerateStringHash(const Value:String; CaseSensitive:Boolean):LongWord;
Description: Sum of (byte value + 1) * (position + 257) for all bytes in string
Note None documented


Locale functions (Compatibility)

function IsValidLocale(LocaleID:LCID; dwFlags:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function GetSystemDefaultLCID:LCID; inline;
Description: To be documented
Note None documented


function GetUserDefaultLCID:LCID; inline;
Description: To be documented
Note None documented


function GetThreadLocale:LCID; 
Description: To be documented
Note None documented


function SetThreadLocale(LocaleID:LCID):BOOL; 
Description: To be documented
Note None documented


Locale functions (Ultibo)

function SetSystemDefaultLCID(LocaleID:LCID):BOOL; inline;
Description: To be documented
Note None documented


function WideCharToString(ABuffer:PWideChar):String;
Description: A replacement for WideCharToString in System unit to allow cross platform compatibility
Note The WideStringManager installed by the Unicode unit should make the System version equivalent


function WideCharLenToString(ABuffer:PWideChar; ALength:Integer):String;
Description: A replacement for WideCharLenToString in System unit to allow cross platform compatibility
Note Length is the size of the Buffer in WideChars (not Bytes). The WideStringManager installed by the Unicode unit should make the System version equivalent.


function StringToWideChar(const AString:String; ABuffer:PWideChar; ASize:Integer):Boolean;
Description: A replacement for StringToWideChar in System unit to allow cross platform compatibility
Note Size is the size of the Buffer in Bytes (not WideChars). The WideStringManager installed by the Unicode unit should make the System version equivalent.


Code page functions (Compatibility)

function IsValidCodePage(CodePage:UINT):BOOL; inline; 
Description: To be documented
Note None documented


function GetACP:UINT; inline;
Description: To be documented
Note None documented


function GetOEMCP:UINT; inline;
Description: To be documented
Note None documented


function GetConsoleCP:UINT; inline;
Description: To be documented
Note None documented


function SetConsoleCP(wCodePageID:UINT):BOOL; inline;
Description: To be documented
Note None documented


function GetConsoleOutputCP:UINT; inline;
Description: To be documented
Note None documented


function SetConsoleOutputCP(wCodePageID:UINT):BOOL; inline;
Description: To be documented
Note None documented


function GetCPInfo(CodePage:UINT; var lpCPInfo:TCPInfo):BOOL; inline;
Description: To be documented
Note None documented


function GetCPInfoEx(CodePage:UINT; dwFlags:DWORD; var lpCPInfoEx:CPINFOEXA):BOOL; inline;
Description: To be documented
Note None documented


function GetCPInfoExA(CodePage:UINT; dwFlags:DWORD; var lpCPInfoEx:CPINFOEXA):BOOL; inline;
Description: To be documented
Note None documented


function GetCPInfoExW(CodePage:UINT; dwFlags:DWORD; var lpCPInfoEx:CPINFOEXW):BOOL; inline;
Description: To be documented
Note None documented


Code page functions (Ultibo)

function SetACP(CodePage:UINT):BOOL; inline;
Description: To be documented
Note None documented


function SetOEMCP(CodePage:UINT):BOOL; inline;
Description: To be documented
Note None documented


Translation functions (Compatibility)

function MultiByteToWideChar(CodePage:UINT; dwFlags:DWORD; lpMultiByteStr:LPCSTR; cbMultiByte:Integer; lpWideCharStr:LPWSTR; cchWideChar:Integer):Integer; inline;
Description: To be documented
Note None documented


function WideCharToMultiByte(CodePage:UINT; dwFlags:DWORD; lpWideCharStr:LPCWSTR; cchWideChar:Integer; lpMultiByteStr:LPSTR; cbMultiByte:Integer; lpDefaultChar:LPCSTR; lpUsedDefaultChar:LPBOOL):Integer; inline;
Description: To be documented
Note None documented


function CompareString(Locale:LCID; dwCmpFlags:DWORD; lpString1:LPCSTR; cchCount1:Integer; lpString2:LPCSTR; cchCount2:Integer):Integer; inline;
Description: To be documented
Note None documented


function CompareStringA(Locale:LCID; dwCmpFlags:DWORD; lpString1:LPCSTR; cchCount1:Integer; lpString2:LPCSTR; cchCount2:Integer):Integer; inline;
Description: To be documented
Note None documented


function CompareStringW(Locale:LCID; dwCmpFlags:DWORD; lpString1:LPCWSTR; cchCount1:Integer; lpString2:LPCWSTR; cchCount2:Integer):Integer; inline;
Description: To be documented
Note None documented


function CharUpper(lpsz:LPSTR):LPSTR; inline;
Description: To be documented
Note None documented


function CharUpperA(lpsz:LPSTR):LPSTR; inline;
Description: To be documented
Note None documented


function CharUpperW(lpsz:LPWSTR):LPWSTR; inline;
Description: To be documented
Note None documented


function CharUpperBuff(lpsz:LPSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function CharUpperBuffA(lpsz:LPSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function CharUpperBuffW(lpsz:LPWSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function CharLower(lpsz:LPSTR):LPSTR; inline;
Description: To be documented
Note None documented


function CharLowerA(lpsz:LPSTR):LPSTR; inline;
Description: To be documented
Note None documented


function CharLowerW(lpsz:LPWSTR):LPWSTR; inline;
Description: To be documented
Note None documented


function CharLowerBuff(lpsz:LPSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function CharLowerBuffA(lpsz:LPSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function CharLowerBuffW(lpsz:LPWSTR; cchLength:DWORD):DWORD; inline;
Description: To be documented
Note None documented


function AnsiToOem(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function AnsiToOemBuff(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function OemToAnsi(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function OemToAnsiBuff(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function CharToOem(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline; 
Description: To be documented
Note None documented


function CharToOemA(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function CharToOemW(lpszSrc:LPCWSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function OemToChar(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function OemToCharA(lpszSrc:LPCSTR; lpszDst:LPSTR):BOOL; inline;
Description: To be documented
Note None documented


function OemToCharW(lpszSrc:LPCSTR; lpszDst:LPWSTR):BOOL; inline;
Description: To be documented
Note None documented


function CharToOemBuff(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function CharToOemBuffA(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function CharToOemBuffW(lpszSrc:LPCWSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function OemToCharBuff(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function OemToCharBuffA(lpszSrc:LPCSTR; lpszDst:LPSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


function OemToCharBuffW(lpszSrc:LPCSTR; lpszDst:LPWSTR; cchDstLength:DWORD):BOOL; inline;
Description: To be documented
Note None documented


Handle functions (Compatibility)

function CloseHandle(hObject:HANDLE):BOOL;
Description: To be documented
Note None documented


function DuplicateHandle(hSourceProcessHandle:HANDLE; hSourceHandle:HANDLE; hTargetProcessHandle:HANDLE; lpTargetHandle:LPHANDLE; dwDesiredAccess:DWORD; bInheritHandle:BOOL; dwOptions:DWORD):BOOL;
Description: To be documented
Note None documented


function GetHandleInformation(hObject:HANDLE; var lpdwFlags:DWORD):BOOL;
Description: To be documented
Note None documented


function SetHandleInformation(hObject:HANDLE; dwMask:DWORD; dwFlags:DWORD):BOOL;
Description: To be documented
Note None documented


Memory functions (Compatibility)

procedure MoveMemory(Destination,Source:PVOID; Length:SIZE_T); inline;
Description: To be documented
Note None documented


procedure CopyMemory(Destination,Source:PVOID; Length:SIZE_T); inline;
Description: To be documented
Note None documented


procedure FillMemory(Destination:PVOID; Length:SIZE_T;Fill:BYTE); inline;
Description: To be documented
Note None documented


procedure ZeroMemory(Destination:PVOID; Length:SIZE_T); inline;
Description: To be documented
Note None documented


function GlobalAlloc(uFlags:UINT; dwBytes:SIZE_T):HGLOBAL;
Description: To be documented
Note All flags except GMEM_ZEROINIT are ignored by Ultibo


function GlobalReAlloc(hMem:HGLOBAL; dwBytes:SIZE_T; uFlags:UINT):HGLOBAL;
Description: To be documented
Note None documented


function GlobalFree(hMem:HGLOBAL):HGLOBAL;
Description: To be documented
Note None documented


function GlobalSize(hMem:HGLOBAL):SIZE_T;
Description: To be documented
Note None documented


function GlobalFlags(hMem:HGLOBAL):UINT;
Description: To be documented
Note None documented


function GlobalLock(hMem:HGLOBAL):LPVOID;
Description: To be documented
Note None documented


function GlobalUnlock(hMem:HGLOBAL):BOOL;
Description: To be documented
Note None documented


function GlobalHandle(pMem:LPCVOID):HGLOBAL;
Description: To be documented
Note None documented


procedure GlobalMemoryStatus(var lpBuffer:MEMORYSTATUS);
Description: To be documented
Note None documented


function GlobalMemoryStatusEx(var lpBuffer:MEMORYSTATUSEX):BOOL;
Description: To be documented
Note None documented


function LocalAlloc(uFlags:UINT; uBytes:SIZE_T):HLOCAL;
Description: To be documented
Note All flags except LMEM_ZEROINIT are ignored by Ultibo


function LocalReAlloc(hMem:HLOCAL; uBytes:SIZE_T; uFlags:UINT):HLOCAL;
Description: To be documented
Note None documented


function LocalFree(hMem:HLOCAL):HLOCAL;
Description: To be documented
Note None documented


function LocalSize(hMem:HLOCAL):SIZE_T;
Description: To be documented
Note None documented


function LocalFlags(hMem:HLOCAL):UINT;
Description: To be documented
Note None documented


function LocalLock(hMem:HLOCAL):LPVOID;
Description: To be documented
Note None documented


function LocalUnlock(hMem:HLOCAL):BOOL;
Description: To be documented
Note None documented


function LocalHandle(pMem:LPCVOID):HLOCAL;
Description: To be documented
Note None documented


function VirtualAlloc(lpAddress:LPVOID; dwSize:SIZE_T; flAllocationType:DWORD; flProtect:DWORD):LPVOID;
Description: To be documented
Note The value of lpAddress on entry is currently ignored by Ultibo. The value of flProtect is currently ignored by Ultibo. As per Win32, the value of dwSize is rounded to the next page multiple.


function VirtualFree(lpAddress:LPVOID; dwSize:SIZE_T; dwFreeType:DWORD):BOOL;
Description: To be documented
Note None documented


function VirtualQuery(lpAddress:LPCVOID; var lpBuffer:MEMORY_BASIC_INFORMATION; dwLength:DWORD):DWORD;
Description: To be documented
Note None documented


function VirtualLock(lpAddress:LPVOID; dwSize:SIZE_T):BOOL;
Description: To be documented
Note None documented


function VirtualUnlock(lpAddress:LPVOID; dwSize:SIZE_T):BOOL;
Description: To be documented
Note None documented


function FlushInstructionCache(hProcess:HANDLE; lpBaseAddress:LPCVOID; dwSize:DWORD):BOOL;
Description: To be documented
Note None documented


function GetNumaHighestNodeNumber(var HighestNodeNumber:ULONG):BOOL;
Description: To be documented
Note None documented


function GetNumaProcessorNode(const Processor:Byte; var NodeNumber:Byte):BOOL;
Description: To be documented
Note None documented


Tls functions (Compatibility)

function TlsAlloc:DWORD;
Description: To be documented
Note None documented


function TlsAllocEx(bFree:BOOL):DWORD;
Description: To be documented
bFree If true then TlsValue will be freed on TlsFree or thread terminate


function TlsGetValue(dwTlsIndex:DWORD):LPVOID;
Description: To be documented
Note None documented


function TlsSetValue(dwTlsIndex:DWORD; lpTlsValue:LPVOID):BOOL;
Description: To be documented
Note None documented


function TlsFree(dwTlsIndex:DWORD):BOOL;
Description: To be documented
Note None documented


Thread functions (Compatibility)

function SwitchToThread:BOOL; inline;
Description: To be documented
Note None documented


procedure Sleep(dwMilliseconds:DWORD); inline;
Description: To be documented
Note None documented


function SleepEx(dwMilliseconds:DWORD; bAlertable:BOOL):DWORD; inline;
Description: To be documented
Note The bAlertable parameter is not currently used but is intended for I/O completion callback from ReadFileEx/WriteFileEx


function GetCurrentThread:HANDLE;
Description: To be documented
Note None documented


function GetCurrentThreadId:DWORD;
Description: To be documented
Note Thread Id and Thread Handle are currently equivalent


function GetThreadPriority(hThread:HANDLE):Integer;
Description: To be documented
Note None documented


function SetThreadPriority(hThread:HANDLE; nPriority:Integer):BOOL;
Description: To be documented
Note None documented


function GetExitCodeThread(hThread:HANDLE; var lpExitCode:DWORD):BOOL;
Description: To be documented
Note None documented


function GetThreadAffinityMask(hThread:HANDLE):DWORD_PTR;
Description: To be documented
Note None documented


function SetThreadAffinityMask(hThread:HANDLE; dwThreadAffinityMask:DWORD_PTR):DWORD_PTR;
Description: To be documented
Note None documented


function GetThreadTimes(hThread:HANDLE; var lpCreationTime,lpExitTime,lpKernelTime,lpUserTime:FILETIME):BOOL;
Description: To be documented
Note None documented


function CreateThread(lpThreadAttributes:LPSECURITY_ATTRIBUTES; dwStackSize:DWORD; lpStartAddress:LPTHREAD_START_ROUTINE; lpParameter:LPVOID; dwCreationFlags:DWORD; lpThreadId:LPDWORD):HANDLE;
Description: To be documented
Note None documented


function OpenThread(dwDesiredAccess:DWORD; bInheritHandle:BOOL; dwThreadId:DWORD):HANDLE;
Description: To be documented
Note None documented


function SuspendThread(hThread:HANDLE):DWORD;
Description: To be documented
Note None documented


function ResumeThread(hThread:HANDLE):DWORD;
Description: To be documented
Note None documented


function TerminateThread(hThread:HANDLE; dwExitCode:DWORD):BOOL;
Description: To be documented
Note None documented


procedure ExitThread(dwExitCode:DWORD);
Description: To be documented
Note None documented


function WaitForSingleObject(hHandle:HANDLE; dwMilliseconds:DWORD):DWORD;
Description: To be documented
Note None documented


function WaitForMultipleObjects(nCount:DWORD; lpHandles:PHANDLE; bWaitAll:BOOL; dwMilliseconds:DWORD):DWORD;
Description: To be documented
Note None documented


function WaitForSingleObjectEx(hHandle:HANDLE; dwMilliseconds:DWORD; bAlertable:BOOL):DWORD;
Description: To be documented
Note The bAlertable parameter is not currently used but is intended for I/O completion callback from ReadFileEx/WriteFileEx


function WaitForMultipleObjectsEx(nCount:DWORD; lpHandles:PHANDLE; bWaitAll:BOOL; dwMilliseconds:DWORD; bAlertable:BOOL):DWORD;
Description: To be documented
Note The bAlertable parameter is not currently used but is intended for I/O completion callback from ReadFileEx/WriteFileEx


Thread functions (Ultibo)

function BeginThreadEx(ThreadFunction:TThreadFunc; Parameter:Pointer; var ThreadId:TThreadID; const StackSize:SizeUInt; Priority,Affinity,CPU:LongWord; Name:PChar):TThreadID;
Description: To be documented
Note None documented


Message functions (Compatibility)

function WaitMessage:BOOL;
Description: To be documented
Note None documented


function GetMessage(lpMsg:LPMSG; hThread:HANDLE; wMsgFilterMin,wMsgFilterMax:UINT):BOOL;
Description: To be documented
Note None documented


function PeekMessage(var lpMsg:MSG; hThread:HANDLE; wMsgFilterMin,wMsgFilterMax,wRemoveMsg:UINT):BOOL;
Description: To be documented
Note None documented


function PostMessage(hThread:HANDLE; Msg:UINT; wParam:WPARAM; lParam:LPARAM):BOOL;
Description: To be documented
Note None documented


function SendMessage(hThread:HANDLE; Msg:UINT; wParam:WPARAM; lParam:LPARAM):LRESULT;
Description: To be documented
Note None documented


function SendMessageTimeout(hThread:HANDLE; Msg:UINT; wParam:WPARAM; lParam:LPARAM; fuFlags,uTimeout:UINT; var lpdwResult:DWORD_PTR):LRESULT;
Description: To be documented
Note None documented


Interlocked functions (Compatibility)

function InterlockedIncrement(var lpAddend:LONG):LONG; inline;
Description: To be documented
Note None documented


function InterlockedDecrement(var lpAddend:LONG):LONG; inline;
Description: To be documented
Note None documented


function InterlockedExchange(var Target:LONG; Value:LONG):LONG; inline;
Description: To be documented
Note None documented


function InterlockedExchangePointer(var Target:PVOID; Value:PVOID):PVOID; inline;
Description: To be documented
Note None documented


function InterlockedExchangeAdd(var Addend:LONG; Value:LONG):LONG; inline;
Description: To be documented
Note None documented


function InterlockedCompareExchange(var Destination:LONG; Exchange:LONG; Comperand:LONG):LONG; inline;
Description: To be documented
Note None documented


function InterlockedCompareExchangePointer(var Destination:PVOID; Exchange,Comperand:PVOID):PVOID; inline;
Description: To be documented
Note None documented


Mutex functions (Compatibility)

function CreateMutex(lpMutexAttributes:LPSECURITY_ATTRIBUTES; bInitialOwner:BOOL; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function CreateMutexA(lpMutexAttributes:LPSECURITY_ATTRIBUTES; bInitialOwner:BOOL; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function CreateMutexW(lpMutexAttributes:LPSECURITY_ATTRIBUTES; bInitialOwner:BOOL; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function OpenMutex(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function OpenMutexA(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function OpenMutexW(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function ReleaseMutex(hMutex:HANDLE):BOOL;
Description: To be documented
Note None documented


Semaphore functions (Compatibility)

function CreateSemaphore(lpSemaphoreAttributes:LPSECURITY_ATTRIBUTES; lInitialCount,lMaximumCount:LONG; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function CreateSemaphoreA(lpSemaphoreAttributes:LPSECURITY_ATTRIBUTES; lInitialCount,lMaximumCount:LONG; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function CreateSemaphoreW(lpSemaphoreAttributes:LPSECURITY_ATTRIBUTES; lInitialCount,lMaximumCount:LONG; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function OpenSemaphore(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function OpenSemaphoreA(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function OpenSemaphoreW(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function ReleaseSemaphore(hSemaphore:HANDLE; lReleaseCount:LONG; lpPreviousCount:LPLONG):BOOL;
Description: To be documented
Note None documented


Critical section functions (Compatibility)

procedure InitializeCriticalSection(var lpCriticalSection:CRITICAL_SECTION);
Description: To be documented
Note None documented


procedure EnterCriticalSection(var lpCriticalSection:CRITICAL_SECTION);
Description: To be documented
Note None documented


procedure LeaveCriticalSection(var lpCriticalSection:CRITICAL_SECTION);
Description: To be documented
Note None documented


function TryEnterCriticalSection(var lpCriticalSection:CRITICAL_SECTION):BOOL;
Description: To be documented
Note None documented


function InitializeCriticalSectionAndSpinCount(var lpCriticalSection:CRITICAL_SECTION; dwSpinCount:DWORD):BOOL;
Description: To be documented
Note None documented


function SetCriticalSectionSpinCount(var lpCriticalSection:CRITICAL_SECTION; dwSpinCount:DWORD):DWORD;
Description: To be documented
Note None documented


procedure DeleteCriticalSection(var lpCriticalSection:CRITICAL_SECTION);
Description: To be documented
Note None documented


Condition variable functions (Compatibility)

procedure InitializeConditionVariable(var ConditionVariable:CONDITION_VARIABLE);
Description: Initializes a condition variable
ConditionVariable The condition variable to initialize


procedure WakeConditionVariable(var ConditionVariable:CONDITION_VARIABLE);
Description: Wake a single thread waiting on the specified condition variable
ConditionVariable The condition variable to wake


procedure WakeAllConditionVariable(var ConditionVariable:CONDITION_VARIABLE);
Description: Wake all threads waiting on the specified condition variable
ConditionVariable The condition variable to wake


function SleepConditionVariableCS(var ConditionVariable:CONDITION_VARIABLE; var CriticalSection:CRITICAL_SECTION; dwMilliseconds:DWORD):BOOL; 
Description: Sleeps on the specified condition variable and releases the specified critical section as an atomic operation
ConditionVariable The condition variable to sleep on
CriticalSection The critical section object to release (This critical section must be entered exactly once by the caller at the time SleepConditionVariableCS is called)
dwMilliseconds The time-out interval, in milliseconds (If the time-out interval elapses, the function re-acquires the critical section and returns false)


procedure DeleteConditionVariable(var ConditionVariable:CONDITION_VARIABLE);
Description: Destroy a condition variable
ConditionVariable The condition variable to destroy
Note This function is Ultibo specific and is not part of the normal Windows API


Event functions (Compatibility)

function CreateEvent(lpEventAttributes:LPSECURITY_ATTRIBUTES; bManualReset,bInitialState:BOOL; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function CreateEventA(lpEventAttributes:LPSECURITY_ATTRIBUTES; bManualReset,bInitialState:BOOL; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function CreateEventW(lpEventAttributes:LPSECURITY_ATTRIBUTES; bManualReset,bInitialState:BOOL; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function OpenEvent(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE; inline;
Description: To be documented
Note None documented


function OpenEventA(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCSTR):HANDLE;
Description: To be documented
Note None documented


function OpenEventW(dwDesiredAccess:DWORD; bInheritHandle:BOOL; lpName:LPCWSTR):HANDLE;
Description: To be documented
Note None documented


function SetEvent(hEvent:HANDLE):BOOL;
Description: To be documented
Note None documented


function ResetEvent(hEvent:HANDLE):BOOL;
Description: To be documented
Note None documented


function PulseEvent(hEvent:HANDLE):BOOL;
Description: To be documented
Note None documented


Process functions (Compatibility)

function GetProcessAffinityMask(hProcess:HANDLE; var lpProcessAffinityMask,lpSystemAffinityMask:DWORD_PTR):BOOL;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function SetProcessAffinityMask(hProcess:HANDLE; dwProcessAffinityMask:DWORD_PTR):BOOL;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function GetProcessTimes(hProcess:HANDLE; var lpCreationTime,lpExitTime,lpKernelTime,lpUserTime:FILETIME):BOOL;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function GetProcessIoCounters(hProcess:HANDLE; var lpIoCounters:IO_COUNTERS):BOOL;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function GetCurrentProcess:HANDLE;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function GetCurrentProcessId:DWORD;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead. Thread Id and Thread Handle are currently equivalent.


procedure ExitProcess(uExitCode:UINT);
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


procedure FatalExit(ExitCode:Integer);
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


function TerminateProcess(hProcess:HANDLE; uExitCode:UINT):BOOL;
Description: To be documented
Note Ultibo has no concept of a Process so this function is mapped to Threads instead


Debug functions (Compatibility)

procedure OutputDebugString(lpOutputString:LPCSTR); inline;
Description: To be documented
Note None documented


procedure OutputDebugStringA(lpOutputString:LPCSTR);
Description: To be documented
Note None documented


procedure OutputDebugStringW(lpOutputString:LPCWSTR);
Description: To be documented
Note None documented


Library functions (Compatibility)

function lstrcmp(lpString1,lpString2:LPCSTR):Integer; inline;
Description: To be documented
Note None documented


function lstrcmpA(lpString1,lpString2:LPCSTR):Integer;
Description: To be documented
Note None documented


function lstrcmpW(lpString1,lpString2:LPCWSTR):Integer;
Description: To be documented
Note None documented


function lstrcmpi(lpString1,lpString2:LPCSTR):Integer; inline;
Description: To be documented
Note None documented


function lstrcmpiA(lpString1,lpString2:LPCSTR):Integer;
Description: To be documented
Note None documented


function lstrcmpiW(lpString1,lpString2:LPCWSTR):Integer;
Description: To be documented
Note None documented


function lstrcpy(lpString1:LPSTR; lpString2:LPCSTR):LPSTR; inline;
Description: To be documented
Note None documented


function lstrcpyA(lpString1:LPSTR; lpString2:LPCSTR):LPSTR;
Description: To be documented
Note None documented


function lstrcpyW(lpString1:LPWSTR; lpString2:LPCWSTR):LPWSTR;
Description: To be documented
Note None documented


function lstrcpyn(lpString1:LPSTR; lpString2:LPCSTR; iMaxLength:Integer):LPSTR; inline;
Description: To be documented
Note None documented


function lstrcpynA(lpString1:LPSTR; lpString2:LPCSTR; iMaxLength:Integer):LPSTR;
Description: To be documented
Note None documented


function lstrcpynW(lpString1:LPWSTR; lpString2:LPCWSTR; iMaxLength:Integer):LPWSTR;
Description: To be documented
Note None documented


function lstrcat(lpString1:LPSTR; lpString2:LPCSTR):LPSTR; inline;
Description: To be documented
Note None documented


function lstrcatA(lpString1:LPSTR; lpString2:LPCSTR):LPSTR;
Description: To be documented
Note None documented


function lstrcatW(lpString1:LPWSTR; lpString2:LPCWSTR):LPWSTR;
Description: To be documented
Note None documented


function lstrlen(lpString:LPCSTR):Integer; inline;
Description: To be documented
Note None documented


function lstrlenA(lpString:LPCSTR):Integer;
Description: To be documented
Note None documented


function lstrlenW(lpString:LPCWSTR):Integer;
Description: To be documented
Note None documented


Return to Unit Reference